Class PrintOutPrint
Print driver implementing output to printer, it does not allow showing print dialog becuase it does not
have dependencies on Windows.Forms
Inheritance
PrintOutPrint
Assembly: Reportman.Drawing.Windows.dll
Syntax
public class PrintOutPrint : PrintOutNet, IDisposable
Constructors
View Source
PrintOutPrint()
Declaration
Fields
View Source
AutoScalePrint
Declaration
public bool AutoScalePrint
Field Value
View Source
BrowsePaperSizes
When BrowsePaperSizes is true, the print driver will browse all paper sizes on the print
server until it finds the correct page size. This procedure can be very slow, specially if
the printer is a network printer, you can disable this browsing
Declaration
public bool BrowsePaperSizes
Field Value
View Source
DisableForwardOnly
Internal property, when this option is set, the printes pages will remain in memory
this is useful for printing multiple copies or process the generated MetaFile later
Declaration
protected bool DisableForwardOnly
Field Value
View Source
FBlackLines
Declaration
protected int FBlackLines
Field Value
View Source
FPagesPrinted
Declaration
protected int FPagesPrinted
Field Value
View Source
FWhiteLines
Declaration
protected int FWhiteLines
Field Value
View Source
ShowPrintProgress
Declaration
public bool ShowPrintProgress
Field Value
View Source
UseStandardPrintController
Declaration
public bool UseStandardPrintController
Field Value
View Source
doc
Declaration
Field Value
View Source
overridedriver
Declaration
protected PrintOut overridedriver
Field Value
Properties
View Source
BlackLinesPrinted
Declaration
public int BlackLinesPrinted { get; }
Property Value
View Source
OutputDevice
Declaration
public string OutputDevice { get; }
Property Value
View Source
PagesPrinted
Declaration
public int PagesPrinted { get; }
Property Value
View Source
WhiteLinesPrinted
Declaration
public int WhiteLinesPrinted { get; }
Property Value
Methods
View Source
DrawPage(MetaFile, MetaPage)
Draw a page to the print surface
Declaration
public override void DrawPage(MetaFile meta, MetaPage page)
Parameters
| Type |
Name |
Description |
| MetaFile |
meta |
MetaFile containing the page
|
| MetaPage |
page |
MetaPage to be drawn
|
Overrides
View Source
The driver should do cleanup here, a print driver should finish print document.
Declaration
public override void EndDocument(MetaFile meta)
Parameters
Overrides
View Source
GetPageSize(out int)
Get current page size, depending on default printed
Declaration
public override Point GetPageSize(out int indexqt)
Parameters
| Type |
Name |
Description |
| int |
indexqt |
Output parameter, index on PageSizeArray
|
Returns
Overrides
View Source
Select printer specified in the MetaFile
Declaration
public void InitPrinter(MetaFile meta)
Parameters
| Type |
Name |
Description |
| MetaFile |
meta |
MetaFile, the PrinterSelect property is used to select the printer
|
View Source
The procedure creates a new PrintDocument
Declaration
public override void NewDocument(MetaFile meta)
Parameters
Overrides
View Source
PageIndexToPaperRawKind(int, ref int, ref int)
Converts a PageSizeArray index to a RawKind, the RawKind index is only available on .Net 2.x
Declaration
public static int PageIndexToPaperRawKind(int index, ref int rwidth, ref int rheight)
Parameters
| Type |
Name |
Description |
| int |
index |
Index in the PageSizeArray
|
| int |
rwidth |
It's filled with the width of the paper in inch thousands
|
| int |
rheight |
It's filled with the height of the paper in inch thousands
|
Returns
| Type |
Description |
| int |
RawKind value
|
View Source
PaperSizeFromPageIndex(int)
Declaration
public static PaperSize PaperSizeFromPageIndex(int index)
Parameters
| Type |
Name |
Description |
| int |
index |
|
Returns
View Source
PaperSizeToQtIndex(PaperSize)
Find the PageSizeArray index given a PaperSize
Declaration
public static int PaperSizeToQtIndex(PaperSize psize)
Parameters
| Type |
Name |
Description |
| PaperSize |
psize |
PaperSize structure
|
Returns
| Type |
Description |
| int |
Integer index to PageSizeArray
|
View Source
Assign events to the PrintDocument and assign page settings
Declaration
public override bool PreparePrint(MetaFile meta)
Parameters
Returns
Overrides
View Source
Declaration
public override bool Print(MetaFile meta)
Parameters
| Type |
Name |
Description |
| MetaFile |
meta |
MetaFile to print
|
Returns
Overrides
View Source
PrinterExists(string)
Declaration
public static bool PrinterExists(string printername)
Parameters
| Type |
Name |
Description |
| string |
printername |
|
Returns
View Source
SelectPrinter(PrinterSelectType)
The driver must select a printer
Declaration
public override void SelectPrinter(PrinterSelectType PrinterSelect)
Parameters
Overrides
View Source
SetOrientation(OrientationType)
Declaration
public override void SetOrientation(OrientationType PageOrientation)
Parameters
Overrides
View Source
UpdateHardMargins()
Update HardMargin values from current printer driver
Declaration
protected void UpdateHardMargins()
Implements