Module to define a Data table. More...

Modules

 Field to indicate the options for creating table for 3D views.
 These fields are used with function A3DPDFDataTable3DViewsCreate to define its behavior.
 

Data Structures

struct  A3DPDFDataTableData
 Structure to define a DataTable. More...
 
struct  A3DPDFTable3DViewsData
 Structure to define a DataTable for 3D Views. More...
 

Functions

A3DStatus A3DPDFDataTable3DViewsCreate (A3DPDFDocument *pDoc, A3DPDF3DArtwork *p3DArtwork, A3DAsmModelFile *pModelFile, const int iModeFlags, const A3DPDFTable3DViewsData *pTable3DViewsData, A3DPDFDataTable3DViews **ppDataTable)
 Function to create a table for 3D views. More...
 
A3DStatus A3DPDFDataTableCreate (A3DPDFDocument *pDoc, const A3DPDFDataTableData *pDataTableData, A3DPDFDataTable **ppDataTable)
 Function to create a DataTable. More...
 
A3DStatus A3DPDFDataTableSetInitIndex (A3DPDFDataTable *pDataTable, A3DInt32 iInitIndex)
 Function to set the property iInitIndex on DataTable object. More...
 
A3DStatus A3DPDFObjectDataTableCreate (A3DPDFDocument *pDoc, const A3DPDFDataTableData *pDataTableData, A3DPDFObjectDataTable **ppDataTable)
 Function to create a Object DataTable. More...
 

Detailed Description

Module to define a Data table.

Version
10.0

Function Documentation

◆ A3DPDFDataTableCreate()

A3DStatus A3DPDFDataTableCreate ( A3DPDFDocument pDoc,
const A3DPDFDataTableData pDataTableData,
A3DPDFDataTable **  ppDataTable 
)

Function to create a DataTable.

Parameters
[in]pDocThe Document object to work with.
[in]pDataTableDataThe DataTable parameters.
[out]ppDataTableThe DataTable object created.
Returns
A3D_SUCCESS in case of success or an error code
Return values
A3D_SUCCESS
Version
10.0

◆ A3DPDFDataTable3DViewsCreate()

A3DStatus A3DPDFDataTable3DViewsCreate ( A3DPDFDocument pDoc,
A3DPDF3DArtwork p3DArtwork,
A3DAsmModelFile pModelFile,
const int  iModeFlags,
const A3DPDFTable3DViewsData pTable3DViewsData,
A3DPDFDataTable3DViews **  ppDataTable 
)

Function to create a table for 3D views.

The table generated is derived from the list obtained with A3DPDF3DArtworkGetViews: it has the same size, and each row has the following columns:

  • column 0 is for the index in 3D annot internal views (internally assigned).
  • column 1 is the internal name of the view (internally assigned).
  • column 2 is the label of the view to be displayed in carousel buttons (assigned using A3DPDFTable3DViewsData.m_ppcViewLabels parameter).
  • column 3 is the icon name for the view (internally assigned from icons generation for carousel and A3DPDFTable3DViewsData.m_ppImages parameter)
  • additional columns are defined in pTable3DViewsData in m_pDataTableData member.

Important: If iModeFlags is set to kA3DPDFTableFor3DViewsComputePosters, the following applies: HOOPS Publish uses the graphics driver of the user's PC. By default, HOOPS Publish attempts to select the graphics driver in this order: DX11->DX9->OpenGL2->OpenGL. To override the default driver selection, set the A3DPOSTERDRV environment variable to one of the following values:

  • DX11
  • DX9
  • OGL2
  • OGL1
Parameters
[in]pDocThe Document object to work with.
[in]p3DArtworkArtwork object, used to get view definitions to compute posters.
[in]pModelFileUsed to compute posters - must be the modelfile as stored into p3DArtwork.
[in]iModeFlagsindicate how views are specified. see Field to indicate the options for creating table for 3D views.. For information about graphics driver selection for poster generation, please the details section above.
[in]pTable3DViewsDataThis allows specification of custom data in addition to internal data. Only used if kA3DPDFTableFor3DViewsCustom is specified in iModeFlags.
[out]ppDataTableThe DataTable3DViews object created.
Returns
A3D_SUCCESS in case of success or an error code
Return values
A3D_SUCCESS
A3DPDF_INVALID_VIEW_INDEXif an index specified in pTable3DViewsData.m_piViewIndexes is out of view array defined in p3DArtwork
Version
10.0

◆ A3DPDFObjectDataTableCreate()

A3DStatus A3DPDFObjectDataTableCreate ( A3DPDFDocument pDoc,
const A3DPDFDataTableData pDataTableData,
A3DPDFObjectDataTable **  ppDataTable 
)

Function to create a Object DataTable.

An Ojbect DataTable is a specific data table that contain objects instead of just text. An Object define a set of properties and related values ; it is formatted as follows : { property1: valueproperty1, property2: valueproperty2, ... }
Supported properties are:

  • caption : the text of the field
  • icon : the icon id to store on the field when the field is defined as image holder (button)
  • actionurl : an url to be launched when the user clicks on the cell
  • actionjs : a javascript code to be launched when the user clicks on the cell
  • actionjscallback : the name of a javascript function stored on the document. This callback function is called when the user clicks on the cell, with the arguments : tablerowindex, tablecolindex, userdata (see actionjscallbackdata)
  • actionjscallbackdata : the third argument provided to the callback function actionjscallback

Properties actionurl, actionjs, or actionjscallback can be used to define an action on a table cell. If an action is defined on a cell: when the user clicks on the cell, the row selected is unhighlighted and the action is launched. If no action is defined on the cell: when the user clicks on the cell, the row selected is highlighted and the datamodel action linked to the row is launched (typically invoking other widgets on the page bound on linked tables).

Parameters
[in]pDocThe Document object to work with.
[in]pDataTableDataThe DataTable parameters.
[out]ppDataTableThe DataTable object created.
Returns
A3D_SUCCESS in case of success or an error code
Return values
A3D_SUCCESS
Version
11.2

◆ A3DPDFDataTableSetInitIndex()

A3DStatus A3DPDFDataTableSetInitIndex ( A3DPDFDataTable pDataTable,
A3DInt32  iInitIndex 
)

Function to set the property iInitIndex on DataTable object.

By default, a -1 value is defined. If it is defined here, the table row at index iInitIndex is 'selected' at init time (when the document is opened), or when the table is reset. A table is typically reset when a bound widget is unselected. A widget bound to this table have to be defined with a NULL source and kA3DPDFDataSelect behaviour to be automatically selected at init time (see A3DPDFWidgetSetTargetBehaviour).

Parameters
[in]pDataTableThe DataTable object.
[in]iInitIndexThe index to set.
Returns
A3D_SUCCESS in case of success or an error code
Return values
A3D_SUCCESS
Version
10.0