aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v3/html_segments.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sisu/v3/html_segments.rb')
-rw-r--r--lib/sisu/v3/html_segments.rb24
1 files changed, 12 insertions, 12 deletions
diff --git a/lib/sisu/v3/html_segments.rb b/lib/sisu/v3/html_segments.rb
index b527eaba..bb77cb36 100644
--- a/lib/sisu/v3/html_segments.rb
+++ b/lib/sisu/v3/html_segments.rb
@@ -374,9 +374,9 @@ module SiSU_HTML_Seg
if @title_banner_
@@seg[:headings] << format_head_seg.title_banner(@md.title.main,@md.title.sub,@author).gsub(clean,'')
end
- ocn=if @@heading1[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]; $1 #fix
- else ''
- end
+ ocn=(@@heading1[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]) \
+ ? $1
+ : ''
@p_num=SiSU_HTML_Format::ParagraphNumber.new(@md,ocn)
txt_obj={ txt: @@heading1, ocn_display: @p_num.ocn_display }
format_seg=SiSU_HTML_Format::FormatSeg.new(@md,txt_obj)
@@ -385,9 +385,9 @@ module SiSU_HTML_Seg
end
if @@is2==1
heading2=@@heading2
- ocn=if heading2[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]; $1 #fix
- else ''
- end
+ ocn=(heading2[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]) \
+ ? $1
+ : ''
@p_num=SiSU_HTML_Format::ParagraphNumber.new(@md,ocn)
txt_obj={ txt: heading2, ocn_display: @p_num.ocn_display }
format_seg=SiSU_HTML_Format::FormatSeg.new(@md,txt_obj)
@@ -396,9 +396,9 @@ module SiSU_HTML_Seg
end
if @@is3==1
heading3=@@heading3
- ocn=if heading3[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]; $1 #fix
- else ''
- end
+ ocn=(heading3[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]) \
+ ? $1
+ : ''
@p_num=SiSU_HTML_Format::ParagraphNumber.new(@md,ocn)
txt_obj={ txt: heading3, ocn_display: @p_num.ocn_display }
format_seg=SiSU_HTML_Format::FormatSeg.new(@md,txt_obj)
@@ -407,9 +407,9 @@ module SiSU_HTML_Seg
end
if @@is4==1
heading4=@@heading4
- ocn=if heading4[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]; $1 #fix
- else ''
- end
+ ocn=(heading4[/.+?#{Mx[:id_o]}~(\d+);(?:[oh]|[0-6]:)\d+;\w\d+#{Mx[:id_c]}#{Mx[:id_o]}#{@dp}:#{@dp}#{Mx[:id_c]}$/]) \
+ ? $1
+ : ''
@p_num=SiSU_HTML_Format::ParagraphNumber.new(@md,ocn)
txt_obj={ txt: heading4, ocn_display: @p_num.ocn_display }
format_seg=SiSU_HTML_Format::FormatSeg.new(@md,txt_obj)