Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
doyousketch2 edited this page Sep 13, 2019 · 21 revisions

Browser:

Corresponds to: Fl_Browser

Inherits from: Browser_, Widget

Constructors

  • fl.Browser( int X, int Y, int W, int H, *str label ) ==> userdata Widget
  • fl.Browser{ table entries } ==> userdata Widget

    ( table constructor syntax )


Functions

  • methods defined for Browser_ userdata type
  • methods defined for Widget userdata type
  • obj:add( *str newtext ) ( add new line to end of browser )
  • obj:clear() ( removes all lines in browser )
  • obj:displayed( int line# ) ==> bool showing ( 1 visible, 0 if not )
  • obj:hide() ( hide entire browser )

    obj:hide( int line# ) ( hide line )

  • obj:insert( int line#, *str newtext )

    ( insert item above line )

  • obj:load( str filename ) ==> bool, *str

    ( 1 if OK, 0 on error w/ reason )

  • obj:make_visible( int line# )
  • obj:move( int to, int from )

    ( Note: 'to' is calculated after line 'from' gets removed )

  • obj:remove( int line# )
  • obj:select( int line# ) ==> bool state change

    ( 1 if state changed, 0 if not )

  • obj:selected( int line# ) ==> bool status

    ( 1 if item selected, 0 if not )

  • obj:show() ( show entire browser )
  • obj:show( int line# ) ( show line )
  • obj:size( int W, int H )
  • obj:swap( int line#A, int line#B )
  • obj:text( int line# ) ==> *str label get

    obj:text( int line#, str newtext ) set

  • obj:line_visible( int line# ) ==> bool

    ( corresponds to Fl_Browser::visible(int line#) )


Properties

  • properties defined for Browser_ userdata type
  • properties defined for Widget userdata type
  • obj.value ==> int line# get

    obj.value = int line# set

  • obj.nitems ==> int lines

    ( corresponds to Fl_Browser::size() )

  • obj.topline ==> int line# get

    obj.topline = int line# set

  • obj.middleline ==> int line# get

    obj.middleline = int line# set

  • obj.bottomline ==> int line# get

    obj.bottomline = int line# set

  • obj.column_char ==> str get

    ( default '\t' tab ) obj.column_char = str set

  • obj.format_char ==> str get

    ( default @ ) obj.format_char = str set

  • obj.column_widths ==> table get

    obj.column_widths = table set

  • obj.type ==> str mode get

    obj.type = str mode set
    select mode:

    • "FL_NORMAL_BROWSER" ( default )
    • "FL_SELECT_BROWSER"
    • "FL_HOLD_BROWSER"
    • "FL_MULTI_BROWSER"

( note: Browser does not inherit methods and properties of Group, although Fl_Browser is implemented as a sub-class of Fl_Group! )

Clone this wiki locally
Morty Proxy This is a proxified and sanitized view of the page, visit original site.