RelativePosition Class
Represents a position on the designer that remains independent of coordinate systems.
Inheritance Hierarchy
System.Object
Microsoft.Windows.Design.Interaction.RelativePosition
Namespace: Microsoft.Windows.Design.Interaction
Assembly: Microsoft.Windows.Design.Interaction (in Microsoft.Windows.Design.Interaction.dll)
Syntax
'Declaration
Public NotInheritable Class RelativePosition _
Implements IEnumerable
public sealed class RelativePosition : IEnumerable
public ref class RelativePosition sealed : IEnumerable
[<Sealed>]
type RelativePosition =
class
interface IEnumerable
end
public final class RelativePosition implements IEnumerable
The RelativePosition type exposes the following members.
Constructors
Name | Description | |
---|---|---|
RelativePosition(array<RelativePosition[]) | Initializes a new instance of the RelativePosition class that contains zero or more existing reference positions. | |
RelativePosition(String, array<RelativePosition[]) | Initializes a new instance of the RelativePosition class that contains zero or more existing reference positions. |
Top
Methods
Name | Description | |
---|---|---|
Contains | Returns a value indicating whether the specified RelativePosition exists inside of this RelativePosition. | |
Equals(Object) | Determines whether the specified object is equal to this RelativePosition object. (Overrides Object.Equals(Object).) | |
Equals(RelativePosition) | Determines whether the specified RelativePosition is equal to this RelativePosition. | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetHashCode | Returns the hash code for this object. (Overrides Object.GetHashCode().) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
ToString | Returns the name of this position. (Overrides Object.ToString().) |
Top
Operators
Name | Description | |
---|---|---|
Equality | Compares two RelativePosition objects. | |
Inequality | Compares two RelativePosition objects. |
Top
Explicit Interface Implementations
Name | Description | |
---|---|---|
IEnumerable.GetEnumerator | For a description of this member, see IEnumerable.GetEnumerator. |
Top
Remarks
You can create a single relative position, or a composite relative position that consists of more than one position. For example, if you define a relative position named "top" and another named "left", you can combine the two by calling new RelativePosition(top, left). Doing so creates a new relative position that is the composite of the first two. The framework defines a set of common relative positions in the static RelativePositions class. You may create your own relative positions for your own needs.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
See Also
Reference
Microsoft.Windows.Design.Interaction Namespace