summaryrefslogtreecommitdiff
path: root/editor/doc/doc_data.h
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-03-05 16:44:50 +0100
committerRémi Verschelde <rverschelde@gmail.com>2017-03-05 16:44:50 +0100
commit5dbf1809c6e3e905b94b8764e99491e608122261 (patch)
tree5e5a5360db15d86d59ec8c6e4f7eb511388c5a9a /editor/doc/doc_data.h
parent45438e9918d421b244bfd7776a30e67dc7f2d3e3 (diff)
A Whole New World (clang-format edition)
I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
Diffstat (limited to 'editor/doc/doc_data.h')
-rw-r--r--editor/doc/doc_data.h36
1 files changed, 15 insertions, 21 deletions
diff --git a/editor/doc/doc_data.h b/editor/doc/doc_data.h
index 7601013979..b4bd63e6ee 100644
--- a/editor/doc/doc_data.h
+++ b/editor/doc/doc_data.h
@@ -29,12 +29,11 @@
#ifndef DOC_DATA_H
#define DOC_DATA_H
-
-#include "variant.h"
-#include "map.h"
#include "io/xml_parser.h"
+#include "map.h"
+#include "variant.h"
-class DocData {
+class DocData {
public:
struct ArgumentDoc {
@@ -50,8 +49,8 @@ public:
String qualifiers;
String description;
Vector<ArgumentDoc> arguments;
- bool operator<(const MethodDoc& p_md) const {
- return name<p_md.name;
+ bool operator<(const MethodDoc &p_md) const {
+ return name < p_md.name;
}
};
@@ -68,13 +67,13 @@ public:
String type;
String brief_description;
String description;
- String setter,getter;
- bool operator<(const PropertyDoc& p_prop) const {
- return name<p_prop.name;
+ String setter, getter;
+ bool operator<(const PropertyDoc &p_prop) const {
+ return name < p_prop.name;
}
};
- struct ClassDoc {
+ struct ClassDoc {
String name;
String inherits;
@@ -86,26 +85,21 @@ public:
Vector<ConstantDoc> constants;
Vector<PropertyDoc> properties;
Vector<PropertyDoc> theme_properties;
-
};
String version;
- Map<String,ClassDoc> class_list;
+ Map<String, ClassDoc> class_list;
Error _load(Ref<XMLParser> parser);
-
public:
-
- void merge_from(const DocData& p_data);
- void remove_from(const DocData& p_data);
- void generate(bool p_basic_types=false);
- Error load(const String& p_path);
- Error save(const String& p_path);
+ void merge_from(const DocData &p_data);
+ void remove_from(const DocData &p_data);
+ void generate(bool p_basic_types = false);
+ Error load(const String &p_path);
+ Error save(const String &p_path);
Error load_compressed(const uint8_t *p_data, int p_compressed_size, int p_uncompressed_size);
-
-
};
#endif // DOC_DATA_H