> step, as it's been ages since I've needed to make changes like this Isn't this a good way of making changes?
On Apr 27, 6:02 pm, Mark Murphy <mmur...@commonsware.com> wrote: > nou wrote: > > It doesn't work. That's to change the margin at instantiation time. I > > already have an element on the page which I retrieve like this > > > LinearLayout el = (LinearLayout) findViewById(R.id.xxx); > > > I'd like to change the margin of the element which is ALREADY > > rendered > > That's what TreKing was pointing you toward. > > Step #1: Get your widget's LayoutParams > > Step #2: Change the margin values > > Step #3: Either call setLayoutParams() (on the widget) or invalidate() > (on the parent) to visibly affect the change -- I'm a bit fuzzy on this > step, as it's been ages since I've needed to make changes like this > > -- > Mark Murphy (a Commons > Guy)http://commonsware.com|http://twitter.com/commonsguy > > Warescription: Three Android Books, Plus Updates, One Low Price! > > -- > 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 > athttp://groups.google.com/group/android-developers?hl=en -- 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