# HG changeset patch # User Ingo Weinzierl # Date 1306929599 0 # Node ID fea93eebd2fa0e25d50db601ed503aa80a0eb06f # Parent 75df5722010462abddd142ae371a65a7dd9e2402 Improved the layout of the mouse position panel. flys-client/trunk@2039 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 75df57220104 -r fea93eebd2fa flys-client/ChangeLog --- a/flys-client/ChangeLog Wed Jun 01 09:03:18 2011 +0000 +++ b/flys-client/ChangeLog Wed Jun 01 11:59:59 2011 +0000 @@ -1,3 +1,12 @@ +2011-06-01 Ingo Weinzierl + + * src/main/java/de/intevation/flys/client/client/ui/chart/ChartToolbar.java: + Moved the mouse position panel to the right border of the toolbar panel. + + * src/main/java/de/intevation/flys/client/client/ui/chart/MousePositionPanel.java: + Improved the layout of this HLayout panel. It has a fixed width of 195px + now. The components inside this panel have also fixed width values. + 2011-06-01 Ingo Weinzierl * src/main/java/de/intevation/flys/client/client/ui/chart/ChartOutputTab.java: diff -r 75df57220104 -r fea93eebd2fa flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/ChartToolbar.java --- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/ChartToolbar.java Wed Jun 01 09:03:18 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/ChartToolbar.java Wed Jun 01 11:59:59 2011 +0000 @@ -71,12 +71,10 @@ setPadding(5); setBorder("1px solid black"); - // TODO do this dynamic Label spacer = new Label(); - spacer.setWidth("100px"); + spacer.setWidth("*"); datacage.setWidth("95px"); position.setWidth("200px"); - position.setLayoutAlign(com.smartgwt.client.types.Alignment.RIGHT); addMember(datacage); addMember(spacer); diff -r 75df57220104 -r fea93eebd2fa flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/MousePositionPanel.java --- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/MousePositionPanel.java Wed Jun 01 09:03:18 2011 +0000 +++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/chart/MousePositionPanel.java Wed Jun 01 11:59:59 2011 +0000 @@ -42,24 +42,32 @@ /** - * Initializes the layout of this component. + * Initializes the layout of this component. Note: This layout has a + * fixed width of 195px plus a margin of 5px. */ protected void initLayout() { - setLayoutAlign(Alignment.RIGHT); setMembersMargin(5); Label xDesc = new Label("Position: X = "); Label yDesc = new Label("Y = "); - xDesc.setWidth(60); - x.setWidth(25); + HLayout xLayout = new HLayout(); + xLayout.setWidth(125); + xLayout.addMember(xDesc); + xLayout.addMember(x); + + HLayout yLayout = new HLayout(); + yLayout.setWidth(70); + yLayout.addMember(yDesc); + yLayout.addMember(y); + + xDesc.setWidth(70); + x.setWidth(55); yDesc.setWidth(20); - y.setWidth(25); + y.setWidth(50); - addMember(xDesc); - addMember(x); - addMember(yDesc); - addMember(y); + addMember(xLayout); + addMember(yLayout); }