Anyone know why the android keyboard input text would be white? It makes it invisible because it's over a white background. See attachment for more details. The text should read "hello world". Any ideas?
Ok, but it's just a new InputField. I just created it and hit build & run. I didn't modify the InputField whatsoever.
Which version of Unity are you using? It should be fixed in 5.3.2p4. If it is not - could be your manifest is misconfigured.
Did it work? We have the same problem with Unity 5.3.4 (p1) :-( Both the entered text and the OK button/text can be totally invisible (white, same as background) on some Android phones, and light gray, looks "disabled", on other phones. On iOS, it works fine.
I'm referencing the issue where the text typed by the user is white on white making it invisible. Not sure about the ok button. In regards to the white on white issue, I have fixed it. I did so by deleting the Android Manifest in Plugins/Android. I think it was the Facebook SDK that put at there and messed it up.
@_Daniel_ you may want to check the contents of the deleted manifest and merge it with Unity manifest if needed - this requires some knowledge about Android manifests though.
@Yury Habets Hi, we have the same issue in 5.3.4p2 Before we updated to this version of Unity, some devices were displaying black text on dark grey field. Now we have white text displayed on white field (reproduced on Nexus 7 Lollipop but not on Nexus 6P Marshmallow and Moto G KitKat). Changing to Unity sample manifest in PlaybackEngine folder to <style name="UnityThemeSelector" parent="android:Theme.Black.NoTitleBar.Fullscreen"> does not change anything. Meanwhile we have a custom manifest in Plugins/Android folder, do we need to add this theme directly in our Manifest? It could be nice to add documentation about it EDIT: We figured out it was that. Could be nice to tell somewhere that the theme will be f***** up by an AndroidManifest which doesn't specify a theme
So did you fix it by adding <style name="UnityThemeSelector" parent="android:Theme.Black.NoTitleBar.Fullscreen"> to every AndroidManifest?
Nope. If you go in your Plugins/Android folder, you may have an Android Manifest file. Open it, there you should see the <application> section at the 3rd or 4th line. It should look a lot like this <applicationandroid:icon="@drawable/app_icon"android:label="@String/app_name"android:debuggable="false"android:hardwareAccelerated="true"> Just add android:theme="@StyLe/UnityThemeSelector" after android:hardwareAccelerated="true" and it will solve the problem.
Yeah thank you @r.pedra for posting the correct solution. I've written a blog post about android themes about a year ago, but many things have changed since then. At least, by using style/UnityThemeSelector, you should be able to get featured without using the Support library or any other tricks.
I tried this but gave me an error : stderr[ AndroidManifest.xml:13: error: Error: No resource found that matches the given name (at 'theme' with value '@StyLe/UnityThemeSelector'). ]
I think UnityThemeSelector is available on recent versions of Unity, which version do you have? Maybe @Yury Habets could help you with that, as he wrote the original blogpost.
Ah... It should work... Can you go to Unity/PlaybackEngines/AndroidPlayer/Apk/res/values where Unity is the folder where you installed Unity.(This is Mac directory but it should be similar on Windows). You should have a strings.xml and a styles.xml Open styles.xml and tell us what is inside
<?xml version="1.0" encoding="utf-8"?> <resources> <style name="UnityThemeSelector" parent="android:Theme.Light.NoTitleBar.Fullscreen"> </style> </resources>
I made a mistake copy pasting the line like you said and didnt notice how the spellings got accidently changed.. Read the error gain and got it working after i changed android:theme="@StyLe/UnityThemeSelector" to android:theme="@style/UnityThemeSelector"... !! Sorry for the trouble.. nd thanks for helping out..
I'm also having same problem and tried the above changes, but did not help, the entire keyboard is not visible for us, but its taking clicks on the keyboard, we can see some random text getting applied on the label. Though when we try to close the keyboard it appears for a fraction of a second and then closes. Please help
Just wanted to follow up with this and mention the code should actually be Code (CSharp): android:theme="@style/UnityThemeSelector" as the casing is sensitive. Otherwise this worked fine for me after tweaking it!
Sorry guys for the typo, someone is called StyLe on the forum and the @ is linking to his profile. I tried to remove the link but it always come back.
The issues still appear in unity 5.4.4.p4, and adding android:theme="@StyLe/UnityThemeSelector" seems to not fix anything except it makes the build fail every time. Does anyone success with the fix above? How to fix it ? Many thanks.
You just need to write style instead of StyLe. Unity forum is thinking that the @ links to a user profile
Unity 5.6.0f3 My manifest file already contained the android:theme="@StyLe/UnityThemeSelector" line and still I am getting the white letters issue.Any update on that? It is actually style in the file, forum keeps changing it to the username
This has happened to me today. I'm using Unity 5.5.1f1, so I understand the fix should be applied in this version. I've inserted the android:theme code in the AndroidManifest.xml file and now it is working ok.
Many Thanks!!! In my case, after import firebase_unity_sdk_4.1.0 (FirebaseMessaging) using unity 5.5.2 same error, white text in the keyword. Adding android:theme="@style/UnityThemeSelector (with lowercase, letter S and letter L) solved this.
Here's my question... You all seem to only wanna focus on the developer... How can us poor users of some unity app which has not cared to fix this problem in development fix it on our android device (system wide if possible) so that we can see what we are doing when typing in our favorite games?
Thanks! We were also able to fix the issue by setting the android theme. We are using Unity 2021.3.6f1 and the issue was observed on devices using Android 6. Small note: We are using Unity Cloud Build and building the project without any other changes than setting the android theme resulted in a failure. /home/buildbot/.rvm/gems/ruby-2.4.2/gems/bvr-6.3.8.2.4.2/bin/bvr:69:in `exit': no implicit conversion from nil to integer (TypeError) I'm not sure whether this was caused directly by the AndroidManifest change, but issuing a Clean Build fixed the issue on UCB.