Package diva.canvas.toolbox

Examples of diva.canvas.toolbox.PaintedFigure


     */
    public void createIcon2() {
        FigureLayer layer = graphicsPane.getForegroundLayer();

        // Use a hash-table
        PaintedFigure g = new PaintedFigure();

        HashMap map = new HashMap();
        map.put("coords", "30 50 70 80 70 20");
        map.put("fill", "red");
        map.put("width", "1");
        g.add(GraphicsParser.createPaintedObject("polygon", map));

        //Line2D line1 = new Line2D.Double(10,50,30,50);
        //f.add(new PaintedPath(line1));
        //Line2D line2 = new Line2D.Double(70,50,90,50);
        //f.add(new PaintedPath(line2));
        layer.add(g);
        g.setInteractor(defaultInteractor);
        g.translate(100, 0);
    }
View Full Code Here


        // If the paintedList is still null, then return the default figure.
        if (_paintedList == null) {
            return _createDefaultBackgroundFigure();
        }

        return new PaintedFigure(_paintedList);
    }
View Full Code Here

            XmlReader reader = new XmlReader();
            reader.parse(document, in);

            XmlElement root = document.getRoot();
            PaintedList paintedList = SVGParser.createPaintedList(root);
            figure = new PaintedFigure(paintedList);
        } catch (Exception ex) {
            return super.createIcon();
        }

        // NOTE: The size is hardwired here.  Should it be?
View Full Code Here

TOP

Related Classes of diva.canvas.toolbox.PaintedFigure

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.