center aligned header labels are a bit towards right aligned


When I center align a header label, the label is not properly centered. Its a bit towards right. So when I start reducing the column width even though there are spaces in left side but the label reaches to the end of right and starts to wrap the text. I’m using dhtmlx grid v.1.5 build 71114.

Thanks in Advance

Which way you are using to center text inside headers.
Attached sample uses third parameter of setHeader command for such tasks, and result view correctly rendered without any shifting to left or right

Some skins ( such as “modern” for example ) have default padding for header cells, which can cause similar effect.
You can remove|change padding settings in dhtmlxgrid.css

div.gridbox_modern table.hdr td div.hdrcell{
    padding-left:10px;   //<= this is it (90 KB)