aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v5/sysenv.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2013-12-03 00:28:11 -0500
committerRalph Amissah <ralph@amissah.com>2013-12-03 00:28:11 -0500
commitc7f7a26587c9ae9e569eb46b4d90f93ff63984d6 (patch)
treecbd1f15db9b3023bf588cec505590a7ee756cd3a /lib/sisu/v5/sysenv.rb
parentv5: plaintext, smarttext: rst (diff)
v5: xml, docbook
Diffstat (limited to 'lib/sisu/v5/sysenv.rb')
-rw-r--r--lib/sisu/v5/sysenv.rb99
1 files changed, 99 insertions, 0 deletions
diff --git a/lib/sisu/v5/sysenv.rb b/lib/sisu/v5/sysenv.rb
index 094df7fd..f25cd027 100644
--- a/lib/sisu/v5/sysenv.rb
+++ b/lib/sisu/v5/sysenv.rb
@@ -1478,6 +1478,12 @@ module SiSU_Env
? @rc['odt']['ocn']
: true
end
+ def xml_docbook_ocn?
+ ((defined? @rc['xml_docbook']['ocn']) \
+ && @rc['xml_docbook']['ocn']==false) \
+ ? @rc['xml_docbook']['ocn']
+ : true
+ end
def xml_scaffold_ocn?
((defined? @rc['xml_scaffold']['ocn']) \
&& @rc['xml_scaffold']['ocn']==false) \
@@ -2760,6 +2766,12 @@ WOK
? @rc['program_select']['xml_viewer']
: text_editor
end
+ def docbook_viewer
+ ((defined? @rc['program_select']['xml_viewer']) \
+ && @rc['program_select']['xml_viewer'] =~/\S\S+/) \
+ ? @rc['program_select']['xml_viewer']
+ : text_editor
+ end
def xml_editor
xml_viewer
end
@@ -3061,6 +3073,9 @@ WOK
if @md.opt.act[:xml_dom][:set]==:on #% --xml-dom, -X xml dom type
ft << @md.fn[:dom]
end
+ if @md.opt.act[:xml_docbook_book][:set]==:on #% --xml-docbook-book
+ ft << @md.fn[:xml_docbook_book]
+ end
if @md.opt.act[:xml_scaffold_structure_sisu][:set]==:on #% --xml-scaffold --xml-scaffold-sisu
ft << @md.fn[:xml_scaffold_structure_sisu]
end
@@ -3123,6 +3138,9 @@ WOK
if @opt.act[:xml_dom][:set]==:on #% --xml-dom, -X xml dom type
ft << 'dom.xml' << '??.dom.xml' << 'dom.??.xml'
end
+ if @opt.act[:xml_docbook_book][:set]==:on #% --xml-docbook-book
+ ft << 'docbook.xml' << '??.docbook.xml' << 'docbook.??.xml'
+ end
if @opt.act[:xml_scaffold_structure_sisu][:set]==:on #% --xml-scaffold --xml-scaffold-sisu
ft << 'scaffold.xml' << '??.scaffold.xml' << 'scaffold.??.xml'
end
@@ -4487,6 +4505,12 @@ WOK
fn=base_filename.xml_dom
make_file(path,fn)
end
+ def xml_docbook_book
+ path=output_path.xml_docbook_book.dir
+ make_path(path)
+ fn=base_filename.xml_docbook_book
+ make_file(path,fn)
+ end
def xml_scaffold_structure_sisu
path=output_path.xml_scaffold_structure_sisu.dir
make_path(path)
@@ -4697,6 +4721,15 @@ WOK
end
self
end
+ def xml_docbook_book
+ def dir
+ output_path.xml_docbook.dir + '/' + base_filename.xml_docbook_book
+ end
+ def rel
+ output_path.xml_docbook.rel + '/' + base_filename.xml_docbook_book
+ end
+ self
+ end
def xml_scaffold_structure_sisu
def dir
output_path.xml.dir + '/' + base_filename.xml_scaffold_structure_sisu
@@ -5132,6 +5165,24 @@ WOK
end
i18n(fnh)
end
+ def xml_docbook_book(fh=nil)
+ fh=default_hash_build(fh,Sfx[:xml_docbook_book])
+ fh[:lng]=lang_code?(fh[:lng])
+ fnh=if output_dir_structure.by_filename?
+ {
+ fn: 'scroll',
+ ft: fh[:ft],
+ lng: fh[:lng],
+ }
+ else
+ {
+ fn: fh[:fn],
+ ft: fh[:ft],
+ lng: fh[:lng],
+ }
+ end
+ i18n(fnh)
+ end
def xml_scaffold_structure_sisu(fh=nil)
fh=default_hash_build(fh,Sfx[:xml_scaffold_structure_sisu])
fh[:lng]=lang_code?(fh[:lng])
@@ -6023,6 +6074,54 @@ WOK
xml
self
end
+ def xml_docbook
+ def ft
+ 'docbook_CONSTRUCTION_ZONE'
+ end
+ def dir
+ set_path(ft).dir.abc
+ end
+ def url
+ set_path(ft).url.abc
+ end
+ def rel
+ set_path(ft).rel.abc
+ end
+ def rcp
+ set_path(ft).rcp.abc
+ end
+ def rel_sm
+ set_path(ft).rel_sm.ab
+ end
+ def rel_image
+ '../../_sisu/image'
+ end
+ self
+ end
+ def xml_docbook_book
+ def ft
+ 'docbook_CONSTRUCTION_ZONE'
+ end
+ def dir
+ set_path(ft).dir.abc
+ end
+ def url
+ set_path(ft).url.abc
+ end
+ def rel
+ set_path(ft).rel.abc
+ end
+ def rcp
+ set_path(ft).rcp.abc
+ end
+ def rel_sm
+ set_path(ft).rel_sm.ab
+ end
+ def rel_image
+ '../../_sisu/image'
+ end
+ self
+ end
def xml_scaffold_structure_sisu
def ft
'sisu.scaffold.xml'