-
Notifications
You must be signed in to change notification settings - Fork 5
Input
Corresponds to:
Fl_Input,
Fl_Input_
Inherits from:
Widget
Constructors
fl.Input( int X, int Y, int W, int H, *str label ) ==> userdata Widget-
fl.Input{ table entries } ==> userdata Widget( table constructor syntax )
Functions
- methods defined for
Widgetuserdata type -
obj:copy( int from ) ==> bool success( 0 selection, 1 clipboard. returns 1 if copied )
-
obj:copy_cuts() ==> bool success( 0 if no change ) -
obj:cut() ==> bool success( Delete current selection. return 0 )
-
obj:cut( int bytes ) ==> bool success( delete bytes after cursor. return 0 )
-
obj:cut( int begin, int end ) ==> bool success( del chars between begin & end. return 0 )
-
obj:index( int i ) ==> int char( Return char at index i )
-
obj:insert( str text ) ==> bool success( insert text at cursor. return 0 )
-
obj:replace( int begin, int end, *str text ) ==> bool success( delete from begin to end, then insert text. return 0 )
-
obj:size( int W, int H )set( width & height of widget )
-
obj:undo()( undo changes to text buffer )
Properties
- properties defined for
Widgetuserdata type -
obj.mark ==> int indexgetobj.mark = int indexset
( index in text ) -
obj.wrap ==> int statusgetobj.wrap = int statusset
( only for multi-line input ) -
obj.value ==> str textgetobj.value = str textset -
obj.tab_nav ==> bool valgetobj.tab_nav = bool valset
( default 1 advance focus. 0 insert tab char ) -
obj.readonly ==> bool valgetobj.readonly = bool valset
( 0 = editable ) -
obj.shortcut ==> userdata keygetobj.shortcut = int|str|userdata keyset
( shortcut key for widget, see Lua vs Cpp for adding key combos ) -
obj.textfont ==> str indexgetobj.textfont = int|str fontset
( Fl_Font index or name ) -
obj.textsize ==> int sizegetobj.textsize = int sizeset
( in pixels ) -
obj.textcolor ==> userdata colorgetobj.textcolor = int|userdata colorset
( Fl_color ) -
obj.value_size ==> int bytesget ( corresponds toFl_Input_::size()) -
obj.cursor_color ==> userdata colorgetobj.cursor_color = int|userdata colorset
( Fl_color ) -
obj.maximum_size ==> int maxgetobj.maximum_size = int maxset
( max length of input field in chars ) -
obj.cursor_position ==> int indexgetobj.cursor_position = int indexset
( corresponds toFl_Input_::position( i )) -
obj.type ==> str modegetobj.type = str modeset-
"FL_NORMAL_INPUT"(default) "FL_FLOAT_INPUT""FL_INT_INPUT""FL_HIDDEN_INPUT""FL_MULTILINE_INPUT""FL_SECRET_INPUT""FL_NORMAL_OUTPUT""FL_MULTILINE_OUTPUT""FL_MULTILINE_INPUT_WRAP""FL_MULTILINE_OUTPUT_WRAP"
-