aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sdp/output/epub3.d
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2018-05-04 21:22:39 -0400
committerRalph Amissah <ralph@amissah.com>2019-04-10 15:14:15 -0400
commit48ba380760b306077afa7a156a21d3ff98d26775 (patch)
tree3385a7efddac04cb52fb08a93b245c89e958e83d /src/sdp/output/epub3.d
parentlink url matching (diff)
html & epub images in place (dimensions not & other issues)
Diffstat (limited to 'src/sdp/output/epub3.d')
-rw-r--r--src/sdp/output/epub3.d28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/sdp/output/epub3.d b/src/sdp/output/epub3.d
index 321ef9b..eb55593 100644
--- a/src/sdp/output/epub3.d
+++ b/src/sdp/output/epub3.d
@@ -375,7 +375,7 @@ template outputEPub3() {
case "para":
switch (obj.is_a) {
case "toc":
- auto t = xhtml_format.para_seg(obj, _txt, suffix);
+ auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
@@ -398,7 +398,7 @@ template outputEPub3() {
case "para":
switch (obj.is_a) {
case "para":
- auto t = xhtml_format.para_seg(obj, _txt, suffix);
+ auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
@@ -412,24 +412,24 @@ template outputEPub3() {
case "block":
switch (obj.is_a) {
case "quote":
- auto t = xhtml_format.quote_seg(obj, _txt, suffix);
+ auto t = xhtml_format.quote_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "group":
- auto t = xhtml_format.group_seg(obj, _txt, suffix);
+ auto t = xhtml_format.group_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "block":
- auto t = xhtml_format.block_seg(obj, _txt, suffix);
+ auto t = xhtml_format.block_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "poem":
break;
case "verse":
- auto t = xhtml_format.verse_seg(obj, _txt, suffix);
+ auto t = xhtml_format.verse_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0].to!string;
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
@@ -460,26 +460,26 @@ template outputEPub3() {
case "para":
switch (obj.is_a) {
case "endnote": assert(part == "endnotes");
- auto t = xhtml_format.para_seg(obj, _txt, suffix);
+ auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
break;
case "glossary": assert(part == "glossary");
- auto t = xhtml_format.para_seg(obj, _txt, suffix);
+ auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "bibliography": assert(part == "bibliography");
- auto t = xhtml_format.para_seg(obj, _txt, suffix);
+ auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "bookindex": assert(part == "bookindex_seg");
- auto t = xhtml_format.para_seg(obj, _txt, suffix);
+ auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
case "blurb": assert(part == "blurb");
- auto t = xhtml_format.para_seg(obj, _txt, suffix);
+ auto t = xhtml_format.para_seg(obj, _txt, suffix, "epub");
doc_epub3[segment_filename] ~= t[0];
doc_epub3_endnotes[segment_filename] ~= t[1];
break;
@@ -723,13 +723,13 @@ template outputEPub3() {
debug(epub_output) {
debug(epub_images) {
writeln(
- doc_matters.src_path_info.image_root, image, " -> ",
+ doc_matters.src_path_info.src_image_root_with_path, "/", image, " -> ",
pth_epub3.dbg_doc_oebps_image(doc_matters.src.filename), "/", image
);
}
}
- auto fn_src = doc_matters.src_path_info.image_root ~ image;
- auto fn_out = pth_epub3.doc_oebps_image(doc_matters.src.filename).to!string ~ "/" ~ image;
+ auto fn_src = doc_matters.src_path_info.src_image_root_with_path ~ "/" ~ image;
+ auto fn_out = pth_epub3.doc_oebps_image(doc_matters.src.filename.to!string) ~ "/" ~ image;
if (exists(fn_src)) {
{
auto zip_arc_member_file = new ArchiveMember();