예제 #1
0
파일: PortionDrawer.cpp 프로젝트: 8l/oovcde
void PortionDrawer::drawGraph(DiagramDrawer &drawer)
    {
    if(mGraph)
        {
        // This must be set for svg
        drawer.setDiagramSize(getDrawingSize(drawer));

        drawNodes(drawer);
        drawer.groupShapes(true, Color(0,0,0), Color(245,245,255));
        drawConnections(drawer);
        drawer.groupShapes(false, 0, 0);

        std::vector<DrawString> drawStrings;
        std::vector<bool> virtOpers;
        getNodeText(drawer, drawStrings, virtOpers);

        drawer.groupText(true, false);
        drawNodeText(drawer, false, drawStrings, virtOpers);
        drawer.groupText(false, false);

        drawer.groupText(true, true);
        drawNodeText(drawer, true, drawStrings, virtOpers);
        drawer.groupText(false, false);
        }
    }
예제 #2
0
GraphSize OperationDrawer::drawDiagram(DiagramDrawer &drawer,
        OperationGraph &graph, const OperationDrawOptions &options)
    {
    drawer.setDiagramSize(getDrawingSize(drawer, graph, options));
    drawer.setCurrentDrawingFontSize(mDiagram.getDiagramBaseFontSize());
    return drawOrSizeDiagram(drawer, graph, options, true);
    }