Erstellung eines Designs

ahhh okay :) danke für den Tipp
stimmt nach dem Neustart von eclipse ist es besser :)

noch eine weitere Frage: Wie kann ich eine Custom font einfügen ? Habe ein Tutorial befolgt und die font unter "assets/fonts" gespeichert, im scr-ordner habe ich eine Java-Datei angelegt mit dem namen wetter.java :
Code:
package com.example.fotooh;

import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.widget.TextView;

public class wetter extends Activity {

   @Override
   protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.wetter);
      TextView tx = (TextView)findViewById(R.id.my_text);
      Typeface myCustomFont = Typeface.createFromAsset(getAssets(),
      "fonts/gabriola.ttf");
      tx.setTypeface(myCustomFont);
   }

  
   }



die dazugehörige xml heißt: "kontakt_willkommen" mit dem Code:
Code:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/linearLayout1"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
     android:background="@drawable/background"
    android:orientation="vertical" >

    
    <EditText
        android:id="@+id/editTextTo"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
         android:background="#00FFFFFF"
        android:inputType="textEmailAddress" >

        <requestFocus />
    </EditText>
 

    <EditText
        android:id="@+id/editTextSubject"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
         android:background="#00FFFFFF"
         
         >
    </EditText>
    <EditText android:ems="10" android:id="@+id/Platzhalter" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="#00FFFFFF" android:gravity="top" android:inputType="textMultiLine" android:lines="7"/>

    <TextView
        android:id="@+id/my_text"
        android:layout_width="fill_parent"
        android:layout_height="match_parent"
        android:background="#B3000000"
        android:text="@string/Kontakt2"
        android:textColor="#FFFFFF" />

</LinearLayout>

Hast du eine Idee warum es noch nicht funktioniert ?
 

Ähnliche Themen

5
Antworten
0
Aufrufe
1.173
586920
5
R
Antworten
6
Aufrufe
1.021
swa00
swa00
W
Antworten
2
Aufrufe
750
rene3006
R
Zurück
Oben Unten