GscTriggerAutowords

GscTriggerAutowords — Autocompletion words trigger

Synopsis

#define             GSC_TRIGGER_AUTOWORDS_NAME
                    GscTriggerAutowordsPrivate;
                    GscTriggerAutowords;
                    GscTriggerAutowordsClass;
GscTriggerAutowords * gsc_trigger_autowords_new         (GscCompletion *completion);
void                gsc_trigger_autowords_set_delay     (GscTriggerAutowords *trigger,
                                                         guint delay);

Object Hierarchy

  GObject
   +----GscTriggerAutowords

Implemented Interfaces

GscTriggerAutowords implements GscTrigger.

Properties

  "delay"                    gint                  : Read / Write
  "min-len"                  gint                  : Read / Write

Description

This object trigger a completion event when the user writes a words with a configured lenght (default 3 characters). You can configure a delay and the completion event will be triggered n millisecons after the user insertion.

Details

GSC_TRIGGER_AUTOWORDS_NAME

#define GSC_TRIGGER_AUTOWORDS_NAME "GscTriggerAutowords"


GscTriggerAutowordsPrivate

typedef struct _GscTriggerAutowordsPrivate GscTriggerAutowordsPrivate;


GscTriggerAutowords

typedef struct _GscTriggerAutowords GscTriggerAutowords;


GscTriggerAutowordsClass

typedef struct {
	GObjectClass parent;
} GscTriggerAutowordsClass;


gsc_trigger_autowords_new ()

GscTriggerAutowords * gsc_trigger_autowords_new         (GscCompletion *completion);

completion :

The GscCompletion where the triggered will be used

Returns :

A new GscTriggerAutowords

gsc_trigger_autowords_set_delay ()

void                gsc_trigger_autowords_set_delay     (GscTriggerAutowords *trigger,
                                                         guint delay);

The delay time is the time between the last user key pressed and the instant when the trigger call to the completion. If delay is 2000 then the user press a key and 2 seconds later this trigger call to the completion if the user don't press another key.

trigger :

delay :

milliseconds to delay the autocompletion event.

Property Details

The "delay" property

  "delay"                    gint                  : Read / Write

Delay between the key pressed and the trigger event.

Allowed values: [0,10000]

Default value: 200


The "min-len" property

  "min-len"                  gint                  : Read / Write

Minimum word length to be autocompleted.

Allowed values: [0,100]

Default value: 3