MaterialDesignLibrary icon indicating copy to clipboard operation
MaterialDesignLibrary copied to clipboard

Android Studio Preview Error

Open hanc1208 opened this issue 10 years ago • 5 comments

i got error in preview window while i am writing xml.

<com.gc.materialdesign.views.ButtonRectangle android:layout_width="113dp" android:layout_height="45dp" android:text="OK"/>

java.lang.NoSuchFieldError: shape_bacground at com.gc.materialdesign.views.Button.setBackgroundColor(Button.java:166) at com.gc.materialdesign.views.Button.setDefaultProperties(Button.java:50) at com.gc.materialdesign.views.ButtonRectangle.setDefaultProperties(ButtonRectangle.java:35) at com.gc.materialdesign.views.Button.(Button.java:36) at com.gc.materialdesign.views.ButtonRectangle.(ButtonRectangle.java:23)

hanc1208 avatar Feb 18 '15 15:02 hanc1208

Hmm well first it seems like you spelt "shape_bacground " incorrectly. Should be "shape_background

This could be the cause of the other errors.

CookieMaster avatar Feb 26 '15 03:02 CookieMaster

I haven't never made the drawable named "shape_bacground". I found "shape_bacground" in the library. (Button.java:166)

hanc1208 avatar Feb 26 '15 06:02 hanc1208

Hmm, can you add a picture of the error that comes from the console.

CookieMaster avatar Feb 26 '15 22:02 CookieMaster

image

        <com.gc.materialdesign.views.ProgressBarDeterminate
            android:layout_width="match_parent"
            android:layout_height="wrap_content"


            android:background="@color/primary"
            android:progress="10"/>

hanc1208 avatar Mar 01 '15 11:03 hanc1208

same issue

hadidez avatar Dec 24 '16 06:12 hadidez