summaryrefslogtreecommitdiff
path: root/writerperfect/source
AgeCommit message (Collapse)AuthorFilesLines
2019-05-31EPUB export: fix not properly paired openPageSpanMark Hung6-11/+23
Fix the test case converting abi11105.abw to EPUB file. ( the attachment at <https://bugzilla.abisource.com/show_bug.cgi?id=11105#c1> ) soffice.bin: .../sax/source/expatwrap/saxwriter.cxx:1184: virtual void (anonymous namespace)::SAXWriter::endElement(const rtl::OUString &): Assertion `aName == m_pSaxWriterHelper->m_DebugStartedElements.top()' failed. We used to invoke handlePageSpan when starting a paragraph or a table element that has master-page-name defined in the referred style, and invoke closePageSpan when XMLBodyContentContext. Limit the handling of page span to top-level paragraph or tables so that it doesn't messed up in the nested ( paragraph that changed it's page style in a table cell ) case. Change-Id: Ic8637663aaa7506ced9758bd7ccd7233309e8557 Reviewed-on: https://gerrit.libreoffice.org/73214 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-05-13fix wrong SET/QUERY flags passed to uno::ReferenceNoel Grandin1-1/+1
By creating deleted methods for the wrong calls. Avoids the compiler needing to construct a temporary Change-Id: I3b8c648d6bb22d22827bf74f21ea5a2a17fc0f6a Reviewed-on: https://gerrit.libreoffice.org/72103 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-04-19tdf#42949 Fix IWYU warnings in comphelperGabor Kelemen1-0/+1
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Also re-evaluate some blacklisted headers and recheck include/comphelper/ Change-Id: Ib7eea5951e849c07cea2e2782be4e8945f71ad96 Reviewed-on: https://gerrit.libreoffice.org/70899 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-04-17EPUB export: make member variable privateMiklos Vajna14-174/+193
In most cases these were public without a good reason, in other cases setter / getters are added. Change-Id: Id6c1032189db1bba211344162e737dabf7ff3f07 Reviewed-on: https://gerrit.libreoffice.org/70842 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-04-14tdf#120703 PVS: V581 ifs with identical conditionsMike Kaganski1-7/+1
V581 The conditional expressions of the 'if' statements situated alongside each other are identical. Change-Id: I18562d60e33c7ecff14807976dde4cbcae3f665b Reviewed-on: https://gerrit.libreoffice.org/70731 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2019-03-25tdf#42949 Fix IWYU warnings in include/sfx2/[a-D]*Gabor Kelemen1-0/+1
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I444cb71bc3d045072a4b1f9eed279ed7e425a0d4 Reviewed-on: https://gerrit.libreoffice.org/69481 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-03-06remove some unnecessary typedef struct... sugarNoel Grandin1-26/+16
Change-Id: I1576282b0a0a3af8ae14c04725d9c4900073f2c4 Reviewed-on: https://gerrit.libreoffice.org/68758 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-02-08o3tl::make_unique -> std::make_unique in tools..xmloffGabor Kelemen1-3/+1
Since it is now possible to use C++14, it's time to replace the temporary solution with the standard one Change-Id: Ib3201f865d43f372007cdf381c7e244e9cbeae26 Reviewed-on: https://gerrit.libreoffice.org/67474 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2018-12-10tdf#42949 Fix IWYU warnings in include/vcl/s*Gabor Kelemen2-0/+2
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ie87d27dd2c385a63349e0b322fd067ba03d2d152 Reviewed-on: https://gerrit.libreoffice.org/64479 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2018-11-29tdf#42949 Fix IWYU warnings in include/vcl/[i-m]*Gabor Kelemen26-3/+26
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: If1b2e04872eb0dd6725802c1709a9085f4cd8c91 Reviewed-on: https://gerrit.libreoffice.org/64141 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2018-11-27tdf#42949 Fix IWYU warnings in include/vcl/[f-h]*Gabor Kelemen1-0/+2
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ice2eb8c5994bf2ccb88972332ca4a1d3ed41752a Reviewed-on: https://gerrit.libreoffice.org/63826 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2018-11-06convert some macros to local functionsNoel Grandin1-2/+4
Change-Id: If2c89f0f53615f6200b6cd1fb6267cc9b47df927 Reviewed-on: https://gerrit.libreoffice.org/62884 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-26tdf#42949 Fix IWYU warnings in include/unotools/*Gabor Kelemen1-0/+1
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: I444c43b9d549977039f25bec2b5bf666c3e15e0e Reviewed-on: https://gerrit.libreoffice.org/62041 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-10-24remove more rtl::OUString and OString prefixesNoel Grandin4-53/+52
which seem to have snuck back in since the great rounds of removals. Change-Id: I85f7f5f4801c0b48dae8b50f51f83595b286d6a1 Reviewed-on: https://gerrit.libreoffice.org/62229 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-24weld AdvancedSettingsDialogCaolán McNamara3-3/+3
make run virtual and fold executes into it, so GenericUnoDialog can call run on tabdialogs to do the right thing, and allows Start_Impl to be private again Change-Id: Ic457edfbdc7457f4c49d4e8ad679903f38ad9b42 Reviewed-on: https://gerrit.libreoffice.org/62227 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-10-04drop SvMemoryStream::GetBufferNoel Grandin2-4/+4
since it does the same thing as GetData() Change-Id: I18d35aa4e67ad7775987160c021863d0de90179b Reviewed-on: https://gerrit.libreoffice.org/61350 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-29Simplify containers iterations in w*Arkadiy Illarionov2-14/+10
Use range-based loop or replace with STL functions. Change-Id: Ie1e169f9d2d44e188180164bd1f93af43740425d Reviewed-on: https://gerrit.libreoffice.org/61141 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-17rename to weld::ComboBox are they are not text only nowCaolán McNamara3-19/+16
Change-Id: Ice26d1fd2ad97a6959c6916fef428777efea9c2d Reviewed-on: https://gerrit.libreoffice.org/60500 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-09-17New loplugin:externalStephan Bergmann1-1/+1
...warning about (for now only) functions and variables with external linkage that likely don't need it. The problems with moving entities into unnamed namespacs and breaking ADL (as alluded to in comments in compilerplugins/clang/external.cxx) are illustrated by the fact that while struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { struct S2: S1 { int f() { return 1; } }; int f(S2 s) { return s.f(); } } int main() { return f(N::S2()); } returns 1, both moving just the struct S2 into an nunnamed namespace, struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { namespace { struct S2: S1 { int f() { return 1; } }; } int f(S2 s) { return s.f(); } } int main() { return f(N::S2()); } as well as moving just the function f overload into an unnamed namespace, struct S1 { int f() { return 0; } }; int f(S1 s) { return s.f(); } namespace N { struct S2: S1 { int f() { return 1; } }; namespace { int f(S2 s) { return s.f(); } } } int main() { return f(N::S2()); } would each change the program to return 0 instead. Change-Id: I4d09f7ac5e8f9bcd6e6bde4712608444b642265c Reviewed-on: https://gerrit.libreoffice.org/60539 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-09-13loplugin:constfields in writerfilterNoel Grandin1-3/+3
Change-Id: Ibe380e1fb35d9defc478d459a988f9f6df13bf35 Reviewed-on: https://gerrit.libreoffice.org/60427 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-09-13new loplugin simplifyconstructNoel Grandin1-2/+0
no need to init smart pointers with nullptr, they all have default constructors that do this already Change-Id: Ief20c060daa0def8c1aa82f1cf8dc4bc696761e9 Reviewed-on: https://gerrit.libreoffice.org/59818 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-07-12Add missing sal/log.hxx headersGabor Kelemen10-0/+15
rtl/string.hxx and rtl/ustring.hxx both unnecessarily #include <sal/log.hxx> (and don't make use of it themselves), but many other files happen to depend on it. This is a continuation of commit 6ff2d84ade299cb3d14d4110e4cf1a4b8070c030 to be able to remove those unneeded includes. This commit adds missing headers to every file found by: grep -FwL sal/log.hxx $(git grep -Elw 'SAL_INFO|SAL_INFO_IF|SAL_WARN|SAL_WARN_IF|SAL_DETAIL_LOG_STREAM|SAL_WHERE|SAL_STREAM|SAL_DEBUG') to directories w* x* Change-Id: I27bff44da3d34d24262031c7489e755311599bc5 Reviewed-on: https://gerrit.libreoffice.org/57307 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-07-10pass SvStream around by std::unique_ptrNoel Grandin1-3/+3
and give utl::OStreamWrapper a new constructor so that it knows it is taking ownership of the SvStream, which appears to fix several leaks Change-Id: Idcbcca9b81a4f0345fd8b8c8a2f4e84213686a6b Reviewed-on: https://gerrit.libreoffice.org/57187 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-06-07Fix IWYU warningsMiklos Vajna2-2/+14
Change-Id: I0442d201a5175a9929d3ea79d79f80db7930b565 Reviewed-on: https://gerrit.libreoffice.org/55394 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-05-28loplugin:unusedmethodsNoel Grandin2-6/+0
Change-Id: I64df1f467986b3d70c058adff289a6dd8f00fb20 Reviewed-on: https://gerrit.libreoffice.org/54821 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-05-18Fix some IWYU warningsMiklos Vajna5-10/+75
Change-Id: I11d874caad9174fb1a70121f1772e117753ee519 Reviewed-on: https://gerrit.libreoffice.org/54503 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-05-15weld WPFTEncodingDialogCaolán McNamara50-142/+124
and pass in parent window for dialog Change-Id: Ibe9f576a74dfbbee3e568c8d3454440700cb0405 Reviewed-on: https://gerrit.libreoffice.org/54328 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-05-10writerfilter, writerperfect: various small cleanupsMiklos Vajna2-2/+1
Change-Id: Iea26b73bd91ed178cc4f2279c23246d79f48a6be Reviewed-on: https://gerrit.libreoffice.org/54063 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-05-01convert a sequence of if to a switchDavid Tardon1-23/+27
Change-Id: Ibca33b2170348ce56e9fa376009ee1cdea2dd67e
2018-05-01tdf#117323 fix import of MS Multiplan for DOSosnola1-1/+6
Change-Id: Ica053852c17ac993b4e50c4c58dbaf2ee4f33035
2018-04-27replace a series of if/else if/ by a switchDavid Tardon2-32/+30
Change-Id: I6319971e1a2a4bffa0466fa37a31beff5a349fd1 Reviewed-on: https://gerrit.libreoffice.org/53535 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
2018-04-26tdf#116822 export ruby text and base text to epub.Mark Hung1-0/+85
Backport aa254c9e6f2d1ecfa2512111746a77c05ba9717f from libepubgen, implement XMLRubyContext, XMLRubyTextContext, XMLRubyBaseContext. Character formats of ruby text, ruby alignment, and ruby position are not implemented yet. Change-Id: I6c3708e6bc8e9e36a68171a037fd393f45d8d34f Reviewed-on: https://gerrit.libreoffice.org/53408 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-04-26upload libwps 0.4.9David Tardon1-0/+5
Change-Id: I9571d91d6ce81d7e8752f24c3220f858a5303986 Reviewed-on: https://gerrit.libreoffice.org/53431 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: David Tardon <dtardon@redhat.com>
2018-04-20writerperfect: astyle -> clang-formatMiklos Vajna90-1974/+2247
< vmiklos> dtardon: are you strongly attached to astyle usage in core.git writerperfect/? my problem is that 1) when less regular contributors touch it, they don't run astyle 2) core.git has git hooks in place to enforce consistent style for selected files, but that uses clang-format. i wonder if switching to the standard core.git clang-format would be an option to stop this reformat game <@dtardon> vmiklos, clang-format is okay. we started to use astyle years ago, before there were even any serious talk about automatic formatting for the whole libreoffice Change-Id: I844fc9c2e8560e54a49f26064cc0b3c55a5f034c Reviewed-on: https://gerrit.libreoffice.org/53184 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-04-18weld EPUBExportDialog and add parentCaolán McNamara4-120/+110
Change-Id: Iec4fa3afb1e90ec36f792ea65b8c57b11cff98b3 Reviewed-on: https://gerrit.libreoffice.org/53094 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-04-11writerperfect: fix whitespaceMiklos Vajna2-3/+9
Be consistent with surrounding code. Change-Id: I86eb3a663a54a63c850ada229ea24d9c770365df Reviewed-on: https://gerrit.libreoffice.org/52708 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-04-10tdf#115623: invoke openPageSpan / closePageSpanMark Hung7-0/+50
* For paragraphs or tables whose styles specify style:master-page-name, it indicate starting a new page style and should invoke openPageSpan / closePageSapn properly. * closePageSpan at the end of text body is invoked. Change-Id: Ic85157c9b1a43c94a027b464ad9105e9072afcf7 Reviewed-on: https://gerrit.libreoffice.org/52082 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-04-09use more DBG_UNHANDLED_EXCEPTIONNoel Grandin1-6/+7
so we get nice logs of the exception dynamic type for UNO exceptions. Change-Id: Ic0b10dc14d354a2c9a0591b3a51d2f1640d54bdb Reviewed-on: https://gerrit.libreoffice.org/52465 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-08tdf#115623: EPUB export: support style:master-pageMark Hung6-2/+29
Change-Id: I12d04c2e346c5202274a01b1f8950e3412dc9081 Reviewed-on: https://gerrit.libreoffice.org/52081 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-04-06weld linkeditdialogCaolán McNamara1-1/+1
which enables changing FileDialogHelper over to welded Change-Id: I988342a6574cb7ed09b2724929e8c7117474a56c Reviewed-on: https://gerrit.libreoffice.org/52388 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-04-05tdf#115623: EPUB export: handle style:page-layoutMark Hung6-3/+62
handle style:page-layout XMLPageLayoutPropertiesContext, store style:writing-mode so that it can be processed in libepubgen. Change-Id: Id997ef84a39bd3321d678ea23c5d1b9101297b34 Reviewed-on: https://gerrit.libreoffice.org/52080 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-03-09inherit welded dialogs from a common ancestorCaolán McNamara3-3/+3
Change-Id: Ifa6c871a134cf89bfba71b1049a115cf7c953c42 Reviewed-on: https://gerrit.libreoffice.org/50936 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-03-09loplugin:redundantfcast look for unnecessary temporariesNoel Grandin1-1/+1
when calling methods that take a const& Change-Id: Idf45dfd9fea0de6fae0b1f89550f2f7fc302aa15 Reviewed-on: https://gerrit.libreoffice.org/50970 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-03-05weld SfxPasswordDialog DialogCaolán McNamara3-12/+12
Change-Id: If8c9757986f4af7b7927717221860e65c8c7285e Reviewed-on: https://gerrit.libreoffice.org/50755 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2018-02-27astyleDavid Tardon3-33/+33
Change-Id: I3ea599f491a464458865ce42930be4728ede5dc9
2018-02-27set number of read bytes correctlyDavid Tardon1-1/+4
It was wrong if we read less than was expected. Thanks to Antti Levomäki and Christian Jalio from Forcepoint. Change-Id: I070c1731d1aace4c101fa01efed0c28734c44899
2018-02-12EPUB export: pick up XMP metadata from 'metadata.xmp'Miklos Vajna1-2/+1
This used to be <filename>.xmp, but that's inconsistent with how cover image is not <filename>.jpg but cover.jpg (or .png, etc). Also it was redundant, since these files are in the media directory, for which the default is the <filename> directory. Change-Id: Iadfebf2f9c336f443537759b1e58409a93e1c51d Reviewed-on: https://gerrit.libreoffice.org/49604 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-02-01EPUB export: can use std::move() hereMiklos Vajna3-5/+7
And get rid of an easy to avoid include if we are at it. Change-Id: I63cb4628a3a7038aab91c66f592920923a31d7a6 Reviewed-on: https://gerrit.libreoffice.org/49060 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-24-Werror=parentheses (upcoming GCC 8)Stephan Bergmann1-2/+2
Change-Id: I4522dc7929030c5da59f2ab030a806ebe7516bd1 Reviewed-on: https://gerrit.libreoffice.org/48403 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2018-01-23EPUB export, fixed layout: add chapter names to the navigation documentMiklos Vajna4-20/+45
Extend vcl::PDFExtOutDevData so that it's possible to use it outside the PDF export; this way the EPUB export can know which chapters start on which page. This means fixed and reflowable layout has the same table of contents, instead of just Page <N> in the fixed layout case. Change-Id: I935fb23c66ec747431b91e83b0e677d4e5f704b9 Reviewed-on: https://gerrit.libreoffice.org/48332 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>