Yesterday, I downloaded a Project which was in eclipse and i imported it in my android studio may be due to this or some other reason today when i opened my android studio recent projects it was showing error in gradle file with some other language i searched for the error which was "File was Loaded in Wrong Encoding UTF-8 " and got a method to change from file
Please help me out what should i do i tried searching every where but could not get a fine result which worked for me.
Here is my sample code of .xml file which is don't know in which format and why
���� 3
0abc_background_cache_hint_selector_material_dark I
ConstantValue 1abc_background_cache_hint_selector_material_light (abc_btn_colored_borderless_text_material abc_btn_colored_text_material abc_color_highlight_material !abc_hint_foreground_material_dark "abc_hint_foreground_material_light !abc_input_method_navigation_guard +abc_primary_text_disable_only_material_dark ,abc_primary_text_disable_only_material_light abc_primary_text_material_dark
abc_primary_text_material_light abc_search_url_text abc_search_url_text_normal
abc_search_url_text_pressed abc_search_url_text_selected abc_secondary_text_material_dark !abc_secondary_text_material_light abc_tint_btn_checkable abc_tint_default abc_tint_edittext abc_tint_seek_thumb abc_tint_spinner abc_tint_switch_track accent_material_dark accent_material_light !background_floating_material_dark "background_floating_material_light background_material_dark background_material_light (bright_foreground_disabled_material_dark )bright_foreground_disabled_material_light 'bright_foreground_inverse_material_dark (bright_foreground_inverse_material_light ! bright_foreground_material_dark " bright_foreground_material_light # button_material_dark $ button_material_light % cardview_dark_background & cardview_light_background ' cardview_shadow_end_color ( cardview_shadow_start_color ) colorAccent * colorPrimary + colorPrimaryDark , %design_bottom_navigation_shadow_color - design_default_color_primary . !design_default_color_primary_dark / design_error 0 design_fab_shadow_end_color 1 design_fab_shadow_mid_color 2 design_fab_shadow_start_color 3 !design_fab_stroke_end_inner_color 4 !design_fab_stroke_end_outer_color 5 !design_fab_stroke_top_inner_color 6 !design_fab_stroke_top_outer_color 7
It was a Fine Working Projects and every thing was working but dnt know what happned tried to reset that was also not working
Searched Alot Tried to make Sdk Locations Update Updated Gradle due to which all my class files were back to normal form but this Xml File was Not re-formatted So At last i created a new Xml File.
But After Some search i come to a result that it might me due to Unwanted Closer of my Android Studio Or may be my battery drained due to which my Android Studio doesn't Closed Properly.
If Any One Know After Every update i can do one more thing so that i can re-arranged my xml file to original format I will Update My Answer if that Worked For me
Thank You.
Related
I'm just created .apk file with buildozer.But as i said in topic, can't see any icon on device.Everything works and looks fine in Linux. But in device,all icons are blank. This is my buildozer.init requirements: (my ndk,sdk,minapi,ndk_api values are default)
requirements = python3,kivy==1.11.1,https://github.com/kivymd/KivyMD/archive/master.zip
If i use kivymd==0.104.1, i can see icons in android but can't use some commands like : MDTab.get_tab_list() , MDTab.switch_tab() (I asked that problem before in here.So i have to use master branch version because i need to switch MDTabs after some button clicks.But now,i can't see any icon.Is that bug or can someone help me ? Thank you..
(Last note: Im removing .buildozer file before change requirements versions.)
Set correct dependencies in buildozer.spec- https://github.com/kivymd/KivyMD/commit/df73810cc725e4575c93bc4cbbb72f67ff568dc1
I have used google, read all Questions here on StackExchange but still couldnt solve my Problem.
So Im following a tutorial from kilobolt(Zombie Bird).
The desktop-version of the game is running without problems, but if I want to run it on an android emulator I get this error message:
"Couldn't load file: data/logo.png"
The line where I get the error looks like this:
logoTexture = new Texture(Gdx.files.internal("data/logo.png"));
My Android Path looks like this:
-Android
-Assets
-Data
-logo.png
I assume this is the correct path.
I have tried cleaning the project, I used Gradle > Refresh All, I restarted Eclipse.
Nothing worked.
Im a little bit confused cause if I move the file outside of Data but in the Assets Folder and change the path to this:
logoTexture = new Texture(Gdx.files.internal("logo.png"));
It works.
Can someone explain me why I cant use the Data Folder inside of Assets?
What emulator are you using to run it? For me, the same code works properly on an actual Android device, so I'd assume it is an Emulator error. Possibly has to do with the / as the seperator character. This is just a wild guess, but does
logoTexture = new Texture(Gdx.files.internal("data" + File.separator + "logo.png"));
fix it, or break it?
maybe it's caused by the difference of OpenGl ES 1 and OpenGl ES 2...
Using OpenGl ES 1 the picture size has the power of two. Bear with me - I'm new to libgdx.. :)
I implemented Android Bootstrap library:
https://github.com/Bearded-Hen/Android-Bootstrap
Everything works fine, but icons in buttons are not displayed.
I add font-awesome file into asset folder, but still without successful result.
How can be this solved?
Thanks for any help.
Try what it worked for me, make sure that "android-support-v4.jar" file in libs folder (assuming that you're working in eclipse) is the same copy in AndroidBootstrap library project and your project.
This might only partially solve your problem, you might have problems with the icon not displaying when you change orientation (landscape/portrait) and there might be better solution, but this is my quick fix:
in OnResume add:
if (getResources().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE){
bbYourButton1.setLeftIcon("fa-heart");
bbYourButton2.setRightIcon("fa-twitter");
}
If there is a problem loading the font, you should get the reason in the log cat, as we can see in com / beardedhen / androidbootstrap / BootstrapButton.java at line 343
Log.e("BootstrapButton", "Could not get typeface because " + e.getMessage());
So, go to the logcat and see if you can understand what happened.
Anyways, the better start point is to import the AndroidBootstrapTest project and see if everything works.
Just copy fontawesome-webfont.ttf into assets folder of your project.
i want to replicate ldap with Syncrepl and i follow http://www.openldap.org/doc/admin24/replication.html.
i get trouble when i start provider which get " line 79: extra cruft after .
slaptest: bad configuration file"
in log file.
Pls help to solve my problem?
The syncprov options "should appear after the overlay directive". That doesn't mean on the same line:
overlay syncprov
syncprov-checkpoint 100 10
syncprov-sessionlog 100
Works for me.
I'm having trouble getting Eclipse to see that I've just put a new image into my project when referencing that image using R.drawable.this_text
So I drag my png into myProject/res/drawable-hdpi in Eclipse's Project Explorer. The name of the image is this_text and it's a png!
So I go into my application and I want to put this on the screen; So here's the code for that...
private void setTitle()
{
ImageView title = new ImageView(this); //this extends activity
title.setBackgroundResource(R.drawable.this_text);
...
}
This I have done before and each time I do it I experience the same thing:
if i just dragged my this_text.png into the Project Explorer in eclipse, the word "this_text" will be underlined in red, and not allow me to compile or proceed. I try to F5 (refresh) the project. I try refreshing the image foldr, the src, the actual java...etc! I try closing and opening eclipse but nothing really works. So I quit for afew minutes and work elsewhere in my application, and eventually this error goes away!
Well I'm impatient today-- And I'd rather know how to solve this incase I need to do any quick programming! So does anyone know what to do?
I'm using eclipse Version: Indigo Service Release 1.
Thanks- Ethan
R files for android are generated. Rather than refreshing you should be able to CLEAN the project which should fix your issue. You could even just delete the error from the problems list which would allow for compilation to start and for the generated R file to be created. Or you could make a change to an xml which would also allow for the file to be regened. As always make sure you are up to date on your tool chain.