Reader small image

You're reading from  Mastering Android Studio 3

Product typeBook
Published inAug 2017
Reading LevelIntermediate
Publisher
ISBN-139781786467447
Edition1st Edition
Languages
Right arrow
Author (1)
Kyle Mew
Kyle Mew
author image
Kyle Mew

Kyle Mew has been programming since the early '80s and has written for several technology websites. Also, he has written three radio plays and four other books on Android development.
Read more about Kyle Mew

Right arrow

Screen orientation

A large percentage of Android apps designed for phones and tablets are designed to work in both landscape and portrait mode and generally switch between these automatically. Many activities, such as videos, are best viewed in landscape mode, while lists are usually easier to scan in portrait; however, and there are some activities, and even entire apps, where the orientation is fixed.

There are some layouts that look equally good, whichever way they are viewed, but this is not often the case; most of the time, we will want to design one for each orientation. Android Studio simplifies and speeds up this process by saving us the task of developing an alternative layout from scratch.

Take a simple layout like the one here:

A portrait layout

A landscape variant can be created with a single click from the Layout Variant tool at the top of the design editor, as follows...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Mastering Android Studio 3
Published in: Aug 2017Publisher: ISBN-13: 9781786467447

Author (1)

author image
Kyle Mew

Kyle Mew has been programming since the early '80s and has written for several technology websites. Also, he has written three radio plays and four other books on Android development.
Read more about Kyle Mew