RectangleFExtensionsScaleByFactor Method
Scale the size and position of the source RectangleF
by the specified percentage factor.
Namespace: DevCase.Extensions.RectangleFExtensionsAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[EditorBrowsableAttribute(EditorBrowsableState.Always)]
public static RectangleF ScaleByFactor(
this RectangleF sender,
float factor
)
<ExtensionAttribute>
<EditorBrowsableAttribute(EditorBrowsableState.Always)>
Public Shared Function ScaleByFactor (
sender As RectangleF,
factor As Single
) As RectangleF
Dim sender As RectangleF
Dim factor As Single
Dim returnValue As RectangleF
returnValue = sender.ScaleByFactor(factor)
public:
[ExtensionAttribute]
[EditorBrowsableAttribute(EditorBrowsableState::Always)]
static RectangleF ScaleByFactor(
RectangleF sender,
float factor
)
[<ExtensionAttribute>]
[<EditorBrowsableAttribute(EditorBrowsableState.Always)>]
static member ScaleByFactor :
sender : RectangleF *
factor : float32 -> RectangleF
No code example is currently available or this language may not be supported.
- sender RectangleF
-
The source RectangleF.
- factor Single
-
The percentage factor.
RectangleF
The resulting
RectangleF.
In Visual Basic and C#, you can call this method as an instance method on any object of type
RectangleF. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
This is a code example.
No code example is currently available or this language may not be supported.
Dim oldRect As New RectangleF(New PointF(100, 100), New SizeF(100, 100))
Dim newRect As RectangleF = ScaleByFactor(oldRect, 2.0F)
Console.WriteLine(String.Format("oldRect: {0}", oldRect.ToString())) ' {X=100,Y=100,Width=100,Height=100}
Console.WriteLine(String.Format("newRect: {0}", newRect.ToString())) ' {X=200,Y=200,Width=200,Height=200}
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.