diff options
Diffstat (limited to 'lib/sisu/v3/epub_segments.rb')
-rw-r--r-- | lib/sisu/v3/epub_segments.rb | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/lib/sisu/v3/epub_segments.rb b/lib/sisu/v3/epub_segments.rb index b6a84bd1..61e65544 100644 --- a/lib/sisu/v3/epub_segments.rb +++ b/lib/sisu/v3/epub_segments.rb @@ -72,7 +72,7 @@ module SiSU_EPUB_seg @seg[:headings]=[] format_head_seg=SiSU_EPUB_Format::Head_seg.new(@md) @seg[:headings] << format_head_seg.title_banner(@md.title.main,@md.title.sub,@author) - txt_obj={:txt =>'Endnotes',:ocn_display =>''} + txt_obj={ txt: 'Endnotes', ocn_display: ''} format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @seg[:headings] << format_seg.title_heading1 filename_seg << @seg[:heading_endnotes] << @seg[:headings] << %{\n<div class="content">\n} << @seg[:endnote_all] << '</div>' @@ -80,7 +80,7 @@ module SiSU_EPUB_seg @seg[:headings]=[] format_head_seg=SiSU_EPUB_Format::Head_seg.new(@md) @seg[:headings] << format_head_seg.title_banner(@md.title.main,@md.title.sub,@author) - txt_obj={:txt =>'Index',:ocn_display =>''} + txt_obj={ txt: 'Index', ocn_display: ''} format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @seg[:headings] << format_seg.title_heading1 filename_seg << @seg[:heading_idx] << @seg[:headings] << %{\n<div class="content">\n} << @seg[:idx] << '</div>' @@ -89,7 +89,7 @@ module SiSU_EPUB_seg @seg[:headings]=[] format_head_seg=SiSU_EPUB_Format::Head_seg.new(@md) @seg[:headings] << format_head_seg.title_banner(@md.title.main,@md.title.sub,@author) - txt_obj={:txt =>'Metadata',:ocn_display =>''} + txt_obj={ txt: 'Metadata', ocn_display: ''} format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @seg[:headings] << format_seg.title_heading1 filename_seg << @seg[:heading_idx] << @seg[:headings] << %{\n<div class="content">\n} << metadata << '</div>' @@ -106,7 +106,7 @@ WOK @seg[:headings]=[] format_head_seg=SiSU_EPUB_Format::Head_seg.new(@md) @seg[:headings] << format_head_seg.title_banner(@md.title.main,@md.title.sub,@author) - txt_obj={:txt =>'Manifest',:ocn_display =>''} + txt_obj={ txt: 'Manifest', ocn_display: ''} format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @seg[:headings] << format_seg.title_heading1 filename_seg << @seg[:heading_idx] << @seg[:headings] << %{\n<div class="content">\n} << manifest << '</div>' @@ -314,7 +314,7 @@ WOK else '' end @p_num=SiSU_EPUB_Format::Paragraph_number.new(@md,ocn) - txt_obj={:txt =>@@heading1,:ocn_display =>@p_num.ocn_display} + txt_obj={ txt: @@heading1, ocn_display: @p_num.ocn_display } format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @@seg[:headings] << format_seg.title_heading1.gsub(clean,'') @@heading1.gsub!(/ <a name="-[\d*+]+" href="#_[\d*+]+"> <sup>[\d*+]+<\/sup> <\/a>/,'') @@ -325,7 +325,7 @@ WOK else '' end @p_num=SiSU_EPUB_Format::Paragraph_number.new(@md,ocn) - txt_obj={:txt =>heading2,:ocn_display =>@p_num.ocn_display} + txt_obj={ txt: heading2, ocn_display: @p_num.ocn_display } format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @@seg[:headings] << format_seg.title_heading2.gsub(clean,'') @@heading2.gsub!(/ <a name="-[\d*+]+" href="#_[\d*+]+"> <sup>[\d*+]+<\/sup> <\/a>/,'') @@ -336,7 +336,7 @@ WOK else '' end @p_num=SiSU_EPUB_Format::Paragraph_number.new(@md,ocn) - txt_obj={:txt =>heading3,:ocn_display =>@p_num.ocn_display} + txt_obj={ txt: heading3, ocn_display: @p_num.ocn_display } format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @@seg[:headings] << format_seg.title_heading3.gsub(clean,'') @@heading3.gsub!(/ <a name="-[\d*+]+" href="#_[\d*+]+"> <sup>[\d*+]+<\/sup> <\/a>/,'') @@ -347,7 +347,7 @@ WOK else '' end @p_num=SiSU_EPUB_Format::Paragraph_number.new(@md,ocn) - txt_obj={:txt =>heading4,:ocn_display =>@p_num.ocn_display} + txt_obj={ txt: heading4, ocn_display: @p_num.ocn_display } format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) @@seg[:headings] << format_seg.title_heading4.gsub(clean,'') end @@ -497,7 +497,7 @@ WOK e_n=note_match_seg[/(?:#{Mx[:en_a_o]}(?:\d|#{ast}|#{pls})+|#{Mx[:en_b_o]}(?:#{ast}|#{pls})\d+)\s+(.+?)(?:#{Mx[:en_a_c]}|#{Mx[:en_b_c]})/m,1] try=e_n.split(/<br \/>/) try.each do |e| - txt_obj={:txt =>e} + txt_obj={ txt: e } format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) note_match=if e =~/#{Mx[:pa_o]}i[1-9]#{Mx[:pa_c]}/ format_seg.endnote_body_indent @@ -510,7 +510,7 @@ WOK m=/(?:#{Mx[:en_a_o]}(?:\d|#{ast}|#{pls})+|#{Mx[:en_b_o]}(?:#{ast}|#{pls})\d+)\s+(.+?href=")(#note_ref(?:\d|_a|_b)+".+)(?:#{Mx[:en_a_c]}|#{Mx[:en_b_c]})/mi endnote_part_a=note_match_seg[m,1] endnote_part_b=note_match_seg[m,2] - txt_obj={:endnote_part_a =>endnote_part_a,:endnote_part_b =>endnote_part_b} + txt_obj={ endnote_part_a: endnote_part_a, endnote_part_b: endnote_part_b } format_seg=SiSU_EPUB_Format::Format_seg.new(@md,txt_obj) note_match_all_seg=format_seg.endnote_seg_body(@@fn) #BUG WATCH 200408 @@seg[:endnote_all] << note_match_all_seg |