-
5 Dec 2011 6:09 AM #1Sencha Premium Member
- Join Date
- Feb 2009
- Location
- Amsterdam, The Netherlands
- Posts
- 217
- Vote Rating
- 2
[HELP] - Table Layout width of children
[HELP] - Table Layout width of children
Hi All,
I'm trying a very small example with table layout (it needs to be this because the client will configure it) and it seems like the panels inside don't share the same width amongst them.
This produces the following:Code:var newPanel = new Ext.Panel({ title : 'Test', layout : 'table', defaults : { bodyStyle : 'height: 250px' }, layoutConfig : { columns : 2, rows : 1, tableAttrs : { style : { width : '100%' } } }, items: [ { xtype: 'panel', title: 'Test 1' }, { xtype: 'panel', title: 'Test 21111111111' } ] });
test.jpg
So instead of sharing the same width it seems like the second panel gets much more width because the title is bigger.
I cannot set the width manually because I want it to resize properly and as said before I cannot change the layout to vbox and hbox.
Can someone help me here?
Thanks!
-
5 Dec 2011 2:18 PM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,714
- Vote Rating
- 438
That's because the items don't have a width. You have to specify a width.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
5 Dec 2011 2:19 PM #3Sencha Premium Member
- Join Date
- Feb 2009
- Location
- Amsterdam, The Netherlands
- Posts
- 217
- Vote Rating
- 2
Correct, but I wanted the width to be dynamic, similar to what is there in hbox/vbox and to resize properly.
Isn't this possible?
-
5 Dec 2011 2:23 PM #4Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,714
- Vote Rating
- 438
Not in table layout.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.


Reply With Quote