Package prefuse.action

Examples of prefuse.action.ItemAction


        //====================================================================
       
        //==== color actions       
        //==== palette for nodes, node color action, and text color action
        int[] nodePalette = new int[]{ColorLib.rgb(153,255,153), ColorLib.rgb(255,255,153), ColorLib.rgb(153,153,255)};       
        ItemAction nodeColor = new NodeColorAction(treeNodes, nodePalette);
        ItemAction textColor = new TextColorAction(treeNodes);
        m_vis.putAction("textColor", textColor);
        m_vis.putAction("nodeColor", nodeColor);
       
        //==== border color for blank borders, and citation count highlighting
        ItemAction borderHighlightColor = new ColorAction("citHighlight", VisualItem.STROKECOLOR, ColorLib.rgb(255,0,0));
        m_vis.putAction("borderHighlightColor", borderHighlightColor);
        ItemAction borderColor = new ColorAction(treeNodes, VisualItem.STROKECOLOR, ColorLib.rgba(0,0,0,0));
        m_vis.putAction("borderColor", borderColor);
       
        //==== spreads the nodes out a little bit
        NodeSpreadAction spreadNodes = new NodeSpreadAction(treeNodes);
        m_vis.putAction("spreadNodes", spreadNodes);
View Full Code Here


        // border colors
        ColorAction borderColor = new BorderColorAction( GRAPH_NODES );
        ColorAction fillColor = new FillColorAction( GRAPH_NODES );

        // uses edge colors
        ItemAction usesColor = new ColorAction( GRAPH_EDGES, usesPredicate, VisualItem.STROKECOLOR, ColorLib.rgb( 50, 50, 50 ) );
        ItemAction usesArrow = new ColorAction( GRAPH_EDGES, usesPredicate, VisualItem.FILLCOLOR, ColorLib.rgb( 50, 50, 50 ) );

        // color settings
        ActionList colors = new ActionList();
        colors.add( fillColor );
        colors.add( borderColor );
View Full Code Here

        rf.add( edgesPredicate, edgeRenderer );
        rf.add( usesPredicate, usesRenderer );
        m_vis.setRendererFactory( rf );

        // colors
        ItemAction nodeColor = new NodeColorAction( GRAPH_NODES );
        ItemAction textColor = new ColorAction( GRAPH_NODES, VisualItem.TEXTCOLOR, ColorLib.rgb( 0, 0, 0 ) );
        m_vis.putAction( "textColor", textColor );

        ItemAction edgeColor = new ColorAction( GRAPH_EDGES, edgesPredicate, VisualItem.STROKECOLOR, ColorLib.rgb( 200, 200, 200 ) );
        ItemAction usesColor = new ColorAction( GRAPH_EDGES, usesPredicate, VisualItem.STROKECOLOR, ColorLib.rgb( 255, 100, 100 ) );
        ItemAction usesArrow = new ColorAction( GRAPH_EDGES, usesPredicate, VisualItem.FILLCOLOR, ColorLib.rgb( 255, 100, 100 ) );

        // quick repaint
        ActionList repaint = new ActionList();
        repaint.add( nodeColor );
        repaint.add( new RepaintAction() );
View Full Code Here

        DefaultRendererFactory rf = new DefaultRendererFactory(m_nodeRenderer);
        rf.add(new InGroupPredicate(treeEdges), m_edgeRenderer);
        m_vis.setRendererFactory(rf);
              
        // colors
        ItemAction nodeColor = new NodeColorAction(treeNodes);
        ItemAction textColor = new ColorAction(treeNodes,
                VisualItem.TEXTCOLOR, ColorLib.rgb(0,0,0));
        m_vis.putAction("textColor", textColor);
       
        ItemAction edgeColor = new ColorAction(treeEdges,
                VisualItem.STROKECOLOR, ColorLib.rgb(200,200,200));
       
        // quick repaint
        ActionList repaint = new ActionList();
        repaint.add(nodeColor);
View Full Code Here

        m_vis.setRendererFactory(rf);
              
        // -- set up processing actions --
       
        // colors
        ItemAction nodeColor = new NodeColorAction(treeNodes);
        ItemAction textColor = new TextColorAction(treeNodes);
        m_vis.putAction("textColor", textColor);
       
        ItemAction edgeColor = new ColorAction(treeEdges,
                VisualItem.STROKECOLOR, ColorLib.rgb(200,200,200));
       
        FontAction fonts = new FontAction(treeNodes,
                FontLib.getFont("Tahoma", 10));
        fonts.add("ingroup('_focus_')", FontLib.getFont("Tahoma", 11));
View Full Code Here

        colorManager.setFailureFilter(failureFilter);
        colorManager.setOkayFilter(okayFilter);
        colorManager.setNoServiceItemFilter(noServiceItemFilter);

        //ItemAction nodeColor = new NodeColorAction(TREE_NODES);
        ItemAction textColor = new TextColorAction(Constants.TREE_NODES);

        vis.putAction("textColor", textColor);

        ItemAction edgeColor = new ColorAction(Constants.TREE_EDGES,
                                               VisualItem.STROKECOLOR,
                                               ColorManager.EDGE_COLOR_RGB);

        FontAction fonts = new FontAction(Constants.TREE_NODES,
                                          FontLib.getFont("Tahoma", 12));
View Full Code Here

TOP

Related Classes of prefuse.action.ItemAction

Copyright © 2018 www.massapicom. 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.