lib/webby/renderer.rb
# call-seq:
#    _layout_page    => string
#
# Apply the desired filters to the page and then render the filtered page
# into the desired layout. The filters to apply to the page are determined
# from the page's meta-data. The layout to use is also determined from the
# page's meta-data.
#
call-seq:
_layout_page    => string

Apply the desired filters to the page and then render the filtered page
into the desired layout. The filters to apply to the page are determined
from the page's meta-data. The layout to use is also determined from the
page's meta-data.
call - seq : _layout_page = > string Apply the desired filters to the page and then render the filtered page into the desired layout . The filters to apply to the page are determined from the page ' s meta - data . The layout to use is also determined from the page ' s meta - data .
def _layout_page
    @content = _render_page
    _track_rendering(@page.path) {
      _render_layout_for(@page)
    }
    raise ::Webby::Error, "rendering stack corrupted" unless @@stack.empty?
    @content
  rescue ::Webby::Error => err
    @log.error "while rendering page '#{@page.path}'"
    @log.error err.message
  rescue => err
    @log.error "while rendering page '#{@page.path}'"
    @log.fatal err
    exit 1
  ensure
    @content = nil
    @@stack.clear
  end
def _layout_page @content = _render_page _track_rendering ( @page . path ) { _render_layout_for ( @page ) } raise :: Webby :: Error , "rendering stack corrupted" unless @@stack . empty? @content rescue :: Webby :: Error => err @log . error "while rendering page '#{@page.path}'" @log . error err . message rescue => err @log . error "while rendering page '#{@page.path}'" @log . fatal err exit 1 ensure @content = nil @@stack . clear end
call-seq:
_layout_page    => string
call - seq : _layout_page = > string