Class CoordinatePoint
Represents a class that contains coordinates in two coordinate systems.
Inheritance
Implements
Inherited Members
Namespace: Syncfusion.Windows.Forms.Edit.Utils
Assembly: Syncfusion.Edit.Windows.dll
Syntax
public class CoordinatePoint : IDisposable
Constructors
CoordinatePoint(ILexemParser, IParsePoint, Int32, Int32, Boolean)
Initializes a new instance of the CoordinatePoint class.
Declaration
public CoordinatePoint(ILexemParser parser, IParsePoint point, int line, int column, bool bAttachToEvents)
Parameters
Type | Name | Description |
---|---|---|
ILexemParser | parser | Lexem parser. |
IParsePoint | point | ParsePoint, coordinate point is associated to. Can be null. |
System.Int32 | line | Virtual line number. |
System.Int32 | column | Virtual column number. |
System.Boolean | bAttachToEvents | Indicates whether point should be attached to text changing events and remain at the same place. |
CoordinatePoint(CoordinatePoint)
Initializes a new instance of the CoordinatePoint class.
Declaration
public CoordinatePoint(CoordinatePoint p)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | p | CoordinatePoint to create new instance from. |
CoordinatePoint(CoordinatePoint, Boolean)
Initializes a new instance of the CoordinatePoint class.
Declaration
public CoordinatePoint(CoordinatePoint p, bool b_attachToEvents)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | p | CoordinatePoint to create new instance from. |
System.Boolean | b_attachToEvents | Indicates whether point should be attached to text changing events and remain at the same place. |
Properties
AttachToEvents
Gets or sets a value indicating whether coordinate point should handle changing of the position of ParsePoint or not.
Declaration
public bool AttachToEvents { get; set; }
Property Value
Type |
---|
System.Boolean |
IsValid
Gets a value indicating whether the coordinate point is valid or not.
Declaration
public bool IsValid { get; }
Property Value
Type |
---|
System.Boolean |
Parser
Gets the parser, coordinates belong to.
Declaration
public ILexemParser Parser { get; }
Property Value
Type |
---|
ILexemParser |
PhysicalPoint
Gets the physical point to stream.
Declaration
public IParsePoint PhysicalPoint { get; }
Property Value
Type |
---|
IParsePoint |
VirtualColumn
Gets the virtual column (Visible column on the screen).
Declaration
public int VirtualColumn { get; }
Property Value
Type |
---|
System.Int32 |
VirtualLine
Gets the virtual line (Visible line on the screen).
Declaration
public int VirtualLine { get; }
Property Value
Type |
---|
System.Int32 |
VirtualPoint
Gets the virtual point.
Declaration
public Point VirtualPoint { get; }
Property Value
Type | Description |
---|---|
System.Drawing.Point | The virtual point. |
Methods
Dispose()
Disposes all the resources used by this object.
Declaration
public void Dispose()
Equals(Object)
Compares two CoordinatePoint instances by override == operator.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | Object to compare. |
Returns
Type | Description |
---|---|
System.Boolean | Result of comparation. |
Overrides
GetHashCode()
Generates hashcode to be used in hashtables.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | Hash code. |
Overrides
ToString()
Gets string representation of the coordinate point.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | String representation of the coordinate point. |
Overrides
UpdatePhisicalCoordinates()
Updates physical coordinates using virtual position.
Declaration
[Obsolete("UpdatePhisicalCoordinates is deprecated, please use UpdatePhysicalCoordinates instead.")]
public void UpdatePhisicalCoordinates()
UpdatePhysicalCoordinates()
Updates physical coordinates using virtual position.
Declaration
public void UpdatePhysicalCoordinates()
UpdateVirtualCoordinates()
Updates virtual coordinates using physical position.
Declaration
public void UpdateVirtualCoordinates()
Events
Deleted
Occurs when the parse point is deleted.
Declaration
public event CoordinatePointDeletedEventHandler Deleted
Event Type
Type |
---|
CoordinatePointDeletedEventHandler |
PointReset
Occurs when coordinate point coordinates are reset.
Declaration
public event EventHandler PointReset
Event Type
Type |
---|
System.EventHandler |
Operators
Equality(CoordinatePoint, CoordinatePoint)
Gets a value regarding whether the first point is equal to second point.
Declaration
public static bool operator ==(CoordinatePoint leftPoint, CoordinatePoint rightPoint)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | leftPoint | First point to compare. |
CoordinatePoint | rightPoint | Second point to compare. |
Returns
Type | Description |
---|---|
System.Boolean | Result of comparation. |
GreaterThan(CoordinatePoint, CoordinatePoint)
Gets a value regarding whether the first point is bigger than second point.
Declaration
public static bool operator>(CoordinatePoint leftPoint, CoordinatePoint rightPoint)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | leftPoint | First point to compare. |
CoordinatePoint | rightPoint | Second point to compare. |
Returns
Type | Description |
---|---|
System.Boolean | Result of comparation. |
GreaterThanOrEqual(CoordinatePoint, CoordinatePoint)
Gets a value regarding whether the first point is bigger than or equal to second point.
Declaration
public static bool operator >=(CoordinatePoint leftPoint, CoordinatePoint rightPoint)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | leftPoint | First point to compare. |
CoordinatePoint | rightPoint | Second point to compare. |
Returns
Type | Description |
---|---|
System.Boolean | Result of comparation. |
Inequality(CoordinatePoint, CoordinatePoint)
Gets a value regarding whether the first point is not equal to second point.
Declaration
public static bool operator !=(CoordinatePoint leftPoint, CoordinatePoint rightPoint)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | leftPoint | First point to compare. |
CoordinatePoint | rightPoint | Second point to compare. |
Returns
Type | Description |
---|---|
System.Boolean | Result of comparation. |
LessThan(CoordinatePoint, CoordinatePoint)
Gets a value regarding whether the first point is bigger than second point.
Declaration
public static bool operator <(CoordinatePoint leftPoint, CoordinatePoint rightPoint)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | leftPoint | First point to compare. |
CoordinatePoint | rightPoint | Second point to compare. |
Returns
Type | Description |
---|---|
System.Boolean | Result of comparation. |
LessThanOrEqual(CoordinatePoint, CoordinatePoint)
Gets a value regarding whether the first point is less than or equal to second point.
Declaration
public static bool operator <=(CoordinatePoint leftPoint, CoordinatePoint rightPoint)
Parameters
Type | Name | Description |
---|---|---|
CoordinatePoint | leftPoint | First point to compare. |
CoordinatePoint | rightPoint | Second point to compare. |
Returns
Type | Description |
---|---|
System.Boolean | Result of comparation. |