TABLE OF CONTENTS


Image/Bitmap [ Packages ]

[ Top ] [ Image ] [ Packages ]

FUNCTION

 Provides code for manipulate Tk image of type bitmap

SOURCE

package Tcl.Tk.Ada.Image.Bitmap with
   SPARK_Mode
is
   pragma Elaborate_Body;

Bitmap/Bitmap.Tk_Bitmap [ Types ]

[ Top ] [ Bitmap ] [ 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 Tk_Bitmap is new Tk_Widget with private;

Bitmap/Bitmap.Create_(function) [ Subprograms ]

[ Top ] [ Bitmap ] [ Subprograms ]

FUNCTION

 Creates a new Tk_Bitmap in the specified interpreter.

SOURCE

   function Create
     (pathName: in String; options: in String := "";
      Interp: in Tcl_Interp := Null_Interp) return Tk_Bitmap with
      Global => null;

PARAMETERS

 pathName - Tk name of the image
 options  - Options which will be passed to the image. Default value is
            empty
 Interp   - Tcl interpreter to which the image will be created. If null,
            the image will be created in the "contextual" interpreter.
            Default value is null.

RESULT

 Newly created Tk_Bitmap

EXAMPLE

   -- Create bitmap image with name arrow-up from the code on default interpreter
   Arrow_Up: constant Tk_Bitmap := Create("arrow-up", "-data {#define arrowUp_width 7  #define arrowUp_height 4 static char arrowUp_bits[] = { 0x08, 0x1c, 0x3e, 0x7f };}");

SEE ALSO

 Bitmap.Create_(procedure)

COMMANDS

 image create bitmap name ?options?

HISTORY

 8.6.1 - Added

Bitmap/Bitmap.Create_(procedure) [ Subprograms ]

[ Top ] [ Bitmap ] [ Subprograms ]

FUNCTION

 Creates a new Tk_Bitmap in the specified interpreter.

SOURCE

   procedure Create
     (Widgt: out Tk_Bitmap; pathName: in String; options: in String := "";
      Interp: in Tcl_Interp := Null_Interp) with
      Global => null;

PARAMETERS

 Widgt    - Tk_Bitmap which will be created
 pathName - Tk name of the image
 options  - Options which will be passed to the image. Default value is
            empty
 Interp   - Tcl interpreter to which the image will be created. If null,
            the image will be created in the "contextual" interpreter.
            Default value is null.

OUTPUT

 Newly created Tk_Bitmap as the Widgt parameter

EXAMPLE

      -- Create bitmap image with name arrow-down from the code on default interpreter
      declare
         Arrow_Down: Tk_Bitmap;
      begin
         Create(Arror_Down, "arrow-down", "-data {#define arrowDown_width 7  #define arrowDown_height 4 static char arrowDown_bits[] = { 0x7f, 0x3e, 0x1c, 0x08 };}");
      end;

SEE ALSO

 Bitmap.Create_(function)

COMMANDS

 image create bitmap name ?options?

HISTORY

 8.6.1 - Added

Bitmap/Bitmap.Get_Widget [ Subprograms ]

[ Top ] [ Bitmap ] [ Subprograms ]

FUNCTION

 Get the existing Tk_Bitmap image

SOURCE

   function Get_Widget
     (pathName: in String; Interp: in Tcl_Interp := Get_Context)
      return Tk_Bitmap with
      Global => null;

PARAMETERS

 pathName - Tk path (starts with dot) for the image
 Interp   - Tcl interpreter on which the image exists. Can be empty.
            Default value is current Tcl interpreter

RESULT

 Existing Tk_Bitmap image

EXAMPLE

     -- Get bitmap image with name .mybitmap on the current Tcl interpreter
     My_Bitmap: constant Tk_Bitmap := Get_Widget(".mybitmap");

HISTORY

 8.6.9 - Added