ok, thanks for the explanations.
For anyone watching this, I am using this class to hold info for each object:
//classes to hold entities
public class EntityItem
{
public IntegerCollection ViewportNumbers = new IntegerCollection();
public Entity Entity;
public ObjectId ObjId;
public int SplineSegs = 0; //needed for drawing smooth plines
public bool Highlight;
private EntityItem() { }
public EntityItem(Entity entity, bool highlight)
{
ViewportNumbers.Add(System.Convert.ToInt32(AcAp.GetSystemVariable("CVPORT")));
Entity = entity;
Highlight = highlight;
}
}
you might laugh at the splinesegs prop, but I don't know how to draw a smoothed pline any other way than setting it, then making the pline.
I'd love to find some way of doing it that was specific to an object, not the state of acad when drawn.
The highlight prop is for transient usage, as the entity does not have such a prop.
Keep in mind the class is intended to hold items that will be shown, and to record what was shown for later use, particularly updating transients or grouping items drawn.
anyway, with the class above, I can hold an entity reference for transient entity usage, or an objectid for items added to the db.
I also have a collection class for EntityItems, which has methods for drawing, ghosting, updating and clearing things out.