Age | Commit message (Collapse) | Author |
|
The problem is that the graphics cache only counts the size of the SVG
text, which is stored in SvgData::maSvgDataArray. However the
SvgData::maSequence may use a lot more memory, as it may contain
de-compressed bitmaps that are stored as base64-encoded PNGs in the SVG
text.
For example icon-themes/galaxy/brand/flat_logo.svg is 812 Ko but contains
60 Mo of bitmaps.
This may cause excessive memory usage and failure to export documents
due to OOM; according to valgrind massif, the bitmap buffers use 90% of
the heap.
Add a new interface com::sun::star::util::XAccounting, and implement
it in drawinglayer BasePrimitive2D. VCL SvgData can't access
drawinglayer via C++ directly so this looks like the best approach.
Change-Id: I5a7c3147733e23473c1decabed24c1f79d951c7d
Reviewed-on: https://gerrit.libreoffice.org/30669
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
|
|
and fix a couple of memory leaks in the process, some of them were
not being deleted at all
Change-Id: Icb5c948662ad3ba878eadfbc807f93cc35cfb228
Reviewed-on: https://gerrit.libreoffice.org/30651
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
...to avoid use-after-free, as e.g. happens on macOS with -fsanitize=address in
CppunitTest_sw_mailmerge:
> ==29010==ERROR: AddressSanitizer: heap-use-after-free on address 0x60800088faf8 at pc 0x000118ebc153 bp 0x7fff52f81a40 sp 0x7fff52f81a38
> READ of size 8 at 0x60800088faf8 thread T0
> WARNING: failed decoding unknown ioctl 0x20007454
> WARNING: failed decoding unknown ioctl 0x20007452
> #0 0x118ebc152 in AquaSalMenu::SetSubMenu(SalMenuItem*, SalMenu*, unsigned int) salmenu.cxx:597
> #1 0x1177bbefc in Menu::SetPopupMenu(unsigned short, PopupMenu*) menu.cxx:803
> #2 0x138dccb5a in framework::MenuBarManager::RemoveListener() menubarmanager.cxx:552
> #3 0x138dcb452 in framework::MenuBarManager::Destroy() menubarmanager.cxx:237
> #4 0x138dcd6d7 in framework::MenuBarManager::dispose() menubarmanager.cxx:267
> #5 0x138dccfa2 in framework::MenuBarManager::RemoveListener() menubarmanager.cxx:587
> #6 0x138dcb452 in framework::MenuBarManager::Destroy() menubarmanager.cxx:237
> #7 0x138dcd6d7 in framework::MenuBarManager::dispose() menubarmanager.cxx:267
> #8 0x138e06acf in framework::MenuBarWrapper::dispose() menubarwrapper.cxx:103
> #9 0x1389c0f67 in framework::LayoutManager::impl_clearUpMenuBar() layoutmanager.cxx:226
> #10 0x1389c497b in framework::LayoutManager::implts_destroyElements() layoutmanager.cxx:447
> #11 0x1389c3777 in framework::LayoutManager::implts_reset(bool) layoutmanager.cxx:413
> #12 0x1389edf4b in framework::LayoutManager::frameAction(com::sun::star::frame::FrameActionEvent const&) layoutmanager.cxx:2811
> #13 0x138b9e1a8 in (anonymous namespace)::Frame::implts_sendFrameActionEvent(com::sun::star::frame::FrameAction const&) frame.cxx:3110
> #14 0x138b8219b in (anonymous namespace)::Frame::setComponent(com::sun::star::uno::Reference<com::sun::star::awt::XWindow> const&, com::sun::star::uno::Reference<com::sun::star::frame::XController> const&) frame.cxx:1557
> #15 0x138b88545 in (anonymous namespace)::Frame::close(unsigned char) frame.cxx:1801
> #16 0x12078429a in SfxFrame::DoClose() frame.cxx:127
> #17 0x120812990 in SfxViewFrame::Notify(SfxBroadcaster&, SfxHint const&) viewfrm.cxx:1234
> #18 0x11ab542d5 in SfxBroadcaster::Broadcast(SfxHint const&) SfxBroadcaster.cxx:50
> #19 0x1203a0682 in SfxModelListener_Impl::notifyClosing(com::sun::star::lang::EventObject const&) objxtor.cxx:171
> #20 0x1204453d2 in SfxBaseModel::close(unsigned char) sfxbasemodel.cxx:1372
> #21 0x1245130d5 in SwXTextDocument::close(unsigned char) unotxdoc.cxx:621
> #22 0x1247af99b in CloseModelAndDocSh(com::sun::star::uno::Reference<com::sun::star::frame::XModel>&, tools::SvRef<SfxObjectShell>&) unomailmerge.cxx:115
> #23 0x1247af4bf in DeleteTmpFile_Impl(com::sun::star::uno::Reference<com::sun::star::frame::XModel>&, tools::SvRef<SfxObjectShell>&, rtl::OUString const&) unomailmerge.cxx:342
> #24 0x1247b6ad6 in SwXMailMerge::execute(com::sun::star::uno::Sequence<com::sun::star::beans::NamedValue> const&) unomailmerge.cxx:814
> #25 0x1247b9c62 in non-virtual thunk to SwXMailMerge::execute(com::sun::star::uno::Sequence<com::sun::star::beans::NamedValue> const&) unomailmerge.cxx:434
> #26 0x11eeab4fd in MMTest::executeMailMerge() mailmerge.cxx:179
> #27 0x11eea2470 in testMultiPageAnchoredDraws::verify() mailmerge.cxx:336
> #28 0x11ef3be50 in MMTest::executeMailMergeTest(char const*, char const*, char const*, bool, int, char const*) mailmerge.cxx:87
> #29 0x11ef38af3 in testMultiPageAnchoredDraws::MailMerge() mailmerge.cxx:334
> #30 0x11ef557b9 in CppUnit::TestCaller<testMultiPageAnchoredDraws>::runTest() TestCaller.h:166
> #31 0x10cfff749 in CppUnit::TestCaseMethodFunctor::operator()() const TestCase.cpp:32
> #32 0x110736b67 in (anonymous namespace)::Protector::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) vclbootstrapprotector.cxx:36
> #33 0x10cfc9c20 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const ProtectorChain.cpp:20
> #34 0x110498fa7 in (anonymous namespace)::Prot::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) unobootstrapprotector.cxx:89
> #35 0x10cfc9c20 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const ProtectorChain.cpp:20
> #36 0x10f776880 in (anonymous namespace)::Prot::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) unoexceptionprotector.cxx:65
> #37 0x10cfc9c20 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const ProtectorChain.cpp:20
> #38 0x10cf64042 in CppUnit::DefaultProtector::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) DefaultProtector.cpp:15
> #39 0x10cfc9c20 in CppUnit::ProtectorChain::ProtectFunctor::operator()() const ProtectorChain.cpp:20
> #40 0x10cfc7200 in CppUnit::ProtectorChain::protect(CppUnit::Functor const&, CppUnit::ProtectorContext const&) ProtectorChain.cpp:77
> #41 0x10d06f15a in CppUnit::TestResult::protect(CppUnit::Functor const&, CppUnit::Test*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) TestResult.cpp:181
> #42 0x10cffd8cd in CppUnit::TestCase::run(CppUnit::TestResult*) TestCase.cpp:91
> #43 0x10d00097a in CppUnit::TestComposite::doRunChildTests(CppUnit::TestResult*) TestComposite.cpp:64
> #44 0x10d00045e in CppUnit::TestComposite::run(CppUnit::TestResult*) TestComposite.cpp:23
> #45 0x10d00097a in CppUnit::TestComposite::doRunChildTests(CppUnit::TestResult*) TestComposite.cpp:64
> #46 0x10d00045e in CppUnit::TestComposite::run(CppUnit::TestResult*) TestComposite.cpp:23
> #47 0x10d0990ac in CppUnit::TestRunner::WrappingSuite::run(CppUnit::TestResult*) TestRunner.cpp:47
> #48 0x10d06da55 in CppUnit::TestResult::runTest(CppUnit::Test*) TestResult.cpp:148
> #49 0x10d099ebd in CppUnit::TestRunner::run(CppUnit::TestResult&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) TestRunner.cpp:96
> #50 0x10cc6f509 in (anonymous namespace)::ProtectedFixtureFunctor::run() const cppunittester.cxx:305
> #51 0x10cc6a0ac in sal_main() cppunittester.cxx:455
> #52 0x10cc687a6 in main cppunittester.cxx:362
> #53 0x7fffc9f36254 in start (libdyld.dylib+0x5254)
>
> 0x60800088faf8 is located 88 bytes inside of 96-byte region [0x60800088faa0,0x60800088fb00)
> freed by thread T0 here:
> #0 0x10d327b6b in wrap__ZdlPv asan_new_delete.cc:179
> #1 0x118eb3011 in AquaSalMenu::~AquaSalMenu() salmenu.cxx:279
> #2 0x118eb10de in AquaSalInstance::DestroyMenu(SalMenu*) salmenu.cxx:238
> #3 0x1177acd1d in Menu::ImplSetSalMenu(SalMenu*) menu.cxx:2342
> #4 0x1177ab046 in Menu::dispose() menu.cxx:183
> #5 0x1177d86f5 in PopupMenu::dispose() menu.cxx:2764
> #6 0x117f99ee2 in VclReferenceBase::disposeOnce() vclreferencebase.cxx:42
> #7 0x1177bf7d8 in VclPtr<Menu>::disposeAndClear() vclptr.hxx:208
> #8 0x1177bbbd5 in Menu::SetPopupMenu(unsigned short, PopupMenu*) menu.cxx:788
> #9 0x138dccb5a in framework::MenuBarManager::RemoveListener() menubarmanager.cxx:552
> #10 0x138dcb452 in framework::MenuBarManager::Destroy() menubarmanager.cxx:237
> #11 0x138dcd6d7 in framework::MenuBarManager::dispose() menubarmanager.cxx:267
> #12 0x138dccfa2 in framework::MenuBarManager::RemoveListener() menubarmanager.cxx:587
> #13 0x138dcb452 in framework::MenuBarManager::Destroy() menubarmanager.cxx:237
> #14 0x138dcd6d7 in framework::MenuBarManager::dispose() menubarmanager.cxx:267
> #15 0x138e06acf in framework::MenuBarWrapper::dispose() menubarwrapper.cxx:103
> #16 0x1389c0f67 in framework::LayoutManager::impl_clearUpMenuBar() layoutmanager.cxx:226
> #17 0x1389c497b in framework::LayoutManager::implts_destroyElements() layoutmanager.cxx:447
> #18 0x1389c3777 in framework::LayoutManager::implts_reset(bool) layoutmanager.cxx:413
> #19 0x1389edf4b in framework::LayoutManager::frameAction(com::sun::star::frame::FrameActionEvent const&) layoutmanager.cxx:2811
> #20 0x138b9e1a8 in (anonymous namespace)::Frame::implts_sendFrameActionEvent(com::sun::star::frame::FrameAction const&) frame.cxx:3110
> #21 0x138b8219b in (anonymous namespace)::Frame::setComponent(com::sun::star::uno::Reference<com::sun::star::awt::XWindow> const&, com::sun::star::uno::Reference<com::sun::star::frame::XController> const&) frame.cxx:1557
> #22 0x138b88545 in (anonymous namespace)::Frame::close(unsigned char) frame.cxx:1801
> #23 0x12078429a in SfxFrame::DoClose() frame.cxx:127
> #24 0x120812990 in SfxViewFrame::Notify(SfxBroadcaster&, SfxHint const&) viewfrm.cxx:1234
> #25 0x11ab542d5 in SfxBroadcaster::Broadcast(SfxHint const&) SfxBroadcaster.cxx:50
> #26 0x1203a0682 in SfxModelListener_Impl::notifyClosing(com::sun::star::lang::EventObject const&) objxtor.cxx:171
> #27 0x1204453d2 in SfxBaseModel::close(unsigned char) sfxbasemodel.cxx:1372
> #28 0x1245130d5 in SwXTextDocument::close(unsigned char) unotxdoc.cxx:621
> #29 0x1247af99b in CloseModelAndDocSh(com::sun::star::uno::Reference<com::sun::star::frame::XModel>&, tools::SvRef<SfxObjectShell>&) unomailmerge.cxx:115
>
> previously allocated by thread T0 here:
> #0 0x10d32752b in wrap__Znwm asan_new_delete.cc:106
> #1 0x118eafa18 in AquaSalInstance::CreateMenu(bool, Menu*) salmenu.cxx:230
> #2 0x1177d75e0 in PopupMenu::PopupMenu() menu.cxx:2711
> #3 0x1177d7664 in PopupMenu::PopupMenu() menu.cxx:2710
> #4 0x129136557 in VclPtr<PopupMenu> VclPtr<PopupMenu>::Create<>() vclptr.hxx:131
> #5 0x1291362de in VCLXMenu::ImplCreateMenu(bool) vclxmenu.cxx:73
> #6 0x1291463ca in VCLXPopupMenu::VCLXPopupMenu() vclxmenu.cxx:901
> #7 0x129146414 in VCLXPopupMenu::VCLXPopupMenu() vclxmenu.cxx:900
> #8 0x138dc5e83 in framework::MenuBarManager::FillMenuManager(Menu*, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&, com::sun::star::uno::Reference<com::sun::star::frame::XDispatchProvider> const&, rtl::OUString const&, bool) menubarmanager.cxx:1354
> #9 0x138dc2316 in framework::MenuBarManager::MenuBarManager(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&, com::sun::star::uno::Reference<com::sun::star::util::XURLTransformer> const&, com::sun::star::uno::Reference<com::sun::star::frame::XDispatchProvider> const&, rtl::OUString const&, Menu*, bool, bool) menubarmanager.cxx:140
> #10 0x138dc72bd in framework::MenuBarManager::MenuBarManager(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&, com::sun::star::uno::Reference<com::sun::star::util::XURLTransformer> const&, com::sun::star::uno::Reference<com::sun::star::frame::XDispatchProvider> const&, rtl::OUString const&, Menu*, bool, bool) menubarmanager.cxx:138
> #11 0x138dc57bc in framework::MenuBarManager::FillMenuManager(Menu*, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&, com::sun::star::uno::Reference<com::sun::star::frame::XDispatchProvider> const&, rtl::OUString const&, bool) menubarmanager.cxx:1304
> #12 0x138dc2316 in framework::MenuBarManager::MenuBarManager(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&, com::sun::star::uno::Reference<com::sun::star::util::XURLTransformer> const&, com::sun::star::uno::Reference<com::sun::star::frame::XDispatchProvider> const&, rtl::OUString const&, Menu*, bool, bool) menubarmanager.cxx:140
> #13 0x138dc72bd in framework::MenuBarManager::MenuBarManager(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, com::sun::star::uno::Reference<com::sun::star::frame::XFrame> const&, com::sun::star::uno::Reference<com::sun::star::util::XURLTransformer> const&, com::sun::star::uno::Reference<com::sun::star::frame::XDispatchProvider> const&, rtl::OUString const&, Menu*, bool, bool) menubarmanager.cxx:138
> #14 0x138e07ba5 in framework::MenuBarWrapper::initialize(com::sun::star::uno::Sequence<com::sun::star::uno::Any> const&) menubarwrapper.cxx:181
> #15 0x138f32e6d in framework::MenuBarFactory::CreateUIElement(rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&, char const*, rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::ui::XUIElement> const&, com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) menubarfactory.cxx:154
> #16 0x138f31848 in framework::MenuBarFactory::createUIElement(rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) menubarfactory.cxx:63
> #17 0x138f3313a in non-virtual thunk to framework::MenuBarFactory::createUIElement(rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) menubarfactory.cxx:56
> #18 0x138f56f6e in (anonymous namespace)::UIElementFactoryManager::createUIElement(rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) uielementfactorymanager.cxx:450
> #19 0x138f5a94a in non-virtual thunk to (anonymous namespace)::UIElementFactoryManager::createUIElement(rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) uielementfactorymanager.cxx:408
> #20 0x1389ca5da in framework::LayoutManager::implts_createElement(rtl::OUString const&) layoutmanager.cxx:731
> #21 0x1389d6fb4 in framework::LayoutManager::createElement(rtl::OUString const&) layoutmanager.cxx:1482
> #22 0x11fbd36f1 in SfxDispatcher::SetMenu_Impl() dispatch.cxx:1216
> #23 0x11fbc36dc in SfxDispatcher::Update_Impl(bool) dispatch.cxx:1290
> #24 0x11fb7556d in SfxBindings::NextJob_Impl(Timer*) bindings.cxx:1459
> #25 0x11fb8ad4c in SfxBindings::NextJob(Timer*) bindings.cxx:1441
> #26 0x11fb61177 in SfxBindings::LinkStubNextJob(void*, Timer*) bindings.cxx:1439
> #27 0x11898aea1 in Link<Timer*, void>::Call(Timer*) const link.hxx:84
> #28 0x11898add6 in Timer::Invoke() timer.cxx:88
> #29 0x1188dae6d in ImplSchedulerData::Invoke() scheduler.cxx:47
Change-Id: I16d5b11710ee46dbaa77afd94a09ba5f07a311b0
|
|
Change-Id: Ifa34faf24e399b5baf24214a2869ca7eb5d61456
|
|
Change-Id: Ib5c40931805ef8a484ccb52c5d2b81180f68f0cc
|
|
MultiSalLayout did not implement IsKashidaPosValid() which meant that
whenever there is a font fallback no Kashida validation was performed.
Change-Id: I30e498c356c49b0c06dd6b45187105f6bd758a24
|
|
Change-Id: I0ac8be9f129636fae2be03f60a4e9b8a65a195e9
|
|
So that we base the rotation or not based on the resolved script,
instead of using the outdated and hard-coded ranges in GetVerticalFlags.
Change-Id: I52ee38c4151f30d98287e64f852b4d2df143c719
|
|
Change-Id: Ic784b3951fcf2f614b62d93d925eec134feb7364
Reviewed-on: https://gerrit.libreoffice.org/30567
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
|
|
Change-Id: I9a086d4a5d2f1b0d1afa3afd155eadcb2ae62ab5
Reviewed-on: https://gerrit.libreoffice.org/30543
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
And use it in xmlsecurity when signing an existing PDF. This is
especially important on Windows, where the PKCS#7 blob doesn't have an
(unsigned) timestamp.
Change-Id: I4051dc19a43f8f8114d9f4d02309f28d6754e9ae
|
|
Change-Id: Ifa8bfafb2e527ce5976f3bd310d107cb2840a5f6
Reviewed-on: https://gerrit.libreoffice.org/30531
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: Ie1f840c3ec9a2d5888f95cf05e531a8a9464bf2e
Reviewed-on: https://gerrit.libreoffice.org/30524
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
We parse features appended to font names in CommonSalLayout as well, so
code that takes care of their presence (striping them when searching,
hashing, etc.) should not be dependent on the old Graphite support or it
will not work when old Graphite is disabled (e.g. on macOS).
Change-Id: If040782a86ec76d3743baf4d2b1d7a194e8e13f2
|
|
The env variable takes precedence.
Change-Id: I273ec867725dd012b005d49fbfaa1dc27203c021
|
|
Change-Id: I572b83949c7e643536b7d62567760546509e4d9f
Reviewed-on: https://gerrit.libreoffice.org/30514
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Regression from 4f1dca5083c5a301181786b563b165f19a9dec7f
Change-Id: I7b7f3594499cd049ae59064da244e3f82dff7757
Reviewed-on: https://gerrit.libreoffice.org/28617
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: jan iversen <jani@documentfoundation.org>
|
|
This reverts commit 3950166877bf1308f9e449992e20b558342af825.
Change-Id: Ie22a99885a23d44a9870fcd286bee4ccf10c53ac
Reviewed-on: https://gerrit.libreoffice.org/30505
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
|
|
Change-Id: I5f9c8011a43e2b15b9b2f58772f6f08ad103f4aa
|
|
and not just menus, this is like how the gtk equivalent can launch popovers
Change-Id: I53ae96aab0c51d75405dba15ab8080d7315471e3
|
|
Move Windows-specific code from PDFWriterImpl::finalizeSignature() to
PDFWriter::Sign(), this way the pdfverify cmdline tool can sign a
previously unsigned file.
Change-Id: I1144e228bf8f12a284c3fc32fd3e74c355855ff3
|
|
if a floating window is inside a floating window, go up the floating
windows until we find the first one that accepts focus, rather than
pass the input to the toplevel frame
Change-Id: I6c2a3de02ab436b8441b1fec15d51dec4f96c931
|
|
Change-Id: Ie003bc7ccc9985162ea52a1b0164118d9c2ce437
|
|
activate the color selector in the toolbar in the sidebar panel, press tab
to cycle between its widgets, when it hits the bottom it will
not return to the first widget, but escape out of the floating
window into the next sibling of the toolbar
Change-Id: I806fd4d94c477e9cfb2ea238830f7b646ea274d2
|
|
Change-Id: I07f2fe400f20d8f52588db326851f310245b7d8d
|
|
Change-Id: I65f96d9cd24572c8d0946acf4d2d45eb3db83a76
Reviewed-on: https://gerrit.libreoffice.org/30476
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I96634c18ba6600f8f7d5d04a162dcd7e1e312923
Reviewed-on: https://gerrit.libreoffice.org/30474
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
This reverts commit d79f43d0bebbe7b1f8d68d50734737aea9fe839d.
Breaks MacOSX tinderbox, need to figure out why a totally unrelated test
is broken.
|
|
Always create HarfBuzz font at the UPEM size and scale HarfBuzz output
with the desired size instead. This theoretically means we loss any
size-specific adjustments in the font but in practice very few fonts do
this and in general modern APIs prefer stable glyph positioning across
font sizes.
Change-Id: Idf396eec5e241cc5fb9d0db698f2c081b7de29e3
|
|
The handful of bugs reported so far have been fixed, and I think it had
enough basic testing to show that it is usable and can be switched on
for wider testing.
We can always revert back to the old engine if needed before or even
during 5.3 series.
The environment variable SAL_NO_COMMON_LAYOUT can be set to disable it
at runtime.
Change-Id: If319a0161897ec676d3123595944a0401c67b63f
Reviewed-on: https://gerrit.libreoffice.org/30443
Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
Tested-by: Khaled Hosny <khaledhosny@eglug.org>
|
|
- Prefer "png" over "svg" because for Tango theme we include both
"png" and "svg" icon, but rendering of "svg" crashes
- We save the choice of which icons to use into the profile. When
32px icons were added the values have shifted - "auto" had value
2 has became "32px" choice and "auto" has the new value 3. In the
case of the default "auto", we now always showed 32px icons. This
commit reverts the "auto" value 2 and puts "32px" choice to 3.
- Name resolving now always removes the icon file extension and
adds the ".png" and ".svg" extension before resolving. This
makes it possible to define the name of the icon without the
file extension.
Change-Id: I05e3913aaee0037692609ced246954b14a13828a
Reviewed-on: https://gerrit.libreoffice.org/30440
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Change-Id: Ifd7e91753d9652d6b1c535cde3cddf74757a2483
Reviewed-on: https://gerrit.libreoffice.org/30430
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
|
|
Change-Id: I7037b7a8c70150f9946cca0c48607bd887779c82
Reviewed-on: https://gerrit.libreoffice.org/30405
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Apparently without implementing InitFont(), we might end up drawing with
the wrong font, thanks to the arcane ways GDI API.
Change-Id: I224de138446d4a536e13992efa98b0f04609576a
|
|
This adds links to "large" icons (prefixed with "lc_") also for
32px icons automatically so that we don't need to duplicate the
links.txt files.
Change-Id: I5fc3a769aa795060b6ae2d554cadd81938e4d4ec
Reviewed-on: https://gerrit.libreoffice.org/30399
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
This adds support for 32 pixel icons - mainly to get them into
the toolbar.
Most changes made are to change the behavior of having only small
and large icons as a boolean choice, but not every code path was
converted to non-boolean choice yet.
Breeze icon theme has the 32px variants so it can be used already.
Change-Id: Iadf832a87826c16b3a83522104dd6c35d61a0f87
Reviewed-on: https://gerrit.libreoffice.org/30398
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Call it once where we will use its results.
Change-Id: I63f3ceaf47e68bea9fab29d6836745416cf8ccb8
|
|
We cache and reuse the HarfBuzz font, so we need to make sure it always
has the right font size before using it.
Change-Id: I332c7f51f6495effde529c63485cb4ec658b2ca5
|
|
We need to update the buffer content type ourselves since we are now
using the low lever shape plan API that does not do this.
Change-Id: I043d15731cf206b142c3153896e194a822a70ffb
|
|
... unless it was opened using the keyboard.
Change-Id: I04675211ff043acf7757afed7252e7d7493eadad
|
|
(I'm not sure about how good are the changes from ScopedVclPtr
to non-scoped, and disposeAndClear to clear. They aren't really
needed, because of the VclReferenceBase::mbDisposed logic. But
at least they should be safe, as long as we have disposeOnce
calls in Menu's dtor.)
See also previous commits:
4433d95b374c13a3501cdf3a6e273f68eb49873a
("MenuItemData now properly disposes the submenu")
89c23b4aaef931b5d6009efaf44ce6e6c976e8d4
("Sub menus no longer need manual disposing")
Change-Id: I9d455a94590f5eec9b097947f6984f1b3e477b52
|
|
This is what it is actually is, we dropped support for server-side fonts
for a long time now. Renamed also a few related classes, but left
ServerFontLayout* ones as they will go away soonish.
Change-Id: I68a6dad51b6972368b7bf85a0b9c8089cc12740e
Reviewed-on: https://gerrit.libreoffice.org/30390
Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
Tested-by: Khaled Hosny <khaledhosny@eglug.org>
|
|
Turns out if we don’t adjust the glyph width (not only its X position)
we will apply the DX adjustment more than once when there is font
fallback.
Change-Id: I5e72e5d211adf3b378ec23c0cabe38fd0d5c9b19
|
|
Change-Id: Ie0f9964d893c520ad02bb33a1d30821735392076
Reviewed-on: https://gerrit.libreoffice.org/30382
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Change-Id: I049b3d2cde4dcb8c8c0690d75a015a43cb71b0c0
Reviewed-on: https://gerrit.libreoffice.org/30381
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Currently we support DPI scaling by a integer factor. This commit
changes that to percentage so we can have scaling factors like
1.5x or 1.25x. This is useful with 2.7k monitors that are in
between standard DPI and HiDPI. Thresholding was adjusted to scale
to 1.5x when DPI is between 120 and 168 DPI.
The old method GetDPIScaleFactor has been changed to return a
float value insted of int. Sometimes it is however more accurate
to use GetDPIScalePercentage which was added in this commit.
Change-Id: Iaecee793ff3d5084d00adeebbcf5d7368c580882
Reviewed-on: https://gerrit.libreoffice.org/30379
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Sometimes we want to surpress automatic scaling and converting
for dark theme. This adds a loadFromResource function with
additional flags which makes this possible.
Change-Id: I893cee82ad6942644755f0c5b772fb5f073bbf00
Reviewed-on: https://gerrit.libreoffice.org/30341
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
We don't need to scale images for HiDPI mode anymore - this is now
done automatically when the image is loaded.
Change-Id: Ie285cf4d672f4c098a468d3f7560ee2700365b92
Reviewed-on: https://gerrit.libreoffice.org/30340
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Also resolves tdf#92248
This extends icon name resolving so that is in addition tries to
find an icon with the "svg" extension and load that instead of
stated (mostly "png") extension. If the filename extension is
"svg" we load the icon with the SVG filter instead.
This also adds icon scaling and conversion for HiDPI or when a
dark theme is wanted. If the SVG icon is available, we render it
at a higher resolution instead of scaling
As loading of SVG icons can be computatunally expensive, a icon
disk cache was added. This saves the rendered SVG as a PNG image
into the "cache" folder. The same caching is also used for HiDPI
and dark theme converted icons so we don't always scale or
convert the icons.
In addition some style changes and DRY fixes were made to the
ImplImageTree source code.
Change-Id: I9e421395a342ffe8da9facea7ea06e5db2778b26
Reviewed-on: https://gerrit.libreoffice.org/30339
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
|
|
Change-Id: I6a87efa5e1072bac3588226df0e1351aa51c4d0d
Reviewed-on: https://gerrit.libreoffice.org/30108
Reviewed-by: Khaled Hosny <khaledhosny@eglug.org>
Tested-by: Khaled Hosny <khaledhosny@eglug.org>
|