summaryrefslogtreecommitdiff
path: root/source/fitz/bidi-imp.h
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2016-11-16 12:13:51 +0000
committerRobin Watts <robin.watts@artifex.com>2016-11-16 12:25:52 +0000
commit0c3e1ee387c995f37aa53f358825f334c06324ec (patch)
tree6b42f4ea01f1376e24716da82f2d91f1d0ace89e /source/fitz/bidi-imp.h
parent141870506d8809723e933963e9e001aca839cdfc (diff)
downloadmupdf-0c3e1ee387c995f37aa53f358825f334c06324ec.tar.xz
Bug 697301: Fix "crash" in epub.
Actually an assert. This is caused by a paragraph separator in the text. The Unicode Bidirectional Algorithm says we should operate paragraph by paragraph, and includes code to split paragraphs at paragraph markers, changing their type to boundary neutrals as it goes. The use of this code was left "as an exercise for the reader" in the example code, so we simply hook it up here.
Diffstat (limited to 'source/fitz/bidi-imp.h')
-rw-r--r--source/fitz/bidi-imp.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/fitz/bidi-imp.h b/source/fitz/bidi-imp.h
index cb0f8871..6c3aab77 100644
--- a/source/fitz/bidi-imp.h
+++ b/source/fitz/bidi-imp.h
@@ -75,3 +75,4 @@ void fz_bidi_resolve_implicit(const fz_bidi_chartype *pcls, fz_bidi_level *pleve
void fz_bidi_resolve_weak(fz_context *ctx, fz_bidi_level baselevel, fz_bidi_chartype *pcls, fz_bidi_level *plevel, size_t cch);
void fz_bidi_resolve_whitespace(fz_bidi_level baselevel, const fz_bidi_chartype *pcls, fz_bidi_level *plevel, size_t cch);
size_t fz_bidi_resolve_explicit(fz_bidi_level level, fz_bidi_chartype dir, fz_bidi_chartype *pcls, fz_bidi_level *plevel, size_t cch, fz_bidi_level nNest);
+int fz_bidi_resolve_paragraphs(fz_bidi_chartype *types, int cch);