Method: Twb::DocDashboardWebVert#initialize

Defined in:
lib/twb/docdashboardwebvert.rb

#initializeDocDashboardWebVert

Returns a new instance of DocDashboardWebVert.



59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# File 'lib/twb/docdashboardwebvert.rb', line 59

def initialize
  @oneColWebPageDash = Nokogiri::XML::Document.parse <<-ONECOlWEBDASH
  <dashdoc>
    <dashboard name='Single Column Web Page Automatic'>
      <style></style>
      <zones>
        <zone h='100000' id='3' param='vert' type='layout-flow' w='100000' x='0' y='0'>
          <zone h='6221' id='1' type='title' w='100000' x='0' y='0'></zone>
          <zone h='93157' id='4' param='horz' type='layout-flow' w='100000' x='0' y='6221'>
            <zone forceUpdate='' h='93157' id='6' param='URL' type='web' w='99655' x='0' y='6221'></zone>
          </zone>
        </zone>
      </zones>
    </dashboard>
    <window auto-hidden='0' class='dashboard' maximized='1' name='Single Column Web Page Automatic'>
      <zones>
        <zone h='6221' id='1' name='' type='title' w='100000' x='0' y='0' />
        <zone forceUpdate='' h='93157' id='5' name='' param='Web Page' type='web' w='50000' x='50000' y='6221' />
      </zones>
    </window>
  </dashdoc>
  ONECOlWEBDASH
  # notes:
  #  - adding a size element to the <dashboard element will change it from automatic, e.g.
  #
  #    <dashboard name='One Column Web Page Laptop (800w 600h)'>
  #    <style>
  #    </style>
  #    <size maxheight='600' maxwidth='800' minheight='600' minwidth='800' />
  #
  #  - the 'name' sttributes for the window and dashboard must match
  @type = 'columnar Web Page'
  @dashnode = @oneColWebPageDash.at_xpath('//dashboard')
  @winnode  = @oneColWebPageDash.at_xpath('//window')
end