[android-developers] Re: Making 2 buttons the same size

2011-01-11 Thread mort
On Mon, Jan 10, 2011 at 7:01 PM, John Lussmyer johnlussm...@gmail.comwrote: Is there any way to do that via settings in the XML? Give them both the same weight. Sadly, this also works only for short texts like OK and Cancel. If you need word wrap or a word's too long, the layout is messed

Re: [android-developers] Re: Making 2 buttons the same size

2011-01-11 Thread venkat kumar
Hi, Both buttons - Layoutweight give as 1. It shares equal size of both buttons. It wont consider the text size. Regards venky On Tue, Jan 11, 2011 at 1:44 PM, mort m...@sto-helit.de wrote: On Mon, Jan 10, 2011 at 7:01 PM, John Lussmyer johnlussm...@gmail.com wrote: Is there any way

Re: [android-developers] Re: Making 2 buttons the same size

2011-01-11 Thread Kostya Vasilyev
11.01.2011 11:14, mort пишет: There doesn't seem to be any simple, reliable, always working way to get buttons use exactly the given percentage of the available space. This works for me: a LinearLayout with two children (let's call them left/right). Set both children's width to 0dp and

[android-developers] Re: Making 2 buttons the same size

2011-01-10 Thread Zsolt Vasvari
Is there any way to do this in a RelativeLayout? I don't think so. Or I could probably add a LinearLayout that contains the row the buttons are in... Yes, sometimes you are forced to use a LinearLayout. -- You received this message because you are subscribed to the Google Groups Android