2016-03-27 2 views
0

Pourquoi des problèmes de rendu apparaissent-ils dans Android Studio?

<?xml version="1.0" encoding="utf-8"?> 
 
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" 
 
    xmlns:app="http://schemas.android.com/apk/res-auto" 
 
    xmlns:tools="http://schemas.android.com/tools" 
 
    android:layout_width="match_parent" 
 
    android:layout_height="match_parent" 
 
    android:fitsSystemWindows="true" 
 
    tools:context="com.yossikally.hello.MainActivity"> 
 

 
    <android.support.design.widget.AppBarLayout 
 
     android:layout_width="match_parent" 
 
     android:layout_height="wrap_content" 
 
     android:theme="@style/AppTheme.AppBarOverlay"> 
 

 
     <android.support.v7.widget.Toolbar 
 
      android:id="@+id/toolbar" 
 
      android:layout_width="match_parent" 
 
      android:layout_height="?attr/actionBarSize" 
 
      android:background="?attr/colorPrimary" 
 
      app:popupTheme="@style/AppTheme.PopupOverlay" /> 
 

 
    </android.support.design.widget.AppBarLayout> 
 

 
    <include layout="@layout/content_main" /> 
 

 
    <!--<android.support.design.widget.FloatingActionButton--> 
 
     <!--android:id="@+id/fab"--> 
 
     <!--android:layout_width="wrap_content"--> 
 
     <!--android:layout_height="wrap_content"--> 
 
     <!--android:layout_gravity="bottom|end"--> 
 
     <!--android:layout_margin="@dimen/fab_margin"--> 
 
     <!--android:src="@android:drawable/ic_dialog_email" />--> 
 

 
</android.support.design.widget.CoordinatorLayout>

J'ai construit le plus simple bonjour projet mondial. Dans la fenêtre de conception de xml, j'ai ce qu'il y a dans l'image enter image description here

J'ai essayé de changer de thème et de changer de version. Obtenez le même

+0

s'il vous plaît montrer votre fichier xml –

+0

whixh xml s'il vous plaît – jkally

+0

celui où vous avez CoordinatorLayout –

Répondre

0

s'il vous plaît ajouter à votre fichier App gradle Android Design Support Library:

compile 'com.android.support:design:23.+' 
+0

acceptées, mais pas tout à fait pleine. L'original 23.2.0 est bon. doit être changé en 23.1.1, aussi seulement ceux qui fonctionne est "NoActionBar", tout autre thème - par exemple. Holo donnera une pleine page d'avertissement quant aux problèmes de rendu. – jkally