This software is licensed under the CC-GNU LGPL.

GWT Widget Library

Monday, May 29, 2006


ANNOUNCE: GWT Widget Library 0.0.2

What's New in GTW Widget Library 0.0.2

Download Version 0.0.2

Wrap existing HTML elements as widgets. Support for hyperlinks, images, buttons, and panels.

WButton action = new WButton("action-button");

WHyperlink searchLink = new WHyperlink("link-to-search");

WPanel content = new WPanel("content");

WImage headerImg = new WImage("header-image");

Wrap an existing HTML element with the most appropriate wrapper.

WrappedWidget navLinkSearch = WBuilder.getWidgetFromDOM("nav-link-search");

if (navLinkSearch.isHyperlink()) {

Replace existing elements and widgets on the page with other widgets.

WBuilder.replaceElementWithWidget(element, widget);

WBuilder.replaceWidget(oldWidget, newWidget);

PNGImage widget, with support for transparancy in IE5.5 and IE6.

PNGImage img = new PNGImage("/images/test.png", width, height);

Color and BorderStyle constants for setting styles. Currently used in the new ImageButton widget.

ImageButton widget designed for use in tool bars. Allows for creation of buttons individually, or with the help of the ImageButtonFactory.

ImageButtonFactory fac = new ImageButtonFactory();

FlowPanel iconBar = new FlowPanel();

iconBar.add(fac.createImageButton("icons/applications-accessories.png", 22, 22));
iconBar.add(fac.createImageButton("icons/applications-development.png", 22, 22));
iconBar.add(fac.createImageButton("icons/applications-games.png", 22, 22));
iconBar.add(fac.createImageButton("icons/applications-graphics.png", 22, 22));
iconBar.add(fac.createImageButton("icons/applications-internet.png", 22, 22));
iconBar.add(fac.createImageButton("icons/applications-multimedia.png", 22, 22));


I am very interested in your project and would like to contribute. We currently have the need for a TextBox widget that i would like to code/contribute. From what i see creating a new widget involves altering the WrappedWidget Interface to add the isText() method and then adding the method to all the existing classes and then altering the WBuilder class to instantiate the new Widget based on this type. I see in some widgets you make a call to sinkEvents in the constructor(Button Widget) but in others you don't. Can you explain when you need to do this and when you don't?
Post a Comment

<< Home


May 2006   June 2006  

This page is powered by Blogger. Isn't yours?