class KIntValidator

QValidator for integers. More...

Definition#include <knumvalidator.h>
InheritsQValidator (qt) [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods


Detailed Description

QValidator for integers.

This can be used by QLineEdit or subclass to provide validated text entry. Can be provided with a base value (default is 10), to allow the proper entry of hexadecimal, octal, or any other base numeric data.

 KIntValidator ( QWidget * parent, int base = 10, const char * name = 0 )

KIntValidator

Constuctor. Also sets the base value.

 KIntValidator ( int bottom, int top, QWidget * parent, int base = 10, const char * name = 0 )

KIntValidator

Constructor. Also sets the minimum, maximum, and numeric base values.

 ~KIntValidator ()

~KIntValidator

[virtual]

Destructs the validator.

State  validate ( QString &, int & )

validate

[const virtual]

Validates the text, and return the result. Does not modify the parameters.

void  fixup ( QString & )

fixup

[const virtual]

Fixes the text if possible, providing a valid string. The parameter may be modified.

void  setRange ( int bottom, int top )

setRange

[virtual]

Sets the minimum and maximum values allowed.

void  setBase ( int base )

setBase

[virtual]

Sets the numeric base value.

int  bottom ()

bottom

[const virtual]

Returns the current minimum value allowed.

int  top ()

top

[const virtual]

Returns the current maximum value allowed.

int  base ()

base

[const virtual]

Returns the current numeric base.