PyKDE - Python Bindings for KDE
class KPrinter
Table of contents
Modules
tdeprint Classes
All Classes
Module
tdeprint
Class
KPrinter
Inherits
QPaintDevice, KPReloadObject
enums
ApplicationType
= {Dialog, StandAlone, StandAlonePersistent }
CollateType
= {Collate, Uncollate }
ColorMode
= {GrayScale, Color }
Orientation
= {Portrait, Landscape }
PageOrder
= {FirstPageFirst, LastPageFirst }
PageSelectionType
= {ApplicationSide, SystemSide }
PageSetType
= {AllPages, OddPages, EvenPages }
PageSize
= {A4, B5, Letter, Legal, Executive, A0, A1, A2, A3, A5, A6, A7, A8, A9, B0, B1, B10, B2, B3, B4, B6, B7, B8, B9, C5E, Comm10E, DLE, Folio, Ledger, Tabloid, NPageSize }
StandardPageType
= {CopiesPage, FilesPage, Custom }
methods
KPrinter
(restore = 1, m = QPrinter .ScreenResolution)
returns
a KPrinter instance
Argument
Type
Default
restore
bool
1
m
QPrinter.PrinterMode
QPrinter .ScreenResolution
abort
()
returns
(bool)
aborted
()
returns
(bool)
addDialogPage
(_page)
returns
nothing
static
Argument
Type
Default
_page
KPrintDialogPage
addStandardPage
(p)
returns
nothing
static
Argument
Type
Default
p
int
applicationType
()
returns
(KPrinter.ApplicationType)
static
autoConfigure
(prname = QString .null, parent = 0)
returns
(bool)
Argument
Type
Default
prname
QString
QString .null
parent
QWidget
0
cmd
(a0, a1, a2)
Not Implemented
collate
()
returns
(KPrinter.CollateType)
colorMode
()
returns
(KPrinter.ColorMode)
creator
()
returns
(QString)
currentPage
()
returns
(int)
doPreview
(file)
returns
(bool)
In versions KDE 3.1.0 and above only
Argument
Type
Default
file
QString
docDirectory
()
returns
(QString)
In versions KDE 3.1.0 and above only
docFileName
()
returns
(QString)
docName
()
returns
(QString)
errorMessage
()
returns
(QString)
finishPrinting
()
returns
nothing
fromPage
()
returns
(int)
fullPage
()
returns
(bool)
implementation
()
Not Implemented
init
(restore = 1, m = QPrinter .ScreenResolution)
returns
nothing
Argument
Type
Default
restore
bool
1
m
QPrinter.PrinterMode
QPrinter .ScreenResolution
initOptions
(opts)
returns
nothing
Argument
Type
Default
opts
QMap
loadSettings
()
returns
nothing
margins
()
returns
(QSize)
margins
()
returns
top (uint) left (uint) bottom (uint) right (uint)
In versions KDE 3.1.0 and above only
maxPage
()
returns
(int)
metric
(a0)
returns
(int)
Argument
Type
Default
a0
int
minPage
()
returns
(int)
newPage
()
returns
(bool)
numCopies
()
returns
(int)
option
(key)
returns
(QString)
Argument
Type
Default
key
QString
options
()
returns
(QMap
)
orientation
()
returns
(KPrinter.Orientation)
outputFileName
()
returns
(QString)
outputToFile
()
returns
(bool)
pageList
()
returns
(QValueList
)
pageOrder
()
returns
(KPrinter.PageOrder)
pageSelection
()
returns
(KPrinter.PageSelectionType)
static
pageSet
()
returns
(KPrinter.PageSetType)
pageSize
()
returns
(KPrinter.PageSize)
preparePrinting
()
returns
nothing
previewOnly
()
returns
(bool)
printFiles
(files, removeafter = 0, startviewer = 1)
returns
(bool)
Argument
Type
Default
files
QStringList
removeafter
bool
0
startviewer
bool
1
printProgram
()
returns
(QString)
printerName
()
returns
(QString)
printerSelectionOption
()
returns
(QString)
realDrawableArea
()
returns
(QRect)
In versions KDE 3.1.0 and above only
realPageSize
()
returns
(QSize)
reload
()
returns
nothing
removeStandardPage
(p)
returns
nothing
static
Argument
Type
Default
p
int
resolution
()
returns
(int)
In versions KDE 3.1.0 and above only
saveSettings
()
returns
nothing
searchName
()
returns
(QString)
setApplicationType
(type)
returns
nothing
static
Argument
Type
Default
type
KPrinter.ApplicationType
setCollate
(type)
returns
nothing
Argument
Type
Default
type
KPrinter.CollateType
setColorMode
(a0)
returns
nothing
Argument
Type
Default
a0
KPrinter.ColorMode
setCreator
(a0)
returns
nothing
Argument
Type
Default
a0
QString
setCurrentPage
(p = 0)
returns
nothing
Argument
Type
Default
p
int
0
setDocDirectory
(dir)
returns
nothing
In versions KDE 3.1.0 and above only
Argument
Type
Default
dir
QString
setDocFileName
(filename)
returns
nothing
Argument
Type
Default
filename
QString
setDocName
(a0)
returns
nothing
Argument
Type
Default
a0
QString
setErrorMessage
(msg)
returns
nothing
Argument
Type
Default
msg
QString
setFromTo
(a0, a1)
returns
nothing
Argument
Type
Default
a0
int
a1
int
setFullPage
(a0)
returns
nothing
Argument
Type
Default
a0
bool
setMargins
(m)
returns
nothing
Argument
Type
Default
m
QSize
setMargins
(top, left, bottom, right)
returns
nothing
In versions KDE 3.2.0 and above only
Argument
Type
Default
top
uint
left
uint
bottom
uint
right
uint
setMinMax
(a0, a1)
returns
nothing
Argument
Type
Default
a0
int
a1
int
setNumCopies
(n)
returns
nothing
Argument
Type
Default
n
int
setOption
(key, value)
returns
nothing
Argument
Type
Default
key
QString
value
QString
setOption
(key, value, broadcast)
returns
nothing
In versions KDE 3.2.0 and above only
Argument
Type
Default
key
QString
value
QString
broadcast
bool
setOptions
(opts)
returns
nothing
Argument
Type
Default
opts
QMap
setOrientation
(a0)
returns
nothing
Argument
Type
Default
a0
KPrinter.Orientation
setOutputFileName
(a0)
returns
nothing
Argument
Type
Default
a0
QString
setOutputToFile
(a0)
returns
nothing
Argument
Type
Default
a0
bool
setPageOrder
(a0)
returns
nothing
Argument
Type
Default
a0
KPrinter.PageOrder
setPageSelection
(_mode)
returns
nothing
static
Argument
Type
Default
_mode
KPrinter.PageSelectionType
setPageSize
(a0)
returns
nothing
Argument
Type
Default
a0
KPrinter.PageSize
setPreviewOnly
(on)
returns
nothing
Argument
Type
Default
on
bool
setPrintProgram
(cmd)
returns
nothing
Argument
Type
Default
cmd
QString
setPrinterName
(a0)
returns
nothing
Argument
Type
Default
a0
QString
setPrinterSelectionOption
(a0)
returns
nothing
Argument
Type
Default
a0
QString
setRealDrawableArea
(r)
returns
nothing
In versions KDE 3.1.0 and above only
Argument
Type
Default
r
QRect
setRealPageSize
(p)
returns
nothing
Argument
Type
Default
p
QSize
setRealPageSize
(p)
Not Implemented
setResolution
(dpi)
returns
nothing
In versions KDE 3.1.0 and above only
Argument
Type
Default
dpi
int
setSearchName
(n)
returns
nothing
Argument
Type
Default
n
QString
setUsePrinterResolution
(on)
returns
nothing
In versions KDE 3.2.0 and above only
Argument
Type
Default
on
bool
setup
(parent = 0, caption = QString .null, forceExpand = 0)
returns
(bool)
Argument
Type
Default
parent
QWidget
0
caption
QString
QString .null
forceExpand
bool
0
toPage
()
returns
(int)
translateQtOptions
()
returns
nothing