Class: ConTeXtSetup::Nothing

Inherits:
Param show all
Defined in:
lib/tex/context/contextsetup.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Param

#opt, #optional?, #sanitize_html, #show

Methods inherited from SetupXML

parse_xml, tag_method

Constructor Details

#initialize(interface) ⇒ Nothing

Returns a new instance of Nothing.



411
412
413
414
# File 'lib/tex/context/contextsetup.rb', line 411

def initialize(interface)
  @interface=interface
  @separator=nil
end

Instance Attribute Details

#separatorObject

Returns the value of attribute separator.



405
406
407
# File 'lib/tex/context/contextsetup.rb', line 405

def separator
  @separator
end

Instance Method Details

#==(other) ⇒ Object



424
425
426
# File 'lib/tex/context/contextsetup.rb', line 424

def ==(other)
  Nothing===other && other.separator==@separator
end

#parse_xml(elt) ⇒ Object



406
407
408
409
410
# File 'lib/tex/context/contextsetup.rb', line 406

def parse_xml(elt)
  if elt.attributes["separator"]=="backslash"
    @separator = "\\\\"
  end
end

#to_html(detail = true, cls = 'first') ⇒ Object



415
416
417
418
419
420
421
422
423
# File 'lib/tex/context/contextsetup.rb', line 415

def to_html(detail=true,cls='first')
  if detail
    tr(:class => cls, :valign => "top" ) { 
      td { "..." } + td { "<i>text</i>" }
    }
  else
    "#{@separator}..."
  end
end