Take the 2-minute tour ×

I need to implement full screen ContentPanel in ext gwt. I use setSize method, but as params I can specify only resolution.

public class HomePage extends ContentPanel {

public HomePage() {


I want to have panel that will fill all window in each browser with different monitor resolution. So how can I use setsize method to solve this problem? Thanks!

share|improve this question
add comment

2 Answers

up vote 1 down vote accepted

Instead of setting the size, maybe try setting a layout that will expand. Maybe something like this (hasn't been tested):

setLayout(new FitLayout()); 
share|improve this answer
Thanks for your's idea! Full answer is here sencha.com/helpcenter/index.jsp?topic=/com.extjs.gxt.help/html/… –  BraginiNI Mar 28 '11 at 7:39
add comment

In GXT 3, I used:

private static final int WIDTH_SCREEN = XDOM.getViewportWidth();
private static final int HEIGTH_SCREEN = XDOM.getViewportHeight();

And after that use setWidth, setHeight

share|improve this answer
add comment

Your Answer


