aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v0/odf.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2007-10-08 12:23:05 +0100
committerRalph Amissah <ralph@amissah.com>2007-10-08 12:23:05 +0100
commit37f81bc4aa6579f269021dfdb3ab84b51f531634 (patch)
treed0254472d94909d6dcba44baf981ef3e8d9adb7b /lib/sisu/v0/odf.rb
parentsisu-0.60.1 + md5s (diff)
dal, shortcut for available outputs, present as grouped text object
this makes more sense for search results - matches all available versions of a document [affects document objects and numbering where used, hence version number bump]
Diffstat (limited to 'lib/sisu/v0/odf.rb')
-rw-r--r--lib/sisu/v0/odf.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/sisu/v0/odf.rb b/lib/sisu/v0/odf.rb
index 981bedeb..610a51aa 100644
--- a/lib/sisu/v0/odf.rb
+++ b/lib/sisu/v0/odf.rb
@@ -367,6 +367,12 @@ module SiSU_ODF
parray=[]
para.split(/<:?br(?: \/)?>/).each do |parablock|
parablock=group_clean(parablock)
+ parablock.gsub!(/&lt;text:a xlink:type="simple" xlink:href="(.+?)"&gt;/m,'<text:a xlink:type="simple" xlink:href="\1">')
+ parablock.gsub!(/&lt;(\/text:a)&gt;/,'<\1>')
+ parablock.gsub!(/&lt;(text:note text:id=.+?)&gt;/,'<\1>')
+ parablock.gsub!(/&lt;(text:p text:style-name="Footnote")&gt;/,'<\1>')
+ parablock.gsub!(/&lt;(\/?text:(?:note-citation|note-body|note|p))&gt;/,'<\1>')
+ parablock=footnote(parablock)
parray << %{<text:p text:style-name="P4">#{parablock}</text:p>} if parablock =~/\S+/
end
para=parray.join + '<text:p text:style-name="Standard"/>'
@@ -397,8 +403,6 @@ module SiSU_ODF
n=lv - 1
n3=lv + 2
lv=nil if lv == 0
- #extract_endnotes(para)
- #para=fontface(para)
para=unless para=~/^<:code>/
para=if para =~/\{\s*\S+?\.(?:png|jpg|gif)\s.+?\}(?:(?:https?|file|ftp):\S+|image)/; image(para)
elsif para =~/\{.+?\}(?:(?:https?|file|ftp):\S+|image)/; text_link(para)