{
return QIcon();
}
+
+QIcon ModuleBase_IconFactory::loadIcon(const QString& theValue)
+{
+ QIcon anIcon(theValue);
+
+ if (anIcon.isNull()) {
+
+ }
+
+ return anIcon;
+}
/// \param theObj an object
virtual QIcon getIcon(ObjectPtr theObj);
+ /// Finds an icon for the given object. The icon is loaded: firstly from qrc file,
+ /// then by the icon path. If the path contains ":" , it will be treated as absolute path to
+ /// the icon, or relative path from the plugin library
+ /// \param theValue an icon information
+ /// \return a loaded or empty icon
+ static QIcon loadIcon(const QString& theValue);
+
protected:
ModuleBase_IconFactory();
<file>icons/dimension_v.png</file>
<file>icons/radius.png</file>
<file>icons/perpendicular.png</file>
- <file>icons/parallel.png</file>
<file>icons/partition.png</file>
<file>icons/length.png</file>
<file>icons/distance.png</file>
../SketcherPrs
)
+SET(ICON_RESOURCES
+ icons/parallel.png
+)
+
INSTALL(TARGETS SketchPlugin DESTINATION ${SHAPER_INSTALL_PLUGIN_FILES})
INSTALL(FILES ${XML_RESOURCES} DESTINATION ${SHAPER_INSTALL_XML_RESOURCES})
+INSTALL(FILES ${ICON_RESOURCES} DESTINATION ${SHAPER_INSTALL_XML_RESOURCES})
ADD_UNIT_TESTS(TestSketchPointLine.py
TestSketchArcCircle.py
</feature>
<!-- SketchConstraintParallel -->
- <feature id="SketchConstraintParallel" title="Parallel" tooltip="Create constraint defining two parallel lines" icon=":icons/parallel.png">
+ <feature id="SketchConstraintParallel" title="Parallel" tooltip="Create constraint defining two parallel lines"
+ icon="parallel.png">
<sketch_shape_selector id="ConstraintEntityA"
label="First line" tooltip="Select a line" shape_types="edge">
<validator id="GeomValidators_ShapeType" parameters="line"/>