|
GLG Toolkit, C / C++ API Library
Version 4.5
|
Modules | |
| GTK Events | |
Structures and Classes | |
| struct | GlgCallEvent |
| A structure used to pass data to a custom Interaction Handler. More... | |
| struct | GlgChartFilterData |
| Contains data passed to the chart filter callback. More... | |
| struct | GlgCube |
| Defines a rectangular parallelepiped in 3D space (usually an object's bounding box) by its two diagonal points. More... | |
| struct | GlgDataSample |
| Chart data sample structure, holds data for one point of a chart. More... | |
| struct | GlgDataSampleExt |
| Extended chart data sample structure, holds data for one point of a chart. More... | |
| struct | GlgFindObjectsData |
| A structure used to pass information to the GlgFindObjects function, and to return the search results. More... | |
| struct | GlgHierarchyCBStruct |
| A structure used to pass data to the Hierarchy callback. More... | |
| struct | GlgMatrixData |
| Contains matrix data used by GlgGetMatrixData and GlgSetMatrixData. More... | |
| struct | GlgMinMax |
| Contains data extent information returned by the GlgGetChartDataExtent function. More... | |
| struct | GlgPoint |
| Defines an XYZ point in 3D space or an RGB color. More... | |
| struct | GlgPoint2 |
| 2D point with x and y coordinates. More... | |
| struct | GlgRectangle |
| 2D rectangle defined by two diagonal points. More... | |
| struct | GlgTraceCBStruct |
| A structure used to pass information to the Trace callback. More... | |
| struct | GlgTraceCBStruct_GTK |
| A structure used to pass information to the Trace callback in GTK. More... | |
| struct | GlgTraceCBStruct_Windows |
| A structure used to pass information to the Trace callback on Windows. More... | |
| struct | GlgTraceCBStruct_X11 |
| A structure used to pass information to the Trace callback in X11. More... | |
| struct GlgCallEvent |
A structure used to pass data to a custom Interaction Handler.
| Class Members | ||
|---|---|---|
| GlgLong | data1 | For message actions (type=GLG_MESSAGE_ACTION) triggered by GlgSendMessage, contain the value of the param1 parameter of the GlgSendMessage call. |
| GlgLong | data2 | For message actions (type=GLG_MESSAGE_ACTION) triggered by GlgSendMessage, contain the value of the param2 parameter of the GlgSendMessage call. |
| GlgLong | data3 | For message actions (type=GLG_MESSAGE_ACTION) triggered by GlgSendMessage, contain the value of the param3 parameter of the GlgSendMessage call. |
| GlgLong | data4 | For message actions (type=GLG_MESSAGE_ACTION) triggered by GlgSendMessage, contain the value of the param4 parameter of the GlgSendMessage call. |
| GlgObject | event_viewport | The event's viewport for native events (type=GLG_NATIVE_EVENT). |
| GlgObject | event_vl | The event's light viewport, if any, or the viewport otherwise. |
| GlgLong | flag |
Provides additional details of the GLG_HI_SETUP_EVENT and GLG_DI_SETUP_EVENT events.
|
| GlgObject | message |
Message object for message events (type=GLG_MESSAGE_EVENT). This message object may be sent by the children input objects inside the handler's viewport. It has the same content as the message object used by the Input callback. |
| char * | message_name | For message actions (type=GLG_MESSAGE_ACTION) triggered by GlgSendMessage, contains value of the message parameter of the GlgSendMessage call. |
| GlgObject | object | The handler's viewport. |
| GlgLong | rval | For message actions (type=GLG_MESSAGE_ACTION) triggered by GlgSendMessage, the handler has to set this output parameter to the value that will be passed to the invoking GlgSendMessage to be used as its return value. |
| GlgCallEventType | type | Call event type, see GlgCallEventType. |
| GlgLong | used | For message actions (type=GLG_MESSAGE_ACTION) triggered by GlgSendMessage, the handler must set this flag to a non-zero value if it handles the message, otherwise an error message is generated and False is returned by the invoking GlgSendMessage. |
| struct GlgChartFilterData |
Contains data passed to the chart filter callback.
| Class Members | ||
|---|---|---|
| double | accum_x | Accumulated x value. |
| double | accum_y | Accumulated y value. |
| double | accum_y_low | Accumulated y_low value for a floating bar chart. |
| GlgChartFilter | custom_filter | The custom filter (read-only). |
| void * | custom_filter_data | Filter's data passed via the data parameter of the GlgSetChartFilter function. |
| GlgDataSample * | data_sample | The data sample to be added (for GLG_FILTER_CB_ADD_SAMPLE only). |
| GlgDataSample * | data_sample1 | Output data sample for the first point. |
| GlgDataSample * | data_sample2 | Output data sample for the second point. |
| GlgDataSample * | data_sample_max | Stored max data sample. |
| GlgDataSample * | data_sample_min | Stored min data sample. |
| unsigned | disable_attributes: 1 | If True, disables the use of colors and other graphical attributes for filters where it does not make sense (such as AVERAGE or MIN_MAX). |
| unsigned | draw_markers: 1 | True if plot has markers (read-only). |
| double | filter_interval | Filter interval (read-only) |
| GlgChartFilterType | filter_type | Filter type (read-only) |
| double | last_added_x | Last added x (read-only) |
| double | last_drawn_x | Last drawn x (read-only) |
| float | marker_vis1 | Output marker visibility for the first point. |
| float | marker_vis2 | Output marker visibility for the second point. |
| float | marker_vis_acc | Stored visibility of the marker with the highest visibility. |
| float | marker_vis_max | Stored visibility of the marker with the highest Y value. |
| float | marker_vis_min | Stored visibility of the marker with the lowest Y value. |
| double | max_x | Stored value for MIN_MAX filter. |
| double | max_y | Stored value for MIN_MAX filter. |
| double | min_x | Stored value for MIN_MAX filter. |
| double | min_y | Stored value for MIN_MAX filter. |
| GlgLong | num_accum | Number of accumulated points. |
| GlgObject | plot | Plot object the filter is attached to. |
| GlgLong | total_points | Total number of points, valid and non-valid (read-only) |
| double | x1 | Output filter value for the first point. |
| double | x2 | Output filter value for the second point. |
| double | y1 | Output filter value for the first point. |
| double | y1_low | Output filter value for the first point. |
| unsigned | y1_low_set: 1 | True if y1_low value is usable. |
| double | y2 | Output filter value for the second point. |
| struct GlgCube |
Defines a rectangular parallelepiped in 3D space (usually an object's bounding box) by its two diagonal points.
The faces of the parallelepiped are parallel to the coordinate planes.
| Class Members | ||
|---|---|---|
| GlgPoint | p1 | Point with the lowest coordinate values. |
| GlgPoint | p2 | Point with the highest coordinate values. |
| struct GlgDataSample |
Chart data sample structure, holds data for one point of a chart.
| Class Members | ||
|---|---|---|
| unsigned | extended_data: 1 | Must be set to False to indicate that no extended data are supplied and the data sample is an instance of GlgDataSample. |
| unsigned | filter_mark: 1 | Marks the last sample to include, with a forced flush after it. |
| float | marker_vis | Marker visibility (for plot types with markers). |
| double | time | Time stamp or X value. |
| unsigned | valid: 1 | Sample valid flag. |
| double | value | Y value. |
| struct GlgDataSampleExt |
Extended chart data sample structure, holds data for one point of a chart.
The extended data sample contains additinal BAR and MARKER properties.
| Class Members | ||
|---|---|---|
| unsigned char | drawn_size | BAR width or MARKER size. |
| unsigned char | drawn_type | BAR fill type or MARKER type. |
| unsigned int | edge_color | Edge color of a BAR or MARKER. |
| unsigned | extended_data: 1 | Must be set to True to indicate that extended data are supplied and the data sample is an instance of GlgDataSampleExt. |
| unsigned int | fill_color | Fill color of a BAR or MARKER. |
| unsigned | filter_mark: 1 | Marks the last sample to include, with a forced flush after it. |
| unsigned char | line_width | BAR line width. |
| float | marker_vis | Marker visibility (for plot types with markers). |
| GlgExtDataType | saved_type | Specifies type of information stored in the extended data sample. |
| double | time | Time stamp or X value. |
| unsigned | valid: 1 | Sample valid flag. |
| double | value | Y value. |
| double | y_low | BAR YLow value. |
| struct GlgFindObjectsData |
A structure used to pass information to the GlgFindObjects function, and to return the search results.
For forward compatibility with future releases, the structure has to be cleared by writing zeros before assigning values to its fields. This can be done using the GlgInitStruct macro:
Public Attributes | |
| void * | custom_data |
| Custom data that will be passed to the custom_match function. More... | |
| GlgBoolean(* | custom_match )(GlgObject object, void *custom_data) |
| Specifies a function that is invoked for each searched object to provide custom matching logic for match_type=GLG_CUSTOM_MATCH. More... | |
| GlgBoolean | dont_add_matches |
| If False, GlgFindObjects returns matching objects in the found_object field. More... | |
| GlgBoolean | find_first_match |
| If True, the search is stopped after the first match and the first matching object is returned. More... | |
| GlgBoolean | find_parents |
| Controls search direction. More... | |
| GlgBoolean | found_multiple |
| Indicates the type of the returned result. More... | |
| GlgObject | found_object |
| Will be set to the contain the search result, which may be NULL if no matching objects were found or if match_type=GLG_CUSTOM_MATCH and dont_add_matches=True. More... | |
| GlgBoolean | include_top_object |
| If True, the top object passed as the object parameter of GlgFindObjects will be included in the search results if it matches the search criteria. More... | |
| GlgObjectMatchType | match_type |
| Specifies a bitwise mask of the object matching criteria: More... | |
| GlgObject | object_id |
| An object to be matched for match_type=GLG_OBJECT_ID_MATCH. More... | |
| char * | object_name |
| Object name for match_type=GLG_OBJECT_NAME_MATCH. More... | |
| GlgObjectType | object_type |
| Object type for match_type=GLG_OBJECT_TYPE_MATCH. More... | |
| char * | resource_name |
| Resource name for match_type=GLG_RESOURCE_MATCH. More... | |
| GlgBoolean | search_drawable_only |
| If True when searching descendants (find_parents=False), only drawable objects are searched. More... | |
| GlgBoolean | search_inside |
| If False, an object's children or parents are not searched if the object itself matches. More... | |
| GlgBoolean | search_templates |
| If False when searching descendants, (find_parents=False) the templates of series, subdrawings and subwindows will be excluded from the search, and only the rendered instances inside these objects will be included. More... | |
| void* custom_data |
Custom data that will be passed to the custom_match function.
If a pointer to a structure is passed, the structure's fields may be used to pass data to the custom_match function, as well as to store data to track the state of the search process.
| GlgBoolean(* custom_match) (GlgObject object, void *custom_data) |
Specifies a function that is invoked for each searched object to provide custom matching logic for match_type=GLG_CUSTOM_MATCH.
The function can perform custom matching for the object supplied by its object parameter and should return True to indicate a match. The function will also receive custom_data as the function's custom_data parameter.
| GlgBoolean dont_add_matches |
If False, GlgFindObjects returns matching objects in the found_object field.
If multiple objects are found, the found_object field will contain a GLG group that is created to hold matching objects. This group is owned by the caller and has to be dereferenced with GlgDropObject when finished.
If the custom_match function processes objects in-place, the returned group containing matching object is not used. In this case, dont_add_matches may be set to True to prevent storing matching objects at all. The DEMOS/SCADAViewer/HMIPage.c file in the GLG installation directory provides an example of using this setting when processing objects in-place.
This setting can be used only with match_type=GLG_CUSTOM_MATCH. If dont_add_matches is set to True, the returned found_object field will always be NULL.
| GlgBoolean find_first_match |
If True, the search is stopped after the first match and the first matching object is returned.
If False, all matching objects are returned.
| GlgBoolean find_parents |
Controls search direction.
If True, the object's ancestors (parents, grandparents and so on) searched.
If False, the object's descendants (children, grandchildren and so on) are searched.
| GlgBoolean found_multiple |
Indicates the type of the returned result.
Will be set to True if the search result stored in found_object contains a group of multiple matching objects.
Will be set to False if the search result stored in found_object is a single matching object.
| GlgObject found_object |
Will be set to the contain the search result, which may be NULL if no matching objects were found or if match_type=GLG_CUSTOM_MATCH and dont_add_matches=True.
If the result is a single object, found_multiple will be set to false.
If the result is a group of several matching objects, found_multiple will be set to True and the group returned as found_object must be dereferenced with GlgDropObject to avoid memory leaks.
| GlgBoolean include_top_object |
If True, the top object passed as the object parameter of GlgFindObjects will be included in the search results if it matches the search criteria.
If False, the top object will not be included.
| GlgObjectMatchType match_type |
Specifies a bitwise mask of the object matching criteria:
| GlgObject object_id |
An object to be matched for match_type=GLG_OBJECT_ID_MATCH.
Only the object with this object ID will be matched. This type of search can be used to find out if the specified object is either a child or a parent of the object passed as the object parameter of the GlgFindObject function.
| char* object_name |
Object name for match_type=GLG_OBJECT_NAME_MATCH.
Only objects with this name will be matched.
| GlgObjectType object_type |
Object type for match_type=GLG_OBJECT_TYPE_MATCH.
Only objects of this type will be matched.
| char* resource_name |
Resource name for match_type=GLG_RESOURCE_MATCH.
Only objects that have a resource at the resource path specified by resource_name will be matched. The resource pointed to by the resource path must be an object.
| GlgBoolean search_drawable_only |
If True when searching descendants (find_parents=False), only drawable objects are searched.
For example, when this flag is set, a polygon object's attributes such as FillColor and EdgeColor, will not be searched, which can be used to speed up the search. See GlgIsDrawable more information.
If False, all objects will be searched.
| GlgBoolean search_inside |
If False, an object's children or parents are not searched if the object itself matches.
If True, the search proceeds to process an object's children or parents even if the object matches.
| GlgBoolean search_templates |
If False when searching descendants, (find_parents=False) the templates of series, subdrawings and subwindows will be excluded from the search, and only the rendered instances inside these objects will be included.
This is a default setting, since the template objects are not drawn and therefore do not need to be processed.
If True, both the instances and the templates will be searched.
This flag is ignored when the search is performed before hierarchy setup, when the instances have not yet been loaded, and only the templates are available.
| struct GlgHierarchyCBStruct |
A structure used to pass data to the Hierarchy callback.
| Class Members | ||
|---|---|---|
| GlgHierarchyCallbackType | condition |
When the callback was invoked:
|
| GlgObject | object | The subwindow or subdrawing object that loaded its template. |
| GlgCallbackType | reason | Callback type: GLG_HIERARCHY_CB. |
| GlgRefType | reference_type | Reference object subtype: GLG_SUBWINDOW_REF or GLG_SUBDRAWING_REF. |
| GlgObject | subobject | Template instance of the subwindow or subdrawing. |
| struct GlgMatrixData |
Contains matrix data used by GlgGetMatrixData and GlgSetMatrixData.
| Class Members | ||
|---|---|---|
| double | matrix[4][4] | 4x4 array of matrix coefficients. |
| GlgLong | type |
Matrix type. Uses translate, scale and rotate constants from the GlgXformType enum. |
| struct GlgMinMax |
Contains data extent information returned by the GlgGetChartDataExtent function.
| Class Members | ||
|---|---|---|
| double | max | Maximum value of the data extent in one direction (X/Time or Y). |
| double | min | Minimum value of the data extent in one direction (X/Time or Y). |
| struct GlgPoint |
| struct GlgPoint2 |
| struct GlgRectangle |
| struct GlgTraceCBStruct |
A structure used to pass information to the Trace callback.
The Windows, GTK and X11 versions of this structure are listed below as GlgTraceCBStruct_Windows, GlgTraceCBStruct_GTK and GlgTraceCBStruct_X11. The real structure type in these environments is still GlgTraceCBStruct.
| struct GlgTraceCBStruct_GTK |
A structure used to pass information to the Trace callback in GTK.
| Class Members | ||
|---|---|---|
| GXEvent * | event | A simulated event similar to X11 XEvent, that makes it possible to use the same code for both X11 and GTK Trace callbacks. |
| GdkEvent * | event1 | A native GDK event, may be NULL for some GXEvent events. |
| GlgObject | light_viewport | Light viewport of the event or NULL. |
| GlgCallbackType | reason |
The type of the Trace callback:
|
| GlgObject | viewport | Viewport that received the event. |
| GtkWidget * | widget | Widget ID of the event viewport. |
| struct GlgTraceCBStruct_Windows |
A structure used to pass information to the Trace callback on Windows.
| Class Members | ||
|---|---|---|
| MSG * | event | Native event that triggered the callback. |
| void * | event1 | Reserved for internal use. |
| GlgObject | light_viewport | Light viewport of the event or NULL. |
| GlgCallbackType | reason |
The type of the Trace callback:
|
| GlgObject | viewport | Viewport that received the event. |
| HWND | widget | Same as window. |
| HWND | window | Window ID of the event viewport. |
| struct GlgTraceCBStruct_X11 |
A structure used to pass information to the Trace callback in X11.
| Class Members | ||
|---|---|---|
| Display * | display | Display of the event viewport. |
| XEvent * | event | The X11 event that triggered the callback. |
| XEvent * | event1 | Reserved for internal use. |
| GlgObject | light_viewport | Light viewport of the event or NULL. |
| GlgCallbackType | reason |
The type of the Trace callback:
|
| GlgObject | viewport | Viewport that received the event. |
| Widget | widget | Widget ID of the event viewport. |
| Window | window | Window ID of the event viewport. |