__extern caca_canvas_t * caca_create_canvas (int, int)
Initialise a libcaca canvas.
__extern int caca_manage_canvas (caca_canvas_t *, int(*)(void *), void *)
Manage a canvas.
__extern int caca_unmanage_canvas (caca_canvas_t *, int(*)(void *), void *)
unmanage a canvas.
__extern int caca_set_canvas_size (caca_canvas_t *, int, int)
Resize a canvas.
__extern int caca_get_canvas_width (caca_canvas_t const *)
Get the canvas width.
__extern int caca_get_canvas_height (caca_canvas_t const *)
Get the canvas height.
__extern uint32_t const * caca_get_canvas_chars (caca_canvas_t const *)
Get the canvas character array.
__extern uint32_t const * caca_get_canvas_attrs (caca_canvas_t const *)
Get the canvas attribute array.
__extern int caca_free_canvas (caca_canvas_t *)
Free a libcaca canvas.
__extern int caca_rand (int, int)
__extern char const * caca_get_version (void)
Return the libcaca version.
These functions provide the basic libcaca routines for library initialisation, system information retrieval and configuration.
Both the cursor and the canvas' handle are initialised at the top-left corner.
If an error occurs, NULL is returned and errno is set accordingly:
Parameters
Returns
References CACA_DEFAULT, caca_set_color_ansi(), and CACA_TRANSPARENT.
Referenced by caca_conio_movetext(), caca_create_display_with_driver(), caca_export_area_to_memory(), caca_import_area_from_file(), caca_import_area_from_memory(), and caca_set_canvas_boundaries().
This function is only useful for display drivers such as the libcaca library.
If an error occurs, -1 is returned and errno is set accordingly:
Parameters
Returns
Referenced by caca_create_display_with_driver().
this function is only useful for display drivers such as the libcaca library.
if an error occurs, -1 is returned and errno is set accordingly:
Parameters
Returns
Referenced by caca_create_display_with_driver(), and caca_free_display().
The contents of the canvas are preserved to the extent of the new canvas size. Newly allocated character cells at the right and/or at the bottom of the canvas are filled with spaces.
If as a result of the resize the cursor coordinates fall outside the new canvas boundaries, they are readjusted. For instance, if the current X cursor coordinate is 11 and the requested width is 10, the new X cursor coordinate will be 10.
It is an error to try to resize the canvas if an output driver has been attached to the canvas using caca_create_display(). You need to remove the output driver using caca_free_display() before you can change the canvas size again. However, the caca output driver can cause a canvas resize through user interaction. See the caca_event() documentation for more about this.
If an error occurs, -1 is returned and errno is set accordingly:
Parameters
Returns
Referenced by caca_canvas_set_figfont(), caca_flush_figlet(), and caca_put_figchar().
This function never fails.
Parameters
Returns
Referenced by caca_conio_clreol(), caca_conio_movetext(), and caca_get_mouse_x().
This function never fails.
Parameters
Returns
Referenced by caca_flush_figlet(), and caca_get_event_type().
This function is probably only useful for libcaca 's internal display drivers.
This function never fails.
Parameters
Returns
This function is probably only useful for libcaca 's internal display drivers.
This function never fails.
Parameters
Returns
If an error occurs, -1 is returned and errno is set accordingly:
Parameters
Returns
References caca_canvas_set_figfont().
Referenced by caca_canvas_set_figfont(), caca_create_display_with_driver(), caca_export_area_to_memory(), caca_free_display(), caca_import_area_from_file(), and caca_import_area_from_memory().
This function never fails.
Returns
Generated automatically by Doxygen for libcaca from the source code.