summaryrefslogtreecommitdiff
path: root/sw/source/filter/ww8/ww8par.cxx
AgeCommit message (Collapse)AuthorFilesLines
2019-08-05ofz#10198 reset uncommitted fly stuff & pams before applying redliningCaolán McNamara1-0/+3
Change-Id: I2a2587ec4590926f7cffc2a4d58a22d9d5f19c99 Reviewed-on: https://gerrit.libreoffice.org/59947 Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> Tested-by: Jenkins (cherry picked from commit 887ee9111f42847406c5ffc85a0ba635080de3de)
2019-08-02forcepoint#69 ditch any unclosed m_pPosAfterTOC before dropping cursorCaolán McNamara1-0/+1
Change-Id: I6b56a48f5449b25fe3bdc2e02d3885388b0da74f Reviewed-on: https://gerrit.libreoffice.org/58498 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit 71aae473c9c3cf15f75e2722afc7153a3af76d44)
2019-08-01ofz#6827 Bad-castCaolán McNamara1-7/+10
Change-Id: I856d781f122c21c02a0a8cd01369d49f50b8a555 Reviewed-on: https://gerrit.libreoffice.org/51365 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com> (cherry picked from commit 19f0b25acc2a23b790301755a9fee2629eb667b0)
2019-08-01ofz: returning SfxPoolItem belonging to localCaolán McNamara1-3/+3
Change-Id: Ib9760efb1231ef057dfd62d06095c15e3bf73a87 Reviewed-on: https://gerrit.libreoffice.org/43426 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> (cherry picked from commit a2ca21fada002b895202abd2cbb4997b112627f8)
2019-08-01ofz: check for null paraCaolán McNamara1-3/+7
Change-Id: Id31273b2a203414f8ad4f827c334ae17689560af (cherry picked from commit ebc2abf207c8d903b07f53ecefbca5731edcb1d6) Reviewed-on: https://gerrit.libreoffice.org/37875 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit d3ba63909740262e0cd64648e2eb00096b4626d2)
2019-08-01ofz: stay within available dataCaolán McNamara1-2/+2
Change-Id: Ic959cf5b2cd92ba5bc297e686beb1fd50427a994 Reviewed-on: https://gerrit.libreoffice.org/36102 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit fdcac49119d3fc9f6216af834e7afc56d2c2e376)
2016-10-26implement CryptoAPI RC4+SHA1 encryption scheme for doc importCaolán McNamara1-19/+91
there might be other variants out there in practice, but this works for default encrypted doc of word 2013 (cherry picked from commit 4f07175cd03bf0fa42992a06d51aed5b421adcf2) contains... rework things in light of now available documentation (cherry picked from commit 6ac3fb584409912d7a4e944a643bc9180bc03015) Change-Id: I995a0437d4001d63e1c3a821e00c05a2af429356 68c1d9489292e63f709bfbc990ffa5ad7d0f827a Reviewed-on: https://gerrit.libreoffice.org/30168 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2016-05-12clang-tidy modernize-loop-convert in swNoel Grandin1-5/+3
Change-Id: I1f4a0ad6658bd3154c48940296aa8edc1ea1612c Reviewed-on: https://gerrit.libreoffice.org/24876 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-10Insert explicit "break" when falling through to empty next caseStephan Bergmann1-0/+1
...which itself only contains a "break" (or nothing at all at the end of the "switch"), as otherwise Clang -Wimplicit-fallthrough would warn about these. Change-Id: I25c1cf2ca74dfeba7ca0385ca8f1c1bf30bbf91b
2016-04-21new plugin stylepoliceNoel Grandin1-9/+9
check for local variables which follow our member field naming convention, which is highly confusing Change-Id: Idacedf7145d09843e96a584237b385f7662eea10
2016-04-20loplugin:salbool: Automatic rewrite of sal_False/TrueStephan Bergmann1-1/+1
Change-Id: I5c33d8ed3551d9ad4432824995bfdc3f73cfc5f8
2016-04-18clang-tidy performance-unnecessary-copy-initializationNoel Grandin1-1/+1
probably not much performance benefit, but it sure is good at identifying leftover intermediate variables from previous refactorings. Change-Id: I3ce16fe496ac2733c1cb0a35f74c0fc9193cc657 Reviewed-on: https://gerrit.libreoffice.org/24026 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-07sw: replace boost::noncopyable with C++11 deleteMichael Stahl1-2/+4
Change-Id: I5c97c500096dee70bf9208daae38c3f042ac57d3
2016-04-07tdf#99120 DOC import: fix lack of first share after odd section breakMiklos Vajna1-1/+2
Commit 848b1a05c5c41b5e7ff19c984f60c297a8143990 (fix for bnc#659631, 2011-02-04) made wwSectionManager::InsertSegments() use SwPageDesc::WriteUseOn() directly, instead of going via SwPageDesc::SetUseOn() that takes care of not throwing away the higher share bits of the bitfield. This way the "is first shared" flag of the bitfield got cleared, even when the input document had no title page declared, so first header/footer must be shared. Fix the problem by using SetUseOn() in the DOC import as well when it comes to handling odd/even page section breaks. Change-Id: If167f4582919fa177840ed81e0a53aa379485598 Reviewed-on: https://gerrit.libreoffice.org/23885 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-03-22loplugin:constantparam in swNoel Grandin1-1/+1
Change-Id: I56925a8fd776b3ee787cc26adbaa08c58dd022c0
2016-03-17loplugin:constantparam in sotNoel Grandin1-1/+1
Change-Id: I380b5a824b1bc8cd322471519d2d87ab7f2bca1c Reviewed-on: https://gerrit.libreoffice.org/23320 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-24convert DocPasswordRequestType to scoped enumNoel Grandin1-1/+1
Change-Id: I25d217ca2cf3e8cc4dfaccc6dc7d5453ffdc6cb6
2016-02-22loplugin:commaoperator in sw/Noel Grandin1-4/+12
Change-Id: I9b00755707687e4c10c02bf49866571f2c44d8ba
2016-02-22loplugin:write only fieldsNoel Grandin1-2/+1
Change-Id: I45895e9845a9037da207f001fece427452ed499f
2016-02-04vcl: take into account the font width is the average font widthChris Sherlock1-1/+1
I'm changing the Font class function names: - SetSize -> SetFontSize - GetSize -> GetFontSize - SetHeight -> SetFontHeight - GetHeight -> GetFontHeight - SetWidth -> SetAverageFontWidth - GetWidth -> GetAverageFontWidth That's because it really makes no sense to say that there is a single constant font width because obviously proportional fonts don't have one - the best we can do is an average font width, which is what folks like Microsoft sort of do already. On a fixed font, the average is still accurate, for obvious reasons :-) I'm also not a fan of GetSize/SetSize as I find it a might too generic. Change-Id: Ib80a604ba62d6883fd6cbc7994da763976be5c70 Reviewed-on: https://gerrit.libreoffice.org/22069 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-01-13loplugin:unusedmethods unused return value in sw/Noel Grandin1-10/+7
Change-Id: Iaec71124b04ed678686d646df3ff0892585d3d50
2016-01-11loplugin:privatebase: Make derivation from noncopyable explicitly privateStephan Bergmann1-1/+1
Change-Id: Ia410950353aec0106ea82d025ed3ee89c79ca127
2016-01-10Fix typosAndrea Gelmini1-2/+2
Change-Id: I9a5940027423ff0791fa7da0b79b617412ce6b86 Reviewed-on: https://gerrit.libreoffice.org/21209 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2015-12-15filter: add BaseURL parameter to SvxMSDffManager::ImportOLE()Michael Stahl1-1/+2
... mainly for the (unlikely) case of ODF embedded objects in MSO binary files, which can be created by toggling the Tools->Options->Load/Save->Microsoft Office export settings. Change-Id: I270f1516b70b20ec0b60cfbd17c2c327c3d9efd0
2015-12-09DOC import: initialize RDF metadata before importing document propertiesMiklos Vajna1-0/+18
With this, it is possible to import part of the document as RDF statements later when SwFltControlStack::SetAttrInDoc() gets an SwFltRDFMark. Previously SfxBaseModel member functions like getMetadataGraphsWithType() and addMetadataFile() failed, as they tried to find the already imported document in UCB, which failed, as the import was still in progress. To prevent that, do the same as the ODT import in XMLReader::Read(), part "RDF metadata". One trick here is the call to comphelper::OStorageHelper::GetTemporaryStorage(), which gives an empty storage. Ideally a wrapper class would be needed that works on a SotStorage, but implements embed::XStorage, but that would be only used to find that the real storage doesn't provide a manifest.rdf stream, which is always the case. So instead of writing such a wrapper, just give loadMetadataFromStorage() an empty storage, which will have the same result without writing lots of dead code. Change-Id: Id1897838b1477eee0489b706d51cb6f59898877b
2015-12-09SwWW8ImplReader::GetSmartTagInfo: read from SmartTagDataMiklos Vajna1-1/+35
With this, SwWW8ImplReader::Read_FactoidBook() gets exactly the matching key/value strings for the smart-tag bookmark, so now only SwFltControlStack has to store the item and process it. Change-Id: If799d7d0bd1d69ddf8325d05f2b7c6e55112bba2
2015-12-08DOC import: read SmartTagDataMiklos Vajna1-0/+9
This only reads all the interesting info, SwWW8ImplReader::Read_FactoidBook() still has to put it on the filter stack in a later commit. Change-Id: Ic2e8b441367448b5bdf940bf8871f25afe8362c4
2015-11-25bin/rename-sw-abbreviations.shlibreoffice-5-1-branch-pointRobinson Tryon1-26/+26
This commit renames the most annoying abbreviations in Writer (and partially in the shared code too). Change-Id: I77e5134f42f25e3786afa36b7a505c7e3237a9e8
2015-11-17Don't assume sal_Unicode is unsigned shortStephan Bergmann1-1/+1
Change-Id: I3411c688361e95b4c72b5257cdd63b137dab0538
2015-11-11Resolves: tdf#95321 tables in headers/footers with wrong contentCaolán McNamara1-1/+1
Change-Id: I937ed893dfd9919bf48b8fd38a1b83c524200532
2015-11-11sw: prefix members of SwWW8StyInfMiklos Vajna1-16/+16
Change-Id: I2749607eb2271a838acb8220c80d9363d8e8d867
2015-11-10sw: rename sw::Frame in the WW8 filter to ww8::FrameMiklos Vajna1-3/+3
This way it's more clear that sw::FrameClient has nothing to do with sw::Frame, also later renaming SwFrm to SwFrame won't cause confusion about why do we have both sw::Frame and SwFrame. Change-Id: I87c4d199d418c77fdbb600fc388c8b9f026cb0fa
2015-11-10loplugin:nullptr (automatic rewrite)Stephan Bergmann1-130/+130
Change-Id: I01e11fa956a249974e77dce9deebe79311f098d0
2015-11-09Revert "Revert "fix tdf#94818 while retaining the tdf#90504 fix""Andras Timar1-5/+18
This reverts commit dad32b63f852716af94cf995696b62b6e60724bd.
2015-11-09Revert "fix tdf#94818 while retaining the tdf#90504 fix"Andras Timar1-18/+5
This reverts commit 959ac511dbebeb3983da92052ced837b39b74ed9.
2015-11-06com::sun::star->css in sw/source/coreNoel Grandin1-4/+4
Change-Id: I30016977f1be8fb53dd239367d043de92a9467d9
2015-11-06loplugin:stringconstant: elide explicit ctor usage (automatic rewrite)Stephan Bergmann1-2/+2
Change-Id: I55970d363ab53eb78d580192006e52d9240d46fb
2015-11-04loplugin:stringconstantNoel Grandin1-1/+1
Change-Id: Ic135382652966e80c288f3407508bdaf0c60316e
2015-10-20loplugin:defaultparamsStephan Bergmann1-3/+2
Change-Id: I11ff551955c1ac291ab576f2f18c2dd410427eda
2015-10-19loplugin:defaultparamsStephan Bergmann1-1/+1
Change-Id: Ib5b0e87064b6dcff03f6b77287a80ee2a03b8799
2015-10-17tdf#36117 .doc preserve page vertical alignment after RTJustin Luth1-0/+2
MSWord has a page-style vertical alignment (center/bottom/justify) setting that was lost after round-tripping through LibreOffice. Writer does not currently have the ability to vertically align text outside of a frame, but the setting should be preserved for interoperability. Change-Id: I91ae841b91ca2f2dd1b68212fdcdf830c7cef22a Reviewed-on: https://gerrit.libreoffice.org/18480 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Justin Luth <justin_luth@sil.org>
2015-10-16sfx items: Kill the unreadable & misplaced SFX_ITEMSET_ARG too.Jan Holesovsky1-2/+2
Change-Id: I1e0f96dce2b9cf9da32f4f577cf76e1d8824d37a
2015-10-16sfx items: The bDeep parameter of SFX_ITEMSET_ARG is always false.Jan Holesovsky1-2/+2
Change-Id: Ifdffc82c9b4ec2e534204294575a78e34e0338c1
2015-10-12fix tdf#94818 while retaining the tdf#90504 fixCaolán McNamara1-5/+18
Change-Id: Ia1c904b16d040714c8d5a0b4946bc42e6b8ac3bb
2015-10-12Replace "SAL_OVERRIDE" with "override" in LIBO_INTERNAL_ONLY codeStephan Bergmann1-2/+2
Change-Id: I2ea407acd763ef2d7dae2d3b8f32525523ac8274
2015-09-29Fix typosAndrea Gelmini1-4/+4
Change-Id: I2373a842818a5ac6ce5bd75205580f7cdc0212e4 Reviewed-on: https://gerrit.libreoffice.org/18988 Reviewed-by: Joren De Cuyper <jorendc@libreoffice.org> Tested-by: Joren De Cuyper <jorendc@libreoffice.org>
2015-09-09no point in reminding me now, we shipped a while backCaolán McNamara1-3/+1
Change-Id: I728d4c0c6e271e3a97a95996f96ed43c00a3abc8
2015-09-08loplugin:mergeclasses merge SwpHintsArray with SwpHintsNoel Grandin1-1/+1
and clean up the API a little, there were multiple versions of the same accessor with different names. Change-Id: I01e44a7a81c0d67cbb6135a6d196ee106cbf994a
2015-09-04drop pams before removing extraneous parasCaolán McNamara1-9/+8
and remove extra paras in order of largest index first Change-Id: Iafbe612a8a8bd51cb157b4a4c07031c6603d92ee
2015-09-01-fsanitize=enumStephan Bergmann1-2/+2
...as happens in CppunitTest_sw_filters_test with sw/qa/core/data/ww8/pass/CVE-2015-2467-1.doc, first at: > filter/source/msfilter/msdffimp.cxx:1477:17: runtime error: load of value 8193, which is not a valid value for type 'MSO_Anchor' > DffPropertyReader::ApplyCustomShapeTextAttributes(SfxItemSet&) const filter/source/msfilter/msdffimp.cxx:1477:17 > DffPropertyReader::ApplyAttributes(SvStream&, SfxItemSet&, DffObjData&) const filter/source/msfilter/msdffimp.cxx:2694:9 > SvxMSDffManager::ImportShape(DffRecordHeader const&, SvStream&, void*, Rectangle&, Rectangle const&, int, int*) filter/source/msfilter/msdffimp.cxx:4332:21 > SvxMSDffManager::ImportGroup(DffRecordHeader const&, SvStream&, void*, Rectangle&, Rectangle const&, int, int*) filter/source/msfilter/msdffimp.cxx:4119:39 > SvxMSDffManager::ImportGroup(DffRecordHeader const&, SvStream&, void*, Rectangle&, Rectangle const&, int, int*) filter/source/msfilter/msdffimp.cxx:4106:39 > SvxMSDffManager::ImportGroup(DffRecordHeader const&, SvStream&, void*, Rectangle&, Rectangle const&, int, int*) filter/source/msfilter/msdffimp.cxx:4106:39 > SvxMSDffManager::ImportGroup(DffRecordHeader const&, SvStream&, void*, Rectangle&, Rectangle const&, int, int*) filter/source/msfilter/msdffimp.cxx:4106:39 > SvxMSDffManager::ImportObj(SvStream&, void*, Rectangle&, Rectangle const&, int, int*) filter/source/msfilter/msdffimp.cxx:4033:16 > SvxMSDffManager::GetShape(unsigned long, SdrObject*&, SvxMSDffImportData&) filter/source/msfilter/msdffimp.cxx:6210:23 > SwWW8ImplReader::Read_GrafLayer(long) sw/source/filter/ww8/ww8graf.cxx:2502:17 > SwWW8ImplReader::ReadChar(long, long) sw/source/filter/ww8/ww8par.cxx:3634:17 > SwWW8ImplReader::ReadChars(int&, int, long, long) sw/source/filter/ww8/ww8par.cxx:3436:27 > SwWW8ImplReader::ReadText(int, int, ManTypes) sw/source/filter/ww8/ww8par.cxx:3974:22 > SwWW8ImplReader::CoreLoad(WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:5175:9 > SwWW8ImplReader::LoadThroughDecryption(WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:5773:19 > SwWW8ImplReader::LoadDoc(WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:6045:19 > WW8Reader::Read(SwDoc&, rtl::OUString const&, SwPaM&, rtl::OUString const&) sw/source/filter/ww8/ww8par.cxx:6167:20 > SwReader::Read(Reader const&) sw/source/filter/basflt/shellio.cxx:175:18 > SwDocShell::ConvertFrom(SfxMedium&) sw/source/uibase/app/docsh.cxx:258:22 > SfxObjectShell::DoLoad(SfxMedium*) sfx2/source/doc/objstor.cxx:790:23 > SwFiltersTest::filter(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) sw/qa/core/filters-test.cxx:112:20 Change-Id: Iafc548b5ba21a985521790770732f7f03e2485c9