Hi,

I apologize if this turns out to be a trivial answer but I've been
searching a solution for this the past few hours but haven't had much
luck.  I have a TextView inside a layout with a specific font and
text
size.  The issue that I'm having is when I have a text that has
characters like p, q, g, etc (basically letters that have "straddles"
down the margin).  In my text view, those characters are always
getting cut-off and I'm not sure what I"m doing wrong.


Here's what my layout looks like.  Note that the text sizes are fixed
(per specification in the work I'm doing) so that's not something I
can change easily.  In the Eclipse layout editor it looks fine, but
when I run it on the emulator the characters are getting cut-off.
The
text region I'm specifically referring to is the second <TextView>
element.  Also note that I purposely set the background color so its
evident where the TextView margins are.  Ideally, if I can avoid
using
arbitrary paddings on the text regions, that would be preferable
(unless there's no other way).  I'm assuming this is a standard issue
and hoping that I wouldn't need padding on the bottom to fix this:


           <RelativeLayout
                android:id="@+id/name_and_email"
                android:layout_width="230.7dip"
                android:layout_height="wrap_content"
                android:orientation="vertical">
                <TextView
                    android:id="@+id/name"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:textColor="@color/custom_text_color"
                    android:textSize="18.6sp"
                    android:singleLine="true"
                    android:ellipsize="end"
                    android:layout_centerInParent="true"
                    android:layout_alignParentTop="true"
                    android:background="#ff000d"
                    android:text="Your Name Here" />
                <TextView
                    android:id="@+id/email"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:textColor="@color/custom_text_color"
                    android:textSize="14.6sp"
                    android:singleLine="true"
                    android:ellipsize="end"
                    android:layout_below="@id/title"
                    android:layout_centerInParent="true"
                    android:layout_alignParentBottom="false"
                    android:background="#00ff00"
                    android:gravity="center"
                    android:text="[email protected]" />
            </RelativeLayout>


Can anyone see what I"m doing wrong?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to