ToolMap
Loading...
Searching...
No Matches
tmValidator Class Reference

Validator for text controls. More...

#include <tmvalidator.h>

Inheritance diagram for tmValidator:

Public Member Functions

 tmValidator (long style=wxFILTER_NONE)
 Constructor.
 

Detailed Description

Validator for text controls.

This class may be used for controls validations. It extend the wxTextValidator with some more strict styles (see tmValidator::tmValidator() for allowed styles). Exemple :

wxTextCtrl myCtrl;
myCtrl.SetValidator(tmValidator(tmFILTER_EXCLUDE_CHAR_RESTRICTED));
Validator for text controls.
Definition tmvalidator.h:46
Author
Lucien Schreiber (c) CREALP 2008
Date
20 May 2008

Constructor & Destructor Documentation

◆ tmValidator()

tmValidator::tmValidator ( long  style = wxFILTER_NONE)

Constructor.

Construct a control validator, all style referenced for wxValidator (see wxWidgets doc) may be used plus the following :

  • tmFILTER_EXCLUDE_CHAR_RESTRICTED : allow only character (without accents) and numerics plus underscore and "-".
  • tmFILTER_EXCLUDE_CHAR_DATABASE : allow the same as above minus the "-" character wich isn't compatible with MySQL's database
  • tmFILTER_EXCLUDE_CHAR_NUMERIC_STRICT : allow only numeric char (0123456789) nothing else. wxFILTER_NUMERIC is more flexible, it allows some character like "." or "e".
    Parameters
    styleone of the style described above
    Author
    Lucien Schreiber (c) CREALP 2008
    Date
    20 May 2008

The documentation for this class was generated from the following files: