Table Of Contents

Previous topic

FloatSpinEvent

Next topic

fmcustomizedlg

This Page

phoenix_title FloatTextCtrl

A class which holds a TextCtrl, one of the two building blocks of FloatSpin.


class_hierarchy Inheritance Diagram

Inheritance diagram for class FloatTextCtrl

Inheritance diagram of FloatTextCtrl


super_classes Known Superclasses

TextCtrl


method_summary Methods Summary

__init__ Default class constructor.
OnChar Handles the EVT_CHAR event for FloatTextCtrl.
OnDestroy Handles the EVT_WINDOW_DESTROY event for FloatTextCtrl.
OnKillFocus Handles the EVT_KILL_FOCUS event for FloatTextCtrl.

api Class API



class FloatTextCtrl(TextCtrl)

A class which holds a TextCtrl, one of the two building blocks of FloatSpin.


Methods



__init__(self, parent, id=ID_ANY, value="", pos=DefaultPosition, size=DefaultSize, style=TE_NOHIDESEL | TE_PROCESS_ENTER, validator=DefaultValidator, name=TextCtrlNameStr)

Default class constructor. Used internally. Do not call directly this class in your code!

Parameters:
  • parent – the FloatTextCtrl parent;
  • id – an identifier for the control: a value of -1 is taken to mean a default;
  • value – default text value;
  • pos – the control position. A value of (-1, -1) indicates a default position, chosen by either the windowing system or wxPython, depending on platform;
  • size – the control size. A value of (-1, -1) indicates a default size, chosen by either the windowing system or wxPython, depending on platform;
  • style – the window style;
  • validator – the window validator;
  • name – the window name.


OnChar(self, event)

Handles the EVT_CHAR event for FloatTextCtrl.

Parameters:event – a KeyEvent event to be processed.


OnDestroy(self, event)

Handles the EVT_WINDOW_DESTROY event for FloatTextCtrl.

Parameters:event – a WindowDestroyEvent event to be processed.

Note

This method tries to correctly handle the control destruction under MSW.



OnKillFocus(self, event)

Handles the EVT_KILL_FOCUS event for FloatTextCtrl.

Parameters:event – a FocusEvent event to be processed.

Note

This method synchronizes the SpinButton and the TextCtrl when focus is lost.