Module reahl.web.layout¶
New in version 3.2.
Utilities to deal with layout.
PageLayout¶
-
class
reahl.web.layout.PageLayout(document_layout=None, contents_layout=None, header_layout=None, footer_layout=None)¶ A PageLayout creates a basic skeleton inside an
reahl.web.ui.HTML5Page, and optionally applies specifiedLayouts to parts of this skeleton.The skeleton consists of a
Divcalled the document of the page, which contains three sub-sections inside of it:the .header – the page header area where menus and banners go;
the .contents of the page – the main area to which the main content will be added; and
the .footer – the page footer where links and legal notices go.
- Parameters
Styling
Adds a <div id=”doc”> to the <body> of the page, which contains:
a <header id=”hd”>
a <div id=”contents”>
a <footer id=”ft”>
New in version 3.2.
-
header¶ The
reahl.web.ui.Headerof the page.
-
contents¶ The
reahl.web.ui.Divcontaining the contents.
The
reahl.web.ui.Footerof the page.
-
document¶ The
reahl.web.ui.Divcontaining the entire page.
-
header_layout¶ A
reahl.web.fw.Layoutto be used for the header of the page.
-
contents_layout¶ A
reahl.web.fw.Layoutto be used for the contents div of the page.
A
reahl.web.fw.Layoutto be used for the footer of the page.
-
document_layout¶ A
reahl.web.fw.Layoutto be used for the document of the page.
-
customise_widget()¶ Override this method in subclasses to allow your Layout to change its Widget upon construction. There is no need to call super(), as the superclass implementation does nothing.
