From 0e42ce6f34c3cfdf370f439f58c4e3de8b05ea92 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Mon, 6 Jan 2014 22:42:31 -0500 Subject: v5: cosmetic code, case statement --- lib/sisu/v5/txt_plain.rb | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'lib/sisu/v5/txt_plain.rb') diff --git a/lib/sisu/v5/txt_plain.rb b/lib/sisu/v5/txt_plain.rb index fbe551f4..81fe7e3a 100644 --- a/lib/sisu/v5/txt_plain.rb +++ b/lib/sisu/v5/txt_plain.rb @@ -128,9 +128,9 @@ module SiSU_Txt_Plain @brace_url=SiSU_Viz::Defaults.new.url_decoration @tab="\t" @@endnotes_=case md.opt.mod.inspect - when /--footnote/; false - when /--endnote/; true - else true + when /--footnote/ then false + when /--endnote/ then true + else true end @plaintext={ body: [], open: [], close: [], head: [], metadata: [], tail: [] } end @@ -377,12 +377,12 @@ WOK times=wrapped.length times=@wrap_width if times > @wrap_width @plaintext[:body] << case lv - when 1; wrapped.upcase << break_line << decorate.heading_underscore.l1*times + p_num << break_line*2 - when 2; wrapped.upcase << break_line << decorate.heading_underscore.l2*times + p_num << break_line*2 - when 3; wrapped.upcase << break_line << decorate.heading_underscore.l3*times + p_num << break_line*2 - when 4; wrapped.upcase << break_line << decorate.heading_underscore.l4*times + p_num << break_line*2 - when 5; wrapped.upcase << break_line << decorate.heading_underscore.l5*times + p_num << break_line*2 - when 6; wrapped.upcase << break_line << decorate.heading_underscore.l6*times + p_num << break_line*2 + when 1 then wrapped.upcase << break_line << decorate.heading_underscore.l1*times + p_num << break_line*2 + when 2 then wrapped.upcase << break_line << decorate.heading_underscore.l2*times + p_num << break_line*2 + when 3 then wrapped.upcase << break_line << decorate.heading_underscore.l3*times + p_num << break_line*2 + when 4 then wrapped.upcase << break_line << decorate.heading_underscore.l4*times + p_num << break_line*2 + when 5 then wrapped.upcase << break_line << decorate.heading_underscore.l5*times + p_num << break_line*2 + when 6 then wrapped.upcase << break_line << decorate.heading_underscore.l6*times + p_num << break_line*2 end else @plaintext[:body] << wrapped + p_num << break_line # main text, contents, body KEEP -- cgit v1.2.3