1. #1
    Ext GWT Premium Member
    Join Date
    Dec 2010
    Posts
    12
    Vote Rating
    0
    christiedavel is on a distinguished road

      0  

    Default Unanswered: DrawComponent in grid

    Unanswered: DrawComponent in grid


    I want to draw an image with DrawComponent and add that to a grid. Is it possible? I can't find something like a DrawComponentCell in order to do the rendering of the drawComponent.

  2. #2
    Sencha - GXT Dev Team BrendanC's Avatar
    Join Date
    Aug 2010
    Posts
    534
    Answers
    3
    Vote Rating
    3
    BrendanC is on a distinguished road

      0  

    Default


    No there is no draw cell and it is probably to complex a component to be made a cell. What are you trying to do exactly?

  3. #3
    Ext GWT Premium Member
    Join Date
    Dec 2010
    Posts
    12
    Vote Rating
    0
    christiedavel is on a distinguished road

      0  

    Default


    I need to display an icon in a grid. The icon is not complex but the color must be unique for each row in the grid. Currently I create the icon on server side based on the color parameters I pass in via a URL and then I render the icon in the grid via an ImageCell. This is a bit slow. I thought that drawing the icon on the client side might be faster.

  4. #4
    Sencha - GXT Dev Team BrendanC's Avatar
    Join Date
    Aug 2010
    Posts
    534
    Answers
    3
    Vote Rating
    3
    BrendanC is on a distinguished road

      0  

    Default


    Yeah even if there was something like draw component cell having a draw component surface for each icon would become very taxing. Unfortunately I don't think the draw package can help you in this situation.

  5. #5
    Sencha User PhiLho's Avatar
    Join Date
    Nov 2011
    Location
    Near Paris, France
    Posts
    139
    Answers
    2
    Vote Rating
    1
    PhiLho is on a distinguished road

      0  

    Default


    A classical trick in Web design is to transmit only one image with several widgets (the trick is used by Sencha in their menu icons, among others).
    Perhaps you can make the server to draw all the icons you need (for a given view) in a single image (in a row or in a column) and use the image as background of a span, with CSS selecting the position and size of the background with regard to the span area. Thus, only the selected image is displayed. Never tried this in GWT, though... Perhaps it offers facilities for this functionality (I guess so).

  6. #6
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,634
    Answers
    107
    Vote Rating
    80
    Colin Alworth is just really nice Colin Alworth is just really nice Colin Alworth is just really nice Colin Alworth is just really nice Colin Alworth is just really nice

      0  

    Default


    Another idea, if just the color needs to be changed of part of the icon, is to use an image with transparency set for part of it, and always draw the same image, but with a different background color each time.

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar