Brief Index      Full Index      I.M. Reference

Delete_By_Key


Functions

void Delete_By_Key (HC_KEY key)

Function Documentation

void Delete_By_Key ( HC_KEY  key  ) 

Throws away a segment identified by key rather than by name, or throws away a particular geometry item.

Parameters:
key - Key returned by a previous call to one of the "K" routines.

DETAILS

If the given key refers to a segment---if it was returned from KOpen_Segment() or KCreate_Segment() ---then, as with Delete_Segment() , that segment and all its subsegments are deleted from the segment tree. This is useful when the segment was originally created without a name (i.e., it was a "no-name" segment), or when it's easier to keep track of the segment by key rather than name.

If the given key refers to a geometric primitive, such as a line or a polygon, that single primitive is deleted from the database and (at the next Update) from the screen. For comparison, Flush_Contents() deletes all the primitives from the specified segment. Delete_Segment() deletes the primitives and the segment structure itself.

Finally, if the given key was returned from KInclude_Segment() or KStyle_Segment() , that segment cross-reference is removed from the database---the "include" or "style" is no longer performed. The segments themselves remain unaffected.

NOTE

If the item is currently open ( Open_Segment() or Open_Geometry() ) an error will be reported and the deletion will fail.

NOTES

RESTRICTIONS

See also:
Flush_Contents, Delete_Segment, Open_Segment, Open_Geometry, Create_Segment, Include_Segment, Style_Segment.

Main Index
Brief Index      Full Index      I.M. Functions