summaryrefslogtreecommitdiff
path: root/sw/source
AgeCommit message (Collapse)Author
2014-11-08sw: delete the SwChapterNumRules binary Load/Store implementationMichael Stahl
Loading the outline formats from a StarOffice 3 user profile went out of style. Change-Id: I4989fa043a616428fea3705a72dee67082bfc226
2014-11-08sw: fix un-safe casts in SwXNumberingRulesMichael Stahl
At least they check that the pointer they reinterpret-cast without checking the type isn't null! Change-Id: I07770e274598b1c476b4c297ac1d388b7ca576e5
2014-11-08sw: remove the PropValData abominationMichael Stahl
Conciseness and type safety: why try to achieve both when you can settle for neither. Change-Id: I68399395083e3ad927c544700cb37363856b1788
2014-11-08sw: these can be assertsMichael Stahl
Change-Id: I4ad1ff6fad2f4097c128dcaea5cf6064e2524aad
2014-11-08sw: remove pointless inheritance of SwChapterNumRules from SwBaseNumRulesMichael Stahl
Change-Id: I5426977d4ed5539d79335df0aa4bcccd71dd8966
2014-11-08xmloff: remove unused parameter of SvxXMLListStyleContext::FillUnoNumRule()Michael Stahl
Change-Id: I359f37ce778d55e6868bd1c78c0ff0d452f36088
2014-11-08sw: store Outline Numbering as ODF fragment instead of SfxPoolItemsMichael Stahl
This should be less fragile and re-uses some xmloff and unocore code. Storing from ~SwBaseNumRules() does not work because other gobals that the export code relies on are already dead at the time it is called from a terminate() listener, so store when the dialog updates a format. Change-Id: I4e148b82d0a338ec7ffa6429c6e162db79f8c44e
2014-11-08sw: refactor SwXNumberingRulesMichael Stahl
... to get some static property getter setter functions. Change-Id: I3e69c0c01ee7ec2d17edbf06876c17cf4fce3833
2014-11-08SwFrmAddPage::SetFrmType: take an OUStringMiklos Vajna
Change-Id: I0d18aeee953d07ae9287ec1bca7d8deca8453d88
2014-11-08coverity#704961 Dereference after null checkCaolán McNamara
Change-Id: I6acca68cbebf149f7ac7f18fa0011e7f3d20a957
2014-11-08coverity#1251172 Dereference null return valueCaolán McNamara
Change-Id: Ic1f1c7f055f3fb21e7361a2e14f6eebe3dac4216
2014-11-08coverity#1251169 Unchecked dynamic_castCaolán McNamara
and coverity#1251170 Unchecked dynamic_cast Change-Id: I3a4806aff3b42ea3cf507c7f435bb687cac32c60
2014-11-07Correct number format mapping for CJK numbered lists in rtf/doc/docx filters.Mark Hung
Reviewed on: https://gerrit.libreoffice.org/12252 Change-Id: I2d8760c7ecb3677464e167528b2424aaca19a0d7
2014-11-07SwFrmPage::SetFrmType: take an OUStringMiklos Vajna
Currently these values are ASCII, but it's better to convert it to OUString from the string literals directly than trying to guess their encoding later. Change-Id: I2629329a84c89410bd6d81d871b564988394e74e
2014-11-07Remove some useless swapping call inside SwGrfNodeZolnai Tamás
Change-Id: I4cd2677197c7a6cff71e2966c2b2dd2285032c07
2014-11-07Make SwGrfNode swapping methods privateZolnai Tamás
Change the filter test accordingly. Change-Id: Ide3043f2f245c097a7b4c07ba2e0713510296b3e
2014-11-07Swapping Graphic is a privilage of GraphicObject.Zolnai Tamás
This means more things: * Graphic won't swap out itself, so those classes which uses Graphic without GraphicObject won't need to deal with swapping. * When a Graphic is queried from GraphicObject the caller won't need to deal with swapping, because GraphicObject swaps it in before return. * GraphicObject will swap in the Graphic always when a swapping dependent data is queried (e.g. whole graphic, transformed graphic or AnimationNotifyHdl) Change-Id: I2bf6e37291ec94146f10aac4a35084682437ed16
2014-11-07Remove unused Graphic member of SwOLENodeZolnai Tamás
Change-Id: Iaff7e86a8e11e9befc6feacdafd3a78a1971bbcd
2014-11-07Be explicit here when to swap out as a linkZolnai Tamás
Change-Id: I70dd00d5f82c5f4f622805e1d6ee1dfc30900b31
2014-11-07More replacements of manual swapping with SwGrfNode::GetGrf()/GetGrfObj()Zolnai Tamás
Change-Id: Ie56584c03af8a6d3ea8f8d4294f5492a841933b7
2014-11-07Make GetTwipSize() call SwapIn() by itself in case of invalid sizeZolnai Tamás
Change-Id: I5bc6cf097e61d65007dde531af4a213b19e8ca5b
2014-11-07Printing: remove an other manual swap out callZolnai Tamás
Change-Id: I2b6d6eaa072d9948eb5734e978d68d3bc37701b2
2014-11-07Paint background images always via drawinglayerZolnai Tamás
Painting via GraphicObject is obsolete. See fdo#68927 where the problem was the quality of svg graphics, it seems a good idea to extend this improvement to all graphic type. Change-Id: I57a26d4fcfea8e4f666504a90281365e8a9a7e1d
2014-11-07More useless static bool variables.Zolnai Tamás
Change-Id: If09aa23768f73bbf659966e4e5aac82dca83d1b6
2014-11-07Swap in graphic by SwGrfNode and not manuallyZolnai Tamás
It's a Writer specific problem, that images lost during export because of not swapped in graphic data. Other components (Impress, Calc...) use SdrGrafObj to get the graphic and SdrGrafObj calls swap in before retrun with the graphic. Change-Id: I7398d8e3f6535199b10de048acd58543bdb42531
2014-11-07Make SetSwapState() an internal methodZolnai Tamás
So we can be sure it is always called when user data changed. Change-Id: If107907afffb85a7a57817f5807847a5c028416c
2014-11-07MS export: don't need to manually swapout images after swapin themZolnai Tamás
We have some good auto mechanisms for that. Change-Id: I487dbf4a5fc69c7563dfbc5c21f9ebdb05ba6b9e
2014-11-07Remove manual SwapOut() call in ODF exportZolnai Tamás
We have a good auto swapout mechanism which will prevent excessive memory use. Change-Id: I362f51c724ac31704561abe8b961910f5d490f04
2014-11-07Avoid using null pointer as a special indicatorZolnai Tamás
When ImpGraphic::ImplSwapOut() is called with null pointer it was assumed that it is becase the graphic is a link and so we don't need to swap out it actually (we can load it anytime using the link), only clear the graphic's internal data. The problem with that it can happen that ImplSwapOut() is called with null pointer accidentally on a non-link graphic object which leads to that we loose the graphic. Seems more robust to use an explicit indicator (GRFMGR_AUTOSWAPSTREAM_LINK) for links swapout. indicator Change-Id: Icf31524a192c7866278ba6a13eb85648aa69f554
2014-11-06Revert "use the new OUString::fromUtf8 method"Stephan Bergmann
This reverts commit 05050cdb23de586870bf479a9df5ced06828d498, not all places that use e.g. OStringToOUString to convert potential UTF-8 are guaranteed to fulfil the prerequisites necessary to use fromUtf8 (and some places like e.g. in codemaker are happy with the best-effort effect of OStringToOUString's OSTRING_TO_OUSTRING_CVTFLAGS).
2014-11-06name of mailmerge marks is actually irrelevantLuboš Luňák
UNO bookmarks have internals names and ignore this Change-Id: I37baa4c9bcf9cec37f91e3b1d0fb2fad322ceda8
2014-11-06do not repeatedly relayout mailmerge document after each changeLuboš Luňák
When mailmerge uses a single document for all the generated documents, doing a layout of this increasingly large document after every generated document addition was getting slower and slower (no wonder). My recent changes should have removed all needs for any layout in progress, so it should be enough to just once calculate the final layout. The final layout still appears to be needed, leaving it as it is to get layout done on the fly puts e.g. 2-page documents on wrong starting page (maybe just invalidating something would fix that). Debug build shows warnings from vdraw.cxx about moving anchor from an invalid page because of broken layouting, but those were there already before, so I assume those are not really significant (or at least made worse by this commit). Change-Id: I62601ad6dccaa008783d1ce34c9e4f66f9621a56
2014-11-06compute page offset for mailmerge based on source document rather than targetLuboš Luňák
This removes another need for doing repeated and expensive layouts of the target document. Change-Id: Id78bc3ccc71c17e42f858dc9660866b9c94dea3a
2014-11-06use bookmarks to mark mailmerge parts in a mailmerge document (fdo#80823)Luboš Luňák
Instead of page numbers, which - was somewhat fragile (and broken, as it was actually off-by-one) - required repeated re-layout of the increasingly large document, making mailmerge awfully slow. The re-layout is not removed by this commit, as it needs further checking whether it can be removed. See the bugreport for details. Change-Id: Ib09bd5f5a6a549c3d38ca40b0f32c0d2831fdd4c
2014-11-06sw: clean up namespace prefixes in SwXMLBlockImport.cxxMichael Stahl
Change-Id: I64716c9d087d1e9d3e76d14d555768af486e8982
2014-11-06sw: merge SwXMLBlockListContext.cxx into SwXMLBlockImport.cxxMichael Stahl
... so all the import is in one source file not 3 tiny ones. Change-Id: I239316ec54cab28a7af643372af33782f70e7040
2014-11-06sw doc model dump: extend SwFmtFrmSize handlingMiklos Vajna
Change-Id: I8b246e198f3b19e65feffb196afdecb1755a0581
2014-11-06coverity#735645 Division or modulo by zeroCaolán McNamara
Change-Id: I03b8404f90b6a05189591d8e3423f32810057a47
2014-11-06SwFrmDlg ctor: turn sRestype into an OUStringMiklos Vajna
In practice, currently possible values are ASCII, but then this string becomes part of URLs, which are in general no longer ASCII, and are OUStrings. Instead of trying to guess the encoding of the string we get, require callers to create an OUString right away. A follow-up commit could adapt SfxTabDialog ctor, SwFrmPage::SetFrmType() and SwFrmAddPage::SetFrmType() accordingly to avoid the new introduced OUStringToOString() calls. Change-Id: I087ed2bb341f5aca59e15e2ef4102556ca803363
2014-11-06use the new OUString::fromUtf8 methodNoel Grandin
Change-Id: I771004b7ccab3344a67e827e45bc34c22ffa5f77
2014-11-06Bin unused include files, thanks to Andrea GelminiTor Lillqvist
Change-Id: I848505b1d4ff03779b89a08d4aeefd6ea0ff205b
2014-11-05coverity#735652 Division or modulo by zeroCaolán McNamara
and coverity#735651 Division or modulo by zero Change-Id: I412308ef3e736b1e9c72d1dd3a8d80d2dce92d67
2014-11-05markup with event type not checker typeCaolán McNamara
Change-Id: I14c0c5d90b67000cb4fe9e6be647854abfe784da
2014-11-05Add rtl::OUString::fromUtf8()Miklos Vajna
Note that this should be used only at places legitimately assuming that the OString contains valid UTF-8. Change-Id: I9e8ecef9928975fe0737553f5b2a19ff2dd40861
2014-11-05more local variableLuboš Luňák
Change-Id: Ibe67ecdd5b121ad5624bfd111dca33897d6e1991
2014-11-05repeated vector::erase() is a bad idea for performanceLuboš Luňák
Especially given that it seems here it was usually called on every single element. Change-Id: Ifc5497aac5108481595df80d00c6e00c00f17596
2014-11-05operator<< for SwPosition/SwPaM/etc. for use with SAL_DEBUGLuboš Luňák
Change-Id: I99ffa87afa6dbdbd20042a882af428d166546af3
2014-11-05fdo#79761: parse BlockList.xml only onceDaniel Sikeler
Change-Id: I3cfc5b66ee73b0e4d07a84c8255c5a006e4fbb25 Reviewed-on: https://gerrit.libreoffice.org/12210 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2014-11-05fdo#38835 strip out OUString globalsNoel Grandin
they are largely unnecessary these days, since our OUString infrastructure gained optimised handling for static char constants. Change-Id: I07f73484f82d0582252cb4324d4107c998432c37
2014-11-04Resolves: fdo#69049 Format in 'Outline Numbering' not saved anymoreCaolán McNamara
Change-Id: Ibd129d989a32eec2f63413d1ed09962ad3b38c68