Sylvester Steele wrote:
> the EditText setHeight and setWidth functions have no effect on the
> display. Any Reason? This EditText object is not in the XML file.
> 
> my code:
> 
> EditText getNumber= new EditText(this);
>         getNumber.setHeight(240);
> 
>         this.setContentView (getNumber);
> 
> 
> The EditText object still occupies the full screen.

It may be that the content view always behaves as if layout_width and 
layout_height are fill_parent. Try putting your EditText inside a 
LinearLayout, setting layout_height and layout_width to your desired 
values, and see if that helps.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com
Android Training on the Ranch in September! http://www.bignerdranch.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
Announcing the new M5 SDK!
http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to