Package diffpy :: Package pdfgui :: Package gui :: Package wxExtensions :: Module validators :: Class TextValidator
[hide private]
[frames] | no frames]

Class TextValidator

source code

     object --+                
              |                
wx._core.Object --+            
                  |            
wx._core.EvtHandler --+        
                      |        
     wx._core.Validator --+    
                          |    
       wx._core.PyValidator --+
                              |
                             TextValidator

This validator is designed to check text input for wxTextCtrls. (It might
have uses in other widgets.) It can validate for letters only, digits only,
floats only, and can allow for a negative at the beginning of a digit string
or a negative float.



Instance Methods [hide private]
 
__init__(self, flag=2, allowNeg=False)
Initialize the validator.
source code
 
Clone(self) source code
 
Validate(self, win)
Validate(self, Window parent) -> bool
source code
 
OnChar(self, event) source code
 
TransferToWindow(self) source code
 
TransferFromWindow(self) source code

Inherited from wx._core.PyValidator (private): _setCallbackInfo

Inherited from wx._core.Validator: GetWindow, SetWindow

Inherited from wx._core.EvtHandler: AddPendingEvent, Bind, Connect, Disconnect, GetEvtHandlerEnabled, GetNextHandler, GetPreviousHandler, ProcessEvent, ProcessPendingEvents, SetEvtHandlerEnabled, SetNextHandler, SetPreviousHandler, Unbind, __repr__

Inherited from wx._core.EvtHandler (private): _setOORInfo

Inherited from wx._core.Object: Destroy, GetClassName, IsSameAs

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __str__

Static Methods [hide private]

Inherited from wx._core.Validator: IsSilent, SetBellOnError

Properties [hide private]

Inherited from wx._core.PyValidator: thisown

Inherited from wx._core.Validator: Window

Inherited from wx._core.EvtHandler: EvtHandlerEnabled, NextHandler, PreviousHandler

Inherited from wx._core.Object: ClassName

Inherited from object: __class__

Method Details [hide private]

__init__(self, flag=2, allowNeg=False)
(Constructor)

source code 
Initialize the validator.

flag        --  DIGIT_ONLY, allow only digits (default)
                ALPHA_ONLY, allow only letters
                FLOAT_ONLY, allow only floats

allowNeg    --  Allow a negative sign in front of DIGIT_ONLY, or
                FLOAT_ONLY text. (default False)

Returns:
PyValidator

Overrides: wx._core.PyValidator.__init__

Clone(self)

source code 


Returns:
Validator

Overrides: wx._core.Validator.Clone
(inherited documentation)

Validate(self, win)

source code 
Validate(self, Window parent) -> bool

Overrides: wx._core.Validator.Validate
(inherited documentation)

TransferToWindow(self)

source code 


Returns:
bool

Overrides: wx._core.Validator.TransferToWindow
(inherited documentation)

TransferFromWindow(self)

source code 


Returns:
bool

Overrides: wx._core.Validator.TransferFromWindow
(inherited documentation)