Nilorea Library
C utilities for networking, threading, graphics
Loading...
Searching...
No Matches
ex_gui_combobox_items.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "nilorea/n_common.h"
#include "nilorea/n_log.h"
#include "nilorea/n_gui.h"
Include dependency graph for ex_gui_combobox_items.c:

Go to the source code of this file.

Macros

#define ALLEGRO_UNSTABLE   1

Functions

static void add_once (N_GUI_CTX *gui, int combo, const char *text)
static void expect_true (const char *what, int ok)
 record one check
int main (int argc, char **argv)
static void move_to (N_GUI_CTX *gui, float x, float y)
 a move of the pointer to a point, nothing pressed
static void press_at (N_GUI_CTX *gui, float x, float y)
 add a value only when it is not in the list yet, the way a filter built from data does, walking the combobox itself rather than a copy of it
static int process_args (int argc, char **argv)
 parse -V LOG_LEVEL

Variables

static int failures = 0
static int log_level = 3

Macro Definition Documentation

◆ ALLEGRO_UNSTABLE

#define ALLEGRO_UNSTABLE   1

Definition at line 21 of file ex_gui_combobox_items.c.

Function Documentation

◆ add_once()

void add_once ( N_GUI_CTX * gui,
int combo,
const char * text )
static
Examples
ex_gui_combobox_items.c.

Definition at line 88 of file ex_gui_combobox_items.c.

References gui, n_gui_combobox_add_item(), n_gui_combobox_get_count(), and n_gui_combobox_get_item_text().

Referenced by main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ expect_true()

void expect_true ( const char * what,
int ok )
static

record one check

Definition at line 36 of file ex_gui_combobox_items.c.

References failures, LOG_ERR, LOG_INFO, and n_log.

◆ main()

◆ move_to()

void move_to ( N_GUI_CTX * gui,
float x,
float y )
static

a move of the pointer to a point, nothing pressed

Examples
ex_gui_combobox_items.c, and ex_gui_hover.c.

Definition at line 78 of file ex_gui_combobox_items.c.

References gui, and n_gui_process_event().

Referenced by main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ press_at()

void press_at ( N_GUI_CTX * gui,
float x,
float y )
static

add a value only when it is not in the list yet, the way a filter built from data does, walking the combobox itself rather than a copy of it

a press and release of the left button at a point, after a move there

Examples
ex_gui_combobox_items.c, and ex_gui_slider_default.c.

Definition at line 62 of file ex_gui_combobox_items.c.

References gui, and n_gui_process_event().

Referenced by main(), and main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ process_args()

int process_args ( int argc,
char ** argv )
static

parse -V LOG_LEVEL

Definition at line 46 of file ex_gui_combobox_items.c.

References log_level.

Variable Documentation

◆ failures

int failures = 0
static

Definition at line 33 of file ex_gui_combobox_items.c.

◆ log_level

int log_level = 3
static

Definition at line 32 of file ex_gui_combobox_items.c.