Selection not based on bounds

What must be done to include in the selection objects that are just
partially in the selection ‘rubber band’ (when dragging to make a

Or for example in the case of a node with text (iconic node) to include
the node in the selection when the icon (not necessary the text) is in
the selection rectangle.

Thanks for any help.

It is the case that GoView.SelectInRectangle just considers each object’s SelectionObject, so that the user doesn’t have to surround the whole object, but just the part of the object that is the GoObject.SelectionObject. In the case of GoIconicNodes, users only need to surround the Icon in order to select the node–they don’t need to include the Label.
If you want to change the behavior, you can certainly override GoObject.SelectionObject and/or GoView.SelectInRectangle to do whatever you want. If you override the latter, remember to consider several things: whether the object is visible (GoObject.CanView()) and selectable (GoObject.CanSelect()) and whether to recurse into GoGroups (which it does).

Unfortnuately because of this:

Northwoods Software =2
The selection object is the whole object.

What is realy needed is to select objects even if they are partialy in
the selection rectangle so it seems that the solution is to override

Thanks you for your help.

If for some reason you are reluctant to subclass GoView, you can just override GoToolRubberBanding.DoRubberBand to call your own method for selecting objects given a rectangle. Here’s the definition:
public virtual void DoRubberBand(Rectangle box) { // BOX is in view coordinates!
Size dragSize = System.Windows.Forms.SystemInformation.DragSize;
if (box.Width <= dragSize.Width/2 && box.Height <= dragSize.Height/2) {
// whether or not we found and/or selected anything, call DoClick
} else {
RectangleF docRect = this.View.ConvertViewToDoc(box);

I did override SelectInRectangle and it works perfectly (until now )