private void InitComponent() { try { OptionLinerLayout = FindViewById <LinearLayout>(Resource.Id.OptionLinerLayout); UpgradeButton = FindViewById <Button>(Resource.Id.UpgradeButton); HeadText = FindViewById <TextView>(Resource.Id.headText); PriceText = FindViewById <TextView>(Resource.Id.priceTextView); MainLayout = FindViewById <LinearLayout>(Resource.Id.mainLayout); RelativeLayout = FindViewById <RelativeLayout>(Resource.Id.relativeLayout1); HeadText.Text = GetText(Resource.String.Lbl_Title_Pro1) + " " + AppSettings.ApplicationName + " " + GetText(Resource.String.Lbl_Title_Pro2); if (AppSettings.SetTabDarkTheme) { MainLayout.SetBackgroundResource(Resource.Drawable.ShadowLinerLayoutDark); RelativeLayout.SetBackgroundResource(Resource.Drawable.price_gopro_item_style_dark); } var list = ListUtils.SettingsSiteList.FirstOrDefault(); if (list != null) { PriceText.Text = list.ProPrice + list.CurrencySymbol; } Typeface font = Typeface.CreateFromAsset(Application.Context.Resources.Assets, "ionicons.ttf"); string name = "go_pro_array"; int? resourceId = Resources.GetIdentifier(name, "array", ApplicationInfo.PackageName); if (resourceId == 0) { return; } string[] planArray = Resources.GetStringArray(resourceId.Value); if (planArray != null) { foreach (string options in planArray) { if (!string.IsNullOrEmpty(options)) { TextView text = new TextView(this) { Text = options, TextSize = 13 }; text.SetTextColor(AppSettings.SetTabDarkTheme ? Color.White : Color.ParseColor("#444444")); text.Gravity = GravityFlags.CenterHorizontal; text.SetTypeface(font, TypefaceStyle.Normal); TextDecorator.Content = options; TextDecorator.DecoratedContent = new Android.Text.SpannableString(options); TextDecorator.SetTextColor(IonIconsFonts.Checkmark, "#43a735"); TextDecorator.SetTextColor(IonIconsFonts.Close, "#e13c4c"); LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MatchParent, ViewGroup.LayoutParams.WrapContent);//height and width are inpixel layoutParams.SetMargins(0, 30, 0, 5); text.LayoutParameters = layoutParams; OptionLinerLayout.AddView(text); TextDecorator.Build(text, TextDecorator.DecoratedContent); } } } } catch (Exception e) { Console.WriteLine(e); } }