-
18 Oct 2010 8:25 AM #1
how do I make a table layout's parent grow to hold the table's natural size?
how do I make a table layout's parent grow to hold the table's natural size?
I'm still missing something about layouts. Sometimes things grow to hold their children at their natural size, but other times children get truncated. Here's an example. I have a form with a fieldset using a table layout. The table layout does exactly what I want, but the parent clips it on the right edge rather than growing to hold the whole child.
Is there a setting for the parent or child to change this?
dialog.png
Code:var keyview = new Ext.form.FieldSet ( { title: 'sample field set', layout: 'table', layoutConfig: { columns: 5 }, items: [ {colspan: 5, xtype: "label", text: 'Long string of text that will wrap if necessary, thats ok and expected'}, {xtype: "button", text: 'Download file'}, {xtype: "button", text: 'Download file2'}, {xtype: "button", text: 'Upload file',}, {xtype: "button", text: 'View file'}, {xtype: "button", text: 'Test file'}, ] }); var panel = new Ext.FormPanel ( { labelAlign: 'right', frame:true, defaultType:'textfield', monitorValid:true, items: [ { fieldLabel:'field 1', }, { fieldLabel:'field 2', xtype: 'checkbox' }, keyview ] }); var win = new Ext.Window( { title:'Settings', closable: false, resizable: false, plain: true, border: false, items: [ panel ] }); win.show();
-
18 Oct 2010 9:45 AM #2
Code:var keyview = new Ext.form.FieldSet ({ title: 'sample field set', layout: 'table', autoWidth: true, layoutConfig: { columns: 5 }, items:[ {colspan: 5, xtype: "label", text: 'Long string of text that will wrap if necessary, thats ok and expected'}, {xtype: "button", text: 'Download file'}, {xtype: "button", text: 'Download file2'}, {xtype: "button", text: 'Upload file',}, {xtype: "button", text: 'View file'}, {xtype: "button", text: 'Test file'}, ] }); var panel = new Ext.FormPanel ({ labelAlign: 'right', frame:true, defaultType:'textfield', monitorValid:true, items:[{ fieldLabel:'field 1', }, { fieldLabel:'field 2', xtype: 'checkbox' }, keyview] }); new Ext.Window({ title:'Settings', border: false, items: panel }).show();Search the forum: http://www.google.com/coop/cse?cx=01...%3Az7of1ufqccu
Read the docs too: http://extjs.com/deploy/dev/docs/
Scope: http://extjs.com/forum/showthread.ph...642#post257642
Similar Threads
-
how to get size of table layout in a window or viewport
By jerrel in forum Ext 2.x: Help & DiscussionReplies: 0Last Post: 21 Mar 2010, 9:40 AM -
size of buttons in table layout
By TheMonolith in forum Ext 3.x: Help & DiscussionReplies: 3Last Post: 2 Mar 2010, 6:43 AM -
Layout is not fitting in the table(need to make the layout sit in <td>).
By sivaprasad in forum Ext 3.x: Help & DiscussionReplies: 0Last Post: 16 Nov 2009, 8:32 AM -
[FIXED] Table Layout / ComboBox - How to make them play nicely
By prgmmr in forum Ext 2.x: Help & DiscussionReplies: 2Last Post: 28 Sep 2009, 6:22 AM -
How to make XmlTablePage fit in full size of table panel
By budhimind in forum Ext GWT: Help & Discussion (1.x)Replies: 8Last Post: 3 Jul 2008, 12:28 AM


Reply With Quote