Hybrid View

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Ext GWT Premium Member
    Join Date
    Jan 2012
    Posts
    17
    Vote Rating
    1
    paucarre is on a distinguished road

      0  

    Default It is not possible to change cell styles

    It is not possible to change cell styles


    There is no way to change the cell styles of a grid. It is only possible to change the text styles, but not the whole cell.
    There is a way to change the whole cell style in the 2.x version as explained in:
    http://ui-programming.blogspot.com/2010/01/gxt-how-to-set-cell-grid-background.html
    You should use ColumnData class to modify the styles of the grid. This class exitsts in GXT 3.x but it is not accessible from the renderer. It is to say, the operation "public void render(Cell.Context context, C value, SafeHtmlBuilder sb)" of the class "PropertyDisplayCell<C>" cant access any instance of the class "ColumnData".
    Finally, is it not possible to change the styles of the whole cell as you only have access to the inner text. The only way to change the text style is to do something like:
    Code:
    @Override
    public void render(com.google.gwt.cell.client.Cell.Context context, T value, SafeHtmlBuilder safeHtmlBuilder) {
       safeHtmlBuilder.appendHtmlConstant("<span style='"+customStyle+"'>");
       super.render(context, value, safeHtmlBuilder);
       safeHtmlBuilder.appendHtmlConstant("</span>");
    }
    But, as said, it is not possible to change the whole cell style.
    In fact there is no usage of the class ColumnData:
    http://dev.sencha.com/deploy/gxt-3.0...olumnData.html

  2. #2
    Software Architect
    Join Date
    Sep 2007
    Posts
    13,971
    Vote Rating
    132
    sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light

      0  

    Default


    Doesnt the GridViewConfig object work for you?

  3. #3
    Ext GWT Premium Member
    Join Date
    Jan 2012
    Posts
    17
    Vote Rating
    1
    paucarre is on a distinguished road

      0  

    Default


    I have tried to return the styles using many formats following the comments of the interface but it seems not to work.
    For example, I tried: return "background-color:green;"; return "background-color:green"; return "{background-color:green;}";return "{background-color:green}";
    No one of them worked.

  4. #4
    Software Architect
    Join Date
    Sep 2007
    Posts
    13,971
    Vote Rating
    132
    sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light

      0  

    Default


    You need to return css classnames.

  5. #5
    Ext GWT Premium Member
    Join Date
    Jan 2012
    Posts
    17
    Vote Rating
    1
    paucarre is on a distinguished road

      1  

    Default


    I assume I have to return a list of class names and GXT will add that class names to the cells/rows. The problem I have is that I have to generate the styles in a dynamic way, so I cant define them in a static CSS file.

Thread Participants: 1

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi