diff options
-rw-r--r-- | data/doc/sisu/CHANGELOG_v5 | 1 | ||||
-rw-r--r-- | data/doc/sisu/CHANGELOG_v6 | 1 | ||||
-rw-r--r-- | lib/sisu/v5/xml_shared.rb | 4 | ||||
-rw-r--r-- | lib/sisu/v6/xml_shared.rb | 4 |
4 files changed, 6 insertions, 4 deletions
diff --git a/data/doc/sisu/CHANGELOG_v5 b/data/doc/sisu/CHANGELOG_v5 index 340edcaf..f140442d 100644 --- a/data/doc/sisu/CHANGELOG_v5 +++ b/data/doc/sisu/CHANGELOG_v5 @@ -49,6 +49,7 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_5.5.1.orig.tar.xz * docbook, * code & other block markup * url links, urls + * images, an adjustment %% 5.5.0.orig.tar.xz (2014-07-11:27/5) http://sources.sisudoc.org/gitweb/?p=code/sisu.git;a=log;h=refs/tags/sisu_5.5.0 diff --git a/data/doc/sisu/CHANGELOG_v6 b/data/doc/sisu/CHANGELOG_v6 index 5450de3c..596e7afc 100644 --- a/data/doc/sisu/CHANGELOG_v6 +++ b/data/doc/sisu/CHANGELOG_v6 @@ -39,6 +39,7 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_6.1.1.orig.tar.xz * docbook, * code & other block markup * url links, urls + * images, an adjustment %% 6.1.0.orig.tar.xz (2014-07-11:27/5) http://sources.sisudoc.org/gitweb/?p=code/sisu.git;a=log;h=refs/tags/sisu_6.1.0 diff --git a/lib/sisu/v5/xml_shared.rb b/lib/sisu/v5/xml_shared.rb index 423044bc..77df1a30 100644 --- a/lib/sisu/v5/xml_shared.rb +++ b/lib/sisu/v5/xml_shared.rb @@ -477,8 +477,8 @@ module SiSU_XML_Munge gsub(/#{Mx[:fa_cite_o]}(.+?)#{Mx[:fa_cite_c]}/,'<cite>\1</cite>'). gsub(/#{Mx[:fa_strike_o]}(.+?)#{Mx[:fa_strike_c]}/,'<del>\1</del>'). gsub(/#{Mx[:fa_monospace_o]}(.+?)#{Mx[:fa_monospace_c]}/,'<tt>\1</tt>'). # tt, kbd - gsub(/#{Mx[:lnk_o]}\s*(\S+?\.(?:png|jpg|gif)).+?#{Mx[:lnk_c]}(?:#{Mx[:url_o]}\S+?#{Mx[:url_c]}|#{Mx[:rel_o]}\S+?#{Mx[:rel_c]}|image)/m, - %{#{Xx[:split]}:spaces0:<figure id="\\1">\n:spaces1:<title></title>\n:spaces1:<graphic fileref="images/\\1" align="center" width="50%"></graphic>\n:spaces0:</figure>#{Xx[:split]}}). + gsub(/#{Mx[:lnk_o]}\s*(\S+?)\.(png|jpg|gif).+?#{Mx[:lnk_c]}(?:#{Mx[:url_o]}\S+?#{Mx[:url_c]}|#{Mx[:rel_o]}\S+?#{Mx[:rel_c]}|image)/m, + %{#{Xx[:split]}:spaces0:<figure id="fig-\\1">\n:spaces1:<title></title>\n:spaces1:<graphic fileref="../../_sisu/image/\\1.\\2" align="center" width="50%"></graphic>\n:spaces0:</figure>#{Xx[:split]}}). # common image location, else use ./images gsub(/#{Mx[:lnk_o]}(.+?)#{Mx[:lnk_c]}#{Mx[:url_o]}(.+?)#{Mx[:url_c]}/, '<ulink url="\2">\1</ulink>'). gsub(/#{Mx[:url_o]}(.+?)#{Mx[:url_c]}/, diff --git a/lib/sisu/v6/xml_shared.rb b/lib/sisu/v6/xml_shared.rb index cef46c92..38c21802 100644 --- a/lib/sisu/v6/xml_shared.rb +++ b/lib/sisu/v6/xml_shared.rb @@ -477,8 +477,8 @@ module SiSU_XML_Munge gsub(/#{Mx[:fa_cite_o]}(.+?)#{Mx[:fa_cite_c]}/,'<cite>\1</cite>'). gsub(/#{Mx[:fa_strike_o]}(.+?)#{Mx[:fa_strike_c]}/,'<del>\1</del>'). gsub(/#{Mx[:fa_monospace_o]}(.+?)#{Mx[:fa_monospace_c]}/,'<tt>\1</tt>'). # tt, kbd - gsub(/#{Mx[:lnk_o]}\s*(\S+?\.(?:png|jpg|gif)).+?#{Mx[:lnk_c]}(?:#{Mx[:url_o]}\S+?#{Mx[:url_c]}|#{Mx[:rel_o]}\S+?#{Mx[:rel_c]}|image)/m, - %{#{Xx[:split]}:spaces0:<figure id="\\1">\n:spaces1:<title></title>\n:spaces1:<graphic fileref="images/\\1" align="center" width="50%"></graphic>\n:spaces0:</figure>#{Xx[:split]}}). + gsub(/#{Mx[:lnk_o]}\s*(\S+?)\.(png|jpg|gif).+?#{Mx[:lnk_c]}(?:#{Mx[:url_o]}\S+?#{Mx[:url_c]}|#{Mx[:rel_o]}\S+?#{Mx[:rel_c]}|image)/m, + %{#{Xx[:split]}:spaces0:<figure id="fig-\\1">\n:spaces1:<title></title>\n:spaces1:<graphic fileref="../../_sisu/image/\\1.\\2" align="center" width="50%"></graphic>\n:spaces0:</figure>#{Xx[:split]}}). # common image location, else use ./images gsub(/#{Mx[:lnk_o]}(.+?)#{Mx[:lnk_c]}#{Mx[:url_o]}(.+?)#{Mx[:url_c]}/, '<ulink url="\2">\1</ulink>'). gsub(/#{Mx[:url_o]}(.+?)#{Mx[:url_c]}/, |