class Tk::Tcllib::Widget::Dialog

Constants

PACKAGE_NAME
TkCommandNames

Public Class Methods

package_name() click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 19
def self.package_name
  PACKAGE_NAME
end
package_version() click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 23
def self.package_version
  begin
    TkPackage.require('widget::dialog')
  rescue
    ''
  end
end

Public Instance Methods

add(what, *args) click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 52
def add(what, *args)
  window(tk_send('add', *args))
end
cancel() click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 71
def cancel
  tk_send('cancel')
  self
end
close(reason = None) click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 76
def close(reason = None)
  tk_send('close', reason)
end
display() click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 65
def display
  tk_send('display')
  self
end
Also aliased as: show
get_frame() click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 56
def get_frame
  window(tk_send('getframe'))
end
set_widget(widget) click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 60
def set_widget(widget)
  tk_send('setwidget', widget)
  self
end
show()
Alias for: display
withdraw() click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 80
def withdraw
  tk_send('withdraw')
  self
end

Private Instance Methods

__boolval_optkeys() click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 37
def __boolval_optkeys
  ['separator', 'synchronous', 'transient']
end
create_self(keys) click to toggle source
# File lib/tkextlib/tcllib/dialog.rb, line 42
def create_self(keys)
  if keys and keys != None
    tk_call_without_enc(self.class::TkCommandNames[0], @path,
                        *hash_kv(keys, true))
  else
    tk_call_without_enc(self.class::TkCommandNames[0], @path)
  end
end