summaryrefslogtreecommitdiff
path: root/vcl/source/gdi
AgeCommit message (Collapse)Author
2024-08-28cid#1607037 silence Overflowed constantCaolán McNamara
and cid#1606925 Overflowed constant cid#1606695 Overflowed constant Change-Id: I2162e9b5da1f31ea1dfc603d6e60b96d98f82be1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172509 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-27vcl,filter: replace about 5 hard-coded JPEG PDF export qualitysMichael Stahl
... with a constant; depending on whether FilterData is passed, the effective default is either 80 or 90. Change-Id: Iffaf8baf8f0ae8ea1cc96c299e4c415d91f818f8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172469 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> Tested-by: Jenkins
2024-08-26tdf#162603 vcl: Fix sporadic non-subpixel label cutoffJonathan Clark
Fixes an issue causing occasional truncation of the final column of pixels when rendering text without subpixel positioning. Partially reverts commit 560e5406f3c6e8e6ed0f1c251b6910465266ed8d. tdf#153966 vcl: Fix precision loss laying out right-aligned text Change-Id: I9372e842c8bea59dd8e6d87a8b6887ba7e34897b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172388 Tested-by: Jenkins Reviewed-by: Jonathan Clark <jonathan@libreoffice.org>
2024-08-23tdf#159895 sw: fix "Stack empty" error in tagged PDF exportTibor Nagy
Change-Id: I8a2e0d51d1cfe6d4b517f193c73e512600638cf0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172302 Tested-by: Jenkins Reviewed-by: Nagy Tibor <tibor.nagy.extern@allotropia.de>
2024-08-22tdf#153966 vcl: Fix precision loss laying out right-aligned textJonathan Clark
Previously, characters would appear to 'fidget' while typing right-aligned right-to-left text. This fix contains the following changes: - Removed a floating point truncate during right-align positioning. - Removed unnecessary repeated multiply-add from the main layout loop. Change-Id: I2f070efb6a1387db1595b41023bd0f076064afda Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172230 Tested-by: Jenkins Reviewed-by: Jonathan Clark <jonathan@libreoffice.org>
2024-08-19CairoSDPR: Text render needs MultiSalLayout supportArmin Le Grand (Collabora)
Change-Id: I418675012392a9707dc515eb1e05a2689ec902aa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172039 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2024-08-19SalLayout::InitFont doesn't do anythingCaolán McNamara
there is a MultiSalLayout::InitFont that overrides it, but only forwards InitFont to the first child sub SalLayout, which itself then doesn't do anything. This is possibly the case since: commit 6c436ba09cb35235ce6f4065cf74c9a6ff14a4bd Date: Thu Dec 1 03:33:30 2016 +0200 Kill old Windows layout engines Change-Id: Ic0d347843257d13ee6d6f695488bd053f5a931fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172040 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-18cid#1557699 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1557435 COPY_INSTEAD_OF_MOVE cid#1557307 COPY_INSTEAD_OF_MOVE cid#1557209 COPY_INSTEAD_OF_MOVE cid#1557192 COPY_INSTEAD_OF_MOVE cid#1557184 COPY_INSTEAD_OF_MOVE cid#1557183 COPY_INSTEAD_OF_MOVE cid#1557171 COPY_INSTEAD_OF_MOVE cid#1557150 COPY_INSTEAD_OF_MOVE cid#1557148 COPY_INSTEAD_OF_MOVE cid#1557123 COPY_INSTEAD_OF_MOVE cid#1557118 COPY_INSTEAD_OF_MOVE cid#1557116 COPY_INSTEAD_OF_MOVE cid#1557103 COPY_INSTEAD_OF_MOVE cid#1557078 COPY_INSTEAD_OF_MOVE cid#1557075 COPY_INSTEAD_OF_MOVE cid#1557071 COPY_INSTEAD_OF_MOVE cid#1557070 COPY_INSTEAD_OF_MOVE cid#1557067 COPY_INSTEAD_OF_MOVE cid#1557049 COPY_INSTEAD_OF_MOVE cid#1557046 COPY_INSTEAD_OF_MOVE cid#1557042 COPY_INSTEAD_OF_MOVE cid#1557036 COPY_INSTEAD_OF_MOVE cid#1557030 COPY_INSTEAD_OF_MOVE cid#1557024 COPY_INSTEAD_OF_MOVE cid#1557012 COPY_INSTEAD_OF_MOVE cid#1557009 COPY_INSTEAD_OF_MOVE cid#1557008 COPY_INSTEAD_OF_MOVE cid#1557004 COPY_INSTEAD_OF_MOVE cid#1556999 COPY_INSTEAD_OF_MOVE cid#1556992 COPY_INSTEAD_OF_MOVE cid#1556987 COPY_INSTEAD_OF_MOVE cid#1556984 COPY_INSTEAD_OF_MOVE cid#1556981 COPY_INSTEAD_OF_MOVE Change-Id: Id2687aa282f4e2d4b8053b73c7aa1a74a9516b16 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171974 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-16cid#1557618 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1557535 COPY_INSTEAD_OF_MOVE cid#1557520 COPY_INSTEAD_OF_MOVE cid#1557513 COPY_INSTEAD_OF_MOVE cid#1557503 COPY_INSTEAD_OF_MOVE cid#1557487 COPY_INSTEAD_OF_MOVE cid#1557483 COPY_INSTEAD_OF_MOVE cid#1557479 COPY_INSTEAD_OF_MOVE cid#1557474 COPY_INSTEAD_OF_MOVE cid#1557461 COPY_INSTEAD_OF_MOVE cid#1557446 COPY_INSTEAD_OF_MOVE cid#1557445 COPY_INSTEAD_OF_MOVE cid#1557441 COPY_INSTEAD_OF_MOVE cid#1557435 COPY_INSTEAD_OF_MOVE cid#1557433 COPY_INSTEAD_OF_MOVE cid#1557429 COPY_INSTEAD_OF_MOVE cid#1557375 COPY_INSTEAD_OF_MOVE cid#1557372 COPY_INSTEAD_OF_MOVE cid#1557356 COPY_INSTEAD_OF_MOVE cid#1557350 COPY_INSTEAD_OF_MOVE cid#1557344 COPY_INSTEAD_OF_MOVE cid#1557339 COPY_INSTEAD_OF_MOVE cid#1557332 COPY_INSTEAD_OF_MOVE cid#1557330 COPY_INSTEAD_OF_MOVE cid#1557328 COPY_INSTEAD_OF_MOVE cid#1557323 COPY_INSTEAD_OF_MOVE cid#1557315 COPY_INSTEAD_OF_MOVE cid#1557313 COPY_INSTEAD_OF_MOVE cid#1557304 COPY_INSTEAD_OF_MOVE cid#1557297 COPY_INSTEAD_OF_MOVE cid#1557291 COPY_INSTEAD_OF_MOVE cid#1557290 COPY_INSTEAD_OF_MOVE cid#1557271 COPY_INSTEAD_OF_MOVE cid#1557266 COPY_INSTEAD_OF_MOVE cid#1557262 COPY_INSTEAD_OF_MOVE cid#1557259 COPY_INSTEAD_OF_MOVE cid#1557246 COPY_INSTEAD_OF_MOVE cid#1557242 COPY_INSTEAD_OF_MOVE cid#1557241 COPY_INSTEAD_OF_MOVE cid#1557236 COPY_INSTEAD_OF_MOVE cid#1557228 COPY_INSTEAD_OF_MOVE cid#1557225 COPY_INSTEAD_OF_MOVE cid#1557221 COPY_INSTEAD_OF_MOVE cid#1557217 COPY_INSTEAD_OF_MOVE cid#1557213 COPY_INSTEAD_OF_MOVE cid#1557211 COPY_INSTEAD_OF_MOVE cid#1557209 COPY_INSTEAD_OF_MOVE cid#1557205 COPY_INSTEAD_OF_MOVE cid#1557204 COPY_INSTEAD_OF_MOVE cid#1557193 COPY_INSTEAD_OF_MOVE cid#1556082 COPY_INSTEAD_OF_MOVE Change-Id: I07f195a79a69d4bac0d14317854efc88d6fe94d7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171927 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-14cid#1557708 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1557707 COPY_INSTEAD_OF_MOVE cid#1557706 COPY_INSTEAD_OF_MOVE cid#1557705 COPY_INSTEAD_OF_MOVE cid#1557704 COPY_INSTEAD_OF_MOVE Change-Id: I2346348d9d896e352db3471e8137c0eca8b21507 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171861 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-11Related: tdf#154959 suitable label printer paper size not auto-selectedCaolán McNamara
a) If the printer is the default, then it doesn't get a paper size auto selected in the paper combobox, even though the preview shows it rendered on a paper size that the printer supports. b) With that fixed, then if the printer is the default one then right paper gets selected automatically, but starting with another and then switching to it gets different results, so throw away the "page cache" on switching pages and get it again. Change-Id: Idd5254eac2668164b02b41a63943f65a222656d7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171721 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-09we can drop cached text check workaroundCaolán McNamara
the root problem was found as: commit e75a1eb21834fa872864df2cc5811c6463aceb78 Date: Tue Jun 11 11:29:44 2024 +0100 more stale hyphenation data after skipping blanks commit f050103c3324d878b310f37429ea3580a8230905 Date: Fri Jun 7 20:14:15 2024 +0100 stale hyphenation data after skipping blanks Change-Id: Ia92dcb779ef75d15dd47479458154ba04ff1ef52 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170255 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-08tdf#162358 Fix missing fallback run inside grapheme clusterJonathan Clark
This change fixes an issue causing certain diacritics to be rendered as the replacement character. The root cause was failing to consistently populate fallback runs for the first grapheme cluster, when a layout begins inside a grapheme cluster. Change-Id: I7ce368c815d33b26fc05d726d4f4efd050ed9a17 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171607 Reviewed-by: Jonathan Clark <jonathan@libreoffice.org> Tested-by: Jenkins
2024-08-05tdf#155228 vcl: appease Adobe Acrobat Pro, always produce /TabsMichael Stahl
Reportedly Adobe Acrobat Pro complains if any page is missing "/Tabs" even though ISO 14289-1:2014 requires it only for a page with annotations. Change-Id: I84d750da12ca55519aa61c196d2d93aa33f1abad Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171486 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> Tested-by: Jenkins
2024-08-05CairoSDPR: direct text rendering using CairoArmin Le Grand (Collabora)
I have added basic support for the text primitives (TextSimplePortionPrimitive2D) to the SDPR Cairo renderer. It can now basically render Text using a fallback to the already existing CairoTextRender. NOTE: This is not yet complete, but for discussion. Change-Id: I9b0c7b6bb4892905576593ef4e2b4071c7663c63 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171429 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2024-08-02m_aPixelSize should be in pixels, but GetPrefSize depends on GetPrefMapModeCaolán McNamara
i.e later we do: Size aSize = PixelToLogic(rEmit.m_aPixelSize, MapMode(m_aMapMode.GetMapUnit())); and PrefSize is in PrefMapMode units. Change-Id: I387316804496fc0a05c3370f370f5f562c288d77 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171251 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com> (cherry picked from commit de15d0a566ce72f2d508ceb7b3fbf60d2aa31329) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171358 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-08-02cid#1556472 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1556481 COPY_INSTEAD_OF_MOVE cid#1556486 COPY_INSTEAD_OF_MOVE cid#1556491 COPY_INSTEAD_OF_MOVE cid#1556507 COPY_INSTEAD_OF_MOVE cid#1556515 COPY_INSTEAD_OF_MOVE cid#1556518 COPY_INSTEAD_OF_MOVE cid#1556519 COPY_INSTEAD_OF_MOVE cid#1556533 COPY_INSTEAD_OF_MOVE cid#1556536 COPY_INSTEAD_OF_MOVE cid#1556559 COPY_INSTEAD_OF_MOVE cid#1556577 COPY_INSTEAD_OF_MOVE cid#1556581 COPY_INSTEAD_OF_MOVE Change-Id: I2ad2f2194e2a89c7246e8742b2fc8be7580e38c3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171394 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-08-02cid#1556086 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1556087 COPY_INSTEAD_OF_MOVE cid#1556093 COPY_INSTEAD_OF_MOVE cid#1556094 COPY_INSTEAD_OF_MOVE cid#1556105 COPY_INSTEAD_OF_MOVE cid#1556121 COPY_INSTEAD_OF_MOVE cid#1556184 COPY_INSTEAD_OF_MOVE cid#1556399 COPY_INSTEAD_OF_MOVE cid#1556405 COPY_INSTEAD_OF_MOVE cid#1556419 COPY_INSTEAD_OF_MOVE cid#1556421 COPY_INSTEAD_OF_MOVE cid#1556444 COPY_INSTEAD_OF_MOVE cid#1556448 COPY_INSTEAD_OF_MOVE cid#1556457 COPY_INSTEAD_OF_MOVE cid#1556468 COPY_INSTEAD_OF_MOVE Change-Id: I1f352682daebd4e3ed2e7fe669aa0943dcc33edd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171372 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-08-02tdf#162289 Update printer info before getting default printerMichael Weghorn
Move the call to `Printer::updatePrinters` to update the printer infos from the print dialog ctor to the beginning of `Printer::PreparePrintJob` (which is the only method potentially creating a print dialog) to make sure that the printer infos (including the default printer) are already up to date there. This e.g. makes sure that the current CUPS default printer on Linux gets preselected the next time the print dialog gets opened if it was changed while LO is running. (Otherwise, it would only be preselected as expected when the print dialog gets opened, closed and reopened again.) For macOS, there was already code to explicitly call `Printer::updatePrinters` in case the dialog was not shown. Drop that, as it happens unconditionally at the beginning now. Change-Id: I5cd530c0c9801bde88e40f5ac2220feb0e8d4247 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171371 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2024-07-31cid#1555587 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1555589 COPY_INSTEAD_OF_MOVE cid#1555593 COPY_INSTEAD_OF_MOVE cid#1555596 COPY_INSTEAD_OF_MOVE cid#1555602 COPY_INSTEAD_OF_MOVE cid#1555608 COPY_INSTEAD_OF_MOVE cid#1555610 COPY_INSTEAD_OF_MOVE cid#1555620 COPY_INSTEAD_OF_MOVE cid#1555623 COPY_INSTEAD_OF_MOVE cid#1555625 COPY_INSTEAD_OF_MOVE cid#1555626 COPY_INSTEAD_OF_MOVE cid#1555634 COPY_INSTEAD_OF_MOVE cid#1555638 COPY_INSTEAD_OF_MOVE cid#1555667 COPY_INSTEAD_OF_MOVE cid#1555682 COPY_INSTEAD_OF_MOVE cid#1555686 COPY_INSTEAD_OF_MOVE cid#1555702 COPY_INSTEAD_OF_MOVE cid#1555710 COPY_INSTEAD_OF_MOVE cid#1555750 COPY_INSTEAD_OF_MOVE cid#1555752 COPY_INSTEAD_OF_MOVE cid#1555761 COPY_INSTEAD_OF_MOVE cid#1555762 COPY_INSTEAD_OF_MOVE cid#1555771 COPY_INSTEAD_OF_MOVE cid#1555772 COPY_INSTEAD_OF_MOVE cid#1555784 COPY_INSTEAD_OF_MOVE cid#1555785 COPY_INSTEAD_OF_MOVE Change-Id: Ib9724230c05b2027b4edf64e6a0bb5e22a270a88 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171274 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-31tdf#162280 vcl: consider font family type for glyph cachingMiklos Vajna
Open tdf105820-1.doc from crashtesting in a dbgutil build, save as PDF, we assert in checkGlyphsEqual(). This is a problem since commit 6dfac38bacd449c64a13363797b56aff49cf8f52 (tdf#162072 vcl, fontconfig: consider font-family-generic for substitute, 2024-07-18), because now the font name no longer determines the fallback name alone, so 2 paragraphs may share the cached vcl-level text layout, even if the underlying fallback font is different. One would naively expect that in the SalLayoutGlyphsCache::CachedGlyphsKey ctor, the fontMetric.GetFamilyType() already has the correct family type, but it turns out that is always the default, and only outputDevice->GetFont().GetFamilyType() has the up to date setting: debug:12372:12372: SalLayoutGlyphsCache ctor: output device font family name is 'Verdana', output device font family type is roman, font metric family name is 'Verdana', font metric family type is 'swiss' debug:12372:12372: SalLayoutGlyphsCache ctor: output device font family name is 'Verdana', output device font family type is swiss, font metric family name is 'Verdana', font metric family type is 'swiss' Fix the problem by explicitly including the output device font family type in the cache key. Note that this only happens in practice if the same font is used in the document with different family types, which is probably never the intention of the user. E.g. Verdana is meant to be sans, a serif Verdana is some weird corner-case. Change-Id: Id6cc60809a35a3dcdc6e83122a559ddfbe5d5d0c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171280 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2024-07-31cid#1555417 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1555423 COPY_INSTEAD_OF_MOVE cid#1555430 COPY_INSTEAD_OF_MOVE cid#1555436 COPY_INSTEAD_OF_MOVE cid#1555440 COPY_INSTEAD_OF_MOVE cid#1555443 COPY_INSTEAD_OF_MOVE cid#1555454 COPY_INSTEAD_OF_MOVE cid#1555459 COPY_INSTEAD_OF_MOVE cid#1555461 COPY_INSTEAD_OF_MOVE cid#1555468 COPY_INSTEAD_OF_MOVE cid#1555477 COPY_INSTEAD_OF_MOVE cid#1555484 COPY_INSTEAD_OF_MOVE cid#1555511 COPY_INSTEAD_OF_MOVE cid#1555515 COPY_INSTEAD_OF_MOVE cid#1555519 COPY_INSTEAD_OF_MOVE cid#1555534 COPY_INSTEAD_OF_MOVE cid#1555537 COPY_INSTEAD_OF_MOVE cid#1555544 COPY_INSTEAD_OF_MOVE cid#1555553 COPY_INSTEAD_OF_MOVE cid#1555559 COPY_INSTEAD_OF_MOVE cid#1555561 COPY_INSTEAD_OF_MOVE cid#1555563 COPY_INSTEAD_OF_MOVE cid#1555564 COPY_INSTEAD_OF_MOVE cid#1555568 COPY_INSTEAD_OF_MOVE cid#1555571 COPY_INSTEAD_OF_MOVE cid#1555580 COPY_INSTEAD_OF_MOVE Change-Id: Ia42a78bffddc80d0e82144f4db51dc6e4d2e9a1d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171237 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-28cid#1556624 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1556622 COPY_INSTEAD_OF_MOVE cid#1556629 COPY_INSTEAD_OF_MOVE cid#1556632 COPY_INSTEAD_OF_MOVE cid#1556634 COPY_INSTEAD_OF_MOVE cid#1556642 COPY_INSTEAD_OF_MOVE cid#1556644 COPY_INSTEAD_OF_MOVE cid#1556663 COPY_INSTEAD_OF_MOVE cid#1556674 COPY_INSTEAD_OF_MOVE cid#1556682 COPY_INSTEAD_OF_MOVE cid#1556683 COPY_INSTEAD_OF_MOVE cid#1556685 COPY_INSTEAD_OF_MOVE cid#1556694 COPY_INSTEAD_OF_MOVE cid#1556708 COPY_INSTEAD_OF_MOVE cid#1556711 COPY_INSTEAD_OF_MOVE cid#1556712 COPY_INSTEAD_OF_MOVE cid#1556714 COPY_INSTEAD_OF_MOVE cid#1556719 COPY_INSTEAD_OF_MOVE cid#1556727 COPY_INSTEAD_OF_MOVE cid#1556744 COPY_INSTEAD_OF_MOVE cid#1556757 COPY_INSTEAD_OF_MOVE cid#1556782 COPY_INSTEAD_OF_MOVE cid#1556784 COPY_INSTEAD_OF_MOVE Change-Id: I5d5bc884cd7351a81c18b35aaf4e304256242988 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171128 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-07-24cid#1556131 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1556135 COPY_INSTEAD_OF_MOVE cid#1556146 COPY_INSTEAD_OF_MOVE cid#1556164 COPY_INSTEAD_OF_MOVE cid#1556171 COPY_INSTEAD_OF_MOVE cid#1556177 COPY_INSTEAD_OF_MOVE cid#1556181 COPY_INSTEAD_OF_MOVE cid#1556182 COPY_INSTEAD_OF_MOVE cid#1556183 COPY_INSTEAD_OF_MOVE cid#1556192 COPY_INSTEAD_OF_MOVE cid#1556201 COPY_INSTEAD_OF_MOVE cid#1556208 COPY_INSTEAD_OF_MOVE cid#1556215 COPY_INSTEAD_OF_MOVE cid#1556224 COPY_INSTEAD_OF_MOVE cid#1556227 COPY_INSTEAD_OF_MOVE cid#1556228 COPY_INSTEAD_OF_MOVE cid#1556238 COPY_INSTEAD_OF_MOVE cid#1556246 COPY_INSTEAD_OF_MOVE cid#1556247 COPY_INSTEAD_OF_MOVE cid#1556288 COPY_INSTEAD_OF_MOVE cid#1556293 COPY_INSTEAD_OF_MOVE cid#1556305 COPY_INSTEAD_OF_MOVE cid#1556310 COPY_INSTEAD_OF_MOVE cid#1556317 COPY_INSTEAD_OF_MOVE cid#1556321 COPY_INSTEAD_OF_MOVE cid#1556322 COPY_INSTEAD_OF_MOVE cid#1556331 COPY_INSTEAD_OF_MOVE cid#1556339 COPY_INSTEAD_OF_MOVE cid#1556342 COPY_INSTEAD_OF_MOVE cid#1556351 COPY_INSTEAD_OF_MOVE cid#1556358 COPY_INSTEAD_OF_MOVE cid#1556370 COPY_INSTEAD_OF_MOVE cid#1556379 COPY_INSTEAD_OF_MOVE cid#1556390 COPY_INSTEAD_OF_MOVE cid#1556423 COPY_INSTEAD_OF_MOVE cid#1556532 COPY_INSTEAD_OF_MOVE cid#1556561 COPY_INSTEAD_OF_MOVE cid#1556662 COPY_INSTEAD_OF_MOVE cid#1556704 COPY_INSTEAD_OF_MOVE cid#1556730 COPY_INSTEAD_OF_MOVE cid#1556988 COPY_INSTEAD_OF_MOVE cid#1557071 COPY_INSTEAD_OF_MOVE cid#1557081 COPY_INSTEAD_OF_MOVE cid#1557177 COPY_INSTEAD_OF_MOVE Change-Id: I2c723f0fe9a4eefa62a68f47049ed690d06eb0ba Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170932 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-24tdf#157390 Fix overlapping CJK characters in PDF exportJonathan Clark
This change fixes a vertical text glyph metrics regression that was introduced while migrating PDF export to use metrics from HarfBuzz. The root cause was incorrectly caching CJK glyph heights in place of widths for vertical text. Change-Id: I8426fc902658d1c045b42e760028f26b09eeef93 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170935 Tested-by: Jenkins Reviewed-by: Jonathan Clark <jonathan@libreoffice.org>
2024-07-23Resolves: tdf#162161 reexport of specific pdf appears blankCaolán McNamara
the contents of the referenced colorspace obj disappears so it gets rendered blank Change-Id: Iaa76d355b5903c695e74edadc329043156bad3b6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170904 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-23cid#1555167 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1555172 COPY_INSTEAD_OF_MOVE cid#1555184 COPY_INSTEAD_OF_MOVE cid#1555188 COPY_INSTEAD_OF_MOVE cid#1555197 COPY_INSTEAD_OF_MOVE cid#1555209 COPY_INSTEAD_OF_MOVE cid#1555211 COPY_INSTEAD_OF_MOVE cid#1555215 COPY_INSTEAD_OF_MOVE cid#1555216 COPY_INSTEAD_OF_MOVE cid#1555217 COPY_INSTEAD_OF_MOVE cid#1555218 COPY_INSTEAD_OF_MOVE cid#1555222 COPY_INSTEAD_OF_MOVE cid#1556674 COPY_INSTEAD_OF_MOVE cid#1555229 COPY_INSTEAD_OF_MOVE cid#1555233 COPY_INSTEAD_OF_MOVE cid#1555234 COPY_INSTEAD_OF_MOVE cid#1555242 COPY_INSTEAD_OF_MOVE cid#1555250 COPY_INSTEAD_OF_MOVE cid#1555251 COPY_INSTEAD_OF_MOVE cid#1555254 COPY_INSTEAD_OF_MOVE cid#1555304 COPY_INSTEAD_OF_MOVE cid#1555307 COPY_INSTEAD_OF_MOVE cid#1555317 COPY_INSTEAD_OF_MOVE cid#1555329 COPY_INSTEAD_OF_MOVE cid#1555340 COPY_INSTEAD_OF_MOVE cid#1555347 COPY_INSTEAD_OF_MOVE cid#1555352 COPY_INSTEAD_OF_MOVE cid#1555358 COPY_INSTEAD_OF_MOVE cid#1555363 COPY_INSTEAD_OF_MOVE cid#1555365 COPY_INSTEAD_OF_MOVE cid#1555367 COPY_INSTEAD_OF_MOVE cid#1555374 COPY_INSTEAD_OF_MOVE cid#1555380 COPY_INSTEAD_OF_MOVE Change-Id: I343194c10749488a1143e2517ee0638ab19da218 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170888 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-23cid#1555070 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1555069 COPY_INSTEAD_OF_MOVE cid#1555128 COPY_INSTEAD_OF_MOVE cid#1555131 COPY_INSTEAD_OF_MOVE cid#1555137 COPY_INSTEAD_OF_MOVE cid#1555142 COPY_INSTEAD_OF_MOVE cid#1555152 COPY_INSTEAD_OF_MOVE cid#1555154 COPY_INSTEAD_OF_MOVE cid#1555161 COPY_INSTEAD_OF_MOVE cid#1555163 COPY_INSTEAD_OF_MOVE Change-Id: I86a5b7049ac8f31ca703add11381f5293233d9d3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170863 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-20cid#1554791 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1554819 COPY_INSTEAD_OF_MOVE cid#1554837 COPY_INSTEAD_OF_MOVE cid#1554881 COPY_INSTEAD_OF_MOVE cid#1554882 COPY_INSTEAD_OF_MOVE cid#1554884 COPY_INSTEAD_OF_MOVE cid#1554891 COPY_INSTEAD_OF_MOVE cid#1554892 COPY_INSTEAD_OF_MOVE cid#1554897 COPY_INSTEAD_OF_MOVE cid#1554904 COPY_INSTEAD_OF_MOVE cid#1554918 COPY_INSTEAD_OF_MOVE cid#1554928 COPY_INSTEAD_OF_MOVE cid#1554931 COPY_INSTEAD_OF_MOVE cid#1554944 COPY_INSTEAD_OF_MOVE cid#1554945 COPY_INSTEAD_OF_MOVE cid#1554959 COPY_INSTEAD_OF_MOVE cid#1554960 COPY_INSTEAD_OF_MOVE cid#1554963 COPY_INSTEAD_OF_MOVE cid#1554966 COPY_INSTEAD_OF_MOVE cid#1554969 COPY_INSTEAD_OF_MOVE cid#1554973 COPY_INSTEAD_OF_MOVE cid#1555011 COPY_INSTEAD_OF_MOVE cid#1555012 COPY_INSTEAD_OF_MOVE cid#1555015 COPY_INSTEAD_OF_MOVE cid#1555044 COPY_INSTEAD_OF_MOVE cid#1555051 COPY_INSTEAD_OF_MOVE cid#1555055 COPY_INSTEAD_OF_MOVE cid#1555063 COPY_INSTEAD_OF_MOVE cid#1555068 COPY_INSTEAD_OF_MOVE cid#1555073 COPY_INSTEAD_OF_MOVE cid#1555074 COPY_INSTEAD_OF_MOVE cid#1555078 COPY_INSTEAD_OF_MOVE cid#1555080 COPY_INSTEAD_OF_MOVE cid#1555091 COPY_INSTEAD_OF_MOVE cid#1555099 COPY_INSTEAD_OF_MOVE cid#1555101 COPY_INSTEAD_OF_MOVE cid#1555121 COPY_INSTEAD_OF_MOVE cid#1610739 COPY_INSTEAD_OF_MOVE cid#1608424 COPY_INSTEAD_OF_MOVE cid#1608059 COPY_INSTEAD_OF_MOVE cid#1607952 COPY_INSTEAD_OF_MOVE cid#1607653 COPY_INSTEAD_OF_MOVE cid#1607614 COPY_INSTEAD_OF_MOVE cid#1607592 COPY_INSTEAD_OF_MOVE Change-Id: Ie9f922a9fe1b8001dfab31e2741fe8bd5558e442 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170802 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-20Remove now unneeded osl/diagnose.hGabor Kelemen
followup to commit 57c228803e55ed343c6693de7d0857ad7d3cd9e3 Change-Id: Iebfb23bb65e2bf898bf27f367cc9641f47a14cf3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167998 Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de> Tested-by: Jenkins
2024-07-17cid#1555694 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1555695 COPY_INSTEAD_OF_MOVE cid#1555696 COPY_INSTEAD_OF_MOVE cid#1555705 COPY_INSTEAD_OF_MOVE cid#1555711 COPY_INSTEAD_OF_MOVE cid#1555713 COPY_INSTEAD_OF_MOVE cid#1555727 COPY_INSTEAD_OF_MOVE cid#1555742 COPY_INSTEAD_OF_MOVE cid#1555745 COPY_INSTEAD_OF_MOVE cid#1555749 COPY_INSTEAD_OF_MOVE cid#1555760 COPY_INSTEAD_OF_MOVE cid#1555773 COPY_INSTEAD_OF_MOVE cid#1555774 COPY_INSTEAD_OF_MOVE cid#1555778 COPY_INSTEAD_OF_MOVE cid#1555790 COPY_INSTEAD_OF_MOVE cid#1555831 COPY_INSTEAD_OF_MOVE cid#1555847 COPY_INSTEAD_OF_MOVE cid#1555851 COPY_INSTEAD_OF_MOVE cid#1555853 COPY_INSTEAD_OF_MOVE cid#1607763 COPY_INSTEAD_OF_MOVE cid#1607504 COPY_INSTEAD_OF_MOVE Change-Id: I991f15f12e773d325ed9725498df5725b049a858 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170625 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-16tdf#162002 DOCX import, font embed: only discard subset fonts with few glyphsMiklos Vajna
Commit a9f3c11375525a7708378dd3648febc40db1ad20 (tdf#162002 DOCX import: ignore subsetted embedded fonts for editing, 2024-07-12) decided to ignore all subsetted fonts for editing, improve this a little so we only ignore subsetted fonts when they can't even provide an English alphabet in any form (lowercase, uppercase). This avoids the possible problem that a font is marked as subsetted but it's good enough in practice and we would still throw it away for editing. Change-Id: I0bc0e14ffc0c039f029220991bd16d9e3254f059 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170570 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2024-07-16cid#1554709 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1554745 COPY_INSTEAD_OF_MOVE cid#1554758 COPY_INSTEAD_OF_MOVE cid#1554766 COPY_INSTEAD_OF_MOVE cid#1554771 COPY_INSTEAD_OF_MOVE cid#1554787 COPY_INSTEAD_OF_MOVE cid#1554802 COPY_INSTEAD_OF_MOVE cid#1554820 COPY_INSTEAD_OF_MOVE cid#1554828 COPY_INSTEAD_OF_MOVE cid#1554829 COPY_INSTEAD_OF_MOVE cid#1554832 COPY_INSTEAD_OF_MOVE cid#1554842 COPY_INSTEAD_OF_MOVE cid#1554885 COPY_INSTEAD_OF_MOVE Change-Id: I43ec20250a04dc087f3d7fdeafc75f0c1dd0de25 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170542 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-15cid#1607327 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1554706 COPY_INSTEAD_OF_MOVE cid#1554733 COPY_INSTEAD_OF_MOVE cid#1554736 COPY_INSTEAD_OF_MOVE cid#1554738 COPY_INSTEAD_OF_MOVE cid#1554740 COPY_INSTEAD_OF_MOVE Change-Id: I766cff4ef8eb4256d26f51d7d9dc64442c4bc728 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170453 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-07-13tdf#92064 sw: Improve Tibetan layout performanceJonathan Clark
This change includes the following scalability improvements for documents containing extremely long paragraphs: - Reduces the size of layout contexts to account for line breaks. - Disables a misbehaving glyph cache performance optimization for long strings. Change-Id: Ie9a3365076c0d112a7a655988d672a9f4609b42b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170420 Tested-by: Jenkins Reviewed-by: Jonathan Clark <jonathan@libreoffice.org>
2024-07-12cid#1555962 Use of auto that causes a copyCaolán McNamara
and cid#1556100 Use of auto that causes a copy cid#1556199 Use of auto that causes a copy cid#1556239 Use of auto that causes a copy cid#1556313 Use of auto that causes a copy cid#1556373 Use of auto that causes a copy cid#1556680 Use of auto that causes a copy cid#1557020 Use of auto that causes a copy cid#1557099 Use of auto that causes a copy cid#1557251 Use of auto that causes a copy cid#1557334 Use of auto that causes a copy cid#1557468 Use of auto that causes a copy Change-Id: Ib5ab5b33eabcac3d18899ceaaa9119e13b0139f1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170412 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-12cid#1555260 Use of auto that causes a copyCaolán McNamara
Change-Id: I256705562832a408b751b28c0bb133f4561e5522 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170410 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-12Optimize a bitMike Kaganski
Change-Id: I676533742f1a91bb1f68b0098a1d54a93d09c6ec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170402 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-07-12tdf#129244: fix thinkoMike Kaganski
Change-Id: I838dfce7d9d329a938c09a2a114dbafffe149ace Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170405 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
2024-07-12tdf#129244: Let ImpGraphic update its buffer for new pixel sizesMike Kaganski
It used getVectorGraphicReplacement once, getting a bitmap with pixel size that depended on the default device DPI, unrelated to the needed bitmap size. It was not updated later, using the cached bitmap for any requested size. The DPI passed to convertPrimitive2DSequenceToBitmapEx must represent the relation between the vector logic size and the pixel size of the generated bitmap, not the target device DPI. This change introduces VectorGraphicData::getBitmap to obtain a bitmap for any requested pixel size, and uses it every time in the introduced ImpGraphic::updateBitmapFromVectorGraphic method every time it needs a new size of the image. Change-Id: Ife1305821fff28f0cd4070615ab032211a5d8c4f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170391 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-07-09Avoid potential negative array index access to cached text.Michael Meeks
if ((nIndex != 0 || nLen != text.getLength()) && !skipGlyphSubsets) seems unlikely to protect us from this: /opt/rh/devtoolset-12/root/usr/include/c++/12/string_view:239: constexpr const std::basic_string_view<_CharT, _Traits>::value_type& std::basic_string_view<_CharT, _Traits>::operator[](size_type) const [with _CharT = char16_t; _Traits = std::char_traits<char16_t>; const_reference = const char16_t&; size_type = long unsigned int]: Assertion '__pos < this->_M_len' failed. coolwsd[16958] ... SIG Fatal signal received: SIGABRT code: 18446744073709551610 for address: 0x7300004e16 SalLayoutGlyphsCache::GetLayoutGlyphs(VclPtr<OutputDevice const>, rtl::OUString const&, int, int, long, vcl::text::TextLayoutCache const*) /home/collabora/jenkins/workspace/build_core_co-24.04_for_online_snapshot/vcl/source/gdi/impglyphitem.cxx:399 GetTextArray(OutputDevice const&, rtl::OUString const&, KernArray&, int, int, bool, vcl::text::TextLayoutCache const*) /home/collabora/jenkins/workspace/build_core_co-24.04_for_online_snapshot/include/rtl/ref.hxx:128 SwFntObj::GetTextSize(SwDrawTextInfo&) /home/collabora/jenkins/workspace/build_core_co-24.04_for_online_snapshot/sw/source/core/txtnode/fntcache.cxx:766 SwSubFont::GetTextSize_(SwDrawTextInfo&) /home/collabora/jenkins/workspace/build_core_co-24.04_for_online_snapshot/sw/source/core/txtnode/swfont.cxx:1022 SwTextSizeInfo::GetTextSize() const /home/collabora/jenkins/workspace/build_core_co-24.04_for_online_snapshot/sw/source/core/inc/swfont.hxx:314 blind fix - but seeing a lot of these. Change-Id: Icb6ca25e4b8c6ef8a5e5b89dfa01b56bb788378d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168539 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2024-07-09cid#1554702 COPY_INSTEAD_OF_MOVECaolán McNamara
and cid#1554729 COPY_INSTEAD_OF_MOVE Change-Id: I39b5e679ea0adf7d3ab543d828730067aef273f9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170191 Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com> Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-07cid#1545993 COPY_INSTEAD_OF_MOVECaolán McNamara
Change-Id: I3234bce1f3b71f10529d5874552566d7abcb3a95 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170077 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-06cid#1555223 COPY_INSTEAD_OF_MOVECaolán McNamara
Change-Id: I991ea6869a22476d793bf301183ccc984d411a49 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170020 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-07-01cid#1604132 Identical code for different branchesCaolán McNamara
revealed after commit 50f3443d59d457da8dd19e0520f317851f050469 Date: Wed Jun 19 15:21:12 2024 +0900 pdf: remove CHECK_RETURN macro from code Change-Id: I35b7c5493e377f691e783ac09a56b72b8463868c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169787 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
2024-06-28Simplify solar.h a bitMike Kaganski
Use std::copy / std::reverse_copy for double serialization. Also remove __cplusplus conditions, because the header is not included in any C files. And simplify the functions uses, where casts were unneeded. Change-Id: I1d8375e601851231fdffcf52e3f3e3bdcbcbde7f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169706 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-06-27vcl: Remove graph. reader context from {Imp}Graph and GraphicReaderTomaž Vajngerl
This removes the mpContext member variable from ImpGraph, which also make {Get,Set}ReaderContext on Graphic obsolete and is also removed. GraphicFilter and other code is adjusted and simplified. Change-Id: Icd1927d7b1bd4624b523d0f49a4343911ec6cd0a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165214 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2024-06-20loplugin:unusedfieldsNoel Grandin
Change-Id: I4bc67811e228b4806db9f9b9bf9fb0de0eb36de2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169263 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-06-20pdf: remove CHECK_RETURN macro from codeTomaž Vajngerl
Doesn't help with code readability and makes code more complex. Change-Id: I0c1dc421d5fb173e610ab303d7c4f707dc65a093 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169203 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2024-06-05annot: improve PDF annotation export and clean-up PDFNote classTomaž Vajngerl
Add support for exporting more PDF annotation types and props. Prefix member variables in PDFNote class, extract it out of pdfwriter.hxx file into it's own header file. Change-Id: I99fb4cbb0c68fcec6585c9c21d81daaef26344cc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/168418 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>