diff options
Diffstat (limited to 'include/cru/platform/win/win_text_layout.hpp')
-rw-r--r-- | include/cru/platform/win/win_text_layout.hpp | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/include/cru/platform/win/win_text_layout.hpp b/include/cru/platform/win/win_text_layout.hpp new file mode 100644 index 00000000..68961dd7 --- /dev/null +++ b/include/cru/platform/win/win_text_layout.hpp @@ -0,0 +1,24 @@ +#pragma once +#include "win_pre_config.hpp" + +#include "../text_layout.hpp" +#include "win_font.hpp" + +#include <memory> + +namespace cru::platform::win { +class WinTextLayout : public Object, public virtual TextLayout { + public: + explicit WinTextLayout(std::shared_ptr<WinFontDescriptor> font); + WinTextLayout(const WinTextLayout& other) = delete; + WinTextLayout(WinTextLayout&& other) = delete; + WinTextLayout& operator=(const WinTextLayout& other) = delete; + WinTextLayout& operator=(WinTextLayout&& other) = delete; + ~WinTextLayout() override; + + IDWriteTextLayout* GetDWriteTextLayout() const { return text_layout_.Get(); } + + private: + Microsoft::WRL::ComPtr<IDWriteTextLayout> text_layout_; +}; +} // namespace cru::platform::win |