aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v6/ao_doc_objects.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2014-06-19 19:33:41 -0400
committerRalph Amissah <ralph@amissah.com>2014-06-19 19:33:41 -0400
commitdffa2293ca33039bc9a625c23842644104fcf401 (patch)
tree1679f52825636a7b38e5472334ffd0de84e36820 /lib/sisu/v6/ao_doc_objects.rb
parentv6: ao, syntax, able optionally to indicate the language syntax of a code block (diff)
v6: ao, syntax, introduce box text block/group
Diffstat (limited to 'lib/sisu/v6/ao_doc_objects.rb')
-rw-r--r--lib/sisu/v6/ao_doc_objects.rb20
1 files changed, 20 insertions, 0 deletions
diff --git a/lib/sisu/v6/ao_doc_objects.rb b/lib/sisu/v6/ao_doc_objects.rb
index 9356321c..e1a14da1 100644
--- a/lib/sisu/v6/ao_doc_objects.rb
+++ b/lib/sisu/v6/ao_doc_objects.rb
@@ -268,6 +268,26 @@ module SiSU_AO_DocumentStructure
@of,@is,@tags,@obj,@lngsyn,@idx,@ocn,@odv,@osp,@parent,@number_,@note_,@ocn_,@num,@digest,@tmp=of,is,tags,obj,lngsyn,idx,ocn,odv,osp,parent,number_,note_,ocn_,num,digest,tmp
self
end
+ def box(h,o=nil)
+ of= @of #Symbol, classification - group
+ is= :box #Symbol, classification - specific type
+ tags= h[:tags] || ((defined? o.tags) ? o.tags : []) #Array, associated object tags, names if any
+ obj= h[:obj] || ((defined? o.obj) ? o.obj : nil) #String, text content
+ idx= h[:idx] || ((defined? o.idx) ? o.idx : nil) #String, book index provided?
+ ocn= h[:ocn] || ((defined? o.ocn) ? o.ocn : nil) #Integer, sequential on substantive-content objects
+ odv= h[:odv] || ((defined? o.odv) ? o.odv : nil)
+ osp= h[:osp] || ((defined? o.osp) ? o.osp : nil)
+ parent= h[:parent] || ((defined? o.parent) ? o.parent : nil) #[Node parent]
+ note_= h[:note_] || ((defined? o.note_) ? o.note_ : false) #Bool, endnotes/footnotes? (processing optimization)
+ ocn_= if h[:ocn_].nil? then ((defined? o.ocn_) ? o.ocn_ : true) #Bool? no ocn, non-substantive content, do not include in toc #consider
+ else h[:ocn_]
+ end
+ num= h[:num] || ((defined? o.num) ? o.num : nil)
+ digest= h[:digest] || ((defined? o.digest) ? o.digest : nil) #hash digests, sha512, sha256 or md5
+ tmp= h[:tmp] || ((defined? o.tmp) ? o.tmp : nil) #available for processing, empty after use
+ @of,@is,@tags,@obj,@idx,@ocn,@odv,@osp,@parent,@note_,@ocn_,@num,@digest,@tmp=of,is,tags,obj,idx,ocn,odv,osp,parent,note_,ocn_,num,digest,tmp
+ self
+ end
def block(h,o=nil)
of= @of #Symbol, classification - group
is= :block #Symbol, classification - specific type