When I put HTMLPane with some content in Window and that window in Canvas, HTMLPane is not resized to fill the window.
If Window is not in Canvas then HTMLPane is fully resized to match the window's size.
Is there a way to resize HTMLPane to match Window size when Window is in Canvas?
I'm using :
SmartGWT 3.1p
SmartClient Version: v8.3_2012-11-20/LGPL Development Only (built 2012-11-20)
Chrome 27.0.1453.94 m
If Window is not in Canvas then HTMLPane is fully resized to match the window's size.
Is there a way to resize HTMLPane to match Window size when Window is in Canvas?
Code:
VLayout screenLayout = new VLayout(); RootPanel.get().add(screenLayout); screenLayout.setWidth100(); screenLayout.setHeight100(); screenLayout.setShowResizeBar(false); screenLayout.draw(); Canvas canvasMain = new Canvas(); canvasMain.setWidth100(); canvasMain.setHeight100(); canvasMain.setBackgroundColor("rgb(100,200,100)"); screenLayout.addMember(canvasMain); Window window = new Window(); window.setTitle("PDF"); window.setWidth(500); window.setHeight(700); window.setCanDragReposition(true); window.setCanDragResize(true); window.setAnimateFadeTime(1000); window.setAnimateMinimize(true); window.setKeepInParentRect(true); window.setShowMaximizeButton(true); HTMLPane htmlPane = new HTMLPane(); htmlPane.setWidth100(); htmlPane.setHeight100(); htmlPane.setContentsType(ContentsType.PAGE); htmlPane.setContentsURL("http://www.smartclient.com/releases/SmartGWT_Quick_Start_Guide.pdf"); window.addItem(htmlPane); // If window is not in canvas - it works OK canvasMain.addChild(window); window.show();
SmartGWT 3.1p
SmartClient Version: v8.3_2012-11-20/LGPL Development Only (built 2012-11-20)
Chrome 27.0.1453.94 m
Comment