6

Where can I find the button to Create Landscape Variation?

In the version of Android Studio that I'm using there is a button to rotate the screen but not to add a variation. I'm using Android Studio 2.2 Preview 7

ANSWERED:

The button that I was looking for was hidden by the 'Properties' view.

Community
  • 1
  • 1
danger mouse
  • 1,457
  • 1
  • 18
  • 31
  • There is this.. I hope it helps http://stackoverflow.com/questions/28815769/android-studio-creating-landscape-layouts#answer-29467041 Upvote the OP –  Aug 24 '16 at 13:23
  • Personally, I might prefer copying the portrait layout into the layout-land folder because the names of the file needs to be the same and the views need to be similar anyways – OneCricketeer Aug 24 '16 at 13:46

5 Answers5

6

well, some answer might not be the answer for latest android version (chipmunk).

here i found it:

android chipmunk: enter image description here

Kakaranara
  • 97
  • 2
  • 7
4

In Android Studio 3.0 and higher the option to create a layout variant has been brought under the "Orientation in Editor" button. There is no longer a separate button for "Layout Variants". See image link below. I've already created a landscape variant hence only the option for an xlarge variation shows up

Create Layout Variation

pcodex
  • 1,812
  • 15
  • 16
4

Android Studio Chipmunk has changed the location of the menu option to create a landscape variation. While in Design mode, click the activity XML toolbar button and select Create Landscape Qualifier from the menu.

enter image description here

tronman
  • 9,862
  • 10
  • 46
  • 61
  • It is the same in Android Studio Dolphin | 2021.3.1 Patch 1. The online documentation, Build a UI with Layout Editor section shows the right picture but the steps they describe do not match, they are the old way. https://developer.android.com/studio/write/layout-editor – jla Feb 07 '23 at 05:59
2

Typically I do this by right clicking on the res directory and then clicking new -> Android resource directory. Choose "Orientation" and name the Directory "Landscape". Then make sure to set the resource type to Layout.

Android Studio: Creating landscape layouts

In android 2.0, there is also a button available above the design preview.

enter image description here

Community
  • 1
  • 1
Joel Nieman
  • 746
  • 4
  • 13
  • Thank you - that's a useful alternative to the button that I was looking for. – danger mouse Aug 24 '16 at 13:33
  • Glad it helped. Please accept my answer if you could. – Joel Nieman Aug 24 '16 at 13:34
  • I appreciate your post, which is why I clicked on 'up vote'. However, the description for the 'accept answer' is for solving my problem or most helpful in finding solution. I was asking specifically about the button shortcut, and had actually already known about the alternative that you suggested. I don't want to confuse others by accepting your answer - I hope you understand. Thanks again for your time – danger mouse Aug 24 '16 at 13:52
  • I had also known about the page linked from your post (see the link in mine). Fyi the button that I have in my Android Studio looks different to the one in the image in your post. It appears at the right of the others, and was hidden by my 'Properties' view (please see my post). Since I answered my question myself before anyone else, I won't be accepting an answer for my question as I feel it would confuse others. – danger mouse Aug 24 '16 at 14:09
2

My Android Studio version is Android Studio 2.3.3 built on June 6, 2017,

And here is the Create Landscape Variation Button in the Design Section.

Create Landscape Variation Button

Community
  • 1
  • 1
devDeejay
  • 5,494
  • 2
  • 27
  • 38