diff options
author | Ralph Amissah <ralph@amissah.com> | 2014-06-19 21:13:06 -0400 |
---|---|---|
committer | Ralph Amissah <ralph@amissah.com> | 2014-06-19 21:13:06 -0400 |
commit | e0c38cb8d044e0b3dc449e10d1aa14ef3b6900ad (patch) | |
tree | 9ad8da13c9c4ac1d66a97438238e425784afd640 /lib/sisu/v6/xml_shared.rb | |
parent | v6: docbook, tags (name touch) (diff) |
v6: docbook, ocn & footnote numbers (as xml comments)
Diffstat (limited to 'lib/sisu/v6/xml_shared.rb')
-rw-r--r-- | lib/sisu/v6/xml_shared.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/sisu/v6/xml_shared.rb b/lib/sisu/v6/xml_shared.rb index 033659f0..aeb73f22 100644 --- a/lib/sisu/v6/xml_shared.rb +++ b/lib/sisu/v6/xml_shared.rb @@ -460,7 +460,8 @@ module SiSU_XML_Munge clean(str) end def markup_docbook(dob='') # work on, initially a copy of fictionbook! - dob.obj=dob.obj.gsub(/#{Mx[:en_a_o]}(.+?)#{Mx[:en_a_c]}/m,'<footnote>\1</footnote>'). + dob.obj=dob.obj.gsub(/#{Mx[:en_a_o]}(\d+)\s*(.+?)#{Mx[:en_a_c]}/m,'<footnote><para><!-- fn\1 -->\2</para></footnote>'). + gsub(/\\\\/,'</para><para>'). gsub(/&/,'&'). #sort gsub(/#{Mx[:mk_o]}#([a-zA-Z]+)#{Mx[:mk_c]}/,'&\1;'). gsub(/(^|#{Mx[:gl_c]}|\s)&\s+/,'\1& '). #sort |