File: Polyline.h
 1#ifndef Polyline_h_
 2#define Polyline_h_
 3
 4#include "Path.h"
 5#include <vector>
 6
 7namespace Paths
 8{
 9
10// The Polyline class. It is an ordered set of
11// connected line segments.
12class Polyline : public Path
13{
14public:
15  // Create a new Polyline.
16  //
17  Polyline();
18  // @group Manipulators {
19
20  // Add a new vertex.
21  void add_vertex(const Vertex &);
22  // Remove the vertex at index i.
23  void remove_vertex(size_t i);
24  // }
25  virtual void draw();
26private:
27  // The data...
28  std::vector<Vertex> vertices_;
29};
30
31}
32
33#endif