Welcome to mirror list, hosted at ThFree Co, Russian Federation.

BLI_dot_export_attribute_enums.h « blenlib « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 3e7f1d7623d0bd18fb62fc6749501dff2c252a04 (plain)
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
#ifndef __BLI_DOT_EXPORT_ATTRIBUTE_ENUMS_H__
#define __BLI_DOT_EXPORT_ATTRIBUTE_ENUMS_H__

#include "BLI_string_ref.h"

namespace BLI {
namespace DotExport {

namespace Attr_rankdir {
enum Enum {
  LeftToRight,
  TopToBottom,
};

static StringRef to_string(Enum value)
{
  switch (value) {
    case LeftToRight:
      return "LR";
    case TopToBottom:
      return "TB";
  }
  return "";
}
}  // namespace Attr_rankdir

namespace Attr_shape {
enum Enum {
  Rectangle,
  Ellipse,
  Circle,
  Point,
  Diamond,
  Square,
};

static StringRef to_string(Enum value)
{
  switch (value) {
    case Rectangle:
      return "rectangle";
    case Ellipse:
      return "ellipse";
    case Circle:
      return "circle";
    case Point:
      return "point";
    case Diamond:
      return "diamond";
    case Square:
      return "square";
  }
  return "";
}
}  // namespace Attr_shape

namespace Attr_arrowType {
enum Enum {
  Normal,
  Inv,
  Dot,
  None,
  Empty,
  Box,
  Vee,
};

static StringRef to_string(Enum value)
{
  switch (value) {
    case Normal:
      return "normal";
    case Inv:
      return "inv";
    case Dot:
      return "dot";
    case None:
      return "none";
    case Empty:
      return "empty";
    case Box:
      return "box";
    case Vee:
      return "vee";
  }
  return "";
}
}  // namespace Attr_arrowType

namespace Attr_dirType {
enum Enum { Forward, Back, Both, None };

static StringRef to_string(Enum value)
{
  switch (value) {
    case Forward:
      return "forward";
    case Back:
      return "back";
    case Both:
      return "both";
    case None:
      return "none";
  }
  return "";
}
}  // namespace Attr_dirType

}  // namespace DotExport
}  // namespace BLI

#endif /* __BLI_DOT_EXPORT_ATTRIBUTE_ENUMS_H__ */