[CLOSED] [2.1] From panel field's width incorrect behaviour

  1. #1

    [CLOSED] [2.1] From panel field's width incorrect behaviour

    Hello.

    Please, review code sample below. It is looks like Width property sets width for field with label, not for field itself. For example, we set Width = 200 for combobox, which has LabelWidth = 95, LabelPad = 5, then width of the combobox would be (200 - 95 - 5) = 100. It seems for me like a bug.

    Is it a bug? Or this works as designed?
            <ext:FormPanel runat="server">
                <FieldDefaults>
                    <CustomConfig>
                        <ext:ConfigItem Name="LabelWidth" Value="120" Mode="Raw" />
                    </CustomConfig>
                </FieldDefaults>
                <Items>
                    <ext:ComboBox runat="server" Width="100" FieldLabel="Combo without container" />
                    <ext:FieldContainer runat="server" FieldLabel="Combo in container">
                        <Items>
                            <ext:ComboBox ID="ComboBox1" runat="server" Width="100" />
                        </Items>
                    </ext:FieldContainer>
                </Items>
            </ext:FormPanel>
    Best regards.
    Last edited by Daniil; Sep 04, 2012 at 12:36 PM. Reason: [CLOSED]
  2. #2
    No, it is designed behaviour. Field is not input element only, it is label, note, error messages, indicator and triggers
  3. #3
    Hi,

    Here is the Docs article about Width.
    http://docs.sencha.com/ext-js/4-1/#!...nent-cfg-width

    The width of this component in pixels.
    A FieldLabel is a part of the ComboBox component. So, the width of FieldLabel is a part of ComboBox Width.

    You can specify a width for an <input> part of the field setting the ComboBox InputWidth property.

    Please note this property was added just a few days ago.
    http://forums.ext.net/showthread.php...ll=1#post89482

    If it is absent in your dlls, please update from SVN or set it via CustomConfig.
  4. #4
    Thank you for clarification.

Similar Threads

  1. [CLOSED] Incorrect Grid Panel height when GridCommand with Icon is used
    By sailendra in forum 2.x Legacy Premium Help
    Replies: 6
    Last Post: Apr 27, 2012, 12:12 AM
  2. [CLOSED] Grid Panel : Column width (Auto width)
    By legaldiscovery in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Sep 24, 2011, 8:31 PM
  3. [CLOSED] Date Field shows incorrect day names
    By randy85253 in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Sep 30, 2010, 5:47 PM
  4. Replies: 2
    Last Post: Sep 28, 2010, 6:12 PM
  5. Replies: 6
    Last Post: Feb 22, 2010, 1:18 AM

Posting Permissions