I am using Google notifications in my app, and until now I have done below in the manifest: <!-- GCM --> <uses-permission android:name="android.permission.GET_ACCOUNTS" /> <!-- GCM requires a Google...
I’m trying to show an almost fullscreen DialogFragment. But I’m somehow not able to do so. The way I am showing the Fragment is straight from the android developer...
I’m trying to set the background color of a View (in this case a Button). I use this code: // set the background to green v.setBackgroundColor(0x0000FF00 ); v.invalidate(); It...
Just wondering if anyone has tried using new Java 7 language features with Android? I know that Android reads the bytecode that Java spits out and turns it to...
I am confused about the difference between LinearLayout, RelativeLayout, and AbsoluteLayout. Could someone please tell me the exact differences between them? 5 Answers 5
I am developing a simple Android application. But when I run Eclipse, it shows the following error: Your project contains error(s), please fix it before running it. I can’t...
This question already has answers here: Android app won’t build — The minCompileSdk (31) specified in a dependency’s androidx.work:work-runtime:2.7.0-beta01 (26 answers) Closed 8 months ago. The community reviewed whether...
I’m trying to create a custom view GhostSurfaceCameraView that extends SurfaceView. Here’s my class definition file GhostSurfaceCameraView.java: public class GhostSurfaceCameraView extends SurfaceView implements SurfaceHolder.Callback { SurfaceHolder mHolder; Camera mCamera;...
I am wondering how to add shadow on text in android? I have the following code which is applied on a bitmap and I wanted to be shadowed… paint.setColor(Color.BLACK);...
I’m trying to change the color on a white marker image by code. I have read that the code below should change the color, but my marker remains white....

