Drawing: Symbol command
A new symbol command and Drawing::FeatureViewSymbol object allow to load the contents of an external svg file and place it as a symbol on a Drawing page. This symbol can then be moved and rescaled.
This commit is contained in:
parent
df3d7ff364
commit
1f2c5b04bb
|
@ -21,6 +21,7 @@
|
||||||
#include "FeatureView.h"
|
#include "FeatureView.h"
|
||||||
#include "FeatureViewPart.h"
|
#include "FeatureViewPart.h"
|
||||||
#include "FeatureViewAnnotation.h"
|
#include "FeatureViewAnnotation.h"
|
||||||
|
#include "FeatureViewSymbol.h"
|
||||||
#include "FeatureProjection.h"
|
#include "FeatureProjection.h"
|
||||||
#include "FeatureClip.h"
|
#include "FeatureClip.h"
|
||||||
#include "PageGroup.h"
|
#include "PageGroup.h"
|
||||||
|
@ -60,6 +61,7 @@ void DrawingExport initDrawing()
|
||||||
Drawing::FeatureViewPartPython ::init();
|
Drawing::FeatureViewPartPython ::init();
|
||||||
Drawing::FeatureViewPython ::init();
|
Drawing::FeatureViewPython ::init();
|
||||||
Drawing::FeatureViewAnnotation ::init();
|
Drawing::FeatureViewAnnotation ::init();
|
||||||
|
Drawing::FeatureViewSymbol ::init();
|
||||||
Drawing::FeatureClip ::init();
|
Drawing::FeatureClip ::init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -30,10 +30,12 @@
|
||||||
#include "ProjectionAlgos.h"
|
#include "ProjectionAlgos.h"
|
||||||
#include <Base/Console.h>
|
#include <Base/Console.h>
|
||||||
#include <Base/VectorPy.h>
|
#include <Base/VectorPy.h>
|
||||||
|
#include <boost/regex.hpp>
|
||||||
|
|
||||||
|
|
||||||
using namespace Drawing;
|
using namespace Drawing;
|
||||||
using namespace Part;
|
using namespace Part;
|
||||||
|
using namespace std;
|
||||||
|
|
||||||
static PyObject *
|
static PyObject *
|
||||||
project(PyObject *self, PyObject *args)
|
project(PyObject *self, PyObject *args)
|
||||||
|
@ -158,6 +160,44 @@ projectToDXF(PyObject *self, PyObject *args)
|
||||||
} PY_CATCH;
|
} PY_CATCH;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static PyObject *
|
||||||
|
removeSvgTags(PyObject *self, PyObject *args)
|
||||||
|
{
|
||||||
|
const char* svgcode;
|
||||||
|
if (!PyArg_ParseTuple(args, "s",&svgcode))
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
PY_TRY {
|
||||||
|
string svg(svgcode);
|
||||||
|
string empty = "";
|
||||||
|
string endline = "--endOfLine--";
|
||||||
|
string linebreak = "\\n";
|
||||||
|
// removing linebreaks for regex to work
|
||||||
|
boost::regex e1 ("\\n");
|
||||||
|
svg = boost::regex_replace(svg, e1, endline);
|
||||||
|
// removing starting xml definition
|
||||||
|
boost::regex e2 ("<\\?xml.*?\\?>");
|
||||||
|
svg = boost::regex_replace(svg, e2, empty);
|
||||||
|
// removing starting svg tag
|
||||||
|
boost::regex e3 ("<svg.*?>");
|
||||||
|
svg = boost::regex_replace(svg, e3, empty);
|
||||||
|
// removing sodipodi tags -- DANGEROUS, some sodipodi tags are single, better leave it
|
||||||
|
//boost::regex e4 ("<sodipodi.*?>");
|
||||||
|
//svg = boost::regex_replace(svg, e4, empty);
|
||||||
|
// removing metadata tags
|
||||||
|
boost::regex e5 ("<metadata.*?</metadata>");
|
||||||
|
svg = boost::regex_replace(svg, e5, empty);
|
||||||
|
// removing closing svg tags
|
||||||
|
boost::regex e6 ("</svg>");
|
||||||
|
svg = boost::regex_replace(svg, e6, empty);
|
||||||
|
// restoring linebreaks
|
||||||
|
boost::regex e7 ("--endOfLine--");
|
||||||
|
svg = boost::regex_replace(svg, e7, linebreak);
|
||||||
|
Py::String result(svg);
|
||||||
|
return Py::new_reference_to(result);
|
||||||
|
} PY_CATCH;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* registration table */
|
/* registration table */
|
||||||
|
@ -170,5 +210,7 @@ struct PyMethodDef Drawing_methods[] = {
|
||||||
"string = projectToSVG(TopoShape[,App.Vector Direction, string type]) -- Project a shape and return the SVG representation as string."},
|
"string = projectToSVG(TopoShape[,App.Vector Direction, string type]) -- Project a shape and return the SVG representation as string."},
|
||||||
{"projectToDXF" ,projectToDXF ,METH_VARARGS,
|
{"projectToDXF" ,projectToDXF ,METH_VARARGS,
|
||||||
"string = projectToDXF(TopoShape[,App.Vector Direction, string type]) -- Project a shape and return the DXF representation as string."},
|
"string = projectToDXF(TopoShape[,App.Vector Direction, string type]) -- Project a shape and return the DXF representation as string."},
|
||||||
|
{"removeSvgTags" ,removeSvgTags ,METH_VARARGS,
|
||||||
|
"string = removeSvgTags(string) -- Removes the opening and closing svg tags and other metatags from a svg code, making it embeddable"},
|
||||||
{NULL, NULL} /* end of table marker */
|
{NULL, NULL} /* end of table marker */
|
||||||
};
|
};
|
||||||
|
|
|
@ -29,6 +29,8 @@ SET(Features_SRCS
|
||||||
FeatureViewPart.h
|
FeatureViewPart.h
|
||||||
FeatureViewAnnotation.cpp
|
FeatureViewAnnotation.cpp
|
||||||
FeatureViewAnnotation.h
|
FeatureViewAnnotation.h
|
||||||
|
FeatureViewSymbol.cpp
|
||||||
|
FeatureViewSymbol.h
|
||||||
FeatureClip.cpp
|
FeatureClip.cpp
|
||||||
FeatureClip.h
|
FeatureClip.h
|
||||||
PageGroup.cpp
|
PageGroup.cpp
|
||||||
|
|
87
src/Mod/Drawing/App/FeatureViewSymbol.cpp
Normal file
87
src/Mod/Drawing/App/FeatureViewSymbol.cpp
Normal file
|
@ -0,0 +1,87 @@
|
||||||
|
/***************************************************************************
|
||||||
|
* Copyright (c) Yorik van Havre (yorik@uncreated.net) 2013 *
|
||||||
|
* *
|
||||||
|
* This file is part of the FreeCAD CAx development system. *
|
||||||
|
* *
|
||||||
|
* This library is free software; you can redistribute it and/or *
|
||||||
|
* modify it under the terms of the GNU Library General Public *
|
||||||
|
* License as published by the Free Software Foundation; either *
|
||||||
|
* version 2 of the License, or (at your option) any later version. *
|
||||||
|
* *
|
||||||
|
* This library is distributed in the hope that it will be useful, *
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||||
|
* GNU Library General Public License for more details. *
|
||||||
|
* *
|
||||||
|
* You should have received a copy of the GNU Library General Public *
|
||||||
|
* License along with this library; see the file COPYING.LIB. If not, *
|
||||||
|
* write to the Free Software Foundation, Inc., 59 Temple Place, *
|
||||||
|
* Suite 330, Boston, MA 02111-1307, USA *
|
||||||
|
* *
|
||||||
|
***************************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
#include "PreCompiled.h"
|
||||||
|
|
||||||
|
#ifndef _PreComp_
|
||||||
|
# include <sstream>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <iomanip>
|
||||||
|
|
||||||
|
#include <Base/Exception.h>
|
||||||
|
#include <Base/FileInfo.h>
|
||||||
|
|
||||||
|
#include "FeatureViewSymbol.h"
|
||||||
|
|
||||||
|
using namespace Drawing;
|
||||||
|
using namespace std;
|
||||||
|
|
||||||
|
|
||||||
|
//===========================================================================
|
||||||
|
// FeatureViewSymbol
|
||||||
|
//===========================================================================
|
||||||
|
|
||||||
|
PROPERTY_SOURCE(Drawing::FeatureViewSymbol, Drawing::FeatureView)
|
||||||
|
|
||||||
|
|
||||||
|
FeatureViewSymbol::FeatureViewSymbol(void)
|
||||||
|
{
|
||||||
|
static const char *vgroup = "Drawing view";
|
||||||
|
|
||||||
|
ADD_PROPERTY_TYPE(Symbol,(""),vgroup,App::Prop_Hidden,"The SVG code defining this symbol");
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
FeatureViewSymbol::~FeatureViewSymbol()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
App::DocumentObjectExecReturn *FeatureViewSymbol::execute(void)
|
||||||
|
{
|
||||||
|
std::stringstream result;
|
||||||
|
result << "<g transform=\"translate(" << X.getValue() << "," << Y.getValue() << ")"
|
||||||
|
<< " rotate(" << Rotation.getValue() << ")"
|
||||||
|
<< " scale(" << Scale.getValue() << ")\">" << endl
|
||||||
|
<< Symbol.getValue() << endl
|
||||||
|
<< "</g>" << endl;
|
||||||
|
|
||||||
|
// Apply the resulting fragment
|
||||||
|
ViewResult.setValue(result.str().c_str());
|
||||||
|
|
||||||
|
return App::DocumentObject::StdReturn;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Python Drawing feature ---------------------------------------------------------
|
||||||
|
|
||||||
|
namespace App {
|
||||||
|
/// @cond DOXERR
|
||||||
|
PROPERTY_SOURCE_TEMPLATE(Drawing::FeatureViewSymbolPython, Drawing::FeatureViewSymbol)
|
||||||
|
template<> const char* Drawing::FeatureViewSymbolPython::getViewProviderName(void) const {
|
||||||
|
return "DrawingGui::ViewProviderDrawingView";
|
||||||
|
}
|
||||||
|
/// @endcond
|
||||||
|
|
||||||
|
// explicit template instantiation
|
||||||
|
template class DrawingExport FeaturePythonT<Drawing::FeatureViewSymbol>;
|
||||||
|
}
|
71
src/Mod/Drawing/App/FeatureViewSymbol.h
Normal file
71
src/Mod/Drawing/App/FeatureViewSymbol.h
Normal file
|
@ -0,0 +1,71 @@
|
||||||
|
/***************************************************************************
|
||||||
|
* Copyright (c) Yorik van Havre (yorik@uncreated.net 2013) *
|
||||||
|
* *
|
||||||
|
* This file is part of the FreeCAD CAx development system. *
|
||||||
|
* *
|
||||||
|
* This library is free software; you can redistribute it and/or *
|
||||||
|
* modify it under the terms of the GNU Library General Public *
|
||||||
|
* License as published by the Free Software Foundation; either *
|
||||||
|
* version 2 of the License, or (at your option) any later version. *
|
||||||
|
* *
|
||||||
|
* This library is distributed in the hope that it will be useful, *
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||||
|
* GNU Library General Public License for more details. *
|
||||||
|
* *
|
||||||
|
* You should have received a copy of the GNU Library General Public *
|
||||||
|
* License along with this library; see the file COPYING.LIB. If not, *
|
||||||
|
* write to the Free Software Foundation, Inc., 59 Temple Place, *
|
||||||
|
* Suite 330, Boston, MA 02111-1307, USA *
|
||||||
|
* *
|
||||||
|
***************************************************************************/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef _FeatureViewSymbol_h_
|
||||||
|
#define _FeatureViewSymbol_h_
|
||||||
|
|
||||||
|
|
||||||
|
#include <App/DocumentObject.h>
|
||||||
|
#include <App/PropertyLinks.h>
|
||||||
|
#include "FeatureView.h"
|
||||||
|
#include <App/FeaturePython.h>
|
||||||
|
|
||||||
|
|
||||||
|
namespace Drawing
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
/** Base class of all View Features in the drawing module
|
||||||
|
*/
|
||||||
|
class DrawingExport FeatureViewSymbol : public FeatureView
|
||||||
|
{
|
||||||
|
PROPERTY_HEADER(Drawing::FeatureView);
|
||||||
|
|
||||||
|
public:
|
||||||
|
/// Constructor
|
||||||
|
FeatureViewSymbol(void);
|
||||||
|
virtual ~FeatureViewSymbol();
|
||||||
|
|
||||||
|
App::PropertyString Symbol;
|
||||||
|
|
||||||
|
/** @name methods overide Feature */
|
||||||
|
//@{
|
||||||
|
/// recalculate the Feature
|
||||||
|
virtual App::DocumentObjectExecReturn *execute(void);
|
||||||
|
//@}
|
||||||
|
|
||||||
|
/// returns the type name of the ViewProvider
|
||||||
|
virtual const char* getViewProviderName(void) const {
|
||||||
|
return "DrawingGui::ViewProviderDrawingView";
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
typedef App::FeaturePythonT<FeatureViewSymbol> FeatureViewSymbolPython;
|
||||||
|
|
||||||
|
|
||||||
|
} //namespace Drawing
|
||||||
|
|
||||||
|
|
||||||
|
#endif
|
|
@ -438,6 +438,60 @@ bool CmdDrawingClip::isActive(void)
|
||||||
return (getActiveGuiDocument() ? true : false);
|
return (getActiveGuiDocument() ? true : false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//===========================================================================
|
||||||
|
// Drawing_Symbol
|
||||||
|
//===========================================================================
|
||||||
|
|
||||||
|
DEF_STD_CMD_A(CmdDrawingSymbol);
|
||||||
|
|
||||||
|
CmdDrawingSymbol::CmdDrawingSymbol()
|
||||||
|
: Command("Drawing_Symbol")
|
||||||
|
{
|
||||||
|
// seting the
|
||||||
|
sGroup = QT_TR_NOOP("Drawing");
|
||||||
|
sMenuText = QT_TR_NOOP("&Symbol");
|
||||||
|
sToolTipText = QT_TR_NOOP("Inserts a symbol from a svg file in the active drawing");
|
||||||
|
sWhatsThis = "Drawing_Symbol";
|
||||||
|
sStatusTip = QT_TR_NOOP("Inserts a symbol from a svg file in the active drawing");
|
||||||
|
sPixmap = "actions/drawing-symbol";
|
||||||
|
}
|
||||||
|
|
||||||
|
void CmdDrawingSymbol::activated(int iMsg)
|
||||||
|
{
|
||||||
|
|
||||||
|
std::vector<App::DocumentObject*> pages = this->getDocument()->getObjectsOfType(Drawing::FeaturePage::getClassTypeId());
|
||||||
|
if (pages.empty()){
|
||||||
|
QMessageBox::warning(Gui::getMainWindow(), QObject::tr("No page to insert"),
|
||||||
|
QObject::tr("Create a page to insert."));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// Reading an image
|
||||||
|
QString filename = Gui::FileDialog::getOpenFileName(Gui::getMainWindow(), QObject::tr("Choose an SVG file to open"), QString::null,
|
||||||
|
QObject::tr("Scalable Vector Graphics (*.svg *.svgz)"));
|
||||||
|
if (!filename.isEmpty())
|
||||||
|
{
|
||||||
|
std::string PageName = pages.front()->getNameInDocument();
|
||||||
|
std::string FeatName = getUniqueObjectName("Symbol");
|
||||||
|
openCommand("Create Symbol");
|
||||||
|
doCommand(Doc,"import Drawing");
|
||||||
|
doCommand(Doc,"f = open(\"%s\",\"r\")",(const char*)filename.toUtf8());
|
||||||
|
doCommand(Doc,"svg = f.read()");
|
||||||
|
doCommand(Doc,"f.close()");
|
||||||
|
doCommand(Doc,"App.activeDocument().addObject('Drawing::FeatureViewSymbol','%s')",FeatName.c_str());
|
||||||
|
doCommand(Doc,"App.activeDocument().%s.Symbol = Drawing.removeSvgTags(svg)",FeatName.c_str());
|
||||||
|
doCommand(Doc,"App.activeDocument().%s.addObject(App.activeDocument().%s)",PageName.c_str(),FeatName.c_str());
|
||||||
|
updateActive();
|
||||||
|
commitCommand();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
bool CmdDrawingSymbol::isActive(void)
|
||||||
|
{
|
||||||
|
return (getActiveGuiDocument() ? true : false);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
//===========================================================================
|
//===========================================================================
|
||||||
// Drawing_ExportPage
|
// Drawing_ExportPage
|
||||||
//===========================================================================
|
//===========================================================================
|
||||||
|
@ -536,6 +590,7 @@ void CreateDrawingCommands(void)
|
||||||
rcCmdMgr.addCommand(new CmdDrawingOpenBrowserView());
|
rcCmdMgr.addCommand(new CmdDrawingOpenBrowserView());
|
||||||
rcCmdMgr.addCommand(new CmdDrawingAnnotation());
|
rcCmdMgr.addCommand(new CmdDrawingAnnotation());
|
||||||
rcCmdMgr.addCommand(new CmdDrawingClip());
|
rcCmdMgr.addCommand(new CmdDrawingClip());
|
||||||
|
rcCmdMgr.addCommand(new CmdDrawingSymbol());
|
||||||
rcCmdMgr.addCommand(new CmdDrawingExportPage());
|
rcCmdMgr.addCommand(new CmdDrawingExportPage());
|
||||||
rcCmdMgr.addCommand(new CmdDrawingProjectShape());
|
rcCmdMgr.addCommand(new CmdDrawingProjectShape());
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,6 +18,7 @@
|
||||||
<file>icons/actions/drawing-openbrowser.svg</file>
|
<file>icons/actions/drawing-openbrowser.svg</file>
|
||||||
<file>icons/actions/drawing-annotation.svg</file>
|
<file>icons/actions/drawing-annotation.svg</file>
|
||||||
<file>icons/actions/drawing-clip.svg</file>
|
<file>icons/actions/drawing-clip.svg</file>
|
||||||
|
<file>icons/actions/drawing-symbol.svg</file>
|
||||||
<file>translations/Drawing_af.qm</file>
|
<file>translations/Drawing_af.qm</file>
|
||||||
<file>translations/Drawing_de.qm</file>
|
<file>translations/Drawing_de.qm</file>
|
||||||
<file>translations/Drawing_fi.qm</file>
|
<file>translations/Drawing_fi.qm</file>
|
||||||
|
|
439
src/Mod/Drawing/Gui/Resources/icons/actions/drawing-symbol.svg
Normal file
439
src/Mod/Drawing/Gui/Resources/icons/actions/drawing-symbol.svg
Normal file
|
@ -0,0 +1,439 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||||
|
|
||||||
|
<svg
|
||||||
|
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||||
|
xmlns:cc="http://creativecommons.org/ns#"
|
||||||
|
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||||
|
xmlns:svg="http://www.w3.org/2000/svg"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||||
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||||
|
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||||
|
width="64px"
|
||||||
|
height="64px"
|
||||||
|
id="svg2985"
|
||||||
|
version="1.1"
|
||||||
|
inkscape:version="0.48.4 r9939"
|
||||||
|
sodipodi:docname="drawing-symbol.svg">
|
||||||
|
<defs
|
||||||
|
id="defs2987">
|
||||||
|
<linearGradient
|
||||||
|
id="linearGradient3763">
|
||||||
|
<stop
|
||||||
|
style="stop-color:#ff8f00;stop-opacity:1;"
|
||||||
|
offset="0"
|
||||||
|
id="stop3765" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:#ffdf30;stop-opacity:1;"
|
||||||
|
offset="1"
|
||||||
|
id="stop3767" />
|
||||||
|
</linearGradient>
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient3763"
|
||||||
|
id="linearGradient3769"
|
||||||
|
x1="34.818184"
|
||||||
|
y1="58.545456"
|
||||||
|
x2="37.36364"
|
||||||
|
y2="7.2727275"
|
||||||
|
gradientUnits="userSpaceOnUse" />
|
||||||
|
<radialGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#aigrd2"
|
||||||
|
id="radialGradient2283"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
gradientTransform="matrix(0.229703,0,0,0.229703,4.613529,3.979808)"
|
||||||
|
cx="20.892099"
|
||||||
|
cy="114.5684"
|
||||||
|
fx="20.892099"
|
||||||
|
fy="114.5684"
|
||||||
|
r="5.256" />
|
||||||
|
<radialGradient
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
fy="114.5684"
|
||||||
|
fx="20.892099"
|
||||||
|
r="5.256"
|
||||||
|
cy="114.5684"
|
||||||
|
cx="20.892099"
|
||||||
|
id="aigrd2">
|
||||||
|
<stop
|
||||||
|
id="stop15566"
|
||||||
|
style="stop-color:#F0F0F0"
|
||||||
|
offset="0" />
|
||||||
|
<stop
|
||||||
|
id="stop15568"
|
||||||
|
style="stop-color:#9a9a9a;stop-opacity:1.0000000;"
|
||||||
|
offset="1.0000000" />
|
||||||
|
</radialGradient>
|
||||||
|
<radialGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#aigrd3"
|
||||||
|
id="radialGradient2285"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
gradientTransform="matrix(0.229703,0,0,0.229703,4.613529,3.979808)"
|
||||||
|
cx="20.892099"
|
||||||
|
cy="64.567902"
|
||||||
|
fx="20.892099"
|
||||||
|
fy="64.567902"
|
||||||
|
r="5.257" />
|
||||||
|
<radialGradient
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
fy="64.567902"
|
||||||
|
fx="20.892099"
|
||||||
|
r="5.257"
|
||||||
|
cy="64.567902"
|
||||||
|
cx="20.892099"
|
||||||
|
id="aigrd3">
|
||||||
|
<stop
|
||||||
|
id="stop15573"
|
||||||
|
style="stop-color:#F0F0F0"
|
||||||
|
offset="0" />
|
||||||
|
<stop
|
||||||
|
id="stop15575"
|
||||||
|
style="stop-color:#9a9a9a;stop-opacity:1.0000000;"
|
||||||
|
offset="1.0000000" />
|
||||||
|
</radialGradient>
|
||||||
|
<radialGradient
|
||||||
|
r="38.158695"
|
||||||
|
fy="7.2678967"
|
||||||
|
fx="8.1435566"
|
||||||
|
cy="7.2678967"
|
||||||
|
cx="8.1435566"
|
||||||
|
gradientTransform="matrix(1.30152,0,0,1.3882106,3.811166,-63.297199)"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
id="radialGradient15668"
|
||||||
|
xlink:href="#linearGradient15662"
|
||||||
|
inkscape:collect="always" />
|
||||||
|
<linearGradient
|
||||||
|
id="linearGradient15662">
|
||||||
|
<stop
|
||||||
|
style="stop-color:#ffffff;stop-opacity:1.0000000;"
|
||||||
|
offset="0.0000000"
|
||||||
|
id="stop15664" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:#f8f8f8;stop-opacity:1.0000000;"
|
||||||
|
offset="1.0000000"
|
||||||
|
id="stop15666" />
|
||||||
|
</linearGradient>
|
||||||
|
<radialGradient
|
||||||
|
r="86.70845"
|
||||||
|
fy="35.736916"
|
||||||
|
fx="33.966679"
|
||||||
|
cy="35.736916"
|
||||||
|
cx="33.966679"
|
||||||
|
gradientTransform="matrix(1.2910623,0,0,1.3994546,-0.69656701,-64.166132)"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
id="radialGradient15658"
|
||||||
|
xlink:href="#linearGradient259"
|
||||||
|
inkscape:collect="always" />
|
||||||
|
<linearGradient
|
||||||
|
id="linearGradient259">
|
||||||
|
<stop
|
||||||
|
style="stop-color:#fafafa;stop-opacity:1.0000000;"
|
||||||
|
offset="0.0000000"
|
||||||
|
id="stop260" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:#bbbbbb;stop-opacity:1.0000000;"
|
||||||
|
offset="1.0000000"
|
||||||
|
id="stop261" />
|
||||||
|
</linearGradient>
|
||||||
|
<radialGradient
|
||||||
|
r="37.751713"
|
||||||
|
fy="3.7561285"
|
||||||
|
fx="8.824419"
|
||||||
|
cy="3.7561285"
|
||||||
|
cx="8.824419"
|
||||||
|
gradientTransform="matrix(1.30152,0,0,1.3882106,3.811166,-63.297199)"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
id="radialGradient15656"
|
||||||
|
xlink:href="#linearGradient269"
|
||||||
|
inkscape:collect="always" />
|
||||||
|
<linearGradient
|
||||||
|
id="linearGradient269">
|
||||||
|
<stop
|
||||||
|
style="stop-color:#a3a3a3;stop-opacity:1.0000000;"
|
||||||
|
offset="0.0000000"
|
||||||
|
id="stop270" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:#4c4c4c;stop-opacity:1.0000000;"
|
||||||
|
offset="1.0000000"
|
||||||
|
id="stop271" />
|
||||||
|
</linearGradient>
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient5048"
|
||||||
|
id="linearGradient5027"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
gradientTransform="matrix(2.774389,0,0,1.969706,-1892.179,-872.8854)"
|
||||||
|
x1="302.85715"
|
||||||
|
y1="366.64789"
|
||||||
|
x2="302.85715"
|
||||||
|
y2="609.50507" />
|
||||||
|
<linearGradient
|
||||||
|
id="linearGradient5048">
|
||||||
|
<stop
|
||||||
|
style="stop-color:black;stop-opacity:0;"
|
||||||
|
offset="0"
|
||||||
|
id="stop5050" />
|
||||||
|
<stop
|
||||||
|
id="stop5056"
|
||||||
|
offset="0.5"
|
||||||
|
style="stop-color:black;stop-opacity:1;" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:black;stop-opacity:0;"
|
||||||
|
offset="1"
|
||||||
|
id="stop5052" />
|
||||||
|
</linearGradient>
|
||||||
|
<radialGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient5060"
|
||||||
|
id="radialGradient5029"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
gradientTransform="matrix(2.774389,0,0,1.969706,-1891.633,-872.8854)"
|
||||||
|
cx="605.71429"
|
||||||
|
cy="486.64789"
|
||||||
|
fx="605.71429"
|
||||||
|
fy="486.64789"
|
||||||
|
r="117.14286" />
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
id="linearGradient5060">
|
||||||
|
<stop
|
||||||
|
style="stop-color:black;stop-opacity:1;"
|
||||||
|
offset="0"
|
||||||
|
id="stop5062" />
|
||||||
|
<stop
|
||||||
|
style="stop-color:black;stop-opacity:0;"
|
||||||
|
offset="1"
|
||||||
|
id="stop5064" />
|
||||||
|
</linearGradient>
|
||||||
|
<radialGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient5060"
|
||||||
|
id="radialGradient5031"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
gradientTransform="matrix(-2.774389,0,0,1.969706,112.7623,-872.8854)"
|
||||||
|
cx="605.71429"
|
||||||
|
cy="486.64789"
|
||||||
|
fx="605.71429"
|
||||||
|
fy="486.64789"
|
||||||
|
r="117.14286" />
|
||||||
|
<radialGradient
|
||||||
|
r="117.14286"
|
||||||
|
fy="486.64789"
|
||||||
|
fx="605.71429"
|
||||||
|
cy="486.64789"
|
||||||
|
cx="605.71429"
|
||||||
|
gradientTransform="matrix(-2.774389,0,0,1.969706,112.7623,-872.8854)"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
id="radialGradient3277"
|
||||||
|
xlink:href="#linearGradient5060"
|
||||||
|
inkscape:collect="always" />
|
||||||
|
<linearGradient
|
||||||
|
inkscape:collect="always"
|
||||||
|
xlink:href="#linearGradient3763"
|
||||||
|
id="linearGradient3398"
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
x1="34.818184"
|
||||||
|
y1="58.545456"
|
||||||
|
x2="37.36364"
|
||||||
|
y2="7.2727275" />
|
||||||
|
</defs>
|
||||||
|
<sodipodi:namedview
|
||||||
|
id="base"
|
||||||
|
pagecolor="#ffffff"
|
||||||
|
bordercolor="#666666"
|
||||||
|
borderopacity="1.0"
|
||||||
|
inkscape:pageopacity="0.0"
|
||||||
|
inkscape:pageshadow="2"
|
||||||
|
inkscape:zoom="5.5"
|
||||||
|
inkscape:cx="37.815644"
|
||||||
|
inkscape:cy="28.257956"
|
||||||
|
inkscape:current-layer="layer1"
|
||||||
|
showgrid="true"
|
||||||
|
inkscape:document-units="px"
|
||||||
|
inkscape:grid-bbox="true"
|
||||||
|
inkscape:window-width="1920"
|
||||||
|
inkscape:window-height="1053"
|
||||||
|
inkscape:window-x="0"
|
||||||
|
inkscape:window-y="0"
|
||||||
|
inkscape:window-maximized="1" />
|
||||||
|
<metadata
|
||||||
|
id="metadata2990">
|
||||||
|
<rdf:RDF>
|
||||||
|
<cc:Work
|
||||||
|
rdf:about="">
|
||||||
|
<dc:format>image/svg+xml</dc:format>
|
||||||
|
<dc:type
|
||||||
|
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||||
|
<dc:title />
|
||||||
|
</cc:Work>
|
||||||
|
</rdf:RDF>
|
||||||
|
</metadata>
|
||||||
|
<g
|
||||||
|
id="layer1"
|
||||||
|
inkscape:label="Layer 1"
|
||||||
|
inkscape:groupmode="layer">
|
||||||
|
<g
|
||||||
|
style="display:inline"
|
||||||
|
id="g5022"
|
||||||
|
transform="matrix(0.02910325,0,0,0.01997086,57.26876,56.57957)">
|
||||||
|
<rect
|
||||||
|
y="-150.69685"
|
||||||
|
x="-1559.2523"
|
||||||
|
height="478.35718"
|
||||||
|
width="1339.6335"
|
||||||
|
id="rect4173"
|
||||||
|
style="opacity:0.40206185;color:#000000;fill:url(#linearGradient5027);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none;visibility:visible;display:inline;overflow:visible" />
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
sodipodi:nodetypes="cccc"
|
||||||
|
id="path5058"
|
||||||
|
d="m -219.61876,-150.68038 c 0,0 0,478.33079 0,478.33079 142.874166,0.90045 345.40022,-107.16966 345.40014,-239.196175 0,-132.026537 -159.436816,-239.134595 -345.40014,-239.134615 z"
|
||||||
|
style="opacity:0.40206185;color:#000000;fill:url(#radialGradient5029);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none;visibility:visible;display:inline;overflow:visible" />
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
style="opacity:0.40206185;color:#000000;fill:url(#radialGradient3277);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none;visibility:visible;display:inline;overflow:visible"
|
||||||
|
d="m -1559.2523,-150.68038 c 0,0 0,478.33079 0,478.33079 -142.8742,0.90045 -345.4002,-107.16966 -345.4002,-239.196175 0,-132.026537 159.4368,-239.134595 345.4002,-239.134615 z"
|
||||||
|
id="path5018"
|
||||||
|
sodipodi:nodetypes="cccc" />
|
||||||
|
</g>
|
||||||
|
<rect
|
||||||
|
ry="1.5445124"
|
||||||
|
y="-59.264698"
|
||||||
|
x="8.1797066"
|
||||||
|
height="55.003952"
|
||||||
|
width="46.877804"
|
||||||
|
id="rect15391"
|
||||||
|
style="color:#000000;fill:url(#radialGradient15658);fill-opacity:1;fill-rule:nonzero;stroke:url(#radialGradient15656);stroke-width:1.34416628;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0;marker:none;visibility:visible;display:block;overflow:visible"
|
||||||
|
rx="1.5445124"
|
||||||
|
transform="matrix(3.7443727e-4,0.99999993,-0.99999993,3.7443727e-4,0,0)" />
|
||||||
|
<rect
|
||||||
|
rx="0.20034605"
|
||||||
|
ry="0.20034605"
|
||||||
|
y="-58.004543"
|
||||||
|
x="9.6078854"
|
||||||
|
height="52.350418"
|
||||||
|
width="44.056244"
|
||||||
|
id="rect15660"
|
||||||
|
style="color:#000000;fill:none;stroke:url(#radialGradient15668);stroke-width:1.34416628;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0;marker:none;visibility:visible;display:block;overflow:visible"
|
||||||
|
transform="matrix(3.7443727e-4,0.99999993,-0.99999993,3.7443727e-4,0,0)" />
|
||||||
|
<g
|
||||||
|
style="display:inline"
|
||||||
|
id="g2270"
|
||||||
|
transform="matrix(5.0330596e-4,1.3441663,-1.3441663,5.0330596e-4,64.217258,0.14831992)">
|
||||||
|
<g
|
||||||
|
transform="matrix(0.229703,0,0,0.229703,4.967081,4.244972)"
|
||||||
|
style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-miterlimit:4"
|
||||||
|
id="g1440">
|
||||||
|
<radialGradient
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
fy="114.5684"
|
||||||
|
fx="20.892099"
|
||||||
|
r="5.256"
|
||||||
|
cy="114.5684"
|
||||||
|
cx="20.892099"
|
||||||
|
id="radialGradient1442">
|
||||||
|
<stop
|
||||||
|
id="stop1444"
|
||||||
|
style="stop-color:#F0F0F0"
|
||||||
|
offset="0" />
|
||||||
|
<stop
|
||||||
|
id="stop1446"
|
||||||
|
style="stop-color:#474747"
|
||||||
|
offset="1" />
|
||||||
|
</radialGradient>
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
id="path1448"
|
||||||
|
d="m 23.428,113.07 c 0,1.973 -1.6,3.572 -3.573,3.572 -1.974,0 -3.573,-1.6 -3.573,-3.572 0,-1.974 1.6,-3.573 3.573,-3.573 1.973,0 3.573,1.6 3.573,3.573 z"
|
||||||
|
style="stroke:none" />
|
||||||
|
<radialGradient
|
||||||
|
gradientUnits="userSpaceOnUse"
|
||||||
|
fy="64.567902"
|
||||||
|
fx="20.892099"
|
||||||
|
r="5.257"
|
||||||
|
cy="64.567902"
|
||||||
|
cx="20.892099"
|
||||||
|
id="radialGradient1450">
|
||||||
|
<stop
|
||||||
|
id="stop1452"
|
||||||
|
style="stop-color:#F0F0F0"
|
||||||
|
offset="0" />
|
||||||
|
<stop
|
||||||
|
id="stop1454"
|
||||||
|
style="stop-color:#474747"
|
||||||
|
offset="1" />
|
||||||
|
</radialGradient>
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
id="path1456"
|
||||||
|
d="m 23.428,63.07 c 0,1.973 -1.6,3.573 -3.573,3.573 -1.974,0 -3.573,-1.6 -3.573,-3.573 0,-1.974 1.6,-3.573 3.573,-3.573 1.973,0 3.573,1.6 3.573,3.573 z"
|
||||||
|
style="stroke:none" />
|
||||||
|
</g>
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
id="path15570"
|
||||||
|
d="m 9.9950109,29.952326 c 0,0.453204 -0.3675248,0.820499 -0.8207288,0.820499 -0.4534338,0 -0.8207289,-0.367524 -0.8207289,-0.820499 0,-0.453434 0.3675248,-0.820729 0.8207289,-0.820729 0.453204,0 0.8207288,0.367525 0.8207288,0.820729 z"
|
||||||
|
style="fill:url(#radialGradient2283);fill-rule:nonzero;stroke:none" />
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
id="path15577"
|
||||||
|
d="m 9.9950109,18.467176 c 0,0.453204 -0.3675248,0.820729 -0.8207288,0.820729 -0.4534338,0 -0.8207289,-0.367525 -0.8207289,-0.820729 0,-0.453434 0.3675248,-0.820729 0.8207289,-0.820729 0.453204,0 0.8207288,0.367525 0.8207288,0.820729 z"
|
||||||
|
style="fill:url(#radialGradient2285);fill-rule:nonzero;stroke:none" />
|
||||||
|
</g>
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
sodipodi:nodetypes="cc"
|
||||||
|
id="path15672"
|
||||||
|
d="M 56.786438,14.747776 5.8336749,14.766849"
|
||||||
|
style="fill:none;stroke:#000000;stroke-width:1.32877982;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:0.01754384;display:inline" />
|
||||||
|
<path
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
sodipodi:nodetypes="cc"
|
||||||
|
id="path15674"
|
||||||
|
d="M 57.423753,16.084011 6.3216261,16.103139"
|
||||||
|
style="fill:none;stroke:#ffffff;stroke-width:1.3441664;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:0.20467828;display:inline" />
|
||||||
|
<g
|
||||||
|
id="g3392"
|
||||||
|
transform="matrix(0.5226481,0,0,0.5226481,3.8083621,14.093443)">
|
||||||
|
<path
|
||||||
|
transform="translate(-2,0)"
|
||||||
|
d="m 59.636366,32 c 0,13.857327 -11.233583,25.09091 -25.09091,25.09091 -13.857327,0 -25.09091,-11.233583 -25.09091,-25.09091 0,-13.857327 11.233583,-25.09091 25.09091,-25.09091 13.857327,0 25.09091,11.233583 25.09091,25.09091 z"
|
||||||
|
sodipodi:ry="25.09091"
|
||||||
|
sodipodi:rx="25.09091"
|
||||||
|
sodipodi:cy="32"
|
||||||
|
sodipodi:cx="34.545456"
|
||||||
|
id="path2993"
|
||||||
|
style="color:#000000;fill:url(#linearGradient3398);fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
|
||||||
|
sodipodi:type="arc" />
|
||||||
|
<path
|
||||||
|
transform="translate(5.2727273,4.5454545)"
|
||||||
|
d="m 25.818182,21.818182 c 0,1.907893 -1.546653,3.454545 -3.454546,3.454545 -1.907893,0 -3.454545,-1.546652 -3.454545,-3.454545 0,-1.907893 1.546652,-3.454546 3.454545,-3.454546 1.907893,0 3.454546,1.546653 3.454546,3.454546 z"
|
||||||
|
sodipodi:ry="3.4545455"
|
||||||
|
sodipodi:rx="3.4545455"
|
||||||
|
sodipodi:cy="21.818182"
|
||||||
|
sodipodi:cx="22.363636"
|
||||||
|
id="path3771"
|
||||||
|
style="color:#000000;fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
|
||||||
|
sodipodi:type="arc" />
|
||||||
|
<path
|
||||||
|
transform="translate(15.272728,4.5454545)"
|
||||||
|
d="m 25.818182,21.818182 c 0,1.907893 -1.546653,3.454545 -3.454546,3.454545 -1.907893,0 -3.454545,-1.546652 -3.454545,-3.454545 0,-1.907893 1.546652,-3.454546 3.454545,-3.454546 1.907893,0 3.454546,1.546653 3.454546,3.454546 z"
|
||||||
|
sodipodi:ry="3.4545455"
|
||||||
|
sodipodi:rx="3.4545455"
|
||||||
|
sodipodi:cy="21.818182"
|
||||||
|
sodipodi:cx="22.363636"
|
||||||
|
id="path3771-2"
|
||||||
|
style="color:#000000;fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
|
||||||
|
sodipodi:type="arc" />
|
||||||
|
<path
|
||||||
|
sodipodi:nodetypes="cc"
|
||||||
|
inkscape:connector-curvature="0"
|
||||||
|
id="path3791"
|
||||||
|
d="m 12.909091,39.818182 c 13.373971,10.442105 31.859617,9.22201 40.909091,-1.636364"
|
||||||
|
style="fill:none;stroke:#000000;stroke-width:3;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none" />
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 16 KiB |
|
@ -64,6 +64,7 @@ Gui::MenuItem* Workbench::setupMenuBar() const
|
||||||
*part << "Drawing_OpenBrowserView";
|
*part << "Drawing_OpenBrowserView";
|
||||||
*part << "Drawing_Annotation";
|
*part << "Drawing_Annotation";
|
||||||
*part << "Drawing_Clip";
|
*part << "Drawing_Clip";
|
||||||
|
*part << "Drawing_Symbol";
|
||||||
*part << "Drawing_ExportPage";
|
*part << "Drawing_ExportPage";
|
||||||
*part << "Separator";
|
*part << "Separator";
|
||||||
*part << "Drawing_ProjectShape";
|
*part << "Drawing_ProjectShape";
|
||||||
|
@ -84,6 +85,7 @@ Gui::ToolBarItem* Workbench::setupToolBars() const
|
||||||
*part << "Drawing_OpenBrowserView";
|
*part << "Drawing_OpenBrowserView";
|
||||||
*part << "Drawing_Annotation";
|
*part << "Drawing_Annotation";
|
||||||
*part << "Drawing_Clip";
|
*part << "Drawing_Clip";
|
||||||
|
*part << "Drawing_Symbol";
|
||||||
*part << "Drawing_ExportPage";
|
*part << "Drawing_ExportPage";
|
||||||
return root;
|
return root;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user