diff options
| author | Ralph Amissah <ralph@amissah.com> | 2012-10-01 15:17:03 -0400 | 
|---|---|---|
| committer | Ralph Amissah <ralph@amissah.com> | 2012-10-01 15:17:03 -0400 | 
| commit | d96753b4e4b7b0f2748064bc35aeaa8418deb7fa (patch) | |
| tree | 6591aa80f6044d391b09ad2d986acece5df80c8c /lib | |
| parent | v3: pdflatex, landscape cover page was botched, came out as portrait, fix (diff) | |
v3: texpdf fixes
* group text, bullet
* group text, hardspaces at start of line (indent)
* group text, pass through special characters safe
* poem, bold etc.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/sisu/v3/texpdf.rb | 8 | 
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/sisu/v3/texpdf.rb b/lib/sisu/v3/texpdf.rb index 4c224b22..618c891e 100644 --- a/lib/sisu/v3/texpdf.rb +++ b/lib/sisu/v3/texpdf.rb @@ -468,13 +468,14 @@ module SiSU_TeX            || dob.is==:group \            || dob.is==:alt \            || dob.is==:verse -            dob.tmp=dob.tmp.gsub(/#{Mx[:nbsp]}/m,'{~}'). -              gsub(/#{Mx[:gl_bullet]}/m,'$\txtbullet$\hspace{\enspace}'). #Bullet environment not used for grouped text, ∴ no hanging indent here +            dob.tmp=dob.tmp.gsub(/#{Mx[:nbsp]}/m,' \hardspace '). +              gsub(/#{Mx[:gl_bullet]}/m,'\txtbullet \hardspace '). #Bullet environment not used for grouped text, no hanging indent here                gsub(/#{Mx[:br_nl]}+/m,"\n\n") #match not ideal, but currently not inserting extra newlines anyway              ocn=SiSU_TeX_Pdf::FormatTextObject.new(@md).ocn_display(dob)              dob.tmp=if dob.is==:group \              || dob.is==:block \              || dob.is==:alt +              dob.tmp=SiSU_TeX_Pdf::SpecialCharacters.new(@md,dob.tmp).special_characters_safe                ocn \                + @tex_ml.paraskip_small \                + "\n" \ @@ -485,6 +486,9 @@ module SiSU_TeX                + "\n" \                + @tex_ml.paraskip_normal              elsif dob.is==:verse +              dob.tmp=dob.tmp.gsub(/#{Mx[:fa_bold_o]}(.+?)#{Mx[:fa_bold_c]}/m,'\begin{bfseries}\1 \end{bfseries}'). +                gsub(/#{Mx[:fa_italics_o]}(.+?)#{Mx[:fa_italics_c]}/m,'\emph{\1}'). +                gsub(/#{Mx[:fa_underscore_o]}(.+?)#{Mx[:fa_underscore_c]}/m,'\uline{\1}')                ocn \                + @tex_ml.paraskip_tiny \                + "\n" \  | 
