0 Replies Latest reply on Apr 30, 2008 4:41 PM by E Aish

    Help with the Richfaces stylesheet

    E Aish Novice

      Hi,

      Can you please help/guide me with the following:

      I have implemented rich:dataTable and rich:scrollabledataTable in my new web application. The header font styles, colors, etc are different for both these tags. I would like to have them the same styles so that it gives a consistent look and feel to the users.


      can you please guide me to implement the customized stylesheet? Please let me know if you need additional information to help me with this.

      I tried two things given as below and none of them worked.. Can you please let me know what am I missing?

      Thanks
      Aish

      (1) Modified the style for the header class .rich-sdt-header-row as follows and the scrollabledatatable was displayed without taking any effect from this .rich-sdt-header-row.



      <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
      <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
      <%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
      <%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>

      .rich-sdt-header-row (This is enclosed within script type="text/css" and /script tag. for some reason, it is not displaying the <> characters properly)

      {
      background-color:#BED6F8;
      font-size:11px;
      font-style:italic;
      }


      <rich:scrollableDataTable rowKeyVar="rkv"
      height="150px" first="0"
      width="740px" value="#{TableDetail.displayinfo}"
      var="dirinfo" sortMode="single"
      focus="dirinfo" id="dirinfo"
      headerClass="myHeaderClass">
      ...
      ...
      </rich:scrollableDataTable>


      (2) Created a new class named".myHeaderClass" and used this class as the headerClass in the scrollabledataTable. There is no change in the display:

      <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
      <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
      <%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
      <%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>

      .myHeaderClass (This is enclosed within script type="text/css" and /script tag. for some reason, it is not displaying the <> characters properly)

      {
      background-color:#BED6F8;
      font-size:11px;
      font-style:italic;
      }
      <rich:scrollableDataTable rowKeyVar="rkv"
      height="150px" first="0"
      width="740px" value="#{TableDetail.displayinfo}"
      var="dirinfo" sortMode="single"
      focus="dirinfo" id="dirinfo"
      headerClass="myHeaderClass">
      ...
      ...
      </rich:scrollableDataTable>



      Thanks
      Aish