diff options
Diffstat (limited to 'org/ocda_functions.org')
| -rw-r--r-- | org/ocda_functions.org | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/org/ocda_functions.org b/org/ocda_functions.org index 6ab4bbf..ca8a7be 100644 --- a/org/ocda_functions.org +++ b/org/ocda_functions.org @@ -1441,12 +1441,17 @@ ST_flow_table_array_munge flow_table_array_munge()( #+NAME: ocdaFunc_images #+HEADER: :noweb yes #+BEGIN_SRC d -// ↓ - images +/+ ↓ - images, the images an object shows. + matched on the internal markup an image has become by this stage + (┥☼name.png,w640h447 ┝┤├), so a filename-shaped word in prose is not + taken for one, and over every match rather than the first, so a + paragraph showing two images reports two. ++/ string[] extract_images()(string content_block) { static auto rgx = RgxI(); string[] images_; - if (auto m = content_block.matchAll(rgx.image)) { - images_ ~= m.captures[1]; + foreach (m; content_block.matchAll(rgx.image_in_object_text)) { + images_ ~= m["image"].to!string; } return images_; } |
