Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
114
rated 0 times [  121] [ 7]  / answers: 1 / hits: 17875  / 15 Years ago, wed, november 11, 2009, 12:00:00

I've created Ext.Window with some Ext.form fields inside. But when I resize window form elements still have initial width and height.



Is it required explicitly resize form fields on window resize? Or there is some option that enables auto resize of form fields?



Sample code:



var f_1 = new Ext.form.TextField({fieldLabel: 'Label 1'});
var f_2 = new Ext.form.TextField({fieldLabel: 'Label 2'});
var fp = new Ext.form.FormPanel({items: [f_1, f_2]});

var w = new Ext.Window({
layout: 'form',
title: 'test',
items: fp
});

w.show()

More From » extjs

 Answers
2

You could check out anchoring, which makes for nicely-resizable forms:



http://www.extjs.com/deploy/dev/examples/form/anchoring.html



See the anchor property on Component:



http://www.extjs.com/deploy/dev/docs/?class=Ext.Component


[#98337] Saturday, November 7, 2009, 15 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
draven

Total Points: 641
Total Questions: 101
Total Answers: 110

Location: Nicaragua
Member since Mon, Sep 26, 2022
2 Years ago
;