mirror of
https://github.com/netsurf-browser/netsurf
synced 2025-03-18 13:02:52 +03:00
Plotters: Expose array of font family strings to front ends.
This commit is contained in:
parent
8332bf6b2a
commit
8a931f01b9
@ -144,6 +144,7 @@ void font_plot_style_from_css(
|
||||
|
||||
fstyle->family = plot_font_generic_family(
|
||||
css_computed_font_family(css, &families));
|
||||
fstyle->families = families;
|
||||
|
||||
css_computed_font_size(css, &length, &unit);
|
||||
fstyle->size = FIXTOINT(FMUL(nscss_len2pt(len_ctx, length, unit),
|
||||
|
@ -26,6 +26,7 @@
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdint.h>
|
||||
#include <libwapcaplet/libwapcaplet.h>
|
||||
#include "netsurf/types.h"
|
||||
|
||||
/** light grey widget base colour */
|
||||
@ -108,6 +109,12 @@ typedef enum {
|
||||
* Font style for plotting
|
||||
*/
|
||||
typedef struct plot_font_style {
|
||||
/**
|
||||
* Array of pointers to font families.
|
||||
*
|
||||
* May be NULL. Array is NULL terminated.
|
||||
*/
|
||||
lwc_string * const * families;
|
||||
plot_font_generic_family_t family; /**< Generic family to plot with */
|
||||
plot_style_fixed size; /**< Font size, in pt */
|
||||
int weight; /**< Font weight: value in range [100,900] as per CSS */
|
||||
|
Loading…
x
Reference in New Issue
Block a user