summaryrefslogtreecommitdiff
path: root/sw
AgeCommit message (Collapse)Author
2014-09-10Invalidate rect cache before moving objectJan-Marek Glogowski
Otherwise I get sw/source/core/layout/anchoredobject.cxx:582: <SwAnchoredObject::GetObjRectWithSpaces> - cache for object rectangle inclusive spaces marked as valid, but it couldn't be. Missing invalidation of cache. Please inform OD. Change-Id: I3f315b15fca6e2480c11183269be5583e6aea123 Reviewed-on: https://gerrit.libreoffice.org/10977 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-10fdo#80926 Don't move anchors of invalid pagesJan-Marek Glogowski
If the anchor is valid, check if its page is valid too, before moving anchors on view change. Change-Id: Idffdfdb786cb29a105c06d652e6ad7315abfb4c5 Reviewed-on: https://gerrit.libreoffice.org/10976 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-10Fix single node CopyRangeJan-Marek Glogowski
Previously there was a restriction for the range to contain at least two nodes. Change-Id: Iadf21d3928303c2ab8df0d93dabd969ed1ff7e09 Reviewed-on: https://gerrit.libreoffice.org/10972 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-10Normalize SwDBManager::Merge{MailFiles,Documents}Jan-Marek Glogowski
There is still a difference, if run mail merge throught one or the other function (MM wizard or UNO). Change-Id: Ia372bd3edea4c8dfb58e045fc8fed2efcb2a4fde Reviewed-on: https://gerrit.libreoffice.org/10971 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-10sw: [loplugin:externandnotdefined]Michael Stahl
It turns out that document compare / merge and master document insert file are all the callers of SwFindDocShell() so move the fix-up there... Change-Id: I912a464c3acab8d0adb7b5b659d62f629a15cb70
2014-09-10WaE: implicit conversion of literal of type 'int' to 'bool'Tor Lillqvist
Change-Id: Ie21c61d718d720ec6bac741cd17e807123f47129
2014-09-10more fixes for SfxItemStateNoel Grandin
In commit 88a874fc "convert SfxItemState constants to a proper enum" I made some mistakes in converting bitwise logic to boolean logic. I fixed one of those places in commit 7ad83656 "fix bitwise->logic conversion in SfxItemState commit" This commit fixes the other places where I converted bitwise to normal boolean logic. I also validated that none of the existing code tries to uses combinations of these enum values. This commit also introduces an exception-throwing check in the one place where the enum is explicitly cast to make sure that no combinations sneak in. Change-Id: I545f7d17b76c4fd999078867caec314e83ffe165 Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
2014-09-10Replace uses of old SFX_ITEM_AVAILABLE alias with SFX_ITEM_DEFAULTStephan Bergmann
Change-Id: I88eeac06413fc3935cbbdb357ff8bf9acaa383a8
2014-09-10Replace uses of old SFX_ITEM_ON alias with SFX_ITEM_SETStephan Bergmann
Change-Id: I64be7ca711dcd3ea7c4d5840a30f2f701d055e1b
2014-09-10fdo#83655: sw: RSID-only hint assertion when inserting in master documentMichael Stahl
For the temporary document there is no layout so SwTxtNode::MakeFrm() isn't called. (regression from 6db39dbd7378351f6476f6db25eb7110c9cfb291) Change-Id: I711d32a81519edd6840cc29f5cd9dbc57ef21982
2014-09-10Add debug documents to SwDBManager::MergeMailFilesJan-Marek Glogowski
Just like the debug documents in SwDBManager::MergeDocuments. Change-Id: I275575853c80d4e19d6df5ba9d8dc689353d7c85 Reviewed-on: https://gerrit.libreoffice.org/10970 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-10Add debug messages for sw.{createcopy,docappend}Jan-Marek Glogowski
This adds a lot of SAL_INFO messages to SwDoc::CreateCopy and SwDoc::Append. Change-Id: Ie924e20698bec84482fcc5496175a9e29245729e Reviewed-on: https://gerrit.libreoffice.org/10969 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-10MM: introduce SwDoc::Append helper functionJan-Marek Glogowski
This drops all the specialized, workaround code from MM, introduced to use the SwFEShell::Paste function and additionally merges and renames SwDoc::Paste into SwDoc::Append. There is still a little common codepath, therefore this adds comments to always update both functions. Change-Id: I704b3ef3257dd977dac95e16e25049ff8ade97ed Reviewed-on: https://gerrit.libreoffice.org/10967 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-10IDocumentContentOperations::CopyRange: fix commentMiklos Vajna
Change-Id: Ide5705323579aa5ea1e725685acb7421f416cf04
2014-09-09MM: always copy the internal documentJan-Marek Glogowski
There is really no need to create the first document via UNO createClone(), which is also slower then the internal copy. Actually createClone also calls createCopy, but without initializing the document. Change-Id: I2d1ee6e12e37caf1b0d9bfa393fb4240516628e9 Reviewed-on: https://gerrit.libreoffice.org/10966 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-09semibold->boldCaolán McNamara
Change-Id: I563f4530f2003ea3090cd15696ea53143f7b3aa6
2014-09-09abi#10076 RTF export: handle frames without a valid anchor pointMiklos Vajna
Ideally all frames have an anchor point in the maFrames vector, as provided by MSWordExportBase. If that's not the case, then we have no idea what would be a valid anchor point: just export those as inline, as we did before. Change-Id: I81134d9fb8dc4ca166084964d277ac02ceccde7b
2014-09-09Replace the whole content for copied documentsJan-Marek Glogowski
If the document is initialized in CreateCopy, it already contains the initial empty paragraph. So we have to delete the content from initial document, as we're going to replace the whole content with the pasted document. Change-Id: Ie6a64dcb070f7d611dfde97f2c1a721834b4167b Reviewed-on: https://gerrit.libreoffice.org/10963 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Tested-by: Björn Michaelsen <bjoern.michaelsen@canonical.com>
2014-09-09Resolves: fdo#83251 menu on master doc insert disappearsCaolán McNamara
on releaseing mouse button Change-Id: Ia2f8da6e62d708744707b8187d5961fe12169eb8
2014-09-09fdo#82496: Change picture option by rightclickingJennifer Liebel
Change-Id: I31fb1a1f89030610a9d11b9236e8cde22dbc0ca5 Reviewed-on: https://gerrit.libreoffice.org/11332 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-09-09fdo#83428 Add test case for custom property dropped in docxHeena Gupta
Reviewed on: https://gerrit.libreoffice.org/11346 Change-Id: I8afc0ae1351b4c8bb25f864040b99832b1bed3c1
2014-09-08coverity#704947 Dereference after null checkCaolán McNamara
Change-Id: Id6eb50de48b8a674d7b48d1256b1529637155eb1
2014-09-08sal_Int16 -> FlyProcessingStateMiklos Vajna
Change-Id: Ibbc48711e656a804a5ac6a5651091131bbf81c4f
2014-09-08fdo#83057 File corrupts on save, as SDT is added incorrectlyVinaya Mandke
A fly frame was attached to a para which started within a hint (run) containing an SDT. This SDT was handled while exporting the FLYFRAME and also the text of the run. So, eventhough the original file had only one sdt in the header, the RT file had two; one for a seperate run as expected, and one incorrectly exported in the alternateContent (FLYFRAME) So don't collect SDTPr from grabbag if the FLY is not processed. As, the SDT will be handled when the run is exported. Change-Id: I7b3c94208c171afbec54467fd6b756a6e30c816b Reviewed-on: https://gerrit.libreoffice.org/11161 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
2014-09-07RTF import: adapt getProperties() to createStyleProperties()Miklos Vajna
Change-Id: I8561aa1532a863bf7f8dd44fbd40e8e0187e4967
2014-09-07more accurate typingLionel Elie Mamane
Change-Id: Ibccf8c5cf520b79da0914eccbebdbb68601dd0f1 Reviewed-on: https://gerrit.libreoffice.org/11314 Reviewed-by: Lionel Elie Mamane <lionel@mamane.lu> Tested-by: Lionel Elie Mamane <lionel@mamane.lu> Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com> Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
2014-09-07AUTH_FIELD_END looks like it is made for thisLionel Elie Mamane
avoids mucking with casts and allows more accurate typing Change-Id: I968a2f7fcfa5534947102918125b095ca3b4a66c Reviewed-on: https://gerrit.libreoffice.org/11313 Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com> Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
2014-09-07push explicit cast to minimal expressionLionel Elie Mamane
Change-Id: I33879aa7724703745728128e59735e5d16aa2a57
2014-09-06SfxHint: convert home-grown RTTI to normal C++ RTTINoel Grandin
Also note that I fixed a bug in SvxFontMenuControl::Notify where the if statement had the check the wrong way around. Change-Id: I611e8929c65818191e36bd80f2b985820ada4411 Reviewed-on: https://gerrit.libreoffice.org/11147 Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com> Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
2014-09-06fdo#82078 RTF import: fix bold text spilling over to non-bold textMiklos Vajna
Regression from commit 41890bf714803969515578b47e63fa9730ea7090 (fdo#54473 fdo#57133 fix RTF import of character styles, 2012-12-04), the problem was that the style undoing magic introduced in 1be0a3fa9ebb22b607c54b47739d4467acfed259 (n#825305: writerfilter RTF import: override style properties like Word, 2014-06-17) was not used for character styles. Change-Id: Id31cfd5574a83bcf2895f0c2fd496fa60791cbb3
2014-09-06Fix build: narrowing castMatteo Casalin
Change-Id: Iebcc89019dc5c482ab00743071002e2983e65469
2014-09-06sal_uInt16: use more proper types, avoid unneeded casts, constifyMatteo Casalin
Change-Id: Ic30441307eaa391868ffbb85a67d1c0327258084
2014-09-06Use more suitable integer types, avoid conversions, constifyMatteo Casalin
Change-Id: I6b7a3b763ea3e2dc6d327c61668fa413fbc60a07
2014-09-06No need to differentiate between 1 and 2: only !=0 mattersMatteo Casalin
Change-Id: I981472a0b33c6f35f87d891fc7b70c92e621bf95
2014-09-06Reduce scope and avoid casts at each call-placeMatteo Casalin
Change-Id: Iade7f5e174b74ea156c0e0bafc5c7c72e4b86dbd
2014-09-06sal_uInt16 to more proper typesMatteo Casalin
Change-Id: I3728f29e6cb869b3b5e27afd2c1dcdf857fd96de
2014-09-06Simplify by early bailoutMatteo Casalin
Change-Id: I9815ced0495f3066f8b6477794f33bbd77c613ca
2014-09-06sal_uInt16 to more proper types, group a test into a boolMatteo Casalin
Change-Id: I4763e1dfd3d674d36063bada83373a6e45c97303
2014-09-06sal_uInt16 to more proper types, constifyMatteo Casalin
Change-Id: Ic587040d62eb02cc2e1907eee2190e0af95d959d
2014-09-06Use arithmetic instead of while loopMatteo Casalin
Change-Id: I35738f09ec562815f74643a547505efb6d9a0bfe
2014-09-06sal_uInt16 to more proper types, constify, avoid unneeded castsMatteo Casalin
Change-Id: I6e7d2c9861e9e004a48595d77b919c37409142f1
2014-09-06SwNoteURL: remove Count and GetURLNote, used only internallyMatteo Casalin
Directly access data member and switch from sal_uInt16 to size_t Change-Id: I8544463dabc099aa94ae0281e636dbf7835c23b4
2014-09-06Simplify by early bailoutMatteo Casalin
Change-Id: Id6697760f6037f3a11d5b72d1727e48fb3ec6b56
2014-09-06Remove unneeded castMatteo Casalin
Change-Id: Ia5ed84488d14e6e779d62e9903c1350b703ad3c6
2014-09-06Use for loops and more proper integer types, constifyMatteo Casalin
Change-Id: I3d4dc54f4178b5607dc75352696228410d08e38e
2014-09-06Remove unneeded local scopeMatteo Casalin
Change-Id: I51fe6e130006fdca547abe99a44117f710d1e776
2014-09-06Use enumeration directlyMatteo Casalin
Change-Id: I5b537bb863eafa9e508c7298c611b0d1c0145d77
2014-09-06HasKana() can be privateMatteo Casalin
Change-Id: I6c26cbf71214dbd307291fdbb63dd3af74a3a4e5
2014-09-06sal_uInt16 to more proper types, constifyMatteo Casalin
Change-Id: I2924f1f8c6ac0e82340293f92656541ffecbcf24
2014-09-06Use more proper types, constify, avoid unneeded conversionsMatteo Casalin
Change-Id: I7f1f587c39b9221363e90aea2cf7ed468ce5aac0