Borderlayout not visible

asked 2008-08-12 18:33:22 +0800

dastultz gravatar image dastultz
797 8

Hello, I'm using Zk 3.0.7 with Firefox on a Mac. The following code produces an invisible borderlayout. Swap the comments as noted and it works:

Window win = new Window();
win.appendChild(new Label("Window"));

Borderlayout layout = new Borderlayout();
East east = new East();
east.appendChild(new Label("The East"));
Center center = new Center();

//center.appendChild(new Label("The Center"));
// switch below block with above line and it works
Hbox hbox = new Hbox();
hbox.appendChild(new Label("Center in Hbox"));

West west = new West();
west.appendChild(new Label("The West"));

Even this doesn't work ("Window" label is visible but borderlayout isn't):

<window border="normal">
<borderlayout width="100%" height="100%">
<east>The East</east>
<center>The Center</center>
<west>The West</west>

Any ideas?

delete flag offensive retag edit

2 Replies

Sort by ยป oldest newest

answered 2008-08-12 18:46:01 +0800

dastultz gravatar image dastultz
797 8

Ok, I've got it working now by specifying the height and width for both the border layout AND the window. It seems I can't make it work without the window (by adding the borderlayout to a vbox, for example). The border layout extends past the bottom of the window, though. Anyway, all I want is an autoscroll region of some kind. I have an hbox that I keep adding stuff to, and when it fills up the screen I want a scroll bar to pop up (for the hbox, not the browser window). Is there a better way to do this?

link publish delete flag offensive edit

answered 2008-08-12 18:59:46 +0800

dastultz gravatar image dastultz
797 8

Well, now I've reduced it to just the window and my content like so:

Window win = new Window();
win.setContentStyle("overflow: auto");

Not bad, but any comments on the borderlayout visibility issue would be appreciated. Also would like to know how to tell the window to scroll to the right when new content is added to contentContainer (which is an Hbox).


link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools




Asked: 2008-08-12 18:33:22 +0800

Seen: 279 times

Last updated: Aug 12 '08

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More