Commit Graph
26046 Commits
Author SHA1 Message Date
Andreas Heinisch 970058a668 tdf#170842 - Check for missing table style info on plain database ranges
Change-Id: I8bed747726bd729fcef9b3845c8ba3e62f2ca2a7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211786
Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
Tested-by: Jenkins
2026-10-05 21:15:16 +02:00
Andrea Gelmini 9117ca006d Fix typo
Change-Id: I8be529ff62c2295c7b8d1cd72d101f8cebe365c5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211816
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2026-10-05 17:08:19 +02:00
Laurent Balland 77478ebbcc tdf#171207 Remove right clic to other navigation buttons
After adding a new button in the TabBar with
https://gerrit.libreoffice.org/210677
right clic is useless for any button of the TabBar

Make some cleanup to remove unused functions

Change-Id: Id141c077583e6d3ea774b902046e871af2b8936a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211778
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2026-10-05 14:07:46 +02:00
Armin Le Grand (collabora) 5519a3d407 Correct StyleSheet handling when cloning to different Model II
Until now the 'local' StyleSheet got set, but that may
not be the same as the original. It was/gets identified just
by searching by name and type, not comparing content.

What to do? We could...

(a) the Style-Friendly way:
 - check if StyleSheet is identical
  - if not, create a new in-between StyleSheet hosting missing Items
  - if yes, use, done.

(b) the pragmatic/practical way:
 - Just hard-attribute the Items that are detected as different
   similar to what BurnInStyleSheetAttributes does/did, but only
   for a view differing Items

(b) is the most simple for now, but will lead to more hard
attributes. The other possibilities will be better in the
long term. For now, I will use (b).

Note that there are more cases in that VERY complex and grown
stuff emerging from SdDrawDocument::PasteBookmarkAsPage. More
things will need to be fixed, see this as a 1st step.

Needed to adapt postProcessAfterCloneToDifferentModel due to
UT testTdf96206 failing, see comment there for details.

That 1st implementation showed weaknesses with those Items
critical and only on MasterPages, so decided to give up on
that and implement ContentCompare to SdPage::Equals. That
was easier than thought: No parameter needed, only used by
InsertBookmarkAsPage_FindDuplicateLayouts::operator(). Thus,
SdPage::Equals needs no change, just SdrObject::Equals.

Due to still problems with Items corrected in Objects on
MasterPages I will for now exclude this.

Could now isolate remaining problems, these are defaults
and/or PresObj things on MasterPages. Important is that I can
completely correct all Items for all Objects in
postProcessAfterCloneToDifferentModel. I can react to these
false-positives in the ContentCompare in SdrObject::Equals.

Signed-off-by: Armin Le Grand (collabora) <Armin.LeGrand@collabora.com>
Change-Id: I10e17c8d6a893dbe92ab716182f07bafce1f3284
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/6595
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Armin Le Grand <armin.legrand@collabora.com>
(cherry picked from commit 92ffaeac04c5c8586006b026f29ce12fba3674f1)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211729
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-10-05 08:52:54 +02:00
Stephan Bergmann 1c0b50766a Fix heap-use-after-free
...as seen once during JunitTest_forms_complex,

> ==2007790==ERROR: AddressSanitizer: heap-use-after-free on address 0x7ccbfe8b3a38 at pc 0x7f5c5361ed51 bp 0x7b5bd4ac7420 sp 0x7b5bd4ac7418
> READ of size 2 at 0x7ccbfe8b3a38 thread T8
>  #0 in SfxItemPool::IsInRange(unsigned short) const at engine/include/svl/itempool.hxx:331:66
>  #1 in SfxItemPool::getTargetPool(unsigned short) const at engine/svl/source/items/itempool.cxx:452:9
>  #2 in SfxItemPool::CheckItemInfoFlag(unsigned short, unsigned short) const at engine/svl/source/items/itempool.cxx:461:26
>  #3 in SfxItemPool::NeedsSurrogateSupport(unsigned short) const at engine/include/svl/itempool.hxx:343:18
>  #4 in SfxItemSet::checkRemovePoolRegistration(SfxPoolItem const*) at engine/svl/source/items/itemset.cxx:384:20
>  #5 in SfxItemSet::ClearSingleItem_PrepareRemove(SfxPoolItem const*) at engine/svl/source/items/itemset.cxx:364:5
>  #6 in SfxItemSet::ClearAllItemsImpl() at engine/svl/source/items/itemset.cxx:443:9
>  #7 in SfxItemSet::~SfxItemSet() at engine/svl/source/items/itemset.cxx:318:5
>  #8 in std::_Optional_payload_base<SfxItemSet>::_M_destroy() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/optional:305:23
>  #9 in std::_Optional_payload_base<SfxItemSet>::_M_reset() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/optional:341:4
>  #10 in std::_Optional_payload<SfxItemSet, false, false, false>::~_Optional_payload() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/optional:464:57
>  #11 in std::_Optional_base<SfxItemSet, false, false>::~_Optional_base() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/optional:488:12
>  #12 in std::optional<SfxItemSet>::~optional() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/optional:781:11
>  #13 in sdr::properties::DefaultProperties::~DefaultProperties() at engine/svx/source/sdr/properties/defaultproperties.cxx:92:50
>  #14 in sdr::properties::AttributeProperties::~AttributeProperties() at engine/svx/source/sdr/properties/attributeproperties.cxx:221:9
>  #15 in sdr::properties::TextProperties::~TextProperties() at engine/svx/source/sdr/properties/textproperties.cxx:79:9
>  #16 in sdr::properties::RectangleProperties::~RectangleProperties() at engine/svx/source/sdr/properties/rectangleproperties.cxx:38:9
>  #17 in sdr::properties::RectangleProperties::~RectangleProperties() at engine/svx/source/sdr/properties/rectangleproperties.cxx:37:9
>  #18 in std::default_delete<sdr::properties::BaseProperties>::operator()(sdr::properties::BaseProperties*) const at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/unique_ptr.h:92:2
>  #19 in std::__uniq_ptr_impl<sdr::properties::BaseProperties, std::default_delete<sdr::properties::BaseProperties>>::reset(sdr::properties::BaseProperties*) at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/unique_ptr.h:204:4
>  #20 in std::unique_ptr<sdr::properties::BaseProperties, std::default_delete<sdr::properties::BaseProperties>>::reset(sdr::properties::BaseProperties*) at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/unique_ptr.h:530:7
>  #21 in SdrObject::~SdrObject() at engine/svx/source/svdraw/svdobj.cxx:589:18
>  #22 in SdrAttrObj::~SdrAttrObj() at engine/svx/source/svdraw/svdoattr.cxx:42:28
>  #23 in SdrTextObj::~SdrTextObj() at engine/svx/source/svdraw/svdotext.cxx:156:1
>  #24 in SdrRectObj::~SdrRectObj() at engine/svx/source/svdraw/svdorect.cxx:69:25
>  #25 in SdrUnoObj::~SdrUnoObj() at engine/svx/source/svdraw/svdouno.cxx:223:1
>  #26 in FmFormObj::~FmFormObj() at engine/svx/source/form/fmobj.cxx:120:1
>  #27 in FmFormObj::~FmFormObj() at engine/svx/source/form/fmobj.cxx:113:1
>  #28 in SdrObject::release() at engine/svx/source/svdraw/svdobj.cxx:612:9
>  #29 in rtl::Reference<SdrObject>::clear() at engine/include/rtl/ref.hxx:181:19
>  #30 in SvxShape::~SvxShape() at engine/svx/source/unodraw/unoshape.cxx:199:21
>  #31 in SvxShapeText::~SvxShapeText() at engine/svx/source/unodraw/unoshape.cxx:3828:1
>  #32 in SvxShapeControl::~SvxShapeControl() at engine/svx/source/unodraw/unoshap2.cxx:393:1
>  #33 in SvxShapeControl::~SvxShapeControl() at engine/svx/source/unodraw/unoshap2.cxx:392:1
>  #34 in cppu::OWeakObject::release() at engine/cppuhelper/source/weak.cxx:231:9
>  #35 in cppu::OWeakAggObject::release() at engine/cppuhelper/source/weak.cxx:293:22
>  #36 in cppu::WeakAggImplHelper12<com::sun::star::drawing::XShape, com::sun::star::lang::XComponent, com::sun::star::beans::XPropertySet, com::sun::star::beans::XMultiPropertySet, com::sun::star::beans::XPropertyState, com::sun::star::lang::XUnoTunnel, com::sun::star::container::XNamed, com::sun::star::drawing::XGluePointsSupplier, com::sun::star::container::XChild, com::sun::star::lang::XServiceInfo, com::sun::star::document::XActionLockable, com::sun::star::beans::XMultiPropertyStates>::release() at engine/include/cppuhelper/implbase12.hxx:161:31
>  #37 in SvxShapeText::release() at engine/include/svx/unoshape.hxx:357:17
>  #38 in SvxShapeControl::release() at engine/include/svx/unoshape.hxx:508:21
>  #39 in freeUnoInterfaceProxy at engine/bridges/source/cpp_uno/shared/unointerfaceproxy.cxx:42:19
>  #40 in (anonymous namespace)::s_stub_defenv_revokeInterface(__va_list_tag (*) [1]) at engine/cppu/source/uno/lbenv.cxx:369:17
>  #41 in s_environment_invoke_v(_uno_Environment*, _uno_Environment*, void (*)(__va_list_tag (*) [1]), __va_list_tag (*) [1]) at engine/cppu/source/uno/EnvStack.cxx:292:9
>  #42 in uno_Environment_invoke_v at engine/cppu/source/uno/EnvStack.cxx:310:5
>  #43 in uno_Environment_invoke at engine/cppu/source/uno/EnvStack.cxx:318:5
>  #44 in (anonymous namespace)::defenv_revokeInterface(_uno_ExtEnvironment*, void*) at engine/cppu/source/uno/lbenv.cxx:423:5
>  #45 in releaseProxy at engine/bridges/source/cpp_uno/shared/unointerfaceproxy.cxx:78:9
>  #46 in com::sun::star::uno::UnoInterfaceReference::~UnoInterfaceReference() at engine/include/uno/dispatcher.hxx:93:9
>  #47 in binaryurp::Bridge::releaseStub(rtl::OUString const&, com::sun::star::uno::TypeDescription const&) at engine/binaryurp/source/bridge.cxx:509:1
>  #48 in binaryurp::IncomingRequest::execute_throw(binaryurp::BinaryAny*, std::__debug::vector<binaryurp::BinaryAny, std::allocator<binaryurp::BinaryAny>>*) const at engine/binaryurp/source/incomingrequest.cxx:138:18
>  #49 in binaryurp::IncomingRequest::execute() const at engine/binaryurp/source/incomingrequest.cxx:79:26
>  #50 in request at engine/binaryurp/source/reader.cxx:86:9
>  #51 in cppu_threadpool::JobQueue::enter(void const*, bool) at engine/cppu/source/threadpool/jobqueue.cxx:100:17
>  #52 in cppu_threadpool::ORequestThread::run() at engine/cppu/source/threadpool/thread.cxx:165:31
>  #53 in threadFunc at engine/include/osl/thread.hxx:175:15
>  #54 in osl_thread_start_Impl(void*) at engine/sal/osl/unx/thread.cxx:240:9
>
> 0x7ccbfe8b3a38 is located 184 bytes inside of 648-byte region [0x7ccbfe8b3980,0x7ccbfe8b3c08)
> freed by thread T23 here:
>  #0 in operator delete(void*, unsigned long) at ~/github.com/llvm/llvm-project/compiler-rt/lib/asan/asan_new_delete.cpp:187:3
>  #1 in SdrItemPool::~SdrItemPool() at engine/svx/source/svdraw/svdattr.cxx:514:1
>  #2 in salhelper::SimpleReferenceObject::release() at engine/include/salhelper/simplereferenceobject.hxx:61:13
>  #3 in rtl::Reference<SfxItemPool>::~Reference() at engine/include/rtl/ref.hxx:116:22
>  #4 in SdrModel::~SdrModel() at engine/svx/source/svdraw/svdmodel.cxx:275:1
>  #5 in FmFormModel::~FmFormModel() at engine/svx/source/form/fmmodel.cxx:69:1
>  #6 in SdDrawDocument::~SdDrawDocument() at engine/sd/source/core/drawdoc.cxx:418:1
>  #7 in sd::DrawDocShell::~DrawDocShell() at engine/sd/source/ui/docshell/docshell.cxx:192:9
>  #8 in sd::GraphicDocShell::~GraphicDocShell() at engine/sd/source/ui/docshell/grdocsh.cxx:57:38
>  #9 in sd::GraphicDocShell::~GraphicDocShell() at engine/sd/source/ui/docshell/grdocsh.cxx:57:37
>  #10 in cppu::OWeakObject::release() at engine/cppuhelper/source/weak.cxx:231:9
>  #11 in rtl::Reference<SfxObjectShell>::~Reference() at engine/include/rtl/ref.hxx:116:22
>  #12 in IMPL_SfxBaseModel_DataContainer::~IMPL_SfxBaseModel_DataContainer() at engine/sfx2/source/doc/sfxbasemodel.cxx:268:5
>  #13 in void std::destroy_at<IMPL_SfxBaseModel_DataContainer>(IMPL_SfxBaseModel_DataContainer*) at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/stl_construct.h:88:15
>  #14 in void std::_Destroy<IMPL_SfxBaseModel_DataContainer>(IMPL_SfxBaseModel_DataContainer*) at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/stl_construct.h:164:7
>  #15 in void std::allocator_traits<std::allocator<void>>::destroy<IMPL_SfxBaseModel_DataContainer>(std::allocator<void>&, IMPL_SfxBaseModel_DataContainer*) at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/alloc_traits.h:863:4
>  #16 in std::_Sp_counted_ptr_inplace<IMPL_SfxBaseModel_DataContainer, std::allocator<void>, (__gnu_cxx::_Lock_policy)2>::_M_dispose() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/shared_ptr_base.h:650:2
>  #17 in std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/shared_ptr_base.h:423:8
>  #18 in std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/shared_ptr_base.h:1100:11
>  #19 in std::__shared_ptr<IMPL_SfxBaseModel_DataContainer, (__gnu_cxx::_Lock_policy)2>::~__shared_ptr() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/shared_ptr_base.h:1574:31
>  #20 in std::__shared_ptr<IMPL_SfxBaseModel_DataContainer, (__gnu_cxx::_Lock_policy)2>::reset() at ~/gcc/inst/lib/gcc/x86_64-pc-linux-gnu/17.0.0/../../../../include/c++/17.0.0/bits/shared_ptr_base.h:1692:9
>  #21 in SfxBaseModel::dispose() at engine/sfx2/source/doc/sfxbasemodel.cxx:802:13
>  #22 in SdXImpressDocument::dispose() at engine/sd/source/ui/unoidl/unomodel.cxx:5515:19
>  #23 in SfxBaseModel::close(bool) at engine/sfx2/source/doc/sfxbasemodel.cxx:1544:5
>  #24 in gcc3::callVirtualMethod(void*, unsigned int, void*, _typelib_TypeDescriptionReference*, bool, unsigned long*, unsigned int, unsigned long*, double*) at engine/bridges/source/cpp_uno/gcc3_linux_x86-64/callvirtualmethod.cxx:87:5
>  #25 in cpp_call(bridges::cpp_uno::shared::UnoInterfaceProxy*, bridges::cpp_uno::shared::VtableSlot, _typelib_TypeDescriptionReference*, int, _typelib_MethodParameter*, void*, void**, _uno_Any**) at engine/bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx:230:13
>  #26 in unoInterfaceProxyDispatch at engine/bridges/source/cpp_uno/gcc3_linux_x86-64/uno2cpp.cxx:410:13
>  #27 in binaryurp::IncomingRequest::execute_throw(binaryurp::BinaryAny*, std::__debug::vector<binaryurp::BinaryAny, std::allocator<binaryurp::BinaryAny>>*) const at engine/binaryurp/source/incomingrequest.cxx:236:13
>  #28 in binaryurp::IncomingRequest::execute() const at engine/binaryurp/source/incomingrequest.cxx:79:26
>  #29 in request at engine/binaryurp/source/reader.cxx:86:9
>  #30 in cppu_threadpool::JobQueue::enter(void const*, bool) at engine/cppu/source/threadpool/jobqueue.cxx:100:17
>  #31 in cppu_threadpool::ORequestThread::run() at engine/cppu/source/threadpool/thread.cxx:165:31
>  #32 in threadFunc at engine/include/osl/thread.hxx:175:15
>  #33 in osl_thread_start_Impl(void*) at engine/sal/osl/unx/thread.cxx:240:9

Change-Id: Ib38eb730f9178976d4432f77857b4f09ebfbdbcf
Signed-off-by: Stephan Bergmann <stephan.bergmann@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/6296
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Michael Stahl <michael.stahl@collabora.com>
(cherry picked from commit 7a151cb95d66be93ef2a2687d1ff55ca37daa410)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211728
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-10-05 08:52:33 +02:00
Xisco Fauli 7003eb6fc6 fix headers
Change-Id: Ia2732cc041367bc113654bc424ea6621f3961e9f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211724
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-10-05 08:52:04 +02:00
Michael Weghorn 6d9b8d423a svx: Switch GalleryPreview::mpParent to reference
... and rename accordingly. This makes clear it's
always non-null.

Change-Id: I33b68dcf3f6cff8680249671121efe25333bbd61
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211742
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-10-04 23:11:58 +02:00
Michael Weghorn b97af65b5d svx: Switch GalleryIconView::mpParent to reference
... and rename accordingly. This makes clear it's
always non-null.

Change-Id: I95774bd2e4b6e830f6550f0277217489848be068
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211740
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-10-04 23:11:39 +02:00
Andrea Gelmini aa8ffbbea9 Fix typo
Change-Id: Ic2c704f63f6977f6a45e8290860a9e920bbad66e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211760
Reviewed-by: Dan Williams <dcbw@libreoffice.org>
Tested-by: Jenkins
2026-10-02 23:38:18 +02:00
Noel Grandin 73c41f63cd Rename again in EditTextObject
I messed up in
  commit e174028ce0335d702ecdad5eac823845a16e2f6d
  Author: Noel Grandin <noelgrandin@collabora.com>
  Date:   Mon Sep 21 18:13:44 2026 +0200
  Rename paragraph related types in EditTextObject.

This is not the primary paragraph data structure for
EditEngine.
Add some commentary to reduce the chance of anyone
else making this mistake.

Rename typedef
  EditEngineParagraphs -> EditTextObjectParagraphs

Rename class
  EditEngineParagraph -> EditTextObjectParagraph

Change-Id: I810571cb61b944dd9d056145fe4cef14ba3e43bb
Signed-off-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13273
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
(cherry picked from commit e8dde7d988a1768b68380ab95ba8fabb5feefc2e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211653
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-10-01 12:33:02 +02:00
Noel Grandin 447298ce46 rename EditEngine::GetDepth to GetNumberingDepth
to distinguish it from the various other depths we have.

Change-Id: I2917ecc55baa90c375150d2066b98c6e5f384626
Signed-off-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13272
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
(cherry picked from commit dc56f1179397f2b6765cdf12a3d09a99fcf7e679)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211652
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-10-01 12:11:03 +02:00
Mike Kaganski 24f40c4b11 tdf#163272 sw,drawinglayer,vcl: give anchored content its own /Lang
With Tagged PDF on, a paragraph in a language other than the document's
gets /Lang on its structure element. What is anchored in the paragraph
is tagged inside that same element and inherits the attribute, so a
frame's text and its description would be declared the paragraph's
language.

0d2d9e656d87647f904f1a463ed9b879c2bfb10c (tdf#163272 sw: give a
paragraph its own /Lang, 2026-09-21) avoided that by putting no /Lang on
such a paragraph, on a check of one node of a text frame that can cover
several. Its text still carried the language, on a Span, while what was
anchored in it specified none and inherited the document's. In a German
document that declared a shape's English text German. See
https://gerrit.collaboraoffice.com/c/online/+/13117/comment/89a7866d_907a2957/

The paragraph specifies its own language now, and a frame anchored in it
no longer inherits it. A Figure, a Formula and a frame's Division
specify the document's where the paragraph's differs, which is what the
frame's own paragraphs are measured against. A drawing shape's text is
tagged by drawinglayer, which takes the locale of the drawn portions and
specifies it where they agree; such a shape is nested in its anchor
paragraph in Writer and in no such paragraph elsewhere, so there is
nothing to compare against.

A drawing shape's own element specifies the document's language too. svx
anchors it under the anchor paragraph, drawinglayer opens it there, and
it carries the shape's title and description. Without the attribute, a
described shape in a paragraph that specifies one would have its
description declared the paragraph's language, and its text likewise
where the portions disagree.

testParagraphLanguage compared a structure type against a language and
quoted no text, so nothing identified the words affected. It lists every
element holding text or a description now, against the language it
specifies, an entry reading "P de-DE: Ein deutscher Absatz mit einem
Bild."; one specifying none is listed without a language, so correct
inheritance is asserted too. PDFiumPageObject gained getMarkedContentID
to join a page object's text to its element.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I1eecf0b56f09fc6d144894910a9037d89884dd3b
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13239
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 898a2e1b3a6fc07d7b43315b2f4781b32f1a20d3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211609
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-10-01 10:25:19 +02:00
Noel Grandin 90f327c670 merge OutlinerEditEng into EditEngine
as part of the process of simplifying the whole Outliner vs EditEngine
infrastructure.

Change-Id: Ia4f173ba41b374864cc4e47d895b037d6493a08f
Signed-off-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13238
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
(cherry picked from commit 196eccebee433d3cfe170786a81ea39f5c491ec1)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211615
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-10-01 09:01:56 +02:00
Noel Grandin 212d17f7ea add a non-const GetEditEngine() method to Outliner
to avoid const-casting all over the place

Change-Id: I75f3442341894dbe4e12cc7995669dc7f3bf63f7
Signed-off-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13354
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
(cherry picked from commit 318e2cf839c6311d4a69572b4534f554bdda3f96)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211604
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-10-01 09:01:52 +02:00
Noel Grandin ce16bc37fd use more concrete UNO class in the form of ScModelObj
Change-Id: I9ad26f05635583e203ff338a88add65838c9188e
Reviewed-on: https://gerrit.collaboraoffice.com/c/core/+/555
Reviewed-by: Noel Grandin <noel.grandin@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 0a6ee7a99d6a5d624c4303256cc385ca6e23d456)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211619
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-10-01 09:01:29 +02:00
Caolán McNamara a1fa358d47 don't create the document BasicManager on save to check module sizes
Creating it loads every Basic library of the document. Only an
existing BasicManager can have loaded the password protected
modules that the size check looks at.

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I1a66c4738d9a91cda785f0603c6f4fd6e6549802
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13628
Reviewed-by: Noel Grandin <noel.grandin@collabora.com>
(cherry picked from commit 35fb01a50f47698e9b059b75c2a3b88699579fac)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211524
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-30 14:41:13 +02:00
Mike Kaganski d00d192770 tdf#157028 vcl: write the structure tree into object streams
Turning Tagged PDF on added 2.4 MB to the reporter's document, 2.0 MB of that
its structure tree: 12562 elements, each its own top-level object,
uncompressed, and each costing a further 20 bytes in the cross-reference
table.

The elements go into /Type/ObjStm streams of 200 now, with the parent and ID
trees. The cross-reference has to become a /Type/XRef stream with them,
because a table cannot address an object inside another object. PDF 1.5
introduced both, so a PDF/A-1b file keeps the plain form. So does an encrypted
file, since a string in an object stream shall not be separately encrypted,
and this writer encrypts strings as it builds the object. So does a hybrid
file, because sdext reads the embedded original document out of a trailer.

The reporter's document exported 3157118 bytes tagged before the change and
1086230 after, against 769448 untagged either way. An 8300-row Writer table
exported 4017140 bytes tagged before and 500967 after, against 73183 untagged.

testTdf159066 and testTdf173162 grep the exported bytes for something the
structure tree carries, /Alt< and the /Namespaces array. They inflate the
object streams first now. testListLabelPDFExport counted its List element in
the token stream, and asks GetObjects() for it.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I1e27dc3a8f43aa8b6c75ae930615c8d4b4645627
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13209
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit ad4bb8ae080aba98080dfaabd688dfdb48cf7ade)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211556
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-09-30 13:25:11 +02:00
Gülşah Köse 111a2ffc8b cool#16233 sw: keep a formula's font size across DOCX import and export
An equation's size lives in the w:sz of its math runs. The import ignored it,
so every equation came in at the 12pt default of the formula editor, and a file
holding equations at three sizes showed all three the same. An equation whose
runs name no size takes the size of the text around it, which the styles and
the document defaults hold.

The export wrote no size at all. It now puts the size on every math run, and in
the control properties of each object, which is where the fraction bar, the
radical sign and the brackets take theirs from. The size travels in the w
namespace, so it goes out for a DOCX only, the way the color of a formula
already does.

Every formula now carries a size of its own on the way out, including one
written in ODF. Such a formula used to leave the size open and took whatever
the text around it had in the reading application. It now keeps the size it is
drawn at here, so both applications show it the same.

Setting the base size means giving each of the fonts that same size. The font
size dialog, the BaseFontHeight property of the model and this import each did
that on their own, so they now share SmFormat::SetBaseSizeAndFonts. The
property used to put the sizes in a copy that a later merge step reads only for
a font the same call has named, so a lone BaseFontHeight left the fonts alone.

Signed-off-by: Gülşah Köse <gulsah.kose@collabora.com>
Change-Id: I18b6c5814a57d8ccb8be5b7bdd357ce76cea024d
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13297
Reviewed-by: Balázs Varga <balazs.varga@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 582e3fdb6496d9f511dfefc1f716b4ead6cc3797)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211600
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-30 12:12:58 +02:00
Caolán McNamara 51744f6265 don't load the document Basic to parse formula names during ODF import
While macros are not yet allowed, a called name is kept as a macro
call if the document has Basic libraries at all.

A cell macro call now decides the macro mode before it loads the
document Basic.

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I2f33b51490db8515cd74d5e753bb9a18c5e6a587
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13626
Reviewed-by: Noel Grandin <noel.grandin@collabora.com>
(cherry picked from commit d17fd31994d71c28f503bb3cc93471c307756627)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211523
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-30 08:44:12 +02:00
Michael Weghorn ec99b899d4 vcl: Pass SvLBoxItem::Paint's SvVieweDataEntry param by ref
... instead of by pointer.

This makes clear it's always non-null.

Change-Id: Iea22c33171572eec0533550293a793372d889ee9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211569
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-09-29 19:40:29 +02:00
Michael Weghorn 6296615b8d tdf#173695 svx: Ensure minimum height for ColorWindow
The number of colors displayed in the ColorIconView
in ColorWindow depends on the selected palette.

When the popup is shown for the first time, its
size is calculated based on the size of the
widgets it contains, and the size of the weld::IconView
used for ColorIconView is in turn based on the number
of colors in the initial palette.

If the initial palette has few (or no) colors,
switching to a palette with many colors results
in the need for the weld::IconView to use more
space than previously to show the additional items,
but since the popup doesn't resize, it remains at
its initial size and the selection of colors is
inconvenient or even impossible.

Avoid the problem by ensuring the ColorIconView
has a minimum height of at least 200 pixels.

Before the switch to ColorIconView in

    commit a4d5983b4e
    Author: Michael Weghorn <m.weghorn@posteo.de>
    Date:   Fri Jun 5 11:48:54 2026 +0200

        tdf#130857 Port ColorWindow from SvxColorValueSet to ColorIconView

, the SvxColorValueSet widget in use previously
was always set to a fixed size altogether.

Change-Id: I7b24dd823083891126cf7b4d0ebe1914c1e0cc87
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211565
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-09-29 17:32:27 +02:00
Caolán McNamara aa5c21e8b1 start with RawBitmap pixels blanked
so pixels that a reader never writes, for example when it stops a row
early, are black rather than arbitrary noise

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I8e7133427b43447875869d23958dfb4316c4e178
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13725
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Noel Grandin <noel.grandin@collabora.com>
(cherry picked from commit b509e99e049d330950edeac35702735fd22245ab)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211562
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-09-29 15:57:31 +02:00
Michael Weghorn f1b64c69c1 vcl: Make ImageTree ctor private
There's only a single instance of the class
that can be retrieved using ImageTree::get.

Make the ctor private to clarify that.

Change-Id: I75bd6e60e8079f5ddcef49200280fa61bbf1c4ca
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211552
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
2026-09-29 14:00:00 +02:00
Mike Kaganski a0c08a780e vcl: let PDFDocument list the objects an object stream holds
GetElements() hands out the tokens the file itself carries, so a caller
hunting structure elements finds none of those a /Type/ObjStm holds - every
one of them, in a file from a producer that compresses its objects. They are
there already: Tokenize unpacks each object stream it passes and registers
what it finds, so only an accessor was missing.

The 64 places that scanned the token stream for an object ask GetObjects()
instead.

testTdf57423 and testStyleNamedStructureTypes compared the order as well. The
map is keyed by object number, which for a structure tree is document order,
where the token stream carried the emission order that writes a child before
its parent - the type sequence reads "Document Table TR TD" now instead of
ending "TR Table". Both hold the same 22 elements; testTdf57423 stopped
indexing its figures and compares one string per kind.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I3e46e600e0aed3802f5ee2f8c6dc25a50002763d
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13207
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit 50bf4f7acb344520ce2055bddfaf844c23239a8e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211450
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-29 12:32:49 +02:00
ApurvR20 df52af4eea tdf#90341 Use std::span to clean up excessive const_cast
Changed implementation in EnhancedCustomShapeGeometry from pointer to
std::span, leading to removal of const_cast.

Change-Id: Ic2d768202991eba674275aa4ffe78478f8f6dd27
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210515
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
2026-09-29 10:15:59 +02:00
Michael Weghorn 2e48a78172 svtools: Return entries in FontNameBox::LoadMRUEntries
Let FontNameBox::LoadMRUEntries simply return the
entries loaded from the file instead of applying
them to the combobox right away.

Let the only caller FontNameBox::Fill do the insertion,
which also unifies the two different code paths of
either reinserting the existing entries or setting
the ones loaded from the file a bit more.

While at it, also rename the local `rEntries`
variable to `aEntries`, to make clear this is
not actually a reference (as the `r` prefix
previously suggested).

Change-Id: I89c14f2bcd34c4b6b4decf33e98bef54e7b31cf0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211536
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-09-29 08:51:21 +02:00
Mike Kaganski 0b3a0fae8c Related: tdf#166401 fix writing properties for empty placeholder
Regression after commit b41a780d139ec6ca5a5514db972ccf0e50058dfc (tdf#166401:
support custom placeholder prompt text, 2026-08-17), where a placeholder that
authored no prompt stopped writing text and got a bare <a:p/> instead.

On a slide an empty presentation object reports no text through UNO anyway, so
the paragraph the export wrote for such a placeholder never had a run. It
carried the properties, and those are the formatting. In PowerPoint 2016 the
original title showed white at 22pt, indented 56.5pt; the round-tripped one
showed bold black at 17pt, indented 18pt.

Write the paragraph the way a shape with no text already does: the paragraph
properties, the run properties in endParaRPr, and no run. The prompt still
stays out of the file. That branch of DrawingML::WriteText is now a method of
its own, called from both places.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I034a4e14f388c90872069d32b303c6c143c1814c
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/10768
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
(cherry picked from commit e2859f5b23f53281d80cbad4c56db1764aaf1406)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211538
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-29 08:45:18 +02:00
Heiko Tietze 0f09c4ea1c Resolves tdf#173717 - Reliably hide transparency controls
Change-Id: Ic77957af1390b9b50321c04e89451d6dd0cae456
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211448
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2026-09-29 06:43:31 +02:00
Heiko Tietze 3b602bc4fc Related tdf#173606 - Show an icon in combobox depending on msg type
Following the prototype of gtk3

Change-Id: Id25c0a61c3c38427e86525f58c6bb40b9cd257ed
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211476
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2026-09-26 11:19:15 +02:00
Heiko Tietze c279ce5108 Related tdf#151121 - Feedback on the actual replacement font
* Missing glyphs such as U+1234 are not detected as missing
* Missing variants such as 'Italic Light' are not detected
* Language on the font is not taken into account

Change-Id: I6329a2607f7e13b8ba09050b1037d4e33b4c7eb4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211324
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
Tested-by: Jenkins
2026-09-26 08:00:17 +02:00
Neil Roberts 6154aa313c Related tdf#173293 comphelper: Add helper class for XInvocation
Lots of classes implement XInvocation in order to add extra methods and
properties that are determined at runtime. One problem with this is that
when such an object is introspected with the css.script.Invocation
service then that service uses the XInvocation interface directly to
query what methods and properties are supported instead of creating an
XIntrospectionAccess via the css.beans.Introspection service. It looks
like probably all of the current implementations of XInvocation only use
it to advertise the dynamic methods and don’t advertise any concrete
methods provided by any interfaces that the object implements. This
means for example that when the object is accessed by pyuno, only the
dynamic methods and properties can be used.

This patch adds a helper class that can be used to help implement
XInvocation in such a way that if a requested method isn’t found as a
dynamic method, it can pass the method call on to the helper which will
use the normal Introspection service to query the available methods and
properties.

Change-Id: Ia4363594ee274c36249a0d1c94f16a829ace4647
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/210130
Tested-by: Jenkins
Reviewed-by: Neil Roberts <nroberts@libreoffice.org>
2026-09-25 10:39:19 +02:00
Christopher Sherlock fdad8a0460 vcl: encapsulate full coordinate transformation in ImplMapRes
This commit finalizes the refactoring of the LogicToLogic() coordinate
mapping pipeline by completely encapsulating both scaling and origin
translation within the ImplMapRes struct.

By recognizing the mathematical symmetry of the affine transformation,
origin shifts are now explicitly decoupled from the scaling logic. This
allows the complete transformation pipeline to be handled internally,
making the call sites in map.cxx significantly cleaner and less prone
to offset-related bugs.

Key changes:
- Removed the intermediate ScaleLogicX() and ScaleLogicY() methods.
- Introduced explicit LocalToAbsolute() and AbsoluteToLocal() helper
  methods to handle origin offset addition and subtraction.
- Added TransformPointX() and TransformPointY(), which cleanly implement
  the full pipeline: LocalToAbsolute() -> ScaleDistance() -> AbsoluteToLocal().
- Updated OutputDevice::LogicToLogic() overloads for Point and Rectangle
  to use the new TransformPoint methods, successfully removing all
  manual destination offset subtractions from map.cxx.

Change-Id: Ibb42f62d6904ae282dabf697b35455aec7c17677
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203680
Tested-by: Jenkins
Reviewed-by: Dan Williams <dcbw@libreoffice.org>
2026-09-24 19:58:11 +02:00
Christopher Sherlock 74176cfe53 vcl: encapsulate coordinate and distance scaling in ImplMapRes
This commit refactors the procedural scaling logic in map.cxx into
clean, object-oriented methods on the ImplMapRes struct. This greatly
improves readability and structurally prevents mathematical bugs by
separating the concepts of coordinate scaling and distance scaling.

Previously, map.cxx relied heavily on the standalone static function
lcl_scaleLogicValue(), requiring manual extraction and passing of
internal scales and offsets at every call site.

Key changes:
- Moved lcl_scaleLogicValue() into ImplMapRes.cxx as an internal helper.
- Added ScaleLogicX() and ScaleLogicY() to ImplMapRes to handle absolute
  coordinates (Points and Rectangles), which safely apply the local
  origin offset before scaling.
- Added ScaleDistanceX() and ScaleDistanceY() to ImplMapRes to handle
  pure vectors (Sizes), ensuring origin offsets are bypassed.
- Refactored OutputDevice::LogicToLogic() overloads to utilize these
  new encapsulated methods.

Change-Id: Ib46f6f2bac09b23baa37f29b8a71fdf6a0ffe164
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203679
Reviewed-by: Dan Williams <dcbw@libreoffice.org>
Tested-by: Jenkins
2026-09-24 19:55:22 +02:00
Christopher Sherlock 2a021a9e60 vcl: introduce parameterized ImplMapRes constructor
This commit introduces a parameterized constructor for ImplMapRes to
streamline map resolution initialization across VCL mapping functions.

Previously, instantiating a local ImplMapRes required an error-prone,
two-step process: default construction followed by a call to the
CalcMapResolution mutator.

The new constructor elegantly bridges this by delegating the complex
scaling math to CalcMapResolution() while explicitly handling the absolute
origin offsets (mnMapOfs) required for a fresh resolution state.

Key changes:
- Added ImplMapRes(MapMode, nDPIX, nDPIY) constructor.
- Refactored CoordinateMapper and OutputDevice mapping functions
  (LogicToPixel, PixelToLogic) to use the new single-line RAII-style
  initialization, eliminating repetitive two-step setup code.

Change-Id: I68072cd66d01fd1663b58330890fe90a7bb8f94c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/203677
Tested-by: Jenkins
Reviewed-by: Dan Williams <dcbw@libreoffice.org>
2026-09-24 19:53:11 +02:00
Miklos Vajna d91da67575 pdfium: replace extractpatterns.patch with the upstreamed version
Similar to commit a7850ccd6656d1718fd0d89709550664e997c759 (pdfium:
replace the fix-windows-build patch with the upstreamed version,
2026-09-11).

The upstreamed version doesn't need a pdf page parameter, so clean up
some (now) unused pPage and (pre-existing) nPageObjectIndex parameters
as well.

Signed-off-by: Miklos Vajna <vmiklos@collabora.com>
Change-Id: Ieef207bf39124fdf4a8bff14ab1532f1836087ec
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13355
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit ba15a8ac8921a3a82fbc193f781610d7c5a18c38)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211417
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-24 13:59:52 +02:00
Noel Grandin 41be19ccbd Rename paragraph related types in EditTextObject
Because we already have a ContentInfo type in ucb/
and ContentInfo is a largely content-free name, which
makes this code much harder to understand than it should be.

Rename class
  ContentInfo -> EditEngineParagraph
Rename typedef
  ContentInfosType -> EditEngineParagraphs

Rename some methods in EditTextObject
  CreateAndInsertContent -> CreateAndInsertParagraph
  GetContents -> GetParagraphs
Rename some fields in EditTextObject
  maContents -> maParagraphs

Change-Id: Iddfb8768c73f9c4eec3b4cc5dc389d44d8e4b90d
Signed-off-by: Noel Grandin <noelgrandin@collabora.com>
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/13210
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
(cherry picked from commit e174028ce0335d702ecdad5eac823845a16e2f6d)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211384
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-24 12:05:17 +02:00
Laurent Balland daadf3e95a tdf#167472 Integrate MediaWiki template for translation
Add the constants needed for the translation
Update mediawiki.ott:
- add title in meta.xml for translation
- remove German language tags to make the template language independant
- simplify Settings.xml
- update Thumbnail.png
- replace fonts with Noto's family fonts
Build mediawiki.ott from XML files like other templates. See
/extras/CustomTarget_templates.mk

Change-Id: I575843003796cb04099f1061f816ba52c658d41d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211247
Tested-by: Jenkins
Reviewed-by: Laurent Balland <laurent.balland@mailo.fr>
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2026-09-23 18:51:43 +02:00
László Németh e668dc84eb tdf#173389 cui offapi sw xmloff: add custom compound-based hyphenation
Add new paragraph justification option "Split compound words" for
custom compound-based "smart" hyphenation. Add compound-based "smart"
hyphenation support for Danish, Dutch, Esperanto, Estonian, German,
Norwegian, Swedish (and potentially, Icelandic, Finnish and
Latvian) languages by fixing Hunspell morphological analysis and the
associated lingucomponent code. (Previously compound-based "smart"
hyphenation was enabled only for Hungarian.)

With the new option it's possible to keep MSO/MS-DOCX interoperability,
also introducing a better hyphenation algorithm for several languages.

Details:

    * Add check box to Alignment in paragraph formatting dialog window;

    * Store properties in paragraph model:

      css::style::ParagraphProperties::ParaIsCompoundBased

    * Implement it by checking the new option in the previously
      added commit f9f694f5d9f39c5801bc5fec45867252c293bbcb;

    * Add ODF import/export (loext:compound-based);

    * Add ODF unit tests by the new tdf173389_smart_hyphenation_nl.odt
      and tdf173389_smart_hyphenation_hu.odt. Now use the previous
      tdf119908_smart_hyphenation_hu for disabled compound-based "smart"
      hyphenation, also the new tdf119908_smart_hyphenation_nl.odt.
      Note: the Dutch test document results better compound-based
      hyphenation in two positions.

    * Add Hunspell patch to fix Danish, Dutch, Esperanto, Estonian,
      German, Norwegian, Swedish (and future Icelandic, Latvian,
      Finnish) morphological analysis for compound word constituents;

    * hyphenimp.cxx hyphenate(): fix tokenization for consecutive
      pa: elements, like resulted in the fixed Hunspell dictionaries.

Follow-up to commit f9f694f5d9
"tdf#173389 sw: add compound-based “smart” hyphenation for readability".

Change-Id: I4414bd588646ecf6dc86b77642833ac9c7820a98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211341
Tested-by: Jenkins
Reviewed-by: László Németh <nemeth@numbertext.org>
2026-09-23 14:38:07 +02:00
Mike Kaganski 5d6c85d78b vcl: a tagged PDF's lengths are in user space units
Indent a paragraph by half an inch, then File - Export As - Export as
PDF with Universal Accessibility (PDF/UA) on. Its element read

 /A <</O/Layout/Placement/Block
 /StartIndent 0.72

where half an inch is 36 points. Every length was a fiftieth of what
it names: a 64.8pt inline formula carried /Width 1.296 and a 481.9pt
table /Width 9.638. Writer passes twips, and the PDF writer prints
thousandths of a point. For an inline Formula the standard makes
Width the sole source of information about the element's extent
(ISO 32000-2 14.8.5.4.6), so the fiftieth is all a reader reflowing
the file has.

A bounding box was right all along, because SetStructureBoundingBox
converts one out of the current map mode. The nine lengths this
writer can set take the same conversion now. The counts and the
identifiers pass through untouched - RowSpan, ColSpan, Language and
the annotation ids.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I4da4d085de9da7e3773294756ff3205b9b1b38aa
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/12997
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
(cherry picked from commit ec0a83ea9cacd67b7842a4899e9996b2d0048ce0)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211350
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Tested-by: Jenkins
2026-09-23 12:22:03 +02:00
Zesen Liu 722410514b tdf#173623 svx: Pass index of activated item in ColorIconView handler
ColorIconView only passed the Color to its activation handler, so its
users took everything else (color name, position for the theme palette
lookup) from the selected item. For mouse and keyboard the activated
item is always the selected one, but the AT-SPI "activate" action of an
item activates it without selecting it first, so the color of the
selected item was applied instead of the activated one.

Pass the index of the activated item to the handler and let the users
take color, name and theme index from it.

Change-Id: I900278bf68e5038e5588ce71b03cd4b5ae9f8918
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211237
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
2026-09-23 09:47:55 +02:00
Mike Kaganski d663a07822 sw,vcl: name the heading a TOC item lists
Insert - Table of Contents and Index, then export with File - Export
as PDF, Universal Accessibility (PDF/UA) on and PDF version 2.0. The
file fails ISO 14289-2 clause 8.2.5.8 once per entry, which veraPDF
reports as:

 Each TOCI in the table of contents shall identify the target of the
 reference using the Ref entry, either directly on the TOCI structure
 element itself or on one of its child structure elements

An item named no target at all:

 <</Type/StructElem/NS 2 0 R/S/TOCI /P 8 0 R /Pg 3 0 R /K[10 0 R ]>>

It names the heading now, in the /Ref entry PDF 2.0 added:

 <</Type/StructElem/NS 2 0 R/S/TOCI /P 8 0 R /Pg 3 0 R /Ref[ 15 0 R ] /K[10 0 R ]>>

Object 15 is the /S/H1 the entry links to, found from the mark its
URL names. An item that links to a table, a frame or an object, or
that has no link at all, still names nothing.

The document of testTdf173162 linked its entries to
bookmark alone now, as Writer writes them, and the document passes
the profile, so the test asks for PDF/UA instead of plain tagging
and the harness validates it.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I76e73684d2ab09f187f56cab093d13980150d737
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/12750
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
(cherry picked from commit ee49bf58e7d3eb3ff94677e9a51c73b76eb51a99)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211338
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-23 00:04:53 +02:00
Mike Kaganski 07ccc05cf7 sw,vcl: name a footnote FENote at PDF 2.0
Put a footnote in a document and export with File - Export as PDF,
Tagged PDF on and PDF version 2.0. The file fails ISO 14289-2 clause
8.2.5.14 once per footnote. veraPDF, on the PDF/UA-2 profile, reports:

 The Note standard structure type shall not be present in conforming
 documents unless role mapped to a structure element in the PDF 2.0
 namespace

The element carried the type PDF 2.0 replaced, in the 1.7 namespace
ISO 14289-2 8.2.4 accepts alongside the 2.0 one:

 <</Type/StructElem/NS 2 0 R/S/Note /ID (id29) /P 28 0 R /Pg 3 0 R ...>>

Writer asks for FENote now, so the element lands in the 2.0 namespace
and the check stops failing:

 <</Type/StructElem/NS 1 0 R/S/FENote /ID (id29) /P 28 0 R /Pg 3 0 R ...>>

Below PDF 2.0 the file still says Note, the only footnote type
ISO 32000-1 has.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I4674f4f902621ee8765121782799f42cc59c5e6e
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/12749
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
(cherry picked from commit 42433cf89b23328991e7a64daea4f771b60f728a)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211337
Tested-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-23 00:04:49 +02:00
Andrea Gelmini dade1d3f9d Fix typo in code
Change-Id: I40f96dbcd3419d10477a00c25f9877b4f4067973
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211194
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2026-09-22 21:58:28 +02:00
Mike Kaganski 3e517fbfe9 vcl: give each style a structure name of its own
Write a paragraph in Writer's built-in Index paragraph style and
export with Tagged PDF switched on. The element comes out as
/S/Index, over a role map that reads

 /Index/P

so the standard Index type means a paragraph, document-wide. veraPDF,
on the PDF/UA-1 profile:

 Standard tags defined in ISO 32000-1:2008, 14.8.4, shall not be
 remapped

A style called Artifact went further. Its paragraph reached the
content stream beside the marker for content that is not part of the
structure at all, the two being one name:

 /Artifact BMC
 /Artifact<</MCID 10>>BDC

Writer names a structure element after the style that produced it,
and the role map records what that name means, one entry per name.
Styles collide there with the standard types, with each other, being
separate families for paragraphs and characters, and with the names
Writer asks for itself, Source Text writing Code literally.

A name a standard type has, or another alias asked for, is now passed
over for the first indexed name beside it that is free, so the Index
style writes /S/Index-1 over /Index-1/P. PDF 2.0 has standard names
1.7 lacks: a style called H7 gives way there, while a heading at
outline level 7, which Writer asks for by that same name, keeps it
and needs no entry at all. The synthetic Div containers ask for no
name now, and carry the Div tag as before.

The test document remapped four standard tags at PDF 1.7 and six at
2.0; now none at either.

Found while reproducing tdf#165454.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: I63e9116e5db17bdb554b508a864e313a77f40bc2
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/12361
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
(cherry picked from commit 54e0207ff6bcf937187a395912f1ed57b60d90e3)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211314
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-22 20:49:36 +02:00
Vissarion Fisikopoulos 68bed36a97 tdf#153057, tdf#173589 enable Base to filter date and time values
This patch implements and fixes cases for filtering. In particular
the cases for form-based and dialogue-based filtering in forms for
data and time. Additionally, the cases for time values in Table
Data View.

A specific limitation comes from firebird which accepts only 4 digits
for nanoseconds in time values. The data are rounded to that digit
for firebird while still support full precision (up to 9 digits)
for other engines. This is implemented using the driver's metadata
functions.

Unit tests are added.

Change-Id: I89435da239c898f3c782fcc9f78f98caf4223f62
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211298
Reviewed-by: Vissarion Fisikopoulos <vfisikop@libreoffice.org>
Tested-by: Jenkins
2026-09-22 15:54:40 +02:00
Laurent Balland 567cbc9557 tdf#171207 Remove right clic for Add sheet button
After adding a new button in the TabBar with
https://gerrit.libreoffice.org/210677
right clic is useless for Add Sheet button

Change-Id: Ie6bc3c28f3f7654f3f7a7e3747faa418f6d19411
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211227
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2026-09-21 13:11:20 +02:00
Heiko Tietze 92320dcca1 Resolves tdf#61134 - Show the sustituted font name in the tooltip
Shows what font is subsituted in the tooltip or that no subsitution
is available

Change-Id: I6171f1a0163d1cde82dba93386d189e0cd1e77c9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211098
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2026-09-21 10:48:54 +02:00
Mike Kaganski c3cae7d482 drawinglayer,svx: ask for an artifact instead of faking a tag
I9431c460cade3d432cb7abf76930e23f8106a7f1 ("tdf#168462 svx: mark the
slide background as an artifact") left page decoration reaching its
/Artifact by a lie: VclMetafileProcessor2D emitted one only for a
background image, and dropped a tag naming NonStructElement, so the
tag claimed to be a Division and an image. Decoration now says so
itself: the artifact decision reads the decorative flag, and the
caller passes NonStructElement and no image and means them. A
background image keeps its own path to an artifact.
isTaggedSdrObject() becomes opensStructureElement(); its comment
still claimed every one of these primitives comes from an SdrObject.

The exported file is unchanged. The one call that goes away with the
old predicate, alternative text on a tag that opens an artifact,
could not reach the file either: setAlternateText writes nothing
without m_bEmitStructure, and checkEmitStructure() is false inside a
NonStructElement. operator== now compares the element and the
decorative flag, which decide what comes out and were not compared.

Letting a master slide's own shapes out as artifacts does not follow
from treating every background as decoration. A background object can
hold tagged children, and a Paragraph begun inside an artifact opens
no marked content at all; tried on testTdf135192, three pieces of its
content came out in no marked-content section. Something narrower has
to tell the two apart.

Signed-off-by: Mike Kaganski <mike.kaganski@collabora.com>
Change-Id: Id0fc0d9bee36e8182702d77e9ac9647709a63f68
Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/12321
Tested-by: Jenkins CPCI <releng@collaboraoffice.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
(cherry picked from commit 9353a1cac3e8056d175acc29dbeecc79ff1cdcd4)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211170
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2026-09-21 00:20:39 +02:00
Michael Weghorn b6f104403a sfx2: Make SfxViewShell::StartPrint private
It's a helper method only used by SfxViewShell::ExecPrint,
so doesn't need to be public. Make it private.

Change-Id: I9925e7d47bcd1e2423aaed7e6e3ff6a06726eb82
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211230
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
2026-09-20 22:24:51 +02:00
Michael Weghorn 25eea781f0 [API CHANGE] Pass XAccessible to XAccessibleGroupPosition::getObjectLink
Similar to previous commit

    Change-Id: I5db3a99bb8d78099e3b136cbcd402fe2ae49d49c
    Author: Michael Weghorn <m.weghorn@posteo.de>
    Date:   Sat Sep 19 13:12:54 2026 +0200

        [API CHANGE] Pass XAccessible to XAccessibleGroupPosition::getGroupPosition

, also pass an XAccessible instead of a uno::Any to
XAccessibleGroupPosition::getObjectLink.

See the above-mentioned commit for more background.

Change-Id: I8440b91eff66a18bc6e431a0ad91362e895d945c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/211217
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Tested-by: Jenkins
2026-09-20 22:24:29 +02:00