You found a bug! We've classified it as EXTJSIV-8112 . We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
  1. #1
    Sencha User Daniil's Avatar
    Join Date
    Jun 2010
    Location
    Saint-Petersburg, Russia
    Posts
    678
    Vote Rating
    62
    Daniil is a jewel in the rough Daniil is a jewel in the rough Daniil is a jewel in the rough Daniil is a jewel in the rough

      0  

    Default [4.2b] Checkbox should ignore inputWidth

    [4.2b] Checkbox should ignore inputWidth


    REQUIRED INFORMATION

    Ext version tested:
    • Ext 4.2 beta
    Browser versions tested against:
    • Chrome
    • IE9
    DOCTYPE tested against:
    • <!DOCTYPE html>
    Description:
    • Probably, a Checkbox should ignore the inputWidth setting. I set up the inputWidth setting via FormPanel's fieldDefaults and a Checkbox is not rendered well. Please look at the screenshot.
    • Generally, I understand what happens and a workaround is easy - setting "inputWidth: 13" for a Checkbox. Just report to you. Maybe, you would like to fix it.
    Steps to reproduce the problem:
    • Just run the sample
    The result that was expected:
    • A common checkbox
    The result that occurs instead:
    • There is a group of four different checkboxes.
    Test Case:
    Code:
    <!DOCTYPE html>
    <html>
    <head>
        <title>Checkbox inputWidth</title>
    
        <link rel="stylesheet" href="../resources/css/ext-all.css" />
    
        <script src="../ext-all-debug.js"></script>
    
        <script>
            Ext.onReady(function () {
                Ext.create("Ext.form.Panel", {
                    renderTo: Ext.getBody(),
                    fieldDefaults: {
                        inputWidth: 90
                    },
                    items: [{
                        xtype: "checkbox"
                    }, {
                        xtype: "textfield"    
                    }]
                });
            });
        </script>
    </head>
    <body>
    </body>
    </html>
    HELPFUL INFORMATION

    Screenshot:


    1.JPG
    Ext.NET - ASP.NET for Ext JS
    MVC and WebForms
    Examples | Twitter

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    St. Louis, MO
    Posts
    33,599
    Vote Rating
    434
    mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.

    I do think that the developer should also make sure not to use it also. LIke this using your code

    Code:
    Ext.create("Ext.form.Panel", {
        renderTo      : Ext.getBody(),
        fieldDefaults : {
            inputWidth : 90
        },
        items         : [
            {
                xtype      : "checkbox",
                inputWidth : false
            },
            {
                xtype : "textfield"
            }
        ]
    });