lv_sdl_window.h
API reference for lv_sdl_window.h
Summary
Functions
lv_sdl_window_set_resizeable
Allow or forbid resizing the window
void lv_sdl_window_set_resizeable(lv_display_t *disp, bool value)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
value | bool | true: resizeable, false: fixed size |
lv_sdl_window_set_size
Set the size of the window
void lv_sdl_window_set_size(lv_display_t *disp, int32_t hor_res, int32_t ver_res)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
hor_res | int32_t | the new width in pixels |
ver_res | int32_t | the new height in pixels |
lv_sdl_window_set_zoom
Set the zoom factor of the window
void lv_sdl_window_set_zoom(lv_display_t *disp, float zoom)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
zoom | float | the new zoom factor |
lv_sdl_window_set_title
Set the title of the window
void lv_sdl_window_set_title(lv_display_t *disp, const char *title)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
title | const char * | the new title |
lv_sdl_window_set_icon
Set the icon of the window
void lv_sdl_window_set_icon(lv_display_t *disp, void *icon, int32_t width, int32_t height)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
icon | void * | pointer to the ARGB8888 pixels of the icon |
width | int32_t | the icon width in pixels |
height | int32_t | the icon height in pixels |
lv_sdl_window_get_zoom
Get the zoom factor of the window
float lv_sdl_window_get_zoom(lv_display_t *disp)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
Returns: float — the current zoom factor
lv_sdl_window_get_renderer
Get the SDL renderer of the window
void * lv_sdl_window_get_renderer(lv_display_t *disp)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
Returns: void * — pointer to the SDL_Renderer, or NULL on error
lv_sdl_window_get_window
Get the SDL window
struct SDL_Window * lv_sdl_window_get_window(lv_display_t *disp)| Name | Type | Description |
|---|---|---|
disp | lv_display_t * | pointer to an SDL display |
Returns: struct SDL_Window * — pointer to the SDL_Window, or NULL on error
lv_sdl_window_create
lv_display_t * lv_sdl_window_create(int32_t hor_res, int32_t ver_res)| Name | Type |
|---|---|
hor_res | int32_t |
ver_res | int32_t |
lv_sdl_quit
void lv_sdl_quit(void)Dependencies
Last updated on