> How do I reposition views at runtime?

The same way you position them in the first place -- by manipulating their
layout rules (e.g., android:layout_centerInParent). You do this via
calling getLayoutParams() on your View, casting it to an appropriate type
(e.g., RelativeLayout.LayoutParams), making the desired changes, and
calling setLayoutParams() to affect those changes.

Note that I haven't done this in quite some time, so the above recipe is
from memory and may be a bit off, though I'm pretty sure it is mostly
correct.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com
Android App Developer Books: http://commonsware.com/books.html


-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to