Component Height within Iframe problem

I’ve come across an interesting problem regarding height calculation, and I’m wondering if there is a solution. Here the scenario:

We are building Java Portlets in Liferay using Vaadin as the front end. We serve up the portlets using a “launchpad”. Basically, when a user selects a portlet to launch, we serve up the portlet in an iframe pointing to the URL where the portlet is accessible. This is done using an Embedded component that lives inside a subwindow.
Here is the layout heirarchy:


  • Launchpad content / main window…
    • Window (The subwindow containing the portlet, currently defaulted to 100% X 100% so that it fills the screen)
      • CssLayout (100% X 100%)
        • Embedded (100% X 100%, resource is the URL to the Portlet)


  • CustomComponent
    • GridLayout (100% X 100%, expand ratios set on column 1 and row 1)

      • Other stuff with in the grid. No heights other than 100% are explicitly in our code…

The problem is that the Portlet content can’t seem to determine what height it can work with. This is an issue where we have portlet content we would like to scale when the user resizes the subwindow. There doesn’t seem to be an issue with the width: the content will widen as we expand the subwindow. The height behaves differently. If I don’t specify a height for the custom component, it looks like it calculates its height based on the content within, so it doesn’t scale. However, if I specify the height of the custom component as 100%, suddenly it calculates its height as 0 in the html, so I get a blank screen. I’ve also tried using a panel as the top level component in the portlet UI heirarchy, but ended up with the same problem.

Any thoughts?