aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v6/html_format.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2014-09-05 23:24:51 -0400
committerRalph Amissah <ralph@amissah.com>2014-09-05 23:24:51 -0400
commita8187c8aa978e99dfbbcae1c6729e16c3438414e (patch)
treedb1ec0a09e972d2122059e665b59ad413a8fb648 /lib/sisu/v6/html_format.rb
parentdebian/changelog (5.6.4-1) (diff)
parentv5 v6: ao_doc_str, if faulty document structure, stop; if --no-stop option, skip (diff)
Merge tag 'sisu_5.6.5' into debian/sid
SiSU 5.6.5
Diffstat (limited to 'lib/sisu/v6/html_format.rb')
-rw-r--r--lib/sisu/v6/html_format.rb43
1 files changed, 27 insertions, 16 deletions
diff --git a/lib/sisu/v6/html_format.rb b/lib/sisu/v6/html_format.rb
index b2476719..acc62a74 100644
--- a/lib/sisu/v6/html_format.rb
+++ b/lib/sisu/v6/html_format.rb
@@ -198,7 +198,7 @@ module SiSU_HTML_Format
button +=%{ <p class="tiny_left"><a href="#{@md.make.home_button_image[:link]}" target="_top"><img border="0" src="#{image_path}/#{@md.make.home_button_image[:home_button]}" width="#{@md.make.home_button_image[:w]}" height="#{@md.make.home_button_image[:h]}" alt="home icon --&gt;" /></a></p>\n}
elsif @md.home_button_links.is_a?(Array)
@md.home_button_links.each do |links|
- button +=%{ <p class="tiny_left"><a href="#{links[:url]}/" target="_top">\n #{links[:say]}\n </a></p>\n}
+ button +=%{ <p class="tiny_left"><a href="#{links[:url]}" target="_top">\n #{links[:say]}\n </a></p>\n}
end
end
button +=%{ </td></tr>\n </table>}
@@ -310,6 +310,15 @@ WOK
end
end
def concordance_navigation_band
+ up_button=if @make.build.html_navigation?
+ %{</td>
+<td width="5%" align="right">
+ &nbsp;<a href="toc.html" target="_top" alt="-&gt;">
+ #{png_nav.toc}
+ </a>&nbsp;
+}
+ else ''
+ end
if @make.build.html_top_band?
%{<table summary="concordance navigation band" id="toc" width="100%" bgcolor=#{@vz.color_band1}>
<tr><td width="20%">
@@ -317,29 +326,29 @@ WOK
</td>
<td width="75%" align="center">
#{doc_types}
-</td>
-<td width="5%" align="right">
- &nbsp;<a href="toc.html" target="_top" alt="-&gt;">
- #{png_nav.toc}
- </a>&nbsp;
+#{up_button}
#{@vz.table_close}
<p />}
else ''
end
end
def seg_head_navigation_band(page=:seg)
- if page==:manifest
- nxt=(@file.output_dir_structure.by_language_code? \
- || @file.output_dir_structure.by_filetype?) \
- ? "../html/#{@md.fnb}/toc#{@md.lang_code_insert}#{Sfx[:html]}"
- : "toc#{@md.lang_code_insert}#{Sfx[:html]}"
- firstseg=%{<a href="#{nxt}" target="_top" alt="-&gt;">
+ if @make.build.html_navigation?
+ if page==:manifest
+ nxt=(@file.output_dir_structure.by_language_code? \
+ || @file.output_dir_structure.by_filetype?) \
+ ? "../html/#{@md.fnb}/toc#{@md.lang_code_insert}#{Sfx[:html]}"
+ : "toc#{@md.lang_code_insert}#{Sfx[:html]}"
+ firstseg=%{<a href="#{nxt}" target="_top" alt="-&gt;">
+ #{png_nav.nxt}</a>}
+ elsif @md.firstseg =~/\S+/
+ firstseg=%{<a href="#{@md.firstseg}#{@md.lang_code_insert}#{Sfx[:html]}" target="_top" alt="-&gt;">
#{png_nav.nxt}</a>}
- elsif @md.firstseg =~/\S+/
- firstseg=%{<a href="#{@md.firstseg}#{@md.lang_code_insert}#{Sfx[:html]}" target="_top" alt="-&gt;">
- #{png_nav.nxt}</a>}
+ end
+ else ''
end
- %{<table summary="table of contents segment navigation band" id="toc" width="100%" bgcolor=#{@vz.color_band1}>
+ if @make.build.html_top_band?
+ %{<table summary="table of contents segment navigation band" id="toc" width="100%" bgcolor=#{@vz.color_band1}>
<tr><td width="20%">
#{button_home(page)}
</td>
@@ -350,6 +359,8 @@ WOK
&nbsp;#{firstseg}&nbsp;
#{@vz.table_close}
<p />}
+ else ''
+ end
end
def manifest_link(text)
# @file=SiSU_Env::FileOp.new(@md) if @md