class Tk::RadioButton

Public Class Methods

tk_command() click to toggle source
# File lib/ffi-tk/widget/radiobutton.rb, line 6
def self.tk_command
  'radiobutton'
end

Public Instance Methods

deselect() click to toggle source

Deselects the radiobutton and sets the associated variable to an empty string. If this radiobutton was not currently selected, the command has no effect.

# File lib/ffi-tk/widget/radiobutton.rb, line 13
def deselect
  execute_only(:deselect)
end
flash() click to toggle source

Flashes the radiobutton. This is accomplished by redisplaying the radiobutton several times, alternating between active and normal colors. At the end of the flash the radiobutton is left in the same normal/active state as when the command was invoked. This command is ignored if the radiobutton's state is disabled.

# File lib/ffi-tk/widget/radiobutton.rb, line 23
def flash
  execute_only(:flash)
end
invoke() click to toggle source

Does just what would have happened if the user invoked the radiobutton with the mouse: selects the button and invokes its associated Tcl command, if there is one. The return value is the return value from the Tcl command, or an empty string if there is no command associated with the radiobutton. This command is ignored if the radiobutton's state is disabled.

# File lib/ffi-tk/widget/radiobutton.rb, line 33
def invoke
  execute_only(:invoke)
end
select() click to toggle source

Selects the radiobutton and sets the associated variable to the value corresponding to this widget. pressed over a radiobutton, the button activates whenever the mouse pointer is inside the button, and deactivates whenever the mouse pointer leaves the button.

# File lib/ffi-tk/widget/radiobutton.rb, line 42
def select
  execute_only(:select)
end