Interface ICanvasFactory
Factory for creating ICanvas instances
Namespace: Codecrete.SwissQRBill.Generator.Canvas
Assembly: Codecrete.SwissQRBill.Core.dll
Syntax
public interface ICanvasFactory
Methods
| Edit this page View SourceCanCreate(BillFormat)
Indicates if this factory can create a canvas for the specified bill format.
Factories must register themselves with the global CanvasCreator instance.
Declaration
bool CanCreate(BillFormat format)
Parameters
| Type | Name | Description |
|---|---|---|
| BillFormat | format | bill format |
Returns
| Type | Description |
|---|---|
| bool |
|
Create(BillFormat, double, double)
Creates a canvas for the specified bill format.
Declaration
ICanvas Create(BillFormat format, double width, double height)
Parameters
| Type | Name | Description |
|---|---|---|
| BillFormat | format | bill format |
| double | width | canvas width, in mm |
| double | height | canvas height, in mm |
Returns
| Type | Description |
|---|---|
| ICanvas | new |