[pango/visible-things-2: 12/16] pango-view: Add an option to show space
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pango/visible-things-2: 12/16] pango-view: Add an option to show space
- Date: Wed, 10 Jul 2019 19:24:44 +0000 (UTC)
commit 12f87d76bc94eab4ea2d3c9ba3f9484a8d5a1c70
Author: Matthias Clasen <mclasen redhat com>
Date: Wed Jul 10 09:03:13 2019 -0400
pango-view: Add an option to show space
utils/viewer-render.c | 5 +++++
1 file changed, 5 insertions(+)
---
diff --git a/utils/viewer-render.c b/utils/viewer-render.c
index f149384a..f369218a 100644
--- a/utils/viewer-render.c
+++ b/utils/viewer-render.c
@@ -54,6 +54,7 @@ int opt_indent = 0;
int opt_spacing = 0;
double opt_line_spacing = 0.0;
gboolean opt_show_ignorables = FALSE;
+gboolean opt_show_space = FALSE;
gboolean opt_justify = 0;
int opt_runs = 1;
PangoAlignment opt_align = PANGO_ALIGN_LEFT;
@@ -135,6 +136,8 @@ make_layout(PangoContext *context,
flags = PANGO_SHAPE_NONE;
if (opt_show_ignorables)
flags |= PANGO_SHAPE_SHOW_IGNORABLES;
+ if (opt_show_space)
+ flags |= PANGO_SHAPE_SHOW_SPACE;
pango_layout_set_shape_flags (layout, flags);
align = opt_align;
@@ -725,6 +728,8 @@ parse_options (int argc, char *argv[])
"Spread factor for line height", "factor"},
{"show-ignorables", 0, 0, G_OPTION_ARG_NONE, &opt_show_ignorables,
"Show invisible characters", NULL},
+ {"show-space", 0, 0, G_OPTION_ARG_NONE, &opt_show_space,
+ "Show space", NULL},
{"justify", 0, 0, G_OPTION_ARG_NONE, &opt_justify,
"Align paragraph lines to be justified", NULL},
{"language", 0, 0, G_OPTION_ARG_STRING, &opt_language,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]