summaryrefslogtreecommitdiff
path: root/include/mupdf/fitz/bidi.h
diff options
context:
space:
mode:
authorRobin Watts <robin.watts@artifex.com>2016-11-11 16:30:59 +0000
committerRobin Watts <robin.watts@artifex.com>2016-11-14 16:09:40 +0000
commit7703ad8b2564f2f3a99b85eca5af276d7ba0e3e4 (patch)
treeabda358d9d039ba76d570a34b7c16d4b79a33724 /include/mupdf/fitz/bidi.h
parent37f95f87bdfb2e0b01d649afae5fffe60bf99d3a (diff)
downloadmupdf-7703ad8b2564f2f3a99b85eca5af276d7ba0e3e4.tar.xz
More API tweaks.
Move internal functions from public to private headers.
Diffstat (limited to 'include/mupdf/fitz/bidi.h')
-rw-r--r--include/mupdf/fitz/bidi.h97
1 files changed, 50 insertions, 47 deletions
diff --git a/include/mupdf/fitz/bidi.h b/include/mupdf/fitz/bidi.h
index e5cb87ed..230f6a94 100644
--- a/include/mupdf/fitz/bidi.h
+++ b/include/mupdf/fitz/bidi.h
@@ -1,20 +1,21 @@
/*
- * Bidirectional text processing.
- *
- * Derived from the SmartOffice code, which is itself derived
- * from the example unicode standard code. Original copyright
- * messages follow:
- *
- * Copyright (C) Picsel, 2004-2008. All Rights Reserved.
- *
- * Processes Unicode text by arranging the characters into an order suitable
- * for display. E.g. Hebrew text will be arranged from right-to-left and
- * any English within the text will remain in the left-to-right order.
- *
- * This is an implementation of the Unicode Bidirectional Algorithm which
- * can be found here: http://www.unicode.org/reports/tr9/ and is based
- * on the reference implementation found on Unicode.org.
- */
+ Bidirectional text processing.
+
+ Derived from the SmartOffice code, which is itself derived
+ from the example unicode standard code. Original copyright
+ messages follow:
+
+ Copyright (C) Picsel, 2004-2008. All Rights Reserved.
+
+ Processes Unicode text by arranging the characters into an order
+ suitable for display. E.g. Hebrew text will be arranged from
+ right-to-left and any English within the text will remain in the
+ left-to-right order.
+
+ This is an implementation of the Unicode Bidirectional Algorithm
+ which can be found here: http://www.unicode.org/reports/tr9/ and
+ is based on the reference implementation found on Unicode.org.
+*/
#ifndef FITZ_BIDI_H
#define FITZ_BIDI_H
@@ -36,43 +37,45 @@ typedef enum fz_bidi_flags_e
}
fz_bidi_flags;
-/**
- * Prototype for callback function supplied to fz_bidi_fragment_text.
- *
- * @param fragment first character in fragment
- * @param fragmentLen number of characters in fragment
- * @param bidiLevel The bidirectional level for this text. The bottom bit
- * will be set iff block should concatenate with other
- * blocks as right-to-left
- * @param script the script in use for this fragment (other than common
- * or inherited)
- * @param arg data from caller of Bidi_fragmentText
- */
+/*
+ Prototype for callback function supplied to fz_bidi_fragment_text.
+
+ @param fragment first character in fragment
+ @param fragmentLen number of characters in fragment
+ @param bidiLevel The bidirectional level for this text.
+ The bottom bit will be set iff block
+ should concatenate with other blocks as
+ right-to-left
+ @param script the script in use for this fragment (other
+ than common or inherited)
+ @param arg data from caller of Bidi_fragmentText
+*/
typedef void (fz_bidi_fragment_callback)(const uint32_t *fragment,
size_t fragmentLen,
int bidiLevel,
int script,
void *arg);
-/**
- * Partitions the given Unicode sequence into one or more unidirectional
- * fragments and invokes the given callback function for each fragment.
- *
- * For example, if directionality of text is:
- * 0123456789
- * rrlllrrrrr,
- * we'll invoke callback with:
- * &text[0], length == 2
- * &text[2], length == 3
- * &text[5], length == 5
- *
- * @param[in] text start of Unicode sequence
- * @param[in] textlen number of Unicodes to analyse
- * @param[in] baseDir direction of paragraph (specify FZ_BIDI_NEUTRAL to force auto-detection)
- * @param[in] callback function to be called for each fragment
- * @param[in] arg data to be passed to the callback function
- * @param[in] flags flags to control operation (see fz_bidi_flags above)
- */
+/*
+ Partitions the given Unicode sequence into one or more
+ unidirectional fragments and invokes the given callback
+ function for each fragment.
+
+ For example, if directionality of text is:
+ 0123456789
+ rrlllrrrrr,
+ we'll invoke callback with:
+ &text[0], length == 2
+ &text[2], length == 3
+ &text[5], length == 5
+
+ @param[in] text start of Unicode sequence
+ @param[in] textlen number of Unicodes to analyse
+ @param[in] baseDir direction of paragraph (specify FZ_BIDI_NEUTRAL to force auto-detection)
+ @param[in] callback function to be called for each fragment
+ @param[in] arg data to be passed to the callback function
+ @param[in] flags flags to control operation (see fz_bidi_flags above)
+*/
void fz_bidi_fragment_text(fz_context *ctx,
const uint32_t *text,
size_t textlen,