summaryrefslogtreecommitdiff
path: root/editeng
AgeCommit message (Collapse)AuthorFilesLines
2021-06-18add missing 'use_underline'Caolán McNamara1-3/+4
Change-Id: Ie6d549b20461d7bb80fd78deb393320e5ba57c0a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107725 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117257 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2021-06-18weld editview menuCaolán McNamara2-102/+80
also squashed: lok: remove popup auto correct item The auto correct options and auto correct menu item are no longer need it. Change-Id: I26bd2d011b5665f198f18d35b8433becca904991 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107572 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117256 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2021-06-18use GetParentWithLOKNotifier to get the frame LOKNotifier to reuse for menusCaolán McNamara2-4/+2
so it doesn't have to be explicitly set by the editview menu creator If I force enable LibreOfficeKit::isActive and right click on a mispelled word in impress, or in the writer comments-in-margin before or after this change I see the same ILibreOfficeKitNotifier set on the MenuFloatingWindow. Seeing as this is used in only the editview spell checking menu give that a unique id 'editviewspellmenu' and only do this for that id SetLOKNotifier in vcl/source/window/menu.cxx added with: commit 8938e8b153f32f3f5926baddb87cb76c8e72755a Author: Jan Holesovsky <kendy@collabora.com> Date: Thu Mar 8 21:07:40 2018 +0100 lokdialog: Tunnel the spell-checking context menu with recommendations. Change-Id: I1a7952e88a3f89346c97d2516628b4a7a0423de6 Reviewed-on: https://gerrit.libreoffice.org/51062 Reviewed-by: pranavk <pranavk@collabora.co.uk> Tested-by: pranavk <pranavk@collabora.co.uk> Reviewed-on: https://gerrit.libreoffice.org/51166 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Jan Holesovsky <kendy@collabora.com> SetLOKNotifier in editeng/source/editeng/editview.cxx added with: commit 7c6fbd0ac3b5927b337aa69b132aba14e9b3103f Author: Tamás Zolnai <tamas.zolnai@collabora.com> Date: Mon Apr 16 14:38:36 2018 +0200 sd lok: Impress: Right-click menu on misspelled word locks up session Change-Id: Ib554eea7049c1ea244bc4789ee3d7d2adf87e283 Reviewed-on: https://gerrit.libreoffice.org/52977 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Change-Id: I6c23ba4252eab3850b7cc4c8cad2d2f8adee2792 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107747 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117254 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2021-06-18drop dumping intermediate popup menu and go straight to boost::property_treeCaolán McNamara1-21/+59
Change-Id: I1209cf14cd23adee9ecf01b73bfcc95b80dea07a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107887 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117252 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
2021-06-17tdf#142839: do not forget to initialize *pHeightNTPMike Kaganski1-0/+4
Regression after commit d0a1616ccad0dd5f5a02c1b0204f537b57d0b4b5 Change-Id: Iaa8f67e0c7e3d99b057294717d24ffac4ad3534c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117389 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 59611f7b6acbf643bde0e0121ee51e2df53e7d50) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117305 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
2021-06-14don't need a vcl::Window for PixelToLogicCaolán McNamara1-2/+2
Change-Id: Iccf5fe5e736017962a58d6471bb2d1890f77c6c2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107560 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117110 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Andras Timar <andras.timar@collabora.com>
2021-06-10editengine-columns: Implement layoutMike Kaganski7-381/+659
This changes the way how different parts access positions of lines and paragraphs. Now there is ImpEditEngine::IterateLineAreas, which performs uniform iteration over all ParaPortions and lines in order, calling a user-provided callback function for each portion and line; it passes all information about current portion, line, area, and column to the callback, and checks the return from the callback, to decide if it needs to continue iteration (in case when callback indicated that if doesn't need further data), and if it needs calling the callback for the rest of current portion's lines. This allows to have the code that calculates and iterates dimensions of lines in one central place, without the need to have duplicating logic in several places. One important exception is ImpEditEngine::Paint, which iterates without ImpEditEngine::IterateLineAreas, because it does many atomic paint operations in different points of iteration process, and implementing ImpEditEngine::IterateLineAreas to call callback in the required places would require increased complexity, which is left for a future change. To make that possible, ImpEditEngine::IterFlag should be extended to indicate additional requirements. Note that in fact, ImpEditEngine::Paint was taken as the model for implementation of ImpEditEngine::IterateLineAreas, with its detailed handling of all the vertical offsets like additional line spacing and interparagraph spacings that depend on context. The notable result of the centralization of the iteration code is slight change of heights reported by ImpEditEngine::CalcTextHeight. Previously it simply added all pre-calculated heights of portions, and not taking into account all the spacing handling that ImpEditEngine::Paint did, which was inconsistent (calculated height was different from painted height). Now ImpEditEngine::CalcTextHeight should provide more accurate results, which required small changes in the unit tests. Change-Id: I33cbb978deb974b314d36fda8674186a03991107 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116034 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116876 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-06-10editengine-columns: Create document model and dialog pageMike Kaganski4-0/+29
Change-Id: I056aad9474ca18134d1f1686a53618cc9ab3d525 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116038 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116868 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2021-06-09sc: lok: apply the previous fix for selections tooDennis Francis1-3/+6
Conflicts: editeng/source/editeng/impedit.cxx Change-Id: Ic1f6c1642da71e0ef8c23831786ae405dda21133 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116427 Reviewed-by: Luboš Luňák <l.lunak@collabora.com> Reviewed-by: Dennis Francis <dennis.francis@collabora.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> (cherry picked from commit c5e249877b93e9d11788ec04fffee1dcb142a0e5) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116805
2021-06-09sc: lokit: fix wrong edit cursor coordinates for numeric cellsDennis Francis1-4/+8
The cursor coordinates returned by editengine implementation is computed with respect to document-visible-area in "display" hmm and not "print" hmm. For numeric cells, the visible top-left is always non-zero, hence triggering this incorrect "refpoint" subtraction to compute "relrect". The fix is to calculate the correct "relrect" by subtracting the display hmm version of "refpoint" from the edit cursor rectange and then convert to twips. Change-Id: I4b663edcb1f74e1bdcc300788769d580fcfe7e17 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116426 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Luboš Luňák <l.lunak@collabora.com> Reviewed-by: Dennis Francis <dennis.francis@collabora.com> (cherry picked from commit 77704022556bb97a64ef47666230a2c0232d45d3) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116804
2021-06-08Unify some code managing coordinates depending on text directionMike Kaganski2-202/+128
Change-Id: I12163e83a6a4d4e7cb85eed690b787c47ee2e7e5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115107 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116861 Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
2021-05-27Seperate SvxBackgroundColorItem from SvxColorItemGülşah Köse1-10/+56
SvxBackgroundColorItem derivated from SfxPoolItem instead of SvxColorItem. Casting is common usage to control if object is this or not. When we can cast SvxBackgroundColorItem to SvxColorItem we can not seperate them anymore. eg: Char color is a SvxColorItem and char background color is a SvxBackgroundColorItem. They can be hold together and we should understand they are different types. Change-Id: I7b1879a1b00de26c0b8a2d9f8d658aa3aef75ecb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116135 Tested-by: Jenkins Reviewed-by: Gülşah Köse <gulsah.kose@collabora.com> Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116183
2021-05-25use GetPopupParent for editeng transient dialogsCaolán McNamara4-9/+12
Change-Id: Ie799643b68ea41b4c4d0d0493755d09d3983d9e0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110934 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-25get parent for welded menu and location to pop it upCaolán McNamara2-0/+9
Change-Id: I654f6edc4b8bdb0e38f70757b970893980b09638 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107728 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-05-01lok: remove popup auto correct itemHenry Castro1-0/+3
The auto correct options and auto correct menu item are no longer need it. Change-Id: I0a5e624c3393151cf80a06961f96d6a5fb8891ab Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113680 Tested-by: Jenkins Reviewed-by: Henry Castro <hcastro@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113740 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2021-04-21a11y tests show we should use GetOutputDevice for pixel/logic conversionsCaolán McNamara1-0/+5
Change-Id: I229ffb376b03ff2479385632319661dd35a63fea Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114188 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> Tested-by: Jenkins
2021-04-10lok: fix incorrect invalidate cursor positionHenry Castro2-0/+10
When the comment is created and it's shown in the "Writer" application, it creates an initial output area: mpOutlinerView->SetOutputArea( PixelToLogic( tools::Rectangle(0,0,1,1) ) ); Unfortunately, it causes that send to client side cursor position and scroll to the beginning of the document. Change-Id: I13e21c71328b7f05781e7cdeed082d6cc2b9d679 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109371 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Jan Holesovsky <kendy@collabora.com> (cherry picked from commit 4618849a1cbba4e249ee13c3b6412337160a2816) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109732 Tested-by: Jenkins Reviewed-by: Henry Castro <hcastro@collabora.com>
2021-04-02avoid LOK text selection update when reference cell is in different tabPranam Lashkari1-3/+6
Change-Id: I511b9c5a27f97b6e14e9a844179c27a96997abe1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111315 Tested-by: Jenkins Reviewed-by: Pranam Lashkari <lpranam@collabora.com> (cherry picked from commit 01f86c59531b29cd06dd53a7a6e4556fb97cbb24) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113536 Tested-by: Pranam Lashkari <lpranam@collabora.com>
2021-04-02enable hyperlink to be detected at the end of textPranam Lashkari1-1/+1
now in online hyperlink popup will appear even when the cursor is at the end of hyperlink text Change-Id: I80a1a093afa11e39236693f8a2639741f74c9876 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110227 Tested-by: Jenkins Reviewed-by: Pranam Lashkari <lpranam@collabora.com> (cherry picked from commit 3233db0913193855285e1f56492d4617368441b6) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113532 Tested-by: Pranam Lashkari <lpranam@collabora.com>
2021-04-01tdf#91920 sw page gutter margin: handle mirrored marginsMiklos Vajna1-0/+5
- SwPageDesc::Mirror: generate "right gutter margin" from gutter margin for mirrored pages, we just lost the gutter margin here previously - SwBorderAttrs::CalcRight: handle right gutter margin, so gutter increases the right margin, not the left margin on mirrored pages - lcl_CalcBorderRect: similar to left and top margins, compensate for right margin gutter as well, so borders are independent from the gutter margin (Word compat) Change-Id: Ie4d3459ab6edcc60b20c2fed08dbf45060ca9828 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110585 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-04-01sw page gutter margin: add UNO APIMiklos Vajna1-0/+9
SvxLRSpaceItem is used for all sorts of left/right margins, but gutter only makes sense for pages, so only expose the gutter margin in the page properties. Change-Id: Icfca2499e944081b70bbdbc4c62e78cade25f5c6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110322 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-04-01sw page gutter margin: add doc modelMiklos Vajna1-0/+5
The page gutter defines the amount of extra space added to the specified margin, above any existing margin values. This can be helpful in case of printed books: e.g. 1cm left margin, 1cm right margin, then some additional gutter margin on the left can mean that once the book is printed and binding consumes its space, the remaining left/right margin is matching. This is just the doc model, other parts will come in follow-up commits. Change-Id: Ibd3e836ced664b57e817f5c0952098460b683089 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110290 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-03-31OSL_FAIL.*exception -> TOOLS_WARN_EXCEPTIONNoel2-2/+2
Change-Id: I6800e23ead2767d245d5da71d2d40e0f8a6d7e1f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106859 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-03-10tdf#140498 middle-button paste doesn't depend on a vcl::WindowCaolán McNamara2-16/+12
Change-Id: I4f1f14994b35cec51761689875bf6b5135612f3c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112085 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-02-26tdf#134940 sw: fix AutoCorrect of arrow "-->"László Németh1-1/+4
Fix bad replacement of "-->" with "–>" instead of "→" (i.e. premature replacement of "--" to n-dash) since '>' was added to IsAutoCorrectChar(). Regression from commit 57f07b1d7378d218648667c5b1315cc8ad905875 "tdf#133524 AutoCorrect: support double angle quotes". Change-Id: I06f0cddb48d13c8e230dab964f79f588799ed4ab Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111527 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org> (cherry picked from commit d1be3d80d0ca5ccd7639ede379a1befc48dc73f2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111579 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-02-15tdf#140414: fix Crash pressing Ctrl-K in input line in CalcJulien Nabet1-1/+4
3 0x00007ff38b819d73 in vcl::Window::GetPointerPosPixel() (this=0x0) at vcl/source/window/mouse.cxx:552 4 0x00007ff3925fe7c1 in EditView::GetFieldUnderMousePointer(int&, int&) const (this=0x4c37160, nPara=@0x7ffd982b4f44: 0, nPos=@0x7ffd982b4f40: 57752960) at editeng/source/editeng/editview.cxx:1325 5 0x00007ff3925fe74a in EditView::GetFieldUnderMousePointer() const (this=0x4c37160) at editeng/source/editeng/editview.cxx:1315 6 0x00007ff3925fec4c in EditView::GetFieldAtCursor() const (this=0x4c37160) at editeng/source/editeng/editview.cxx:1384 7 0x00007ff377f6aa55 in ScEditShell::GetURLField() (this=0x37a31a0) at sc/source/ui/view/editsh.cxx:833 Change-Id: Ib369644f26eec4f37a34213f0b0113359a653098 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110859 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-10tdf#96787: AutoCorrect: after deleting a replacement entry, it's still usedJulien Nabet1-0/+2
If specific acor<language>.dat exists in "user", don't use the initial one in "share" since the initial one will still contain the deleted entry. See detailed explanation here: https://bugs.documentfoundation.org/show_bug.cgi?id=96787#c21 Change-Id: Ic349159c93d9fc327f38a1d4e8187e3bdc16d08a Change-Id: If6b16641d04721f2945a8e920e2933d1b8baa90f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109039 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr> (cherry picked from commit ae56dc05b27f05ffcee99845d661a237e70a7a51) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108998 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2021-01-04tdf#120171 editeng: don't reduce nBreakPosMark Hung1-4/+3
even if it is greater then nMaxBreakPos. The only situation that happens is when there is a hanging punctuation. Reducing nBreakPos to nMaxBreakPos always break that punctuation to the next line. Change-Id: Ie4b61d21f4d8f6f874e2a969260c13a3bca2a049 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108594 Tested-by: Jenkins Reviewed-by: Mark Hung <marklh9@gmail.com> (cherry picked from commit 2ffa6c897379bf07367d445918b4c142cd493e7f) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108591 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2020-11-25Use sal_Int64 to printf tools::Long valuesStephan Bergmann1-1/+1
(The "%l" format specifiers had now caused -Werror,-Wformat with clang-cl for a Windows 64-bit build.) Change-Id: I86b9617310f7348d72172cc7a29f0976c7030dd5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106576 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> (cherry picked from commit 9e0de138a5afaa7132ee535a15741effc983d2b0) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106612
2020-11-17loplugin:stringviewparam check methods tooNoel2-2/+2
not just functions Change-Id: Icca295dd159002b428b73f2c95d40725434f04d9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105789 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-16Instead of labs, use overloaded absStephan Bergmann1-1/+3
...more likely to pick an appropriate version for the involved integer types, esp. after the recent long -> tools::Long changes Change-Id: Ia91259ca35aaf74b0e907de6831fc926f30057f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105949 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-11-13tdf#123936 Formatting files in module editeng with clang-formatPhilipp Hofer6-40/+36
Change-Id: I745057f4a6dc0d8103ed7fa29d0f662226a5cee5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105663 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2020-11-12New loplugin:stringviewparamStephan Bergmann2-3/+3
...to "Find functions that take rtl::O[U]String parameters that can be generalized to take std::[u16]string_view instead." (Which in turn can avoid costly O[U]String constructions, see e.g. loplugin:stringview and subView.) Some of those functions' call sites, passing plain char string literals, needed to be adapted when converting them. Change-Id: I644ab546d7a0ce9e470ab9b3196e3e60d1e812bc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105622 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-11-12tdf#42949 Fix new IWYU warnings in directories [e-f]*Gabor Kelemen9-12/+10
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I963aa5fb892a0be36212fd0587b69f217f017947 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105469 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de>
2020-11-11loplugin:stringviewNoel1-1/+1
Add new methods "subView" to O(U)String to return substring views of the underlying data. Add a clang plugin to warn when replacing existing calls to copy() would be better to use subView(). Change-Id: I03a5732431ce60808946f2ce2c923b22845689ca Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105420 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-11convert more long -> tools::LongNoel2-3/+3
found by grepping and changed by hand. Change-Id: I3c720859dba430fde3abc76c6c5cb58269efaf4b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105512 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-11make tools::Long 64-bit on Windows platformNoel Grandin2-6/+6
This is only for the 64-bit windows platform. I don't see the point in messing with the 32-bit platforms, they are (a) become more and more rare (b) unlikely to even have enough available process memory to load extremely large calc spreadsheets The primary problem we are addressing here is bringing Windows-64bit up to same capability as Linux-64bit when it comes to handling very large spreadsheets, which is caused by things like tools::Rectangle using "long", which means that all the work done to make Libreoffice on 64-bit Linux capable of loading large spreadsheets is useless on Windows, where long is 32-bit. The operator<< for tools::Rectangle needs to be inside the tools namespace because of an interaction with the cppunit printing template stuff that I don't understand. SalPoint changed to use sal_Int32, since it needs to be the same definition as the Windows POINT structure. Change-Id: Iab6f1af88847b6c8d46995e8ceda3f82b6722ff7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104913 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-06tdf#137908 Revert "use FasterParser for LoadXMLExceptList_Imp"Noel Grandin1-3/+6
This reverts commit 79ea745d595945e454ced9f6cacd2bb57aa51f95. Change-Id: I88d0ae9f0a3ec6691fdd09c58b20532833d8c090 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105373 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-11-02make SvXMLImport capable of mixing fast- and slow- contexts adhocNoel2-10/+0
so I can convert even *ImportContext subclasses in the middle of a context stack, and thus break the cyclic dependency nature of the writer import. and adjust the xmlimport loplugin for the new rules. As a consequence of the loplugin:xmlimport's checking, we remove a bunch of now unnecessary overrides of startFastElement. Change-Id: I97464522ede8ec5e345e928cdafa4b18364b1b80 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104730 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-28std::set->o3tl::sorted_vector in ImpEditEngineNoel Grandin1-3/+4
Change-Id: Ia78b986c28e2d8e3655d5c8f56d3cb5cd7a5ee1d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104944 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-28convert some more long -> tools::LongNoel3-14/+14
grepping for stuff in template params this time Change-Id: Ia37bfd85480b3a72c3c465489581d56ad8dde851 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104855 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-27Resolves: tdf#137620 add DeleteSurroundingText at vcl::Window levelCaolán McNamara2-1/+16
a) give it a default implementation based on the current one b) re-use code introduced for WeldEditView::DeleteSurroundingText for the EditView containing vcl::Window in impress/draw and various similar Annotation windows Change-Id: I55547c70e90ee394795b5545450cf8131538fad8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104781 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-10-26std::unique_ptr -> std::optionalNoel1-13/+7
Change-Id: Icd4c818579a7b15454706ab4e02d47e1ac368160 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104796 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-26std::unique_ptr -> std::optionalNoel2-5/+5
Change-Id: Icf8168423af437fda88a6bd26679fecb699606e8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104795 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-25editeng: AccessibleImageBullet : avoid recursive SolarMutextArnaud Versini2-5/+11
Change-Id: I7dc6c2dbeda4f35c609ef154af888480a81f2512 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104777 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-23tdf#104378: don't reset para attributes whileMark Hung5-8/+24
converting Chinese characters. In TextConvWrapper::ChangeText_impl, calls to EditView::RemoveAttribs() reset the paragraph attributes. That makes SvxLanguageItem of EE_CHAR_LANGUAGE_CJK become LANGUAGE_DONTKNOW. Hence it always stops converting after the first success. This patch overload EditView::RemoveAttribs() so that it is possible to clear all character attributes of the selction without touching paragraph attributes. Before, bRemoveParaAttribs either removes items between EE_ITEMS_START and EE_CHAR_END, or removes items between EE_CHAR_START and EE_CHAR_END. The patch add a new enum class EERemoveParaAttribsMode, with the following values: 1. RemoveAll : correspond to the old bRemoveParaAttribs = true 2. RemoveCharItems: correspond to the old bRemoveParaAttribs = false 3. RemoveNone: new thing for "don't touch para attributes." Change-Id: I5132e708dea9e2066f13f1b001bd954d7b477f56 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104484 Tested-by: Jenkins Reviewed-by: Mark Hung <marklh9@gmail.com>
2020-10-22set all .ui min require version of gtk to 3.20Caolán McNamara1-1/+1
and update the version mentioned in our min req in the readme.xrm follow up to commit 0c9ccc7dbf6deb4d012e0d1e6eb934e54e0f19bc Author: Caolán McNamara <caolanm@redhat.com> Date: Fri Oct 2 21:21:45 2020 +0100 raise min version of gtk to 3.20.0 Change-Id: Ibae55c97e1ee577f4b7435d124cda6a21005ad0c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104692 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-10-21new tools::Degree10 strong typedefNoel Grandin11-28/+28
partly to flush some use of "long" out the codebase, but also to make it obvious which units are being used for angle values. Change-Id: I1dc22494ca42c4677a63f685d5903f2b89886dc2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104548 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-20use tools::Long in editengNoel30-394/+394
Change-Id: Ib7014c353489461ad9489d9f3fefd59a32f8f877 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104524 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-10-16weld InputBarCaolán McNamara1-0/+5
this also restores that DnD of a selection from the inputbar is pasted as plain text not rich text formatted with the happenstance formatting of the inputbar's EditEngine Change-Id: If4934f83c14357afec2e0a7e1d51c8a1aea1d292 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104037 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>