1 #ifndef MWGUI_BOOKPAGE_HPP 
    2 #define MWGUI_BOOKPAGE_HPP 
    4 #include "MyGUI_Colour.h" 
    5 #include "MyGUI_Widget.h" 
    9 #include <boost/function.hpp> 
   10 #include <boost/shared_ptr.hpp> 
   18         typedef boost::shared_ptr <TypesetBook> 
Ptr;
 
   30         virtual std::pair <unsigned int, unsigned int> 
getSize () 
const = 0;
 
   36         typedef boost::shared_ptr <BookTypesetter> 
Ptr;
 
   40         typedef std::pair <Utf8Point, Utf8Point> 
Utf8Span;
 
   55         static Ptr create (
int pageWidth, 
int pageHeight);
 
   68         virtual void lineBreak (
float margin = 0) = 0;
 
   92         virtual void write (Style * Style, 
size_t Begin, 
size_t End) = 0;
 
  122 #endif // MWGUI_BOOKPAGE_HPP 
virtual Style * createStyle(char const *Font, Colour Colour)=0
Create a simple text style consisting of a font and a text color. 
 
virtual void showPage(TypesetBook::Ptr Book, size_t Page)=0
Make the widget display the specified page from the specified book. 
 
uint8_t const * Utf8Point
Definition: bookpage.hpp:39
 
static Ptr create(int pageWidth, int pageHeight)
A factory function for creating the default implementation of a book typesetter. 
Definition: bookpage.cpp:629
 
Alignment
Definition: bookpage.hpp:42
 
TypesetBook::InteractiveId InteractiveId
Definition: bookpage.hpp:104
 
virtual intptr_t addContent(Utf8Span Text, bool Select=true)=0
 
virtual TypesetBook::Ptr complete()=0
Finalize the document layout, and return a pointer to it. 
 
Definition: bookpage.hpp:16
 
Definition: bookpage.hpp:45
 
boost::function< void(InteractiveId)> ClickCallback
Definition: bookpage.hpp:105
 
std::pair< Utf8Point, Utf8Point > Utf8Span
Definition: bookpage.hpp:40
 
virtual void setSectionAlignment(Alignment sectionAlignment)=0
Changes the alignment for the current section of text. 
 
static void registerMyGUIComponents()
Definition: bookpage.cpp:1319
 
virtual void unadviseLinkClicked()=0
Clear the hyper-link click callback. 
 
virtual void selectContent(intptr_t contentHandle)=0
Select a previously created content block for future writes. 
 
virtual void sectionBreak(int margin=0)=0
 
MyGUI::Colour Colour
Definition: bookpage.hpp:38
 
virtual size_t pageCount() const =0
Returns the number of pages in the document. 
 
Definition: bookpage.hpp:44
 
virtual std::pair< unsigned int, unsigned int > getSize() const =0
 
intptr_t InteractiveId
Definition: bookpage.hpp:19
 
A factory class for creating a typeset book instance. 
Definition: bookpage.hpp:34
 
boost::shared_ptr< BookTypesetter > Ptr
Definition: bookpage.hpp:36
 
An interface to the BookPage widget. 
Definition: bookpage.hpp:99
 
virtual void lineBreak(float margin=0)=0
 
virtual void write(Style *Style, Utf8Span Text)=0
 
TypesetBook::InteractiveId InteractiveId
Definition: bookpage.hpp:37
 
virtual void adviseLinkClicked(ClickCallback callback)=0
Set the callback for a clicking a hyper-link in the document. 
 
virtual Style * createHotStyle(Style *BaseStyle, Colour NormalColour, Colour HoverColour, Colour ActiveColour, InteractiveId Id, bool Unique=true)=0
 
boost::shared_ptr< TypesetBook > Ptr
Definition: bookpage.hpp:18
 
Definition: bookpage.hpp:43