[CLOSED] [1.0] Window/form resize and buttonalign issue

  1. #1

    [CLOSED] [1.0] Window/form resize and buttonalign issue

    It's me again ;-)

    Code:

    <ext:Window ID="windowEdit" AutoShow="false" Modal="true" Hidden="true" runat="server" Icon="ApplicationEdit" Width="440" AutoHeight="true" BodyStyle="padding:5px;" Title="Edit Details" >
        <Items>
            <ext:FormPanel ID="formpanelEdit" runat="server" ButtonAlign="Right" Layout="Form" Border="true" Padding="0" AutoHeight="true">
                <Items>
                    <ext:TabPanel runat="server" Border=false>
                        <Items>
                            <ext:Panel runat="server" ID="memberEditPanelGeneral" Title="General" Padding="5" AutoHeight="true" Layout="Form">
                                <Items>
                                    <ext:Hidden runat="server" ID="GUID"></ext:Hidden>
                                    <ext:TextField runat="server" ID="FirstName" FieldLabel="Firstname"></ext:TextField>
                                    <ext:TextField runat="server" ID="LastName" FieldLabel="Lastname"></ext:TextField>
                                </Items>
                            </ext:Panel>
                            <ext:Panel runat="server" ID="memberEditPanelContent" Title="Content" Padding="5" AutoHeight="true" Layout="Form">
                                <Items>
                                    <ext:Hidden runat="server" ID="Hidden1"></ext:Hidden>
                                </Items>
                            </ext:Panel>
                        </Items>
                        <Listeners>
                            <TabChange Handler="#{windowEdit}.syncSize();" />
                        </Listeners>
                    </ext:TabPanel>
                </Items>
                <Buttons>
                    <ext:Button ID="buttonSaveButton" runat="server" Text="Save" Icon="Disk" Type="Submit">
                    </ext:Button>
                    <ext:Button ID="buttonCancelButton" runat="server" Text="Cancel" Icon="Cancel">
                    </ext:Button>
                </Buttons>
            </ext:FormPanel>
        </Items>
        <Listeners>
            <Show Handler="#{FirstName}.focus();" Delay="40" />
        </Listeners>
    </ext:Window>
    When I resize the window, everything resizes well, but the buttons in the buttons collection from the formpanel remain on the same place, allthough buttonalign=right is stated.

    Thanks for the help.
  2. #2

    RE: [CLOSED] [1.0] Window/form resize and buttonalign issue

    Hi,

    If you're using the latest SVN, this may be related to some layout logic changes currently working their way through development.


    I was able to work-around the problem by removing AutoHeight="true" from the formpanelEdit <ext:FormPanel>.


    Geoffrey McGill
    Founder
  3. #3

    RE: [CLOSED] [1.0] Window/form resize and buttonalign issue

    Here's a full .aspx sample to test with.

    Example

    <%@ Page Language="C#" %>
    
    <%@ Register assembly="Ext.Net" namespace="Ext.Net" tagprefix="ext" %>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    
    <html xmlns="http://www.w3.org/1999/xhtml" >
    <head runat="server">
        <title>Ext.NET Example</title>
    </head>
    <body>
        <form runat="server">
            <ext:ResourceManager runat="server" />
            
            <ext:Window 
                ID="Window1" 
                Modal="true" 
                runat="server" 
                Width="440" 
                AutoHeight="true" 
                Padding="5"
                Title="Edit Details">
                <Items>
                    <ext:FormPanel 
                        runat="server" 
                        ButtonAlign="Right" 
                        Layout="Form" 
                        Border="true" 
                        Padding="0">
                        <Items>
                            <ext:TabPanel runat="server" Border="false">
                                <Items>
                                    <ext:Panel 
                                        runat="server" 
                                        Title="General" 
                                        Padding="5" 
                                        AutoHeight="true" 
                                        Layout="Form">
                                        <Items>
                                            <ext:Hidden runat="server" />
                                            <ext:TextField runat="server" FieldLabel="Firstname" />
                                            <ext:TextField runat="server" FieldLabel="Lastname" />
                                        </Items>
                                    </ext:Panel>
                                    <ext:Panel 
                                        runat="server" 
                                        Title="Content" 
                                        Padding="5" 
                                        AutoHeight="true" 
                                        Layout="Form">
                                        <Items>
                                            <ext:Hidden runat="server" />
                                        </Items>
                                    </ext:Panel>
                                </Items>
                                <Listeners>
                                    <TabChange Handler="#{Window1}.syncSize();" />
                                </Listeners>
                            </ext:TabPanel>
                        </Items>
                        <Buttons>
                            <ext:Button runat="server" Text="Save" Icon="Disk" Type="Submit" />
                            <ext:Button runat="server" Text="Cancel" Icon="Cancel" />
                        </Buttons>
                    </ext:FormPanel>
                </Items>
            </ext:Window>
        </form>
    </body>
    </html>
    Hope this helps.

    Geoffrey McGill
    Founder

Similar Threads

  1. Coolite 0.8.2 - Resize form
    By schrovena in forum 1.x Help
    Replies: 14
    Last Post: Oct 02, 2012, 6:12 PM
  2. [1.0] Resize window containing form
    By danielg in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Nov 17, 2009, 3:39 AM
  3. [CLOSED] Center window on window resize
    By CSG in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: May 29, 2009, 5:05 AM
  4. form controls resize
    By [WP]joju in forum 1.x Help
    Replies: 8
    Last Post: Mar 09, 2009, 5:15 AM
  5. Form inside window reset issue
    By sz_146 in forum 1.x Help
    Replies: 0
    Last Post: Feb 03, 2009, 12:50 PM

Posting Permissions