Tag Archives: color

1,263 views

NumberFormatException Color value drawable must start with

NumberFormatException Color value drawable must start with NumberFormatException: Color value ‘@drawable/my_picture’ must start with # Check all colors tags if value start with# Read this and check path c:\Users\me\AndroidStudioProjects\myProject\myModule\build\intermediates\res\merged\debug\ values folder for corupted values or delete ALL values folders or … Continue reading

Posted in Android Studio, Bugs, warnings, errors | Tagged , | Comments Off on NumberFormatException Color value drawable must start with
5,456 views

Get the color of a specific pixel Java Android example

ImputStream is = this.getResources().openRawResource(R.drawable.colors); Bitmap mBitmap2 = BitmapFactory.decodeStream(is);   int w = mBitmap2.getWidth(); int h = mBitmap2.getHeight(); // int x , y have to be smaller as w , h int _color = mBitmap2.getPixel(x, y);

Posted in Android Examples Code, Bitmap, drawing | Tagged , , , | Comments Off on Get the color of a specific pixel Java Android example
14,280 views

Change TableRow background color if on row click Android example

Change table row background color if user click on row Android example code. MainActivity.java public class MainActivity extends Activity { Boolean bColorYellow = true; TextView hTextView; TableRow hTableRow; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); hTextView = (TextView)findViewById(R.id.idTextView); hTableRow … Continue reading

Posted in Android Examples Code | Tagged , , , , , | Comments Off on Change TableRow background color if on row click Android example
18,149 views

Change background color dynamically View TableRow setBackgroundColor Android example

How change background color of View Android sample. MainActivity.java public class MainActivity extends Activity { TextView hTextView; TableRow hTableRow; Button hButton, hButtonStop; private Handler mHandler = new Handler(); private int nCounter = 0; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); … Continue reading

Posted in Android Examples Code | Tagged , , , , , , | Comments Off on Change background color dynamically View TableRow setBackgroundColor Android example
7,761 views

How setup color coloring syntax code highlight highlighting in Eclipse editor Android example

How setup color coloring highlight highlighting syntax font size and family in Eclipse Java and XML editor Android example Java editor Go to Eclipse menu Window -> Preferences Doubleclick on Java Double click on Editor Select Java, Javadocs or Comments … Continue reading

Posted in Android Examples Code, Eclipse | Tagged , , , , , , , | Comments Off on How setup color coloring syntax code highlight highlighting in Eclipse editor Android example