// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Customize business objects
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

object."NetworkElement" {
  label: @name;
  labelForeground: black;
  iconVisible: true;
  toolTipText: @name;
  labelFont: 'arial-plain-12';
}
object."NetworkElement":selected {
  labelForeground: red;
}

object."Domain" {
  icon: @|image("domain.png");
}
object."Server" {
  icon: @|image("server.png");
}

// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// The following selectors create a composite
// graphic to represent the business object of
// class 'Workstation' in the Tree component.
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
object."Workstation" {
  class: 'ilog.views.graphic.composite.IlvCompositeGraphic';
  layout: @+attachmentLayout;
  children[0]: @+wsBase;
  children[1]: @+wsLabel;
  constraints[1]: @+wsLabelConstraint;
}

#attachmentLayout {
  class: 'ilog.views.graphic.composite.layout.IlvAttachmentLayout';
}
#wsBase {
  class: 'ilog.views.graphic.IlvIcon';
  image: '@|image("workstation.png")';
}
#wsLabel { 
  class: 'ilog.views.graphic.IlvText';
  label: @name;
  foreground: black;
  font: 'arial-bold-12';
  strokeOn: false;
  fillOn: false;
  topMargin: 2;
  bottomMargin: 2;
  leftMargin: 1;
  rightMargin: 1;
}
// The following selectors are used to provide the tree look & feel
// for selection and focus. The values are retrieved from the 
// UI manager for the selection background color and border color.
#wsLabel:selected { 
  foreground: red;
  fillOn: true;
  fillPaint: @|uimanager("Tree.selectionBackground");
}
#wsLabel:focus { 
  strokeOn: true;
  strokeColor: @|uimanager("Tree.selectionBorderColor");
}
#wsLabelConstraint {
  class: 'ilog.views.graphic.composite.layout.IlvAttachmentConstraint';
  hotSpot: Left;
  anchor: Right;
  offset: 3,0;
}