## Documentation

Table of Contents
Class Inheritance Tree
Widget Screenshots
Package groups

## Index

Package: Main

- Goto spec source

# Description

    package Gdk.Main is

This package provides routines to handle initialization and set up of the Gdk library.

Binding from C File version 1.3.6

# Types

### Gdk_Grab_Status

- Goto declaration in source

    type Gdk_Grab_Status is
         (Grab_Success,
          Grab_Already_Grabbed,
          Gdk_Grab_Invalid_Time,
          Gdk_Grab_Not_Viewable,
          Gdk_Grab_Frozen);

# Subprograms & Entries

### Init

- Goto spec in source

    procedure Init;

Initialize the library for use. The command line arguments are modified to reflect any arguments which were not handled. (Such arguments should either be handled by the application or dismissed).

### Gdk_Exit

- Goto spec in source
- Goto body in source

    procedure Gdk_Exit (Error_Code: Gint);

Restore the library to an un-itialized state and exits the program using the "exit" system call. Error_Code is the error value to pass to "exit". Allocated structures are freed and the program exits cleanly. This function is deprecated.

### Set_Locale

- Goto spec in source

    function Set_Locale return String;

Initialize handling of internationalization of strings. See Gtkada.Intl for more details.

### Set_Locale

- Goto spec in source

    procedure Set_Locale;

Drops the string returned by the Set_Locale function;

### Set_Use_Xshm

- Goto spec in source

    procedure Set_Use_Xshm (Use_Xshm: Boolean := True);

Set whether shared memory (when supported by the graphic server) should be used.

### Get_Use_Xshm

- Goto spec in source

    function Get_Use_Xshm return Boolean;

Return whether shared memory on the graphic server is used.

### Get_Display

- Goto spec in source

    function Get_Display return String;

Return the name of the display.

### Pointer_Grab

- Goto spec in source

    function Pointer_Grab (Window: Gdk.Window.Gdk_Window;Owner_Events: Boolean := True;Event_Mask: Gdk.Event.Gdk_Event_Mask;Confine_To: Gdk.Window.Gdk_Window := Gdk.Window.Null_Window;Cursor: Gdk.Cursor.Gdk_Cursor := Gdk.Cursor.Null_Cursor;Time: Guint32 := 0) return Gdk_Grab_Status;

Grab the pointer to a specific window. - Window is the window which will receive the grab - Owner_Events specifies whether events will be reported as is, or relative to Window - Event_Mask masks only interesting events - Confine_To limits the cursor movement to the specified window - Cursor changes the cursor for the duration of the grab - Time specifies the time Requires a corresponding call to Pointer_Ungrab

### Pointer_Ungrab

- Goto spec in source

    procedure Pointer_Ungrab (Time: Guint32 := 0);

Release any pointer grab.

### Pointer_Is_Grabbed

- Goto spec in source

    function Pointer_Is_Grabbed return Boolean;

Tell wether there is an active pointer grab in effect.

### Keyboard_Grab

- Goto spec in source

    function Keyboard_Grab (Window: Gdk.Window.Gdk_Window;Owner_Events: Boolean := True;Time: Guint32 := 0) return Gdk_Grab_Status;

Grab the keyboard to a specific window. - Window is the window which will receive the grab - Owner_Events specifies whether events will be reported as is, or relative to Window - Time specifies the time Requires a corresponding call to Keyboard_Ungrab

### Keyboard_Ungrab

- Goto spec in source

    procedure Keyboard_Ungrab (Time: Guint32 := 0);

Release any keyboard grab.

### Screen_Width

- Goto spec in source
- Goto body in source

    function Screen_Width return Gint;

Return the width of the screen.

### Screen_Height

- Goto spec in source
- Goto body in source

    function Screen_Height return Gint;

Return the height of the screen.

### Screen_Width_MM

- Goto spec in source
- Goto body in source

    function Screen_Width_MM return Gint;

Return the width of the screen in millimeters.

### Screen_Height_MM

- Goto spec in source
- Goto body in source

    function Screen_Height_MM return Gint;

Return the height of the screen in millimeters.

### Flush

- Goto spec in source
- Goto body in source

    procedure Flush;

Flush the queue of graphic events and then wait until all requests have been received and processed.

### Beep

- Goto spec in source
- Goto body in source

    procedure Beep;

Emit a beep.

### Set_Double_Click_Time

- Goto spec in source
- Goto body in source

    procedure Set_Double_Click_Time (Msec: Guint);