In Xamarin.Android, I have used TextView with the LayoutParameter as WrapContent. But the text is not aligned to vertically center for the textView and additional space is always remains between the textview’s top and the text.
TextView textView = new TextView(this);
textView.LayoutParameters = new ViewGroup.LayoutParams(ViewGroup.LayoutParams.WrapContent, ViewGroup.LayoutParams.WrapContent);
textView.Text = "Rejected";
textView.TextSize = 12;
How to avoid the additional space at the top in text view or else how to align the text at vertically center when setting the LayoutParameters as WrapContent( I have tried by setting the Gravity as Center for TextView. But it does not work out in this case)