Applies an animation to the specified DependencyProperty. The animation is started when the next frame is rendered. If the specified property is already animated, the SnapshotAndReplace handoff behavior is used. (Inherited from Animatable.)

Applies an animation to the specified DependencyProperty. The animation is started when the next frame is rendered. If the specified property is already animated, the specified HandoffBehavior is used. (Inherited from Animatable.)

Creates a modifiable clone of this RectangleGeometry, making deep copies of this object's values. When copying dependency properties, this method copies resource references and data bindings (but they might no longer resolve) but not animations or their current values.

Creates a modifiable clone of this RectangleGeometry object, making deep copies of this object's current values. Resource references, data bindings, and animations are not copied, but their current values are.

Coerces the value of the specified dependency property. This is accomplished by invoking any CoerceValueCallback function specified in property metadata for the dependency property as it exists on the calling DependencyObject. (Inherited from DependencyObject.)

Returns an axis-aligned rectangle that is exactly large enough to contain the geometry after it has been outlined with the specified Pen, given the specified tolerance factor. (Inherited from Geometry.)

Ensures that the Freezable is being accessed from a valid thread. Inheritors of Freezable must call this method at the beginning of any API that reads data members that are not dependency properties. (Inherited from Freezable.)

Gets a value that describes the intersection between the specified Geometry and the stroke created by applying the specified Pen to the current geometry, given the specified margin of error. (Inherited from Geometry.)

Raises the Changed event for the Freezable and invokes its OnChanged method. Classes that derive from Freezable should call this method at the end of any API that modifies class members that are not stored as dependency properties. (Inherited from Freezable.)

Verifies that the Freezable is not frozen and that it is being accessed from a valid threading context. Freezable inheritors should call this method at the beginning of any API that writes to data members that are not dependency properties. (Inherited from Freezable.)

This example describes how to use the RectangleGeometry class to describe a rectangle.

The following example shows how to create and render a RectangleGeometry. The relative position and the dimensions of the rectangle are defined by a Rect structure. The relative position is 50,50 and the height and the width are both 25 creating a square. The rectangle's interior is painted with a LemonChiffon brush and its outline is painted with a Black stroke with a thickness of 1.

Although this example used a Path element to render the RectangleGeometry, there are many other ways to use RectangleGeometry objects. For example, a RectangleGeometry can be used to specify the Clip of a UIElement or the Geometry of a GeometryDrawing.

This example shows how to create composite shapes using Geometry objects and display them using a Path element. In the following example, a LineGeometry, EllipseGeometry, and a RectangleGeometry are used with a GeometryGroup to create a composite shape. The geometries are then drawn using a Path element.