Newer
Older
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
#include <LineStyle.h>
LineStyle :: LineStyle(int ID, string name, string rgb, int type, float width) :
ID_(ID),
name_(name),
rgb_(rgb),
type_(type),
width_(width)
{
}
void LineStyle :: type(int t)
{
type_ = t;
}
void LineStyle :: width(float w)
{
width_ = w;
}
string LineStyle :: name()
{
return name_;
}
string LineStyle :: style()
{
stringstream ID, type, width;
/*
stringstream ID(ID_);
stringstream type(type_);
stringstream width(width_);
*/
ID << ID_;
type << type_;
width << width_;
string style = "set style line " + ID.str() + " lc rgb '" + rgb_ + "' lt " + type.str() + " lw " + width.str();
}