Questions tagged [landscape]

A page or device orientation in which the horizontal axis is longer than the vertical axis.

A page or device orientation in which the horizontal axis is longer than the vertical axis. Contrast with portrait orientation, where the vertical axis is the major axis.

1434 questions
324
votes
12 answers

Force "portrait" orientation mode

I'm trying to force the "portrait" mode for my application because my application is absolutely not designed for the "landscape" mode. After reading some forums, I added these lines in my manifest file:
thomaus
  • 6,170
  • 8
  • 45
  • 63
159
votes
11 answers

How do I specify different layouts for portrait and landscape orientations?

I've seen references to being able to specify two separate layout xml files for an activity, one for Portrait and one for Landscape. I've not been to find any information on how to do that though. How do I specify for each activity which xml file…
Jay Askren
  • 10,282
  • 14
  • 53
  • 75
158
votes
16 answers

Force an Android activity to always use landscape mode

I am using the Android VNC viewer on my HTC G1. But for some reason, that application is always in landscape mode despite my G1 is in portrait mode. Since the Android VNC viewer is open source, I would like know how is it possible hard code an…
hap497
  • 154,439
  • 43
  • 83
  • 99
110
votes
16 answers

Getting android.content.res.Resources$NotFoundException: exception even when the resource is present in android

Please let me know where I am going wrong to get the error. I am creating an app which have one of its activity to be only in landscape mode. So I added the following in AndroidManifest.xml file
Nik
  • 2,913
  • 7
  • 40
  • 66
100
votes
8 answers

iPhone app in landscape mode, 2008 systems

Please note that this question is from 2008 and now is of only historic interest. What's the best way to create an iPhone application that runs in landscape mode from the start, regardless of the position of the device? Both programmatically and…
Michiel de Mare
  • 41,982
  • 29
  • 103
  • 134
96
votes
15 answers

Supported orientations has no common orientation with the application, and shouldAutorotate is returning YES'

My app (iPad;iOS 6) is a landscape only application, but when I try using a UIPopoverController to display the photo library it throws this error: Supported orientations has no common orientation with the application, and shouldAutorotate is…
Destiny Dawn
  • 1,457
  • 3
  • 15
  • 29
89
votes
21 answers

Force landscape mode in one ViewController using Swift

I am trying to force only one view in my application on landscape mode, I am calling: override func shouldAutorotate() -> Bool { print("shouldAutorotate") return false } override func supportedInterfaceOrientations() -> Int { …
sazz
  • 3,193
  • 3
  • 23
  • 33
59
votes
10 answers

How do I disable landscape-orientation on an iPad app?

I created a completely new, single-view iOS universal Swift app. Then, I unchecked "Landscape Left" and "Landscape Right" in the app settings. I ran it on my iPhone, and hooray, it stays in portrait mode no matter how I rotate my phone. Then I ran…
Eugene
  • 3,417
  • 5
  • 25
  • 49
55
votes
9 answers

Find out if Android device is portrait or landscape for normal usage?

Is there anyway to find out if a device is portrait or landscape by default? In that I mean how you normally use the device. Most phones have a portrait screen for normal usage but is there some flag for finding that out?
joynes
  • 1,627
  • 4
  • 16
  • 19
44
votes
5 answers

Only ONE VIEW landscape mode

I finished my iOS app but I need to set only ONE view to landscape mode, the rest of the views can only be seen in portrait mode. I'm using Xcode 5.1 and I created all of my Views by dropping in my storyboard View Controllers from the right panel,…
maeq
  • 1,073
  • 1
  • 12
  • 23
41
votes
5 answers

Crash on presenting UIImagePickerController under iOS 6.0

My app only supports landscape orientations via the supportedInterfaceOrientation properties. Using an iOS prior to iOS 6, my app can successfully load an instance of UIImagePickerController via presentViewController:animated:completion: even…
jenonen
  • 573
  • 1
  • 5
  • 8
39
votes
3 answers

UIViewController returns invalid frame?

When I start my ViewController in landscape mode (After viewDidLoad is called), I print the frame it's giving me the frame size for portrait mode instead. Is this a bug any suggestions? - (void)viewDidLoad { [super viewDidLoad]; NSLog(@"%@",…
aryaxt
  • 76,198
  • 92
  • 293
  • 442
36
votes
7 answers

How to change GENYMOTION screen orientation?

Is it possible to change the orientation of the genymotion emulator? Is there a shotcut or setting to change this? I've tried to google it but have not find it. Any suggestion would be appreciated,thank you.
topxebec
  • 1,417
  • 3
  • 15
  • 29
32
votes
9 answers

Using UIImagePickerController in landscape orientation

I am creating an app which is in landscape mode and I am using UIImagePickerController to take photos using iPhone camera in it and I want to create it in landscape mode too. But as the Apple documention suggests UIImagePickerController does not…
30
votes
2 answers

Force portrait orientation while pushing from landscape View Controller

App Support: iOS6+ My app works in both portrait and landscape. But 1 controller should only works in a Portrait. The problem is that when I am in landscape and push the view controller the new viewcontroller is in landscape as well until I rotate…
Tariq
  • 9,861
  • 12
  • 62
  • 103
1
2 3
95 96