girara
Data Structures | Typedefs | Enumerations
types.h File Reference
#include "girara-version.h"
#include <stdbool.h>

Go to the source code of this file.

Data Structures

struct  girara_argument_t
 
struct  girara_event_t
 

Typedefs

typedef struct girara_tree_node_s girara_tree_node_t
 
typedef struct girara_list_s girara_list_t
 
typedef struct girara_list_iterator_s girara_list_iterator_t
 
typedef struct girara_setting_s girara_setting_t
 
typedef struct girara_tab_s girara_tab_t
 
typedef struct girara_completion_element_s girara_completion_element_t
 
typedef struct girara_completion_s girara_completion_t
 
typedef struct girara_completion_group_s girara_completion_group_t
 
typedef int girara_mode_t
 
typedef girara_completion_t *(* girara_completion_function_t) (girara_session_t *session, const char *input)
 
typedef bool(* girara_inputbar_special_function_t) (girara_session_t *session, const char *input, girara_argument_t *argument)
 
typedef bool(* girara_command_function_t) (girara_session_t *session, girara_list_t *argument_list)
 
typedef bool(* girara_shortcut_function_t) (girara_session_t *, girara_argument_t *, girara_event_t *, unsigned int)
 
typedef void(* girara_free_function_t) (void *data)
 
typedef void(* girara_list_callback_t) (void *data, void *userdata)
 
typedef int(* girara_compare_function_t) (const void *data1, const void *data2)
 
typedef void(* girara_setting_callback_t) (girara_session_t *session, const char *name, girara_setting_type_t type, const void *value, void *data)
 
typedef struct girara_input_history_io_s GiraraInputHistoryIO
 

Enumerations

enum  {
  GIRARA_HIDE = 1 , GIRARA_NEXT , GIRARA_PREVIOUS , GIRARA_NEXT_GROUP ,
  GIRARA_PREVIOUS_GROUP , GIRARA_HIGHLIGHT , GIRARA_NORMAL , GIRARA_DELETE_LAST_WORD ,
  GIRARA_DELETE_LAST_CHAR , GIRARA_NEXT_CHAR , GIRARA_PREVIOUS_CHAR , GIRARA_DELETE_TO_LINE_START ,
  GIRARA_DELETE_TO_LINE_END , GIRARA_DELETE_CURR_CHAR , GIRARA_GOTO_START , GIRARA_GOTO_END
}
 
enum  girara_setting_type_t {
  BOOLEAN , FLOAT , INT , STRING ,
  UNKNOWN = 0xFFFF
}
 
enum  girara_mouse_button_t {
  GIRARA_MOUSE_BUTTON1 = 1 , GIRARA_MOUSE_BUTTON2 = 2 , GIRARA_MOUSE_BUTTON3 = 3 , GIRARA_MOUSE_BUTTON4 = 4 ,
  GIRARA_MOUSE_BUTTON5 = 5 , GIRARA_MOUSE_BUTTON6 = 6 , GIRARA_MOUSE_BUTTON7 = 7 , GIRARA_MOUSE_BUTTON8 = 8 ,
  GIRARA_MOUSE_BUTTON9 = 9
}
 
enum  girara_event_type_t {
  GIRARA_EVENT_BUTTON_PRESS , GIRARA_EVENT_2BUTTON_PRESS , GIRARA_EVENT_3BUTTON_PRESS , GIRARA_EVENT_BUTTON_RELEASE ,
  GIRARA_EVENT_MOTION_NOTIFY , GIRARA_EVENT_SCROLL_UP , GIRARA_EVENT_SCROLL_DOWN , GIRARA_EVENT_SCROLL_LEFT ,
  GIRARA_EVENT_SCROLL_RIGHT , GIRARA_EVENT_OTHER , GIRARA_EVENT_SCROLL_BIDIRECTIONAL
}
 

Typedef Documentation

◆ girara_command_function_t

typedef bool(* girara_command_function_t) (girara_session_t *session, girara_list_t *argument_list)

Function declaration of a command function

Parameters
sessionThe current girara session
argcNumber of arguments
argvArguments

Definition at line 89 of file types.h.

◆ girara_compare_function_t

typedef int(* girara_compare_function_t) (const void *data1, const void *data2)

Function declaration of a function which compares two elements.

Parameters
data1the first element.
data2the second element.
Returns
-1 if data1 < data2, 0 if data1 == data2 and 1 if data1 > data2

Definition at line 123 of file types.h.

◆ girara_completion_element_t

typedef struct girara_completion_element_s girara_completion_element_t

Definition at line 24 of file types.h.

◆ girara_completion_function_t

typedef girara_completion_t *(* girara_completion_function_t) (girara_session_t *session, const char *input)

Function declaration of a function that generates a completion group

Parameters
sessionThe current girara session
inputThe current input
Returns
The completion group

Definition at line 67 of file types.h.

◆ girara_completion_group_t

typedef struct girara_completion_group_s girara_completion_group_t

Definition at line 26 of file types.h.

◆ girara_completion_t

typedef struct girara_completion_s girara_completion_t

Definition at line 25 of file types.h.

◆ girara_free_function_t

typedef void(* girara_free_function_t) (void *data)

Function declaration of a function that frees something.

Parameters
datathe data to be freed.

Definition at line 107 of file types.h.

◆ girara_inputbar_special_function_t

typedef bool(* girara_inputbar_special_function_t) (girara_session_t *session, const char *input, girara_argument_t *argument)

Function declaration of a inputbar special function

Parameters
sessionThe current girara session
inputThe current input
argumentThe given argument
Returns
TRUE No error occurred
FALSE Error occurred

Definition at line 79 of file types.h.

◆ girara_list_callback_t

typedef void(* girara_list_callback_t) (void *data, void *userdata)

Function declaration of a function called as callback from girara_list_* functions.

Parameters
dataa list element.
userdatadata passed as userdata to the calling function.

Definition at line 115 of file types.h.

◆ girara_list_iterator_t

typedef struct girara_list_iterator_s girara_list_iterator_t

Definition at line 11 of file types.h.

◆ girara_list_t

typedef struct girara_list_s girara_list_t

Definition at line 10 of file types.h.

◆ girara_mode_t

typedef int girara_mode_t

Mode identifier

Definition at line 58 of file types.h.

◆ girara_setting_callback_t

typedef void(* girara_setting_callback_t) (girara_session_t *session, const char *name, girara_setting_type_t type, const void *value, void *data)

Function declaration for a settings callback

Parameters
sessionThe current girara session
nameThe name of the affected setting
typeThe type of the affected setting
valuePointer to the new value
dataUser data

Definition at line 146 of file types.h.

◆ girara_setting_t

typedef struct girara_setting_s girara_setting_t

Definition at line 12 of file types.h.

◆ girara_shortcut_function_t

typedef bool(* girara_shortcut_function_t) (girara_session_t *, girara_argument_t *, girara_event_t *, unsigned int)

Function declaration of a shortcut function

If a numeric value has been written into the buffer, this function gets as often executed as the value defines or until the function returns false the first time.

Definition at line 99 of file types.h.

◆ girara_tab_t

typedef struct girara_tab_s girara_tab_t

Definition at line 19 of file types.h.

◆ girara_tree_node_t

typedef struct girara_tree_node_s girara_tree_node_t

Definition at line 9 of file types.h.

◆ GiraraInputHistoryIO

typedef struct girara_input_history_io_s GiraraInputHistoryIO

Definition at line 208 of file types.h.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

This structure defines the possible argument identifiers

Enumerator
GIRARA_HIDE 

Hide the completion list

GIRARA_NEXT 

Next entry

GIRARA_PREVIOUS 

Previous entry

GIRARA_NEXT_GROUP 

Next group in the completion list

GIRARA_PREVIOUS_GROUP 

Previous group in the completion list

GIRARA_HIGHLIGHT 

Highlight the entry

GIRARA_NORMAL 

Set to the normal state

GIRARA_DELETE_LAST_WORD 

Delete the last word

GIRARA_DELETE_LAST_CHAR 

Delete the last character

GIRARA_NEXT_CHAR 

Go to the next character

GIRARA_PREVIOUS_CHAR 

Go to the previous character

GIRARA_DELETE_TO_LINE_START 

Delete the line to the start

GIRARA_DELETE_TO_LINE_END 

Delete the line to the end

GIRARA_DELETE_CURR_CHAR 

Delete current char

GIRARA_GOTO_START 

Go to start of the line

GIRARA_GOTO_END 

Go to end of the line

Definition at line 35 of file types.h.

◆ girara_event_type_t

Describes the types of a girara

Enumerator
GIRARA_EVENT_BUTTON_PRESS 

Single click

GIRARA_EVENT_2BUTTON_PRESS 

Double click

GIRARA_EVENT_3BUTTON_PRESS 

Triple click

GIRARA_EVENT_BUTTON_RELEASE 

Button released

GIRARA_EVENT_MOTION_NOTIFY 

Cursor moved

GIRARA_EVENT_SCROLL_UP 

Scroll event

GIRARA_EVENT_SCROLL_DOWN 

Scroll event

GIRARA_EVENT_SCROLL_LEFT 

Scroll event

GIRARA_EVENT_SCROLL_RIGHT 

Scroll event

GIRARA_EVENT_OTHER 

Unknown event

GIRARA_EVENT_SCROLL_BIDIRECTIONAL 

Scroll event that carries extra data in girara_argument_t with motion information as double[2]. First component is horizontal shift, second - vertical.

Definition at line 177 of file types.h.

◆ girara_mouse_button_t

Define mouse buttons

Enumerator
GIRARA_MOUSE_BUTTON1 

Button 1

GIRARA_MOUSE_BUTTON2 

Button 2

GIRARA_MOUSE_BUTTON3 

Button 3

GIRARA_MOUSE_BUTTON4 

Button 4

GIRARA_MOUSE_BUTTON5 

Button 5

GIRARA_MOUSE_BUTTON6 

Button 6

GIRARA_MOUSE_BUTTON7 

Button 7

GIRARA_MOUSE_BUTTON8 

Button 8

GIRARA_MOUSE_BUTTON9 

Button 9

Definition at line 161 of file types.h.

◆ girara_setting_type_t

This structure defines the possible types that a setting value can have

Enumerator
BOOLEAN 

Boolean type

FLOAT 

Floating number

INT 

Integer

STRING 

String

UNKNOWN 

Unknown type

Definition at line 128 of file types.h.