Eclipse Community Forums - RDF feed
https://www.eclipse.org/forums/
Eclipse Community ForumsInput validation - decoration / visual feedback - howto
https://www.eclipse.org/forums/index.php/mv/msg/482782/1049212/#msg_1049212
http://rap.eclipsesource.com/rapdemo/examples#input
Note how the "digits only" example gives you an orange background and also a small red 'X' graphic on its top left.
Could someone please explain (better, give an example), on how the 'X' graphic is provided?
Is this done in JavaScript with ClientScripting, or is that image put in by explicit logic (with a Label widget) on the RAP server side using Java code?
Thanks, John
]]>John Gymer2013-04-25T14:10:46-00:00Re: Input validation - decoration / visual feedback - howto
https://www.eclipse.org/forums/index.php/mv/msg/482782/1049812/#msg_1049812
> Is this done in JavaScript with ClientScripting, or is that image put in
> by explicit logic (with a Label widget) on the RAP server side?
The examples on the "input"[1] page are Java-only, see here[2], line 108.
On the "validation" page [3] we also use ClientScripting for faster
feedback, except on the first field. Find the Java
(ValidationExamplePage.java) and JavaScript code here[4].
You can also import the Examples demo from your target platform[5] to
view the code, but the bundle with the "validation" page is in the
ClientScripting repository[6].
To show that decorator by ClientScripting is not possible in 2.0
(without dirty tricks), but probably will be in 2.1. (The issue is that
the script can only access the widget that fires the event.)
Professional services for RAP and RCP? http://eclipsesource.com/services/rap/]]>Tim Buschtoens2013-04-26T09:51:41-00:00Re: Input validation - decoration / visual feedback - howto
https://www.eclipse.org/forums/index.php/mv/msg/482782/1049886/#msg_1049886
Java-only is good - I wasn't aware of the jface.fieldassist ControlDecoration and FieldDecoration classes, so I think you've pointed me in the right direction.
I cannot get it working in my own application, but it is most likely just me doing something silly... I shall persevere.
Everything builds and runs ok, but I just don't see the images appear... must be me I guess...
Cheers, John
]]>John Gymer2013-04-26T12:02:46-00:00Re: Input validation - decoration / visual feedback - howto
https://www.eclipse.org/forums/index.php/mv/msg/482782/1051861/#msg_1051861
I just wonder when Tabris will support them... do you happen to know, or shall I ask on their Forum?
Cheers, John
]]>John Gymer2013-04-29T09:48:29-00:00Re: Input validation - decoration / visual feedback - howto
https://www.eclipse.org/forums/index.php/mv/msg/482782/1051943/#msg_1051943
> I just wonder when Tabris will support them... do you happen to know, or
> shall I ask on their Forum?