Examples of GraphicNode


Examples of com.adobe.internal.fxg.dom.GraphicNode

                unit.topLevelDefinitions.add(topLevelQName);

                MultiName baseMultiName = MULTINAME_SPRITEVISUALELEMENT;
                if (node instanceof GraphicNode)
                {
                  GraphicNode graphicNode = (GraphicNode)node;
                  if (graphicNode.baseClassName != null)
                  {
                    String pkg = "";
                    String baseClassName = graphicNode.baseClassName;
                    String className = baseClassName;
View Full Code Here

Examples of com.adobe.internal.fxg.dom.GraphicNode

    /**
     * {@inheritDoc}
     */
    public Object transcode(FXGNode fxgNode)
    {
        GraphicNode node = (GraphicNode)fxgNode;
        DefineSprite sprite = createDefineSprite("Graphic");
        spriteStack.push(sprite);

        // Process mask (if present)
        if (node.mask != null)
            mask(node, sprite);

        // Handle 'scale 9' grid definition
        if (node.definesScaleGrid())
        {
            DefineScalingGrid grid = createDefineScalingGrid(node.getScalingGrid());
            grid.scalingTarget = sprite;
            sprite.scalingGrid = grid;
        }

        // Process child nodes
View Full Code Here

Examples of com.adobe.internal.fxg.dom.GraphicNode

                if (group.children != null)
                    clipDepth = parentSprite.depthCounter + group.children.size();
            }
            else if (node instanceof GraphicNode)
            {
                GraphicNode graphic = (GraphicNode)node;
                if (graphic.children != null)
                    clipDepth = parentSprite.depthCounter + graphic.children.size();
            }
            // ... otherwise, just clip the shape itself.
            else
View Full Code Here

Examples of com.projity.pm.graphic.model.cache.GraphicNode

  protected CellFormat format=new CellFormat();
  public DefaultCellStyle(){
   
  }
  public CellFormat getCellFormat(Object object) {
    GraphicNode node=(GraphicNode)object;
//    CellFormat format=new CellFormat();
    format.reset();
    format.setBold(node.isSummary());
    format.setItalic(node.isAssignment());
    format.setCompositeIcon(node.isSummary()||node.isValidLazyParent());
    if (node.getSubprojectLevel()>0) format.setBackground(node.getSubprojectLevel()%2==0?"MULTIPROJET0":"MULTIPROJET1");
    if (node.isGroup()){
      if (node.getLevel()==1) format.setBackground("TAN");
      else format.setBackground("LINEN");
    }
    return format;
  }
View Full Code Here

Examples of com.projity.pm.graphic.model.cache.GraphicNode

  public ResourceCellStyle(){
   
  }
  public CellFormat getCellFormat(Object object) {
    CellFormat format=super.getCellFormat(object);
    GraphicNode node=(GraphicNode)object;
    Object impl=node.getNode().getImpl();
    if (impl instanceof ResourceImpl) {
      if (((ResourceImpl)impl).getAssignments().size()>0) // make assigned resources have a special color
        format.setBackground("PALE_GREEN");
    }
View Full Code Here

Examples of com.projity.pm.graphic.model.cache.GraphicNode

  protected CellFormat format=new CellFormat();
  public AssignmentCellStyle(){
   
  }
  public CellFormat getCellFormat(Object object) {
    GraphicNode node=(GraphicNode)object;
    //CellFormat format=new CellFormat();   
    format.reset();
    format.setBold(node.isSummary());
    format.setItalic(node.isAssignment());
    format.setCompositeIcon(node.isSummary()||node.isValidLazyParent());
    if (node.isGroup()){
      if (node.getLevel()==1) format.setBackground("TAN");
      else format.setBackground("LINEN");
    }
    else format.setBackground("NORMAL_YELLOW");
    return format;
  }
View Full Code Here

Examples of com.projity.pm.graphic.model.cache.GraphicNode

    protected int beforeLinkState=0;
    public void mouseDragged(MouseEvent e){
      if (isReadOnly()) return;
      if (!SwingUtilities.isLeftMouseButton(e)) return;
      if (selected instanceof GraphicNode){
        GraphicNode node=(GraphicNode)selected;
        boolean sw=switchOnLinkCreation(e.getX(),e.getY());
        if (state!=LINK_CREATION&&sw){
          drawBarShadow(lastShadowX,lastLinkShadowY,true);
          beforeLinkState=state;
          state=LINK_CREATION;
          selectCursor();

          sourceNode=(GraphicNode)selected;
          drawLinkSelectionBarShadow(sourceNode);

          setLinkOrigin();
        }
        else if (state==LINK_CREATION&&!sw&&allowLinkSelectionToMove()){
          drawLinkShadow(lastLinkShadowX,lastLinkShadowY,true);
          drawBarShadow(lastShadowX,lastLinkShadowY,true);
          state=beforeLinkState;
          selectCursor();

          sourceNode=null;

        }
      }
      if (state==LINK_CREATION){
        GraphZone zone=ui.getNodeAt(e.getX(),e.getY());
      GraphicNode newDestinationNode=zone==null?null:(GraphicNode)zone.getObject();
      drawLinkSelectionBarShadow(destinationNode);
        drawLinkShadow(lastLinkShadowX,lastLinkShadowY,true);
        scrollToVisible(e.getX(),e.getY());
      drawLinkShadow(e.getX(),e.getY(),true);
      if (newDestinationNode!=null && newDestinationNode.isLinkable() && sourceNode != newDestinationNode){
        destinationNode=newDestinationNode;
        drawLinkSelectionBarShadow(destinationNode);
      }else destinationNode=null;
      }else if (isMove()){
        drawBarShadow(lastShadowX,lastShadowY,true);
View Full Code Here

Examples of com.projity.pm.graphic.model.cache.GraphicNode

      //System.out.println("Shallow update");
      if (nodes==null) updateShapes();
      else updateShapes(nodes.listIterator());
    }
    public void updateShapes(ListIterator nodeIterator){
      GraphicNode node;
    for (ListIterator i=nodeIterator;i.hasNext();){
      node=(GraphicNode)i.next();
      if (!node.isVoid()) updateShape(node);
    }
    }
View Full Code Here

Examples of com.projity.pm.graphic.model.cache.GraphicNode

  }
 
  protected int updateBounds(Point2D origin,Rectangle2D ref){//cache in current version isn't a tree
    double x=origin.getX()+ref.getWidth()/2;
    double y=origin.getY()+ref.getHeight()/2;
    GraphicNode node,previous=null;
    int maxLevel=0;
    for (ListIterator i=cache.getIterator();i.hasNext();){
      node=(GraphicNode)i.next();
      if (node.getLevel()>maxLevel) maxLevel=node.getLevel();
      if (previous!=null&&node.getLevel()<=previous.getLevel()){
        setShape(previous,ref,x,y+(previous.getLevel()-1)*(ref.getMaxY()));
        x+=ref.getMaxX();
      }
      previous=node;
    }
 
View Full Code Here

Examples of com.projity.pm.graphic.model.cache.GraphicNode

  protected void updateBounds(int level,Point2D origin,Rectangle2D ref){//cache in current version isn't a tree
    double y=origin.getY()+ref.getHeight()/2+ref.getMaxY()*(level-1);
    Point2D childCenter,center;
    double x0,x1;
    GraphicNode node,child;
    boolean hasChild;
    for (ListIterator i=cache.getIterator();i.hasNext();){
      node=(GraphicNode)i.next();
      if (node.getLevel()==level){
        x0=-1;
        x1=-1;
        hasChild=false;
        while (i.hasNext()){
          child=(GraphicNode)i.next();
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.