WeeLayout add-on

Hi,

Just thought I’d open up a thread for my latest add-on,

WeeLayout

(see the add-on page for explanation/description), that I published a couple of weeks ago, so we can have a place to discuss bugs and features.

At least André Schild has left a question in the add-on page ratings/comments, so I’ll answer it here:

When the layout is undefined or fixed sized, you can add margins to the
.v-weelayout-cell
elements. Use either margin-top (vertical) or margin-right (horizontal). You could even create a custom style name that you can use to trigger spacing. See example below (not a final solution, this won’t work in IE6/7):

weeLayout.addStyleName("spacing");
/* Vertical */
.v-weelayout-vertical.spacing .v-weelayout-cell {
   margin-top: 5px;
   }
.v-weelayout-vertical-spacing .v-weelayout-cell:first-child {
   margin-top: 0;
   }

/* Horizontal */
.v-weelayout-horizontal.spacing .v-weelayout-cell {
   margin-right: 5px;
   }
.v-weelayout-horizontal.spacing .v-weelayout-cell:last-child {
   margin-right: 0;
   }

But when the layout is using percentage sizes, those margins won’t be taken into account (not yet, but it’s planned).

Hey Jouni,

What would I have to do to make this work in IE6/7?? :slight_smile:

Ty

Marcos

We sure need these new layout options, because the core ones are just HEEEEAVY! :frowning:

Hi,

Are you willing to spend extensive time in GWT Development Mode? That’s what is needed to get things fixed.

I guess there are plenty of bugs with the layout, but could you describe in detail what sort of trouble you ran into in IE6 and IE7, and maybe I’m able to point you in the right direction. Thanks!

Hi,

I’m having a simple problem that I think affects several Vaadin users: I have a long report page that I want to allow my user to print.

Then we go for the first problem: printing itself. It is solved by this:
http://vaadin.com/book/-/page/advanced.printing.html
. But I’m currently using a jQuery approach to do the same job:
http://projects.erikzaadi.com/jQueryPlugins/jQuery.printElement/
(a plug-in that allows a single component of the page to be printed, avoiding menus, sidebars and so on.).

The printing problem is solved, but not completely. With my full-hd-wide-screen-workaholic monitor, the 100% width divs are show with fixed size of 1900-like pixels. And when I put that divs into a popup window to get printed, the text is cropped. That was discussed
here
and
here
: the fault is of the heavy, slow, fixed-size core layouts.

A solution? Using the CssLayout. An acceptable solution? Well, time to give the WeeLayout a chance.

I simply switched from my long page of nested VerticalLayouts to a long page with nested WeeLayouts - no good. As it seems I have to redefine every component of the tree (labels, buttons, tables…), making it painful enough to remind JSF as “good days”.

This is what I need: a layout with no fixed sizes at all, which maintains the components gracefully spaced (like VerticalLayout does), and which I can “copy and paste” to another smaller window without cropping the content. Can WeeLayout handle that? If not, can you point me some directions?

(By the way, as we are talking about printing: try to print the sampler app. The content gets cropped.)

Thank you.

WeeLayout 0.2.1 jar currently in the addon repo has widgetset.gwt.xml which sets user.agent to safari.
I suppose this is not intentional?

Other than that, thanks for a nice little layout.

Marko

Oh, crap! Totally unintentional, but it did cross my mind that I might not remember to change it back. Will be fixed soon.

Thanks for reporting!