Dynamic Scalable Size Android
DynamicSizes — dynamic scalable size unit
An android SDK that provides a new size unit — hsdp. This size unit scales with the screen size. It can help Android developers with supporting multiple screens.
With this library, you can support almost 97% of screens
Use it carefully! for example, in most cases you still need to design a different layout for tablets.
Example
Here is a single layout built using hsdp:

Here is a single layout built using dp:

You can see that hsdp scales with the screen size and the dp stays with the same size on all screen sizes.
How to integrate Dynamic Scalable Size Library into Android Project?
For use this library, you should use AndroidX
instead of Support
Step 1:
Add below code into <project>/build.gradle file.
allprojects {
repositories {
maven { url 'https://jitpack.io' }
}
}
Step 2:
Add below code into <project>/<app>/build.gradle.
dependencies {
implementation 'com.hardik.hsdp:scalablesize-android:1.0.1'
}
How to Use Dynamic Scalable Size in layout?
╔════════════════╦════════════╦═══════════════╗
║ Types ║ Values ║ Example ║
╠════════════════╬════════════╬═══════════════╣
║ Normal sizes ║ hsdp ║ _15hsdp ║
║ Font size ║ font_ssp ║ _15font_ssp ║
║ Negative sizes ║ mines_hsdp ║ _minus15hsdp ║
╚════════════════╩════════════╩═══════════════╝
Example:
How to use this hsdp size unit, please see this link : hsdp_layout.xml
So that’s all for this Dynamic Scalable Size Android Tutorial. If any query/suggestion for Dynamic Scalable Size Tutorial ask freely on hardikdungrani8@gmail.com
Please go through my GitHub repository.
Thanks.
Hardik D.