Age | Commit message (Collapse) | Author |
|
Previously, Writer performed shaping for each span of text separately.
In certain situations, this caused incorrect glyph use, or incorrect
glyph positioning. This change updates Writer so it will also consider
neighboring text while performing shaping.
This change resolves the outstanding duplicates filed against tdf#61444.
As a side effect, this change also fixes tdf#134226.
In addition to the shaping fix, this change implements rendering for
individually-styled glyphs, which is required to fix tdf#71956. However,
this change does not implement diacritic selection, which is also
required for that issue.
Change-Id: Iab4774ffaab5ad6113778c54d02cb260a70c1010
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167699
Reviewed-by: Jonathan Clark <jonathan@libreoffice.org>
Tested-by: Jenkins
|
|
Change-Id: I8fbe02547d5045cfdb5021720b10ddd10106209a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155750
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
|
|
Change-Id: I5695d9ab51eb09929b4c290ceaf7ae2be46f5989
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154504
Tested-by: Jenkins
Reviewed-by: خالد حسني <khaled@libreoffice.org>
|
|
The unnatural DXArray is gone for a while now.
Change-Id: I6cda530f332839e49aa91da2d5e347401c4d159d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154502
Tested-by: Jenkins
Reviewed-by: خالد حسني <khaled@libreoffice.org>
|
|
continue to do rounding to integer, just transported as double,
unless the opt-in TextRenderModeForResolutionIndependentLayout is set,
so this is not intended to create visible changes
though
nRunAdvance = static_cast<tools::Long>(nRunAdvance*fUnitMul + 0.5);
becomes
nRunAdvance = nRunAdvance * fUnitMul;
in MultiSalLayout::ImplAdjustMultiLayout which might create a
difference, but it is in the glyph fallback case where things are a last
ditch effort already
Change-Id: Iebd4ff9a602d0fa29a5253d73e6372d274d0c8c9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138565
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Communicate Kashida insertion positions in an explicit way.
Rest of LibreOffice communicate adjustments to character widths (e.g.
for justification or spacing) using so-called DX array. DX array is an
array of absolute character positions (e.g. DX[n] is the position after
character n from the start of the lines, and its widths is DX[n] -
DX[n-1]).
This DX array is modified also when Kashidas are inserted after a given
character for Arabic justification, by expanding its width. VCL would
use this to know where to insert the Kashidas and how many ones.
But because DX array is used for both widths adjustments and kashida
insertion, this turns out to be a source of bugs since VCL has tosecond
guess the DX array to find which is pure width adjustment and which also
involves Kashida insertion, and the heuristics it uses are fragile.
This change adds a second array of booleans that records where Kashida
is inserted and communicates it all the way from where Kashida insertion
is decoded in Writer and down to VCL layout.
This change passes the Kashida array only when it seems necessary (e.g.
during drawing but not when measuring text since the DX array is enough
in this case). Hopefully no places where Kashida insertion needs to be
passed down were missed.
A couple of glyph and layout flags that were used for old heuristics and
no longer needed and are removed.
This also fixes:
tdf#87731
tdf#106309
tdf#108604
tdf#112849
tdf#114257
tdf#127176
tdf#145647
tdf#146199
Change-Id: I4ed0850ef2fdc3e9143341afac649e7e7d463c39
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138068
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I9ddb786eb88213c53cf53067ced6899ca40ac6e8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137000
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I4f7183f2f038bcc780e9438b04ee4d15b945d065
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128489
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
When rendering in ResolutionIndependentLayout mode keep the scaled
glyph positions as floating point all the way down to the renderer
Change-Id: I02415f18c26737a886751972f472b499a25c776b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128379
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
|
|
Add unit tests for ImplLayoutArgs. Also add to the vcl::text namespace.
Change-Id: I9fa0943548be8ca17ea3dac104e9cb609337a70e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121209
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|