aboutsummaryrefslogtreecommitdiff
path: root/include/pango.h
diff options
context:
space:
mode:
authorBrian Ashworth <RedSoxFan@users.noreply.github.com>2018-05-14 00:28:21 -0400
committerGitHub <noreply@github.com>2018-05-14 00:28:21 -0400
commit34b864fb1752fde2528db6aa86d53c23412a8f43 (patch)
treeb387f1e1eb8f8fc16faeb4bf24a0ab6e8ba5787c /include/pango.h
parent6ff7c5273659061ec4ff2f6c79c69af2d4d165a5 (diff)
parent270c1ee7e507f1d2960920a7f4f0cc70f4e13d26 (diff)
Merge branch 'master' into fix-1975
Diffstat (limited to 'include/pango.h')
-rw-r--r--include/pango.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/pango.h b/include/pango.h
index f6325f28..d8263f9e 100644
--- a/include/pango.h
+++ b/include/pango.h
@@ -6,6 +6,17 @@
#include <cairo/cairo.h>
#include <pango/pangocairo.h>
+/* Utility function which escape characters a & < > ' ".
+ *
+ * If the dest parameter is NULL, then the function returns the length of
+ * of the escaped src string. The dest_length doesn't matter.
+ *
+ * If the dest parameter is not NULL then the fuction escapes the src string
+ * an puts the escaped string in dest and returns the lenght of the escaped string.
+ * The dest_length parameter is the size of dest array. If the size of dest is not
+ * enough, then the function returns -1.
+ */
+int escape_markup_text(const char *src, char *dest, int dest_length);
PangoLayout *get_pango_layout(cairo_t *cairo, const char *font,
const char *text, int32_t scale, bool markup);
void get_text_size(cairo_t *cairo, const char *font, int *width, int *height,