This file is indexed.

/usr/include/vtk-6.2/vtkTanglegramItem.h is in libvtk6-dev 6.2.0+dfsg1-10build1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
/*=========================================================================

  Program:   Visualization Toolkit
  Module:    TestDiagram.cxx

  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
  All rights reserved.
  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.

     This software is distributed WITHOUT ANY WARRANTY; without even
     the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
     PURPOSE.  See the above copyright notice for more information.

=========================================================================*/
// .NAME vtkTanglegramItem - Display two related trees
//
// .SECTION Description
// This item draws two trees with connections between their leaf nodes.
// Use SetTable() to specify what leaf nodes correspond to one another
// between the two trees.  See the documentation for this function for
// more details on how this table should be formatted.
//
// .SEE ALSO
// vtkTree vtkTable vtkDendrogramItem vtkNewickTreeReader

#ifndef vtkTanglegramItem_h
#define vtkTanglegramItem_h

#include "vtkViewsInfovisModule.h" // For export macro

#include "vtkContextItem.h"
#include "vtkSmartPointer.h"       // For SmartPointer ivars
#include "vtkTable.h"  // For get/set

class vtkDendrogramItem;
class vtkLookupTable;
class vtkStringArray;
class vtkTree;

class VTKVIEWSINFOVIS_EXPORT vtkTanglegramItem : public vtkContextItem
{
public:
  static vtkTanglegramItem *New();
  vtkTypeMacro(vtkTanglegramItem, vtkContextItem);
  virtual void PrintSelf(ostream &os, vtkIndent indent);

  // Description:
  // Set the first tree
  virtual void SetTree1(vtkTree *tree);

  // Description:
  // Set the second tree
  virtual void SetTree2(vtkTree *tree);

  // Description:
  // Get/Set the table that describes the correspondences between the
  // two trees.  The first column should contain the names of the leaf
  // nodes from tree #1.  The columns of this table should be named
  // after the leaf nodes of tree #2.  A non-zero cell should be used
  // to create a connection between the two trees.  Different numbers
  // in the table will result in connections being drawn in different
  // colors.
  vtkTable * GetTable();
  void SetTable(vtkTable *table);

  // Description:
  // Get/Set the label for tree #1.
  vtkGetStringMacro(Tree1Label);
  vtkSetStringMacro(Tree1Label);

  // Description:
  // Get/Set the label for tree #2.
  vtkGetStringMacro(Tree2Label);
  vtkSetStringMacro(Tree2Label);

  // Description:
  // Set which way the tanglegram should face within the visualization.
  // The default is for tree #1 to be drawn left to right.
  void SetOrientation(int orientation);

  // Description:
  // Get the current orientation.
  int GetOrientation();

  // Description:
  // Get/Set the smallest font size that is still considered legible.
  // If the current zoom level requires our vertex labels to be smaller
  // than this size the labels will not be drawn at all.  Default value
  // is 8 pt.
  vtkGetMacro(MinimumVisibleFontSize, int);
  vtkSetMacro(MinimumVisibleFontSize, int);

  // Description:
  // Get/Set how much larger the dendrogram labels should be compared to the
  // vertex labels.  Because the vertex labels automatically resize based
  // on zoom levels, this is a relative (not absolute) size.  Default value
  // is 4 pts larger than the vertex labels.
  vtkGetMacro(LabelSizeDifference, int);
  vtkSetMacro(LabelSizeDifference, int);

  // Description:
  // Get/Set how wide the correspondence lines should be.  Default is two pixels.
  vtkGetMacro(CorrespondenceLineWidth, float);
  vtkSetMacro(CorrespondenceLineWidth, float);

  // Description:
  // Get/Set how wide the edges of the trees should be.  Default is one pixel.
  float GetTreeLineWidth();
  void SetTreeLineWidth(float width);

  // BTX

  // Description:
  // Returns true if the transform is interactive, false otherwise.
  virtual bool Hit(const vtkContextMouseEvent &mouse);

  // Description:
  // Propagate any double click onto the dendrograms to check if any
  // subtrees should be collapsed or expanded.
  virtual bool MouseDoubleClickEvent(const vtkContextMouseEvent &event);

  //ETX

protected:
  vtkTanglegramItem();
  ~vtkTanglegramItem();

  // Description:
  // Update the bounds of our two dendrograms.
  void RefreshBuffers(vtkContext2D *painter);

  // Description:
  // Calculate and set an appropriate position for our second dendrogram.
  void PositionTree2();

  // Description:
  // Draw the lines between the corresponding vertices of our two dendrograms.
  void PaintCorrespondenceLines(vtkContext2D *painter);

  // Description:
  // Draw the labels of our two dendrograms.
  void PaintTreeLabels(vtkContext2D *painter);

  // Description:
  // Reorder the children of tree #2 to minimize the amount of crossings
  // in our tanglegram.
  void ReorderTree();

  // Description:
  // Helper function used by ReorderTree.
  // Rearrange the children of the specified parent vertex in order to minimize
  // tanglegram crossings.
  void ReorderTreeAtVertex(vtkIdType parent, vtkTree *tree);

  // Description:
  // Helper function used by ReorderTreeAtVertex.  Get the average height of
  // the vertices that correspond to the vertex parameter.  This information
  // is used to determine what order sibling vertices should have within the
  // tree.
  double GetPositionScoreForVertex(vtkIdType vertex, vtkTree *tree);

  // Description:
  // Initialize the lookup table used to color the lines between the two
  // dendrograms.
  void GenerateLookupTable();

  // Description:
  // Paints the tree & associated table as a heatmap.
  virtual bool Paint(vtkContext2D *painter);

private:
  vtkSmartPointer<vtkDendrogramItem> Dendrogram1;
  vtkSmartPointer<vtkDendrogramItem> Dendrogram2;
  vtkSmartPointer<vtkLookupTable> LookupTable;
  vtkSmartPointer<vtkTable> Table;
  vtkStringArray *Tree1Names;
  vtkStringArray *Tree2Names;
  vtkStringArray *SourceNames;
  double Tree1Bounds[4];
  double Tree2Bounds[4];
  double Spacing;
  double LabelWidth1;
  double LabelWidth2;
  bool PositionSet;
  bool TreeReordered;
  char* Tree1Label;
  char* Tree2Label;
  int Orientation;
  int MinimumVisibleFontSize;
  int LabelSizeDifference;
  float CorrespondenceLineWidth;

  vtkTanglegramItem(const vtkTanglegramItem&); // Not implemented
  void operator=(const vtkTanglegramItem&); // Not implemented

};

#endif