View Full Version : Web Application window

16 Jan 2012, 8:57 AM
Hi guys.
I'm new in this forum and I recently begin to use GXT.
I'm developing a web application where I need it to be full size inside the browser, i managed to do this by the next code:

package com.packfa.client;

import com.extjs.gxt.ui.client.widget.Viewport;
import com.extjs.gxt.ui.client.widget.layout.FitLayout;
import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.user.client.ui.RootPanel;

public class Main implements EntryPoint {
public void onModuleLoad() {
Viewport v = new Viewport();
v.setLayout(new FitLayout());
HomePage homePage=new HomePage();


and the question is: is there a way to put the entire application on a full window whit no URL fields and no Tabs to make the look and fill more like an independent application but still inside the browser?, i know applications like pencil project that works this way, is possible to make this in GXT?, how can i do it?


21 Jan 2012, 10:58 PM
you can use :

public void onModuleLoad() {

RootPanel rp=RootPanel.get("main");

Viewport vp=new Viewport();
vp.setLayout(new FitLayout());

Colin Alworth
22 Jan 2012, 2:30 PM
Viewport will make your components use the entire available browser space, but will not allow you to take over the url, tabs of the browser itself. For that, look into Window.open (http://google-web-toolkit.googlecode.com/svn/javadoc/2.4/com/google/gwt/user/client/Window.html#open%28java.lang.String,%20java.lang.String,%20java.lang.String%29) from a gwt app, or window.open (https://developer.mozilla.org/en/DOM/window.open) in regular javascript, and investigate the features parameter, to see what can be done to ask the browser to not show those things.

Use this method to open a new window, and have your GWT app be launched in that.

29 Jan 2012, 12:34 PM
Ok, thx a lot