Method | Description | |
---|---|---|
AddDashLine ( System mousePosition ) : void |
add the dash U/V line (used only in "Move grid line" operation)
|
|
AddDashULine ( System mousePosition ) : bool |
show the candicate new U grid line to be added. In "add horizontal grid line" operation, there'll be a dash line following the movement of the mouse, it's drawn by this method
|
|
AddDashVLine ( System mousePosition ) : bool |
show the candicate new V grid line to be added. In "add vertical grid line" operation, there'll be a dash line following the movement of the mouse, it's drawn by this method
|
|
DrawCurtainGrid ( |
draw curtain grid in the canvas
|
|
GetConjointSegments ( |
check whether the segments which have the same junction with the specified segment will be isolated if we delete the specified segment for example: 2 grid line has one junction, so there'll be 4 segments connecting to this junction let's delete 2 segments out of the 4 first, then if we want to delete the 3rd segment, the 4th segment will be a "isolated" one, so we will pick this kind of segment out
|
|
GetLines2D ( ) : void |
get the 2D data of the curtain grid the original data is in CurtainGridLine/XYZ/Curve format of Revit, change it to Point/GridLine2D format
|
|
GridDrawing ( MyDocument myDoc, |
constructor
|
|
SelectLine ( System mousePosition, bool verifyLock, bool verifyRemove ) : void |
pick up a grid line by mouse
|
|
SelectSegment ( System mousePosition ) : void |
pick up a segment
|
|
SelectULine ( System mousePosition, bool verifyLock, bool verifyRemove ) : void |
pick up a U grid line by mouse
|
|
SelectUSegment ( System mousePosition ) : void |
pick up a segment of a U grid line
|
|
SelectVLine ( System mousePosition, bool verifyLock, bool verifyRemove ) : void |
pick up a V grid line by mouse
|
|
SelectVSegment ( System mousePosition ) : void |
pick up a segment of a V grid line
|
Method | Description | |
---|---|---|
ConvertCurveToSegment ( CurveArray curveArray ) : List |
convert the segment lines in Curve format to SegmentLine2D format
|
|
ConvertToLine2D ( CurtainGridLine line, List |
convert the grid line in CurtainGridLine format to GridLine2D format in the Canvas area, the "System.Drawing.Point" instances are directly used, it's hard for us to use CurtainGridLine and Autodesk.Revit.DB.XYZ directly, so convert them to 2D data first
|
|
DrawAssistLine ( |
draw the assistant lines used to highlight some special lines for example: in add Horizontal/Vertical grid line operations, the to-be-added lines will be shown in bold with red color, this assistant line is drawn in this method
|
|
DrawBoundLines ( |
draw the boundary lines of the curtain grid
|
|
DrawULines ( |
draw the U grid lines
|
|
DrawVLines ( |
draw the V grid lines
|
|
GetBoundLines2D ( ) : void |
get the boundary lines of the curtain grid
|
|
GetConjointSegment ( System point, bool isUSegment, |
get all the segments which is connected to the end point of the segment and is in the same line as the segment for example: 2 grid line has one junction, so there'll be 4 segments connecting to this junction 2 U segments and 2 V segments, delete the 2 U segments first, then delete one of the V segment, the other V segment will be marked as the "ConjointSegment" and will be deleted automatically. this method is used to pick the "the other V segment" out
|
|
GetOutlineIndex ( List |
get which grid line (in GraphicsPath format) contains the specified point, if the grid line contains the point, return the index of the grid line
|
|
GetOutlineIndexes ( List |
get which segment contains the specified point, if the segment contains the point, return the index of the segment in the grid line
|
|
GetSegments ( |
get all the segments of the specified grid line
|
|
GetULines2D ( ) : void |
get the U ("Horizontal") grid lines and their segments in GridLine2D format
|
|
GetVLines2D ( ) : void |
get the V ("Vertical") grid lines and their segments in GridLine2D format
|
|
IsOverlapped ( System point, List |
check whether the point is in the outline of the paths
|
|
IsPointIsolate ( System point ) : bool |
check whether the segments which have the same junction with the specified junction will be isolated if we delete the specified segment for example: 2 grid line has one junction, so there'll be 4 segments connecting to this junction let's delete 2 segments out of the 4 first, then if we want to delete the 3rd segment, the 4th segment will be a "isolated" one, so we will pick this kind of segment out
|
|
IsPointsEqual ( System pa, System pb ) : bool |
judge whether the 2 points are equal (have the same coordinate) (as the X & Y of the Point class are both int values, so needn't use AlmostEqual)
|
|
IsSegLineContained ( List |
identify whether the segment is contained in the segments of a grid line
|
|
UpdateIsolate ( ) : void | ||
VerifyMouseLocation ( System mousePosition ) : bool |
if mouse insiede the curtain grid area, returns true; otherwise false
|
public AddDashLine ( System mousePosition ) : void | ||
mousePosition | System | /// the location of the mouse cursor /// |
return | void |
public AddDashULine ( System mousePosition ) : bool | ||
mousePosition | System | /// the location of the mouse cursor /// |
return | bool |
public AddDashVLine ( System mousePosition ) : bool | ||
mousePosition | System | /// the location of the mouse cursor /// |
return | bool |
public DrawCurtainGrid ( |
||
graphics | /// form graphic /// | |
return | void |
public GetConjointSegments ( |
||
segLine | /// the specified segment used to checking /// | |
removeSegments | List |
/// the result seg list (all the segments in this list is to-be-deleted) /// |
return | void |
public GridDrawing ( MyDocument myDoc, |
||
myDoc | MyDocument | |
geometry | /// the referred parent geometry of the curtain grid /// | |
return | System |
public SelectLine ( System mousePosition, bool verifyLock, bool verifyRemove ) : void | ||
mousePosition | System | /// the location of the mouse cursor /// |
verifyLock | bool | /// will locked grid lines be picked (if verifyLock is true, won't pick up locked ones) /// |
verifyRemove | bool | /// whether grid line without skipped segments be picked (if verifyRemove is true, won't pick up the grid line without skipped segments) /// |
return | void |
public SelectSegment ( System mousePosition ) : void | ||
mousePosition | System | /// the location of the mouse cursor /// |
return | void |
public SelectULine ( System mousePosition, bool verifyLock, bool verifyRemove ) : void | ||
mousePosition | System | /// the location of the mouse cursor /// |
verifyLock | bool | /// will locked grid lines be picked (if verifyLock is true, won't pick up locked ones) /// |
verifyRemove | bool | /// whether grid line without skipped segments be picked (if verifyRemove is true, won't pick up the grid line without skipped segments) /// |
return | void |
public SelectUSegment ( System mousePosition ) : void | ||
mousePosition | System | /// the location of the mouse cursor /// |
return | void |
public SelectVLine ( System mousePosition, bool verifyLock, bool verifyRemove ) : void | ||
mousePosition | System | /// the location of the mouse cursor /// |
verifyLock | bool | /// will locked grid lines be picked (if verifyLock is true, won't pick up locked ones) /// |
verifyRemove | bool | /// whether grid line without skipped segments be picked (if verifyRemove is true, won't pick up the grid line without skipped segments) /// |
return | void |
public SelectVSegment ( System mousePosition ) : void | ||
mousePosition | System | /// the location of the mouse cursor /// |
return | void |