vtkSMContextViewProxy.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkSMContextViewProxy.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 =========================================================================*/
23 #ifndef vtkSMContextViewProxy_h
24 #define vtkSMContextViewProxy_h
25 
26 #include "vtkNew.h" // needed for vtkInteractorObserver.
27 #include "vtkRemotingViewsModule.h" //needed for exports
28 #include "vtkSMViewProxy.h"
29 
31 class vtkContextView;
33 class vtkRenderWindow;
35 class vtkSelection;
37 
38 class VTKREMOTINGVIEWS_EXPORT vtkSMContextViewProxy : public vtkSMViewProxy
39 {
40 public:
41  static vtkSMContextViewProxy* New();
43  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
48  vtkContextView* GetContextView();
49 
53  virtual vtkAbstractContextItem* GetContextItem();
54 
59  vtkRenderWindow* GetRenderWindow() override;
60 
67  void SetupInteractor(vtkRenderWindowInteractor* iren) override;
68 
73 
77  virtual void ResetDisplay();
78 
86  bool CanDisplayData(vtkSMSourceProxy* producer, int outputPort) override;
87 
88  vtkSelection* GetCurrentSelection();
89 
90 protected:
92  ~vtkSMContextViewProxy() override;
93 
94  void CreateVTKObjects() override;
95 
100  void OnInteractionEvent();
101 
107  void OnForwardInteractionEvent(vtkObject*, unsigned long, void*);
108 
113  void OnLeftButtonReleaseEvent();
114 
119  void PostRender(bool interactive) override;
120 
124  int ReadXMLAttributes(vtkSMSessionProxyManager* pm, vtkPVXMLElement* element) override;
125 
131  vtkTypeUInt32 PreRender(bool interactive) override;
132 
137 
147 
154 
155 private:
157  void operator=(const vtkSMContextViewProxy&) = delete;
158 
163  void CopyAxisRangesFromChart();
164 
166  vtkNew<vtkEventForwarderCommand> EventForwarder;
167 };
168 
169 #endif
void CreateVTKObjects() override
Called at the end of CreateVTKObjects().
virtual void PostRender(bool vtkNotUsed(interactive))
Superclass for all view proxies.
static vtkSMViewProxy * New()
virtual vtkRenderWindow * GetRenderWindow()
Return the vtkRenderWindow used by this view, if any.
void PrintSelf(ostream &os, vtkIndent indent) override
bool XYChartViewBase4Axes
Flag automatically set when Bottom and Right custom axes related property are present in this proxy.
vtkContextView * ChartView
The context view that is used for all context derived charts.
virtual vtkRenderWindowInteractor * GetInteractor()
Returns the interactor.
virtual vtkTypeUInt32 PreRender(bool vtkNotUsed(interactive))
This method is called before executing code that could cause a render on the underlying vtkPVView.
int ReadXMLAttributes(vtkSMSessionProxyManager *pm, vtkPVXMLElement *element) override
Read attributes from an XML element.
proxy for a VTK source on a server
abstract base class for all Chart Views.
The vtkSMSessionProxyManager is esponsible for creating and managing proxies for a given session.
virtual bool CanDisplayData(vtkSMSourceProxy *producer, int outputPort)
Returns true if the view can display the data produced by the producer's port.
virtual void SetupInteractor(vtkRenderWindowInteractor *iren)
A client process need to set the interactor to enable interactivity.
helper class that make it easier to hook vtkRenderWindowInteractor and vtkSMViewProxy.
This is used by vtkPVXMLParser to represent an XML document starting at the root element.
bool SkipPlotableCheck
To avoid showing large datasets in context views, that typically rely on delivering all data to the c...