This class describes a node in a TreeView. This node is identified by an ID string. It can contain a text and an icon.

Some attributes can be set for the node:

  1. foreground color
  2. background color
  3. border
  4. font
  5. tool tip

In addition, each TreeNode can have children nodes.


The constructor gets the ID, the text and the icon of the TreeNode.

CEventTreeNode(@NotNull final String aId,
               @NotNull final String aDisplayedText,
               @Nullable final CEventIcon aIcon);


The method returns the ID of the TreeNode. The ID is always a valid string and is set in the constructor.

String getId();


Here the displayed text is returned. It is set in the constructor and can be empty.

String getDisplayedText();


The optional icon is set in the constructor.

CEventIcon getIcon();


The optional background of the TreeNode can be set explicitly.

CEventColor getBackground();

void setBackground(final CEventColor aBackground);


The optional foreground of the TreeNode can be set explicitly.

CEventColor getForeground();

void setForeground(final CEventColor aForeground);


Each node in a TreeView can have its own border.

IBorder getBorder()

void setBorder(final IBorder aBorder);


For each node in a TreeView a separate font can be set.

CEventFont getFont();

void setFont(final CEventFont aFont);

nyssr.net - Innovative Distributed System