vtkSMScalarBarWidgetRepresentationProxy.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkSMScalarBarWidgetRepresentationProxy.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
22 #ifndef vtkSMScalarBarWidgetRepresentationProxy_h
23 #define vtkSMScalarBarWidgetRepresentationProxy_h
24 
25 #include "vtkRemotingViewsModule.h" //needed for exports
27 #include "vtkSMTrace.h" // needed for vtkSMTrace::TraceItem
28 
29 class vtkSMViewProxy;
31 
34 {
35 public:
38  void PrintSelf(ostream& os, vtkIndent indent) override;
39 
41 
45  virtual bool UpdateComponentTitle(vtkPVArrayInformation* dataInfo);
46  static bool UpdateComponentTitle(vtkSMProxy* proxy, vtkPVArrayInformation* dataInfo)
47  {
50  return self ? self->UpdateComponentTitle(dataInfo) : false;
51  }
53 
55 
59  virtual bool PlaceInView(vtkSMProxy* view);
60  static bool PlaceInView(vtkSMProxy* proxy, vtkSMProxy* view)
61  {
64  return self ? self->PlaceInView(view) : false;
65  }
67 
68 protected:
71 
76  void CreateVTKObjects() override;
77 
81  void ExecuteEvent(unsigned long event) override;
82 
84 
85 private:
87 
92  void BeginTrackingPropertiesForTrace();
93  void EndTrackingPropertiesForTrace();
95 
100  void ScalarBarWidgetPosition2ToScalarBarLength();
101  void ScalarBarLengthToScalarBarWidgetPosition2();
102 
103  // Used in StartTrackingPropertiesForTrace/EndTrackingPropertiesForTrace.
104  vtkSMTrace::TraceItem* TraceItem;
105 
106 private:
108  void operator=(const vtkSMScalarBarWidgetRepresentationProxy&) = delete;
109 };
110 
111 #endif
is the representation corresponding to a scalar bar or color legend in a Render View.
#define VTKREMOTINGVIEWS_EXPORT
Superclass for all view proxies.
proxy for 3D widgets and their representations in ParaView.
static vtkSMScalarBarWidgetRepresentationProxy * SafeDownCast(vtkObject *o)
void CreateVTKObjects() override
Overridden from vtkSMProxy to call BeginCreateVTKObjects() and EndCreateVTKObjects().
void PrintSelf(ostream &os, vtkIndent indent) override
static bool UpdateComponentTitle(vtkSMProxy *proxy, vtkPVArrayInformation *dataInfo)
Updates the scalar bar's component title using the data information to determine component names if p...
static vtkSMNewWidgetRepresentationProxy * New()
virtual void ExecuteEvent(unsigned long event)
Called every time the user interacts with the widget.
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:152
Data array information like type.
static bool PlaceInView(vtkSMProxy *proxy, vtkSMProxy *view)
Attempt to place the scalar bar in the view based on the placement of other currently shown and visib...