Home » U++ Library support » LineEdit, EditFields, DocEdit » Custom check for EditIntXxxx controls
Re: Custom check for EditIntXxxx controls [message #37550 is a reply to message #37549] |
Tue, 16 October 2012 15:09 |
|
Hi Pavel,
Edit*Spin ctrls are unfortunately not templates, so I'm afraid it is not really simple to "inject" them with custom value checking code (aside from the default min/max/notNull constraints).
For Edit* ctrls, you can achieve this simply by writing custom Convert based class and declare the type using typedef. E.g. for EditInt with your custom logic:typedef EditValue<int, MyConvert> MyEditInt; The input will be marked as invalid if your MyConvert class returns ErrorValue (see docs and/or Core/Convert.h). If you also want the spin buttons, you'll probably have to add them yourself, but it should be easy if you follow the code in original EditIntSpin class.
Best regards,
Honza
|
|
|
Goto Forum:
Current Time: Fri May 03 09:57:10 CEST 2024
Total time taken to generate the page: 0.04571 seconds
|