Rename text widget layout members.
authorSebastian Rasmussen <[email protected]>
Tue, 10 Aug 2021 10:09:38 +0000 (12:09 +0200)
committerSebastian Rasmussen <[email protected]>
Tue, 10 Aug 2021 12:29:47 +0000 (14:29 +0200)
include/mupdf/fitz/structured-text.h
source/fitz/stext-device.c

index 41af96822a85f5a6fe579d9d9a8ac4b1a61d993f..7da6943b960c0cab2d47c60f899a4c9ae64b1c28 100644 (file)
 */
 typedef struct fz_layout_char
 {
-       float x, w;
+       float x, advance;
        const char *p; /* location in source text of character */
        struct fz_layout_char *next;
 } fz_layout_char;
 
 typedef struct fz_layout_line
 {
-       float x, y, h;
+       float x, y, font_size;
        const char *p; /* location in source text of start of line */
        fz_layout_char *text;
        struct fz_layout_line *next;
index a876bdadc7ff26f4a36a198113728630840650bd..bcaa0c231146619ceea3e84a52ad359a198fd907 100644 (file)
@@ -34,12 +34,12 @@ void fz_drop_layout(fz_context *ctx, fz_layout_block *block)
                fz_drop_pool(ctx, block->pool);
 }
 
-void fz_add_layout_line(fz_context *ctx, fz_layout_block *block, float x, float y, float h, const char *p)
+void fz_add_layout_line(fz_context *ctx, fz_layout_block *block, float x, float y, float font_size, const char *p)
 {
        fz_layout_line *line = fz_pool_alloc(ctx, block->pool, sizeof (fz_layout_line));
        line->x = x;
        line->y = y;
-       line->h = h;
+       line->font_size = font_size;
        line->p = p;
        line->text = NULL;
        line->next = NULL;
@@ -48,11 +48,11 @@ void fz_add_layout_line(fz_context *ctx, fz_layout_block *block, float x, float
        block->text_tailp = &line->text;
 }
 
-void fz_add_layout_char(fz_context *ctx, fz_layout_block *block, float x, float w, const char *p)
+void fz_add_layout_char(fz_context *ctx, fz_layout_block *block, float x, float advance, const char *p)
 {
        fz_layout_char *ch = fz_pool_alloc(ctx, block->pool, sizeof (fz_layout_char));
        ch->x = x;
-       ch->w = w;
+       ch->advance = advance;
        ch->p = p;
        ch->next = NULL;
        *block->text_tailp = ch;