summaryrefslogtreecommitdiff
path: root/include/vcl/vcllayout.hxx
diff options
context:
space:
mode:
authorKhaled Hosny <khaled@aliftype.com>2022-08-12 02:12:04 +0200
committerCaolán McNamara <caolanm@redhat.com>2022-08-14 21:11:52 +0200
commit5e2b7a656024b621bdeeb6efd977331191b66d9d (patch)
treec81dc99f67ff3ab67aa8d305c5da7a1d308ad504 /include/vcl/vcllayout.hxx
parent72e56537d4bb9411229346da977d1d669ccfca9a (diff)
Streamline Kashida validation logic
We are asked to validate the position *after* which Kashida will be inserted, but HarfBuzz will tell us which glyph we can insert Kashida *before*. So align both by passing down the position before and after and make the loop iterating over glyph items a lot simpler. As a bonus, the new code allow Kashida insertion across layout change in both sides, old code allowed it only at the start of the layout. Change-Id: I9f632610b92c0f4c512e50456bf7d207175f17ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138168 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'include/vcl/vcllayout.hxx')
-rw-r--r--include/vcl/vcllayout.hxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/vcl/vcllayout.hxx b/include/vcl/vcllayout.hxx
index 87d9345f4b9b..cbadb47ee0ba 100644
--- a/include/vcl/vcllayout.hxx
+++ b/include/vcl/vcllayout.hxx
@@ -92,7 +92,7 @@ public:
virtual DeviceCoordinate FillDXArray( std::vector<DeviceCoordinate>* pDXArray ) const = 0;
virtual DeviceCoordinate GetTextWidth() const { return FillDXArray( nullptr ); }
virtual void GetCaretPositions( int nArraySize, sal_Int32* pCaretXArray ) const = 0;
- virtual bool IsKashidaPosValid ( int /*nCharPos*/ ) const { return true; } // i60594
+ virtual bool IsKashidaPosValid ( int /*nCharPos*/, int /*nNextCharPos*/ ) const = 0; // i60594
// methods using glyph indexing
virtual bool GetNextGlyph(const GlyphItem** pGlyph, DevicePoint& rPos, int& nStart,