From 505c66abbbdc8f9f8f9930cacec751e6a886d8d9 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Fri, 15 Oct 2010 16:22:07 -0400 Subject: texpdf, codeblocks do not permit empty lines, fix --- CHANGELOG_v2 | 4 +++- data/doc/sisu/v2/CHANGELOG | 4 +++- lib/sisu/v2/texpdf.rb | 6 ++++-- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/CHANGELOG_v2 b/CHANGELOG_v2 index 81c2b6ce..4e992d26 100644 --- a/CHANGELOG_v2 +++ b/CHANGELOG_v2 @@ -12,7 +12,7 @@ Reverse Chronological: %% Development branch UNSTABLE -%% 2.7.7.orig.tar.gz (2010-10-14:41/4) +%% 2.7.7.orig.tar.gz (2010-10-15:41/5) http://www.jus.uio.no/sisu/pkg/src/sisu_2.7.7.orig.tar.gz sisu_2.7.7.orig.tar.gz sisu_2.7.7-1.dsc @@ -36,6 +36,8 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_2.7.7.orig.tar.gz grouped text) (requested fix, Ben Armstrong) + * texpdf, codeblocks do not permit empty lines, fix + * documentation related minor updates and fixes %% 2.7.6.orig.tar.gz (2010-10-11:41/1) diff --git a/data/doc/sisu/v2/CHANGELOG b/data/doc/sisu/v2/CHANGELOG index d7a71987..9bfc86f3 100644 --- a/data/doc/sisu/v2/CHANGELOG +++ b/data/doc/sisu/v2/CHANGELOG @@ -12,7 +12,7 @@ Reverse Chronological: %% Development branch UNSTABLE -%% 2.7.7.orig.tar.gz (2010-10-14:41/4) +%% 2.7.7.orig.tar.gz (2010-10-15:41/5) http://www.jus.uio.no/sisu/pkg/src/sisu_2.7.7.orig.tar.gz sisu_2.7.7.orig.tar.gz sisu_2.7.7-1.dsc @@ -36,6 +36,8 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_2.7.7.orig.tar.gz grouped text) (requested fix, Ben Armstrong) + * texpdf, codeblocks do not permit empty lines, fix + * documentation related minor updates and fixes %% 2.7.6.orig.tar.gz (2010-10-11:41/1) diff --git a/lib/sisu/v2/texpdf.rb b/lib/sisu/v2/texpdf.rb index 363cfc8c..3a868cd8 100644 --- a/lib/sisu/v2/texpdf.rb +++ b/lib/sisu/v2/texpdf.rb @@ -435,8 +435,10 @@ module SiSU_TeX dob.tmp.gsub!(/#{Mx[:nbsp]}/,'{~}') #dob.tmp.gsub!(/#{Mx[:nbsp]}\s*/,'{~}') dob.tmp.gsub!(/#{Mx[:vline]}/m,'\vline') dob.tmp.gsub!(/ \\( |#{Mx[:br_nl]})/,' {\textbackslash}\1') - dob.tmp.gsub!(/(?:#{Mx[:br_nl]}\s*)+/,' \\\\\\ ') #watch - dob.tmp.gsub!(/\n\n\n/m," \\newline\n\n") #watch + dob.tmp.gsub!(/#{Mx[:br_nl]}\s*\Z/m,'') + dob.tmp.gsub!(/#{Mx[:br_nl]}{2}/,'\newline \\\\\\ ') + dob.tmp.gsub!(/#{Mx[:br_nl]}/,' \\\\\\ ') + dob.tmp.gsub!(/\n\n\n/m," \\newline\n\n") ocn=SiSU_TeX_Pdf::Format_text_object.new(@md).ocn_display(dob) dob.tmp = ocn \ + @tex_ml.paraskip_small \ -- cgit v1.2.3