change size of controls in a layout

by dillipk » Thu, 22 Apr 2010 03:32:36 GMT


Sponsored Links
 Hi,
  How do I change the size of the controls placed in a layout? (by any
method)

 I tried to change the height of an EditBox ->setHeight(10); doesn't
seem to work.

Thank you,

-DK

--



change size of controls in a layout

by social hub » Thu, 22 Apr 2010 03:46:09 GMT


 did u call requestLayout()
or invalidate()

if that doesnt work try below
textView.getLayoutParams().height = x;
requestLayout();
should work





>


Sponsored Links


change size of controls in a layout

by karteek » Thu, 22 Apr 2010 12:22:01 GMT


 If you declared EditText in xml file you can change by
<EditText android:layout_width="50px"
          android:layout_height="50px">
</EditText>
  where you can use any nuber instead of 50



>



change size of controls in a layout

by ~ TreKing » Thu, 22 Apr 2010 21:58:49 GMT


 



You should use "dp" to stay consistent across devices with different
resolutions, unless this is definitely what you want.

-------------------------------------------------------------------------------------------------
TreKing - Chicago transit tracking app for Android-powered devices
 http://sites.google.com/site/rezmobileapps/treking 

--



Other Threads

1. what is ORIENTATION_SQUARE ?

Dear all,

landscape, portrait, square.

public static final int ORIENTATION_LANDSCAPE
Since: API Level 1
Constant Value: 2 (0x00000002)
public static final int ORIENTATION_PORTRAIT
Since: API Level 1
Constant Value: 1 (0x00000001)
public static final int ORIENTATION_SQUARE


I can't imagine why square exist in the world? I never seen the phone
is a square screen, which height equal weight.

Can we necessary always to judge is it a square? If it exist, how can
we judge it's a landscape or portrait?

-- 

2. Butuh framework-res.apk untuk Gtab Sprint

As subject, ada yang punya battery meter-nya seperti di-attach? 
Kalau nggak keberatan boleh japri saya?

Terimakasih,
Agus

-- 
"

<<attachment: 255700.png>>

3. ViewHolder paradigm vs. using View.setTag()

4. DHD root failed

5. assets referenced in HTML

6. Navigation in a Help Screen

7. Paging Hendra Suntoro