Gui: Placement/DatumCS view provider changes
* Add always zoom invariant and always on top rendering to ViewProviderDatumCS * Add a new utility class AxisOrigin for more efficient axis rendering. Also exposed to python. * Change ViewProviderPlacement to use AxisOrigin for rendering. A single instance of AxisOrigin is shared by all ViewProviderPlacement. Selection context is used to distinguish among different instances.
This commit is contained in:
@@ -1862,6 +1862,7 @@ void Application::initTypes(void)
|
||||
App ::MaterialObjectPython ::init();
|
||||
App ::TextDocument ::init();
|
||||
App ::Placement ::init();
|
||||
App ::PlacementPython ::init();
|
||||
App ::OriginFeature ::init();
|
||||
App ::Plane ::init();
|
||||
App ::Line ::init();
|
||||
|
||||
@@ -51,6 +51,14 @@ Placement::~Placement(void)
|
||||
|
||||
|
||||
|
||||
// Python feature ---------------------------------------------------------
|
||||
namespace App {
|
||||
PROPERTY_SOURCE_TEMPLATE(App::PlacementPython, App::Placement)
|
||||
template<> const char* App::PlacementPython::getViewProviderName(void) const {
|
||||
return "Gui::ViewProviderPlacementPython";
|
||||
}
|
||||
template class AppExport FeaturePythonT<App::Placement>;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
|
||||
#include <Base/Placement.h>
|
||||
|
||||
#include "FeaturePython.h"
|
||||
#include "GeoFeature.h"
|
||||
#include "PropertyGeo.h"
|
||||
|
||||
@@ -66,6 +67,7 @@ public:
|
||||
|
||||
|
||||
};
|
||||
typedef App::FeaturePythonT<App::Placement> PlacementPython;
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user