aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2011-12-13 22:11:26 -0500
committerRalph Amissah <ralph@amissah.com>2011-12-13 22:11:26 -0500
commit316219ecfaca8b614ed6040dc974ecd184d33710 (patch)
treeb9288fb5d6f2da822a8972412da19cb48cabe6c1 /lib
parentdebian/changelog (3.1.7-1) (diff)
parentv3: texpdf, output_by: filetype, fix, language code part of filename, fix (diff)
Merge commit 'sisu_3.1.8' into debian/sid
Diffstat (limited to 'lib')
-rw-r--r--lib/sisu/v3/odf.rb6
-rw-r--r--lib/sisu/v3/sysenv.rb6
2 files changed, 6 insertions, 6 deletions
diff --git a/lib/sisu/v3/odf.rb b/lib/sisu/v3/odf.rb
index b7b747ee..7d4fa309 100644
--- a/lib/sisu/v3/odf.rb
+++ b/lib/sisu/v3/odf.rb
@@ -535,10 +535,12 @@ module SiSU_ODF
unless dob =~/^(?:#{Rx[:meta]}|%+ )/m
w.gsub!(/&#(?:126|152);/,'~') #126 usual
w.gsub!(/&nbsp;/,'&#160;')
- if w !~/&\S{2,7}?;/
+ if w !~/(?:&\S{2,7}?;)+/
w.gsub!(/&/,'&amp;')
end
- w.gsub!(/(&\S{1,7};)+&/,'\1&amp;') #could break things
+ if w !~/&\S{1,7}?;(?:&\S{1,7}?;)+/ #imperfect
+ w.gsub!(/(&\S{1,7};)+&/,'\1&amp;')
+ end
end
para_array << w
end
diff --git a/lib/sisu/v3/sysenv.rb b/lib/sisu/v3/sysenv.rb
index 953c8eec..98a58f72 100644
--- a/lib/sisu/v3/sysenv.rb
+++ b/lib/sisu/v3/sysenv.rb
@@ -3818,15 +3818,13 @@ WOK
end
end
def pdf_p
- if @env.output_dir_structure.by_language_code? \
- or @env.output_dir_structure.by_filetype?
+ if @env.output_dir_structure.by_language_code?
@md.fnb + '.portrait.'
else 'portrait' + @md.lang_code_insert + '.'
end
end
def pdf_l
- if @env.output_dir_structure.by_language_code? \
- or @env.output_dir_structure.by_filetype?
+ if @env.output_dir_structure.by_language_code?
@md.fnb + '.landscape.'
else 'landscape' + @md.lang_code_insert + '.'
end