大约有 3,614 项符合查询结果(耗时:0.0250秒) [XML]

https://stackoverflow.com/ques... 

How do I solve the INSTALL_FAILED_DEXOPT error?

I am developing an Android application using Android 2.2, my application APK size is 22.5 MB, and I would like to create a new build for a Samsung tablet. I got the following error: ...
https://stackoverflow.com/ques... 

how to get android screen size programmatically, once and for all?

...nswered Jul 5 '13 at 5:11 Preet_AndroidPreet_Android 2,30744 gold badges2222 silver badges4343 bronze badges ...
https://stackoverflow.com/ques... 

how to make a specific text on TextView BOLD

...API 24 , you have to use next code : Spanned durationSpanned; if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.N) { durationSpanned = Html.fromHtml(durationFormatted,Html.FROM_HTML_MODE_LEGACY); } else { durationSpanned = Html.fromHtml(duration...
https://stackoverflow.com/ques... 

List View Filter Android

I have created a list view in android and I want to add edit text above the list and when the user enter text the list will be filtered according to user input ...
https://stackoverflow.com/ques... 

Android - how do I investigate an ANR?

...ce in the "main" thread. This is the event loop thread, and if it is busy, Android cannot process any further GUI events in the application, and thus throws up an ANR dialog. Now, in the trace you posted, the main thread seems to be doing fine, there is no problem. It is idling in the MessageQueue,...
https://stackoverflow.com/ques... 

Check if application is installed - Android

...69 Note: This will not work in some virtual spaces. They can violate the Android API and always return an array, even if there is no application with that package name. In this case, use getPackageInfo. share | ...
https://stackoverflow.com/ques... 

How to set margin of ImageView using code, not xml

... android.view.ViewGroup.MarginLayoutParams has a method setMargins(left, top, right, bottom). Direct subclasses are: FrameLayout.LayoutParams, LinearLayout.LayoutParams and RelativeLayout.LayoutParams. Using e.g. LinearLayout...
https://stackoverflow.com/ques... 

Disable ScrollView Programmatically?

...to do with the ScrollView, you can change how an ImageView scales with the android:scaleType property (XML) or the setScaleType method - for instance ScaleType.CENTER will not stretch your image and will center it at it's original size You could modify ScrollView as follows to disable scrolling ...
https://stackoverflow.com/ques... 

Dialog to pick image from gallery or from camera

...rom gallery: Intent pickPhoto = new Intent(Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI); startActivityForResult(pickPhoto , 1);//one can be replaced with any action code onActivityResult code: protected void onActivityResult(int requestCode, int r...
https://stackoverflow.com/ques... 

JSON Array iteration in Android/Java

I am building an android app that needs to download and synchronise with an online database, I am sending my query from the app to a php page which returns the relevant rows from a database in JSON format. ...