aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2020-03-18 21:40:10 +0800
committercrupest <crupest@outlook.com>2020-03-18 21:40:10 +0800
commit068714c0f2fe7ab003462e5483f9944b0bf2f8e0 (patch)
treea16aea1a4414c2763e2d82eabd9bf68d4e44c7fc
parentb129c5a144dfb116082689ffaaa9ac78e2403656 (diff)
downloadcru-068714c0f2fe7ab003462e5483f9944b0bf2f8e0.tar.gz
cru-068714c0f2fe7ab003462e5483f9944b0bf2f8e0.tar.bz2
cru-068714c0f2fe7ab003462e5483f9944b0bf2f8e0.zip
...
-rw-r--r--.gitignore1
-rw-r--r--CMakeLists.txt2
-rw-r--r--include/cru/platform/graph/base.hpp12
-rw-r--r--include/cru/platform/graph/fwd.hpp12
4 files changed, 12 insertions, 15 deletions
diff --git a/.gitignore b/.gitignore
index 058ed33c..122fa5e4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -590,3 +590,4 @@ flycheck_*.el
# End of https://www.gitignore.io/api/emacs
compile_flags.txt
+.clangd
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 62709ec5..34adff17 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -4,7 +4,7 @@ project(CruUI)
enable_testing()
-set(CMAKE_CXX_STANDARD 20)
+set(CMAKE_CXX_STANDARD 17)
if (MSVC)
string(REGEX REPLACE "/W[0-4]\\s*" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
diff --git a/include/cru/platform/graph/base.hpp b/include/cru/platform/graph/base.hpp
index 0b011262..002c2f51 100644
--- a/include/cru/platform/graph/base.hpp
+++ b/include/cru/platform/graph/base.hpp
@@ -3,11 +3,19 @@
#include "../matrix.hpp"
#include "../resource.hpp"
-#include "fwd.hpp"
-
#include <memory>
namespace cru::platform::graph {
+// forward declarations
+struct IGraphFactory;
+struct IBrush;
+struct ISolidColorBrush;
+struct IFont;
+struct IGeometry;
+struct IGeometryBuilder;
+struct IPainter;
+struct ITextLayout;
+
struct TextHitTestResult {
int position;
bool trailing;
diff --git a/include/cru/platform/graph/fwd.hpp b/include/cru/platform/graph/fwd.hpp
deleted file mode 100644
index 508a49fa..00000000
--- a/include/cru/platform/graph/fwd.hpp
+++ /dev/null
@@ -1,12 +0,0 @@
-#pragma once
-
-namespace cru::platform::graph {
-struct IGraphFactory;
-struct IBrush;
-struct ISolidColorBrush;
-struct IFont;
-struct IGeometry;
-struct IGeometryBuilder;
-struct IPainter;
-struct ITextLayout;
-} // namespace cru::platform::graph