summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2016-07-06 21:45:00 +0200
committerTor Andersson <tor.andersson@artifex.com>2016-07-08 12:04:51 +0200
commitaf3386764c57b83c8de1cdd81fb35f97afc25fd6 (patch)
treec877f28d9d51f7789d67a2b537245bdde2cf7dff /docs
parent174cc9758d4dd7e8e3bd295f61271c3216e0cd3d (diff)
downloadmupdf-af3386764c57b83c8de1cdd81fb35f97afc25fd6.tar.xz
js: Add wrapper for fz_stext_page to search, select and copy text.
Diffstat (limited to 'docs')
-rw-r--r--docs/mutool/run.html24
1 files changed, 24 insertions, 0 deletions
diff --git a/docs/mutool/run.html b/docs/mutool/run.html
index c6bc80e5..9cf4cdb9 100644
--- a/docs/mutool/run.html
+++ b/docs/mutool/run.html
@@ -193,6 +193,8 @@ If skipAnnotations is true, ignore annotations.
If alpha is true, the page will be drawn on a transparent background, otherwise white.
<dt>Page#toDisplayList(skipAnnotations)
<dd>Record the contents on the page into a DisplayList.
+<dt>Page#toStructuredText()
+<dd>Extract the text on the page into a StructuredText object.
<dt>Page#search(needle)
<dd>Search for 'needle' text on the page, and return an array with rectangles of all matches found.
<dt>Page#getAnnotations()
@@ -215,6 +217,23 @@ If alpha is true, the page will be drawn on a transparent background, otherwise
</dl>
<h2>
+StructuredText
+</h2>
+
+<p>
+StructuredText objects hold text from a page that has been analyzed and grouped into blocks, lines and spans.
+</p>
+
+<dl>
+<dt>StructuredText#search(needle)
+<dd>Search the text for all instances of 'needle', and return an array with rectangles of all matches found.
+<dt>StructuredText#highlight(rect)
+<dd>Return an array with rectangles needed to highlight a selection defined by the two corners of the rectangle.
+<dt>StructuredText#copy(rect)
+<dd>Return the text from the selection defined by the two corners of the rectangle.
+</dl>
+
+<h2>
ColorSpace
</h2>
@@ -297,6 +316,11 @@ will keep all the graphics required in memory, so will increase the amount of me
<dd>Play back the recorded device calls onto the device.
<dt>DisplayList#toPixmap(transform, colorspace, alpha)
<dd>Render display list to a pixmap. If alpha is true, it will render to a transparent background, otherwise white.
+<dt>DisplayList#toStructuredText(skipAnnotations)
+<dd>Extract the text in the display list into a StructuredText object.
+<dt>DisplayList#search(needle)
+<dd>Search the display list text for all instances of 'needle', and return an array with rectangles of all matches found.
+<dd>
</dl>
<dl>