Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Help identify the layout used here?

I'm working on a layout that comprises some of the same features seen in the screenshot below, but I'm running into a bit of confusion. Can someone help me understand a few points for the screenshot below?

  • What is the root layout used here?
  • How do I get the button bar to remain at the bottom, while the center section scrolls when it is long enough?
  • Similar to the Ok/Cancel buttons seen here, how do I make them each 50% width (minus some margin and padding)?

Android Market

like image 335
Matt Huggins Avatar asked Nov 19 '25 00:11

Matt Huggins


1 Answers

starting with last one i.e.

Buttons each with 50% width:

  • Place both buttons in another linear layout
  • Make linear layout's orientation="horizontal"
  • make layout's width = "fill parent"
  • make button's width = "0px"
  • for each button, set layout_weight="1.0"

What is the root layout used here?

  • Use a linear layout with orientation="vertical"

  • plave a layout for button bar portion with height="wrap_content"

  • then a listView

  • thne the linear layout for button, described above

section scrolls when it is long enough?

  • Use a Custom ListView

  • Make height pf listView = "wrap_content"

  • Make layout_weight = "1.0" for ListView

i hope it will help if not completely then will give you an idea.

like image 90
Khawar Avatar answered Nov 20 '25 14:11

Khawar



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!