I'm designing for Mobile Web and have an image/button in a mobile site, (positioned by percentages) that shows up correctly on an iPhone (in portrait and landscape).
However, when tried on most Android phones, the image does not show up until the phone is rotated to a landscape position, and then will show up in the correct position in portrait. It will not load in portrait mode with the button showing.
I've tried positioning, z-index and that doesn't seem to be what is causing it.
Any help is greatly appreciated, thanks!
I'm not sure if I'm able to comment yet so I will just post this here and a mod can move it if they want.
Many browsers interpret css differently. I would make sure that you do not have overflow:hidden or overflow:inerit which is taking the form of "hidden." It's the only thing I can think that would lead to it being invisible until the screen is widened.
Related
I have submitted an android tv app to the play store and got rejection email explaining the reason that:
Not designed in landscape orientation. Your app has vertical letterboxing when displayed on TV's. Please design your app to be displayed in landscape orientation.
I have tried removing margins from the screen designs but it didn't helped me. Can anyone help me in solving this issue. I have already added the leanback launcher intent and software.leanback uses feature tag with true value.
Thanks In Advance.
You don't want to just remove padding/margins without explicitly testing it. You have to deal with overscan on TVs, so having anything important at the very edge means it might not be visible on some devices. On ATV, the normal values are 48dp horizontally and 27dp vertically. If you're using the Leanback library, this is handled for you.
Vertical letterboxing is almost always a case of something that's inherently portrait orientation being show in landscape.
You should verify that none of your activities have a screenOrientation set (unless it's landscape). It's pretty common for people to forget one particular screen is forced to portrait (e.g., a login screen from a 3rd party SDK). A quick launch of each Activity/Fragment on an ATV emulator will also help you catch anything wildly wrong.
If your app has video, you also want to make sure you're reasonably matching the aspect ratio. For example, you should display a 16x9 video instead of a 2x3 video on landscape.
I have almost same problem:
To fix this issue, please ensure that your app/game is displayed in landscape orientation and the content fills the entire screen.
Alternatively, if your app requires content to be displayed in its original aspect ratio or is of older quality, please include a disclaimer in your app description or within the app prior to the content playing. You may want to refer to our TV Layouts documentation for additional guidance.
I choosed Alternate solution because the sent me a screenshot of old video in 4:3 scale.
I symply added to app description text about possibility to show content in 4:3 aspect ratio. I hope ot will help. Will it?
I have looked around but, I am unable to find an answer to my question. Basically, I am creating a phone app. The only problem I seem to be having is with the menu UI. Basically, it is set to a 1080x1920 resolution, which is probably the most common one out there. However, it is not the only one. How do I handle multiple screen resolutions? Do I need to make like separate widgets for each resolutions and load in the correct one based on that? Or is there some other way that I am just not aware of. I am sure that others have come across this same problem too.
The reason I bring this up is because I have loaded the app onto a phone that is not 1080x1920 and the UI doesn't fit inside of it. I have tried messing with different settings on the UI but, nothing seems to fix it. Any help would be greatly appreciated.
There were two problems that were happening. The first reason why the UI wasn't scaling properly was because I was using a Size Box instead of just a plain Canvas Panel. It didn't matter what I did, the Size box would remain the same. Changing that would solve the first problem. The second problem that was happening was that because of the size box it forced my anchors to be centered instead of stretched. Once I replaced the Size Boxes with Canvas Panels I was able to make my panel anchors stretch to fill the screen.
I hope this helps anyone else that comes across this problem.
I have a webview which opens a page that shows different images like a gallery.
The image is saved locally on an sdcard and is loaded through css with background-image: url(file://...).
This issue seems (not sure though) to be connected to Android's request for resources for some reason. The longer the OS needs resources the bigger the white (or black) band is.
This doesn't happen always in one test session and affects images randomly (in a cycle a certain image displays ok, in the next it doesn't). Also it seems to affect only images, displaying an iframe is always loaded normally.
I wouldn't have a problem if this happened for one second and then it would display normally, the problem is that the image stays like that until the next refresh of the webview.
android's version is 4.4.2. It is a mk808b plus device if any of this helps...
Any ideas on how to solve or somehow decrease the times this happens... anything really... except using imageview, I want to keep all in the webview. Any directions to follow for further debugging are also greatly appreciated.
Thank you for any help you can provide.
If it is possible I would try converting background images to a vectorial format (like SVG). Rendering should be easier and less memory hungry.
So I am making a game in processing, but I'm not aware as to how to make my game fit every android phone's screen, I've looked online, but I can't seem to find anything about it in Processing.
I'm fully aware of displayWidth/displayHeight, but I'm not too sure on how to make my buttons to be all pressable, and never change their positions, I would've thought that it would be done by putting all the co-ordinates using something like displayHeight/2 etc. etc. But I've tested the game out on my phone(Samsung Galaxy S3), but the text is not aligned properly
If anyone could please help me, I'd be super grateful!
android devices have different screen size, so instead of using px you can use percentage(%) value for the screen i believe it is sp(a different unit than px) by using this the properties you set for an identity or element becomes constant for all devices
I know you can set orientation using android:screenOrientation statically and setRequestedOrientation programatically. However the problem is that if I use either of these to set the screen orientation I do not get to choose which landscape or which portrait I want. To wit, flipping the phone 180 degrees does not rotate the view but rather just appears upside down to the user. I cannot use screenOrientation="sensor", because in some cases I would only want the view to be landscape OR portrait and seldom both. This seems insignificant until you consider external hardware.
If I developed an app and set the layout to android:screenOrientation="landscape", the app would only display correctly if the left side of the droid were sitting on a desk. Unforunately the left side is where the usb port is, so the phone would not sit very well on that side if it were plugged in. Unless of course they used a docking station but that is not the kind of help I am looking for. If the right side of the phone is sitting on the desk to allow for the cord, the display appears upside down. I tried posting an image but being a new user I was not able to do so.
What I would like to know is how to programmatically choose which landscape (Surface.ROTATION_90,Surface.ROTATION_270) or portrait (Surface.ROTATION_0,Surface.ROTATION_180) orientation I wish the user to see, but more importantly allow them to do so in the app's settings activity. I have googled for quite awhile and all I can find are sensors that tell you when the orientation/rotation has changed and to what, but none show how to programmatically set either.