Skip to content

Devel GTK os_custom

Simeon Andreev edited this page Feb 23, 2023 · 1 revision

TODO

  • Move some of the sections from comprehensive guide to this section. (SWT fixed etc..)

os custom

os_custom.h and os_custom.c contain custom functionality for SWT. Mainly the SWT Fixed container that is used to have exact sizing for layouts such as grid, form and other layouts.

We rebuild these files manually after each change. (TODO - link to swtjnibuild be here)

Printing in os_custom

Gtk buffers stdout, including print statements, as such a printf("... \n"); may not print to screen right away (even with "\n" at the end). To get around this use: gtk logging.

For example:

void g_print(const gchar *format, ...);
void g_message(const gchar *format, ...);
void g_warning(const gchar *format, ...);
void g_error(const gchar *format, ...);    // << this terminates the application. Useful if you want to kill the app if certain code runs.
Clone this wiki locally