Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
395
Why the extra 2 pixels in igtbl_isXHTML mode?
posted

In NetVantage_2008 CLR3X ASP.NET, in ig_WebGrid_dom.js, there is something that is screwing up my usage of the web grid control (I need finer control of the scrolling for Virtual mode) something fierce:

"getDefaultRowHeight",
function()
{
    var rh=igtbl_parseInt(this.Bands[0].DefaultRowHeight);
    if(!rh)
        rh=22;
    if(igtbl_isXHTML)
        rh+=2;
    return rh;
},

igtbl_isXHTML is set when the document.compatMode is "CSS1Compat, i.e. non "Quirks Mode".

The problem is that these two extra pixels that getDefaultRowHeight adds to the row height are not actually there in IE7. With a server-assigned default row height of 16, this function returns 18, but it is clear from a count of the rows on-screen that the row height is actually 16.

I tried looking at the Infragistics samples page to see if there were any issues from this, but the Infragistics ASP.NET samples page uses quirks mode, and thus would not trigger the extra two pixels.

(For those who want to see what mode a page uses, type this into the address bar after the web page loads, type javascript followed by a colon and then alert(document.compatMode)  )

What are these extra two pixels for? IE6? Firefox?

Is there any proper way to get rid of these? There are too many things using getDefaultRowHeight for me to just use igtbl_parseInt(this.Bands[0].DefaultRowHeight) everywhere I go.

Regards,

-- Ritchie Annand

Parents Reply Children