VTK  9.3.1
vtkApplyIcons.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
47 #ifndef vtkApplyIcons_h
48 #define vtkApplyIcons_h
49 
51 #include "vtkVariant.h" // For variant arguments.
52 #include "vtkViewsInfovisModule.h" // For export macro
53 
54 VTK_ABI_NAMESPACE_BEGIN
55 class VTKVIEWSINFOVIS_EXPORT vtkApplyIcons : public vtkPassInputTypeAlgorithm
56 {
57 public:
58  static vtkApplyIcons* New();
60  void PrintSelf(ostream& os, vtkIndent indent) override;
61 
63 
67  void SetIconType(vtkVariant v, int icon);
68  void SetIconType(double v, int icon) { this->SetIconType(vtkVariant(v), icon); }
69  void SetIconType(const char* v, int icon) { this->SetIconType(vtkVariant(v), icon); }
70  void ClearAllIconTypes();
72 
74 
78  vtkSetMacro(UseLookupTable, bool);
79  vtkGetMacro(UseLookupTable, bool);
80  vtkBooleanMacro(UseLookupTable, bool);
82 
84 
88  vtkSetMacro(DefaultIcon, int);
89  vtkGetMacro(DefaultIcon, int);
91 
93 
97  vtkSetMacro(SelectedIcon, int);
98  vtkGetMacro(SelectedIcon, int);
100 
102 
106  vtkSetStringMacro(IconOutputArrayName);
107  vtkGetStringMacro(IconOutputArrayName);
109 
110  enum
111  {
115  IGNORE_SELECTION
116  };
117 
119 
129  vtkSetMacro(SelectionMode, int);
130  vtkGetMacro(SelectionMode, int);
131  virtual void SetSelectionModeToSelectedIcon() { this->SetSelectionMode(SELECTED_ICON); }
132  virtual void SetSelectionModeToSelectedOffset() { this->SetSelectionMode(SELECTED_OFFSET); }
133  virtual void SetSelectionModeToAnnotationIcon() { this->SetSelectionMode(ANNOTATION_ICON); }
134  virtual void SetSelectionModeToIgnoreSelection() { this->SetSelectionMode(IGNORE_SELECTION); }
136 
138 
144  vtkSetMacro(AttributeType, int);
145  vtkGetMacro(AttributeType, int);
147 
148 protected:
149  vtkApplyIcons();
150  ~vtkApplyIcons() override;
151 
156 
160  int FillInputPortInformation(int port, vtkInformation* info) override;
161 
168 
169  class Internals;
170  Internals* Implementation;
171 
172 private:
173  vtkApplyIcons(const vtkApplyIcons&) = delete;
174  void operator=(const vtkApplyIcons&) = delete;
175 };
176 
177 VTK_ABI_NAMESPACE_END
178 #endif
Superclass for algorithms that produce output of the same type as input.
Store vtkAlgorithm input/output information.
virtual void SetSelectionModeToSelectedIcon()
Changes the behavior of the icon to use for selected items.
void SetIconType(double v, int icon)
Edits the lookup table to use for point icons.
Definition: vtkApplyIcons.h:68
A type representing the union of many types.
Definition: vtkVariant.h:52
virtual void SetSelectionModeToIgnoreSelection()
Changes the behavior of the icon to use for selected items.
a simple class to control print indentation
Definition: vtkIndent.h:28
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
void SetIconType(const char *v, int icon)
Edits the lookup table to use for point icons.
Definition: vtkApplyIcons.h:69
Internals * Implementation
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual void SetSelectionModeToAnnotationIcon()
Changes the behavior of the icon to use for selected items.
Store zero or more vtkInformation instances.
virtual void SetSelectionModeToSelectedOffset()
Changes the behavior of the icon to use for selected items.
apply icons to a data set.
Definition: vtkApplyIcons.h:55
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks the algorithm to do its work.
static vtkPassInputTypeAlgorithm * New()
char * IconOutputArrayName