summaryrefslogtreecommitdiff
path: root/sw
AgeCommit message (Collapse)Author
2021-01-05SwClientNotifyCall no moreBjoern Michaelsen
- SwClientNotify calls really shouldnt happen from outside the class in the future - the few remaining legacy exceptions have been marked as friend -- admittedly ugly, but it reduces the scope of call being triggered from anywhere to a welldefined set. Change-Id: I46d5f755b0cf5de013a4c345a04e2c67447a99aa Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108651 Tested-by: Jenkins Reviewed-by: Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>
2021-01-05tdf#138879: sw_odfimport: Add unittestXisco Fauli
Change-Id: Idbe6775dd00f985fbbf6d102e88e768edf2ad525 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108667 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2021-01-04sw: prefix members of SwCharRange, SwEmbedObjectLink, SwHolePortion and ...Miklos Vajna
... SwLineInfo See tdf#94879 for motivation. Change-Id: I6d397ea717161ad435af903cc236c87731f8a419 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108654 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-01-04loplugin:stringviewparam: operator +=Stephan Bergmann
Change-Id: I30ce1b5bd8fb168da7067c1967c5af2569df2653 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108512 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-01-04tdf#133718 Add accelerator keys to Hyperlink dialog tabsGabor Kelemen
Also change an accelerator on the Internet tab to avoid clashing with the new one for Mail tab Change-Id: I24a03647ccba6901b1865f5ca4228e54d686d662 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108358 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-03NotifyClients no moreBjoern Michaelsen
... and prevent recursive invalidation in SwAnchoredObject. Change-Id: I6f386f3ffded29663fcc74c2679b76c1b839f367 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108604 Tested-by: Jenkins Reviewed-by: Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>
2021-01-03Revert tdf#104278: text in Type frame in DocInformation...Kevin Suo
...is not aligned left This reverts commit 4987c82449183d47464c94d4ed0aa0bbf2abf3aa, because it breaks the feature of showing the customs document property in the DocInformation dialog, see Caolan's comment in https://bugs.documentfoundation.org/show_bug.cgi?id=104278#c13 Change-Id: I859ad3a6fa08290d5158dd03c33adfa821d78131 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108497 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-03tdf#124176 Use pragma once instead of include guardsAlchemist
Change-Id: I491742c51ddc7c97f02b148dfb81d9ba820a759e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108600 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-01-03tighten up asserting in SfxPoolItem::operator==Noel Grandin
...subclasses, so we always call the SfxPoolItem::operatar== which will ensure that we are always comparing two objects that belong to the same class. And fix the fallout in SvxUnoNameItemTable. Change-Id: I5ec7fedaa914a328897b54c016ad13e505a15937 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108599 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-02SwFrame: Modify no moreBjoern Michaelsen
Change-Id: I8e2c89f2c897535013d64720b6c2c5bbac602b14 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108551 Tested-by: Jenkins Reviewed-by: Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>
2021-01-02drop deprecated GtkAlignment, move left/top-padding into child margin-start/topCaolán McNamara
for sw part b Change-Id: Iebd29eb907e47fbaf1d80c9201dd6cbd32c06c44 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108597 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-02Remove warning while buildingdante
Operator >>= from any does not guarantee initialization, so compiler warns you. Value defaluted at 0. Change-Id: Icecc765be73bb653f0167958e319a1417df6ac86 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108485 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-02introduce Degree100 strong_int typeNoel
Change-Id: I78f837a1340be0ca5c49097f543a481b7b43a632 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108367 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-01-02drop deprecated GtkAlignment, move left/top-padding into child margin-start/topCaolán McNamara
for sw part a Change-Id: I27a3bbd46ba87e67c4a0d109fb661e2228f38ce5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108564 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2021-01-02tdf#124176: Use pragma once instead of include guardsVishwas
Change-Id: I346da72b15d21f09440f65f2c4f832115267c5e5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108552 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2021-01-02Fix: Move remaining direct calls to SwLayoutFrame::Modify out of the wayBjoern Michaelsen
Change-Id: I544cc42845d346eb0901ca86621a563d1173e2b7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108550 Tested-by: Jenkins Reviewed-by: Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>
2021-01-01Typo in code 'Reapeat'->'Repeat'Julien Nabet
Change-Id: I50bd9648584a60feccc115b4e58dff896e1284be Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108499 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-31SwFlyFrame: Modify no moreBjoern Michaelsen
Also, make the uitest output a bit more explicit. Change-Id: I41fa08a6fc02d95ad3337129eb93f8a569cf3cbd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108491 Tested-by: Jenkins Reviewed-by: Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>
2020-12-30atrflyin.cxx Modify no moreBjoern Michaelsen
the fragile tests depending on specific order of objects any a bit unfortunate ... Change-Id: Ib74ec2a69c95e6ca859d7c75796081ac889ac32d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107647 Tested-by: Jenkins Reviewed-by: Bjoern Michaelsen <bjoern.michaelsen@libreoffice.org>
2020-12-30vcl: remove {Read,Write}ImpGraphic and ImplExportNative from GraphicTomaž Vajngerl
ReadImpGraphic and WriteImpGraphic have been reimplemented in the TypeSerializer some time ago, but the code has not yet been moved to use that class. This commits does that and changes all the code using those 2 methods and removes them. With this implemented in the TypeSerializer, it is easier to handle In addition it also removes ImplExportNative (and the method on the Graphic interface). This was really used only in one method, and it could be implemented in the mthod itself. Change-Id: I0982429d1c1d5ed7ef07627d87ed9a08df43f040 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108256 Tested-by: Tomaž Vajngerl <quikee@gmail.com> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-12-29Missing last para style when inserting text from odt file tdf#138879Georgy Litvinov
Change-Id: Ief235e98f3de02350b6403a1ea8ecf6361571789 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108285 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-29use SdrAngleItem for SID_ATTR_TRANSFORM_DELTA_ANGLENoel Grandin
as a precursor to introducing a strong_int type for hundredths of a degree Change-Id: I766f1c2f8c6d31ec1ea2f064293d70b30da0bc56 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108431 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann
Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-29tdf#138907 sw TitlePageDlg: fix round-trippingJustin Luth
This Format -> Title Pages dialog is completely broken, so I threw in lots of FIXME notes. At least for the case of just using the existing pages and setting them up as title/follow page, fix: 1.) the ability to round-trip page number restart if a numbering restart without a page style already existed. (Yes, this likely is an odd case of someone messing around. In any case, a page number restart REQUIRES a page style) make UITest_writer_tests5 UITEST_TEST_NAME=\ titlePageWizard.tdf138907.test_tdf138907 Change-Id: I544145e9f749f471b54fa6686242e93bc98f50be Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108322 Tested-by: Jenkins Reviewed-by: Justin Luth <justin_luth@sil.org>
2020-12-29tdf#138779 do not call EndRun() in StartRuby()Mark Hung
and EndRuby(). Ruby is implemented as EQ field in RTF. The original run text become the ruby base text in this case. Calling EndRun() in StartRuby() might cause the run completed early and text attributes that hasn't be processed mistakenly applied to next run. This patch close the in EQ field command in EndRun, in case StartRuby has already inserted EQ field command. Change-Id: I3a755f235b79d11b7897f85ae3989cc3ac73b06a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108194 Tested-by: Jenkins Reviewed-by: Mark Hung <marklh9@gmail.com>
2020-12-29tdf#134881 sw table dlg: make column change %-proportionalJustin Luth
Apparently, there is a discrepancy in how the various help manuals describe this. What was actually happening was that the same amount was being changed on each column instead of the same percentage. That is really bad if there are small columns, and a large one is reduced. Plus it seemed like there were implementation problems anyway, especially when growing a column too much. This patch sets it to how the guide describes it. "Adjust columns proportionally results in all columns changing their widths by the same percentage when one is changed. For example, if you reduce by half the size of a column, the sizes of all the other columns will be halved." (July 2018 LibreOffice Writer Guide 6.0 page 282) Online help since 2013 simply says. "Adjust columns proportionally: If possible, change in column width will be equal for each column." https://bugs.documentfoundation.org/show_bug.cgi?id=42023 One situation I noticed but don't think it needs dealing with is if "from left" contains a value, then perhaps the table should not be allowed to take up the full width? It could grow to spill out past the edge of the page. (Problem already existed with previous solution.) Also, merged cells might cause some unexpected results, but that becomes a user problem to fix I say. I didn't think it would matter if I grew the table a couple of Twips larger than full width. If it is, then probably just reduce maxWidth by a twip for every two columns - or truncate instead of round. (And then I also need to account for theoretical columns that are "increased" to MINLAY size too.) Note that the table will NOT grow beyond 100% text width. However, if a table is already larger than 100% (which the UI makes difficult to do) at least an attempt to grow the columns will not cause them to shrink. They will just stay the same sime. make UITest_sw_table UITEST_TEST_NAME=\ tdf134881_colProportionalAdjust.tdf134881.test_tdf134881 Change-Id: Id57d80d9658b9ac1938189c75da0cbf309fc321a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107604 Tested-by: Jenkins Reviewed-by: Justin Luth <justin_luth@sil.org>
2020-12-29Fix crash in SwXTextDocument::getSelection() method.Tamás Zolnai
pWrtShell was nullptr. This crash was triggered by an collaborative editing use case. Change-Id: Id64298b424f5ac4d96df97581c6fe3067e799eb3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108417 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2020-12-29use Degree10 in SwRotationGrfNoel Grandin
(*) Fix SwRotationGrf::GetPresentation to return a more accurate string (*) Add utility functions sal_Int32 toDegree100(Degree10) double toRadians(Degree10) (*) Fix SwVirtFlyDrawObj::GetRotateAngle to return the angle in the units that svx expects (deg100) which was introduced in commit c2e30949e0fb7c6a73742450f646e0d8d59d5e4f Date: Wed Apr 10 15:13:53 2019 +0200 lok: writer: svg export transformed images and consequently we can remove the kludge from that commit in SdrMarkView::SetMarkHandlesForLOKit Change-Id: I1a8c5f3a417f887f85b92ae5464578e9ee251619 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108406 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-28tdf#104278: text in Type frame in DocInformation is not aligned leftKevin Suo
As we can see from sw/uiconfig/swriter/ui/flddocinfopage.ui, we have a GtkTreeView in GtkFrame "typeframe", without the following property: <property name="show_expanders">False</property> A GtkTreeView seems have a default indentation if show_expanders is True (which is the default), see: https://developer.gnome.org/gtk3/stable/GtkTreeView.html#gtk-tree-view-set-show-expanders A "expander" would look like this: https://python-gtk-3-tutorial.readthedocs.io/en/latest/expander.html I do not see a reason why we should use an expander here in this dialog. As a result, setting show_expanders to False will solve the problem. Change-Id: I29cbb13f8d57aeb502079f278e4b620d97d8f170 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108261 Tested-by: Jenkins Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org>
2020-12-28use SdrAngleItem for SID_ATTR_TRANSFORM_ANGLENoel Grandin
as a precursor to introdcing a strong_int type for hundredths of a degree Change-Id: Ie2d7ad3b48d01defb43bf2e11e6494c4b999de0e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108378 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-27replace margin-left with margin-startCaolán McNamara
and restore assert to not use margin-left/right anymore Change-Id: I05d2a4cc829ed9de3cca73d987f5a66e0582eaa5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108379 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-12-27ofz#28918 Direct-Leak in SotStorage::OpenSotStreamCaolán McNamara
Change-Id: I2d99a13822b07d98e03d7e7de91ca44ab4f8599d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108266 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-12-27ofz#28926 Direct-leakCaolán McNamara
Change-Id: I6be3fd88ea092309de63389d64c25d7a28195d3d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108270 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-12-27Simplify loplugin:stringviewparam comparison operator handlingStephan Bergmann
In practice, it works fine to look at all of them, regardless of actual argument types. Change-Id: Ifc49cbcd6003c8837c1b3f81d432c59fb0657bf1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108366 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-26vcl: use Color:IsTransparent() where appropriateChris Sherlock
Change-Id: I37bbab5f22f91faad65be8ef79734ce1ee6355d4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108249 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-26Remove pointless macroGabor Kelemen
DDE_TXT_ENCODING is just an alias since 2008 commit a190965485508c4493ee33228dae68e12cd858f9 and commit cc141699cc6b2fa38b0b0003bff27751e23ae8e4 Change-Id: I2ca32871c13bd3837f173e5f9f959f364857de52 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108330 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-26tdf#88205: Adapt uses of css::uno::Sequence to use initializer_list ctorBayram Çiçek
Change-Id: Id4034a57580f37fd71f841deec9edfe9b7c26a67 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108286 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-26tdf#138545 fix mouse pointer not changing when over a hyperlinkJim Raykowski
Rework of offending code that changes the mouse pointer to a hand icon when outline content visibility feature is active. Change-Id: Ia30a8f951b341a4f44f8b900cc756c205f6a273d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108275 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2020-12-26Return focus to edit windowJim Raykowski
commit 797915bf0bc0ed82c3cf58b7bd03c42d3335ca18 prevents focus from returning to the edit window when Navigate by previous or next buttons in the Navigator tool box are pressed. This may be nice for activation of the button by keyboard as it keeps focus on the button, but it doesn't allow for cursor indication of the navigated position in the edit window. Change-Id: I0067ee7d80aa94a510c83a52c22f788ba4a03dc6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108276 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2020-12-26New loplugin:stringliteralvarStephan Bergmann
See the comment at the top of compilerplugins/clang/stringliteralvar.cxx for details. (Turned some affected variables in included files into inline variables, to avoid GCC warnings about unused variables.) Change-Id: Ie77219e6adfdaaceaa8b4e590b08971f2f04c83a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108239 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-26Don't unload the msword libraryStephan Bergmann
It caused issues on Windows with an upcoming change that introduces more static OUStringLiterals, and apparently one from msword ended up in the data structures of editeng's SvxForbiddenCharactersTable, which in turn is owned by theEditDLL singleton, which was destryoed at exit after the msword library had already been unloaded, so an OUString referenced the dangling OUStringLiteral data. Change-Id: I873f0b4e879a5820d1e8a1cda3b1b1fd49f809db Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108321 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-25tdf#139218: Title Page: fix "Reset page number", put default at 1Julien Nabet
Change-Id: Ic3758d8eeeb1818e3be3ca5d815fa601a34e8dd9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108279 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-24Fix typosAndrea Gelmini
Change-Id: Ic283206b318e4367e5d88475bdc2abac48e79f62 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108271 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-24custom literal for Degree10Noel Grandin
Change-Id: Id13869138a622e62d9ffebf2c89bddccda6aff01 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108238 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-24vcl: move access functions into appropriate bitmap access filesChris Sherlock
Split class functions into BitmapInfoAccess.cxx, BitmapReadAccess.cxx and BitmapWriteAccess.cxx Split header files into BitmapInfoAccess.hxx and BitmapReadAccess.hxx Change-Id: I7dcbe1d26c5b64d297658a6b809c93d7ad7f053d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108039 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-12-24tdf#124176: Use pragma once instead of include guardsBayram Çiçek
Change-Id: I49acd246a9675a0749e056178dec43d0d73c488e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106450 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2020-12-24tdf#138136 tdf#38093 add option to treat sub outline levels as contentJim Raykowski
Also included in this patch: - Modifications to make all outline content visible during move operations. - Removal of code intended to redraw buttons when layout is changed that seems not to work as intended. - Function IsOutlineContentFolded changed to IsOutlineContentVisible - Change of delay before button is shown to half of what it was. Change-Id: I0dde555ccd0693ca382c1f15326edfdc2fc44a93 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107815 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com>
2020-12-23uitest: check undo works when deleting a pagebreakXisco Fauli
Change-Id: I197a04a889ba24e21143414da50145891566ea94 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108243 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2020-12-23tdf#136578: uitest: add wrapper for PageBreakWinXisco Fauli
Change-Id: I1536f2f03da9ec64627bd1e2e1776cf130717aff Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108143 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
2020-12-23uitest: simplify assertXisco Fauli
Change-Id: I8a511df34cd52ebc7b2535ef6977e42b3d4d04f7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108232 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>