How can I set the design preview in Android Studio to show a tablet layout instead of a phone layout?

Viewed 2723

I'm at the moment developing an app for tablets and the app isn't supposed to be available for phones. When I edit an XML in Android Studio, there's the design preview that shows roughly how the XML will be rendered on the device. By default it's set to show it in a phone device. How do I set this to be a tablet view?

3 Answers

By default, it should have a nexus 5 and an icon at the top. Click on that icon ans a list of devices will appear.In the third listView you will find Nexus 7 where it is a tablet. CHoose one from that listView.enter image description here

Go to XML EDITOR

Click on Device Editor

Now you will see different type of Device with there Name ,resolution and size

Bottom of the device list you will see Generic Phones and Tablets

enter image description here

In Android Studio, go to Preview - Top Toolbar:

enter image description here

  • The pixel phone name will let you choose the screen to show in the Android Studio Preview so, this can be helpful to design the layout for Tablets.

  • The second icon, has two options called Landscape and portrait which the first one Landscape will help to design the layout for the purpose.

  • The second option & important is, Create Tablet Variation which creates few directories for designing the Tablet layout.


There is also an option in the phone icon called Generic phones and Tablets which you might consider using.

Related