Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [nebula-dev] Extensions for faster text input / idea

Hi Charlie!

... thank you *smmmiiiiile*  (you haven't seen the code yet. I'm only a
hobby programmer ... ok, to correct it: I write code down ;-))))))

Actualy, no, I didn't say anything about data binding and validation in
the verbal presentation. That's true. Ooops. Thanks.

Well, I tried to accomplish two things:

a) get the desired functionality for the user (what you can see on the
screencast), because I've seen other applications with these features
(like Outlook or even the brilliant ComboBox in MS-Access ... why didn't
they ever brought this to windows?)

b) and ... ehhh ... getting rid of the loooong & boring code needed for
JFace data-binding and validation for each property / field. It's kind
of exhausting writing almost the same lines over and over, when you just
have to connect a simple POJO with a form. That part has gotten pretty
selfish, because it is not generic and works only with bean observables.
That's why I'm pretty kean to learn more about the UFacekit, because it
intends to provide a high level API with a far more elegant way.

My solution is made out of separate parts, so others can use it the way
they want.

First there are validators (like the simple regex-validator ... whoa ...
nothing new ;-) that validate the text for a date input, regex, numeric
etc. You can use them as typical jface-databinding validators. 

Second: I've created 'validatingConverters' only, because when it get's
to the special date input, I realized, that I need to convert the
entered text in order to check if the input is valid. The
AbstractValidatingConverter provides four methods to obtain the
approriate converters and validators. Well, probably I didn't figure it
out how to tell jface databinding, that the converter may fail and to
show an error to the user, but these validating converts worked finally.

Third: In order to write less code, I provided a simple error decoration
(the red-ballon) that offers a simple method to attach all of the
binding code to a bean. AbstractBindingFactory is the base class for
this. It creates the decoration, binds the control to the apprioriate
validators and converters and binds it the model. Convivience code if
you like.

Fourth: The so called SmartCombo was added, because I found out, that
the typical proposals we all know from Eclipse are not accepted by an
ordinary business user. "WHERE'S THE COMBO-BOX?!", "...ohhh, wait, type
in any text and wait for 1 second and proposals will appear". They never
liked it nor understood it ;-)))) Now, they are familiar with it ... and
still use the mouse! *argghh*

I hope, that this text helped. I'll continue reading about UFacekit
:-))))

Greetings and thanx again

Holger

-----Original Message-----
From: Charlie Kelly [mailto:Charlie@xxxxxxxxxxxxxxxx] 
Sent: Wednesday, October 29, 2008 6:41 PM
To: holger.prang@xxxxxxxxxxxxxx; Nebula Dev
Subject: Re: [nebula-dev] Extensions for faster text input / idea


Hi Holger,

Great work.

Did you say something about validate/verify and data-binding in the 
verbal portion of your presenation?
If yes, what?

Thanks

Charlie

webmaster@xxxxxxxxxxxxxx wrote:
> Hello!
>
> I have to admit, that I am a complete newbie for contributing ideas 
> and / or code to an open source community. So please apologize for any

> inconvenience or this message itself. I hope, that this is the right 
> place.
>
> Maybe, this post isn't even a possible direct contribution, but more 
> an idea how to extend existing controls. But instead of leaving the 
> idea and code alone on my PC, I've decided to ask if anyone else might

> find this usefull, though my coding style probably looks like newbie, 
> too ;-)
>
> For a quick demonstration, you'll find a brief introduction via a
> screencast: http://www.vielsichtig.de/index.php?id=36
>
> The source code can be found here (requiring Subversion): 
> http://www.vielsichtig.de/svn/public
> (user: nobody / password: nobody)
>
> Download the projects: de.vielsichtig.jfaceUtils.*. The demo projects 
> contains the application for the web cast. Currently, only english and

> german phrases are supported.
>
> But because these extensions are tightly bound to JFace data binding, 
> I'm not sure, if the Nebula project is the right audience, but I think

> it's closer to controls than to data binding itself. Please apologize 
> again if I'm wrong.
>
> I'd be happy to participate and include or adapt the solution to 
> existing controls in the nebula project.
>
> Thanks for answers in advance and greetings
>
> Holger Prang
>
> _______________________________________________
> nebula-dev mailing list
> nebula-dev@xxxxxxxxxxx 
> https://dev.eclipse.org/mailman/listinfo/nebula-dev
>
>
>
>   



Back to the top