Community
Participate
Working Groups
Subject: Re: possible feature request for Wizards... From: Martin_Aeschlimann@oti.com (Martin Aeschlimann) Newsgroups: eclipse.tools Organization: EclipseCorner Date: Oct 16 2001 10:52:12 I want to support this one. I also would like to have the desktiop to offer somthing like FieldEditors for wizards, property pages and dialogs, giving support for layouting and validation. Currently, writing the UI for a non trivial wizard (3 -4 input field) takes you at least half a day, and can fill pages of code with constructing GridLayouts, GridDatas, listeners of various kinds. ect. And every dialog has to do it again. There are some standard control building blocks: - String Input: Label & text - String Input with Button: Label, text, 'Browse'-button. - List: List with user configurable buttons on the right side, Up, Down, Remove - Checked List: List with User configurable buttons on the right side, Up, Down, Remove We have somthing similar in the jdt code (internal dialog fields). What I think what is valuable. is the 'doFillIntoGrid(Composite, int numberOfColumns), which assumes you are using the Grid Layout and so creates the controls for you and sets the GridDatas with correct span & grap. Note that having something like FieldEditors does not help only speed up writing UI, but also brings a common look to Eclipse. Martin "Mazen Faraj" <mazenfaraj@home.com> wrote in message news:9qfacc$uck$1@rogue.oti.com... > thanks Randy, > I'm fine with the preference store and the dialog settings. Ease of use with > the preference store > was not what I was looking for :-) > What I was looking for is "smart widgets". Specifically, StringFieldEditor > has methods like > isEmptyStringAllowed > isValid > setTextLimit.... etc > > If these methods actually do what they sound like (to be honest with you I > have not tried > these filed editors yet, I'm quickly weighing my options...) then I can use > these widgets > to create a wizard whose fields do heavy duty checking before allowing > "next" or "finish". > > Maybe there are some swt widgets that I might have overlooked, but basically > I don't want > to code too much logic in a Wizard page if I can ofload some of this logic > checking to the > widgets themselves. > > To give you a specific example, I need a widget that only takes a max of 10 > char, and no > "/" allowed, no int... etc. > I don't want to code this logic if it has already been done.... > > so am I missing something? Isn't that what these field editors are somewhat > accompliching? > (besides handling preference store stuff...) > > regards, > Mazen > > > > > > > "Randy Giffen" <none@oti.com> wrote in message > news:9qf8pv$t67$1@rogue.oti.com... > > FieldEditors provide simple widget creation/layout and simplify > interaction > > with a preference store. I assume it is the former feature that you are > > looking for in Wizards. > > > > Quite a while ago we tried providing convenience widget creation api for > > wizards and dialogs in a utility class. But eventually this was dropped in > > favor of creating the SWT widgets and layout directly. > > > > Remembering previous selections in wizards is provided by the > > IDialogSettings api. > > > > Mazen Faraj <mazenfaraj@home.com> wrote in message > > news:9qf2kv$lrk$1@rogue.oti.com... > > > Sorry, it's me again :-) > > > One last thing... > > > I wa just looking at the org.eclipse.jface.preference.FieldEditor > > framework. > > > The docs say that they can should be used in conjunction with > > > FieldEditorPreferencePage. > > > > > > But the functionality is great, so can we, should we somehow embedd > these > > > FieldEditors > > > in a Wizard Page? The functionality applies there too ;-) > > > > > > If yes, great. > > > If now, then as a feature request, maybe a WizardPage and a Preference > > page > > > could have > > > a version of the FieldEditorPreferencePage to enable this functionality > > for > > > both Preferences > > > and Wizards. > > > > > > As usual, please scream if I am not making sense :-) > > > > > > regards, > > > Mazen > > > > > > > > > > > > > > >
Issues to consider: 1) How are the created widgets referenced? 2) Can other (non-field editor) widgets be created in the same page/dialog. 3) This functionality would have to go in org.eclipse.jface.util?
Consider post 2.0
Reopen for investigation
*** This bug has been marked as a duplicate of 104570 ***