clearStyle() just erases an override in the CSSStyleDeclaration set using setStyle(). A lot of component implement styleChanged() where they can adjust there view based on the styleProp parameter.
Some components invalidate the component in this method, if they do you will not see an update immediatly. For situations where you don't see updates and want them right off call;
However, for some reason it doesnt work.
This code doesnt update the textarea.
Note! In my setup I set many styles in a series of calls. I have also tried textarea_target.validateNow() after the calls but it still doesnt work.
What to do ??
I'm not quite sure but since the style bottom has to do with the display list and measurement, you might need;
textarea_target.clearStyle("bottom"); textarea_target.invalidateSize(); textarea_target.invalidateDisplayList(); UIComponent(textarea_target.parent).validateNow();
Thanks again Mike
I think I`ve found a solution. When the baseline style is undefined the bottom update doesnt work. When baseline is set to a value the bottom update works (event without calling validateNow). It seems some styleproperties depend on others being defined for them to work