Color bar solution killed after defining sdk version in manifest

The reader can turn to this question: android: dither = "true" does not interfere, what's wrong?

I also had a color scheme ... The solution was to create an alias (in xml) with the parameter "true" for my png images with gradients. This worked until I specified the SDK version in the manifest file <uses-sdk android:minSdkVersion="4" android:targetSdkVersion="8" />...

Color bandage appeared on the emulator with Android 1.6 (API level 4) and the WVGA800 skin

Can anyone explain to me why !?

Project Files: https://rapidshare.com/files/3429393846/Dithering.zip

-

My layout and purpose against its background (aliasing alias):

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:background="@drawable/d_gradient_grey_dither">
<TextView  
    android:layout_width="fill_parent" 
    android:layout_height="wrap_content" 
    android:text="@string/hello"
    />
</LinearLayout>

Background (d_gradient_grey_dither.xml):

<?xml version="1.0" encoding="utf-8"?>
<bitmap
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:src="@drawable/d_gradient_grey"
    android:antialias="true"
    android:dither="true"/>

Manifest file:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="com.test"
      android:versionCode="1"
      android:versionName="1.0">


    <application android:icon="@drawable/icon" android:label="@string/app_name">
        <activity android:name=".Main"
                  android:label="@string/app_name">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

    </application>

    <uses-sdk android:minSdkVersion="4" android:targetSdkVersion="8" />

</manifest>

See the result here:

https://docs.google.com/document/d/1XNlR9DvXRvoyFYWVOe9wMARq0E60fkbrBy9ANADvPw4/edit?hl=fr&authkey=COvrv9EG

, :

https://docs.google.com/leaf?id=0B6Y0F7DEUPbPZTM5MDU0YzAtNjJiYi00NTU0LTlmNTAtMWJiZTJhNjBhYjA3&hl=fr

(zipped)

https://rapidshare.com/files/3429393846/Dithering.zip

+3
1

, , API 11.

/** -- Eliminates color banding -- **/

@Override
public void onAttachedToWindow() {
super.onAttachedToWindow();
Window window = getWindow();
window.setFormat(PixelFormat.RGBA_8888);
}
+3

All Articles