This is a migrated thread and some comments may be shown as answers.

GridCheckBoxColumn problem with row height

3 Answers 106 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Steve Newbery
Top achievements
Rank 1
Steve Newbery asked on 11 Jun 2008, 02:39 PM
I have a GridCheckBoxColumn in my grid, but the problem is that it forces the height of the rows to 28px, instead of the normal 21px - this is with the Office2007 skin.

So, I tried to change the default 4px top and bottom padding of the skin, by specifying a special css class for the row item, bit it doesn't use my padding.

In the documentation it mentions that for this to work I have to specify skin="", which would not be good as then I lose the rest of the styling.

So it seems that the only way is to create a custom skin, and make it non-embedded, ie like the "old" way.
 
Isn't there a simpler way to override the padding in a row?

Thanks, Steve

3 Answers, 1 is accepted

Sort by
0
Steve Newbery
Top achievements
Rank 1
answered on 13 Jun 2008, 08:23 AM
Ok, I found the solution, which is to use "!important" in my css to override the skin:

So in my aspx:

<MasterTableView   
ItemStyle-CssClass="myGridItemStyle">   
 

then in the stylesheet:

.myGridItemStyle td  
{  
    padding-top: 0px !important;  
    padding-bottom: 0px !important;  
}  
 

And voila! This is cool, and means I can override the embedded skins without changing them.

Might it be a good idea to include this trick in the documentation?

Steve
0
Sebastian
Telerik team
answered on 13 Jun 2008, 08:31 AM
Hello Steve,

Thank you for the feedback - I will forward it to our documentation team to be considered for the future versions of the product.

Best regards,
Stephen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Ed Bassin
Top achievements
Rank 1
answered on 24 Jul 2008, 01:31 PM
Thanks Steve!  This is the exact problem I just ran into.
Tags
Grid
Asked by
Steve Newbery
Top achievements
Rank 1
Answers by
Steve Newbery
Top achievements
Rank 1
Sebastian
Telerik team
Ed Bassin
Top achievements
Rank 1
Share this question
or