diff options
author | Ralph Amissah <ralph@amissah.com> | 2013-06-25 00:11:09 -0400 |
---|---|---|
committer | Ralph Amissah <ralph@amissah.com> | 2013-06-25 00:11:09 -0400 |
commit | b3006eb0268887ec481c4d46e4602a3a9a2275e8 (patch) | |
tree | 54d8b4fb9f0c2744aa6096b546fe6277c184d273 /lib/sisu/v4/texinfo_format.rb | |
parent | debian/changelog (4.1.5-1) (diff) | |
parent | v4: general code cleaning, sync with v5 (diff) |
Merge tag 'sisu_4.1.6' into debian/sid
SiSU 4.1.6
Diffstat (limited to 'lib/sisu/v4/texinfo_format.rb')
-rw-r--r-- | lib/sisu/v4/texinfo_format.rb | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/lib/sisu/v4/texinfo_format.rb b/lib/sisu/v4/texinfo_format.rb index a490c68b..04fb06f6 100644 --- a/lib/sisu/v4/texinfo_format.rb +++ b/lib/sisu/v4/texinfo_format.rb @@ -82,7 +82,6 @@ module SiSU_TexInfoFormat def head t=Time.now year=t.year - filename=%{#{@md.fns}}[/(.+?)\.\w\w\d\d$/,1] title=spec_char(@md.title.full) title=title.gsub(/<(br|p|i)>|<\/\s*(br|p|i)>|<(br|p)\s*\/>/," #{Tex[:backslash]*2} "). gsub(/\$/,"\\$"). @@ -98,7 +97,7 @@ module SiSU_TexInfoFormat author=@md.author if @md.author author ||='' author=author.gsub(/[\*]/,'') #if author - v=SiSU_Env::InfoVersion.instance.get_version + SiSU_Env::InfoVersion.instance.get_version head =<<WOK \\input texinfo @c -*-texinfo-*- @comment %**start of header @@ -165,8 +164,6 @@ WOK "@menu\n" end def dublincore - title=spec_char(@md.title.main) if @md.title.main - subtitle=spec_char(@md.title.sub) if @md.title.sub if defined? @md.title.full \ and @md.title.full=~/\S+/ full_title=spec_char(@md.title.full) @@ -465,7 +462,7 @@ WOK @row_break='\\\\\\\\' @break_page="#{@row_break}\n#{@row_break} \n" if @dob[/#{Mx[:gr_o]}Th?#{Mx[:tc_p]}\s+c(\d+);(.+?)#{Mx[:gr_c]}/ui] #fix - no_of_cols,cols_width=$1,$2 + cols_width=$2 @w=cols_width.split(/;\s+/) @colW=[] @w.each do |x| @@ -489,7 +486,6 @@ WOK else @dob.obj=@dob.obj.gsub(/#{Mx[:tc_o]}#{Mx[:tc_p]}/u,'') @@table_pg_break_counter+=1 - tablefoot=@dob[/\<!f(.+?)!\>/] @dob.obj=@dob.obj.gsub(/\<!f(.+?)!\>/,'') end end @@ -517,7 +513,7 @@ WOK def png # very messy clean up ! - work area, testing z=@dob[/\\\{(.+?)\}(?:image|png)/,1] # match operator for z \\ fragile ! - image,w,x,y=z.scan(/\S+/) + image=z.scan(/\S+/)[0] #image,w,x,y=z.scan(/\S+/) image=image.gsub(/\\/,'') @dob.obj=@dob.obj.gsub(/\\\{\S+\.(png|jpg|gif).+?\}(image|png)/,"<image #{image} not available>") # fragile match operator\\ fragile ! end @@ -526,7 +522,7 @@ WOK z=@dob[/#{Mx[:lnk_o]}(.+?)#{Mx[:lnk_c]}#{Mx[:url_o]}\S+?#{Mx[:url_c]}/,1] # match operator for z \\ fragile ! url=@dob[/((?:https?|file|ftp):\S+)/im,1] if @dob =~/\.(png|jpg|gif)/ - image,w,x,y=z.scan(/\S+/) + image=z.scan(/\S+/)[0] #image,w,x,y=z.scan(/\S+/) image=image.gsub(/\\/,'') width=200 width=z[/w=(\d+)/im,1] if z =~/w=(\d+)/ |