0

I tried the example code from this side to learn the SuggestBox in GWT.

http://gwt.google.com/samples/Showcase/Showcase.html#!CwSuggestBox

I have no idea where i connect the style with the SuggestBox.

So it looks...

I use uiBinder...

in the class: actioncontactpersontext = new SuggestBox(createContactOracle());

in uiBinder:

user959456
  • 565
  • 1
  • 9
  • 13

1 Answers1

0

EDIT: SuggestBox extends UIObject so call .setStyle("mystyle.css");

You can change the style of the Suggest Box in the css file. It should be located under war/[project name]/gwt/[theme name]/[theme name].css. I'm using the 'clean' theme so I would replace [theme name] with clean.

Look for the css class .gwt-SuggestBox, .gwt-SuggestBoxPopup, .gwt-SuggestBoxPopup .item etc. They are all located in the same area in the css file.

bmoran
  • 1,499
  • 2
  • 13
  • 21
  • I inserted the css-example in the css. .gwt-SuggestBox .... My question is, how recognise the SuggestBox that, that it have to take this style? Set the style to the suggestBox. – user959456 Feb 02 '12 at 17:02
  • One other thing. Not sure if you're trying to make RPC calls but if you are, check this post I answered. My suggest box makes RPC calls to the database as the user types. http://stackoverflow.com/questions/5367091/gwt-autosuggest-in-jsp/8523382#8523382 – bmoran Feb 02 '12 at 17:03