Skip to content Skip to sidebar Skip to footer

Design Looks Perfect On Phone But So Small On Tablet - Android Studio

I made up this xml file for my android project, the design looks perfect on my phone but running it on my tablet makes buttons, images,... look so small, i would love to make their

Solution 1:

You can try scalable dp instead of dp/sp etc. This will adjust the size of views according to device running on.

Dependency:-

compile'com.intuit.sdp:sdp-android:1.0.2'

Use like this:-

Replace all "10dp" (your dp value) with "dimen/_10sdp" (change according to your dp value) in your xml.

Solution 2:

You have to design your xmls for multi screens. For tab supported, you should create layout-sw600dp layout, this will support 7 inch tablets and for 10 inch tablet create layout-sw720dp. After creating those layouts in res folder copy and paste your xmls in that folders and give sizes for views according to your requirement.

Post a Comment for "Design Looks Perfect On Phone But So Small On Tablet - Android Studio"