3 Replies Latest reply on Jul 22, 2010 4:48 AM by ilya_shaikovsky

    RichFaces Skin and background-image

    zhyuhong

      I am happy with the out of box skin, let's say "blueSky".  Now all I want to do are,

      1. make all my buttons the same fixed width.

      2. give each of my button a different icon.

       

      What is the best way to accomplish this?

        • 1. Re: RichFaces Skin and background-image
          nbelaevski

          Hi,

           

          >> 1. make all my buttons the same fixed width.

           

          The safest way is to assign some CSS class to all buttons and do customization via it. If IE6 doesn't need to be supported, you can try

          CSS attribute selectors like this:

           

          input[type=button], input[type=submit], etc...

           

          >> 2. give each of my button a different icon.

          Again, custom CSS class for each type of the icon and background image assigned or via page code.


          • 2. Re: RichFaces Skin and background-image
            zhyuhong

            Thanks Nick.  I gave up on the button icon.  But I did set the button size be defining a style class in css and let all my buttons use that styleClass.  I am good for now

             

            I am still not so sure how the whole skin thing work exactly.   Why cannot I set the button width in the .xcss file to get it to work without creating a new style class?

            • 3. Re: RichFaces Skin and background-image
              ilya_shaikovsky

              Hi Yuhong Zhang !

               

              Nick mentioned separate styleClass in order to support IE 6. If you not need such support - you could leave with selectors like he mentioned. That will save class assignment work for you.