In rare situations our application goes into a state where no letters are displayed. Screenshots are attached to demonstrate this. On the first is the application in normal state, on the second with letters disappeared (http://pic.pschstavebni.cz/limigo.png). It seems that all the TextViews (updated in code) does’nt display any text. This happens rarely and we can’t reproduce it in test environment. For most users, the application works fine, for few of the users this state sometimes occurs. After a device restart the application works normally. Does anyone know what could cause this problem?
Users have Samsung Note 8 tablets. Layout is done using fragments in v4 support library.
All TextViews have default value in xml layout. I checked code for uncaught exceptions and OutOfMemory problems, but without success.
Make sure that the elements on the XML layout have a good alignment.
The issue has been resolved after upgrading to a newer version of android.
Related
I'm stuck in a unknown issue of coloring. I develop an food delivery application. I set the design of application, for example i take Food Menu screen. Actual output of screen :
I run the app on almost 6 mobiles include samsung, q-mobile, huawei. It works perfect.
But when i run the app on another random samsung mobile it show me the layout like this:
I don't know why this dark gray appear in boxes bakcground. This is happening in only one mobile of samsung. I'm confused because i also check on samsung on other mobile with same android version and it works fine.
The same thing was happening to me on my OnePlus phone. The solution I use was that I added background color for all component that was not using correct color on my OP phone. So in the case of CardView's that you have below, I added app:cardBackgroundColor property to CardView XML component view and it started to show just fine. I didn't investigate any further to know what was the reason behind this, but as you said, it almost certainly got to do something with a different Theme on that Samsung.
For some inexplicable reason, focusing on certain entrys (textedits in native Android) within our app causes the parent container along with all of its contents to be pushed completely off the screen - and this problem only occurs on the Galaxy S8 and Galaxy Note 8.
The only difference between the entries that work correctly and those that do not seems to be the size of their parent containers. The larger the container, the more likely the problem is going to occur.
The following screenshots show the size difference - the entry in the first screenshot works as expected. The second screenshot is where the problem occurs.
Does anyone have any idea what is causing this or how to resolve it?
This might be issue due to softinput mode in android you can try this Onscreenkeyboard issue in xamarin
This bug only occurs on my Nexus 5 and my Nexus 7 running Lollipop.
EDIT
This bug also occurs in the new Inbox app by Google, when I'm going into Inbox > Settings > Notifications > any item and go back...
/EDIT
compileSdkVersion 21
buildToolsVersion 21.1.1
compile 'com.android.support:appcompat-v7:21.0.2'
I'm having a GalleryActivity that shows multiple images, once per page (inside a ViewPager. When I hit the back button, sometimes the Android's SystemUI have glitches.
Normal view
Glitched view
See how the views repeats themselves, and inside the system itself?
A simple touch event brings back the normal SystemUI views.
What is going on?
Might be similar to:
Android 5 screen glitch/static with Google Maps Fragment inside a Viewpager
Android Lollipop Activity Screen corrupted
Setting android:hardwareAccelerated="false" is a kind of extreme solution, as graphical performance is likely to be very bad.
If you can pinpoint the view that is misbehaving and causing this issue, a better fix would be to switch it to software rendering instead, via setLayerType(), e.g.
view.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
Funny thing is, I haven't experienced any rendering glitches with Lollipop so far, but we did see them in KITKAT (as mentioned in this question), and only when WebViews are present on the screen.
I would recommend experimenting with toggling this on different views until the problem is isolated (especially if it's easy to reproduce).
So far, every occurence of this issue has been related to WebViews (or components that use WebView, such as AdMob). According to the AOSP Issue Tracker the problem is fixed in Android 5.0, but it doesn't seem to be the case.
I've seen UI glitches with Lollipop, though different than yours. The only workaround I found was disabling hardware acceleration:
android:hardwareAccelerated="false"
at the Activity or Application level. If this resolves your glitches, make sure to report this to Google as this would indicate a bug in the platform. There is already at least one open report with them already.
I certainly wouldn't want to deploy an application with this setting, it's really only intended to answer the WHY and help prove that it's not a bug in your code.
Hope this helps!
EDIT 12/10/2014:
#matiash offered a much more precise answer than this "sledgehammer" suggestion. I was seeing drawing glitches mostly on the ActionBar in a multi-tab app with ViewPager, and always on tabs/pages without any WebView at all. However, one of my tabs/fragments does have an embedded WebView, and when setting it to software rendering, my glitches appear to have gone away. I'm not at all uncomfortable putting the workaround suggested by #matiash in a shipping app...though it still points to some underlying issue in the platform.
I have also witnessed this problem in my own app.
Any Android devs ever experience this kind of visual static? (see picture)
Not only did I get that kind of visual static, but also repeated drawing. Only witnessed it on Nexus 5 with 5.0 when developing with api 21 and support library 21.0.+.
For me its not very reproducible. It will happen repeatedly during one session of use, but the next day I won't be able to reproduce it.
I am not using any WebViews (accept maybe via admob). I am using ViewPagers with fragments. I am also using DragSortList and first started seeing the issue in Activities that used it.
https://github.com/bauerca/drag-sort-listview
How reproducible is it for you guys?
have you tried to set android:fitsSystemWindows="true" in your Fragment layout? this will make sure the layout is below the statusBar, im not really sure about the navigation buttons but i guess this should work for it too.
Call request layout on DecorView after rendering:
getActivity().getWindow().getDecorView().requestLayout();
I call it using postDelay() in WebViewClient.onPageFinished(). It's not a perfect solution (just a workaround) but maybe better way like LAYER_TYPE_SOFTWARE.
.........go to settings and then developer options(if they are not visible... go to about phone then click on build number 7-10 times and developer mode will be on) and there scroll down and untick 'show layout bounds' and you are done. its simple and easy.
I'm currently developing an application with which a schedule can be retrieved and viewed. To display the schedule I used the TimeRulerView (and BlocksLayout and BlockView) java source files from the Google IO 2011 app because I liked the look and feel. Source code can be found here: https://github.com/underhilllabs/iosched2011 . (Google replaced there one with the code of IO2012).
Since my Galaxy Nexus updated tot Jelly Bean (4.1.1) yesterday the TimeRulerView (and/or one of the others) doesn't get shown anymore.
The weird thing is that they are actually still there, but there not visible. I can see a scrollbar of the length the timeruler normally has. Also when I normally click on an block in the view I get a little pop-up, and this still happens when not seeing the timeruler or a block.
I tested the original IO2011 app on my JB GN but nothing is visible there either, so the problem lies within (one of) the view(s) or the way JellyBean is rendering the view(s) (project butter maybe?).
See here ( https://dl.dropbox.com/u/7102660/TimeRulerView_JellyBean_problem.zip ) for screenshots on ICS (app working), JB (app not working) and the GoogleIO2011 app.
Could this be something to do with Hardware acceleration? I just recently ran into an issue on couple phones with ICS, but not all phones/devices were affected. Adding the hardwareAccelerated tag to my manifest didn't fix the issue either, and I had to define it on specific views that I did not want to be hardware accelerate. My solution used android:layerType="software" in my xml layouts and setLayerType(LAYER_TYPE_SOFTWARE, null) in the java code.
EDIT: Testing this more, it didn't fix my issue using setLayerType on Jelly Bean. Setting the layer type to software on ICS did fix my issue. The only way I could make the views show up was setting the whole application or specific activity to android:hardwareAccelerated="false".
Thanks to Chris answer I played around with hardware acceleration settings. I use the iosched2011 code as well and only had to remove the line android:layerType="software" from my BlocksLayout View inside the block_content.xml file .
As the titles state, I can't drag widgets onto the screen. Attempting to do so simply produces a dashed outline, but the widget isn't added. Different widgets cause differently-sized outlines to be created, so the application (Eclipse) is recognizing my input to some degree. No errors are produced either.
I've found no documentation on the drag-and-drop UI approach, probably because it's supposed to be self-explanatory (I had no problems doing the same thing on Qt, for example). Also note that I've gotten a basic "hello world" program working, both on an emulated device and on a smartphone.
I tried uploading a picture illustrating the problem but as I am a new user I don't have the permissions to do so.
EDIT: Well restarting Eclipse fixed the issue, though I still don't know what caused it.
Well restarting Eclipse fixed the issue, though I still don't know what caused it.