[fxruby-users] OpenGL selection

Jeroen van der Zijp jeroen at fox-toolkit.org
Wed Dec 14 20:57:45 EST 2005

On Wednesday 14 December 2005 01:32, Björn Bergqvist wrote:
> Hi,
> Thank you for the answer.
> Still I think there should be some highlight feature.
> FXGLShape::onDNDDrop exist, why not a FXGLShape::onMouseClicked??

Except for FXGLObject and FXGLGroup, the other classes are just examples;
they are not intented to be useful in a real application.

In a real application, you'd catch the SEL_SELECTED and SEL_DESELECTED
messages from the FXGLViewer and use them to alter the appearance of
the objects in some way.   How you do this depends on the application.

For example, you can draw a bounding box around the selected object to
indicate that it's selected, or draw "drag-handles" at selected points.

In other applications you may highlight an item in a treelist corresponding
to the object hierarchy.

No state information is present in FXGLObject itself, so there's little
overhead [beyong the usual vtable pointer that is], in case your application
manages massive amounts of point-objects, for example.

		- Jeroen

| Copyright (C) 19:50 12/14/2005 Jeroen van der Zijp.   All Rights Reserved. |

More information about the fxruby-users mailing list