|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.trolltech.qt.QSignalEmitter
com.trolltech.qt.QtJambiObject
com.trolltech.qt.core.QObject
com.trolltech.qt.gui.QWidget
com.trolltech.qt.gui.QDialog
com.trolltech.qt.gui.QPrintPreviewDialog
public class QPrintPreviewDialog
The QPrintPreviewDialog
class provides a dialog for previewing and configuring page layouts for printer output. Using QPrintPreviewDialog
in your existing application is straightforward:
QPrintPreviewDialog
. You can construct a QPrintPreviewDialog
with an existing QPrinter
object, or you can have QPrintPreviewDialog
create one for you, which will be the system default printer.
paintRequested()
signal to a slot. When the dialog needs to generate a set of preview pages, the paintRequested()
signal will be emitted. You can use the exact same code for the actual printing as for having the preview generated, including calling QPrinter::newPage()
to start a new page in the preview. Connect a slot to the paintRequested()
signal, where you draw onto the QPrinter
object that is passed into the slot.
exec()
. Call QPrintPreviewDialog::exec()
to show the preview dialog.
QPrinter
, QPrintDialog
, QPageSetupDialog
, and QPrintPreviewWidget
.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.trolltech.qt.gui.QDialog |
---|
QDialog.DialogCode |
Nested classes/interfaces inherited from class com.trolltech.qt.gui.QWidget |
---|
QWidget.RenderFlag, QWidget.RenderFlags |
Nested classes/interfaces inherited from class com.trolltech.qt.QSignalEmitter |
---|
QSignalEmitter.Signal0, QSignalEmitter.Signal1, QSignalEmitter.Signal2, QSignalEmitter.Signal3, QSignalEmitter.Signal4, QSignalEmitter.Signal5, QSignalEmitter.Signal6, QSignalEmitter.Signal7, QSignalEmitter.Signal8, QSignalEmitter.Signal9 |
Field Summary | |
---|---|
QSignalEmitter.Signal1 |
paintRequested
This signal is emitted when the QPrintPreviewDialog needs to generate a set of preview pages. |
Fields inherited from class com.trolltech.qt.gui.QDialog |
---|
accepted, finished, rejected |
Fields inherited from class com.trolltech.qt.gui.QWidget |
---|
customContextMenuRequested |
Constructor Summary | |
---|---|
QPrintPreviewDialog()
This will create an internal QPrinter object, which will use the system default printer. |
|
QPrintPreviewDialog(QPrinter printer)
Constructs a QPrintPreviewDialog based on printer and with parent as the parent widget. |
|
QPrintPreviewDialog(QPrinter printer,
QWidget parent)
Constructs a QPrintPreviewDialog based on printer and with parent as the parent widget. |
|
QPrintPreviewDialog(QPrinter printer,
QWidget parent,
Qt.WindowFlags flags)
Constructs a QPrintPreviewDialog based on printer and with parent as the parent widget. |
|
QPrintPreviewDialog(QPrinter printer,
QWidget parent,
Qt.WindowType[] flags)
Constructs a QPrintPreviewDialog based on printer and with parent as the parent widget. |
|
QPrintPreviewDialog(QWidget parent)
This will create an internal QPrinter object, which will use the system default printer. |
|
QPrintPreviewDialog(QWidget parent,
Qt.WindowFlags flags)
This will create an internal QPrinter object, which will use the system default printer. |
|
QPrintPreviewDialog(QWidget parent,
Qt.WindowType[] flags)
This will create an internal QPrinter object, which will use the system default printer. |
Method Summary | |
---|---|
static QPrintPreviewDialog |
fromNativePointer(QNativePointer nativePointer)
|
Methods inherited from class com.trolltech.qt.gui.QDialog |
---|
accept, done, exec, isSizeGripEnabled, reject, result, setModal, setResult, setSizeGripEnabled |
Methods inherited from class com.trolltech.qt.core.QObject |
---|
childEvent, children, connectSlotsByName, customEvent, disposeLater, dumpObjectInfo, dumpObjectTree, dynamicPropertyNames, event, eventFilter, findChild, findChild, findChild, findChildren, findChildren, findChildren, findChildren, indexOfProperty, installEventFilter, isWidgetType, killTimer, moveToThread, objectName, parent, properties, property, removeEventFilter, setObjectName, setParent, setProperty, startTimer, timerEvent, toString, userProperty |
Methods inherited from class com.trolltech.qt.QtJambiObject |
---|
dispose, disposed, equals, finalize, reassignNativeResources, tr, tr, tr |
Methods inherited from class com.trolltech.qt.QSignalEmitter |
---|
blockSignals, disconnect, disconnect, signalsBlocked, signalSender, thread |
Methods inherited from class java.lang.Object |
---|
clone, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.trolltech.qt.QtJambiInterface |
---|
disableGarbageCollection, nativeId, nativePointer, reenableGarbageCollection, setJavaOwnership |
Field Detail |
---|
public final QSignalEmitter.Signal1 paintRequested
QPrintPreviewDialog
needs to generate a set of preview pages. The printer instance supplied is the paint device onto which you should paint the contents of each page, using the QPrinter
instance in the same way as you would when printing directly.
Constructor Detail |
---|
public QPrintPreviewDialog(QPrinter printer, QWidget parent, Qt.WindowType[] flags)
QPrintPreviewDialog
based on printer and with parent as the parent widget. The widget flags flags are passed on to the QWidget
constructor. QWidget::setWindowFlags()
.
public QPrintPreviewDialog(QPrinter printer, QWidget parent)
QPrintPreviewDialog
based on printer and with parent as the parent widget. The widget flags flags are passed on to the QWidget
constructor. QWidget::setWindowFlags()
.
public QPrintPreviewDialog(QPrinter printer)
QPrintPreviewDialog
based on printer and with parent as the parent widget. The widget flags flags are passed on to the QWidget
constructor. QWidget::setWindowFlags()
.
public QPrintPreviewDialog(QPrinter printer, QWidget parent, Qt.WindowFlags flags)
QPrintPreviewDialog
based on printer and with parent as the parent widget. The widget flags flags are passed on to the QWidget
constructor. QWidget::setWindowFlags()
.
public QPrintPreviewDialog(QWidget parent, Qt.WindowType[] flags)
QPrinter
object, which will use the system default printer.
public QPrintPreviewDialog(QWidget parent)
QPrinter
object, which will use the system default printer.
public QPrintPreviewDialog()
QPrinter
object, which will use the system default printer.
public QPrintPreviewDialog(QWidget parent, Qt.WindowFlags flags)
QPrinter
object, which will use the system default printer.
Method Detail |
---|
public static QPrintPreviewDialog fromNativePointer(QNativePointer nativePointer)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |