Landscape mode handle when auto screen orientation is ON and easily turn to portrait. But Auto Screen Orientation is Off then forcefully change supported orientation which effect on if Auto Screen Orientation is ON. Pls tell me these things in WP
How check auto screen orientation of setting ON or Off?
Another way to change orientation of screen contents?
To specify that your app supports portrait and landscape, you must set the SupportedOrientations property to PortraitOrLandscape either in the XAML or in the code.
Add this piece of code in your XAML within the <phone:PhoneApplicationPage>
SupportedOrientations="PortraitOrLandscape"
Take a look over here
Hope it helps!
Read this quick start tutorial on how to gracefully handel orientation change in windows phone 8
Screen orientation for Windows Phone 8
In short, if you need to support both orientations than first you need to change your SupportedOrientation in you page xaml SupportedOrientations="PortraitOrLandscape"
Then handle orientation Changed Event in the code for UI related changes(as explained in above artical)
You can use following page property on page load to check the current orientation of the screen when it is loaded.
this.SupportedOrientations
Hope this helps
Related
Better than a long description, I made some schemas :)
The 2 native use cases show the classical behaviours when I rotate my tablet.
Native Landscape mode use case
Native Portrait mode use case
Now, I would like to be able to rotate virtualy my tablet and see on the 2nd screen in Portrait mode.
In other words, the tablet remains in landscape with the view rotated 90° and the 2nd screen shows view portrait.
Wished behaviour use case
But I encountered 2 issues:
1/ The 2nd screen remained in landscape mode with 90° rotation when the "lock rotation" feature is enabled.
Behaviour issue when lock rotation enabled
2/ The tablet toggled into lanscape because of autorotation and the 2nd screen stayed in portrait mode but the view is the landscape one.
Behaviour issue when lock rotation disabled
So to do that, I found Display.exe to rotate my view and it's a good start.
But it seems that the software is not designed to handle the wished use case.
Is there some extra configuration on Windows 10 to change in order to force duplicated screen to be in portrait mode?
Other ideas to reach my goal are welcome!
Thanks all,
Kelson
I'm developing a WP/ camera app that shows the picture that have been taken. Is there a way to somehow know how your currently holding your camera so that the image preview will display the picture as portrait or landscape?
Have a read of How to Handle Orientation Changes in WP7
On PhoneApplicationFrame you have Orientation property
Just replace or add the below codes to PhoneApplicationFrame.....
SupportedOrientations=”PortraitOrLandscape”
I have a directdraw application (in c) that becomes black in color once the user rotates the screen using a button on the application. The button uses enumdisplaysettings to do this. I have tested this on both Nvidia and ATI, the problem persists.
Is there a way to make a directdraw application "displaysettings-proof"? Can I add some code to get back the display once the screen is rotated?
You can use IDirectDraw::RestoreDisplayMode to reset the display mode to whatever it was before IDirectDraw::SetDisplayMode was called. I'm not quite sure if this is what you want however.
I saw the splash screen of the Corel-Draw 12 application and lost my mind!
What technique do they use?
On application start-up they load a transparent image, use windows api or what?
How do they achieve this transparency?
Here is a demo project for both VB.NET & C#.
If you are using winforms with vb.net you can modify the opacity of any form by setting the Form.Opacity property. I am not familiar with the splash screen you are speaking about but it shouldn't be too difficult to achieve a similar effect.
If you're using WPF, set the AllowsTransparancy, WindowStyle and Background attributes on the Window object:
<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
AllowsTransparency="True"
WindowStyle="None"
Background="Transparent">
<!-- more -->
</Window>
I am also unfamiliar with this flash screen... but if it slowly fades or something, then I would go with Quintin's answer here. Opacity at a certain percentage will show another form through yours.
If the splash screen is just an image and some of it is see-through and some of it isn't, then you can set the transparency key on your form to a certain color, then set the form's background color equal to that, and then whatever image you wish to display should be loaded into a picture box. Make sure you use a .GIF image though! or some other format that supports deleting out the background. JPG's and BMP's are worthless here since their "empty" color becomes white instead of transparent.
I am new to BlackBerry Java application development. My scenario is: In my application a gallery list of images will be displayed in a small icons. If I click on any image it will display in a large mode. Here I need to provide controls like front and back buttons. On clicking on those buttons the background image should change. In addition to that those buttons should be highlighted and the back ground large image should be transparent. How to do this?
Please guide me.
You can use Graphics.setGlobalAlpha() on paint() or to modify bitmap before preview.
Don't forget to set back normal global alpha value after bitmap drawing.