Esempio n. 1
0
        public void SetDoneTextTypeface(string typeURL)
        {
            TextView doneText = (TextView)FindViewById(Resource.Id.done);

            if (CustomFontCache.Get(typeURL, this) != null)
            {
                doneText.Typeface = CustomFontCache.Get(typeURL, this);
            }
        }
Esempio n. 2
0
        public void SetSkipTextTypeface(string typeURL)
        {
            TextView skipText = (TextView)FindViewById(Resource.Id.skip);

            if (CustomFontCache.Get(typeURL, this) != null)
            {
                skipText.Typeface = CustomFontCache.Get(typeURL, this);
            }
        }
        public override View OnCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
        {
            View      v = inflater.Inflate(LayoutId, container, false);
            TextView  t = (TextView)v.FindViewById(Resource.Id.title);
            TextView  d = (TextView)v.FindViewById(Resource.Id.description);
            ImageView i = (ImageView)v.FindViewById(Resource.Id.image);

            mainLayout = (LinearLayout)v.FindViewById(Resource.Id.main);

            t.Text = title;
            if (titleColor != 0)
            {
                t.SetTextColor(new Color(titleColor));
            }
            if (titleTypeface != null)
            {
                if (CustomFontCache.Get(titleTypeface, Context) != null)
                {
                    t.Typeface = CustomFontCache.Get(titleTypeface, Context);
                }
            }
            d.Text = description;
            if (descColor != 0)
            {
                d.SetTextColor(new Color(descColor));
            }
            if (descTypeface != null)
            {
                if (CustomFontCache.Get(descTypeface, Context) != null)
                {
                    d.Typeface = CustomFontCache.Get(descTypeface, Context);
                }
            }
            i.SetImageResource(drawable);
            mainLayout.SetBackgroundColor(new Color(bgColor));

            return(v);
        }