Beispiel #1
0
  /**
   * Updates the attributes in the fig. Called from modelchanged if there is a modelevent effecting
   * the attributes and from renderingChanged in all cases.
   */
  protected void updateAttributes() {
    if (!isAttributesVisible()) {
      return;
    }
    FigAttributesCompartment attributesCompartment = getAttributesFig();
    attributesCompartment.populate();

    Rectangle rect = getBounds();

    // ouch ugly but that's for a next refactoring
    // TODO: make setBounds, calcBounds and updateBounds consistent
    setBounds(rect.x, rect.y, rect.width, rect.height);
  }
Beispiel #2
0
 /** @return The bounds of the attributes compartment. */
 public Rectangle getAttributesBounds() {
   return attributesFigCompartment.getBounds();
 }