On Mon, Mar 3, 2008 at 12:54 PM, Ben Tomasini <[EMAIL PROTECTED]> wrote:
> Ooops, Hit enter too soon.  Here is a resend
>
>
>  I am trying to use the Grid component to render an HTML table with
>  very specific CSS to make the table look like a table which is
>  currently being rendered with the displaytag library in a Struts2
>  application.  Our current style sheet uses CSS selectors based on the
>  simple element name without any classes.  This works well with
>  displaytag as it's default behavior is to output a simple table
>  without any CSS classes.
>
>  I am having two issues:
>
>  1) Applying styles.
>
>  My preference  would like to simply apply our existing styles to an
>  HTML table created by Tapestry without having to wrestle with the
>  default styles in place.  I looks like Tapestry's Grid component
>  specifies a total of 23 CSS attributes among its various styles for
>  the Grid and related components.  I know we can override these
>  attributes in our stylesheets, but this puts a rather annoying burden
>  on our CSS developer.  Another option would be to remove the default
>  tapestry stylesheet via application configuration, but this would have
>  negative side effects for other components such as the exception page.
>   Is there a way to have the Grid component not render any style
>  classes or to use style classes we specify?  Any other ideas would be
>
> appreciated.

This should be easier, but currently is not.

One option would be to subclass Grid as, say, PlainGrid.

You could then provide a PlainGrid.tml file and remove the @class
attributes that are in place there.

>
>  2) Changing pager display
>
>  Is there a way to override the rendering of the pager, perahaps by
>  specifiying an alternate block to use?
>
>  With these in mind, am I better off not using the Grid component and
>  creating my own Table component instead?
>
>  Ben
>
>

You could use pagerposition="none" and supply your own component to
perform the paging.

>
>
>
>  On Mon, Mar 3, 2008 at 12:49 PM, Ben Tomasini <[EMAIL PROTECTED]> wrote:
>  > I am trying to use the Grid component to render an HTML table with
>  >  very specific CSS to make the table look like a table which is
>  >  currently being rendered with the displaytag library in a Struts2
>  >  application.  Our current style sheet uses CSS selectors based on the
>  >  simple element name without any classes.  This works well with
>  >  displaytag as it's default behavior is to output a simple table
>  >  without any CSS classes.
>  >
>  >  I am having two issues:
>  >
>  >  1) Applying styles.
>  >
>  >  My preference  would like to simply apply our existing styles to an
>  >  HTML table created by Tapestry without having to wrestle with the
>  >  default styles in place.  I looks like Tapestry's Grid component
>  >  specifies a total of 23 CSS attributes among its various styles for
>  >  the Grid and related components.  I know we can override these
>  >  attributes in our stylesheets, but this puts a rather annoying burden
>  >  on our CSS developer.  Another option would be to remove the default
>  >  tapestry stylesheet via application configuration, but this would have
>  >  negative side effects for other components such as the exception page.
>  >   Is there a way to have the Grid component not render any style
>  >  classes?  Any other ideas would be appreciated.
>  >
>  >  2) Changing pager display
>  >
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: [EMAIL PROTECTED]
>  For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to