Commit graph

476214 commits

Author SHA1 Message Date
Noel Grandin
485300f9ae loplugin:unusedmethods
Change-Id: Ib89ab59f7ad7e90b2a44ddd122176cde904fba4d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135520
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-06-09 12:08:15 +02:00
Xisco Fauli
0e1a0ecffa get-forum-attachments: Add 2 more mso forums
Add login mechanism for them

Also add --config and --outdir arguments to
set the pathes

Change-Id: I641f10396e1f4cf5bdb19da287b1a2962ff4e2ca
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135495
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-06-09 12:02:31 +02:00
Caolán McNamara
b1d57168b8 a Frame has max two children
during creation it might not have all its children created yet
if a11y querys it during its setup.

Change-Id: Ifbbec7eeb80409dc5e871c2022d1ee1e36c6e74f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135526
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-09 11:51:15 +02:00
Andras Timar
8494815ba5 Update git submodules
* Update dictionaries from branch 'master'
  to 68b272ec160ded8157c13117e350fc4dfc3037fb
  - Updated Danish spellchecker
    
    Change-Id: I7c8ff2e7fac358706a580f2b24842ade0a1baa55
    Reviewed-on: https://gerrit.libreoffice.org/c/dictionaries/+/135531
    Tested-by: Andras Timar <andras.timar@collabora.com>
    Reviewed-by: Andras Timar <andras.timar@collabora.com>
2022-06-09 11:42:31 +02:00
Noel Grandin
e9f407fbf0 can pass by const& here
no need to copy

Change-Id: I1fcc5d645a8f5278e2122a168b00c846d75bc091
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135522
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-06-09 11:27:03 +02:00
Stephan Bergmann
0bbbde84b0 tdf#140886: Make "Do you really want to open it?" more reliable
70009098fd "tdf#128969: Let the user explicitly
decide to execute an external program" had shoehorned that new warning dialog
into the existing XSystemShellExecute::execute IllegalArgumentException return
path, which caused some issues:  For example, it caused the warning dialog to
reappear after you acknowledged it on macOS (see comment at
<https://bugs.documentfoundation.org/show_bug.cgi?id=140886#c10> "Allow
hyperlink opening on file with execute bit set ref. CVE-2019-9847"), and it
caused the warning dialog to erroneously appear for a non-existing file on
Windows (see comment at
<https://gerrit.libreoffice.org/c/core/+/124422/2#message-ac76b728fedc53e7d0a04c99f00364068b51a8ea>
"tdf#128969: Let the user explicitly decide to execute an external program").

So rather than reusing IllegalArgumentException for this case, use a different
kind of exception to trigger that warning dialog.  The existing
AccessControlException (which is also a RuntimeException) happened to fit more
or less well.

Change-Id: I3f743c21be48d54f10951006ef3d7172e23e9076
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135524
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-06-09 11:17:14 +02:00
Seth Chaiklin
a54e10c270 Update git submodules
* Update helpcontent2 from branch 'master'
  to dae8c0f4225b25d4612f7a9db86fc4518bf4b3d9
  - (Related) tdf#126658 update Arrow styles help to reflect UI change
    
         text/shared/01/05200300.xhp (Arrow Styles tab)
           * update new control names
           * corrections to description of tab and its use
    
         text/shared/00/00040502.xhp  ("howtoget" for Arrow Styles)
           + add appl-switches with 
               * menu variations for Writer, Calc, Draw and Impress
               + access variations using toolbars
           + add right-click access
           + add section for embedding
           * rename German ID
    
    
    Change-Id: Ic224d72b2abeee777063626f4dcdb570562d3650
    Reviewed-on: https://gerrit.libreoffice.org/c/help/+/133037
    Tested-by: Jenkins
    Reviewed-by: Seth Chaiklin <sdc.blanco@youmail.dk>
2022-06-09 11:16:14 +02:00
Balazs Varga
246d4f14c3 Ignore warning C4723 for windows arm64 build
Tinderbox message from windows arm64 build:
C:\cygwin\home\tdf\jenkins\daily_workspace\tb\src_master\include\basegfx\range\basicrange.hxx(276) :
error C2220: the following warning is treated as an error
C:\cygwin\home\tdf\jenkins\daily_workspace\tb\src_master\include\basegfx\range\basicrange.hxx(276) :
warning C4723: potential divide by 0
LINK : fatal error LNK1257: code generation failed

Change-Id: I86ce1a0ea6abdf46464dcac95b9b591120782a13
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135523
Tested-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
Reviewed-by: Thorsten Behrens <thorsten.behrens@allotropia.de>
2022-06-09 11:04:12 +02:00
Khaled Hosny
be39eba9a3 Use same glyph width in PDF drawing and font subset
During PDF drawing we already know the glyph width, but when subsetting
we get it again from the font subset.

For fonts without CFF table this is redundant but harmless, but for
fonts with CFF table, if the CFF and hmtx table (the authoritative
source of glyph widths) disagree, we will be drawing the PDF string with
the wrong adjustment resulting in displaced glyphs. This is a font bug,
but avoiding redundancy and having one source of truth is an improvement
overall.

I kept the code that calculates advance widths for font subsets, just in
case it is is still used elsewhere.

Change-Id: I757cd0c2ebb6477b2f840d0005e84b5a131f7efb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135442
Tested-by: Jenkins
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-09 10:03:51 +02:00
Jan-Marek Glogowski
136fac12eb redland WASM: add Emscripten flags to fix NEH build
Change-Id: I4ed242e774e1ce2ac05dabb9fc657329dc4a63c6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135519
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2022-06-09 09:50:46 +02:00
Seth Chaiklin
64b5eb2286 tdf#149414 change Format Object label for Calc and Impress
The label for Calc was Format > OLE Object (using
  .uno:ObjectMenu), while the label for Impress was
  Format > "Object and Shape" (using .uno:FormatObjectMenu).
  This patch (a) changes the label of .uno:FormatObjectMenu
  from "Object and Shape" to "Text Box and Shape"
  (to bring it in line with Writer). This change appears
  immediately in Impress, and (b) changes the .uno:ObjectMenu
  in Calc to .uno:FormatObjectMenu, which also gives the
  "Text Box and Shape" label, which is also more appropriate
  for its submenu.

  Kept the same keyboard accelerator "o", which was used both
  in Impress and Calc.

Change-Id: Ifcf7b953b6bed262d630f7a07bf1f5000ee33aa4
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135162
Tested-by: Jenkins
Reviewed-by: Seth Chaiklin <sdc.blanco@youmail.dk>
2022-06-09 09:19:42 +02:00
Miklos Vajna
19632bf0bc CppunitTest_sw_ooxmlexport14: avoid mustTestImportOf()
Can use CPPUNIT_TEST_FIXTURE() instead.

See commit a226cec52e
(CppunitTest_sw_rtfimport: convert one testcase to use
CPPUNIT_TEST_FIXTURE(), 2019-11-05) for motivation.

Change-Id: I6d5c130ea25982d2cc0dc424a79c6962c1aa4f1a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135510
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-06-09 08:08:01 +02:00
Noel Grandin
91fef4a475 clang-tidy modernize-pass-by-value in editeng
Change-Id: Ibf912c597896a2ac0bf3ba8108f55c5018115bb0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135501
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-06-09 07:56:10 +02:00
Caolán McNamara
66b1ebd4dd gtk: let math GtkIconViews flow to fill available space with icons
Change-Id: I25f3433e9404ac1938568607a9a52a50ca8a7892
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135513
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-08 22:24:51 +02:00
Caolán McNamara
50c478fd84 GtkIconView uses a different way to link model and view
Change-Id: I1ad2734c9f28568433de8b9532cf20da8a27f7cb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135512
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-08 22:24:37 +02:00
Caolán McNamara
83c2a61737 drop two unused suppressions
Change-Id: I0bf5bed7fbfb3b46c1c9a48969f492b5745b1fb5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135511
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-08 22:24:06 +02:00
Andrea Gelmini
19a67603c7 Fix typo
Change-Id: Id5517254be4e108c4aeedbd067f9bf3097f89452
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135515
Tested-by: Julien Nabet <serval2412@yahoo.fr>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-06-08 21:18:11 +02:00
Andrea Gelmini
33f88380fb Fix typo
Change-Id: I278a23c9dc7a20f293e8167ee3c0492679e81f8d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135516
Tested-by: Julien Nabet <serval2412@yahoo.fr>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-06-08 21:17:44 +02:00
Andrea Gelmini
16af8e2185 Fix typo
Change-Id: I6463eb09c5bac07e6aa8e23b4b5eab06172ab2b7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135514
Tested-by: Julien Nabet <serval2412@yahoo.fr>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-06-08 21:16:33 +02:00
Julien Nabet
a943e7ddd1 tdf#149470: Firebird, Clob may need several segments to store a very long input
Change-Id: I85c7789f46d834d2ae1b251f915382f833bd529d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135480
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Tested-by: Jenkins
2022-06-08 21:13:22 +02:00
Michael Stahl
12acdce71d (related: tdf#139514) sw: fix Undo of delete with at-para fly
Nonobviously, there are situations where the anchor node must be
preserved and restored when it's not on the node that is being deleted.

(probably regression from commit 91b2325808)

Change-Id: I39f09ddb631204c8ad522f9ec7068d235ca94ad2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135509
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2022-06-08 21:05:37 +02:00
Eike Rathke
33a8c4bd0e Related: tdf#149484 Write proper <number:boolean-style> with <number:text>
Change-Id: I46b7987dde25840ae0b6e5871b14e3806c6e4ac8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135508
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2022-06-08 20:49:53 +02:00
Heiko Tietze
755e0cd60d Resolves tdf#149010 - MInor UI fixes
* Next/Previous controls placed in an extra frame
* This frame becomes hidden in case of picture and objects
(next/prev is only possible for frames)

Change-Id: Iab7042b72efa7857c5405a8c345ba03d6b975519
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135494
Tested-by: Jenkins
Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2022-06-08 20:35:43 +02:00
Michael Stahl
85376a0234 tdf#133957 sw: don't delete flys on Backspace/Delete keys
Also fixes: tdf#134007 tdf#138835 tdf#139514

When a character is deleted via the keyboard by Backspace or Delete key,
an artificial selection is created in SwWrtShell::DelLeft()/DelRight().

Ideally this should not delete flys that may be anchored to the
paragraphs, but unfortunately this may happen if there are only 2 empty
paragraphs in the section, because then the artificial selection cannot
be distinguished by the SwDoc implementation from a selection from
Ctrl+A (Select All), which *should* delete the flys.

So introduce a new flag that needs to be passed down multiple layers so
that SwUndoDelete can use it to determine if flys should be deleted, and
translating it to a flag that had been introduced to preserve flys in
ReplaceRange() previously.

There are a couple more callers that look like they want to "replace"
some text, so guess a bit at where to set this new flag.

(note: of course fly anchored *as char* must be deleted via keys.)

(regression from commit e75dd1fc99)

Change-Id: Ib4467476b12a12aefbbcb74ab9802f9318cf9aa0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135476
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
2022-06-08 20:31:40 +02:00
Eike Rathke
025231224b Resolves: tdf#149484 Read and handle <number:text> in <number:boolean-style>
Change-Id: I1be5f2be908eb88aa4ef7436ea7c09f35b076acf
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135507
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2022-06-08 20:15:44 +02:00
Eike Rathke
2932dc7aa0 Related: tdf#149484 Display BOOLEAN literal string text additions
Change-Id: Ifbaf0b18178091c3a340a7c4bc66f78397aadc18
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135506
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Jenkins
2022-06-08 20:15:19 +02:00
Jan-Marek Glogowski
98cfc7db5e libtiff WASM: add Emscripten flags to fix NEH build
Change-Id: I3ea1ca064cdddee1bea6b5816f63f0e4a93217de
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135505
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2022-06-08 18:53:32 +02:00
Jan-Marek Glogowski
ea5a0918c8 VCL add vcl::WindowPosSize abstract class
... and use it to remove a duplicate and simplify code.

Should mostly be a refactoring, which was mainly done by some
larger sed calls, except for the new API calls, which helped
shrinking some LOC. All data is also now private.

Originally two of the "replaced" "classes" had unsigned width
and height and one had signed. Noel pointed out, that during
calculations, the value might get negative temporarly, so this
now settles with signed values. Still the set size should never
be negative and this is enforced this way. Not sure that is what
Noel had in mind.

This also includes:
- rename WindowState => WindowData
- rename WindowStateMask => WindowDataMask
- rename WindowStateState => WindowState
- move WindowState and WindowDataMask to vcl/windowstate.hxx
- move WindowData(Mask) and WindowState into vcl namespace
- readability: replace or'ed WindowState enums with "meta" enums
  + add "meta" WindowState enums PosSize and PosSizeState

Change-Id: Icd16cfb498531aa7238ddbde83fcb0ed6d9e4f77
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135426
Tested-by: Jenkins
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
2022-06-08 18:17:17 +02:00
Miklos Vajna
d4123356c6 RTF filter: allow measuring page borders from the edge of the page
This is similar to commit 51942eafdb (DOC
import: allow negative page border distances, 2022-06-08), except here
we map \pgbrdropt's 5th bit to the "from page edge" bool, and then the
rest of the import works already after the DOCX fixes.

Similarly, the export has to map the "from page edge" bool to \pgbrdropt
and has to call into editeng::BorderDistancesToWord(), but the rest of
the process works after the DOCX fixes.

Change-Id: Ic88f1ab17ac169025c38790ffa895748df0a76c0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135502
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2022-06-08 17:46:58 +02:00
Rafael Lima
c44fc50569 Update git submodules
* Update helpcontent2 from branch 'master'
  to fc9022d593c7b7ae9818ed4b4502a2743e7ac377
  - Fix sentence about solver settings
    
    As pointed out by Adolfo in change 40ee3181de08d372b5a25bb691644a94d3ffe9bd, the word "beware" was used incorrectly. This patch fixes it.
    
    Change-Id: I3b2dd94b04b9c9c5ca5dc9c0b4c99a8e1c048941
    Reviewed-on: https://gerrit.libreoffice.org/c/help/+/135384
    Tested-by: Jenkins
    Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2022-06-08 16:37:44 +02:00
Luboš Luňák
118bafcfd1 use recursive mutex for LOK queue
Callbacks may be invoked while calling getLOKPayload(), which
would try to lock the mutex again. I actually originally expected
this possibility, as the comment and moving the data to
temporaries in CallbackFlushHandler::enqueueUpdatedTypes()
shows, I just didn't realize the used mutex wasn't recursive
and so would deadlock.

Change-Id: I2b5c4b6b4c1a3933a32ae4641830877e085f2b6c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135499
Tested-by: Jenkins
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2022-06-08 16:10:25 +02:00
Seth Chaiklin
7905dba8a5 fix typos
Change-Id: I47acb63703d007da7493d9baaa5569bc375e4f56
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135386
Reviewed-by: Seth Chaiklin <sdc.blanco@youmail.dk>
Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2022-06-08 14:52:58 +02:00
Caolán McNamara
6f17d42f25 tdf#119827 implement GtkBuilder "scale" property for font size
and use it for the case in charnamepage

Change-Id: I5920aa429c750e9b147cbc09a6f3814166851a8c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135493
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-08 14:22:36 +02:00
Luboš Luňák
e3f8a43379 it is not our job to tell GCC whether to colorize its output
GCC's -fdiagnostics-color option is complex (read: brain-damaged),
since it depends on how the compiler was configured during building it
(https://gcc.gnu.org/onlinedocs/gcc/Diagnostic-Message-Formatting-Options.html).
So while with Clang coloring works out of the box and the option
can be used for force it in special cases, GCC depending on how
it's been built may (or may not) require the option explicitly
just to do the sane default. 13b52f50e5
added an explicitly =auto to handle that, and then
9ab2703d5c changed it to =always
depending on gb_COLOR to prevent it from overriding
explicitly used option. This results in a possible massive rebuild
when redirecting build output (because e.g. PCHs get rebuilt if
build flags change, and ccache I think cannot use cached compilations
either).

It should not be gbuild's job to go out of its way to handle broken
tooling, so just revert both of those. If somebody uses such a lame
GCC build, either don't do that, add those explicit flags
to CXX/ENVCFLAGSCXX, or create a clean way to add flags to CXXFLAGS
or something.

Change-Id: Ieac6ac7dd198639529aba8f47983587771772349
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135467
Tested-by: Jenkins
Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-06-08 14:13:54 +02:00
Miklos Vajna
437acab38f sw: fix crash in SwFEShell::SelectObj()
Fatal signal received: SIGSEGV code: 1 for address: 0x0

SwLayoutFrame::Lower() const
        sw/source/core/inc/layfrm.hxx:101
SwFEShell::SelectObj(Point const&, unsigned char, SdrObject*)
        sw/source/core/frmedt/feshview.cxx:317
SwEditWin::MouseButtonDown(MouseEvent const&)
        sw/source/uibase/docvw/edtwin.cxx:?

Change-Id: I6c4076eef21dd80381b37ed89aa2dc8bc20fbc98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135491
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2022-06-08 12:53:10 +02:00
Colomban Wendling
d2a5b4bc0b toolkit: convert AccessibleStatusBar test to C++
Just translate the test and add required or handy CppUnit helpers.

Change-Id: Ib8ccd3490876c6302cca85e69f4d61600f7aec84
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133844
Tested-by: Jenkins
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-06-08 12:51:01 +02:00
Jean-Pierre Ledure
1d5ed2fdd1 ScriptForge - (scriptforge.py) modify URL to help page
Avoid using hardcoded release number. Use 'latest'.

Change-Id: I04f531ee736bcd94d058413634ddb49046bc6c5e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135475
Tested-by: Jean-Pierre Ledure <jp@ledure.be>
Tested-by: Jenkins
Reviewed-by: Jean-Pierre Ledure <jp@ledure.be>
2022-06-08 12:22:46 +02:00
Ilmari Lauhakangas
7784f289d2 Fix typo
Change-Id: I56b36663a460eb6840968bc02e61371ace558fa7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135490
Tested-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
Reviewed-by: Ilmari Lauhakangas <ilmari.lauhakangas@libreoffice.org>
2022-06-08 12:12:43 +02:00
Miklos Vajna
51942eafdb DOC import: allow negative page border distances
In case the margin (distance between body frame and page frame) is
smaller than the border spacing (distance between border and page
frame), then we can map that to a negative border distance during the
import of DOCX files since commit
1f127a2b9e (sw layout: allow negative page
border distances, 2022-06-07), but DOC import had the same problem.

The above commit intentionally kept the default behavior of
BorderDistanceFromWord() unchanged to avoid side effects in other
clients of that function (not DOCX import), but means that DOC import
was still broken.

Given that it turns out there are only 2 callers of
BorderDistanceFromWord(), fix the problem by allowing negative border
distances unconditionally: this simplifies code & SetBorderDistance() in
the DOC import will now get the correct border distance out of the box.

DOC export works out of the box without any additional work.

Change-Id: I6bf15b3c73823c9265218b7b3a7b869e131818db
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135484
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-06-08 12:07:48 +02:00
Tomaž Vajngerl
e216988657 tdf148321: convert OOXML inset values to text distance values
Inset values for top, bottom are calcualted differently in OOXML
and need to be coverted on import to the text distance LO values,
that place the text relative to the shape correctly.

At export, the values can be converted back to the OOXML inset
compatible values, but the values are not always converted back to
the same values as the conversion is not bijective, however they
do render the same.

This also adds the test for the conversion when importing and
checks that the exported values are expected.

Change-Id: Ic64eec1a2a80ddad997f916da3e87dc30aaa12be
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135463
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2022-06-08 11:36:12 +02:00
Miklos Vajna
e9a7ed5326 sw content controls: update the cursor at SwContentControlDlg end
Once a dropdown content control is inserted, the properties dialog can
modify list items. The desktop case updates these list items when
SfxViewFrame::Enable() calls SwView::ShowCursor(), but for some reason
the same implicit update doesn't happen in the LOK case.

This means adding new list items requires leaving the content control &
entering again, then the dropdown shows the new list items, which is
confusing. And also the update (when it works) is implicit, so it can
break without us noticing.

Fix the problem by explicitly updating the cursor before ending the
properties dialog: this will scroll to the cursor position, but that's
not a problem since the properties dialog is always editing the content
control at the current position anyway.

Show / hide is used because that's an easy way to call
SwCursorShell::UpdateCursor(), which is private to us.

Change-Id: I43aca24c2961ef6c4cc14f895edd6f3f22980148
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135483
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
2022-06-08 11:07:35 +02:00
Miklos Vajna
1cb9274494 CppunitTest_vcl_pdfexport: reduce test doc size in testAlternativeText
A one-pixel image will do the job.

Change-Id: Ied9b51c104a39b0bcf5401d8486c11f87c979805
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135477
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-06-08 09:04:06 +02:00
Noel Grandin
bf29483599 tdf#81293 dialog “manage names” forgets size and column width settings
I can't see any reason for this code to be this way. I can
see that Jim has tried to make some dialogs retain window size and
position. Surely all dialogs should be able to do this?
Unfortunately, it has been this way since initial commit.

Let us live dangerously and see what happens if we give
power to ALL the dialogs.

   VIVA LA REVOLUTION!!!

Change-Id: I44e389ba3cb46793365607d36a05474584ee6490
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135478
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-06-08 08:40:26 +02:00
Mark Hung
3e754c07fa tdf#149089 fix extra mini space in text grid.
1. Create Justify::SnapToGridEdge() to adjust kern array
under CJK textgrid GRID_LINES_CHARS mode when snap to chars is off.
This function can handle a) Unicode IVS b) rInf.GetSpace() like
what CJKJustify() does.  c) rInf.GetKern() value for letter spacing.

Excluded parts comparing to original kern array adjustment:
a) Kana compression under textgrid mode has been removed. Kana compression
is used to compress space of punctuation. It doesn't make sense to
perform that under textgrid node.
b) Inserting nSpaceAdd for CH_BLANK is removed. I don't know its
purpose.

2. Use Justify::SnapToGridEdge() in GetTextSize(), GetTextBreak(),
DrawText(), GetModelPositionForViewPoint() to adjust kern array
consistently.

Change-Id: I136a92f513fae05af2fb429e747356ba7eedec7f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135086
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-06-08 08:14:25 +02:00
Caolán McNamara
0515ad1966 add LIBTIFF to cross-compiling targets
with an eye to win_arm64 cross build failure

Change-Id: I6872859f288168352e3e70c1d559f4d318439958
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135479
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-06-08 07:26:50 +02:00
Andrea Gelmini
f593c328b1 Fix typos
Change-Id: If282a3a9f68de2cf0f1576ea34b56b9316f03ef6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135470
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-06-08 07:21:59 +02:00
Rafael Lima
15e182148b Update git submodules
* Update helpcontent2 from branch 'master'
  to 40ee3181de08d372b5a25bb691644a94d3ffe9bd
  - Related tdf#38948 Warn that Calc Solver does not save model to file
    
    Based on Comment 36 from bug 38948, the help should make it clearer that Solver models are not saved to the file by LO Calc.
    
    This patch changes the current <note> into a <warning> and makes it clearer that solver settings are not saved.
    
    Change-Id: Ie1cdf5a82c105c371e05b85ccad6736ed5e74a3f
    Reviewed-on: https://gerrit.libreoffice.org/c/help/+/135272
    Tested-by: Jenkins
    Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2022-06-07 23:44:20 +02:00
Tomoyuki Kubota
d1581fe4cc rPosition to pPosition
Change-Id: I5c1bda5419752288e494e2116bef8d258a1de4c2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133869
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-06-07 21:10:21 +02:00
Xisco Fauli
8b8e9d3126 bin: Add script to get attachments from OO forums
Testing it locally, I could download 52.000 documents
Reuse mimetypes dictionary from get-bugzilla-attachments-by-mimetype
by putting it into an external file

Change-Id: I875d90f6119c3c3bdfea6a0efd3bbc8c5be1eb63
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135457
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2022-06-07 20:26:13 +02:00
Attila Szűcs
8741fd0e0a tdf#43244 sw: show stripped line-end spaces on margin
in View->Formatting Marks mode instead of hiding them
This way it's possible to avoid interoperability issues
better, when these (now visible) spaces are stripped only
in Writer, but not in MSO, resulting different layout,
i.e. bad paragraph alignment, because the users can
notice the extra spaces and remove them in Writer.

Extend SwHolePortion::Paint() to paint its text,
what is probably just a bunch of spaces.

It's an initial fix for tdf#43100, tdf#120715 and tdf#104683
(cursor movement on the hidden spaces, end of paragraph sign
before the hidden spaces, unable to select spaces after the margin).

Follow-up to commit 93d7bdcb85
"fdo#33167, i#20878: Show spaces at the end of line".

Co-authored-by: Tibor Nagy (NISZ)

Change-Id: I48df3b41af37c77fd594bb6776ca30e845c51490
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135104
Tested-by: László Németh <nemeth@numbertext.org>
Reviewed-by: László Németh <nemeth@numbertext.org>
2022-06-07 19:28:48 +02:00