diff options
Diffstat (limited to 'lib/sisu/v0/texpdf.rb')
-rw-r--r-- | lib/sisu/v0/texpdf.rb | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/lib/sisu/v0/texpdf.rb b/lib/sisu/v0/texpdf.rb index d6420684..c080c554 100644 --- a/lib/sisu/v0/texpdf.rb +++ b/lib/sisu/v0/texpdf.rb @@ -206,7 +206,8 @@ module SiSU_TeX @dir_sisu=@dirout.path.output texfile=@md.fns.gsub(/$/,'.tex') texfile=texfile.gsub(/~/,'-') - if File.exist?(texfile) and File.size(texfile) > 0 + if File.exist?(texfile) \ + and File.size(texfile) > 0 @tex_f_no+=1 latex_do(texfile) else @@ -241,7 +242,9 @@ module SiSU_TeX @vz=SiSU_Env::Get_init.instance.skin @dp=@@dp ||=SiSU_Env::Info_env.new.digest.pattern vz=SiSU_Env::Get_init.instance.skin - @skin_no_ocn=if defined? vz.ocn_display_off and vz.ocn_display_off == true; true + @skin_no_ocn=if defined? vz.ocn_display_off \ + and vz.ocn_display_off == true + true else false end end @@ -272,7 +275,9 @@ module SiSU_TeX if @md.flag_tables data=tables(data) end - ocn=if @md.markup.inspect =~/no_ocn/ or @md.mod.inspect =~/--no-ocn/ or @skin_no_ocn + ocn=if @md.markup.inspect =~/no_ocn/ \ + or @md.mod.inspect =~/--no-ocn/ \ + or @skin_no_ocn false else true end @@ -429,7 +434,8 @@ WOK @group_collect=[] data.each do |para| #% case follows with levels 1-6 indents & graphics mono=SiSU_TeX_Pdf::Format_text_object.new(@md,para) - if para =~/<:(code|alt|verse|group)>/ or @@flag_alt + if para =~/<:(code|alt|verse|group)>/ \ + or @@flag_alt if para =~/<:(code|alt|verse|group)>/ @lineone=case para when /<:(alt|verse|group)>/; para @@ -521,7 +527,8 @@ WOK @tex_file << if @md.doc_skin !~/skin_mail/; @tex.doc_tail else @tex.mail_tail end - if defined? @md.lnk and @md.lnk + if defined? @md.lnk \ + and @md.lnk @md.lnk.each do |l| if l[:say] url=%<#{l[:url]}> @@ -565,7 +572,8 @@ WOK def number_paras(data,ocn) @tex_file=[] data.each do |para| - if para =~/<\\~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+><#@dp:#@dp>$/ and para !~/\\end\{longtable\}|<EOF>/ #catch <!TZ!> + if para =~/<\\~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+><#@dp:#@dp>$/ \ + and para !~/\\end\{longtable\}|<EOF>/ #catch <!TZ!> m=/(.+?)<\\~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+><#@dp:#@dp>$/m parablock=para[m,1] paranum=if ocn; para[m,2] |