Examples of SequenceLayoutConstraintDef


Examples of org.eclipse.sapphire.ui.diagram.shape.def.SequenceLayoutConstraintDef

    Object layoutConstraint = null;
    if (layoutDef instanceof SequenceLayoutDef)
    {
      if (((SequenceLayoutDef)layoutDef).getOrientation().content() != SequenceLayoutOrientation.STACKED)
      {
        SequenceLayoutConstraintDef def = (SequenceLayoutConstraintDef)childShapePresentation.getLayoutConstraint();
        layoutConstraint = new SapphireSequenceLayoutConstraint(def);
      }
      else
      {
        SapphireStackLayoutConstraint constraint = null;
        if (childShapePresentation.getLayoutConstraint() != null)
        {
          SequenceLayoutConstraintDef constraintDef =
              (SequenceLayoutConstraintDef)childShapePresentation.getLayoutConstraint();
          if (constraintDef != null)
          {
            constraint = new SapphireStackLayoutConstraint(
                constraintDef.getHorizontalAlignment().content(),
                constraintDef.getVerticalAlignment().content(),
                constraintDef.getMarginTop().content(),
                constraintDef.getMarginBottom().content(),
                constraintDef.getMarginLeft().content(),
                constraintDef.getMarginRight().content());
          }
        } 
        layoutConstraint = constraint != null ? constraint : new SapphireStackLayoutConstraint();
      }
    }
View Full Code Here

Examples of org.eclipse.sapphire.ui.diagram.shape.def.SequenceLayoutConstraintDef

    Object layoutConstraint = null;
    if (layoutDef instanceof SequenceLayoutDef)
    {
      if (((SequenceLayoutDef)layoutDef).getOrientation().content() != SequenceLayoutOrientation.STACKED)
      {
        SequenceLayoutConstraintDef def = (SequenceLayoutConstraintDef)childShapePresentation.getLayoutConstraint();
        layoutConstraint = new SapphireSequenceLayoutConstraint(def);
      }
      else
      {
        SapphireStackLayoutConstraint constraint = null;
        if (childShapePresentation.getLayoutConstraint() != null)
        {
          SequenceLayoutConstraintDef constraintDef =
              (SequenceLayoutConstraintDef)childShapePresentation.getLayoutConstraint();
          if (constraintDef != null)
          {
            constraint = new SapphireStackLayoutConstraint(
                constraintDef.getHorizontalAlignment().content(),
                constraintDef.getVerticalAlignment().content(),
                constraintDef.getMarginTop().content(),
                constraintDef.getMarginBottom().content(),
                constraintDef.getMarginLeft().content(),
                constraintDef.getMarginRight().content());
          }
        } 
        layoutConstraint = constraint != null ? constraint : new SapphireStackLayoutConstraint();
      }
    }
View Full Code Here

Examples of org.eclipse.sapphire.ui.diagram.shape.def.SequenceLayoutConstraintDef

    return size;
  }
 
  public Point getMinimumSize()
  {
    SequenceLayoutConstraintDef constraint = (SequenceLayoutConstraintDef)getLayoutConstraint();
    Point size = new Point(constraint.getMinWidth().content() != null ? constraint.getMinWidth().content() : -1,
                constraint.getMinHeight().content() != null ? constraint.getMinHeight().content() : -1);
    return size;
  }
View Full Code Here

Examples of org.eclipse.sapphire.ui.diagram.shape.def.SequenceLayoutConstraintDef

    return size;
  }
 
  public Point getMaximumSize()
  {
    SequenceLayoutConstraintDef constraint = (SequenceLayoutConstraintDef)getLayoutConstraint();
    Point size = new Point(constraint.getMaxWidth().content() != null ? constraint.getMaxWidth().content() : -1,
                constraint.getMaxHeight().content() != null ? constraint.getMaxHeight().content() : -1);
    return size;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.