Ext


Go Back   Ext JS Forums > Ext JS Community Forums (2.0) > Ext 2.x: Help

Reply
 
Thread Tools
  #1  
Old 09-18-2008, 12:52 AM
mattsheppard mattsheppard is offline
Ext User
 
Join Date: Apr 2008
Posts: 3
mattsheppard is on a distinguished road
Default Width issue with Ext.Panel bbar in IE 6

Hi all,

I've just run into a display glitch in IE6 - Hopefully someone can point me in the right direction.

In the following example, the bbar for the panel is displayed 2ems narrower than the panel it is attached to (it's left aligned) in IE6, where as in Firefox it is displayed as the same width as the panel.

Can anyone suggest how to fix this?

I seem to be able to work around either by specifying the width of the panel in ems or the padding in pixels, but I assume it would be expected to work as I have it below.

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <link rel="stylesheet" type="text/css" href="ext/resources/css/ext-all.css"/>
    <script type="text/javascript" src="ext/ext-base.js"></script>
    <script type="text/javascript" src="ext/ext-all-debug.js"></script>
    <script type="text/javascript">

    Ext.onReady(function(){        
        var main = new Ext.Panel({
            renderTo: 'content',
            bodyStyle: 'padding: 1em;',
            width: 500,
            html: "Alignment issue in IE - The bbar's width is 2ems less than the main panel in IE6.",
            bbar: [
                    "->",
                {id: "continue", text: 'Continue'}
            ]
        });
    });
    
    </script>
</head>
<body>
    <div id="content"></div>
</body>
</html>
Reply With Quote
  #2  
Old 06-25-2009, 03:22 PM
jsmitty jsmitty is offline
Ext User
 
Join Date: Oct 2007
Posts: 1
jsmitty is on a distinguished road
Default Question answered elsewhere

The author posted this question at Stack Overflow and received an answer there.

http://stackoverflow.com/questions/9...l-bbar-in-ie-6
Reply With Quote
  #3  
Old 06-25-2009, 03:32 PM
Animal's Avatar
Animal Animal is offline
Ext JS - Community Support Team
 
Join Date: Mar 2007
Location: East Midlands, UK
Posts: 23,352
Animal will become famous soon enough
Default

You cannot use any other units than px

Ext has no way of calculating the exact size for the body because there's no way of knowing how big the margin is.

If you use eg "10px", I think it will work.
__________________
ExtJs forum volunteer. No official connection to the Ext Company. I do not speak for them.
ExtJs consultancy offered. £ 50/hour. Evenings+weekends. the_bagbournes@btinternet.com

Search the forum: http://www.google.com/coop/cse?cx=01...%3Az7of1ufqccu
Read the docs too: http://extjs.com/deploy/dev/docs/
See Saki's samples: http://examples.extjs.eu/
Build your own Ext: http://extjs.com/products/extjs/build/
Scope: http://extjs.com/forum/showthread.ph...642#post257642
Reply With Quote
  #4  
Old 06-25-2009, 03:37 PM
tryanDLS tryanDLS is offline
Ext JS - Community Support Team
 
Join Date: Mar 2007
Posts: 7,371
tryanDLS is on a distinguished road
Default

Looks to be caused by the loose doctype - try running without.
__________________
Tim Ryan - Ext JS Support Team
Read BEFORE posting a question / BEFORE posting a Bug
Use Google to Search - API / Forum
API Doc (3.x | 2.x | 1.x) / FAQ / Wiki / Tutorials / 1.x->2.0 Migration Guide
Reply With Quote
Reply

Thread Tools

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

All times are GMT -5. The time now is 09:58 PM.

© 2006-2009 Ext, LLC
Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.