Fusion API Python tooltip message with picture

Fusion API Python tooltip message with picture

daniel.schaefer9P5YP
Contributor Contributor
474 Views
2 Replies
Message 1 of 3

Fusion API Python tooltip message with picture

daniel.schaefer9P5YP
Contributor
Contributor

 

Hello,

 

I could not find help in the Python API Documentation. I would like to know if there is a possibility to create a tooltip message with text and pictures (like shown in the picture).

danielschaefer9P5YP_0-1733150815834.png

 

0 Likes
Accepted solutions (1)
475 Views
2 Replies
Replies (2)
Message 2 of 3

Jorge_Jaramillo
Collaborator
Collaborator

Hi,

 

Every commandInput object type has the properties tooltip and tooltipDescription for it.

Here is their descriptions from the API documentation:

Jorge_Jaramillo_0-1733152100412.png

You can set them once the commandInput is created.

 

I hope this can help.

 

Regards,

Jorge Jaramillo

 

Message 3 of 3

daniel.schaefer9P5YP
Contributor
Contributor
Accepted solution

Thanks, it works.

danielschaefer9P5YP_0-1733215441641.png

 

 # Create value input.
         
            valueInput = tab1ChildInputs.addValueInput('value', 'test', 'cm', adsk.core.ValueInput.createByReal(0.0))
            valueInput.tooltip = 'Dies ist der Haupt-Tooltip für das Textfeld.'
            valueInput.tooltipDescription = (
                '<br>Zusätzliche Details zum Textfeld:</br>'
                'Geben Sie hier benutzerdefinierte Werte ein.'
                '<li>Unterstützt Standard- und Sonderzeichen.</li>'
                '<img src="C:\\Temp\\image.png" alt="Beschreibung des Bildes">'
            )
 
Thanks!