gtk.Idle.Idle Class Reference

List of all members.

Detailed Description

Description Before using GTK+, you need to initialize it; initialization connects to the window system display, and parses some standard command line arguments.

The gtk_init() function initializes GTK+. gtk_init() exits the application if errors occur; to avoid this, use gtk_init_check(). gtk_init_check() allows you to recover from a failed GTK+ initialization - you might start up your application in text mode instead. Like all GUI toolkits, GTK+ uses an event-driven programming model. When the user is doing nothing, GTK+ sits in the main loop and waits for input. If the user performs some action - say, a mouse click - then the main loop "wakes up" and delivers an event to GTK+. GTK+ forwards the event to one or more widgets. When widgets receive an event, they frequently emit one or more signals. Signals notify your program that "something interesting happened" by invoking functions you've connected to the signal with g_signal_connect(). Functions connected to a signal are often termed callbacks. When your callbacks are invoked, you would typically take some action


Public Member Functions

bit delegate ()[] idleListeners
 Holds all idle delegates.
 this (bit delegate() dlg, bit fireNow=false)
 Creates a new idle cycle.
void stop ()
 ~this ()
 Removes the idle from gtk Returns:.
void addListener (bit delegate() dlg, bit fireNow=false)
 Adds a new delegate to this idle cycle Params: delegate() = fireNow =.
 extern (C) static bit idleCallback(Idle idle)
 The callback execution from glib Params: idle = Returns:.

Static Public Member Functions

static uint add (GtkFunction funct, void *data)
 Warning gtk_idle_add has been deprecated since version 2.4 and should not be used in newly-written code.
static uint addPriority (int priority, GtkFunction funct, void *data)
 Warning gtk_idle_add_priority has been deprecated since version 2.4 and should not be used in newly-written code.
static uint addFull (int priority, GtkFunction funct, GtkCallbackMarshal marshal, void *data, GtkDestroyNotify destroy)
 Warning gtk_idle_add_full has been deprecated since version 2.4 and should not be used in newly-written code.
static void remove (uint idleHandlerId)
 Warning gtk_idle_remove has been deprecated since version 2.4 and should not be used in newly-written code.
static void removeByData (void *data)
 Warning gtk_idle_remove_by_data has been deprecated since version 2.4 and should not be used in newly-written code.

Public Attributes

uint idleID
 our gtk idle ID

Private Member Functions

bit callAllListeners ()
 Executes all delegates on the execution list Returns:.


Constructor & Destructor Documentation

gtk.Idle.Idle.this ( bit delegate()  dlg,
bit  fireNow = false 
)

Creates a new idle cycle.

Params: interval = the idle in milieconds delegate() = the delegate to be executed fireNow = When true the delegate will be executed emmidiatly Returns:

gtk.Idle.Idle.~this (  ) 

Removes the idle from gtk Returns:.


Member Function Documentation

static uint gtk.Idle.Idle.add ( GtkFunction  funct,
void *  data 
) [static]

Warning gtk_idle_add has been deprecated since version 2.4 and should not be used in newly-written code.

Use g_idle_add() instead. Causes the mainloop to call the given function whenever no events with higher priority are to be processed. The default priority is GTK_PRIORITY_DEFAULT, which is rather low. function: The function to call. data: The information to pass to the function. Returns: a unique handle for this registration.

static uint gtk.Idle.Idle.addFull ( int  priority,
GtkFunction  funct,
GtkCallbackMarshal  marshal,
void *  data,
GtkDestroyNotify  destroy 
) [static]

Warning gtk_idle_add_full has been deprecated since version 2.4 and should not be used in newly-written code.

Use g_idle_add_full() instead. Like gtk_idle_add() this function allows you to have a function called when the event loop is idle. The difference is that you can give a priority different from GTK_PRIORITY_DEFAULT to the idle function. priority: The priority which should not be above G_PRIORITY_HIGH_IDLE. Note that you will interfere with GTK+ if you use a priority above GTK_PRIORITY_RESIZE. function: The function to call. marshal: The marshaller to use instead of the function (if non-NULL). data: Data to pass to that function. destroy: Function to call when the timeout is destroyed or NULL. Returns: A unique id for the event source.

void gtk.Idle.Idle.addListener ( bit delegate()  dlg,
bit  fireNow = false 
)

Adds a new delegate to this idle cycle Params: delegate() = fireNow =.

static uint gtk.Idle.Idle.addPriority ( int  priority,
GtkFunction  funct,
void *  data 
) [static]

Warning gtk_idle_add_priority has been deprecated since version 2.4 and should not be used in newly-written code.

Use g_idle_add_full() instead. Like gtk_idle_add() this function allows you to have a function called when the event loop is idle. The difference is that you can give a priority different from GTK_PRIORITY_DEFAULT to the idle function. priority: The priority which should not be above G_PRIORITY_HIGH_IDLE. Note that you will interfere with GTK+ if you use a priority above GTK_PRIORITY_RESIZE. function: The function to call. data: Data to pass to that function. Returns: A unique id for the event source.

bit gtk.Idle.Idle.callAllListeners (  )  [private]

Executes all delegates on the execution list Returns:.

bit gtk.Idle.Idle.delegate (  ) 

Holds all idle delegates.

gtk.Idle.Idle.extern (  ) 

The callback execution from glib Params: idle = Returns:.

static void gtk.Idle.Idle.remove ( uint  idleHandlerId  )  [static]

Warning gtk_idle_remove has been deprecated since version 2.4 and should not be used in newly-written code.

Use g_source_remove() instead. Removes the idle function with the given id. idle_handler_id: Identifies the idle function to remove.

static void gtk.Idle.Idle.removeByData ( void *  data  )  [static]

Warning gtk_idle_remove_by_data has been deprecated since version 2.4 and should not be used in newly-written code.

Use g_idle_remove_by_data() instead. Removes the idle function identified by the user data. data: remove the idle function which was registered with this user data.

void gtk.Idle.Idle.stop (  ) 


Member Data Documentation

uint gtk.Idle.Idle.idleID

our gtk idle ID


SourceForge.net Logo DSource.org Logo digitalmars.com Logo