From 652afa9aa23a5b786af9fab507ef54cf74ea1d43 Mon Sep 17 00:00:00 2001 From: Teppo Kurki Date: Tue, 10 Feb 2009 10:11:50 +0000 Subject: [PATCH] Fixed ticket #2562. Added margins to layout examples. svn changeset:6776/svn branch:trunk --- .../sampler/features/layouts/ApplicationLayoutExample.java | 2 ++ .../sampler/features/layouts/ExpandingComponentExample.java | 3 ++- .../demo/sampler/features/layouts/SplitPanelBasicExample.java | 4 ++++ .../demo/sampler/features/layouts/WebLayoutExample.java | 3 ++- 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/com/itmill/toolkit/demo/sampler/features/layouts/ApplicationLayoutExample.java b/src/com/itmill/toolkit/demo/sampler/features/layouts/ApplicationLayoutExample.java index af3a17966f..773437b9f3 100644 --- a/src/com/itmill/toolkit/demo/sampler/features/layouts/ApplicationLayoutExample.java +++ b/src/com/itmill/toolkit/demo/sampler/features/layouts/ApplicationLayoutExample.java @@ -61,6 +61,8 @@ public class ApplicationLayoutExample extends VerticalLayout { HorizontalLayout demoLayout = new HorizontalLayout(); // Enable spacing in the layout demoLayout.setSpacing(true); + // Enable margins in the layout + demoLayout.setMargin(true); // Create an example tree component, set to full size Tree t = new Tree("Hardware Inventory", ExampleUtil diff --git a/src/com/itmill/toolkit/demo/sampler/features/layouts/ExpandingComponentExample.java b/src/com/itmill/toolkit/demo/sampler/features/layouts/ExpandingComponentExample.java index f4e5922e00..b8858dea9d 100644 --- a/src/com/itmill/toolkit/demo/sampler/features/layouts/ExpandingComponentExample.java +++ b/src/com/itmill/toolkit/demo/sampler/features/layouts/ExpandingComponentExample.java @@ -56,8 +56,9 @@ public class ExpandingComponentExample extends VerticalLayout { private HorizontalLayout createDemoLayout() { // Create a new layout HorizontalLayout expandDemoLayout = new HorizontalLayout(); - // Enable spacing in the layout + // Enable spacing and margins in the layout expandDemoLayout.setSpacing(true); + expandDemoLayout.setMargin(true); expandDemoLayout.setSizeFull(); // Create an example tree component, set to full size diff --git a/src/com/itmill/toolkit/demo/sampler/features/layouts/SplitPanelBasicExample.java b/src/com/itmill/toolkit/demo/sampler/features/layouts/SplitPanelBasicExample.java index 4712fda82a..0fe365b84f 100644 --- a/src/com/itmill/toolkit/demo/sampler/features/layouts/SplitPanelBasicExample.java +++ b/src/com/itmill/toolkit/demo/sampler/features/layouts/SplitPanelBasicExample.java @@ -110,6 +110,10 @@ public class SplitPanelBasicExample extends VerticalLayout { // Add sub-SplitPanel to main SplitPanel demoSP.addComponent(subSP); + // Enable margins in both SplitPanels + demoSP.setMargin(true); + subSP.setMargin(true); + return demoSP; } } \ No newline at end of file diff --git a/src/com/itmill/toolkit/demo/sampler/features/layouts/WebLayoutExample.java b/src/com/itmill/toolkit/demo/sampler/features/layouts/WebLayoutExample.java index c1da5ed530..47238d6f2f 100644 --- a/src/com/itmill/toolkit/demo/sampler/features/layouts/WebLayoutExample.java +++ b/src/com/itmill/toolkit/demo/sampler/features/layouts/WebLayoutExample.java @@ -59,8 +59,9 @@ public class WebLayoutExample extends VerticalLayout { private HorizontalLayout createDemoLayout() { // Create a new layout HorizontalLayout demoLayout = new HorizontalLayout(); - // Enable spacing in the layout + // Enable spacing and margins in the layout demoLayout.setSpacing(true); + demoLayout.setMargin(true); // Create an example tree component, set to undefined size Tree t = new Tree("Hardware Inventory", ExampleUtil -- 2.39.5