rwlogo
Rogue Wave Views 5.5.1

Rogue Wave Views
Foundation Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

IlvPrintable Class Reference

This class encapsulates the object to be printed. More...

#include <ilviews/printing/printable.h>

Inheritance diagram for IlvPrintable:
IlvPrintableComposite IlvPrintableFrame IlvPrintableScalable IlvPrintableText IlvPrintableContainer IlvPrintableGraphic IlvPrintableFormattedText

List of all members.

Public Member Functions

 IlvPrintable (IlvPrintable const &other)
 The copy constructor.
 IlvPrintable ()
 The default constructor.
virtual ~IlvPrintable ()
 The destructor.
virtual IlvRect getBBox (IlvPrintableJob const &job) const =0
 Gets the bounding box of the area to print.
void lock ()
 Locks the current instance.
IlvPrintableoperator= (IlvPrintable const &other)
 The assignment operator.
IlBoolean print (IlvPrintableJob const &job) const
 Prints the contents of the object.
void unlock ()
 Unlocks the current instance.

Protected Member Functions

virtual IlBoolean internalPrint (IlvPrintableJob const &job) const =0
 This function actually prints the document.

Detailed Description

This class encapsulates the object to be printed.

Library: ilvprint

This is an abstract class that is intended to be inherited to encapsulate any object(s) that can be drawn on an IlvPort so that they may be printed.

Instances of this class should be contained in an IlvPrintableDocument object.

See also:
IlvPrintableDocument::append

Constructor & Destructor Documentation

virtual IlvPrintable::~IlvPrintable (  )  [virtual]

The destructor.

This member function is likely to be overloaded in inherited classes.

IlvPrintable::IlvPrintable ( IlvPrintable const &  other  ) 

The copy constructor.

Parameters:
other The object to copy.

Member Function Documentation

virtual IlvRect IlvPrintable::getBBox ( IlvPrintableJob const &  job  )  const [pure virtual]

Gets the bounding box of the area to print.

This pure virtual member function must be overloaded in inherited classes.

Parameters:
job The settings of the current print job.
Returns:
The bounding box.

Implemented in IlvPrintableComposite, IlvPrintableScalable, IlvPrintableText, IlvPrintableFormattedText, and IlvPrintableFrame.

virtual IlBoolean IlvPrintable::internalPrint ( IlvPrintableJob const &  job  )  const [protected, pure virtual]

This function actually prints the document.

This pure virtual member function must be overloaded in inherited classes. It actually does the printing.

Parameters:
job The settings of the current print job.
Returns:
IlFalse if an error occurred during the printing, or IlTrue otherwise.

Implemented in IlvPrintableComposite, IlvPrintableContainer, IlvPrintableText, IlvPrintableFormattedText, IlvPrintableGraphic, and IlvPrintableFrame.

void IlvPrintable::lock (  ) 

Locks the current instance.

A reference counter is incremented internally.

IlvPrintable& IlvPrintable::operator= ( IlvPrintable const &  other  ) 

The assignment operator.

Parameters:
other Another instance of this class.
Returns:
A reference to the current object.
IlBoolean IlvPrintable::print ( IlvPrintableJob const &  job  )  const

Prints the contents of the object.

This function uses the job given as the parameter to get the settings of the current print job.

It actually sets the clipping area and calls the virtual function internalPrint.

Parameters:
job The settings of the current print job.
Returns:
IlFalse if an error occurred during the printing, or IlTrue otherwise.
void IlvPrintable::unlock (  ) 

Unlocks the current instance.

A reference counter is decremented internally; when the reference counter reaches 0, the instance is deleted.


© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.