summaryrefslogtreecommitdiff
path: root/sw
AgeCommit message (Collapse)Author
2021-09-22tdf#95378 Writer Navigator: Track hyperlinksJim Raykowski
Continued effort for request to highlight corresponding Navigator tree items at document cursor position. Change-Id: I21c6b45308c7de654dbf1f904c30336a6229722c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122338 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2021-09-21Typo: sparatorIndex->separatorIndexJulien Nabet
Change-Id: Ie43ef6b231c1cb6dd7be516f47e84c12b5684c40 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122403 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-09-21tdf#39828 sw: fix table formula calculation at track changesLászló Németh
Tracked deleted cell content, e.g. removed digits of the numbers were used in calculation instead of the actual table content. (For example, if the cell content changed from "1" to "2", tracked cell text is a crossed out "1" and a plain "2", and Writer calculated with "12" instead of "2".) Change-Id: Iecc91585cd37be3647d85f97ba1716a5fc836242 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122393 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2021-09-21Fix splitting of "permission-for-group/-user:" stringsStephan Bergmann
...that had been introduced in f5c266695a4a88da7db971a21915e2bbf758d48e "tdf#66398 Parse and output permissions for DOCX using bookmarks": For one, in DocxAttributeOutput::DoWritePermissionTagStart permissionIdAndName was left empty in the permission-for-user case. This had already been addressed for DocxAttributeOutput::DoWritePermissionTagEnd in 7f0b7410e84a222d8fbee7c4fadd3b40028a068d "permissionIdAndName is empty in permission-for-user case". But from the calling code it looks like in both functions that permission will always start with either "permission-for-group:" or "permission-for-user:", so assert that rather than silently doing nothing if the assumption is wrong. For another, in both functions the code didn't take any precaution if permissionIdAndName didn't contain a colon (which would cause undefined behavior when OUString::copy is called with a negative count argument). Again, from the calling code assume that permissionIdAndName will always contain a colon, and assert that. Change-Id: Ia7432413c138d47efbe8aec76f14c561ac241fb3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122387 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-09-21tdf#144347 sw: fix tracked deletion of table with tracked contentLászló Németh
When a table contained tracked content already, its tracked deletion (or cut) didn't work correctly, if the deletion contained also the text before or after the table: accepting the deletion left an empty table in the text, also Hide Changes showed an empty table before that in the place of the deleted text. Follow-up of commit f481c2c8e74bded11fac754e493560391229dbcd "df#144057 sw track changes: hide deleted table rows". Change-Id: If3294fe0316df7c065e7ff63290c1723386ec7ba Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122382 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2021-09-21fix !HAVE_FEATURE_DESKTOP build, IsOver->OverlapsCaolán McNamara
and change some commented out cases Change-Id: Icc60b19de7d12a78e7d40e7aa94dae40dc8b60a7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122378 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-21tdf#143591 DOCX import: handle anchored objects as at-charMiklos Vajna
This partially reverts cc8f8ae55f681755f5da3bf64e4c30bb713f0383 (DOCX drawingML shape import: wp:anchor's behindDoc attribute, 2013-11-19), it seems to be more important to be consistent with the DOC import than with the VML import which is no longer used for DOCX shapes crated with Word >= 2010. Change-Id: I631da010bce1b4d3c392645e0ae3797a03665a42 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122367 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-09-21vcl: remove OutputDevice's GetDevFontSizeCount() and GetDevFontSize()Chris Sherlock
The OutputDevice::GetDevFontSize() function is only used for non-scalable (bitmap) fonts. We have stopped supporting bitmap fonts since LO 5.3, see tdf#103514: Support for bitmap-only fonts on Windows has been removed (Khaled Hosny) I found the following when removing PhysicalFontFace::SetBitmapSize(): 1. as mnHeight and mnWidth and not set by anyone, I realized I could remove them, which meant removing GetHeight() and GetWidth() 2. PhysicalFontFamily::GetFontHeights() populates heights from the collection of font faces into a sorted vector of font heights taken from PhysicalFontFace. As this no longer exists this function serves no purpose, it has been removed. 3. PhysicalFontFamily::GetDeviceFontSizeList() calls upon PhysicalFontFace::GetFontHeights(). This function takes this sorted list of font heights, and then populates and returns a new list of sizes (or rather, heights). As the heights aren't available any more, this function is also unneeded, so it has been removed. 4. OutputDevice::GetDevFontSizeCount() calls upon PhysicalFontFamily::GetDeviceFontSizeList(). This function has the side effect of initializing the list of fonts. 5. When I checked what calls on GetDevFontSizeCount(), there is only one caller - FontList::GetSizeAry() in svtools. The function returns a standard font size list if the family name is empty, or there are no font sizes (via OutputDevice::GetDevFontSizeCount()). As this will *always* be empty (see chain above) then this function just needs to always return a standard font size list. Thus OutputDevice::GetDevFontSizeCount() and GetFontSizeList() are no longer called upon by anything, so they can be removed. 6. svtool's FontList::GetSizeAry() no longer uses the FontMetric parameter, so this has been removed from the function signature, and cleanup done of the function that calls upon it in svtools, framework, editeng, and desktop. A number of variables that were no longer used due to this change were also removed. 7. This change removed the need for the mpSizeAry unique_ptr in FontList. ImplFontListFontMetric::GetDevice() and mpDevice could also be removed as it was no longer used anywhere. 8. After simplifying GetSizeAry(), it turns out it was the same as GetStdSizeAry(), so removed FontList::GetSizeAry() and used FontList::GetStdSizeAry() in its place. 9. Changing to use GetStdSizeAry() revealed that FontSizeBox::Fill() no longer used the pFontMetric paramter, so this was removed, and call sites updated. 10. Due to change to Fill(): a. SvxFontSizeBox_Base::UpdateFont() no longer uses the const css::awt::FontDescriptor& rCurrentFont parameter, so removed this. This also removed the member variable m_aCurrentFont b. SvxCharNamePage::FillSizeBox_Impl() had a number of newly unused variables removed. c. SwStdFontTabPage::Reset() and SwStdFontTabPage::LoseFocusHdl() had a number of newly unused variables removed. Change-Id: If840e240155c36ed351c63e3136b5b44bb058697 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121932 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-09-20Resolves: tdf#144620 toolbar config item overwrites options dialog oneCaolán McNamara
There are two SwMailMergeConfigItem involved. One SwMailMergeConfigItem from the toolbar created and considered modified and with changes not commited to the config yet. Then the other SwMailMergeConfigItem is created by the options dialog and commited on ok, but after that commit at cui/source/options/treeopt.cxx at line 723 there is a utl::ConfigManager::storeConfigItems() to flush all outstanding config items, so the one belonging to the toolbar is now flushed after the options dialog one was written. The SwMailMergeConfigItem has a IsModified() of true right after ctor which doesn't seem intentional, there is no explicit set of Modified to true on setting the simple bool members, the Modified bit is toggled on when using the more complicated modifier methods during ctor so very much looks like an accidental side effect. Change-Id: If84a6f01c7bf92704dd1e175a2bd8e2ea59e157f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122364 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-20Revert "tdf#99492 sw layout: always paint merged cell grids"Justin Luth
This reverts LO 7.1 commit c016fe2b5918d6e53113e100b1126076b6e1a6a3. This failed for two reasons. 1.) If it is not a solid color (like a graphic for example) then the graphic is going to be repeated in each cell. 2.) This is NOT actually repainting the visible cell's background. It is painting the hidden cell - which MIGHT be different from the visible cell (in the case of a solid color). Since this will require a completely different approach, I am just reverting this. Thanks Mike for finding an example document that shows the flaws. Change-Id: Icdc21e09118e7c33ac9f7ede23c913b95ad69c93 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122366 Tested-by: Jenkins Reviewed-by: Justin Luth <justin_luth@sil.org>
2021-09-20avoid division by zeroLuboš Luňák
A rectangle in SwRegionRects may apparently be empty. Change-Id: I0956be2921d5110e2a8b9867bebf99814dd222f1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122351 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-09-20ofz: avoid TimeoutCaolán McNamara
Change-Id: I941a5b9b930248236f35b31582ee8f2c9e0be16e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122348 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-20no need to allocate these SfxItemSet on the heapNoel Grandin
Change-Id: I1703ee1d7cfc5f3f3458dce8db36fa86c578814c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122331 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-20improve the SwViewShellImpl paint region API a bitLuboš Luňák
Make it clear that the region is a paint region, and make the ownership clearer when SwViewShell takes it over. Change-Id: I229255a8e2d07ccc228e894e85b0a47f1e2b1259 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122309 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-09-20clean up ambiguous confusing rectangle APIs like IsInside()Luboš Luňák
Reading 'rectA.IsInside( rectB )' kind of suggests that the code checks whether 'rectA is inside rectB', but it's actually the other way around. Rename IsInside() -> Contains(), IsOver() -> Overlaps(), which should make it clear which way the logic goes. Change-Id: I9347450fe7dc34c96df6d636a4e3e660de1801ac Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122271 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Luboš Luňák <l.lunak@collabora.com> Tested-by: Jenkins
2021-09-20sw: prefix members of SwNavigationConfig, SwNumRulesWithName and SwSrcViewMiklos Vajna
See tdf#94879 for motivation. Change-Id: I2740ff914fe35a069ce67ad10783dadc0cfdbf74 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122339 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-09-20no need to allocate these SfxItemSet on the heapNoel Grandin
Change-Id: I5a80d85225d1e5ba98a52885a79bed5bb873243d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122330 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-20no need to allocate these SfxItemSet on the heapNoel Grandin
Change-Id: Ia7be6c4e04f5558ed0dd53aa0df4feea1b1c556e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122329 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-20tdf#143813 Outline folding: Make copy cut paste workJim Raykowski
Change-Id: Ib8b491fdcce1cd059c8eaf80a9c3bb2590af7c63 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122212 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2021-09-19cid#1492160 Dereference before null checkCaolán McNamara
Change-Id: If53b117a69c37907c4d3871eec6c8b3ecfc9c461 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122314 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-19do not double-invert SwRegionRectsLuboš Luňák
The usual way to use SwRegionRects seems to be to set it to the full area (origin) and then use operator-= to remove parts. But operator-= is slower than operator+=, so if that all is followed by Invert() and Compress(), it's essentially inverting the operation twice, making it both slower and (IMO) more complicated. Make it possible to simply use operator+=, collect all rectangles and then post-process once using LimitToOrigin()+Compress(). I'm not entirely happy about the SwRegionRects constructor, but I don't have a better idea that wouldn't silently break backwards compatibility for backporting. Change-Id: If3c83e32729e5d02b9d97b66c93fac04d4fb3ecc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122215 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-09-19optimize SwRegionRects::Compress() moreLuboš Luňák
Implement Noel's idea of sorting the rectangles by Y axis and then considering only pairs of rectangles that are close enough to possibly get merged. Change-Id: Iac4a94fc411237f8c0fb5812906dc832be398cfa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122214 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-09-18ofz#35787 Avoid timeout when fuzzingCaolán McNamara
Change-Id: Ia506200f91dcf165dab951d240cb529f1a0d8034 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122302 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-18result of pDest->FindRealSdrObject() is already availableCaolán McNamara
Change-Id: If743c9cdcaaa75fac281b8c50d3e37bfa5ecf0c4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122296 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-18cid#1491948 Dereference before null checkCaolán McNamara
Change-Id: Ic1a408e464934ebd9d264de3c77bf77379c1f254 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122294 Tested-by: Jenkins Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-18vcl: create FontMetric from PhysicalFontFaceChris Sherlock
A FontMetric can be created from a PhysicalFontFace, so setup a constructor that takes a PhysicalFontFace object to instantiate the FontMetric. The OutputDevice functions GetDevFont() and GetDevFontCount() don't necessarily make much sense, so have changed GetDevFont() to GetFontMetricFromCollection() and GetDevFontCount() to GetFontFaceCollectionCount(). Change-Id: I1577679b949a49a7cf1248838786d0f5e84a5245 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121796 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-09-18tdf#144349 Make Navigator global tree track sub-document sectionsJim Raykowski
Master document relies on the Navigator listing all the sub-documents. However there is no connection between the currently selected section (containing the sub-document) and the entry in the Navigator making it very hard to see what file needs to be edited. This patch highlights the corresponding item in the Navigator at the current cursor position in the document. Change-Id: Iee32d1db0e40e302bfff7a879d47a5632ce4ed43 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122103 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2021-09-17ofz#38652 Avoid timeout in html importCaolán McNamara
Change-Id: Ic2c3b71a96749d613a3a3339824b57eaae2b63ef Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122267 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-17ofz: MemorySanitizer: use-of-uninitialized-valueCaolán McNamara
Change-Id: I65338d31b3b556b2ba96f592c2b12084dab87e4d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122261 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-17speedup toUpperCase when called in parallelNoel Grandin
by removing locking from CharClass, which means we need to make it an immutable class Since SharedStringPool in sc/ stores a pointer to the CharClass in use, we have to tweak SvtSysLocale so that the object does not change location. Change-Id: I2c62d354fa542ebc04e755ce5b9b9e2ddff76a64 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122185 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-17Some test-code simplifications, using starts/endsWith rest parameterStephan Bergmann
Change-Id: I3376ddc30e8ddc0e2dfc052ab47fe086108e015a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122221 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-09-17ensure that some basic geometry classes are trivially copyableLuboš Luňák
They in practice are, since they are just integers, but SwRect had explicit implementations of some functions that technically prevented SwRect from being considered trivially copyable, even though they were identical to default implementations. Change-Id: Ib5086dcd5279f3b4c0c530535c91524671cc6656 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122213 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-09-17sw layout xml dump: show SwMultiPortionMiklos Vajna
This helped fixing tdf#144305. Change-Id: I736f12b06a69a1c11a55487dc1a3eec976250dcc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122207 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-09-17Writer Navigator: Fix category content trackingJim Raykowski
This patch fixes a tracking bug that causes category content not to be tracked when field content is at the current cursor position in the document. Change-Id: I6fb5c4584cb05205e0c966eef079bd30ee3e6430 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122105 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2021-09-17tdf#95378 Writer Navigator: Track sectionsJim Raykowski
This patch adds document content tracking of sections. Change-Id: I4355792968031f10ab0afd176aa3284e89541b72 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122104 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2021-09-16tdf#143574 tdf#144271 sw: textboxes in group shapes - part 2Attila Bakos (NISZ)
Sync textboxes with group shapes, adding textboxes to group shapes, copying textboxes with group shapes, grouping/ungrouping group shapes with textboxes, removing textboxes from group shapes. This patch fixes a memory leak (tdf#144271) introduced by commit 504d78acb866495fd954fcd6db22ea68f174a5ab "tdf#143574 sw: textboxes in group shapes - part 1". Note: AS_CHAR anchoring is far not the best for group shapes and import/export is still missing. Change-Id: I7dc3b8d36c4a04f792ae4742fe4a45af9227a17e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121449 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2021-09-16ofz#38757 avoid config during fuzzingCaolán McNamara
Change-Id: Ie56e70faf40ec63ba5b17a8a9ea5f2947bbe53e1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122174 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-16optimize SwRegionRects::Compress()Luboš Luňák
This function gets called on modifying documents, and it shows up noticeably e.g. when profiling editing in Online. The code repeatedly restarts the whole process on most changes, but in practice this seems to only lead to repeated checks with the same outcome. So finish the whole compression and try again only at the end, if deemed needed. And even there I'm not sure if it's actually ever needed, since I couldn't trigger such a case in practice. Change-Id: I15b0a83c6865bad21fe60a7e9ca0b87ceea5b489 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122156 Tested-by: Luboš Luňák <l.lunak@collabora.com> Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2021-09-16sw layout xml dump: show SwLinePortionMiklos Vajna
Towards showing details of multi-portions. Change-Id: If086df39127483820c245fe58f2de0ddf2c98694 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122160 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-09-15tdf#144319: sw_odfexport: Add unittestXisco Fauli
Change-Id: Ib3c6834150e7bc2538af413840b8b45b053af603 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122161 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-09-15loplugin:finalclassesNoel Grandin
Change-Id: I88831f290e1923db6fb5a733746bfa3bc7fbc7e8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122148 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-15loplugin:virtualdead HasExtraRedlineTable always returns trueNoel Grandin
Change-Id: Ibc703b4c2adc6c6579cc4be50d274504ba957f45 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122138 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-15remove stray track-visited-linksCaolán McNamara
and add truncate-multiline for consistency Change-Id: I5a6fc0f0ac97a0f96739f2383b6d3eb474e776fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122145 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-09-15Fix broken ui fileStephan Bergmann
...after 45c4caff685b15a0f1b87ef05436a7e6aca96851 "tdf#144483 sw mail merge: save ranges in a single document", causing CppunitTest_sw_dialogs_test to fail with > warn:vcl.gtk:2759211:2759211:vcl/unx/gtk3/gtkinst.cxx:21611: GtkInstanceBuilder: error when calling gtk_builder_add_from_file: ~/lo/core/instdir/share/config/soffice.cfg/modules/swriter/ui/mmresultsavedialog.ui:165:49 Invalid property: GtkCheckButton.group Change-Id: Ib846f3cb1883de50c28c13441aaf880ae1a480fd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122153 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-09-15sw: add a DisableBuiltinStyles API settingMiklos Vajna
The built-in Writer styles (e.g. Caption) are written to each & every document to help compatibility: this way if the built-in style changes, existing documents are not changing. While this is a good default, sometimes document conversion workflows want to ensure that no new styles are added to the document during conversion. This new settings allows to opt in for this behavior in case not polluting the doc model is more important than the negative effects of changing built-in styles. Change-Id: I43130a215ee10ee6952724dbef2caab7174ff77f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122154 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-09-15CppunitTest_sw_core_text needs some more RTTI now in UBSan buildsStephan Bergmann
...presumably since 0c3e47cc2f0570a7cd8ff4889763991a86b29f26 "tdf#144305 sw: fix rendering of ruby portions with non-default ruby alignment", > DynamicLibraryManagerException: "Failed to load dynamic library: ~/lo/core/workdir/LinkTarget/CppunitTest/libtest_sw_core_text.so > ~/lo/core/workdir/LinkTarget/CppunitTest/libtest_sw_core_text.so: undefined symbol: _ZTI13SwLinePortion" and > DynamicLibraryManagerException: "Failed to load dynamic library: ~/lo/core/workdir/LinkTarget/CppunitTest/libtest_sw_core_text.so > ~/lo/core/workdir/LinkTarget/CppunitTest/libtest_sw_core_text.so: undefined symbol: _ZTI14SwMultiPortion" Change-Id: Iaebffc3c9c0245d6092ef1dfc58213fd2d38d303 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122143 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-09-15Fix some assorted mistakes in translatable stringsAdolfo Jayme Barrientos
Thanks Mihail Balabanov, Olivier Hallot and Tuomas Hietala for your keen eyes. Change-Id: Ibceeae6d82e39079c02140ac99729be1a1ab0407
2021-09-15loplugin:constvarsNoel Grandin
Change-Id: I9b35d6333afa6b305bf73fc55a7e60c8365674e9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122134 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-09-15Uninitialized data memberStephan Bergmann
...introduced in d467cd0dd9e9cf3b018859a592e2638527bc7add "tdf#135683 speedup DocumentRedlineManager::GetRedlinePos", causing isssues like > [_RUN_____] SwDocTest::testFileNameFields > /sw/inc/docary.hxx:238:50: runtime error: load of value 190, which is not a valid value for type 'bool' > #0 0x2b89dcc7897e in SwRedlineTable::HasOverlappingElements() const /sw/inc/docary.hxx:238:50 > #1 0x2b89dcc40efc in sw::DocumentRedlineManager::GetRedlinePos(SwNode const&, RedlineType) const /sw/source/core/doc/DocumentRedlineManager.cxx:2624:25 > #2 0x2b89df2a4e8c in SwScriptInfo::selectRedLineDeleted(SwTextNode const&, MultiSelection&, bool) /sw/source/core/text/porlay.cxx:2653:44 > #3 0x2b89df285fbe in SwScriptInfo::CalcHiddenRanges(SwTextNode const&, MultiSelection&, std::__debug::vector<std::pair<sw::mark::IBookmark const*, SwScriptInfo::MarkKind>, std::allocator<std::pair<sw::mark::IBookmark const*, SwScriptInfo::MarkKind> > >*) /sw/source/core/text/porlay.cxx:2687:5 > #4 0x2b89df29359b in SwScriptInfo::GetBoundsOfHiddenRange(SwTextNode const&, int, int&, int&, std::__debug::vector<int, std::allocator<int> >*) /sw/source/core/text/porlay.cxx:1917:9 > #5 0x2b89dfa1c1e6 in SwTextNode::CalcHiddenCharFlags() const /sw/source/core/txtnode/ndtxt.cxx:4522:5 [...] during CppunitTest_sw_uwriter at <https://ci.libreoffice.org/job/lo_ubsan/2135/> Change-Id: I42c8801f83d2e92a826864494b1f0f4c63f30f6f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122109 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Jenkins
2021-09-15sw layout xml dump: show SwParaPortionMiklos Vajna
Towards showing details of multi-portions. Change-Id: I3afb84731ae716557279d6253347c57fada710af Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122094 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>