Commit graph

494877 commits

Author SHA1 Message Date
Mike Kaganski
b6c10f89e2 When no branch is specified, fallback to the tracked branch first
This allows to work in a branch foo, which tracks e.g. master, and
using plain ./logerrit submit, have it submit to master properly.

Change-Id: I7aaff759392250a5380853cbaea0f892461c1d77
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165984
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-04-11 14:08:29 +02:00
Mike Kaganski
9bbecbaea3 Use COMReference in D2DWriteTextOutRenderer
... and simplify the related code.

Change-Id: Idaef7c9d725273e202948158e45ded7e7a2f85a0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165985
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-04-11 12:51:50 +02:00
Sarper Akdemir
fd7afc0a66 related tdf#33603: sd: fix notespanel crash on drag and drop
Change-Id: I067fd3f3eccd8e0fa0d13795f660fe43410b0aa3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165809
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2024-04-11 11:02:24 +02:00
Sarper Akdemir
7a495eb899 related tdf#33603: sd: force invalidate notespanel
This is likely not the correct thing to do here, but is a working
solution that fixes the view lagging behind the resize for now.

Change-Id: I662e59cfd0f1259eeb10a49b6e9c5fd616afa7a0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165808
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2024-04-11 11:02:18 +02:00
Sarper Akdemir
c3bc5c09e0 related tdf#33603: fix notespanel missing outliner on mode change
When MainViewShell changed editing mode, two EventMultipexerEvents
arrive in succession - if while processing the first one links are
reset, second one was ignored.

Do not remove EventMultiplexer listener on FillOutliner()

Change-Id: I9c41c823ca74574238d1199ed38f92d9c75a113e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165807
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2024-04-11 11:02:09 +02:00
Sarper Akdemir
2919194762 tdf#33603: sd: rework notes panel
To be able to support various dispatch commands, sidebar, proper
user configuration, and more - reworked the previous notes panel
implementation as a sd::View/sd::ViewShell pair that plays nice
with Impress framework.

To be able to support TextObjectBar(Shell) functionality, without
having TextObjectBar as a SubShell (In the current sd::framework
implementation AFAICS, SubShells are only possible for the
MainViewShell - this doesn't work for notes panel which is never
used as the MainViewShell.).

A workaround is implemented where NotesPanel inherits dispatching
slots from TextObjectBar, and for these inherited slots forwards
the calls to TextObjectBar's implementation.

This workaround could be removed if/when, SubShell support
outside of MainViewShell is implemented.

Known issues/TODO:
- Drag & Drop crashes / doesn't work.

- Some notes placeholder syncing problems on page change, edit mode
  change.

- A rendering issue related to resizing when ArrangeGUIElements
  isn't called on resize.

Change-Id: I588a4854fbedf6556e001fee1693b32410cbc23f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165770
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
2024-04-11 11:02:01 +02:00
Mike Kaganski
8d85da5616 Only call ID2D1RenderTarget::Get/SetTransform when needed
Change-Id: Ifde2c24c222e3c316f5a4f47e86c2c08f676639a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165983
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-04-11 10:38:47 +02:00
László Németh
6e8819f29b tdf#132599 cui offapi sw xmloff: add hyphenation-keep-type
Support XSL attribute "column" and CSS 4 attribute "spread",
stored in loext:hyphenation-keep-type, to give better control
over hyphenation-keep. E.g. spread: both parts of a hyphenated
word shall lie within a single spread, i.e. when the next page
is not visible at the same time (e.g. the next page is not a
right page of a book).

– css::style::ParaHyphenationKeep is a boolean property now,
  importing hyphenation-keep = "page" as true.

– type of ParaHyphenationKeep, including the new non-ODF types
  is stored in the new ParagraphProperties::ParaHyphenationKeepType.

– default value of ParaHyphenationKeepType is COLUMN for
  interoperability.

– Add checkboxes to Text Flow -> Hyphenation Across in
  paragraph dialog:

  * Column (previously: Hyphenate across column and page)
  * Page
  * Spread

  – enabling/disabling them follows XSL/CSS 4/loext, i.e.
    possible combinations:

  * No Hyphenation across
    (hyphenation-keep = "page" and loext:hyphenation-keep-type = "column")

  * Hyphenation across [x] Column
    (hyphenation-keep = "page" and loext:hyphenation-keep-type = "page")

  * Hyphenation across [x] Column [x] Page
    (hyphenation-keep = "page" and loext:hyphenation-keep-type = "spread")

  * Hyphenation across [x] Column [x] Page [x] Spread
    (hyphenation-keep = "auto")

– Add ODF import/export

– Update DOCX import

– Add ODF unit tests

Note: recent implementation depends on widow settings: disabling widow
handling allows hyphenation across columns and pages not only in table
cells.

Note: RTF import-only, but not used bPageEnd has been renamed to bKeep.
Depending on the RTF test results, likely it will need to disable
the layout change, e.g. GetKeepType()=ParagraphHyphenationKeepType::AUTO,
if PageEnd uses obsolete hyphenation rule, i.e. shifting only the
hyphenated word to the next page, not the full line.

More information:

– COLUMN (standard XSL value, defined in
  https://www.w3.org/TR/2001/REC-xsl-20011015/slice7.html#hyphenation-keep)

– SPREAD and ALWAYS (CSS 4 values of hyphenate-limit-last,
  equivalent of hyphenation-keep, defined in
  https://www.w3.org/TR/css-text-4/#hyphenate-line-limits).

Follow-up to commit 9574a62add
"tdf#132599 cui offapi sw xmloff: implement hyphenate-keep" and
commit c8ee0e8f58
"tdf160518 DOCX: import hyphenation-keep to fix layout".

Change-Id: I3ac6d9e86d0ed1646f105de8607c0e8ebc534eaa
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165954
Tested-by: László Németh <nemeth@numbertext.org>
Reviewed-by: László Németh <nemeth@numbertext.org>
2024-04-11 10:20:41 +02:00
Miklos Vajna
d890c27b67 CppunitTest_sw_uibase_shells: turn on set_non_application_font_use
Similar to commit dc4d7500c9 (Fix
CppunitTest_sd_import_tests-smartart non_application_font_use,
2023-10-23), got rid of 'MS 明朝' as suggested by the failing assert.

Change-Id: I24dcf0bffa8c213f776c0483d53fdee64ff7a413
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165982
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2024-04-11 09:48:23 +02:00
Mike Kaganski
1dc1729183 Drop old Windows 95/98/ME problem workaround
KB305290 (broken link https://support.microsoft.com/en-us/help/305290)
was for these long-unsupported systems.

Change-Id: Ie2e3814d24ceb5d014c0bff1a39b3d6675e3603c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165981
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-04-11 09:26:51 +02:00
Stephan Bergmann
3f5811a464 Silence strange -Warray-bounds with recent GCC 14
...seen at least with some (--enable-dbgutil --enable-optimized etc.)
configuration and a recent GCC 14 trunk,

> In file included from ~/gcc/inst/include/c++/14.0.1/vector:62,
>                  from connectivity/source/drivers/postgresql/pq_connection.cxx:38:
> In static member function ‘static constexpr _Up* std::__copy_move<_IsMove, true, std::random_access_iterator_tag>::__copy_m(_Tp*, _Tp*, _Up*) [with _Tp = long unsigned int; _Up = long unsigned int; bool _IsMove = false]’,
>     inlined from ‘constexpr _OI std::__copy_move_a2(_II, _II, _OI) [with bool _IsMove = false; _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:521:30,
>     inlined from ‘constexpr _OI std::__copy_move_a1(_II, _II, _OI) [with bool _IsMove = false; _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:548:42,
>     inlined from ‘constexpr _OI std::__copy_move_a(_II, _II, _OI) [with bool _IsMove = false; _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:555:31,
>     inlined from ‘constexpr _OI std::copy(_II, _II, _OI) [with _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:651:7,
>     inlined from ‘constexpr std::__cxx1998::vector<bool, _Alloc>::iterator std::__cxx1998::vector<bool, _Alloc>::_M_copy_aligned(const_iterator, const_iterator, iterator) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_bvector.h:1342:28,
>     inlined from ‘constexpr void std::__cxx1998::vector<bool, _Alloc>::_M_reallocate(size_type) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/vector.tcc:1054:40,
>     inlined from ‘constexpr void std::__cxx1998::vector<bool, _Alloc>::reserve(size_type) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_bvector.h:1130:17,
>     inlined from ‘constexpr void std::__debug::vector<_Tp, _Allocator>::reserve(size_type) [with _Tp = bool; _Allocator = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/debug/vector:495:16,
>     inlined from ‘pq_sdbc_driver::{anonymous}::cstr_vector::cstr_vector()’ at connectivity/source/drivers/postgresql/pq_connection.cxx:338:58:
> ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:452:30: error: ‘void* __builtin_memmove(void*, const void*, long unsigned int)’ forming offset 8 is out of the bounds [0, 8] [-Werror=array-bounds=]
>   452 |             __builtin_memmove(__result, __first, sizeof(_Tp) * _Num);
>       |             ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

and

> In file included from ~/gcc/inst/include/c++/14.0.1/vector:62,
>                  from connectivity/source/drivers/postgresql/pq_connection.cxx:38:
> In static member function ‘static constexpr _Up* std::__copy_move<_IsMove, true, std::random_access_iterator_tag>::__copy_m(_Tp*, _Tp*, _Up*) [with _Tp = long unsigned int; _Up = long unsigned int; bool _IsMove = false]’,
>     inlined from ‘constexpr _OI std::__copy_move_a2(_II, _II, _OI) [with bool _IsMove = false; _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:521:30,
>     inlined from ‘constexpr _OI std::__copy_move_a1(_II, _II, _OI) [with bool _IsMove = false; _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:548:42,
>     inlined from ‘constexpr _OI std::__copy_move_a(_II, _II, _OI) [with bool _IsMove = false; _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:555:31,
>     inlined from ‘constexpr _OI std::copy(_II, _II, _OI) [with _II = long unsigned int*; _OI = long unsigned int*]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:651:7,
>     inlined from ‘constexpr std::__cxx1998::vector<bool, _Alloc>::iterator std::__cxx1998::vector<bool, _Alloc>::_M_copy_aligned(const_iterator, const_iterator, iterator) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_bvector.h:1342:28,
>     inlined from ‘constexpr void std::__cxx1998::vector<bool, _Alloc>::_M_reallocate(size_type) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/vector.tcc:1054:40,
>     inlined from ‘constexpr void std::__cxx1998::vector<bool, _Alloc>::reserve(size_type) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_bvector.h:1130:17,
>     inlined from ‘constexpr void std::__debug::vector<_Tp, _Allocator>::reserve(size_type) [with _Tp = bool; _Allocator = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/debug/vector:495:16,
>     inlined from ‘pq_sdbc_driver::{anonymous}::cstr_vector::cstr_vector()’ at connectivity/source/drivers/postgresql/pq_connection.cxx:338:58:
> ~/gcc/inst/include/c++/14.0.1/bits/stl_algobase.h:452:30: error: ‘void* __builtin_memmove(void*, const void*, long unsigned int)’ writing between 9 and 9223372036854775807 bytes into a region of size 8 overflows the destination [-Werror=stringop-overflow=]
>   452 |             __builtin_memmove(__result, __first, sizeof(_Tp) * _Num);
>       |             ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> In file included from ~/gcc/inst/include/c++/14.0.1/x86_64-pc-linux-gnu/bits/c++allocator.h:33,
>                  from ~/gcc/inst/include/c++/14.0.1/bits/allocator.h:46,
>                  from ~/gcc/inst/include/c++/14.0.1/vector:63:
> In member function ‘_Tp* std::__new_allocator<_Tp>::allocate(size_type, const void*) [with _Tp = long unsigned int]’,
>     inlined from ‘constexpr _Tp* std::allocator< <template-parameter-1-1> >::allocate(std::size_t) [with _Tp = long unsigned int]’ at ~/gcc/inst/include/c++/14.0.1/bits/allocator.h:196:40,
>     inlined from ‘static constexpr _Tp* std::allocator_traits<std::allocator<_Up> >::allocate(allocator_type&, size_type) [with _Tp = long unsigned int]’ at ~/gcc/inst/include/c++/14.0.1/bits/alloc_traits.h:478:28,
>     inlined from ‘constexpr std::__cxx1998::_Bvector_base<_Alloc>::_Bit_pointer std::__cxx1998::_Bvector_base<_Alloc>::_M_allocate(std::size_t) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_bvector.h:679:48,
>     inlined from ‘constexpr void std::__cxx1998::vector<bool, _Alloc>::_M_reallocate(size_type) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/vector.tcc:1052:43,
>     inlined from ‘constexpr void std::__cxx1998::vector<bool, _Alloc>::reserve(size_type) [with _Alloc = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/bits/stl_bvector.h:1130:17,
>     inlined from ‘constexpr void std::__debug::vector<_Tp, _Allocator>::reserve(size_type) [with _Tp = bool; _Allocator = std::allocator<bool>]’ at ~/gcc/inst/include/c++/14.0.1/debug/vector:495:16,
>     inlined from ‘pq_sdbc_driver::{anonymous}::cstr_vector::cstr_vector()’ at connectivity/source/drivers/postgresql/pq_connection.cxx:338:58:
> ~/gcc/inst/include/c++/14.0.1/bits/new_allocator.h:151:55: note: destination object of size 8 allocated by ‘operator new’
>   151 |         return static_cast<_Tp*>(_GLIBCXX_OPERATOR_NEW(__n * sizeof(_Tp)));
>       |                                                       ^

Change-Id: I6ef1be6428363ff37d591207df379cc18ebea933
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165959
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-04-11 08:18:31 +02:00
Olivier Hallot
d5dcc9de8e Update git submodules
* Update helpcontent2 from branch 'master'
  to c2b91a5c78e053498f5ff6a411c314e36eb4a859
  - Stick to translatable content and simplify.
    
    * The example was locale dependent and was removed.
    
    Change-Id: I1df47fb5ba18ca4874b8b681ffff88a6fa7514aa
    Reviewed-on: https://gerrit.libreoffice.org/c/help/+/165910
    Tested-by: Jenkins
    Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2024-04-10 23:23:58 +02:00
Justin Luth
7b515b473c tdf#160293 sc NBB: tabbed groupbar_compact keep tabs in Pivot context
The VBox was hidding each child item since none had
Pivot or any as context types.

This didn't affect any other NBB variants
because they hadn't wrapped the tabs in a ContextVBox.

Using context-any would be bad for PrintPreview for example.

Change-Id: I47c4c9c813c17dde5440ae6dbadb8d1ab066d293
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165956
Tested-by: Jenkins
Reviewed-by: Justin Luth <jluth@mail.com>
2024-04-10 23:13:13 +02:00
Omkar Santosh Nikam
7d1dc5707e tdf#143148 Use pragma once instead of include guards
Use pragma once

Change-Id: Iedf25f6034f285e9bdcab515ec6d9e20b230d969
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165955
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
2024-04-10 22:29:08 +02:00
Jim Raykowski
64f1fbc4a6 tdf#160190 Fix selection stops working in sidebar SdNavigator
after formula or OLE insert

Change-Id: I945a07fef137aa30afff91ac7c50f180e5f4c3d9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164797
Tested-by: Jenkins
Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2024-04-10 18:48:39 +02:00
Jim Raykowski
833e2ecf43 tdf#139944 follow up
Also refresh the document info list so the objects tree will fill on
switching to normal view mode after the Navigator is opened in master
view mode.

Change-Id: I3749060206408ca2b9b58de541a9c9bf1731ec4d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165917
Tested-by: Jenkins
Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2024-04-10 18:43:06 +02:00
Armin Le Grand (allotropia)
614bcc5942 IASS: Support Mouse-Wheel Actions
The support for MouseWheel was missing. That showed
when using it in IASS the scroll commands were always
feeded to the SlideShow. Thus it was not possible
to e.g. scroll using MouseWheel in EditView when
IASS was active and SlideShow running.

This happens in ViewShell::HandleScrollCommand. It
needs to be made focus-dependent when IASS is active.

This is the same as already done for keyboard input,
so I consolidated this now to a method called
ViewShell::useInputForSlideShow() that does all the
necessary stuff and answers as needed. Using that
in various places: keyboard and MouseWheel, but also
adapted other places where the same has to happen,
mainly some gesture stuff.

Change-Id: I1a697e4b35b195695f1a5ea2305a3cee8851fa8d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165929
Tested-by: Jenkins
Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2024-04-10 18:22:23 +02:00
Patrick Luby
fe3a4bdf48 tdf#160590 Disable Metal with Intel HD Graphics 6000
Releasing a Metal buffer resource hangs when fetching pixels from a
Skia surface on this Intel MacBook Air built-in GPU.

Change-Id: Ic3028bf8eb45ebb9f6d71879bf5d96f0401a95c8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165927
Tested-by: Jenkins
Reviewed-by: Patrick Luby <guibomacdev@gmail.com>
2024-04-10 17:59:32 +02:00
Xisco Fauli
e1f3120ce8 vcl: return earlier if size is empty
Change-Id: I96bcd47d93e0e4d05e33d3ad3eca86c6edcf87ac
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165950
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2024-04-10 17:42:03 +02:00
Stephan Bergmann
fe66cf8c80 New Expert Configuration setting to not offer Safe Mode in the UI
/org.openoffice.Office/Common/Misc/OfferSafeMode (default: true), controlling:
* "Help - Restart in Safe Mode..." menu entry
* "Restart LibreOffice to enter safe mode" checkbox in the "Crash Report" dialog
* "To start temporarily with a fresh user profile,..." tip of the day

(It does not control the --safe-mode command line argument, though.)

Change-Id: I66084448a1ba9427aaafef630187b4bf25219a2c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165926
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-04-10 14:54:41 +02:00
Noel Grandin
7f9a35e6ef use unordered_map for ScTokenMatrixMap
which is considerably faster

Change-Id: Ic44d88d8ef222edd91de8ae0e79d77a99c5c2e95
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165924
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-04-10 14:50:57 +02:00
Rafał Dobrakowski
97af15c86c tdf#114441 Convert sal_uLong to better integer types
This patch changes the usage of type sal_uLong in sc module to sal_Int32.
Looking into ScRefreshTimer constructor in sc/inc/refreshtimer.hxx, it
becomes clear that sal_Int32 is a good choice. The usage is for
communicating the refresh delay, measured in seconds. The reason to use
signed variables is to follow the convention in ScRefreshTimer class.

Change-Id: Ib565fd50ec4e6a46e95e9db06b7798a0b4a38d4b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164957
Tested-by: Hossein <hossein@libreoffice.org>
Reviewed-by: Hossein <hossein@libreoffice.org>
2024-04-10 13:55:11 +02:00
Gabor Kelemen
fa42bdabca Drop unused define CALC_TEST_PERF
Seems to be not used since 2016 commit
52871b360c

Change-Id: Ie1f95ece6d9b6efe93dd16adcdacd644deb21fdb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165914
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-10 13:31:03 +02:00
Zainab Abbasi
547f3215fc tdf#143148 Use pragma once instead of include guards
use pragma once

Change-Id: I96babd680b494600b0e159ab757208fcecf2049e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165922
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
2024-04-10 12:40:43 +02:00
Stephan Bergmann
8559e6b5a5 Adapt flatpak build to upstream changes
<29463ebd29>
"Merge pull request #288 from
EliasTheGrandMasterOfMistakes/EliasTheGrandMasterOfMistakes-patch-2: Update JDK,
GVFS and ANT"

Change-Id: I021ddb9ca6b1fbec6cfe22784a9d023db2fa737c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165920
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-04-10 12:05:32 +02:00
Noel Grandin
7883397826 simplify OGenericUnoController init
Change-Id: I9053e8f320b140bbb6907daac61939258245ff7f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165913
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-04-10 10:18:47 +02:00
Noel Grandin
1dd0d2ce71 OGenericUnoController remove some typedefs
Change-Id: I9e582c19cd6a169d839aea9d2192e31ab06366b1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165912
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2024-04-10 10:17:54 +02:00
Caolán McNamara
834cbc4ccf kit: Update formulas when switching tabs
we moved to not forcing a redraw on switching tabs
at:

commit 9f3ee2b27c
Date:   Sun Jan 14 16:29:56 2024 +0000

    don't invalidate when switching tabs

but in a scenario (to which two_sheets.ods is updated to capture) where
there is no view/user active on a sheet B that depends on cells in sheet
A, then when A is updated, B does not update automatically to reflect
the changes in A.

So, on switching to a tab, do the check for out of date formulas on
the switched to tab.

Change-Id: Ibbba83119adbd323b42314dbd9bcba6f797e5934
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165911
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-04-10 09:47:53 +02:00
Caolán McNamara
164bde27ba cid#1596245 Explicit null dereferenced
Change-Id: I3912517648f76cd7a0fd651cf592bce427dc69f5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165900
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
2024-04-10 09:47:34 +02:00
Miklos Vajna
4dc788ea10 CppunitTest_sw_rtfexport2: avoid DECLARE_RTFEXPORT_TEST
No need to go via Writer-specific macros here.

Change-Id: I50de20f3199878db2b9fe7e66f09b2620e43cc3c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165918
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2024-04-10 09:28:19 +02:00
Gabor Kelemen
1a91641fd6 tdf#146619 Drop unused 'using namespace' in: sw/
Change-Id: I56463130ab617b0e11e237718cb8456913373818
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165696
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-10 09:19:42 +02:00
Gabor Kelemen
d70f461d83 tdf#146619 Drop unused 'using namespace' in: sc/
Change-Id: I03478dd4c8e3c2ac88c0fe5e51efd53b09888475
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165695
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-10 09:19:27 +02:00
Stephan Bergmann
42f6e89d5e Avoid -O2 in AC_PROG_CC/CXX, work around occasional Clang 12.0.1 SEGVs
At least with one ASan/UBSan setup of mine using LODE's Clang 12.0.1,
./autogen.sh would occasionally detect -std=gnu11 as the required CC "option to
enable C11 features" (which would in turn cause building external/firebird to
fail oddly; an issue worth investigations of its own), because Clang would
occasionally crash with a SEGV on the corresponding configure test program's
first invocation (without -std=gnu11) when invoked with -O2 (and happen to
succeed on second invocation with -std=gnu11, so configure thinks that's
needed), see below for a relevant config.log excerpt.

When CC/CXX are already set (as is the case in this scenario), we could arguably
skip the AC_PROG_CC/CXX checks entirely (and thus avoid configure potentially
adding -std=gnu11 to CC), but at least AC_PROG_CC also internally sets the GCC
shell var, which we use in configure.ac.  So better be conservative and just
avoid -O2 during AC_PROG_CC/CXX (whatever the autoconf motivation to include it
in the first place).

> configure:8165: checking for /home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang -fsanitize=address -fsanitize=undefined -fsanitize=float-divide-by-zero -fsanitize=local-bounds -fsanitize-blacklist=/home/sberg/lo0/core/sanitize-ubsan-excludelist option to enable C11 features
> configure:8180: /home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang -fsanitize=address -fsanitize=undefined -fsanitize=float-divide-by-zero -fsanitize=local-bounds -fsanitize-blacklist=/home/sberg/lo0/core/sanitize-ubsan-excludelist  -c -g -O2  conftest.c >&5
> PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash backtrace, preprocessed source, and associated run script.
> Stack dump:
> 0.	Program arguments: /home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang -fsanitize=address -fsanitize=undefined -fsanitize=float-divide-by-zero -fsanitize=local-bounds -fsanitize-blacklist=/home/sberg/lo0/core/sanitize-ubsan-excludelist -c -g -O2 conftest.c
> 1.	<eof> parser at end of file
> 2.	Code generation
>  #0 0x000055f3a890caf2 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x1c3eaf2)
>  #1 0x000055f3a890a734 llvm::sys::RunSignalHandlers() (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x1c3c734)
>  #2 0x000055f3a887b998 CrashRecoverySignalHandler(int) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x1bad998)
>  #3 0x00007f750d24e520 (/lib/x86_64-linux-gnu/libc.so.6+0x42520)
>  #4 0x000055f3a93f9cd4 llvm::DIE::getUnitDie() const (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x272bcd4)
>  #5 0x000055f3a9404574 llvm::DwarfDebug::finishEntityDefinitions() (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x2736574)
>  #6 0x000055f3a941df99 llvm::DwarfDebug::finalizeModuleInfo() (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x274ff99)
>  #7 0x000055f3a9421128 llvm::DwarfDebug::endModule() (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x2753128)
>  #8 0x000055f3a93f1219 llvm::AsmPrinter::doFinalization(llvm::Module&) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x2723219)
>  #9 0x000055f3a82478f5 llvm::FPPassManager::doFinalization(llvm::Module&) (.localalias) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x15798f5)
> #10 0x000055f3a8253900 llvm::legacy::PassManagerImpl::run(llvm::Module&) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x1585900)
> #11 0x000055f3a8bb57d3 (anonymous namespace)::EmitAssemblyHelper::EmitAssembly(clang::BackendAction, std::unique_ptr<llvm::raw_pwrite_stream, std::default_delete<llvm::raw_pwrite_stream> >) (.constprop.0) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x1ee77d3)
> #12 0x000055f3a8bb76ea clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::HeaderSearchOptions const&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::DataLayout const&, llvm::Module*, clang::BackendAction, std::unique_ptr<llvm::raw_pwrite_stream, std::default_delete<llvm::raw_pwrite_stream> >) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x1ee96ea)
> #13 0x000055f3a9825876 clang::BackendConsumer::HandleTranslationUnit(clang::ASTContext&) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x2b57876)
> #14 0x000055f3aa35c549 clang::ParseAST(clang::Sema&, bool, bool) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x368e549)
> #15 0x000055f3a91ef2d9 clang::FrontendAction::Execute() (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x25212d9)
> #16 0x000055f3a91903a3 clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x24c23a3)
> #17 0x000055f3a92a2fd8 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x25d4fd8)
> #18 0x000055f3a7798815 cc1_main(llvm::ArrayRef<char const*>, char const*, void*) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0xaca815)
> #19 0x000055f3a77961a7 ExecuteCC1Tool(llvm::SmallVectorImpl<char const*>&) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0xac81a7)
> #20 0x000055f3a9039689 void llvm::function_ref<void ()>::callback_fn<clang::driver::CC1Command::Execute(llvm::ArrayRef<llvm::Optional<llvm::StringRef> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool*) const::'lambda'()>(long) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x236b689)
> #21 0x000055f3a887baa7 llvm::CrashRecoveryContext::RunSafely(llvm::function_ref<void ()>) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x1badaa7)
> #22 0x000055f3a903a802 clang::driver::CC1Command::Execute(llvm::ArrayRef<llvm::Optional<llvm::StringRef> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*, bool*) const (.part.0) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x236c802)
> #23 0x000055f3a900fbec clang::driver::Compilation::ExecuteCommand(clang::driver::Command const&, clang::driver::Command const*&) const (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x2341bec)
> #24 0x000055f3a9010679 clang::driver::Compilation::ExecuteJobs(clang::driver::JobList const&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) const (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x2342679)
> #25 0x000055f3a901e8f1 clang::driver::Driver::ExecuteCompilation(clang::driver::Compilation&, llvm::SmallVectorImpl<std::pair<int, clang::driver::Command const*> >&) (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0x23508f1)
> #26 0x000055f3a7717e6f main (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0xa49e6f)
> #27 0x00007f750d235d90 (/lib/x86_64-linux-gnu/libc.so.6+0x29d90)
> #28 0x00007f750d235e40 __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x29e40)
> #29 0x000055f3a7795b55 _start (/home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang+0xac7b55)
> clang-12: error: clang frontend command failed with exit code 139 (use -v to see invocation)
> clang version 12.0.1 (https://github.com/llvm/llvm-project.git fed41342a82f5a3a9201819a82bf7a48313e296b)
> Target: x86_64-unknown-linux-gnu
> Thread model: posix
> InstalledDir: /home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin
> clang-12: note: diagnostic msg:
> ********************
>
> PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
> Preprocessed source(s) and associated run script(s) are located at:
> clang-12: note: diagnostic msg: /tmp/conftest-968380.c
> clang-12: note: diagnostic msg: /tmp/conftest-968380.sh
> clang-12: note: diagnostic msg:
>
> ********************
> configure:8180: $? = 139
> configure: failed program was:
> | /* confdefs.h */
> | #define PACKAGE_NAME "LibreOffice"
> | #define PACKAGE_TARNAME "libreoffice"
> | #define PACKAGE_VERSION "24.8.0.0.alpha0+"
> | #define PACKAGE_STRING "LibreOffice 24.8.0.0.alpha0+"
> | #define PACKAGE_BUGREPORT ""
> | #define PACKAGE_URL "http://documentfoundation.org/"
> | #define LIBO_VERSION_MAJOR 24
> | #define LIBO_VERSION_MINOR 8
> | #define LIBO_VERSION_MICRO 0
> | #define LIBO_VERSION_PATCH 0
> | #define LIBO_THIS_YEAR 2024
> | #define SRCDIR "/home/sberg/lo0/core"
> | #define SRC_ROOT "/home/sberg/lo0/core"
> | #define BUILDDIR "/home/sberg/lo0/core"
> | #define USE_HEADLESS_CODE 1
> | #define ENABLE_HEADLESS 1
> | /* end confdefs.h.  */
> |
> | /* Does the compiler advertise C89 conformance?
> |    Do not test the value of __STDC__, because some compilers set it to 0
> |    while being otherwise adequately conformant. */
> | #if !defined __STDC__
> | # error "Compiler does not advertise C89 conformance"
> | #endif
> |
> | #include <stddef.h>
> | #include <stdarg.h>
> | struct stat;
> | /* Most of the following tests are stolen from RCS 5.7 src/conf.sh.  */
> | struct buf { int x; };
> | struct buf * (*rcsopen) (struct buf *, struct stat *, int);
> | static char *e (p, i)
> |      char **p;
> |      int i;
> | {
> |   return p[i];
> | }
> | static char *f (char * (*g) (char **, int), char **p, ...)
> | {
> |   char *s;
> |   va_list v;
> |   va_start (v,p);
> |   s = g (p, va_arg (v,int));
> |   va_end (v);
> |   return s;
> | }
> |
> | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
> |    function prototypes and stuff, but not \xHH hex character constants.
> |    These do not provoke an error unfortunately, instead are silently treated
> |    as an "x".  The following induces an error, until -std is added to get
> |    proper ANSI mode.  Curiously \x00 != x always comes out true, for an
> |    array size at least.  It is necessary to write \x00 == 0 to get something
> |    that is true only with -std.  */
> | int osf4_cc_array ['\x00' == 0 ? 1 : -1];
> |
> | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
> |    inside strings and character constants.  */
> | #define FOO(x) 'x'
> | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
> |
> | int test (int i, double x);
> | struct s1 {int (*f) (int a);};
> | struct s2 {int (*f) (double a);};
> | int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
> |                int, int);
> |
> | // Does the compiler advertise C99 conformance?
> | #if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
> | # error "Compiler does not advertise C99 conformance"
> | #endif
> |
> | #include <stdbool.h>
> | extern int puts (const char *);
> | extern int printf (const char *, ...);
> | extern int dprintf (int, const char *, ...);
> | extern void *malloc (size_t);
> |
> | // Check varargs macros.  These examples are taken from C99 6.10.3.5.
> | // dprintf is used instead of fprintf to avoid needing to declare
> | // FILE and stderr.
> | #define debug(...) dprintf (2, __VA_ARGS__)
> | #define showlist(...) puts (#__VA_ARGS__)
> | #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
> | static void
> | test_varargs_macros (void)
> | {
> |   int x = 1234;
> |   int y = 5678;
> |   debug ("Flag");
> |   debug ("X = %d\n", x);
> |   showlist (The first, second, and third items.);
> |   report (x>y, "x is %d but y is %d", x, y);
> | }
> |
> | // Check long long types.
> | #define BIG64 18446744073709551615ull
> | #define BIG32 4294967295ul
> | #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
> | #if !BIG_OK
> |   #error "your preprocessor is broken"
> | #endif
> | #if BIG_OK
> | #else
> |   #error "your preprocessor is broken"
> | #endif
> | static long long int bignum = -9223372036854775807LL;
> | static unsigned long long int ubignum = BIG64;
> |
> | struct incomplete_array
> | {
> |   int datasize;
> |   double data[];
> | };
> |
> | struct named_init {
> |   int number;
> |   const wchar_t *name;
> |   double average;
> | };
> |
> | typedef const char *ccp;
> |
> | static inline int
> | test_restrict (ccp restrict text)
> | {
> |   // See if C++-style comments work.
> |   // Iterate through items via the restricted pointer.
> |   // Also check for declarations in for loops.
> |   for (unsigned int i = 0; *(text+i) != '\0'; ++i)
> |     continue;
> |   return 0;
> | }
> |
> | // Check varargs and va_copy.
> | static bool
> | test_varargs (const char *format, ...)
> | {
> |   va_list args;
> |   va_start (args, format);
> |   va_list args_copy;
> |   va_copy (args_copy, args);
> |
> |   const char *str = "";
> |   int number = 0;
> |   float fnumber = 0;
> |
> |   while (*format)
> |     {
> |       switch (*format++)
> | 	{
> | 	case 's': // string
> | 	  str = va_arg (args_copy, const char *);
> | 	  break;
> | 	case 'd': // int
> | 	  number = va_arg (args_copy, int);
> | 	  break;
> | 	case 'f': // float
> | 	  fnumber = va_arg (args_copy, double);
> | 	  break;
> | 	default:
> | 	  break;
> | 	}
> |     }
> |   va_end (args_copy);
> |   va_end (args);
> |
> |   return *str && number && fnumber;
> | }
> |
> |
> | // Does the compiler advertise C11 conformance?
> | #if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
> | # error "Compiler does not advertise C11 conformance"
> | #endif
> |
> | // Check _Alignas.
> | char _Alignas (double) aligned_as_double;
> | char _Alignas (0) no_special_alignment;
> | extern char aligned_as_int;
> | char _Alignas (0) _Alignas (int) aligned_as_int;
> |
> | // Check _Alignof.
> | enum
> | {
> |   int_alignment = _Alignof (int),
> |   int_array_alignment = _Alignof (int[100]),
> |   char_alignment = _Alignof (char)
> | };
> | _Static_assert (0 < -_Alignof (int), "_Alignof is signed");
> |
> | // Check _Noreturn.
> | int _Noreturn does_not_return (void) { for (;;) continue; }
> |
> | // Check _Static_assert.
> | struct test_static_assert
> | {
> |   int x;
> |   _Static_assert (sizeof (int) <= sizeof (long int),
> |                   "_Static_assert does not work in struct");
> |   long int y;
> | };
> |
> | // Check UTF-8 literals.
> | #define u8 syntax error!
> | char const utf8_literal[] = u8"happens to be ASCII" "another string";
> |
> | // Check duplicate typedefs.
> | typedef long *long_ptr;
> | typedef long int *long_ptr;
> | typedef long_ptr long_ptr;
> |
> | // Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
> | struct anonymous
> | {
> |   union {
> |     struct { int i; int j; };
> |     struct { int k; long int l; } w;
> |   };
> |   int m;
> | } v1;
> |
> |
> | int
> | main (int argc, char **argv)
> | {
> |   int ok = 0;
> |
> | ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
> |
> |
> |   // Check bool.
> |   _Bool success = false;
> |   success |= (argc != 0);
> |
> |   // Check restrict.
> |   if (test_restrict ("String literal") == 0)
> |     success = true;
> |   char *restrict newvar = "Another string";
> |
> |   // Check varargs.
> |   success &= test_varargs ("s, d' f .", "string", 65, 34.234);
> |   test_varargs_macros ();
> |
> |   // Check flexible array members.
> |   struct incomplete_array *ia =
> |     malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
> |   ia->datasize = 10;
> |   for (int i = 0; i < ia->datasize; ++i)
> |     ia->data[i] = i * 1.234;
> |
> |   // Check named initializers.
> |   struct named_init ni = {
> |     .number = 34,
> |     .name = L"Test wide string",
> |     .average = 543.34343,
> |   };
> |
> |   ni.number = 58;
> |
> |   int dynamic_array[ni.number];
> |   dynamic_array[0] = argv[0][0];
> |   dynamic_array[ni.number - 1] = 543;
> |
> |   // work around unused variable warnings
> |   ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
> | 	 || dynamic_array[ni.number - 1] != 543);
> |
> |
> |   _Static_assert ((offsetof (struct anonymous, i)
> | 		   == offsetof (struct anonymous, w.k)),
> | 		  "Anonymous union alignment botch");
> |   v1.i = 2;
> |   v1.w.k = 5;
> |   ok |= v1.i != 5;
> |
> |   return ok;
> | }
> |
> configure:8180: /home/builder/lode/opt_private/clang-llvmorg-12.0.1/bin/clang -fsanitize=address -fsanitize=undefined -fsanitize=float-divide-by-zero -fsanitize=local-bounds -fsanitize-blacklist=/home/sberg/lo0/core/sanitize-ubsan-excludelist -std=gnu11 -c -g -O2  conftest.c >&5
> configure:8180: $? = 0
> configure:8201: result: -std=gnu11

Change-Id: I9122d0d853d0010155d57cb1d1d56f7c453d5208
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165904
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
2024-04-09 23:40:49 +02:00
RMZeroFour
e64a1dfc36 Fix typo in HelloTextTableShape makefile
The HelloTextTableShape example, which was recently ported to C++,
has a small typo in line #64 of the Makefile. It gives the user the
command to run the example, but it was missing an 'e' at the end.

Change-Id: I29af45f21ff78dbda42e5bd9e25e44f06536f7c3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165915
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
2024-04-09 22:21:44 +02:00
Mike Kaganski
2dbd0acb88 Simplify a bit
Change-Id: I92def0e5731d231583b9b03e351bc46949045b4a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165846
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-04-09 21:50:37 +02:00
Gabor Kelemen
098f366895 tdf#146619 Drop unused 'using namespace' in: scripting/
Change-Id: I84194df451ea990c515ae914741078c80e53e45b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165694
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 18:53:50 +02:00
Gabor Kelemen
ff9373bd72 tdf#146619 Drop unused 'using namespace' in: starmath/
Change-Id: I382ca117484b0928580f4bed765799e915e7b8a2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165693
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 18:53:23 +02:00
Gabor Kelemen
6f10dc1101 find-unneeded-includes: improve grepping for namespaces
for example this was not found:

extensions/source/update/check/updatecheck.cxx:58:namespace frame = com::sun::frame ;

due to the missing using and the space before the semicolon
but IWYU correctly detected it as unused

Change-Id: I404c93d41aec1a571c9ac49db7b7c7e8da824bf6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165698
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 18:53:11 +02:00
Gabor Kelemen
a919a0aa4c tdf#146619 Drop unused 'using namespace' in: reportdesign/
Change-Id: Iaf246112014d5b5da751570ca55a179232a1e9d4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165692
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 18:52:56 +02:00
Armin Le Grand (allotropia)
32d3826a36 IASS: Missing updates in OutlinerView mode
It looked like in OutlinerMode in IASS when doing
changes updating the other views were missing. After
debugging and finding no error I found out that the
text as COL_AUTO is painted white on white - all
updates happen but are invisible - argh.

After some more debugging I found that in
ViewShellBase::GetColorConfigColor only the
DrawViewShell case was handled, so I added the
OutlineViewShell now. Since that ViewShell has
no SdViewOptions I hard-coded the DOCCOLOR
to COL_WHITE.

That method returns {} aka COL_BLACK as default
which is a bad default for an office package
with paper as target, so I also changed that
to COL_WHITE - which is the default for unknown
ViewShells now that way. Also adapted the warning
to mention an 'unknown ViewShell' now.

Change-Id: I580a151b4c0a9eb46d190ba84b0c6d0798dc21d7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165907
Tested-by: Jenkins
Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2024-04-09 17:37:00 +02:00
Olivier Hallot
6cd0ef58cd Update git submodules
* Update helpcontent2 from branch 'master'
  to af2fc2b7c1d2226ce628f60415fd384ffc75a342
  - Fixes in Gallery help page
    
    Change-Id: I319b4a6c3b028bf36c86752a73855e947826b271
    Reviewed-on: https://gerrit.libreoffice.org/c/help/+/165845
    Tested-by: Jenkins
    Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2024-04-09 14:27:02 +02:00
Michael Stahl
2b47fae7e3 tdf#88214 sw: text formatting: adapt empty line at end of para to Word
For an empty line at the end of an empty paragraph, Writer already uses
any existing text attribute in the paragraph, see for example
testEmptyTrailingSpans.

For an empty line at the end of a non-empty paragraph, Writer text
formatting uses only paragraph attributes, ignoring any text attributes,
whereas the UI will display the attributes from the text attributes
(such as font height) if you move the cursor there.

Word uses text attributes also in this case, so adapt the inconsistent
Writer behaviour: text formatting now uses text attributes too.

Apparently this can be achieved by calling SeekAndChgBefore() instead of
SeekAndChg().

Add another compat flag "ApplyTextAttrToEmptyLineAtEndOfParagraph" to
preserve the formatting of existing ODF documents.

Adapt test document fdo74110.docx, it has a line break with "Angsana
New" font.

Change-Id: I0863d3077e419404194b47110e4ad2bdda3d11c4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165887
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2024-04-09 14:10:19 +02:00
Christian Lohmaier
b523a72fd0 Update git submodules
* Update translations from branch 'master'
  to 162f2568c09f9391b8ceb5a123757a9ed75e7898
  - update translations for master
    
    and force-fix errors using pocheck
    
    Change-Id: I90a33a0294035c5efd3e6b130d340924d4bc9d4f
2024-04-09 12:38:12 +02:00
Tuukka Orava
f3d0a184c4 tdf#147132 Flatten Basic function implementations
Change-Id: I077e042c82cbefd1d46db5ca8d5983a0870a296c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165903
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2024-04-09 10:51:14 +02:00
Gabor Kelemen
83f1a6f817 find-unneeded-includes: improve list of namespaces
Add 'star' for com::sun::star instances

Add some vcl-specific ones

'PackageKit' gave always a false warning due to the similarity in
org/freedesktop/PackageKit/*hpp
and
officecfg::Office::Common::PackageKit::*

Change-Id: I109e7a2e8d7588d62b2a6bec2e55ec32e993e49e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165697
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 10:43:59 +02:00
Gabor Kelemen
4aa43e62e4 tdf#146619 Drop unused 'using namespace' in: xmlsecurity/
Change-Id: I95b84eff5d8bb288aa704620db328d89062efdf4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165689
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 10:43:32 +02:00
Gabor Kelemen
6e1647699f tdf#146619 Drop unused 'using namespace' in: chart2/
Change-Id: I632d0dda0e62e5b1bf0956e731ab5ed6417db1ad
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165688
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 10:43:12 +02:00
Miklos Vajna
e2b968e682 sw: document SwTextFormatColls
Text is never clear, it means paragraph in this case, since we have
SwCharFormats for character styles.

Change-Id: Iba21df71053f0b4fbcc0616c024e5cd2972ad44a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165902
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2024-04-09 10:25:17 +02:00
Mohit Marathe
e211607dff tdf#42982: Improve UNO API error reporting
Change-Id: If075965f2b020767b35692ea110ca768daf342c4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165228
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
2024-04-09 09:06:27 +02:00
Gabor Kelemen
4c1d626d72 Fix typo: compytibility
Change-Id: I989d0a9510e6a3691a4c1ba89dd3f04e62906292
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165691
Tested-by: Jenkins
Reviewed-by: Gabor Kelemen <gabor.kelemen.extern@allotropia.de>
2024-04-09 08:46:04 +02:00