Grouped Objects Cursors

Is there a way of applying a cursor to a grouped object?

I have a motor graphic in a component pallete that I am wanting to apply a cursor to. It consists of a bunch of lines and one rectangle combined into one group. I can apply the cursor to the rectangle but it does not appear when hovering over it (I believe the group setting is overriding this)

The group properties do not seem to support different cursors (I can’t see any option for this). I get the following error message when trying to set it manually and run the folowing code in a mouse enter event assigned to the group.

Traceback (most recent call last): File "<event:mouseEntered>", line 7, in <module> AttributeError: 'NoneType' object has no attribute 'setCursor'

#Available Cursors are as follows #DEFAULT_CURSOR #HAND_CURSOR import java.awt component = event.source.parent.getComponent("componentName") defaultCursor = java.awt.Cursor.getPredefinedCursor(java.awt.Cursor.HAND_CURSOR) component.setCursor(defaultCursor)

Thoughts? Possible feature request?

I was able to use your script without errors…can you attach the component in question?


I’m trying to apply the script to the group. Not the components inside the group.
ONESCADA_testwindow_2012-07-09_1439.proj (6.56 KB)

You have to convert the group to a container to do this. So right click on the group and select “Convert to Container”

Thanks for the help

Just a quick question. What is the difference between groups and containers? Where do each of them fit in the Ignition grand scheme of things? Will they be combined in some update in the future?

Here is the difference:

Look at this page in the user manual: