3.2.0

Problem with borders

I've been trying to put a red border around a cell which contains invalid data. I created a CSS class and assigned it to the cell in question, and it gets assigned properly. However, the bottom border doesn't show up because I believe the extra width of the border is "pushing" the bottom border down and making it invisible. I experimented with padding and margins, but haven't been able to resolve this.
I am sure someone else must have encountered this problem at some point, so if so, please help a brother out!
Thanks!
Alan
October 30,
It seems like you are using DOCTYPE which triggers 'standards-compliant' box model. In this case when you add borders you should reduce padding for the same amount so the total width/height does not change. Normal grid cell padding in 'standards-compliant' mode is 0px 4px 4px 4px, so after adding 1px border it should become 0px 3px 2px 3px -

#myGrid-cell-1-1 {
    border: 1px solid red;
    padding: 0px 3px 2px 3px;
}
Alex (ActiveWidgets)
October 31,
Ahhh...took the easy way out and removed the DOCTYPE. Works like a charm. Thanks for the quick response!
Alan
October 31,

This topic is archived.

See also:


Back to support forum