Missing styles. Is the correct theme chosen for this layout? Use the Theme combobox above the layout to choose a different layout, or fix the theme style references. Potential trying to resolve
'?attr/textColorHighlight'
: cyclic resource definitions? Render may not be accurate. (16 similar errors not shown) Failed to find'?attr/textColorHighlight'
in current theme. (16 similar errors not shown) The graphics preview in the layout editor may not be accurate: -Paint.setShadowLayer
is not supported. (Ignore for this session)レンダリングの問題行方不明のスタイル
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent"
>
<RelativeLayout
android:id="@+id/qwe"
android:layout_width="match_parent"
android:layout_height="50dp"
android:background="#34b233"
android:orientation="horizontal">
<Button
android:id="@+id/buttonmnu"
android:layout_width="40dp"
android:layout_height="40dp"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"
android:layout_marginRight="5dp"
android:layout_centerVertical="true"
android:background="@drawable/homeicon" />
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:text="Contact Exhibitor"
android:textColor="#fff"
android:textSize="7pt" />
</RelativeLayout>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:id="@+id/buttons"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_marginBottom="10dp"
android:gravity="center"
android:orientation="vertical">
<Button
android:id="@+id/buttonsubmit"
android:layout_width="150dp"
android:layout_height="40dp"
android:layout_centerHorizontal="true"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:background="@drawable/button_round"
android:text="Submit"
android:textColor="#fff"
android:textSize="5pt"
/>
</LinearLayout>
<ScrollView
android:id="@+id/scrollView1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@id/buttons"
android:layout_marginBottom="10dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="40dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="15dp"
android:orientation="vertical">
<android.support.design.widget.TextInputLayout
android:id="@+id/text1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/editText1"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="Name*"
android:maxLength="50"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/text2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/editText2"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="Designation*"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/text3"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/editText3"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="Company Name*"
android:maxLength="30"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/text4"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/editText4"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="Phone Number*"
android:inputType="number"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/text5"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/editText5"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="E-mail address*"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/text6"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/editText6"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="Main activity of your company*"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/text10"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="5dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/edit10"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="P.O.Box*"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<android.support.design.widget.TextInputLayout
android:id="@+id/text12"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"
android:layout_marginTop="10dp"
android:divider="#535353"
android:theme="@style/TextLabel">
<EditText
android:id="@+id/edit12"
android:layout_width="match_parent"
android:layout_height="30dp"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:background="@null"
android:gravity="left"
android:hint="City"
android:textColor="#000"
android:textSize="7pt"
/>
<ImageView
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="#535353" />
</android.support.design.widget.TextInputLayout>
<TextView
android:id="@+id/text11"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="4dp"
android:layout_marginTop="25dp"
android:text="Country*"
android:textColor="#000"
android:textSize="6pt" />
<Spinner
android:id="@+id/edit11"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:entries="@array/country_arrays"
android:gravity="center"
android:popupBackground="#fff"
android:spinnerMode="dropdown"
android:textSize="6pt"
/>
<TextView
android:id="@+id/text7"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/text2"
android:layout_alignParentTop="true"
android:layout_marginLeft="4dp"
android:layout_marginTop="25dp"
android:text="Sector1"
android:textColor="#000"
android:textSize="6pt" />
<Spinner
android:id="@+id/spinner1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:gravity="center"
android:popupBackground="#fff"
android:prompt="@string/spinner1"
android:spinnerMode="dropdown"
android:textSize="7pt"
android:theme="@style/TextAppearanceSpinnerItem"
/>
<TextView
android:id="@+id/text8"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/text2"
android:layout_alignParentTop="true"
android:layout_marginLeft="4dp"
android:layout_marginTop="25dp"
android:text="Exhibitor1"
android:textColor="#000"
android:textSize="6pt" />
<Spinner
android:id="@+id/spinnerExhibitor1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/text4"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:gravity="center"
android:popupBackground="#fff"
android:prompt="@string/spinner1"
android:spinnerMode="dropdown"
android:textColor="#000"
android:textSize="7pt"
android:theme="@style/TextAppearanceSpinnerItem" />
<TextView
android:id="@+id/text00"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/text2"
android:layout_alignParentTop="true"
android:layout_marginLeft="4dp"
android:layout_marginTop="25dp"
android:text="Sector2"
android:textColor="#000"
android:textSize="6pt" />
<Spinner
android:id="@+id/spinner2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_marginLeft="10dp"
android:entries="@array/About_arrays"
android:gravity="center"
android:popupBackground="#fff"
android:prompt="@string/spinner1"
android:spinnerMode="dropdown"
android:textSize="7pt"
android:theme="@style/TextAppearanceSpinnerItem" />
<TextView
android:id="@+id/text9"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/text2"
android:layout_alignParentTop="true"
android:layout_marginLeft="4dp"
android:layout_marginTop="25dp"
android:text="Exhibitor2"
android:textColor="#000"
android:textSize="6pt" />
<Spinner
android:id="@+id/spinnerExhibitor2"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/text4"
android:layout_centerHorizontal="true"
android:layout_marginBottom="10dp"
android:layout_marginLeft="10dp"
android:entries="@array/About_arrays"
android:gravity="center"
android:popupBackground="#fff"
android:prompt="@string/spinner1"
android:spinnerMode="dropdown"
android:textColor="#000"
android:textSize="7pt"
android:theme="@style/TextAppearanceSpinnerItem" />
</LinearLayout>
</ScrollView>
</RelativeLayout>
これはのstyles.xmlの関連する部分である:ここでは
がビルドです:<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Base.Theme.AppCompat.Light.DarkActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>
<style name="AppTheme.AppBarOverlay" parent="Base.ThemeOverlay.AppCompat.Dark.ActionBar">
<item name="android:textColorPrimary">@color/caldroid_lighter_gray</item>
<item name="android:textColorSecondary">@color/colorAccent</item>
</style>
<style name="AppTheme.PopupOverlay" parent="Base.ThemeOverlay.AppCompat.Light">
<item name="android:colorBackground">@color/colorAccent</item>
<item name="android:textColor">@color/colorAccent</item>
</style>
<style name="TextLabel" parent="Base.TextAppearance.AppCompat">
<!-- Hint color and label color in FALSE state -->
<item name="android:textColorHint">#535353</item>
<item name="android:textSize">7pt</item>
<!-- Label color in TRUE state and bar color FALSE and TRUE State -->
<item name="colorAccent">#535353</item>
<item name="colorControlNormal">#535353</item>
<item name="colorControlActivated">#535353</item>
</style>
<style name="TextAppearanceSpinnerItem" parent="android:TextAppearance.Widget.TextView.SpinnerItem">
<item name="android:textColor">#000</item>
</style>
<style name="AppTheme.NoActionBar">
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
</style>
<style name="MyEditTextTheme">
<!-- Used for the bottom line when not selected/focused -->
<item name="colorControlNormal">#d4d4d4</item>
<!-- colorControlActivated & colorControlHighlight use the colorAccent color by default -->
</style>
</resources>
そして、これは誤りです。 gradle(モジュール:app)ファイル
0123ここはbuild.gradle(プロジェクト)
buildscript {
repositories {
jcenter()
maven { url "https://jitpack.io" }
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.0'
classpath "io.realm:realm-gradle-plugin:1.0.1"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
レイアウトエディタのダウングレードでは23から21にない作品ならば、私は21にダウングレードすると問題 – piotrek1543
がどこにあるかチェックするために、ここで 'build.gradle'ファイルを追加し、それは言います"R埋め込みの問題レイアウトエディタのグラフィックプレビューが正確でない可能性があります: - Paint.setShadowLayerはサポートされていません " –
同じ問題です... build.gradleファイルを追加してください – piotrek1543