|Re: RAP rowTemplates changing dynamically [message #1211665 is a reply to message #1208998]
||Tue, 26 November 2013 15:01
| Tim Buschtoens
Registered: July 2009
Am 25.11.2013 10:31, schrieb John Gymer:
> Currently it appears that once a Table/Tree's rowTemplate is defined it
> cannot be changed without disposing the entire Table/Tree and recreating
That is correct.
> Is this something that has been considered for future enhancement, or
> have I missed something?
Not very likely. This limitation was initially put into place due to
some restrictions on iOS (Tabris), and much of the implementation for
the WebClient was also done with this in mind. I also think that
changing the template during the widgets lifetime could easily lead to
some bad code and that it should not be necessary. If there is some
effect that can't be achieved without changing the template, then it
would be better for us to improve the template feature so it can be done
> I can imagine a very common requirement to change the layout dynamically
> based on the Table's width e.g. when device is rotated, or when browser
> is resized - you may wish to attach a column to the right side, or to
> grow the size of a column if the width of the Table increases. Some
> columns may be good to track to left or right edge, and others may work
> better using percentages etc.
You can already layout cells relative to tables the right side, either
setting width and right, or left and right. We also have some ideas (no
definite plans) to make layouting more flexible by attaching cells to
other cells or possibly using percentages. We will also very likely
introduce column templates as an alternative to row templates. Those
would work the same way, but not use the entire width of a row, but only
that of a column (which can be changed in width). Another idea we have
is to allow creating custom cell types. It's already possible to use row
templates together with the markup feature, though you loose some
single-sourcing capability if you do that.
I hope this gives you an idea in what direction we are heading.
Professional services for RAP and RCP?
Powered by FUDForum
. Page generated in 0.04793 seconds