This file is indexed.

/usr/include/choreonoid-1.1/cnoid/src/Base/GraphWidget.h is in libcnoid-dev 1.1.0+dfsg-6.1+b4.

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
/**
   @author Shin'ichiro Nakaoka
*/

#ifndef CNOID_GUIBASE_GRAPH_WIDGET_H_INCLUDED
#define CNOID_GUIBASE_GRAPH_WIDGET_H_INCLUDED

#include <cnoid/Archive>
#include <string>
#include <vector>
#include <boost/shared_ptr.hpp>
#include <boost/function.hpp>
#include <boost/signals.hpp>
#include <QWidget>
#include <QLabel>

#include "exportdecl.h"


namespace cnoid {

    class View;
    class ToolBar;
    class Archive;
    class GraphDataHandler;
    class GraphDataHandlerImpl;
    class GraphWidgetImpl;
    
    typedef boost::shared_ptr<GraphDataHandler> GraphDataHandlerPtr;
    
    class CNOID_EXPORT GraphDataHandler
    {
      public:

        GraphDataHandler();
        ~GraphDataHandler();

        void setColor(float r, float g, float b);
        void setLabel(const std::string& label);
        void setFrameProperties(int numFrames, double frameRate, double offset = 0.0);

        void setValueLimits(double lower, double upper);
        void setVelocityLimits(double lower, double upper);

        void addVerticalLine(double x, const std::string& label);
        void addHorizontalLine(double y, const std::string& label);
        void clearLines();
        
        void update();

        typedef boost::function<void(int frame, int size, double* out_values)> DataRequestCallback;
        void setDataRequestCallback(DataRequestCallback callback);

        typedef boost::function<void(int frame, int size, double* values)> DataModifiedCallback;
        void setDataModifiedCallback(DataModifiedCallback callback);

      private:
        
        friend class GraphWidgetImpl;

        GraphDataHandlerImpl* impl;
    };


    class CNOID_EXPORT GraphWidget : public QWidget, public boost::signals::trackable
    {
      public:

        GraphWidget(View* parentView);
        ~GraphWidget();

        void addDataHandler(GraphDataHandlerPtr handler);
        void clearDataHandlers();

        void setRenderingTypes(bool showOriginalValues, bool showVelocities, bool showAccelerations);
        void getRenderingTypes(bool& showOriginalValues, bool& showVelocities, bool& showAccelerations);

        bool setCursorPosition(double pos);

        void setTimeBarSyncMode(bool on);
        bool isTimeBarSyncMode();
        
        enum ScrollMode { OFF, CONTINUOUS, PAGE };
        void setAutoScrollMode(ScrollMode on);
        ScrollMode autoScrollMode();
        
        void setVerticalValueRange(double lower, double upper);
        void getVerticalValueRange(double& lower, double& upper);

        void setLineWidth(double width);
        double getLineWidth();

        void showRulers(bool show);
        bool showsRulers();
        
        void showLimits(bool show);
        bool showsLimits();
        
        void showGrid(bool show);
        bool showsGrid();
        
        void setGridSize(double width, double height);
        void getGridSize(double& width, double& height);
        
        void setControlPointStep(int step, int offset = 0);
        void getControlPointStep(int& step, int& offset);
        
        void highlightControlPoints(bool on);
        bool highlightsControlPoints();

        enum Mode { VIEW_MODE, EDIT_MODE };
        void changeMode(Mode mode);
        Mode mode();

        enum EditMode { FREE_LINE_MODE, LINE_MODE };
        void changeEditMode(EditMode mode);
        EditMode editMode();

        QLabel& statusLabel();

        virtual bool storeState(Archive& archive);
        virtual bool restoreState(const Archive& archive);

      protected:
        virtual bool eventFilter(QObject* obj, QEvent* event);

      private:

        friend class GraphDataHandler;
        
        GraphWidgetImpl* impl;
    };

}


#endif