Painted like a slash is textview, used scrollview wrapped up, I want the textview text less, when the red button below to follow scrollview piece of wrapcontent size automatically follow below, while a large amount of text textview time, automatically extended to occupy the screen height until all remaining available space, like a set of weight = 1, and the effect in the following figure, the red button is always displayed on the screen, followed scrollview below. If the width is set directly textview wrapcontent, text length when the red button directly below the screen was textview launched outside, do not know how to humbly ask for advice! !

Reply:
Not sure I understand there is no problem that has been with the scrollview button below, and if it appears beyond the screen scrollview scrolling, button at the bottom?
Here is what I wrote, the number of test yourself filling textview height.
android: layout_height = "wrap_content"
android: orientation = "vertical"
>
android: layout_height = "wrap_content"
android: minHeight = "20dip"
android: scrollbars = "vertical"
android: id = "@ + id / sc"
android: layout_weight = "5"
>
android: layout_height = "wrap_content"
android: orientation = "vertical"
>
android: layout_height = "wrap_content"
android: text = "@ string / hello" />
android: layout_height = "wrap_content"
android: text = "@ string / hello" />
android: layout_height = "wrap_content"
android: text = "@ string / hello" />
android: layout_weight = "0"
android: text = "OK"
android: background = "@ android: color / darker_gray"
android: layout_width = "match_parent"
android: layout_height = "wrap_content"
/>
Reply:
Button there plus a property like: android: layout_gravity = "bottom"
Reply:
Recent projects really busy powerful, forget there's a problem not bear out .. the first time, do not know how to reply to the above found two enthusiastic floors, post and sink ... say two bars, a it is a complete code of building tenants, but the key is my bottom there is a black bar at the bottom of the absolute position of the tool, not the same as that followed by the red button to move the position of the above scrollview stretch, I think, or their own research well, Posts good use.
Reply:
In fact, the answer to the first floor of what purpose did, but in order to return points, be hard to reward it, the second floor of the word too little, not a reference.
No comments:
Post a Comment