2024-10-19 16:05:49 +02:00
.TH "include/util.h" 3 "Version 0.1.0" "Gem-graph" \" -*- nroff -*-
.ad l
.nh
.SH NAME
include/util.h \- utilities header
.SH SYNOPSIS
.br
.PP
\fC #include <stdbool\& .h>\fP
.br
\fC #include <stddef\& .h>\fP
.br
\fC #include <gtk\- 4\& .0/gtk/gtk\& .h>\fP
.br
\fC #include '\& .\& ./include/fsm\& .h'\fP
.br
.SS "Classes"
.in +1c
.ti -1c
.RI "struct \fBpile\fP"
.br
2024-10-22 23:58:04 +02:00
.RI "phantom documentation "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "struct \fBelem\fP"
.br
2024-10-22 23:58:04 +02:00
.RI "simplest element of a double-chained list "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "struct \fBdblist\fP"
.br
2024-10-22 23:58:04 +02:00
.RI "required to init the empty list "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "struct \fBslist\fP"
.br
2024-10-22 23:58:04 +02:00
.RI "phantom documentation "
2024-10-19 16:05:49 +02:00
.in -1c
.SS "Typedefs"
.in +1c
.ti -1c
.RI "typedef struct \fBpile\fP \fBpile\fP"
.br
2024-10-22 23:58:04 +02:00
.RI "phantom documentation "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "typedef struct \fBelem\fP \fBelem\fP"
.br
2024-10-22 23:58:04 +02:00
.RI "simplest element of a double-chained list "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "typedef struct \fBslist\fP \fBslist\fP"
.br
2024-10-22 23:58:04 +02:00
.RI "phantom documentation "
2024-10-19 16:05:49 +02:00
.in -1c
.SS "Functions"
.in +1c
.ti -1c
.RI "char * \fButil_read_file\fP (char *filename)"
.br
2024-10-20 01:05:12 +02:00
.RI "reads a file from filename into a provided buffer "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "char * \fButil_concat\fP (const char *str,\&.\&.\&.)"
.br
2024-10-26 08:15:20 +02:00
.RI "/home/jean/Gem-Graph/gem-graph-client/src/util/strings_op\&.c:63: warning: unable to resolve reference to '\&.\&.\&.' for ref command TODO (.\&.\&.ref desactivated) @ ref https://sourceware.org/glibc/manual/latest/html_mono/libc.html#Variadic-Prototypes "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "void \fButil_pile_clear\fP (\fBpile\fP **)"
.br
.ti -1c
.RI "void \fButil_pile_view\fP (\fBpile\fP *)"
.br
.ti -1c
.RI "int \fButil_pile_push\fP (\fBpile\fP **, int)"
.br
.ti -1c
.RI "int \fButil_pile_pop\fP (\fBpile\fP **)"
.br
.ti -1c
.RI "int \fButil_pile_length\fP (\fBpile\fP *p)"
.br
.ti -1c
.RI "void \fButil_list_2x2_init\fP (\fBdblist\fP *l)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "void \fButil_list_2x2_clear\fP (\fBdblist\fP *l)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "void \fButil_list_2x2_view\fP (\fBdblist\fP l)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "int \fButil_list_2x2_push_back\fP (\fBdblist\fP *l, int val)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "int \fButil_list_2x2_push_front\fP (\fBdblist\fP *l, int val)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "int \fButil_list_2x2_pop_back\fP (\fBdblist\fP *l)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "int \fButil_list_2x2_pop_front\fP (\fBdblist\fP *l)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "int \fButil_list_2x2_length\fP (\fBdblist\fP l)"
.br
2024-10-20 01:05:12 +02:00
.RI "Phantom documentation\&. "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "void \fButil_sorted_list_clear\fP (\fBslist\fP **sl)"
.br
.ti -1c
.RI "void \fButil_sorted_list_view\fP (\fBslist\fP *sl)"
.br
.ti -1c
.RI "int \fButil_sorted_list_insert\fP (\fBslist\fP **sl, int val)"
.br
.ti -1c
.RI "int \fButil_sorted_list_pop\fP (\fBslist\fP **sl)"
.br
.ti -1c
.RI "int \fButil_sorted_list_length\fP (\fBslist\fP *sl)"
.br
.ti -1c
.RI "void \fButil_trigger_test\fP ()"
.br
2024-10-20 23:03:17 +02:00
.RI "simplifying utilities tests "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "void \fButil_test_pile\fP ()"
.br
2024-10-20 23:03:17 +02:00
.RI "sample test "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "void \fButil_test_double_list\fP ()"
.br
2024-10-20 23:03:17 +02:00
.RI "sample test "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "void \fButil_test_sorted_list\fP ()"
.br
2024-10-20 23:03:17 +02:00
.RI "sample test "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "long \fButil_gl_get_stack\fP (void *container_widget)"
.br
.RI "Look for stack entry and returns stack_id\&. "
.ti -1c
.RI "bool \fButil_gl_init_stack\fP (void *container_widget, GError *error_buffer)"
.br
.RI "Look for stack entry and initializes OpenGL for it\&. "
.ti -1c
.RI "bool \fButil_gl_shutdown_stack\fP (void *container_widget, GError *error_buffer)"
.br
.RI "Look for stack entry and shutdowns OpenGL for it\&. "
.ti -1c
.RI "void \fButil_gl_clean_stack_index\fP (void)"
.br
2024-10-24 09:12:19 +02:00
.RI "phantom documentation "
2024-10-19 16:05:49 +02:00
.ti -1c
.RI "bool \fButil_gl_render_stack\fP (GtkWidget *container_widget)"
.br
.RI "Look for stack entry and triggers OpenGL for drawing\&. "
.ti -1c
.RI "bool \fButil_gl_update_axis\fP (GtkWidget *container_widget, int axis, int value)"
.br
.RI "Look for stack entry and triggers OpenGL for drawing\&. "
.ti -1c
.RI "void \fButil_gl_shutdown_all_stacks\fP (void)"
.br
.RI "Look for every stack entry and shutdowns OpenGL for it\&. "
.ti -1c
.RI "GtkWidget * \fBcreate_axis_slider\fP (int axis)"
.br
.RI "Creates a slider widget\&. "
.in -1c
.SH "Detailed Description"
.PP
utilities header
This file is part of Gem-graph\& .
.SH "Function Documentation"
.PP
.SS "GtkWidget * create_axis_slider (int axis)"
.PP
Creates a slider widget\& .
.PP
\fB Parameters\fP
.RS 4
2024-10-20 23:03:17 +02:00
\fI axis\fP meaning which axis we're building (for label)
2024-10-19 16:05:49 +02:00
.RE
.PP
\fB Returns\fP
.RS 4
2024-10-22 23:58:04 +02:00
GtkWidget* pointer to the new widget
2024-10-20 23:03:17 +02:00
.RE
.PP
.SS "char * util_concat (const char * str, \&.\&.\&.)"
.PP
2024-10-26 08:15:20 +02:00
/home/jean/Gem-Graph/gem-graph-client/src/util/strings_op\& .c:63: warning: unable to resolve reference to '\& .\& .\& .' for ref command TODO (.\& .\& .ref desactivated) @ ref https://sourceware.org/glibc/manual/latest/html_mono/libc.html#Variadic-Prototypes
2024-10-20 23:03:17 +02:00
.PP
\fB See also\fP
.RS 4
(in glibc/manual) > ellipsis (‘…’) A\& .2\& .2\& .2 Receiving the Argument Values
2024-10-26 08:15:20 +02:00
.PP
\fB widget_get_selected_rule_conditions_list_btt()\fP
.PP
\fB widget_get_page_measure()\fP
.PP
\fB util_trigger_test()\fP
.PP
\fB on_topbar_right_measure_clicked()\fP
.PP
\fB on_toggle_state_rules_data()\fP
.PP
\fB fsm_set_state_rules_data()\fP
.PP
\fB fsm_set_exec_edit()\fP
.PP
\fB fsm_add_result()\fP
2024-10-20 23:03:17 +02:00
.RE
.PP
\fB Parameters\fP
.RS 4
\fI *str\fP
.br
\fI \& .\& .\& .\fP
.RE
.PP
\fB Returns\fP
.RS 4
*
2024-10-19 16:05:49 +02:00
.RE
.PP
.SS "long util_gl_get_stack (void * container_widget)"
.PP
Look for stack entry and returns stack_id\& .
.PP
\fB Parameters\fP
.RS 4
2024-10-20 23:03:17 +02:00
\fI *container_widget\fP
2024-10-19 16:05:49 +02:00
.RE
.PP
\fB Returns\fP
.RS 4
stack_id
.RE
.PP
.SS "bool util_gl_init_stack (void * container_widget, GError * error_buffer)"
.PP
Look for stack entry and initializes OpenGL for it\& .
.PP
\fB Parameters\fP
.RS 4
2024-10-20 23:03:17 +02:00
\fI *container_widget\fP
2024-10-19 16:05:49 +02:00
.br
2024-10-20 23:03:17 +02:00
\fI *error_buffer\fP
2024-10-19 16:05:49 +02:00
.RE
.PP
\fB Returns\fP
.RS 4
2024-10-20 23:03:17 +02:00
success
.RE
.PP
2024-10-19 16:05:49 +02:00
.SS "bool util_gl_render_stack (GtkWidget * container_widget)"
.PP
Look for stack entry and triggers OpenGL for drawing\& .
.PP
\fB Parameters\fP
.RS 4
\fI container_widget\fP generally the GtkBox that contains the GLArea
.RE
.PP
\fB Returns\fP
.RS 4
bool: true if success
.RE
.PP
.SS "void util_gl_shutdown_all_stacks (void)"
.PP
2024-10-22 23:58:04 +02:00
Look for every stack entry and shutdowns OpenGL for it\& . DO NOT DOCUMENT param void < argument 'void' of command @ param is not found
2024-10-20 23:03:17 +02:00
.PP
2024-10-22 23:58:04 +02:00
DO NOT DOCUMENT returns bool true if success < does not return anything
2024-10-19 16:05:49 +02:00
.SS "bool util_gl_shutdown_stack (void * container_widget, GError * error_buffer)"
.PP
Look for stack entry and shutdowns OpenGL for it\& .
.PP
\fB Parameters\fP
.RS 4
2024-10-22 23:58:04 +02:00
\fI *container_widget\fP
2024-10-19 16:05:49 +02:00
.br
2024-10-20 23:03:17 +02:00
\fI *error_buffer\fP
2024-10-19 16:05:49 +02:00
.RE
.PP
\fB Returns\fP
.RS 4
2024-10-22 23:58:04 +02:00
success
2024-10-19 16:05:49 +02:00
.RE
.PP
.SS "bool util_gl_update_axis (GtkWidget * container_widget, int axis, int value)"
.PP
Look for stack entry and triggers OpenGL for drawing\& .
.PP
\fB Parameters\fP
.RS 4
2024-10-20 23:03:17 +02:00
\fI *container_widget\fP
2024-10-19 16:05:49 +02:00
.br
2024-10-20 23:03:17 +02:00
\fI axis\fP
2024-10-19 16:05:49 +02:00
.br
2024-10-20 23:03:17 +02:00
\fI value\fP
2024-10-19 16:05:49 +02:00
.RE
.PP
\fB Returns\fP
.RS 4
bool: true if success
.RE
.PP
2024-10-20 01:05:12 +02:00
.SS "void util_list_2x2_clear (\fBdblist\fP * l)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.RE
.PP
.SS "void util_list_2x2_init (\fBdblist\fP * l)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.RE
.PP
.SS "int util_list_2x2_length (\fBdblist\fP l)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.RE
.PP
\fB Returns\fP
.RS 4
int
.RE
.PP
.SS "int util_list_2x2_pop_back (\fBdblist\fP * l)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.RE
.PP
\fB Returns\fP
.RS 4
int
.RE
.PP
.SS "int util_list_2x2_pop_front (\fBdblist\fP * l)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.RE
.PP
\fB Returns\fP
.RS 4
int
.RE
.PP
.SS "int util_list_2x2_push_back (\fBdblist\fP * l, int val)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.br
\fI val\fP
.RE
.PP
\fB Returns\fP
.RS 4
int
.RE
.PP
.SS "int util_list_2x2_push_front (\fBdblist\fP * l, int val)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.br
\fI val\fP
.RE
.PP
\fB Returns\fP
.RS 4
int
.RE
.PP
.SS "void util_list_2x2_view (\fBdblist\fP l)"
.PP
Phantom documentation\& .
.PP
\fB Parameters\fP
.RS 4
\fI *l\fP
.RE
.PP
2024-10-20 23:03:17 +02:00
.SS "void util_pile_clear (\fBpile\fP ** p)"
.PP
\fB Parameters\fP
.RS 4
\fI **p\fP
.RE
.PP
.SS "int util_pile_length (\fBpile\fP * p)"
.PP
\fB Parameters\fP
.RS 4
\fI **p\fP
.RE
.PP
\fB Returns\fP
.RS 4
length
.RE
.PP
.SS "int util_pile_pop (\fBpile\fP ** p)"
.PP
\fB Parameters\fP
.RS 4
\fI **p\fP
.RE
.PP
\fB Returns\fP
.RS 4
value
.RE
.PP
.SS "int util_pile_push (\fBpile\fP ** p, int value)"
.PP
\fB Parameters\fP
.RS 4
\fI **p\fP
.br
\fI value\fP
.RE
.PP
\fB Returns\fP
.RS 4
value
.RE
.PP
.SS "void util_pile_view (\fBpile\fP * p)"
.PP
\fB Parameters\fP
.RS 4
\fI **p\fP
.RE
.PP
2024-10-20 01:05:12 +02:00
.SS "char * util_read_file (char * filename)"
.PP
reads a file from filename into a provided buffer
.PP
\fB Parameters\fP
.RS 4
\fI *filename\fP
.RE
.PP
\fB Returns\fP
.RS 4
char
.RE
.PP
2024-10-20 23:03:17 +02:00
.SS "void util_sorted_list_clear (\fBslist\fP ** sl)"
.PP
\fB Parameters\fP
.RS 4
\fI **sl\fP
.RE
.PP
.SS "int util_sorted_list_insert (\fBslist\fP ** sl, int value)"
.PP
\fB Parameters\fP
.RS 4
\fI **sl\fP
.br
\fI value\fP
.RE
.PP
\fB Returns\fP
.RS 4
value
.RE
.PP
.SS "int util_sorted_list_length (\fBslist\fP * sl)"
.PP
\fB Parameters\fP
.RS 4
\fI **sl\fP
.RE
.PP
\fB Returns\fP
.RS 4
length
.RE
.PP
.SS "int util_sorted_list_pop (\fBslist\fP ** sl)"
.PP
\fB Parameters\fP
.RS 4
\fI **sl\fP
.RE
.PP
\fB Returns\fP
.RS 4
value
.RE
.PP
.SS "void util_sorted_list_view (\fBslist\fP * sl)"
.PP
\fB Parameters\fP
.RS 4
\fI **sl\fP
.RE
.PP
2024-10-19 16:05:49 +02:00
.SH "Author"
.PP
Generated automatically by Doxygen for Gem-graph from the source code\& .