IE vertical scroll bar when using a full DOCTYPE
Here's a link to show you what I'm referring to.
http://saratogahomeowners.com/Ext-Samples/test-with-doctype.html
You'll have to be using IE 6 to see this. It works fine in FF and I'm not sure about IE 7.
Here's my two fixes.
Fix 1 - add a css rule of html {overflow-y: hidden}
http://saratogahomeowners.com/Ext-Samples/test-with-doctype-fix1.html
Fix 2 - remove the url from the doctype
http://saratogahomeowners.com/Ext-Samples/test-with-doctype-fix2.html
I like Fix 1 since there are some doctypes that I don't have control over and thus can't modify. Also, if you remove the url, doesn't the rendering revert to quirks mode???
What I don't like about Fix 1 is that there will be cases where I'm not using a BorderLayout in document.body and thus I would loose the vertical scrollbar if I add this rule globally. So my question is this: Can Ext handle this for us? And dynamically set the overflow-y to hidden if you are using IE and you have a BorderLayout defined for document.body?
In LayoutManager.js I see this snippet of code:
// ie scrollbar fix
if(this.el.dom == document.body && Ext.isIE){
document.body.scroll = "no";
Is there a way to also set the overflowY on the element? Would document.documentElement.style.overflowY = "hidden" do it?
I'll just make sure to document for my development team to add that extra piece of css for any pages that use a full doctype AND they are creating a borderlayout in document.body.
This also might be a good thing to add in the FAQs, don't you think? I know I spent a good little while tracking down why some of our pages that used the same borderlayout code worked and others didn't.
Plus, I can't add these rules to a global stylesheet we have for our apps since not every page will need a BorderLayout and not all will need it in document.body.
What do you think?
// ie scrollbar fix
if(this.el.dom == document.body && Ext.isIE){
document.body.scroll = "no";
document.documentElement.style.overflow = "hidden"
}
So, now I have fix3 that uses the above modification to Ext.LayoutManager.
To see this fix click here (http://saratogahomeowners.com/Ext-Samples/test-with-doctype-fix3.html)
html, body {
margin:0;
padding:0;
border:0 none;
overflow:hidden;
height:100%;
}
#If you have any other info about this subject , Please add it free.# |

