2016-05-13 6 views
1

Hallo Ich habe diese einfache Aktivität mit vielen Texte bearbeiten, aber es sieht schlecht aus. Ich möchte einige Farben, Stile Hintergrund hinzufügen und EditText bewegen, um diese Seite attraktiv machen zu wissen, dass die Farben in meiner Anwendung verwendet werden, sind orange und blau Dank im VorausWie kann ich eine attraktive Schnittstelle Android machen

<?xml version="1.0" encoding="utf-8"?> 
<ScrollView 
    android:layout_width="match_parent" 
    android:layout_height="match_parent" 
    android:id="@+id/scrollView" 
    xmlns:android="http://schemas.android.com/apk/res/android" > 
    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
     android:orientation="vertical" android:layout_width="match_parent" 
     android:layout_height="match_parent"> 
     <TextView 
      android:layout_width="wrap_content" 
      android:layout_height="wrap_content" 
      android:text="Référence" 
      android:textColor="@color/colorPrimary" 
      android:layout_marginTop="70dp"/> 

     <TextView 
      android:layout_width="match_parent" 
      android:layout_height="wrap_content" 
      android:enabled="false" 
      android:id="@+id/editRef" /> 

     <TextView 
      android:layout_width="wrap_content" 
      android:layout_height="wrap_content" 
      android:textColor="@color/colorPrimary" 
      android:text="Nom" /> 

     <TextView 
      android:layout_width="match_parent" 
      android:layout_height="wrap_content" 
      android:id="@+id/editName" /> 

     <TextView 
      android:layout_width="wrap_content" 
      android:layout_height="wrap_content" 
      android:textColor="@color/colorPrimary" 
      android:text="Description" /> 

     <TextView 
      android:layout_width="match_parent" 
      android:layout_height="wrap_content" 
      android:id="@+id/editDesc" /> 

     <TextView 
      android:layout_width="wrap_content" 
      android:layout_height="wrap_content" 
      android:textColor="@color/colorPrimary" 
      android:text="Quantité" /> 

     <TextView 
      android:layout_width="match_parent" 
      android:layout_height="wrap_content" 
      android:id="@+id/editQt" /> 
     <TextView 
      android:layout_width="wrap_content" 
      android:layout_height="wrap_content" 
      android:textColor="@color/colorPrimary" 
      android:text="Prix" /> 

     <TextView 
      android:layout_width="match_parent" 
      android:layout_height="wrap_content" 
      android:id="@+id/editprix" /> 

    </LinearLayout> 
</ScrollView> 

This is my interface ich eine Schnittstelle wie diese haben wollen zum Beispiel oder attraktiver und organisiert This is my image

+0

verwenden für Design hier https://www.google.com/design/spec /style/color.html#color-color-schemes –

+0

danke Gibt es eine Android-Vorlage? –

Antwort

1

Sie HTML auf Textview wie folgt verwenden können:

myTextView.setText(Html.fromHtml("<h2>Title</h2><br><p>Description here</p>")); 

und Ihre Aktivitäten einige Textview, nicht EditText

+1

Warum in der Welt würden Sie verwenden HTML für das Styling einer Android-App –

+0

Ich habe bereits Android: textColor = "@ color/colorPrimary" aber meine Schnittstelle immer noch schlecht. Die Disposition von Textview ist schlecht. Ich möchte sie in der Schnittstelle platzieren und Stile hinzufügen, um eine schöne Schnittstelle zu machen –

0

Für Farbeinstellung können Sie verwenden

String text = "<font color=#cc0029>Erste Farbe</font> <font color=#ffcc00>zweite Farbe</font>"; 
yourtextview.setText(Html.fromHtml(text)); 

Für Arten und Hintergrund styles

+0

Ich habe bereits Android: textColor = "@ color/colorPrimary" aber meine Schnittstelle immer noch schlecht. Die Disposition von Textview ist schlecht. Ich möchte sie in der Schnittstelle platzieren und Stile hinzufügen, um eine schöne Schnittstelle –

+0

Sie können ein Beispiel geben, wie es aussehen sollte. –

+0

Ich habe keine klare Idee, aber ich möchte eine Schnittstelle wie das Bild in meinem ersten Beitrag zum Beispiel hinzugefügt haben. Ich habe es aktualisiert –

Verwandte Themen