I am working on adapting an app which was designed for a larger vertical screen dimension (1200px) to a device with a smaller size (vertical=800px). I've managed to get things displaying properly by editing the layout XML files--except for one thing. As you can see, the crossword puzzle is cut off at the bottom. Its original dimensions in the layout were 570x570px. At that size, the lower part of the puzzle ended up peeking out from behind the keyboard.
After resizing both the keyboard and the clue drop-down at the top of the screen so they work properly, I'm left with a vertical space of 390px for the puzzle. Absent any other ideas, I've been trying to implement scrolling in that FrameLayout, following several examples such as Scrollable FrameLayout.
I can't seem to get it to work. My knowledge of layout is sketchy. Can anyone suggest a solution or a different approach?
(the puzzle layout on the screen is given in line 6)
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:gravity="bottom|center" android:orientation="vertical" android:background="#color/root_background" android:layout_width="fill_parent" android:layout_height="fill_parent"
xmlns:android="http://schemas.android.com/apk/res/android">
<FrameLayout android:gravity="top|center" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1.0">
<FrameLayout android:gravity="top|center" android:orientation="vertical" android:id="#id/field_container" android:paddingTop="160.0px" android:layout_width="600.0px" android:layout_height="wrap_content">
<com.encore.crossword.view.CrosswordView android:layout_gravity="top|center" android:id="#id/crosswordView" android:layout_width="570.0px" android:layout_height="390.0px" />
<LinearLayout android:gravity="center" android:id="#id/difficulty_layout" android:paddingTop="146.0px" android:visibility="invisible" android:layout_width="fill_parent" android:layout_height="fill_parent">
<LinearLayout android:layout_gravity="center" android:orientation="vertical" android:background="#drawable/c_dialog_box" android:paddingLeft="30.0px" android:paddingTop="30.0px" android:paddingRight="30.0px" android:paddingBottom="20.0px" android:layout_width="wrap_content" android:layout_height="wrap_content">
<TextView android:textAppearance="#style/DialogHeader" android:gravity="center" android:id="#id/TextViewGameOver" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="Game Difficulty" />
<RadioGroup android:gravity="left|center" android:orientation="vertical" android:id="#id/RadioGroupDifficulty" android:paddingTop="6.0px" android:paddingBottom="6.0px" android:layout_width="fill_parent" android:layout_height="wrap_content">
<RadioButton android:textAppearance="#style/ButtonTextMain" android:textColor="#color/button_radio" android:id="#id/RadioButtonEasy" android:layout_width="wrap_content" android:layout_height="wrap_content" android:checked="false" android:button="#drawable/sudoku_radio_button" android:text="#string/easy" android:width="160.0px" />
<RadioButton android:textAppearance="#style/ButtonTextMain" android:textColor="#color/button_radio" android:id="#id/RadioButtonMedium" android:layout_width="wrap_content" android:layout_height="wrap_content" android:button="#drawable/sudoku_radio_button" android:text="#string/medium" android:width="160.0px" />
<RadioButton android:textAppearance="#style/ButtonTextMain" android:textColor="#color/button_radio" android:id="#id/RadioButtonHard" android:layout_width="wrap_content" android:layout_height="wrap_content" android:button="#drawable/sudoku_radio_button" android:text="#string/hard" android:width="160.0px" />
<RadioButton android:textAppearance="#style/ButtonTextMain" android:textColor="#color/button_radio" android:id="#id/RadioButtonExtreme" android:layout_width="wrap_content" android:layout_height="wrap_content" android:button="#drawable/sudoku_radio_button" android:text="#string/themeless" android:width="160.0px" />
</RadioGroup>
</LinearLayout>
</LinearLayout>
</FrameLayout>
<LinearLayout android:gravity="top|center" android:orientation="vertical" android:id="#id/clue_container" android:background="#drawable/cross_top_dialog_box" android:paddingLeft="5.0px" android:paddingRight="5.0px" android:layout_width="fill_parent" android:layout_height="wrap_content">
<LinearLayout android:gravity="top|center" android:orientation="vertical" android:id="#id/mini_clue_container" android:paddingLeft="5.0px" android:paddingRight="5.0px" android:visibility="visible" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1.0">
<LinearLayout android:id="#id/ClueTop1" android:layout_width="fill_parent" android:layout_height="wrap_content">
<TextView android:textAppearance="#style/ClueInfoText" android:id="#id/TextViewClueWordNumber1" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="" android:layout_weight="1.0" />
<TextView android:textAppearance="#style/ClueInfoText" android:gravity="right" android:id="#id/TextViewClueWordLength1" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="" android:layout_weight="1.0" />
</LinearLayout>
<TextView android:textAppearance="#style/ClueText" android:id="#id/TextViewClue1" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="10.0px" android:text="" android:lines="2" />
<LinearLayout android:id="#id/ClueTop2" android:layout_width="fill_parent" android:layout_height="wrap_content">
<TextView android:textAppearance="#style/ClueInfoText" android:id="#id/TextViewClueWordNumber2" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="" android:layout_weight="1.0" />
<TextView android:textAppearance="#style/ClueInfoText" android:gravity="right" android:id="#id/TextViewClueWordLength2" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="" android:layout_weight="1.0" />
</LinearLayout>
<TextView android:textAppearance="#style/ClueText" android:id="#id/TextViewClue2" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="10.0px" android:text="" android:lines="2" />
</LinearLayout>
<LinearLayout android:gravity="top|center" android:orientation="vertical" android:id="#id/big_clue_container" android:paddingLeft="0.0px" android:paddingRight="0.0px" android:visibility="gone" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1.0">
<TextView android:textAppearance="#style/ClueTextBold" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="10.0px" android:text="ACROSS" />
<LinearLayout android:gravity="top|center" android:orientation="vertical" android:id="#id/big_clue_across_container" android:background="#drawable/c_dialog_box" android:paddingTop="17.0px" android:paddingBottom="17.0px" android:layout_width="fill_parent" android:layout_height="200.0px">
<ListView android:scrollbarStyle="outsideOverlay" android:id="#id/big_clue_across_list" android:paddingLeft="5.0px" android:layout_width="fill_parent" android:layout_height="wrap_content" />
</LinearLayout>
<TextView android:textAppearance="#style/ClueTextBold" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="10.0px" android:text="DOWN" />
<LinearLayout android:gravity="top|center" android:orientation="vertical" android:id="#id/big_clue_down_container" android:background="#drawable/c_dialog_box" android:paddingTop="17.0px" android:paddingBottom="17.0px" android:layout_width="fill_parent" android:layout_height="200.0px">
<ListView android:id="#id/big_clue_down_list" android:paddingLeft="5.0px" android:layout_width="fill_parent" android:layout_height="wrap_content" />
</LinearLayout>
</LinearLayout>
<ImageView android:id="#id/ClueContainerArrow" android:background="#drawable/cross_down_arrow" android:layout_width="30.0px" android:layout_height="20.0px" android:layout_marginBottom="10.0px" android:layout_weight="1.0" />
</LinearLayout>
<LinearLayout android:gravity="bottom" android:layout_gravity="bottom|left|center" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent">
<include android:id="#id/bottom_layout" android:layout_width="fill_parent" android:layout_height="160.0px" layout="#layout/bottom_layout" />
</LinearLayout>
<include android:id="#id/bottom_menu" android:layout_width="fill_parent" android:layout_height="fill_parent" layout="#layout/bottom_menu" />
</FrameLayout>
<LinearLayout android:gravity="center" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="50.0dip">
<LinearLayout android:gravity="center" android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1.0">
<Button android:textAppearance="#style/ButtonText" android:textColor="#color/solid_white" android:id="#id/GameButton" android:background="#drawable/btn_footer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="2.0dip" android:layout_marginRight="0.0dip" android:text="Game" android:layout_weight="1.0" />
<ImageView android:id="#id/ImageView01" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="#drawable/footer_line_divider" />
<Button android:textAppearance="#style/ButtonText" android:textColor="#color/solid_white" android:id="#id/LastWordButton" android:background="#drawable/btn_footer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="0.0dip" android:layout_marginRight="0.0dip" android:text="Prev Word" android:layout_weight="1.0" />
<ImageView android:id="#id/ImageView01" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="#drawable/footer_line_divider" />
<Button android:textAppearance="#style/ButtonText" android:textColor="#color/solid_white" android:id="#id/NextWordButton" android:background="#drawable/btn_footer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="2.0dip" android:layout_marginRight="0.0dip" android:text="Next Word" android:layout_weight="1.0" />
<ImageView android:id="#id/ImageView01" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="#drawable/footer_line_divider" />
<Button android:textAppearance="#style/ButtonText" android:textColor="#color/solid_white" android:id="#id/KeyboardButtonHint" android:background="#drawable/btn_footer" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="0.0dip" android:layout_marginRight="0.0dip" android:text="Hint" android:layout_weight="1.0" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
Related
I have made a view for advertisements list and LinearLayout is not filling whole screen width, checked all the code and I don't understand where I am mistaken. Here is the code of my LinearLayout:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
android:orientation="vertical"
android:id="#id/advertisement_list_container"
android:paddingTop="0.0dip"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto">
<TextView
android:id="#id/advertisement_list_datetime"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingLeft="#dimen/activity_margin_horizontal"
android:paddingTop="#dimen/small_listing_margin"
android:paddingRight="#dimen/activity_margin_horizontal"
android:paddingBottom="#dimen/small_listing_margin"
android:layout_marginBottom="#dimen/listing_margin"
android:text="#string/advertisement_list_datetime"
style="#style/TextWhiteNormalBoldGreyBackground" />
<LinearLayout
android:orientation="vertical"
android:paddingLeft="#dimen/activity_margin_horizontal"
android:paddingRight="#dimen/activity_margin_horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<TextView
android:id="#id/advertisement_list_from_city"
android:layout_marginLeft="#dimen/listing_margin"
android:text="#string/advertisement_list_from_city"
style="#style/TextNormalBold" />
<TextView
android:id="#id/advertisement_list_tire"
android:layout_marginLeft="#dimen/tire_margin"
android:text="#string/advertisement_list_tire"
style="#style/TextNormalBold" />
<TextView
android:id="#id/advertisement_list_to_city"
android:layout_marginLeft="#dimen/tire_margin"
android:text="#string/advertisement_list_to_city"
style="#style/TextNormalBold" />
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/activity_margin_vertical">
<ImageView
android:id="#id/advertisement_list_user_avatar"
android:layout_width="#dimen/avatar_result_size_width"
android:layout_height="#dimen/avatar_result_size_height"
android:src="#drawable/ic_default_avatar" />
<LinearLayout
android:gravity="center_vertical"
android:orientation="vertical"
android:layout_width="0.0dip"
android:layout_height="fill_parent"
android:layout_marginLeft="#dimen/listing_margin"
android:layout_weight="1.0">
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<TextView
android:id="#id/advertisement_list_user_name"
android:text="#string/advertisement_list_user_name"
style="#style/TextDarkBlueNormalBold" />
<TextView
android:id="#id/advertisement_list_user_age"
android:text="#string/advertisement_list_user_age"
android:layout_marginLeft="#dimen/small"
style="#style/TextGreyNormal" />
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<ImageView
android:layout_width="#dimen/text_normal"
android:layout_height="fill_parent"
android:layout_marginRight="#dimen/margin_small"
android:src="#drawable/ic_star_gold_no_border"
android:scaleType="fitCenter" />
<TextView
android:id="#id/advertisement_list_user_rating"
android:text="#string/advertisement_list_user_rating"
style="#style/TextNormalBold" />
<TextView
android:id="#id/advertisement_list_user_rate"
android:layout_marginLeft="#dimen/margin_micro"
android:text="#string/advertisement_list_user_rate"
style="#style/TextGreyNormal" />
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<ImageView
android:layout_width="#dimen/text_normal"
android:layout_height="fill_parent"
android:layout_marginRight="#dimen/small"
android:src="#drawable/ic_car_blue"
android:scaleType="fitCenter" />
<TextView
android:id="#id/advertisement_list_user_car"
android:layout_marginRight="#dimen/small"
android:text="#string/advertisement_list_user_car"
style="#style/TextNormalBold" />
<TextView
android:id="#id/advertisement_list_user_car_y"
android:text="#string/advertisement_list_user_car_y"
style="#style/TextGreyNormal" />
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<ImageView
android:layout_width="#dimen/text_normal"
android:layout_height="fill_parent"
android:layout_marginRight="#dimen/small"
android:tint="#color/text_dark_blue"
android:src="#drawable/ic_phone"
android:scaleType="fitCenter" />
<TextView
android:id="#id/advertisement_list_user_phone"
android:layout_marginRight="#dimen/small"
android:text="#string/advertisement_list_user_phone"
style="#style/TextNormalBold" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginTop="#dimen/activity_margin_vertical">
<LinearLayout
android:orientation="vertical"
android:layout_width="0.0dip"
android:layout_height="wrap_content"
android:layout_weight="2.0">
<TextView
android:gravity="center_horizontal"
android:id="#id/advertisement_list_free_seats"
android:layout_width="fill_parent"
android:text="#string/advertisement_list_free_seats"
style="#style/TextDarkBlueMediumBold" />
<TextView
android:gravity="center_horizontal"
android:id="#id/advertisement_list_free_seats"
android:layout_width="fill_parent"
android:text="#string/advertisement_list_free_seats"
android:lines="2"
style="#style/TextDarkBlueSmall" />
</LinearLayout>
<LinearLayout
android:orientation="vertical"
android:background="#color/transparent"
android:layout_width="0.0dip"
android:layout_height="wrap_content"
android:layout_weight="2.0">
<TextView
android:gravity="center_horizontal"
android:id="#id/advertisement_list_price"
android:layout_width="fill_parent"
android:text="#string/advertisement_list_price"
style="#style/TextDarkBlueMediumBold" />
<TextView
android:gravity="center_horizontal"
android:id="#id/advertisement_list_ride_price"
android:layout_width="fill_parent"
android:text="#string/advertisement_list_ride_price"
android:lines="2"
style="#style/TextDarkBlueSmall" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<ImageView
android:background="#drawable/divider"
android:contentDescription="#string/description"
android:layout_width="fill_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</LinearLayout>
And this is the result what I see in my app: https://imgur.com/a/eKv1hHi
So advertisement must fill whole screen width.
Changed main LinearLayout to RelativeLayout and it fixed my issue!
When I launch my app, I go to one of my screens to test out my game. Though, when I go to tap on the buttons, they don't work and do not change images like I wanted them to. So after various amounts of googling and testing, I believe I came across the problem. I believe I just have my text layer on top of my button layer, causing it so the buttons cannot be clicked as they are not the top layer. My issue here is I need the text on top to change constantly. How do I make it so my text does not interfere with my buttons.
I apologize for the big amount of code. The buttons are in the third relative layout, and the text is all in the middle.
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_height="match_parent"
android:gravity="center_horizontal">
<ImageView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="#+id/imageView"
android:background="#drawable/backgroundupg" />
</RelativeLayout>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_height="match_parent"
android:gravity="center_horizontal" android:layout_weight="1">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="#+id/imageView5"
android:layout_marginTop="#dimen/activity_vertical_margin"
android:background="#drawable/upgrades"
android:layout_gravity="center_horizontal" />
</RelativeLayout>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_height="match_parent"
android:gravity="center_horizontal" android:layout_weight=".5">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:weightSum="4">
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="#drawable/selector_state2_xml"
android:id="#+id/upgbutton"
android:layout_gravity="center_horizontal" />
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="#drawable/selector_state3_xml"
android:id="#+id/upgbutton1"
android:layout_gravity="center_horizontal" />
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="#drawable/selector_state4_xml"
android:id="#+id/upgbutton2"
android:layout_gravity="center_horizontal" />
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="#drawable/selector_state5_xml"
android:id="#+id/upgbutton3"
android:layout_gravity="center_horizontal" />
</LinearLayout>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:weightSum="8">
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/upgtext"
android:text="Accuracy"
style="#style/Base.TextAppearance.AppCompat.Large"
android:textColor="#ffffff" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight=".5"
android:gravity="center_vertical|right"
android:id="#+id/pricetext"
android:text="100"
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1.5"
android:id="#+id/upg1cost"
android:background="#drawable/cookie" />
</LinearLayout>
</RelativeLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_weight="1">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/bottomtext"
android:text="Eh, close enough."
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
</RelativeLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/upgtext2"
android:text="Base Cookies"
style="#style/Base.TextAppearance.AppCompat.Large"
android:textColor="#ffffff" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight=".5"
android:gravity="center_vertical|right"
android:id="#+id/pricetext2"
android:text="500"
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1.5"
android:id="#+id/upg1cost"
android:gravity="center_vertical"
android:layout_alignRight="#+id/upgtext2"
android:background="#drawable/cookie" />
</LinearLayout>
</RelativeLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_weight="1">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/bottomtext2"
android:text="Double the cookies? Sweet!"
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
</RelativeLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/upgtext3"
android:text="Stopping Time"
style="#style/Base.TextAppearance.AppCompat.Large"
android:textColor="#ffffff" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight=".5"
android:gravity="center_vertical|right"
android:id="#+id/pricetext3"
android:text="1000"
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1.5"
android:id="#+id/upg1cost"
android:gravity="center_vertical"
android:layout_alignRight="#+id/upgtext3"
android:background="#drawable/cookie" />
</LinearLayout>
</RelativeLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_weight="1">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/bottomtext3"
android:text="I save an extra second!"
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
</RelativeLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/upgtext4"
android:text="Secret"
style="#style/Base.TextAppearance.AppCompat.Large"
android:textColor="#ffffff" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"
android:orientation="horizontal"
android:weightSum="2">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight=".5"
android:gravity="center_vertical|right"
android:id="#+id/pricetext4"
android:text="250 000"
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_weight="1.5"
android:id="#+id/upg1cost"
android:gravity="center_vertical"
android:layout_alignRight="#+id/upgtext4"
android:background="#drawable/cookie" />
</LinearLayout>
</RelativeLayout>
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_weight="1">
<TextView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:gravity="center_vertical|center_horizontal"
android:id="#+id/bottomtext4"
android:text="End game?!?!"
style="#style/Base.TextAppearance.AppCompat.Medium"
android:textColor="#ffffff" />
</RelativeLayout>
</LinearLayout>
</RelativeLayout>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent" android:layout_height="match_parent"
android:gravity="center_horizontal" android:layout_weight="1">
</RelativeLayout>
</LinearLayout>
</FrameLayout>
I also included an image to help give a visual representation of my code.
As well as my selector state for those who would like to know exactly what I put in it
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="#drawable/button" android:state_enabled="true"></item>
<item android:drawable="#drawable/buttonclick" android:state_pressed="true"></item>
<item android:drawable="#drawable/buttongray" android:state_enabled="false"></item>
</selector>
Button is used when the user has enough cash to purchase the upgrade.
Buttongray is used when the user does not have enough cash, I do not want the button to be pressable then. The Button color just turns gray.
Buttonclick is just a highlight of Button.
I have tried interchanging both states as I thought that was the initial problem. Neither can be pressed.
the problem is because you are having your TextView objects above your Button objects and they steal the click event which you intend for the Button. The easiest fix would be to set:
android:focusable="false"
for all the TextView objects that overlay Button objects.
But I would still say your coding style needs to be improved. Why not dynamically change text in code based on events that happen in run time. You can use the setText(CharSequence text) method for buttons to dynamically set the text they should display.
You can use Button's attribute android:text="TEXT_HERE" in xml to set initial text for your button and later on with on click you can set a different text by this
Button button = (Button)findViewById(R.id.upgbutton);
button.setText("New_TEXT");
you button code in XML will look like this
<Button
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text = "Accuracy"
android:background="#drawable/selector_state2_xml"
android:id="#+id/upgbutton"
android:layout_gravity="center_horizontal" />
Since each "button" is so complex, you should consider creating a custom view.
I have to create the following layout on an Android device:
The requirements are as follows:
First layout which occupies the whole screen (fill_parent);
Second (at the bottom of the screen) overlays the first one and has the following formats:
3 columns;
occupies the whole screen width;
arrows are aligned left and right sides, and text area is resized based on screen width;
I've tried numerous things, but since I'm new to the Android world, I had no success yet.
Here is what I have so far:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:minWidth="25px"
android:minHeight="25px"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:weightSum="100"
android:id="#+id/RootView">
<ImageView
android:src="#android:drawable/ic_menu_gallery"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:scaleType="fitXY"
android:id="#+id/mapImageView" />
<LinearLayout
android:id="#+id/bottomArea"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_alignParentBottom="true">
<LinearLayout
android:id="#+id/adsArea"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="horizontal"
android:layout_alignParentBottom="true">
<ImageButton
android:src="#drawable/leftArrow"
android:id="#+id/btnPrev"
android:layout_alignParentRight="true"
android:layout_marginLeft="0dip"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<LinearLayout
android:orientation="vertical"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_gravity="center">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Title" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="This is some summary text" />
</LinearLayout>
<ImageButton
android:src="#drawable/rightArrow"
android:layout_alignParentRight="true"
android:layout_marginRight="0dip"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="#+id/btnNext" />
</LinearLayout>
</LinearLayout>
</RelativeLayout>
but the text doesn't seem to be center aligned, nor resized to the screen width:
Does someone has a clue?
Thanks.
Use this code for your required layout...
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity" >
<LinearLayout
android:id="#+id/linear1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="#+id/linear2" >
<ImageView
android:id="#+id/imageView1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:src="#drawable/ic_launcher" />
</LinearLayout>
<RelativeLayout
android:id="#+id/linear2"
android:layout_width="match_parent"
android:layout_height="70dp"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true" >
<ImageButton
android:id="#+id/leftButton1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:src="#drawable/ic_launcher" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_toLeftOf="#+id/rightButton1"
android:layout_toRightOf="#+id/leftButton1"
android:gravity="center"
android:orientation="vertical" >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Title" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="This is some summary text" />
</LinearLayout>
<ImageButton
android:id="#+id/rightButton1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:src="#drawable/ic_launcher" />
</RelativeLayout>
Please find the code below. Also, do not use multiple viewgroup for simple layout solution.
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="#+id/RootView"
android:layout_width="fill_parent"
android:layout_height="fill_parent" >
<ImageView
android:id="#+id/mapImageView"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:src="#android:drawable/ic_menu_gallery" />
<RelativeLayout
android:id="#+id/adsArea"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true" >
<ImageButton
android:id="#+id/btnPrev"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:src="#drawable/leftArrow" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:orientation="vertical" >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Title" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="This is some summary text" />
</LinearLayout>
<ImageButton
android:id="#+id/btnNext"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:src="#drawable/rightArrow" />
</RelativeLayout>
</RelativeLayout>
I need to positioning the ImageView at the same level of the user's name (vito in the example).
This is what I have:
And I want this (look at the second icon):
My xml:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_height="wrap_content"
android:layout_width="fill_parent"
android:paddingBottom="5px"
android:paddingTop="5px"
android:paddingLeft="5px"
android:orientation="horizontal"
style="#style/ListRow">
<ImageView
android:id="#+id/imagenItem"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_marginRight="6dip"
android:layout_gravity="top"
android:gravity="top"
android:layout_alignParentTop="true"
style="#style/iconLISTA" />
<LinearLayout
android:orientation="vertical"
android:layout_width="0dip"
android:layout_weight="1"
android:layout_height="fill_parent">
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
android:id="#+id/idUsuario"
android:textSize="#dimen/font_size_small"
android:textStyle="bold"
android:textColor="#color/list_item_text"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"/>
<TextView
android:id="#+id/hora"
android:textSize="#dimen/font_size_small"
android:textStyle="bold"
android:textColor="#color/list_item_secondary_text"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="215px" />
</RelativeLayout>
<TextView
android:id="#+id/comentarios"
android:textSize="#dimen/font_size_small"
android:color="#color/list_item_text"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="0px" />
</LinearLayout>
</LinearLayout>
Thanks.
Change the ImageView and following LinearLayout hight attributes to both be wrap_content.
The ImageView is currently fill_parent which is making it take all available vertical space and centering it vertically.
Add:
android:scaleType="fitStart"
to the ImageView layout.
e.g.
<ImageView
android:id="#+id/imagenItem"
android:scaleType="fitStart"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_marginRight="6dip"
android:layout_gravity="top"
android:gravity="top"
android:layout_alignParentTop="true"
style="#style/iconLISTA" />
Try this, is bit simplified:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:padding="5dp" >
<ImageView
android:id="#+id/imagenItem"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_gravity="top"
android:scaleType="fitCenter"
android:src="#drawable/avatar_default" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dp"
android:orientation="vertical" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="horizontal" >
<TextView
android:id="#+id/idUsuario"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="left"
android:text="usuario"
android:textStyle="bold" />
<TextView
android:id="#+id/hora"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="right"
android:text="hora"
android:textStyle="bold" />
</LinearLayout>
<TextView
android:id="#+id/comentarios"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="commmmment" />
</LinearLayout>
</LinearLayout>
And you shouldn't use px, use always dp/dip.
I'm trying to put the buttonbar I've created on the bottom of each screen. I've succeeded for the first screen fairly easy.
Now I've tried to put it other screens, but it seems that it can't stick to the bottom of the screen. When I look in the hiearchyviewer, it looks like the RelativeLayout that's wrapped araound my layout and buttonbar, isn't filling the whole screen, though, its height is set to fill parent.
Can anyone help me by pointing out where I'm going wrong?
This is the XML I use:
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="fill_parent">
<RelativeLayout android:layout_width="fill_parent"
android:layout_height="fill_parent" android:orientation="vertical">
<TableLayout android:layout_width="fill_parent"
android:layout_height="fill_parent" android:padding="5pt" android:id="#+id/table"
android:stretchColumns="1">
<TableRow>
<TextView android:text="#string/Arbeiderbediende"
android:id="#+id/txtArbeiderBediende" android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</TableRow>
<TableRow android:gravity="center">
<RadioGroup android:layout_width="fill_parent"
android:layout_height="wrap_content" android:orientation="horizontal"
android:id="#+id/group1">
<RadioButton style="#style/RadioButton"
android:layout_width="wrap_content" android:id="#+id/rbArbeider"
android:text="#string/Arbeider" android:layout_height="wrap_content"
android:paddingLeft="18pt" />
<RadioButton style="#style/RadioButton"
android:layout_width="wrap_content" android:id="#+id/rbBediende"
android:text="#string/Bediende" android:layout_height="wrap_content"
android:layout_marginLeft="20pt" android:paddingLeft="18pt" />
</RadioGroup>
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/OverzichtFuncties"
android:id="#+id/txtFuncties" android:layout_width="0dip"
android:layout_weight="1" android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content" style="Spinner"
android:layout_width="0dip" android:layout_weight="2"
android:id="#+id/cmbFuncties" />
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/Regio" android:id="#+id/txtRegio"
android:layout_width="0dip" android:layout_weight="1"
android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content"
android:layout_width="0dip" android:layout_weight="2" android:id="#+id/cmbRegio" />
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/Opleiding" android:id="#+id/txtOpleidingsniveau"
android:layout_width="0dip" android:layout_weight="1"
android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content"
android:layout_width="0dip" android:layout_weight="2"
android:id="#+id/cmbOpleidingsniveau" />
</TableRow>
<Button android:text="#string/VindJobButton" android:id="#+id/btnFindJob"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:layout_marginTop="10dip" />
</TableLayout>
<stage.accent.Toolbar android:layout_width="fill_parent"
android:layout_height="70dip" android:layout_alignParentBottom="true"
android:layout_below="#+id/table" />
</RelativeLayout>
This is the result I achieved and the result I want to get
In case you want your buttonbar to be always visible at the bottom of the screen and not scroll with the content, you might want to switch your RelativeLayout and ScrollView tags, and move your buttonbar to be the first child of your RelativeLayout, the ScrollView to be the second:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical">
<stage.accent.Toolbar android:id="id/buttonBar" android:layout_width="fill_parent"
android:layout_height="70dip" android:layout_alignParentBottom="true" />
<ScrollView android:layout_above="#+id/buttonBar"
android:layout_width="fill_parent" android:layout_height="fill_parent">
<TableLayout android:layout_width="fill_parent"
android:layout_height="fill_parent" android:padding="5pt" android:id="#+id/table"
android:stretchColumns="1">
<TableRow>
<TextView android:text="#string/Arbeiderbediende"
android:id="#+id/txtArbeiderBediende" android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</TableRow>
<TableRow android:gravity="center">
<RadioGroup android:layout_width="fill_parent"
android:layout_height="wrap_content" android:orientation="horizontal"
android:id="#+id/group1">
<RadioButton style="#style/RadioButton"
android:layout_width="wrap_content" android:id="#+id/rbArbeider"
android:text="#string/Arbeider" android:layout_height="wrap_content"
android:paddingLeft="18pt" />
<RadioButton style="#style/RadioButton"
android:layout_width="wrap_content" android:id="#+id/rbBediende"
android:text="#string/Bediende" android:layout_height="wrap_content"
android:layout_marginLeft="20pt" android:paddingLeft="18pt" />
</RadioGroup>
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/OverzichtFuncties"
android:id="#+id/txtFuncties" android:layout_width="0dip"
android:layout_weight="1" android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content" style="Spinner"
android:layout_width="0dip" android:layout_weight="2"
android:id="#+id/cmbFuncties" />
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/Regio" android:id="#+id/txtRegio"
android:layout_width="0dip" android:layout_weight="1"
android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content"
android:layout_width="0dip" android:layout_weight="2" android:id="#+id/cmbRegio" />
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/Opleiding" android:id="#+id/txtOpleidingsniveau"
android:layout_width="0dip" android:layout_weight="1"
android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content"
android:layout_width="0dip" android:layout_weight="2"
android:id="#+id/cmbOpleidingsniveau" />
</TableRow>
<Button android:text="#string/VindJobButton" android:id="#+id/btnFindJob"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:layout_marginTop="10dip" />
</TableLayout>
</ScrollView>
</RelativeLayout>
This way you'll be able to achieve what you want:
and
The button bar will be always at the bottom of your screen.
And by scrolling the content, you'll be able to see the last bit of it too, it won't be hidden behind the buttonbar:
I still suggests dont use ScrollView here is an example how you can show the ButtonBar at the bottom
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content" android:layout_height="wrap_content">
<RelativeLayout
android:id="#+id/headerlayout"
android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_alignParentTop="true"
android:layout_alignParentLeft="true"
>
<Button android:id="#+id/amap_back_btn" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_alignParentTop="true"
android:layout_alignParentLeft="true" android:text="Back">
</Button>
<TextView android:id="#+id/amap_txt"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:text="" android:layout_centerVertical="true"
android:layout_centerHorizontal="true">
</TextView>
<ImageButton android:id="#+id/amap_action_btn"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:src="#drawable/icon_menu_action"
android:layout_alignParentTop="true" android:layout_alignParentRight="true">
</ImageButton>
</RelativeLayout>
//What ever widgets you wants to add
<LinearLayout
android:id="#+id/bottomlayout"
android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_alignParentBottom="true"
android:layout_centerHorizontal="true"
android:orientation="horizontal"
>
<ImageButton android:id="#+id/map_refresh_btn"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:src="#drawable/icon_refresh"
android:gravity="center"
>
</ImageButton>
<Button android:id="#+id/map_log_btn" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:text="Log"
android:gravity="center">
</Button>
<Button android:id="#+id/map_map_btn" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:text="Map"
android:gravity="center"
>
</Button>
</LinearLayout>
</RelativeLayout>
that is all this is the most robust solution.
If you find it useful dont forget to mark it as an answer.
Please take one main linear layout
above scroll view and after ending
scroll view please set your bottom
bar..
It would be also my suggetion.
LinearLayout is the main view.
Within it
Another LinearLayout (layout_height=0dp and layout_weight = 1) *ll_container*
and you tabbar
Within *ll_container* place
a scrollview (layout_height=0dp and layout_weight = 1) with tablelayout
and the button
Probably for explanation. With layout_height=0dp and layout_weight = 1 you give your layouts the whole free place remaining after placing your tabbar and then after placing your button
UPD
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical">
<LinearLayout android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:orientation="vertical">
<ScrollView android:layout_width="fill_parent"
android:layout_height="0dp"
android:layout_weight="1">
<TableLayout android:layout_width="fill_parent"
android:layout_height="fill_parent" android:padding="5pt" android:id="#+id/table"
android:stretchColumns="1">
<TableRow>
<TextView android:text="#string/Arbeiderbediende"
android:id="#+id/txtArbeiderBediende" android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</TableRow>
<TableRow android:gravity="center">
<RadioGroup android:layout_width="fill_parent"
android:layout_height="wrap_content" android:orientation="horizontal"
android:id="#+id/group1">
<RadioButton style="#style/RadioButton"
android:layout_width="wrap_content" android:id="#+id/rbArbeider"
android:text="#string/Arbeider" android:layout_height="wrap_content"
android:paddingLeft="18pt" />
<RadioButton style="#style/RadioButton"
android:layout_width="wrap_content" android:id="#+id/rbBediende"
android:text="#string/Bediende" android:layout_height="wrap_content"
android:layout_marginLeft="20pt" android:paddingLeft="18pt" />
</RadioGroup>
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/OverzichtFuncties"
android:id="#+id/txtFuncties" android:layout_width="0dip"
android:layout_weight="1" android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content" style="Spinner"
android:layout_width="0dip" android:layout_weight="2"
android:id="#+id/cmbFuncties" />
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/Regio" android:id="#+id/txtRegio"
android:layout_width="0dip" android:layout_weight="1"
android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content"
android:layout_width="0dip" android:layout_weight="2" android:id="#+id/cmbRegio" />
</TableRow>
<TableRow android:gravity="center" android:paddingTop="5dip">
<TextView android:text="#string/Opleiding" android:id="#+id/txtOpleidingsniveau"
android:layout_width="0dip" android:layout_weight="1"
android:layout_height="wrap_content" />
<Spinner android:layout_height="wrap_content"
android:layout_width="0dip" android:layout_weight="2"
android:id="#+id/cmbOpleidingsniveau" />
</TableRow>
</TableLayout>
</ScrollView>
<Button android:text="#string/VindJobButton" android:id="#+id/btnFindJob"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:layout_marginTop="10dip" />
</LinearLayout>
<stage.accent.Toolbar android:layout_width="fill_parent"
android:layout_height="70dip" android:layout_alignParentBottom="true"
android:layout_below="#+id/table" />
</LinearLayout>