[android-developers] Re: How can we do TextView Justification

2009-12-04 Thread UD
Hi, Try using WebView instead of TextView. U can add text justification with help of CSS. -- Regards, Udayan Warnekar On Dec 3, 5:36 pm, Archana archana.14n...@gmail.com wrote: Please see this link ..here they are aligning the text i want same like this Check Full Text Search

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Dexter#39;s Brain
Hi Archana, This does work. Specify gravity as whatever, but If you don't specify the width of the text-view as fill_parent instead of wrap_content, the gravity property is meaningless. So, first set the width as fill_parent, for horizontal gravity props, and height as fill_parent for vertical

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Archana
I tried by giving both fill parent and and some value..But right side of the text is not justified.Can you pleas give some example if you have. On Dec 3, 2:11 pm, Dexter#39;s Brain coomar@gmail.com wrote: Hi Archana, This does work. Specify gravity as whatever, but If you don't specify

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Dexter#39;s Brain
If you can paste your code, I might be able to point out the error. RelativeLayout android:id=@+id/RelativeLayout01 android:layout_width=fill_parent xmlns:android=http:// schemas.android.com/apk/res/android android:layout_height=wrap_content TextView

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Archana
Actually i am using java not xml Like this i tried LinearLayout Contentlayout = new LinearLayout(context); Contentlayout.setLayoutParams(new LinearLayout.LayoutParams( LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT)); Contentlayout.setOrientation(HORIZONTAL);

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Dexter#39;s Brain
I guess, you haven't set the Gravity text1.setGravity(Gravity.RIGHT) This should work. Btw, any specific reason of not using xml? AFAIK they are a lot better to manage, and after you get a hand, easier to implement also. You can also get nice previews for your layout, before even running your

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Archana
No i set gravity to right but at that time everything is moving to right side. I want to align it from both left and right side. On Dec 3, 5:20 pm, Dexter#39;s Brain coomar@gmail.com wrote: I guess, you haven't set the Gravity text1.setGravity(Gravity.RIGHT) This should work. Btw, any

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Archana
ya i want it to be in java,Becoz i am fetching some content from server and itrating so if i use xml it wont display content properly.But now everything coming fine except justification. On Dec 3, 5:26 pm, Archana archana.14n...@gmail.com wrote: No i set gravity to right but at that time

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Dexter#39;s Brain
Sorry, but I don't get what you want to achieve GRAVITY.CENTER ? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Archana
Please see this link ..here they are aligning the text i want same like this Check Full Text Search http://www.aldiko.com/blog/ On Dec 3, 5:32 pm, Dexter#39;s Brain coomar@gmail.com wrote: Sorry, but I don't get what you want to achieve GRAVITY.CENTER ? -- You received this

[android-developers] Re: How can we do TextView Justification

2009-12-03 Thread Dexter#39;s Brain
Hmm...I got it now. I am not sure if you can do it. Sorry. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to

[android-developers] Re: How can we do TextView Justification

2009-12-02 Thread Archana
ya i tried in this way..But here textcontent coming to center.I want to justify from left and right side On Dec 3, 11:07 am, Desu Vinod Kumar vinny.s...@gmail.com wrote: hi r u tried like this android:layout_gravity=*center_vertical|center_horizontal * On Thu, Dec 3, 2009 at 11:32 AM,