TABLE OF CONTENTS
- 1. Widgets/TtkButton
- 1.1. TtkButton/TtkCheckButton
- 1.1.1. TtkCheckButton/TtkCheckButton.Ttk_CheckButton
- 1.1.2. TtkCheckButton/TtkCheckButton.Create_(function)
- 1.1.3. TtkCheckButton/TtkCheckButton.Create_(procedure)
- 1.1.4. TtkCheckButton/TtkCheckButton.Get_Widget
- 1.2. TtkButton/TtkRadioButton
- 1.2.1. TtkRadioButton/TtkRadioButton.Ttk_RadioButton
- 1.2.2. TtkRadioButton/TtkRadioButton.Create_(function)
- 1.2.3. TtkRadioButton/TtkRadioButton.Create_(procedure)
- 1.2.4. TtkRadioButton/TtkRadioButton.Get_Widget
- 1.3. TtkButton/TtkButton.Ttk_Button
- 1.4. TtkButton/TtkButton.Create_(function)
- 1.5. TtkButton/TtkButton.Create_(procedure)
- 1.6. TtkButton/TtkButton.Get_Widget
- 1.7. TtkButton/TtkButton.Invoke
Widgets/TtkButton [ Packages ]
[ Top ] [ Widgets ] [ Packages ]
FUNCTION
Provides code for Tk Ttk::Button
SOURCE
package Tcl.Tk.Ada.Widgets.TtkButton with SPARK_Mode is pragma Elaborate_Body;
TtkButton/TtkButton.Ttk_Button [ Types ]
[ Top ] [ TtkButton ] [ Types ]
FUNCTION
This is a non-abstract type derived directly from Tk_Widget. Each of the derived widgets redefines the Create subprogram in order to create the correct type of widget.
SOURCE
type Ttk_Button is new Tk_Widget with private;
TtkButton/TtkButton.Create_(function) [ Subprograms ]
[ Top ] [ TtkButton ] [ Subprograms ]
FUNCTION
Creates a new Ttk_Button in the specified interpreter.
SOURCE
overriding function Create (pathName: in String; options: in String := ""; Interp: in Tcl_Interp := Null_Interp) return Ttk_Button with Global => null;
PARAMETERS
pathName - Tk path (starts with dot) for the widget options - Options which will be passed to the widget. Default value is empty Interp - Tcl interpreter to which the widget will be created. If null, the widget will be created in the "contextual" interpreter. Default value is null.
RESULT
Newly created Ttk_Button
EXAMPLE
-- Create a new button with pathname .mybutton and text hello world My_Button: constant Ttk_Button := Create(".mybutton", "-text {hello world}");
SEE ALSO
TtkButton.Create_(procedure)
COMMANDS
ttk::button pathName ?options?
HISTORY
8.6.1 - Added
TtkButton/TtkButton.Create_(procedure) [ Subprograms ]
[ Top ] [ TtkButton ] [ Subprograms ]
FUNCTION
Creates a new Ttk_Button in the specified interpreter.
SOURCE
overriding procedure Create (Widgt: out Ttk_Button; pathName: in String; options: in String := ""; Interp: in Tcl_Interp := Null_Interp) with Global => null;
PARAMETERS
Widgt - Ttk_Button which will be created pathName - Tk path (starts with dot) for the widget options - Options which will be passed to the widget. Default value is empty Interp - Tcl interpreter to which the widget will be created. If null, the widget will be created in the "contextual" interpreter. Default value is null.
OUTPUT
Newly created Ttk_Button as parameter Widgt
EXAMPLE
-- Create button My_Button with pathname .mybutton and width 100px on the current Tcl interpreter declare My_Button: Ttk_Button; begin Create(My_Button, ".mybutton", "-width 100"); end;
SEE ALSO
TtkButton.Create_(function)
COMMANDS
ttk::button pathName ?options?
HISTORY
8.6.1 - Added
TtkButton/TtkButton.Get_Widget [ Subprograms ]
[ Top ] [ TtkButton ] [ Subprograms ]
FUNCTION
Get the existing Ttk_Button widget
SOURCE
overriding function Get_Widget (pathName: in String; Interp: in Tcl_Interp := Get_Context) return Ttk_Button with Global => null;
PARAMETERS
pathName - Tk path (starts with dot) for the widget Interp - Tcl interpreter on which the widget exists. Can be empty. Default value is current Tcl interpreter
RESULT
Existing Ttk_Button widget
EXAMPLE
-- Get button widget with name .mybutton on the current Tcl interpreter My_Button: constant Ttk_Button := Get_Widget(".mybutton");
HISTORY
8.6.9 - Added
TtkButton/TtkButton.Invoke [ Subprograms ]
[ Top ] [ TtkButton ] [ Subprograms ]
FUNCTION
Invoke the Tcl command associated with the button.
SOURCE
function Invoke (Buttn: in Ttk_Button'Class; options: in String := "") return String;
PARAMETERS
Buttn - Ttk_Button from which Tcl command will be invoked options - Tk options for the Tcl command invoke
RESULT
Value returned by the Tcl command associated with the button
EXAMPLE
-- Invoke the code related to My_Button Result: constant String := Invoke(My_Button);
COMMANDS
Buttn invoke
HISTORY
8.6.1 - Added