diff options
Diffstat (limited to 'include/cru/osx/graphics/quartz')
-rw-r--r-- | include/cru/osx/graphics/quartz/Brush.hpp | 4 | ||||
-rw-r--r-- | include/cru/osx/graphics/quartz/Factory.hpp | 10 | ||||
-rw-r--r-- | include/cru/osx/graphics/quartz/Font.hpp | 2 | ||||
-rw-r--r-- | include/cru/osx/graphics/quartz/Geometry.hpp | 4 | ||||
-rw-r--r-- | include/cru/osx/graphics/quartz/Painter.hpp | 2 | ||||
-rw-r--r-- | include/cru/osx/graphics/quartz/Resource.hpp | 8 | ||||
-rw-r--r-- | include/cru/osx/graphics/quartz/TextLayout.hpp | 2 |
7 files changed, 20 insertions, 12 deletions
diff --git a/include/cru/osx/graphics/quartz/Brush.hpp b/include/cru/osx/graphics/quartz/Brush.hpp index 1b5fd7e4..11f05292 100644 --- a/include/cru/osx/graphics/quartz/Brush.hpp +++ b/include/cru/osx/graphics/quartz/Brush.hpp @@ -11,7 +11,7 @@ namespace cru::platform::graphics::osx::quartz { class QuartzBrush : public OsxQuartzResource, public virtual IBrush { public: - QuartzBrush(IGraphFactory* graphics_factory) + QuartzBrush(IGraphicsFactory* graphics_factory) : OsxQuartzResource(graphics_factory) {} CRU_DELETE_COPY(QuartzBrush) CRU_DELETE_MOVE(QuartzBrush) @@ -24,7 +24,7 @@ class QuartzBrush : public OsxQuartzResource, public virtual IBrush { class QuartzSolidColorBrush : public QuartzBrush, public virtual ISolidColorBrush { public: - QuartzSolidColorBrush(IGraphFactory* graphics_factory, const Color& color); + QuartzSolidColorBrush(IGraphicsFactory* graphics_factory, const Color& color); CRU_DELETE_COPY(QuartzSolidColorBrush) CRU_DELETE_MOVE(QuartzSolidColorBrush) diff --git a/include/cru/osx/graphics/quartz/Factory.hpp b/include/cru/osx/graphics/quartz/Factory.hpp index 5346d039..454b2388 100644 --- a/include/cru/osx/graphics/quartz/Factory.hpp +++ b/include/cru/osx/graphics/quartz/Factory.hpp @@ -5,7 +5,7 @@ namespace cru::platform::graphics::osx::quartz { class QuartzGraphicsFactory : public OsxQuartzResource, - public virtual IGraphFactory { + public virtual IGraphicsFactory { public: QuartzGraphicsFactory() : OsxQuartzResource(this) {} @@ -16,5 +16,13 @@ class QuartzGraphicsFactory : public OsxQuartzResource, public: std::unique_ptr<ISolidColorBrush> CreateSolidColorBrush() override; + + std::unique_ptr<IGeometryBuilder> CreateGeometryBuilder() override; + + std::unique_ptr<IFont> CreateFont(String font_family, + float font_size) override; + + std::unique_ptr<ITextLayout> CreateTextLayout(std::shared_ptr<IFont> font, + String text) override; }; } // namespace cru::platform::graphics::osx::quartz diff --git a/include/cru/osx/graphics/quartz/Font.hpp b/include/cru/osx/graphics/quartz/Font.hpp index 618c4c48..75eeff60 100644 --- a/include/cru/osx/graphics/quartz/Font.hpp +++ b/include/cru/osx/graphics/quartz/Font.hpp @@ -8,7 +8,7 @@ namespace cru::platform::graphics::osx::quartz { class OsxCTFont : public OsxQuartzResource, public virtual IFont { public: - OsxCTFont(IGraphFactory* graphics_factory, const String& name, float size); + OsxCTFont(IGraphicsFactory* graphics_factory, const String& name, float size); CRU_DELETE_COPY(OsxCTFont) CRU_DELETE_MOVE(OsxCTFont) diff --git a/include/cru/osx/graphics/quartz/Geometry.hpp b/include/cru/osx/graphics/quartz/Geometry.hpp index 0c8f840f..565c5b86 100644 --- a/include/cru/osx/graphics/quartz/Geometry.hpp +++ b/include/cru/osx/graphics/quartz/Geometry.hpp @@ -9,7 +9,7 @@ namespace cru::platform::graphics::osx::quartz { class QuartzGeometry : public OsxQuartzResource, public virtual IGeometry { public: - QuartzGeometry(IGraphFactory *graphics_factory, CGPathRef cg_path); + QuartzGeometry(IGraphicsFactory *graphics_factory, CGPathRef cg_path); CRU_DELETE_COPY(QuartzGeometry) CRU_DELETE_MOVE(QuartzGeometry) @@ -27,7 +27,7 @@ class QuartzGeometry : public OsxQuartzResource, public virtual IGeometry { class QuartzGeometryBuilder : public OsxQuartzResource, public virtual IGeometryBuilder { public: - explicit QuartzGeometryBuilder(IGraphFactory *graphics_factory); + explicit QuartzGeometryBuilder(IGraphicsFactory *graphics_factory); CRU_DELETE_COPY(QuartzGeometryBuilder) CRU_DELETE_MOVE(QuartzGeometryBuilder) diff --git a/include/cru/osx/graphics/quartz/Painter.hpp b/include/cru/osx/graphics/quartz/Painter.hpp index 5dcc49dc..9a3df187 100644 --- a/include/cru/osx/graphics/quartz/Painter.hpp +++ b/include/cru/osx/graphics/quartz/Painter.hpp @@ -10,7 +10,7 @@ namespace cru::platform::graphics::osx::quartz { class QuartzCGContextPainter : public OsxQuartzResource, public virtual IPainter { public: - explicit QuartzCGContextPainter(IGraphFactory* graphics_factory, + explicit QuartzCGContextPainter(IGraphicsFactory* graphics_factory, CGContextRef cg_context) : OsxQuartzResource(graphics_factory), cg_context_(cg_context) {} diff --git a/include/cru/osx/graphics/quartz/Resource.hpp b/include/cru/osx/graphics/quartz/Resource.hpp index 2d3b4b08..d7038274 100644 --- a/include/cru/osx/graphics/quartz/Resource.hpp +++ b/include/cru/osx/graphics/quartz/Resource.hpp @@ -5,9 +5,9 @@ namespace cru::platform::graphics::osx::quartz { class OsxQuartzResource : public platform::osx::OsxResource, - public virtual IGraphResource { + public virtual IGraphicsResource { public: - explicit OsxQuartzResource(IGraphFactory* graphics_factory) + explicit OsxQuartzResource(IGraphicsFactory* graphics_factory) : graphics_factory_(graphics_factory) {} CRU_DELETE_COPY(OsxQuartzResource) @@ -17,9 +17,9 @@ class OsxQuartzResource : public platform::osx::OsxResource, public: String GetPlatformId() const override { return u"OSX Quartz"; } - IGraphFactory* GetGraphFactory() override; + IGraphicsFactory* GetGraphicsFactory() override; private: - IGraphFactory* graphics_factory_; + IGraphicsFactory* graphics_factory_; }; } // namespace cru::platform::graphics::osx::quartz diff --git a/include/cru/osx/graphics/quartz/TextLayout.hpp b/include/cru/osx/graphics/quartz/TextLayout.hpp index adcf3b0c..96aabf90 100644 --- a/include/cru/osx/graphics/quartz/TextLayout.hpp +++ b/include/cru/osx/graphics/quartz/TextLayout.hpp @@ -10,7 +10,7 @@ namespace cru::platform::graphics::osx::quartz { class OsxCTTextLayout : public OsxQuartzResource, public virtual ITextLayout { public: - OsxCTTextLayout(IGraphFactory* graphics_factory, + OsxCTTextLayout(IGraphicsFactory* graphics_factory, std::shared_ptr<OsxCTFont> font, const String& str); CRU_DELETE_COPY(OsxCTTextLayout) |