Click or drag to resize

DrawingUtilitiesLoadIconWithScaleDown Method

Loads an icon from an embedded resource. If the icon is not a standard size, this function scales down a larger image.

Namespace:  Rhino.UI
Assembly:  RhinoCommon (in RhinoCommon.dll)
Since: 6.0
Syntax
public static Icon LoadIconWithScaleDown(
	string iconName,
	int sizeDesired,
	Assembly assembly = null
)

Parameters

iconName
Type: SystemString
The case-sensitive name of the icon manifest resource being requested.
sizeDesired
Type: SystemInt32
The desired size, in pixels, of the icon.
assembly (Optional)
Type: System.ReflectionAssembly
The assembly containing the manifest resource.

Return Value

Type: Icon
The icon if successful, null otherwise.
Exceptions
ExceptionCondition
ArgumentException Thrown when iconName is not found as an embedded resource in the specified assembly.
See Also