You are viewing a plain text version of this content. The canonical link for it is here.
Posted to adffaces-dev@incubator.apache.org by Günther, Thorsten <Th...@medocino.de> on 2006/10/13 13:38:46 UTC

[Proposal] Always render navigation controls in tr:table if "rows" attribute > 0

Hi!

Today the table's navigation controls for pagination are only rendered if the number of rows in the model is bigger then the number of rows currently displayed in the table. So when the number of rows in the model changes the table moves up and down when the control bar is rendered or not rendered.

I would prefer to have the navigation controls and therefore the control bar always rendered if I have decided to enable paging on a table by setting "rows" to a value greater then 0.

Today the default value for "rows" seems to be 25, which IMHO is arbitrary (and not documented in the tagdoc) and prevents from check via component.getAttributes().get("rows") if the page developer wanted to activate paging or not. If tr:table should paginate by default the tagdoc should be clear about that one has to set "rows" to 0 to disable paginating. Then, if paginating is not explicitly disabled, the navigation controls should IMO always be rendered to show the ability to paginate, to show the number of displayed rows and to prevent the table from moving up and down.

What do you think?

Regards,
Thorsten



Re: [Proposal] Always render navigation controls in tr:table if "rows" attribute > 0

Posted by Arjuna Wijeyekoon <ar...@gmail.com>.
the number of rows to display per page, and whether or not you want the
paging controls all the time are two separate things that should not be
bundled into one attribute.
I like Adam's proposal for a skinning property to control the latter.
--arjuna

On 10/13/06, Adam Winer <aw...@gmail.com> wrote:
>
> A couple things here:
> - Clearly +1 to documenting the default for "rows"
> - Maybe we should add a skinning property for whether the nav controls
> should always be visible even when only one page is visible?
>
> -- Adam
>
>
> On 10/13/06, Günther, Thorsten <Th...@medocino.de> wrote:
> > Hi!
> >
> > Today the table's navigation controls for pagination are only rendered
> if the number of rows in the model is bigger then the number of rows
> currently displayed in the table. So when the number of rows in the model
> changes the table moves up and down when the control bar is rendered or not
> rendered.
> >
> > I would prefer to have the navigation controls and therefore the control
> bar always rendered if I have decided to enable paging on a table by setting
> "rows" to a value greater then 0.
> >
> > Today the default value for "rows" seems to be 25, which IMHO is
> arbitrary (and not documented in the tagdoc) and prevents from check via
> component.getAttributes().get("rows") if the page developer wanted to
> activate paging or not. If tr:table should paginate by default the tagdoc
> should be clear about that one has to set "rows" to 0 to disable paginating.
> Then, if paginating is not explicitly disabled, the navigation controls
> should IMO always be rendered to show the ability to paginate, to show the
> number of displayed rows and to prevent the table from moving up and down.
> >
> > What do you think?
> >
> > Regards,
> > Thorsten
> >
> >
> >
>

Re: [Proposal] Always render navigation controls in tr:table if "rows" attribute > 0

Posted by Adam Winer <aw...@gmail.com>.
A couple things here:
- Clearly +1 to documenting the default for "rows"
- Maybe we should add a skinning property for whether the nav controls
should always be visible even when only one page is visible?

-- Adam


On 10/13/06, Günther, Thorsten <Th...@medocino.de> wrote:
> Hi!
>
> Today the table's navigation controls for pagination are only rendered if the number of rows in the model is bigger then the number of rows currently displayed in the table. So when the number of rows in the model changes the table moves up and down when the control bar is rendered or not rendered.
>
> I would prefer to have the navigation controls and therefore the control bar always rendered if I have decided to enable paging on a table by setting "rows" to a value greater then 0.
>
> Today the default value for "rows" seems to be 25, which IMHO is arbitrary (and not documented in the tagdoc) and prevents from check via component.getAttributes().get("rows") if the page developer wanted to activate paging or not. If tr:table should paginate by default the tagdoc should be clear about that one has to set "rows" to 0 to disable paginating. Then, if paginating is not explicitly disabled, the navigation controls should IMO always be rendered to show the ability to paginate, to show the number of displayed rows and to prevent the table from moving up and down.
>
> What do you think?
>
> Regards,
> Thorsten
>
>
>