Skip to content

Latest commit

 

History

History
18 lines (17 loc) · 595 Bytes

README.md

File metadata and controls

18 lines (17 loc) · 595 Bytes

TTextView

Custom Android TextView. Define custom typeface directly in XML.

Eliminate

TextView textView = (TextView) findViewById(R.id.textView1);
Typeface typeface = Typeface.createFromAsset(context.getAssets(), typefacePath);
textView.setTypeface(typeface);

Define typeface path (from assets folder) in XML with customTypeface attribute.

<agnamc.ci.library.TTextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="Atlantide Starlight"
        app:customTypeface="AtlantideStarlight.ttf"
        />