fffy2366 / android-query

Automatically exported from code.google.com/p/android-query
0 stars 0 forks source link

Request: Typeface #45

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago

I need use typeface with my TextView, anything like
aq.id().typeFace("myFont.ttf"); would be great :-)

Original issue reported on code.google.com by julien.quievreux on 2 May 2012 at 2:20

GoogleCodeExporter commented 8 years ago

Original comment by tinyeeliu@gmail.com on 2 May 2012 at 6:31

GoogleCodeExporter commented 8 years ago
this code work with a good path:

    public T typeface(String typeface){

        if(view != null){
            Context context = getContext();
            ((TextView) view).setTypeface(Typeface.createFromAsset(context.getAssets(), typeface));
        }
        return self();
    }

Original comment by julien.quievreux on 10 May 2012 at 2:34

GoogleCodeExporter commented 8 years ago

Original comment by tinyeeliu@gmail.com on 13 Jul 2012 at 7:43