visualize#

Item.visualize(new_tab: bool | None = False) None#

Render this item only.

Parameters:
new_tabbool, optional

Whether to render the item in a new tab if the current environment is a Jupyter notebook. The default is False, in which case the item is rendered in the current location. If the environment is not a Jupyter notebook, the item is always rendered in a new tab.

Returns:
Item

Rendered item.

Examples

Create a text item and render it in a new tab:

import ansys.dynamicreporting.core as adr
adr_service = adr.Service(ansys_installation = r'C:\Program Files\ANSYS Inc\v232')
ret = adr_service.connect(url='http://localhost:8010')
my_txt = adr_service.create_item()
my_txt.item_text = '<h1>The test</h1>This is a text item'
my_txt.visualize(new_tab = True)