libwebsockets
Lightweight C library for HTML5 websockets
Loading...
Searching...
No Matches
lws-dlo.h File Reference
#include <stdint.h>
Include dependency graph for lws-dlo.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  lws_dlo_dim_t
struct  lws_font_glyph
struct  lws_display_id
struct  lws_dlo
struct  lws_circle
struct  lws_dlo_rect
struct  lws_dlo_circle
struct  lws_dlo_hit
struct  lws_font_choice
struct  lws_display_font
struct  lws_dlo_filesystem
struct  lws_dlo_text
struct  lws_dlo_rasterize
struct  lws_dlo_png
struct  lws_dlo_jpeg
struct  lws_dlo_svg
struct  lws_dlo_gif
struct  lws_dlo_image_t
struct  lws_displaylist
struct  lws_dl_rend
struct  lws_display_render_stack
struct  lws_display_render_state
struct  lws_dlo_ss_create_info_t
union  lws_dlo_image_t.u

Macros

#define LWSDC_RGBA(_r, _g, _b, _a)
#define LWSDC_R(_c)
#define LWSDC_G(_c)
#define LWSDC_B(_c)
#define LWSDC_ALPHA(_c)
#define RGB_TO_Y(_r, _g, _b)
#define PALETTE_RGBY(_r, _g, _b)
#define LWSDLO_TEXT_FLAG_WRAP   (1 << 0)
#define LWS_DLO_ASSET_BLOB_DEFAULT_MAX_FOOTPRINT   (64 * 1024 * 1024)
#define LWS_DLO_ASSET_BLOB_MAX_PAYLOAD   (16 * 1024 * 1024)
#define LWS_DLO_ASSET_L1_MAX_FOOTPRINT   (8 * 1024 * 1024)
#define LWS_DLO_ASSET_L1_MAX_ITEMS   256
#define LWS_DLO_ASSET_CACHE_EXPIRY_S   (24 * 60 * 60)
#define lws_dlo_image_width(_u)
#define lws_dlo_image_height(_u)
#define lws_dlo_image_metadata_scan(_u)

Typedefs

typedef struct lws_font_glyph lws_font_glyph_t
typedef lws_stateful_ret_t(* lws_dlo_renderer_t) (struct lws_display_render_state *rs)
typedef lws_font_glyph_t *(* lws_dlo_image_glyph_t) (struct lws_dlo_text *text, uint32_t unicode, char attach)
typedef void(* lws_dlo_destroy_t) (struct lws_dlo *dlo)
typedef struct lws_display_id lws_display_id_t
typedef struct lws_dlo lws_dlo_t
typedef struct lws_circle lws_circle_t
typedef struct lws_dlo_rect lws_dlo_rect_t
typedef struct lws_dlo_circle lws_dlo_circle_t
typedef struct lws_dlo_hit lws_dlo_hit_t
typedef struct lws_font_choice lws_font_choice_t
typedef struct lws_display_font lws_display_font_t
typedef struct lws_dlo_filesystem lws_dlo_filesystem_t
typedef struct lws_dlo_text lws_dlo_text_t
typedef struct lws_dlo_rasterize lws_dlo_rasterize_t
typedef struct lws_dlo_png lws_dlo_png_t
typedef struct lws_dlo_jpeg lws_dlo_jpeg_t
typedef struct lws_dlo_svg lws_dlo_svg_t
typedef struct lws_dlo_gif lws_dlo_gif_t
typedef struct lws_displaylist lws_displaylist_t
typedef struct lws_dl_rend lws_dl_rend_t
typedef struct lws_display_render_stack lws_display_render_stack_t
typedef struct lws_display_render_state lws_display_render_state_t

Enumerations

enum  lws_dlo_cursor_t {
  LWS_DLO_CURSOR_DEFAULT , LWS_DLO_CURSOR_POINTER , LWS_DLO_CURSOR_TEXT , LWS_DLO_CURSOR_CROSSHAIR ,
  LWS_DLO_CURSOR_MOVE , LWS_DLO_CURSOR_WAIT , LWS_DLO_CURSOR_HELP , LWS_DLO_CURSOR_NOT_ALLOWED ,
  LWS_DLO_CURSOR_NONE
}
enum  lws_dlo_image_type_t {
  LWSDLOSS_TYPE_JPEG , LWSDLOSS_TYPE_PNG , LWSDLOSS_TYPE_SVG , LWSDLOSS_TYPE_GIF ,
  LWSDLOSS_TYPE_CSS
}

Functions

LWS_VISIBLE LWS_EXTERN void lws_display_render_free_ids (lws_display_render_state_t *rs)
LWS_VISIBLE LWS_EXTERN lws_display_id_tlws_display_render_add_id (lws_display_render_state_t *rs, const char *id, void *priv)
LWS_VISIBLE LWS_EXTERN lws_display_id_tlws_display_render_get_id (lws_display_render_state_t *rs, const char *id)
LWS_VISIBLE LWS_EXTERN void lws_display_render_dump_ids (lws_dll2_owner_t *ids)
LWS_VISIBLE LWS_EXTERN void lws_dlo_contents (lws_dlo_t *parent, lws_dlo_dim_t *dim)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_adjust_dims (lws_dlo_t *dlo, lws_dlo_dim_t *dim)
LWS_VISIBLE LWS_EXTERN void lws_display_dl_init (lws_displaylist_t *dl, struct lws_display_state *ds)
LWS_VISIBLE LWS_EXTERN void lws_display_dl_dump (lws_displaylist_t *dl)
LWS_VISIBLE LWS_EXTERN void lws_display_list_destroy (struct lws_context *cx, lws_displaylist_t *dl)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_destroy (lws_dlo_t **r)
LWS_VISIBLE LWS_EXTERN int lws_display_dlo_add (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, lws_dlo_t *dlo)
LWS_VISIBLE LWS_EXTERN int lws_dlo_ensure_err_diff (lws_dlo_t *dlo)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_list_render_line (lws_display_render_state_t *rs)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_get_ids_boxes (lws_display_render_state_t *rs)
LWS_VISIBLE LWS_EXTERN lws_dlo_rect_tlws_display_dlo_rect_new (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, lws_box_t *box, const lws_fx_t *radii, lws_display_colour_t dc)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_rect (struct lws_display_render_state *rs)
LWS_VISIBLE LWS_EXTERN lws_dlo_hit_tlws_display_dlo_hit_new (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, const lws_box_t *box, const char *url, size_t url_len)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_hit_destroy (struct lws_dlo *dlo)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_hit (struct lws_display_render_state *rs)
LWS_VISIBLE LWS_EXTERN lws_dlo_hit_tlws_display_dl_hit_test (lws_displaylist_t *dl, int x, int y, lws_box_t *abox)
LWS_VISIBLE LWS_EXTERN lws_dlo_cursor_t lws_display_dl_cursor_at (lws_displaylist_t *dl, int x, int y)
LWS_VISIBLE LWS_EXTERN lws_dlo_text_tlws_display_dlo_text_new (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, lws_box_t *box, const lws_display_font_t *font)
LWS_VISIBLE LWS_EXTERN int lws_display_dlo_text_update (lws_dlo_text_t *text, lws_display_colour_t dc, lws_fx_t indent, const char *utf8, size_t text_len)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_text_measure (lws_dlo_text_t *text, const char *utf8, size_t text_len, lws_fx_t *total, lws_fx_t *longest_word)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_text_destroy (struct lws_dlo *dlo)
LWS_VISIBLE LWS_EXTERN lws_dlo_png_tlws_display_dlo_png_new (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, lws_box_t *box, const char *name, size_t len)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_png (struct lws_display_render_state *rs)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_png_metadata_scan (lws_dlo_png_t *dp)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_png_destroy (struct lws_dlo *dlo)
LWS_VISIBLE LWS_EXTERN lws_dlo_jpeg_tlws_display_dlo_jpeg_new (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, lws_box_t *box, const char *name, size_t len)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_jpeg (struct lws_display_render_state *rs)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_jpeg_metadata_scan (lws_dlo_jpeg_t *dj)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_jpeg_destroy (struct lws_dlo *dlo)
LWS_VISIBLE LWS_EXTERN lws_dlo_svg_tlws_display_dlo_svg_new (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, lws_box_t *box, const char *name, size_t len)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_svg (struct lws_display_render_state *rs)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_svg_metadata_scan (lws_dlo_svg_t *ds)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_svg_destroy (struct lws_dlo *dlo)
LWS_VISIBLE LWS_EXTERN lws_dlo_gif_tlws_display_dlo_gif_new (lws_displaylist_t *dl, lws_dlo_t *dlo_parent, lws_box_t *box, const char *name, size_t len)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_gif (struct lws_display_render_state *rs)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_gif_metadata_scan (lws_dlo_gif_t *dg)
LWS_VISIBLE LWS_EXTERN void lws_display_dlo_gif_destroy (struct lws_dlo *dlo)
LWS_VISIBLE LWS_EXTERN int lws_display_dlo_gif_rx (lws_dlo_gif_t *dlo_gif, const uint8_t *buf, size_t len)
LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_create (lws_dlo_ss_create_info_t *i, lws_dlo_t **pdlo)
LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_find (struct lws_context *cx, const char *url, lws_dlo_image_t *u)
LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_assets_active (struct lws_context *cx)
LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_stop_any_active (struct lws_context *cx)
LWS_VISIBLE LWS_EXTERN void lws_dlo_ss_detach_lhp (struct lws_context *cx, struct lhp_ctx *lhp)
LWS_VISIBLE LWS_EXTERN void lws_dlo_ss_renew_images (struct lws_context *cx)
LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_renew_image (struct lws_context *cx, lws_dlo_t *dlo)
LWS_VISIBLE LWS_EXTERN struct lws_cache_ttl_lru * lws_dlo_asset_cache (struct lws_context *cx)
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lhp_displaylist_layout (struct lhp_ctx *ctx, char reason)
LWS_VISIBLE LWS_EXTERN int lws_font_register (struct lws_context *cx, const uint8_t *data, size_t data_len)
LWS_VISIBLE LWS_EXTERN int lws_font_register_file (struct lws_context *cx, const char *path)
LWS_VISIBLE LWS_EXTERN int lws_fonts_register_dir (struct lws_context *cx, const char *dirpath)
LWS_VISIBLE LWS_EXTERN const lws_display_font_tlws_font_choose (struct lws_context *cx, const lws_font_choice_t *hints)
LWS_VISIBLE LWS_EXTERN void lws_fonts_destroy (struct lws_context *cx)
LWS_VISIBLE LWS_EXTERN lws_dlo_filesystem_tlws_dlo_file_register (struct lws_context *cx, const lws_dlo_filesystem_t *f)
LWS_VISIBLE LWS_EXTERN void lws_dlo_file_unregister (lws_dlo_filesystem_t **f)
LWS_VISIBLE LWS_EXTERN void lws_dlo_file_unregister_by_name (struct lws_context *cx, const char *name)
LWS_VISIBLE LWS_EXTERN const lws_dlo_filesystem_tlws_dlo_file_choose (struct lws_context *cx, const char *name)
LWS_VISIBLE LWS_EXTERN void lws_dlo_file_destroy (struct lws_context *cx)

Variables

LWS_VISIBLE LWS_EXTERN_FOR_DATA const struct lws_plat_file_ops lws_dlo_fops

Data Structure Documentation

◆ lws_dlo_dim_t

struct lws_dlo_dim_t

Definition at line 55 of file lws-dlo.h.

Collaboration diagram for lws_dlo_dim_t:
Data Fields
lws_fx_t w
lws_fx_t h

◆ lws_font_glyph

struct lws_font_glyph

Definition at line 66 of file lws-dlo.h.

Collaboration diagram for lws_font_glyph:
Data Fields
lws_dll2_t list
lws_fx_t xorg
lws_fx_t xpx
lws_fx_t height
lws_fx_t cwidth
int8_t x
void * pin

◆ lws_display_id

struct lws_display_id

Definition at line 85 of file lws-dlo.h.

Collaboration diagram for lws_display_id:
Data Fields
lws_dll2_t list
char id[16]
lws_box_t box
void * priv_user
void * priv_driver
char exists
char iframe

◆ lws_dlo

struct lws_dlo

Definition at line 107 of file lws-dlo.h.

Collaboration diagram for lws_dlo:
Data Fields
lws_dll2_t list
lws_dll2_t col_list
lws_dll2_t row_list
lws_dll2_owner_t children
lws_dll2_owner_t table_cols
lws_dll2_owner_t table_rows
struct lws_dlo * abut_x
struct lws_dlo * abut_y
lws_dlo_destroy_t _destroy
lws_dlo_renderer_t render
lws_fx_t margin[4]
lws_fx_t padding[4]
lws_display_id_t * id
lws_box_t box
lws_display_colour_t dc
uint8_t budget
int16_t base_up
uint8_t flag_toplevel:1
uint8_t flag_block:1
uint8_t flag_row:1
uint8_t flag_cell:1
uint8_t flag_abs:1
uint8_t flag_float:1
uint8_t flag_zraise:1
uint8_t flag_online:1
uint8_t flag_bg_homed:1
uint8_t flag_inline_bg:1
uint8_t flag_flex_item:1
uint8_t flag_fixed_h:1
uint8_t flag_abs_stretch:1
uint8_t flex_grow
uint8_t align_self

◆ lws_circle

struct lws_circle

Definition at line 172 of file lws-dlo.h.

Collaboration diagram for lws_circle:
Data Fields
lws_fx_t r
lws_fx_t orx
lws_fx_t ory
lws_fx_t rsq
lws_fx_t ys

◆ lws_dlo_rect

struct lws_dlo_rect

Definition at line 182 of file lws-dlo.h.

Collaboration diagram for lws_dlo_rect:
Data Fields
lws_dlo_t dlo
lws_circle_t c[4]
lws_fx_t b[4]
lws_display_colour_t dcb
lws_fx_t btm
lws_fx_t right
lws_box_t db
uint8_t init
uint8_t alt
uint8_t tri

◆ lws_dlo_circle

struct lws_dlo_circle

Definition at line 202 of file lws-dlo.h.

Collaboration diagram for lws_dlo_circle:
Data Fields
lws_dlo_t dlo

◆ lws_dlo_hit

struct lws_dlo_hit

Definition at line 232 of file lws-dlo.h.

Collaboration diagram for lws_dlo_hit:
Data Fields
lws_dlo_t dlo
const char * url
uint8_t fill
uint8_t cursor

◆ lws_font_choice

struct lws_font_choice

Definition at line 242 of file lws-dlo.h.

Collaboration diagram for lws_font_choice:
Data Fields
const char * family_name
const char * generic_name
uint16_t weight
uint16_t style
uint16_t fixed_height

◆ lws_display_font

struct lws_display_font

Definition at line 250 of file lws-dlo.h.

Collaboration diagram for lws_display_font:
Data Fields
lws_dll2_t list
lws_font_choice_t choice
const uint8_t * data
uint8_t * priv
size_t data_len
lws_dlo_renderer_t renderer
lws_dlo_image_glyph_t image_glyph
lws_fx_t em
lws_fx_t ex

◆ lws_dlo_filesystem

struct lws_dlo_filesystem

Definition at line 265 of file lws-dlo.h.

Collaboration diagram for lws_dlo_filesystem:
Data Fields
lws_dll2_t list
const char * name
const void * data
size_t len

◆ lws_dlo_text

struct lws_dlo_text

Definition at line 275 of file lws-dlo.h.

Collaboration diagram for lws_dlo_text:
Data Fields
lws_dlo_t dlo
const lws_display_font_t * font
lws_dll2_owner_t glyphs
lws_box_t bounding_box
const struct lws_surface_info * ic
struct lwsac * ac_glyphs
uint8_t * line
uint16_t curr
uint16_t glyph_row
char * text
uint8_t * kern
size_t text_len
lws_display_list_coord_t clkernpx
lws_display_list_coord_t cwidth
lws_fx_t indent
uint32_t flags
int16_t font_y_baseline
int16_t font_height
int16_t font_line_height
int16_t group_height
int16_t group_y_baseline
lws_fx_t _cwidth

◆ lws_dlo_rasterize

struct lws_dlo_rasterize

Definition at line 310 of file lws-dlo.h.

Collaboration diagram for lws_dlo_rasterize:
Data Fields
lws_dll2_owner_t owner
lws_sorted_usec_list_t sul
int lines

◆ lws_dlo_png

struct lws_dlo_png

Definition at line 316 of file lws-dlo.h.

Collaboration diagram for lws_dlo_png:
Data Fields
lws_dlo_t dlo
lws_flow_t flow
char name[25]
lws_upng_t * png
uint32_t emitted
uint8_t * row
uint32_t row_len
lws_reclaimable_t rc
uint8_t evicted
uint8_t yields

◆ lws_dlo_jpeg

struct lws_dlo_jpeg

Definition at line 332 of file lws-dlo.h.

Collaboration diagram for lws_dlo_jpeg:
Data Fields
lws_dlo_t dlo
lws_flow_t flow
char name[25]
lws_jpeg_t * j
uint32_t emitted
uint8_t * row
uint32_t row_len
lws_reclaimable_t rc
uint8_t evicted

◆ lws_dlo_svg

struct lws_dlo_svg

Definition at line 347 of file lws-dlo.h.

Collaboration diagram for lws_dlo_svg:
Data Fields
lws_dlo_t dlo
lws_flow_t flow
char name[25]
lws_svg_t * svg

◆ lws_dlo_gif

struct lws_dlo_gif

Definition at line 362 of file lws-dlo.h.

Collaboration diagram for lws_dlo_gif:
Data Fields
lws_dlo_t dlo
lws_flow_t flow
char name[25]
lws_gif_t * gif
uint8_t * whole
size_t whole_len
size_t whole_size
size_t pos
char whole_done

◆ lws_displaylist

struct lws_displaylist

Definition at line 393 of file lws-dlo.h.

Collaboration diagram for lws_displaylist:
Data Fields
lws_dll2_owner_t dl
struct lws_display_state * ds

◆ lws_dl_rend

struct lws_dl_rend

Definition at line 398 of file lws-dlo.h.

Collaboration diagram for lws_dl_rend:
Data Fields
lws_displaylist_t * dl
int w
int h
char clipped

◆ lws_display_render_stack

struct lws_display_render_stack

Definition at line 406 of file lws-dlo.h.

Collaboration diagram for lws_display_render_stack:
Data Fields
lws_dlo_t * dlo
lws_box_t co

◆ lws_display_render_state

struct lws_display_render_state

Definition at line 411 of file lws-dlo.h.

Collaboration diagram for lws_display_render_state:
Data Fields
lws_sorted_usec_list_t sul
struct lws_display_state * lds
lws_dll2_owner_t ids
const struct lws_surface_info * ic
lws_display_render_stack_t st[64]
int sp
uint8_t * line
lws_displaylist_t displaylist
struct lws_ss_handle * hss_html
lws_display_scalar curr
lws_display_scalar lowest_id_y
char html
char retained
char layout_clipped
int32_t viewport_h

◆ lws_dlo_ss_create_info_t

struct lws_dlo_ss_create_info_t

Definition at line 706 of file lws-dlo.h.

Collaboration diagram for lws_dlo_ss_create_info_t:
Data Fields
struct lws_context * cx
lws_displaylist_t * dl
lws_dlo_t * dlo_parent
lws_box_t * box
sul_cb_t on_rx
lws_sorted_usec_list_t * on_rx_sul
const char * url
struct lhp_ctx * lhp
lws_dlo_image_t * u
int32_t window
uint8_t type

◆ lws_dlo_image_t.u

union lws_dlo_image_t.u

Definition at line 383 of file lws-dlo.h.

Collaboration diagram for lws_dlo_image_t.u:
Data Fields
lws_dlo_jpeg_t * dlo_jpeg
lws_dlo_png_t * dlo_png
lws_dlo_svg_t * dlo_svg
lws_dlo_gif_t * dlo_gif

Macro Definition Documentation

◆ LWSDC_RGBA

#define LWSDC_RGBA ( _r,
_g,
_b,
_a )
Value:
(((uint32_t)(_r) & 0xff) | \
(((uint32_t)(_g) & 0xff) << 8) | \
(((uint32_t)(_b) & 0xff) << 16) | \
(((uint32_t)(_a) & 0xff) << 24))
unsigned int uint32_t

Definition at line 41 of file lws-dlo.h.

41#define LWSDC_RGBA(_r, _g, _b, _a) (((uint32_t)(_r) & 0xff) | \
42 (((uint32_t)(_g) & 0xff) << 8) | \
43 (((uint32_t)(_b) & 0xff) << 16) | \
44 (((uint32_t)(_a) & 0xff) << 24))

◆ LWSDC_R

#define LWSDC_R ( _c)
Value:
((_c) & 0xff)

Definition at line 46 of file lws-dlo.h.

◆ LWSDC_G

#define LWSDC_G ( _c)
Value:
((_c >> 8) & 0xff)

Definition at line 47 of file lws-dlo.h.

◆ LWSDC_B

#define LWSDC_B ( _c)
Value:
((_c >> 16) & 0xff)

Definition at line 48 of file lws-dlo.h.

◆ LWSDC_ALPHA

#define LWSDC_ALPHA ( _c)
Value:
((_c >> 24) & 0xff)

Definition at line 49 of file lws-dlo.h.

◆ RGB_TO_Y

#define RGB_TO_Y ( _r,
_g,
_b )
Value:
((((_r) * 299) + ((_g) * 587) + ((_b) * 114)) / 1000)

Definition at line 51 of file lws-dlo.h.

◆ PALETTE_RGBY

#define PALETTE_RGBY ( _r,
_g,
_b )
Value:
LWSDC_RGBA(_r, _g, _b, (RGB_TO_Y(_r, _g, _b)))
#define LWSDC_RGBA(_r, _g, _b, _a)
Definition lws-dlo.h:41
#define RGB_TO_Y(_r, _g, _b)
Definition lws-dlo.h:51

Definition at line 53 of file lws-dlo.h.

◆ LWSDLO_TEXT_FLAG_WRAP

#define LWSDLO_TEXT_FLAG_WRAP   (1 << 0)

Definition at line 273 of file lws-dlo.h.

◆ LWS_DLO_ASSET_BLOB_DEFAULT_MAX_FOOTPRINT

#define LWS_DLO_ASSET_BLOB_DEFAULT_MAX_FOOTPRINT   (64 * 1024 * 1024)

default max bytes on disk for the asset cache, when the context creation info gives 0 for dlo_asset_cache_max_footprint

Definition at line 802 of file lws-dlo.h.

◆ LWS_DLO_ASSET_BLOB_MAX_PAYLOAD

#define LWS_DLO_ASSET_BLOB_MAX_PAYLOAD   (16 * 1024 * 1024)

individual assets larger than this are not cached

Definition at line 808 of file lws-dlo.h.

◆ LWS_DLO_ASSET_L1_MAX_FOOTPRINT

#define LWS_DLO_ASSET_L1_MAX_FOOTPRINT   (8 * 1024 * 1024)

max heap bytes for the in-memory level of the asset cache

Definition at line 813 of file lws-dlo.h.

◆ LWS_DLO_ASSET_L1_MAX_ITEMS

#define LWS_DLO_ASSET_L1_MAX_ITEMS   256

max items in the in-memory level of the asset cache

Definition at line 818 of file lws-dlo.h.

◆ LWS_DLO_ASSET_CACHE_EXPIRY_S

#define LWS_DLO_ASSET_CACHE_EXPIRY_S   (24 * 60 * 60)

how long fetched assets stay valid in the cache, in seconds. Set to 0 to keep them until the cache needs the space (LRU eviction)

Definition at line 823 of file lws-dlo.h.

◆ lws_dlo_image_width

#define lws_dlo_image_width ( _u)
Value:
((_u)->failed ? -1 : \
((_u)->type == LWSDLOSS_TYPE_JPEG ? \
(int)lws_jpeg_get_width((_u)->u.dlo_jpeg->j) : \
(int)lws_upng_get_width((_u)->u.dlo_png->png)))
@ LWSDLOSS_TYPE_JPEG
Definition lws-dlo.h:375
LWS_VISIBLE LWS_EXTERN unsigned int lws_jpeg_get_width(const lws_jpeg_t *j)
LWS_VISIBLE LWS_EXTERN unsigned int lws_upng_get_width(const lws_upng_t *upng)

Definition at line 924 of file lws-dlo.h.

924#define lws_dlo_image_width(_u) ((_u)->failed ? -1 : \
925 ((_u)->type == LWSDLOSS_TYPE_JPEG ? \
926 (int)lws_jpeg_get_width((_u)->u.dlo_jpeg->j) : \
927 (int)lws_upng_get_width((_u)->u.dlo_png->png)))

◆ lws_dlo_image_height

#define lws_dlo_image_height ( _u)
Value:
((_u)->failed ? -1 : \
((_u)->type == LWSDLOSS_TYPE_JPEG ? \
(int)lws_jpeg_get_height((_u)->u.dlo_jpeg->j) : \
(int)lws_upng_get_height((_u)->u.dlo_png->png)))
LWS_VISIBLE LWS_EXTERN unsigned int lws_jpeg_get_height(const lws_jpeg_t *j)
LWS_VISIBLE LWS_EXTERN unsigned int lws_upng_get_height(const lws_upng_t *upng)

Definition at line 928 of file lws-dlo.h.

928#define lws_dlo_image_height(_u) ((_u)->failed ? -1 : \
929 ((_u)->type == LWSDLOSS_TYPE_JPEG ? \
930 (int)lws_jpeg_get_height((_u)->u.dlo_jpeg->j) : \
931 (int)lws_upng_get_height((_u)->u.dlo_png->png)))

◆ lws_dlo_image_metadata_scan

#define lws_dlo_image_metadata_scan ( _u)
Value:
((_u)->failed ? LWS_SRET_FATAL : \
((_u)->type == LWSDLOSS_TYPE_JPEG ? \
lws_display_dlo_jpeg_metadata_scan((_u)->u.dlo_jpeg) : \
@ LWS_SRET_FATAL
LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_png_metadata_scan(lws_dlo_png_t *dp)

Definition at line 933 of file lws-dlo.h.

933#define lws_dlo_image_metadata_scan(_u) ((_u)->failed ? LWS_SRET_FATAL : \
934 ((_u)->type == LWSDLOSS_TYPE_JPEG ? \
935 lws_display_dlo_jpeg_metadata_scan((_u)->u.dlo_jpeg) : \
936 lws_display_dlo_png_metadata_scan((_u)->u.dlo_png)))

Typedef Documentation

◆ lws_font_glyph_t

◆ lws_dlo_renderer_t

typedef lws_stateful_ret_t(* lws_dlo_renderer_t) (struct lws_display_render_state *rs)

Definition at line 79 of file lws-dlo.h.

◆ lws_dlo_image_glyph_t

typedef lws_font_glyph_t *(* lws_dlo_image_glyph_t) (struct lws_dlo_text *text, uint32_t unicode, char attach)

Definition at line 80 of file lws-dlo.h.

◆ lws_dlo_destroy_t

typedef void(* lws_dlo_destroy_t) (struct lws_dlo *dlo)

Definition at line 83 of file lws-dlo.h.

◆ lws_display_id_t

◆ lws_dlo_t

typedef struct lws_dlo lws_dlo_t

◆ lws_circle_t

typedef struct lws_circle lws_circle_t

◆ lws_dlo_rect_t

typedef struct lws_dlo_rect lws_dlo_rect_t

◆ lws_dlo_circle_t

◆ lws_dlo_hit_t

typedef struct lws_dlo_hit lws_dlo_hit_t

◆ lws_font_choice_t

◆ lws_display_font_t

◆ lws_dlo_filesystem_t

◆ lws_dlo_text_t

typedef struct lws_dlo_text lws_dlo_text_t

◆ lws_dlo_rasterize_t

◆ lws_dlo_png_t

typedef struct lws_dlo_png lws_dlo_png_t

◆ lws_dlo_jpeg_t

typedef struct lws_dlo_jpeg lws_dlo_jpeg_t

◆ lws_dlo_svg_t

typedef struct lws_dlo_svg lws_dlo_svg_t

◆ lws_dlo_gif_t

typedef struct lws_dlo_gif lws_dlo_gif_t

◆ lws_displaylist_t

◆ lws_dl_rend_t

typedef struct lws_dl_rend lws_dl_rend_t

◆ lws_display_render_stack_t

◆ lws_display_render_state_t

Enumeration Type Documentation

◆ lws_dlo_cursor_t

Enumerator
LWS_DLO_CURSOR_DEFAULT 
LWS_DLO_CURSOR_POINTER 
LWS_DLO_CURSOR_TEXT 
LWS_DLO_CURSOR_CROSSHAIR 
LWS_DLO_CURSOR_MOVE 
LWS_DLO_CURSOR_WAIT 
LWS_DLO_CURSOR_HELP 
LWS_DLO_CURSOR_NOT_ALLOWED 
LWS_DLO_CURSOR_NONE 

Definition at line 220 of file lws-dlo.h.

220 {
221 LWS_DLO_CURSOR_DEFAULT, /* the platform arrow */
222 LWS_DLO_CURSOR_POINTER, /* pointing hand: links, buttons */
223 LWS_DLO_CURSOR_TEXT, /* I-beam: editable / selectable text */
229 LWS_DLO_CURSOR_NONE, /* hidden */
lws_dlo_cursor_t
Definition lws-dlo.h:220
@ LWS_DLO_CURSOR_NONE
Definition lws-dlo.h:229
@ LWS_DLO_CURSOR_WAIT
Definition lws-dlo.h:226
@ LWS_DLO_CURSOR_HELP
Definition lws-dlo.h:227
@ LWS_DLO_CURSOR_CROSSHAIR
Definition lws-dlo.h:224
@ LWS_DLO_CURSOR_DEFAULT
Definition lws-dlo.h:221
@ LWS_DLO_CURSOR_POINTER
Definition lws-dlo.h:222
@ LWS_DLO_CURSOR_NOT_ALLOWED
Definition lws-dlo.h:228
@ LWS_DLO_CURSOR_TEXT
Definition lws-dlo.h:223
@ LWS_DLO_CURSOR_MOVE
Definition lws-dlo.h:225

◆ lws_dlo_image_type_t

Enumerator
LWSDLOSS_TYPE_JPEG 
LWSDLOSS_TYPE_PNG 
LWSDLOSS_TYPE_SVG 
LWSDLOSS_TYPE_GIF 
LWSDLOSS_TYPE_CSS 

Definition at line 374 of file lws-dlo.h.

374 {
lws_dlo_image_type_t
Definition lws-dlo.h:374
@ LWSDLOSS_TYPE_SVG
Definition lws-dlo.h:377
@ LWSDLOSS_TYPE_CSS
Definition lws-dlo.h:379
@ LWSDLOSS_TYPE_PNG
Definition lws-dlo.h:376
@ LWSDLOSS_TYPE_GIF
Definition lws-dlo.h:378

Function Documentation

◆ lws_display_render_free_ids()

LWS_VISIBLE LWS_EXTERN void lws_display_render_free_ids ( lws_display_render_state_t * rs)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_add_id()

LWS_VISIBLE LWS_EXTERN lws_display_id_t * lws_display_render_add_id ( lws_display_render_state_t * rs,
const char * id,
void * priv )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_get_id()

LWS_VISIBLE LWS_EXTERN lws_display_id_t * lws_display_render_get_id ( lws_display_render_state_t * rs,
const char * id )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_dump_ids()

LWS_VISIBLE LWS_EXTERN void lws_display_render_dump_ids ( lws_dll2_owner_t * ids)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_contents()

LWS_VISIBLE LWS_EXTERN void lws_dlo_contents ( lws_dlo_t * parent,
lws_dlo_dim_t * dim )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_adjust_dims()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_adjust_dims ( lws_dlo_t * dlo,
lws_dlo_dim_t * dim )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dl_init()

LWS_VISIBLE LWS_EXTERN void lws_display_dl_init ( lws_displaylist_t * dl,
struct lws_display_state * ds )

lws_display_dl_init() - init display list object

Parameters
dlPointer to the display list
dsLws display state to bind the list to

Initializes the display list dl and binds it to the display state ds.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dl_dump()

LWS_VISIBLE LWS_EXTERN void lws_display_dl_dump ( lws_displaylist_t * dl)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_list_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_list_destroy ( struct lws_context * cx,
lws_displaylist_t * dl )

lws_display_list_destroy() - destroys display list and objects on it

Parameters
cxlws_context
dlPointer to the display list

Destroys every DLO on the list.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_destroy ( lws_dlo_t ** r)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_add()

LWS_VISIBLE LWS_EXTERN int lws_display_dlo_add ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
lws_dlo_t * dlo )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_ensure_err_diff()

LWS_VISIBLE LWS_EXTERN int lws_dlo_ensure_err_diff ( lws_dlo_t * dlo)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_list_render_line()

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_get_ids_boxes()

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_rect_new()

LWS_VISIBLE LWS_EXTERN lws_dlo_rect_t * lws_display_dlo_rect_new ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
lws_box_t * box,
const lws_fx_t * radii,
lws_display_colour_t dc )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_rect()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_rect ( struct lws_display_render_state * rs)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_hit_new()

LWS_VISIBLE LWS_EXTERN lws_dlo_hit_t * lws_display_dlo_hit_new ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
const lws_box_t * box,
const char * url,
size_t url_len )

lws_display_dlo_hit_new() - add a non-printing hit region to the display list

Parameters
dlthe display list
dlo_parentthe dlo whose child it becomes, or NULL for the list head
boxits box relative to the parent, or NULL for all zeros
urlthe url (or other metadata string) the region carries, or NULL
url_lenthe length of url

The url is copied into the region's own allocation. Set .fill on the result for a region that always has its parent's size, and .cursor to the lws_dlo_cursor_t the pointer should take over it.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_hit_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_hit_destroy ( struct lws_dlo * dlo)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_hit()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_hit ( struct lws_display_render_state * rs)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dl_hit_test()

LWS_VISIBLE LWS_EXTERN lws_dlo_hit_t * lws_display_dl_hit_test ( lws_displaylist_t * dl,
int x,
int y,
lws_box_t * abox )

lws_display_dl_hit_test() - find the hit region at a point

Parameters
dlthe display list
xx in the display list's coordinates
yy in the display list's coordinates
aboxNULL, or filled with the region's absolute box if one is hit

Returns the topmost hit region containing the point, or NULL if none. For a laid-out html document the coordinates are those of the document, so a viewport offset must be added to a window position first.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dl_cursor_at()

LWS_VISIBLE LWS_EXTERN lws_dlo_cursor_t lws_display_dl_cursor_at ( lws_displaylist_t * dl,
int x,
int y )

lws_display_dl_cursor_at() - the pointer shape for a point

Parameters
dlthe display list
xx in the display list's coordinates
yy in the display list's coordinates

Returns the cursor the topmost hit region containing the point asks for, or LWS_DLO_CURSOR_DEFAULT if there is none. A windowing app calls this on pointer motion and sets the platform cursor to match.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_text_new()

LWS_VISIBLE LWS_EXTERN lws_dlo_text_t * lws_display_dlo_text_new ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
lws_box_t * box,
const lws_display_font_t * font )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_text_update()

LWS_VISIBLE LWS_EXTERN int lws_display_dlo_text_update ( lws_dlo_text_t * text,
lws_display_colour_t dc,
lws_fx_t indent,
const char * utf8,
size_t text_len )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_text_measure()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_text_measure ( lws_dlo_text_t * text,
const char * utf8,
size_t text_len,
lws_fx_t * total,
lws_fx_t * longest_word )

lws_display_dlo_text_measure() - width of a string in a text dlo's font

text: a text dlo, used for its font utf8: the string text_len: its length in bytes total: set to the width if laid out on one line longest_word: set to the width of the widest space-delimited word

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_text_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_text_destroy ( struct lws_dlo * dlo)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_png_new()

LWS_VISIBLE LWS_EXTERN lws_dlo_png_t * lws_display_dlo_png_new ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
lws_box_t * box,
const char * name,
size_t len )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_png()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_png ( struct lws_display_render_state * rs)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_png_metadata_scan()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_png_metadata_scan ( lws_dlo_png_t * dp)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_png_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_png_destroy ( struct lws_dlo * dlo)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_jpeg_new()

LWS_VISIBLE LWS_EXTERN lws_dlo_jpeg_t * lws_display_dlo_jpeg_new ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
lws_box_t * box,
const char * name,
size_t len )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_jpeg()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_jpeg ( struct lws_display_render_state * rs)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_jpeg_metadata_scan()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_jpeg_metadata_scan ( lws_dlo_jpeg_t * dj)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_jpeg_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_jpeg_destroy ( struct lws_dlo * dlo)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_svg_new()

LWS_VISIBLE LWS_EXTERN lws_dlo_svg_t * lws_display_dlo_svg_new ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
lws_box_t * box,
const char * name,
size_t len )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_svg()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_svg ( struct lws_display_render_state * rs)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_svg_metadata_scan()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_svg_metadata_scan ( lws_dlo_svg_t * ds)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_svg_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_svg_destroy ( struct lws_dlo * dlo)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_gif_new()

LWS_VISIBLE LWS_EXTERN lws_dlo_gif_t * lws_display_dlo_gif_new ( lws_displaylist_t * dl,
lws_dlo_t * dlo_parent,
lws_box_t * box,
const char * name,
size_t len )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_render_gif()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_render_gif ( struct lws_display_render_state * rs)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_gif_metadata_scan()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lws_display_dlo_gif_metadata_scan ( lws_dlo_gif_t * dg)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_gif_destroy()

LWS_VISIBLE LWS_EXTERN void lws_display_dlo_gif_destroy ( struct lws_dlo * dlo)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_display_dlo_gif_rx()

LWS_VISIBLE LWS_EXTERN int lws_display_dlo_gif_rx ( lws_dlo_gif_t * dlo_gif,
const uint8_t * buf,
size_t len )

◆ lws_dlo_ss_create()

LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_create ( lws_dlo_ss_create_info_t * i,
lws_dlo_t ** pdlo )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_ss_find()

LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_find ( struct lws_context * cx,
const char * url,
lws_dlo_image_t * u )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_ss_assets_active()

LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_assets_active ( struct lws_context * cx)

lws_dlo_ss_assets_active() - are any document assets fetching or queued?

Parameters
cxthe lws_context

Returns nonzero if any image or stylesheet asset is being fetched, or is queued waiting for an in-flight slot. A document whose own stream has ended should defer considering itself complete until this returns 0.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_ss_stop_any_active()

LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_stop_any_active ( struct lws_context * cx)

lws_dlo_ss_stop_any_active() - destroy all tracked document assets

Parameters
cxthe lws_context

Destroys every document asset that is fetching or queued for a fetch slot, if any. Used to tear a document down; see lws_lhp_ss_cancel().

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_ss_detach_lhp()

LWS_VISIBLE LWS_EXTERN void lws_dlo_ss_detach_lhp ( struct lws_context * cx,
struct lhp_ctx * lhp )

lws_dlo_ss_detach_lhp() - forget a document parser in its asset streams

Parameters
cxthe lws context
lhpthe html parser context that is about to be destroyed

Asset streams (images, stylesheets) created for a document keep pointers to its parser context and to the sul and callback of the stream that owns it, to resume the parse when they have something. If that stream is destroyed while assets are still in flight (a failure of the html stream, a context destroy), call this from its DESTROYING so the assets stop referring to memory that is going away; they then finish or fail on their own and are destroyed with their dlos or by lws_dlo_ss_stop_any_active().

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_ss_renew_images()

LWS_VISIBLE LWS_EXTERN void lws_dlo_ss_renew_images ( struct lws_context * cx)

lws_dlo_ss_renew_images() - reset tracked images for a re-scan

Parameters
cxthe lws_context

Image decode state only moves forwards, but a retained display list can be re-scanned at a different vertical offset (eg, an interactive viewport scrolling). This re-stashes each tracked image's payload from the document asset cache and gives it a fresh decoder, so the next scan can decode the rows the viewport wants. Images not in the cache are left as they are.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_ss_renew_image()

LWS_VISIBLE LWS_EXTERN int lws_dlo_ss_renew_image ( struct lws_context * cx,
lws_dlo_t * dlo )

lws_dlo_ss_renew_image() - re-stash one image's payload from the asset cache

Parameters
cxthe lws context
dlothe png or jpeg dlo

As lws_dlo_ss_renew_images() for one image whose payload and decoder were evicted to make room: returns 0 if it is decodable again.

◆ lws_dlo_asset_cache()

LWS_VISIBLE LWS_EXTERN struct lws_cache_ttl_lru * lws_dlo_asset_cache ( struct lws_context * cx)

lws_dlo_asset_cache() - get the context's document asset cache, if any

Parameters
cxthe lws_context

Returns NULL if the context was created without dlo_asset_cache_dir, else the L1 cache handle of the context asset cache, for inspection or manual invalidation using the lws_cache_ttl apis. The cache belongs to the context and is destroyed with it.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lhp_displaylist_layout()

LWS_VISIBLE LWS_EXTERN lws_stateful_ret_t lhp_displaylist_layout ( struct lhp_ctx * ctx,
char reason )

◆ lws_font_register()

LWS_VISIBLE LWS_EXTERN int lws_font_register ( struct lws_context * cx,
const uint8_t * data,
size_t data_len )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_font_register_file()

LWS_VISIBLE LWS_EXTERN int lws_font_register_file ( struct lws_context * cx,
const char * path )

lws_font_register_file() - register an mcufont kept in a file

Parameters
cxthe lws context
paththe file, opened through the context's fops

Only the face's name and metrics stay in memory. Its dictionary and the glyph strings text needs are read in when text is set in it, and are reclaimable heap occupants: they are given back when memory runs short and read again when next needed.

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_fonts_register_dir()

LWS_VISIBLE LWS_EXTERN int lws_fonts_register_dir ( struct lws_context * cx,
const char * dirpath )

lws_fonts_register_dir() - register every .mcufont in a directory

Parameters
cxthe lws context
dirpaththe directory to scan

Returns the number of faces registered (0 if the directory can't be read or holds none).

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_font_choose()

LWS_VISIBLE LWS_EXTERN const lws_display_font_t * lws_font_choose ( struct lws_context * cx,
const lws_font_choice_t * hints )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_fonts_destroy()

LWS_VISIBLE LWS_EXTERN void lws_fonts_destroy ( struct lws_context * cx)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_file_register()

LWS_VISIBLE LWS_EXTERN lws_dlo_filesystem_t * lws_dlo_file_register ( struct lws_context * cx,
const lws_dlo_filesystem_t * f )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_file_unregister()

LWS_VISIBLE LWS_EXTERN void lws_dlo_file_unregister ( lws_dlo_filesystem_t ** f)

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_file_unregister_by_name()

LWS_VISIBLE LWS_EXTERN void lws_dlo_file_unregister_by_name ( struct lws_context * cx,
const char * name )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_file_choose()

LWS_VISIBLE LWS_EXTERN const lws_dlo_filesystem_t * lws_dlo_file_choose ( struct lws_context * cx,
const char * name )

References LWS_EXTERN, and LWS_VISIBLE.

◆ lws_dlo_file_destroy()

LWS_VISIBLE LWS_EXTERN void lws_dlo_file_destroy ( struct lws_context * cx)

Variable Documentation

◆ lws_dlo_fops

Definition at line 1005 of file lws-dlo.h.