Pick a Color


Pick a color using a color picker dialog.

Applications should use startActivityForResult() to launch this color picker with a default color specified in the integer Intent extra "org.openintents.extra.COLOR". The chosen color will be returned in an Intent the same way.


public void startPickAColor(int color) {
    Intent intent = new Intent("org.openintents.action.PICK_COLOR"); 
    intent.putExtra("org.openintents.extra.COLOR", color); // int
    if (intent.resolveActivity(getPackageManager()) != null) { 
      startActivityForResult(intent, REQUEST_CODE);

protected void onActivityResult(int requestCode, int resultCode, Intent data) {
    if (requestCode == REQUEST_CODE && resultCode == RESULT_OK) { 
      int color = data.getIntExtra(org.openintents.extra.COLOR);
      // handle result

Example intent filter

<activity ...>
        <action android:name="org.openintents.action.PICK_COLOR" />
        <category android:name="android.intent.category.DEFAULT" />

Apps Providing an Implementation

Search on Github

Search on Google Play, AppBrain, Amazon App store or similar (not yet available - please make this happen!)

For Specification Writers

Edit on Github