C# Class PurplePen.MapUtil

Show file Open project: petergolde/PurplePen Class Usage Examples

Public Properties

Property Type Description
StandardPaperSizes System.Drawing.Printing.PaperSize[]
TextMetricsProvider ITextMetrics

Public Methods

Method Description
CreateToolboxIcon ( Bitmap bm ) : ToolboxIcon
GetDefaultPageSize ( RectangleF printAreaRectangle, float printScaleRatio, int &pageWidth, int &pageHeight, int &pageMargin, bool &landscape ) : void
GetDefaultPrintArea ( string mapFileName, float printScaleRatio ) : PrintArea
ValidateMapFile ( string mapFileName, float &scale, float &dpi, Size &bitmapSize, RectangleF &mapBounds, MapType &mapType, string &errorMessageText ) : bool
ValidatePdf ( string pdfFileName, float &dpi, Size &bitmapSize, string &errorMessageText ) : PdfMapFile

Method Details

CreateToolboxIcon() public static method

public static CreateToolboxIcon ( Bitmap bm ) : ToolboxIcon
bm System.Drawing.Bitmap
return ToolboxIcon

GetDefaultPageSize() public static method

public static GetDefaultPageSize ( RectangleF printAreaRectangle, float printScaleRatio, int &pageWidth, int &pageHeight, int &pageMargin, bool &landscape ) : void
printAreaRectangle System.Drawing.RectangleF
printScaleRatio float
pageWidth int
pageHeight int
pageMargin int
landscape bool
return void

GetDefaultPrintArea() public static method

public static GetDefaultPrintArea ( string mapFileName, float printScaleRatio ) : PrintArea
mapFileName string
printScaleRatio float
return PrintArea

ValidateMapFile() public static method

public static ValidateMapFile ( string mapFileName, float &scale, float &dpi, Size &bitmapSize, RectangleF &mapBounds, MapType &mapType, string &errorMessageText ) : bool
mapFileName string
scale float
dpi float
bitmapSize System.Drawing.Size
mapBounds System.Drawing.RectangleF
mapType MapType
errorMessageText string
return bool

ValidatePdf() public static method

public static ValidatePdf ( string pdfFileName, float &dpi, Size &bitmapSize, string &errorMessageText ) : PdfMapFile
pdfFileName string
dpi float
bitmapSize System.Drawing.Size
errorMessageText string
return PdfMapFile

Property Details

StandardPaperSizes public static property

public static PaperSize[],System.Drawing.Printing StandardPaperSizes
return System.Drawing.Printing.PaperSize[]

TextMetricsProvider public static property

public static ITextMetrics TextMetricsProvider
return ITextMetrics