Hybrid View
-
17 Nov 2012 4:40 AM #1
Answered: [4.1.1] How to align textfield with combobox/datefield?
Answered: [4.1.1] How to align textfield with combobox/datefield?
Textfield isn't aligned with combobox/datefield:
http://jsfiddle.net/ZgcAS/1/Code:Ext.onReady(function() { Ext.QuickTips.init(); Ext.create("Ext.window.Window", { title: "Test Ext.layout.container.Anchor", autoShow: true, layout: "fit", border: 0, items:[{ xtype: "form", frame: true, bodyStyle: "padding: 5px 0 0 0", items: [{ xtype: "textfield", fieldLabel: "textfield", anchor: "100%" }, { xtype: "combobox", fieldLabel: "combobox", anchor: "100%" }, { xtype: "datefield", fieldLabel: "datefield", anchor: "100%" }] }] }); });
P.S. BTW, textfield is aligned if window will be resized.
-
Best Answer Posted by sword-it
Hi Ext_soft,
Give width config to the window container.
-
17 Nov 2012 4:52 AM #2Sencha - Community Support Team
- Join Date
- May 2012
- Location
- Istanbul
- Posts
- 1,331
- Vote Rating
- 76
- Answers
- 124
Hi Ext_soft,
Give width config to the window container.sword-it.com, Sencha Developer House in Turkey - Istanbul University Technopark Suite 204.
-
17 Nov 2012 4:56 AM #3
Try this:
Code:Ext.onReady(function(){ Ext.create("Ext.window.Window", { title: "Test Ext.layout.container.Anchor", autoShow: true, layout: "fit", border: 0, items:[{ xtype: "form", frame: true, bodyStyle: "padding: 5px 0 0 0", layout: { type: 'vbox', align: 'stretch' }, items: [{ xtype: "textfield", fieldLabel: "textfield", //anchor: "100%" }, { xtype: "combobox", fieldLabel: "combobox", //anchor: "100%" }, { xtype: "datefield", fieldLabel: "datefield", //anchor: "100%" }] }] }); });
-
17 Nov 2012 6:03 AM #4


Reply With Quote
