Class | Tk::Iwidgets::Optionmenu
In: | tk/lib/tkextlib/iwidgets/optionmenu.rb
Parent: | Tk::Iwidgets::Labeledwidget

### Methods

delete disable enable get get_range get_selected index insert select sort sort_ascending sort_descending

### Constants

TkCommandNames | = | ['::iwidgets::optionmenu'.freeze].freeze
WidgetClassName | = | 'Optionmenu'.freeze

### Public Instance methods

delete(first, last=nil)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 26
      def delete(first, last=nil)
        if last
          tk_call(@path, 'delete', first, last)
        else
          tk_call(@path, 'delete', first)
        end
        self
      end

disable(idx)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 35
      def disable(idx)
        tk_call(@path, 'disable', idx)
        self
      end

enable(idx)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 40
      def enable(idx)
        tk_call(@path, 'enable', idx)
        self
      end

get(first=nil, last=nil)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 45
      def get(first=nil, last=nil)
        if last
          simplelist(tk_call(@path, 'get', first, last))
        elsif first
          tk_call(@path, 'get', first)
        else
          tk_call(@path, 'get')
        end
      end

get_range(first, last)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 54
      def get_range(first, last)
        get(first, last)
      end

get_selected()

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 57
      def get_selected
        get()
      end

index(idx)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 61
      def index(idx)
        number(tk_call(@path, 'index', idx))
      end

insert(idx, *args)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 65
      def insert(idx, *args)
        tk_call(@path, 'insert', idx, *args)
        self
      end

select(idx)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 70
      def select(idx)
        tk_call(@path, 'select', idx)
        self
      end

sort(*params, &b)

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 75
      def sort(*params, &b)
        # see 'lsort' man page about params
        if b
          tk_call(@path, 'sort', '-command', proc(&b), *params)
        else
          tk_call(@path, 'sort', *params)
        end
        self
      end

sort_ascending()

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 84
      def sort_ascending
        tk_call(@path, 'sort', 'ascending')
        self
      end

sort_descending()

[Source]

    # File tk/lib/tkextlib/iwidgets/optionmenu.rb, line 88
      def sort_descending
        tk_call(@path, 'sort', 'descending')
        self
      end

[Validate]