Class BitmapScaleHandler
Factory for the generic BitmapScaleHandler
Inheritance
System.Object
BitmapScaleHandler
Namespace: Dapplo.Windows.Dpi
Assembly: Dapplo.Windows.Dpi.dll
Syntax
public static class BitmapScaleHandler : object
Methods
| Improve this Doc View SourceCreate<TKey>(DpiHandler, Func<TKey, Double, Bitmap>, Func<Bitmap, Double, Bitmap>)
Create with your own providing logic
Declaration
public static BitmapScaleHandler<TKey> Create<TKey>(DpiHandler dpiHandler, Func<TKey, double, Bitmap> bitmapProvider, Func<Bitmap, double, Bitmap> bitmapScaler = null)
Parameters
Type | Name | Description |
---|---|---|
DpiHandler | dpiHandler | DpiHandler |
Func<TKey, System.Double, Bitmap> | bitmapProvider | A function which provides the requested bitmap |
Func<Bitmap, System.Double, Bitmap> | bitmapScaler | A function to provide a newly scaled bitmap |
Returns
Type | Description |
---|---|
BitmapScaleHandler<TKey> |
Type Parameters
Name | Description |
---|---|
TKey |
WithComponentResourceManager(DpiHandler, Type, Func<Bitmap, Double, Bitmap>)
Create a BitmapScaleHandler with a ComponentResourceManager as resource provider
Declaration
public static BitmapScaleHandler<string> WithComponentResourceManager(DpiHandler dpiHandler, Type resourceType, Func<Bitmap, double, Bitmap> bitmapScaler = null)
Parameters
Type | Name | Description |
---|---|---|
DpiHandler | dpiHandler | DpiHandler |
Type | resourceType | Type to create the ComponentResourceManager for |
Func<Bitmap, System.Double, Bitmap> | bitmapScaler | A function to provide a newly scaled bitmap |
Returns
Type | Description |
---|---|
BitmapScaleHandler<System.String> |