Generic Logic, Inc.

GLG 2.6 Release New Features and Enhancements

Integrated Zooming and Panning

Includes integrated scrollbars (controlled by the PanEnabled attribute of the viewport) which scroll the drawing and automatically adjust to the drawing extent changes. Also includes integrated support for zooming and panning keystrokes with integrated ZoomTo and Fit Drawing features. The zoom and pan key accelerators are controlled by the ZoomEnabled attribute of the viewport.

The programming API is also provided, so that the program can use custom zoom controls (buttons with custom icons, etc.)  and then call the zoom methods when the zoom or pan buttons are pressed.

Integrated panning and zooming eliminates programming used in the older versions of GLG to implement zoom and pan features, and provides better visual feedback.

Integrated Object Tooltips

Integrated tooltips feature enables support for adding MouseOver tooltips to individual objects in the drawing.

It's done by adding the TooltipString custom property to the object. If an object (or any of its parents) has this property, the tooltip will be activated when the mouse is moved on top of the object.

The tooltip delay is controlled by the GlgMouseTooltipTimeout configuration resource. A new ProcessMotion attribute of the viewport object controls the tooltips, as well and selection events and mouse highlight described below.

A new GlgButtonTooltipTimeout configuration resource is also added to control delay of the button tooltips, which was not configurable before.

Integrated Highlight on MouseOver (Custom Hot Spots)

The integrated highlight on the mouse over event can be enabled for selected objects to implement a custom "hot spot" functionality. For example, it may be used to change line width or display an outline around the object to highlight it when the mouse moves over the object.

It's done by defining a MouseOverState resource of D-type. The value MouseOverState resource of the object (or its closest parent) will be changed to 1 when the mouse is moved over the object, and changed back to 0 when it moves away. The MouseOverState may control any of the object attributes to achieve any custom highlighting effects.

Integrated MouseClick Feedback and Toggle

The integrated MouseClick highlight and toggle may be used to implement button press feedback (for example, flatten the object when it's clicked on with the mouse or toggle the object position).  Both features may be used to implement light viewport-less buttons and toggles with various feedbacks and visual effects.

The integrated highlight is added to an object by defining a D-type resource named MouseClickState. This resource can control any of the object properties, changing them when the object is clicked on with the mouse.  The resource's value will be set to 1 when the object is clicked with the left mouse button, and reset back to 0 when the button is released. The resource can control a visual feedback of any type (attribute change, object movement, etc.).

If a MouseClickToggle resource (D-type) is defined for an object, its value will be toggled between 0 and 1 every time the object is selected with the left mouse button.

Each of the MouseClickState and MouseClickToggle resources can be defined on the object level or at the level of any of the object's parents.

Integrated MouseClick Highlight and Toggle features can be used to implement light viewport-less buttons and toggles with various visual feedbacks and effects.

New Selection Event

The selection model has been extended to include several new selection events. In addition to the SelectCallback, the InputCallback will also be invoked with the ObjectSelection event, providing Object IDs of all objects potentially selected with the mouse, in addition to object names provided by the SelectCallback. This allows the program to process selection of unnamed objects or objects with duplicate names without a need to use the TraceCallback, as it was required in the past.

The ObjectSelection event may also be generated on the mouse move events, if desired.

Custom MouseOver and MouseClick Events

Custom MouseClick, MouseRelease and MouseOver events can be defined for individual objects, making it easier to handle object selection.

The MouseClickEvent property (S-type) can be added to objects to generate custom MouseClick events when the object is selected with the mouse button (the MouseRelease event will be generated when the mouse is released).

The MouseOverEvent property of S-type can be added to objects to generate custom MouseOver events when the mouse moves on top of the object (MouseOver event with an empty event label will also be generated when the mouse moves away).

These properties can be added at a specific location in the object hierarchy, making sure that, for example, selecting any sub-object of a composite node object will result in the selection event for the node. In the past, it was accomplished by custom application code, which was converting sub-objects selection to the selection of the node containing them.

The value of these event properties specifies a custom event label, so that an application can define custom selection event types (for example, NodeSelection and LinkSelection events) right in the Graphics Builder, without writing any custom code. In the Input Callback, an application can query the type of the custom event and perform different actions depending on the event type. This can significantly reduce the amount of code required to handle elaborate object selection.

New Avionics Widget Set and new Controls

A new Avionics Widget Set has been added, with gauges for building avionics panels. The existing Control Widget Set has been extended by adding windowless versions of the controls. The windowless controls have a round shape suitable for integration with instrument panels which have a custom image background.

JPEG Support

The JPEG format support has also been added to the GLG image object to support TrueColor images. It's available in both C/C++ and Java versions of the Toolkit.

Multiple Input Callbacks

In the 2.6 release, each viewport can have its own Input, Select and Trace callbacks, which makes it easier to encapsulate various parts of the application code. Previously, only Select and Trace callbacks could be used this way, while the Input callback could be added only to the top viewports and not to the children viewports.

Viewport Span Attributes

SpanX and SpanY viewport attributes were introduced to allow changing the [-1000;+1000] default coordinate extent of the viewport. The new SpanX and SpanY attributes allow better control over the coordinate span for custom handling of viewports with non-square drawing areas.

Light Object and Light-Weight Viewports

The viewport's light attributes were split into a separate Light object, which could be added to a viewport only when necessary, decreasing the space consumed by the viewport objects.

Arbitrary Path Support for the Series

The Series object now allows using arbitrary transformations to define its path. For example, a Path and Rotate transformations can be used, while only linear transformation was allowed in the past.

Graphics Builder User Interface Improvements

Include the following new features:
  • automatic inversion of the control points and dragging color when editing dark drawings
  • improved cloning type selection interface for various operations
  • keeping the drawing order when exploding objects in the Builder
  • keeping the zoom state when traversing down into a group
  • added the ">>" sign to the aliases in the resource browser
  • viewport font and color table editing interface change
  • and other features.

    Glg Bean Interface Changes

    The Glg Bean for Java has additional properties and methods for smoother Java integration. The Input, Selection and Ready callbacks can now be added as Java listeners. The new H and V callbacks and listeners were added to allow setting the initial resources of the drawing before it is displayed the first time. The H callback is invoked before the object hierarchy is setup, and V callback is invoked after hierarchy setup.

    The new DrawingName property and SetParentApplet method have been added for transparent loading of drawings from either URL or a file, as well as for better bean encapsulation when it's used as a component inside another applet.

    New coding examples illustrating various scenarios of the Glg Bean usage (as an applet, bean, etc.) have been added to the release.

    The Ext suffix for the Bean's Extended API method names has been eliminated for better compatibility with the C/C++ version of the Toolkit. The old methods with the Ext suffix are still supported for backward compatibility.

    DXF Converter Updates

    The DXF converter has been updated to handle new primitives and the latest versions of the AutoCAD.

    Miscellaneous Bug Fixes

    Miscellaneous bug fixes and user interface improvements have been implemented in the new release. All bugs reported prior to the release date have been fixed and closed.