From 7ee2a70c18f899a4845621622241adc578b0400c Mon Sep 17 00:00:00 2001 From: Neil Date: Wed, 23 May 2018 15:41:59 +1000 Subject: Add definitions for bidirectional support to Platform.h and provide empty implementations for each platform. --- gtk/PlatGTK.cxx | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'gtk') diff --git a/gtk/PlatGTK.cxx b/gtk/PlatGTK.cxx index 0f5ea58d9..ce0863462 100644 --- a/gtk/PlatGTK.cxx +++ b/gtk/PlatGTK.cxx @@ -166,6 +166,10 @@ public: void Ellipse(PRectangle rc, ColourDesired fore, ColourDesired back) override; void Copy(PRectangle rc, Point from, Surface &surfaceSource) override; + size_t PositionFromX(const IScreenLine *screenLine, XYPOSITION xDistance, bool charPosition) override; + XYPOSITION XFromPosition(const IScreenLine *screenLine, size_t caretPosition) override; + std::vector FindRangeIntervals(const IScreenLine *screenLine, size_t start, size_t end) override; + void DrawTextBase(PRectangle rc, Font &font_, XYPOSITION ybase, std::string_view text, ColourDesired fore); void DrawTextNoClip(PRectangle rc, Font &font_, XYPOSITION ybase, std::string_view text, ColourDesired fore, ColourDesired back) override; void DrawTextClipped(PRectangle rc, Font &font_, XYPOSITION ybase, std::string_view text, ColourDesired fore, ColourDesired back) override; @@ -183,6 +187,7 @@ public: void SetUnicodeMode(bool unicodeMode_) override; void SetDBCSMode(int codePage) override; + void SetBidiR2L(bool bidiR2L_) override; }; } @@ -625,6 +630,18 @@ void SurfaceImpl::Copy(PRectangle rc, Point from, Surface &surfaceSource) { } } +size_t SurfaceImpl::PositionFromX(const IScreenLine *, XYPOSITION, bool) { + return 0; +} + +XYPOSITION SurfaceImpl::XFromPosition(const IScreenLine *, size_t) { + return 0; +} + +std::vector SurfaceImpl::FindRangeIntervals(const IScreenLine *, size_t, size_t) { + return std::vector(); +} + std::string UTF8FromLatin1(std::string_view text) { std::string utfForm(text.length()*2 + 1, '\0'); size_t lenU = 0; @@ -954,6 +971,9 @@ void SurfaceImpl::SetDBCSMode(int codePage) { et = dbcs; } +void SurfaceImpl::SetBidiR2L(bool) { +} + Surface *Surface::Allocate(int) { return new SurfaceImpl(); } -- cgit v1.2.3