[ER] Grid.setStyle() to add CSS directives to current CSS


_size.js!AW.Grid.Controllers.Size defines a setStyle() function allowing to add CSS directives to document.styleSheets[document.styleSheets.length-1]

Could it be possible to call a similar function at any time?

Something like
obj.setStyle(selector, attribute, value);
Thierry Nivelet (FoxInCloud)
February 20,
I am not sure if this is a good idea. Modifying the stylesheet is a very expensive operation, basically IE re-renders all elements on the page after each update, so it might be extremely heavy. Also IE has a bug/feature where the content of the nested <table> tags in some cases does not get repainted after stylesheet modification - AW has to explicitly trigger repaint after changing the column width (just in case someone puts the grid into a table cell, for example, when using tables for page layout).
Alex (ActiveWidgets)
February 22,
Thanks Alex,

Understand your concern,

We'll do a similar implementation in our own javaScript
Thierry Nivelet (FoxInCloud)
February 23,

This topic is archived.

See also:

Back to support forum