Set clang-format macro indent.

1) Set clang-format macro indent.
2) Run clang-format on every files.
This commit is contained in:
ArthurSonzogni
2020-03-23 21:26:00 +01:00
parent 9e71c467f6
commit 493e734680
30 changed files with 110 additions and 104 deletions

View File

@@ -29,7 +29,8 @@ class Node {
// Step 3: Draw this element.
virtual void Render(Screen& screen);
std::vector<std::unique_ptr<Node>> children;
std::vector<std::unique_ptr<Node>> children;
protected:
Requirement requirement_;
Box box_;

View File

@@ -7,10 +7,16 @@ namespace ftxui {
struct Requirement {
// The required size to fully draw the element.
struct { int x = 0; int y = 0; } min;
struct {
int x = 0;
int y = 0;
} min;
// How much flexibility is given to the component.
struct { int x = 0; int y = 0; } flex;
struct {
int x = 0;
int y = 0;
} flex;
// Frame.
enum Selection {
@@ -21,6 +27,6 @@ struct Requirement {
Box selected_box;
};
} // namespace ftxui
} // namespace ftxui
#endif /* end of include guard: FTXUI_REQUIREMENT_HPP */

View File

@@ -10,7 +10,7 @@ inline void Merge(Elements& container, Element element) {
template <>
inline void Merge(Elements& container, Elements elements) {
for(auto& element : elements)
for (auto& element : elements)
container.push_back(std::move(element));
}
@@ -23,8 +23,8 @@ Elements unpack(Args... args) {
}
// Make |container| able to take any number of argments.
#define TAKE_ANY_ARGS(container) \
template <class... Args> \
Element container(Args... children) { \
return container(unpack(std::forward<Args>(children)...)); \
}
#define TAKE_ANY_ARGS(container) \
template <class... Args> \
Element container(Args... children) { \
return container(unpack(std::forward<Args>(children)...)); \
}