Use the API to Customize and Extend Inspire#

The Inspire Python API is a Pythonic wrap of the next-generation Inspire GUI framework and select HyperWorks clients that have chosen to expose their interface through Python.

Inspire internals are exposed as an easy-to-use Python API layer, with classes to create user interface components like widgets, dialogs, and menus, as well as classes to exercise Inspire core functionalities including objects, boundary conditions, geometry, and graphics.

Put the powerful API to work in an infinite number of ways.#

Take advantage of the API to execute Python scripts in pure batch mode without UI or graphics, to run macros from the Python command window or script editor, or to kick off a Python script on start up. Use the API to create an entirely new major functionality ribbon, or use it to add new icons to an existing ribbon, whether to add on to Inspire functionality or to launch another product.

Find everything you need for extension development packaged with the installation.#

  • ActiveState Python distribution is included.

  • The most commonly used Python modules are contained in the distribution.

  • An IPython command window is integrated with Inspire.

  • IPython command window allows execution of the commands interactively.

  • Batch mode option allows execution of the script silently.

  • Batch mode can be used by executing below command in command prompt.

    <installation directory>/hwx/bin/win64/ExecWinEnvInsp.exe -b -p Inspire -ex hwx.exe -f <absolute path to a script>
    

    To perform SimSolid analysis, execute the following command.

    <installation directory>/hwx/bin/win64/ExecWinEnvInsp.exe -b -p Inspire -ex hwx.exe -runMode SimSolid -f <absolute path to a script>
    
    Command Line Arguments
    These options may be passed to ExecWinEnvInsp as command line arguments to change startup behaviour.

    Argument

    Action

    -cfg

    Returns the control on execution completion.


Explore numerous documented running examples to get a head start.#

Inspire provides demos of available components with the source code to implement them, allowing you to modify the code and run it to see the results in real time, or you can open it directly in the debugger.

Learn about the interactive dialog where you can tour the components in Quickstart Demos.


Easily manage extensions in the Extension Manager.#

Extend the application through shared libraries or scripts to create new clients, profiles, contexts, and model views.

See Extension Manager for information on creating extensions and managing them.