summaryrefslogtreecommitdiff
path: root/writerfilter
AgeCommit message (Collapse)Author
2014-10-30Fixed typos. No automatic tools (sed, and so on).Andrea Gelmini
Change-Id: Ia43976d84eede6f699381bc4f3daf89b95e4cb4f Reviewed-on: https://gerrit.libreoffice.org/12150 Reviewed-by: Bryan Quigley <gquigs@gmail.com> Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2014-10-30fdo#79602: sw: add new compatibiltiy flag PropLineSpacingShrinksFirstLineMichael Stahl
This is enabled by default, to get the new formatting where the first line of a paragraph is shrunk if a proportional line spacing < 100% is applied; existing OOo documents get the previous (before LO 3.3) formatting. Since the formatting in LO releases is broken anyway, it does not matter much which way documents written by old LO get formatted. Change-Id: I0952f568a933c137bd03070759989cac3517d8b9
2014-10-29coverity#1202781 Division or modulo by zeroCaolán McNamara
Change-Id: I2908c57badd079c8f19c679f40ed815ce2cba374
2014-10-28coverity#1000600 Division or modulo by zeroCaolán McNamara
Change-Id: I38fb8a7072eb7905f5dccc8697b3176d8b34c6c2
2014-10-26Avoid boost::optional<bool>Miklos Vajna
Change-Id: Idaacaf80098e59df47183741402c8664ba5ea631
2014-10-26fdo#82076 RTF import: handle footnote in table cellMiklos Vajna
Change-Id: I69def7936c320e93db5d4504922d52346caaf9cf
2014-10-25loplugin:unreffunMiklos Vajna
Change-Id: I7b707ddd526c927ed99e93797d1bd320860d5397
2014-10-25fdo#82859 RTF import: fillColor is unsignedMiklos Vajna
Otherwise ARGB 0xFFFFFFFF would turn into black. Change-Id: I690f34d888ca9a013e8ce1af2c7ef8ed88ee28b0
2014-10-25fdo#82859 RTF import: don't try to set CustomShapeGeometry on a TextFrameMiklos Vajna
Change-Id: I687fa609559f0484fe6bb804265243de154c3760
2014-10-25only the now removed OOXML tokenizer called getType()Miklos Vajna
Change-Id: Id9786ed75bf9d9b637312655af33d790caf93b13
2014-10-25writerfilter: remove unused dumpXml() methodsMiklos Vajna
Unused since 51d1545e0ce8b30eea710501b84853288dd2563b (writerfilter: Kill debug_logger., 2014-06-11). Change-Id: I01743a9f5c603da06cfd422d29d3258a17d4dd40
2014-10-25writerfilter: nobody generates FSPA references anymore, only doctok didMiklos Vajna
Change-Id: I3dbfb727c40a71eb70a26fd53ad651477a8a5220
2014-10-25writerfilter: nobody generates PICF references anymore, only doctok didMiklos Vajna
Change-Id: I65576f09cbc39f98f3d27739e06ec9520d5032c5
2014-10-25fdo#85179 RTF filter: import image borderMiklos Vajna
Also adjust CppunitTest_sw_htmlexport that implicitly tested that there is no color around the image. Change-Id: I8e14dfa7e7be80c4f8c492999071decae6a492e8
2014-10-25writerfilter: avoid copy&pasteMiklos Vajna
Change-Id: I72057875cf2803008f63a85fee2be477598d8aff
2014-10-23Fraction: Revert "fdo#81356: convert Fraction to boost::rational<long> - wip"Jan Holesovsky
This reverts commit 47a2d7642d249d70b5da0c330a73f3a0032e4bba. Conflicts: cui/source/tabpages/transfrm.cxx svx/source/svdraw/svdedtv1.cxx svx/source/svdraw/svdibrow.cxx sw/source/filter/ww1/w1filter.cxx tools/source/generic/rational.cxx Change-Id: I4849916f5f277a4afef0e279b0135c76b36b9d15
2014-10-23Fraction: Revert "error C2677: binary '*' : no global operator found"Jan Holesovsky
This reverts commit 9abc8067365e394bdc7c4fe49f642207a86d13f5.
2014-10-23Fraction: Revert "fdo#84854 it seems long is not enough on 32 bit"Jan Holesovsky
This reverts commit 582ef22d3e8e30ffd58f092d37ffda30bd07bd9e. Conflicts: svx/source/svdraw/svdedtv1.cxx svx/source/svdraw/svdibrow.cxx sw/source/filter/ww1/w1filter.cxx Change-Id: I80abc7abdeddc267eaabc9f8ab49611bb3f8ae83
2014-10-23WaE: unused parametersTor Lillqvist
Change-Id: I689754378773fc6926e4cebe3ec14b5056fb8986
2014-10-23loplugin: cstylecastNoel Grandin
Change-Id: Iad39bce8e7562821bc8fbf8156ea56aedc19c7d6
2014-10-22i#84172 RTF import: handle nested groups inside redlinesMiklos Vajna
The problem was that in case we had {\revised foo {bar}}, then we only started a redline before "foo", but we ended it twice: during handling of both "}". Make sure that the end of the redline is only handled by the second one. Change-Id: I41ab8b486e8615d3479fa0fadd6016476859b4b2
2014-10-21WaE: unused parametersTor Lillqvist
Change-Id: I080677b1add4f82315ed063af2478c9e41d267ac
2014-10-20DOCX import: fix <w:pageBreakBefore> wrt. inherited stylesMiklos Vajna
We used to ignore this element with a "false" logical attribute, but that causes a problem when an inherited style wants to explicitly disable this element from a parent style. Change-Id: I2fc4c5b2002987d44679d863ea3f19114b9ab7a4
2014-10-19fdo#83464 RTF import: \plain should reset \rtlch and \hich as wellMiklos Vajna
Regression from 36246aa9fb57c9fe4e546c91a8274d8828b1424e (RTF import: fix handling of \loch \hich \dbch \ltrch \rtlch, 2014-06-03), now that \f no longer means the ascii font name, \plain should reset a few more parser state members. Change-Id: Ia6b0bdf25563dd5300e108b46731751f0886f67d
2014-10-18i#74153 RTF import: fix track changes vs superscript char propMiklos Vajna
Since 9dbf817fe5c5253fba0831aefa17575ae0ba3af1 (handle scope of w:pPrChange and w:rPrChange properly (bnc#821804), 2014-10-01), this caused an assertion failure -> crash. Change-Id: I680edf58854d0c9be6e77c44c1e6beb1e0442a49
2014-10-17UBSan: Don't force sal_Int32/float values into sal_uInt32Stephan Bergmann
...overload of TagLogger::attribute. Not withstanding that function looks just silly anyway. Change-Id: I6cc3c5004884e564aac1397cab6eb6fae7a06f7e
2014-10-17Work around Clang 3.2 -Wnull-conversion bugStephan Bergmann
...by running all of writerfilter through loplugin:nullptr rewriter Change-Id: Ie6ec5dd989dc2035ccd10941bc38e557e128be0f
2014-10-17DOCX import: parse <w:spacing>'s w:before/afterLines attributeMiklos Vajna
Change-Id: I63b3afda5e8915b562de51aa31e420c135f919ba
2014-10-17writerfilter: Fix various Clang warningsStephan Bergmann
Change-Id: I733bcf8e02e659ef18ee9c2be4ad4e9f107fe7c6
2014-10-17error: use of undeclared identifier 'sResult'Miklos Vajna
Change-Id: I80f71b16896cd028c9b5d60b243fc5cd825d3c23
2014-10-17DEBUG_DOMAINMAPPER -> DEBUG_WRITERFILTERMiklos Vajna
As it's used in the tokenizers as well. Change-Id: I7a78cad0414c724f33b50315a45a5ff2c941f4db
2014-10-17fix incremental buildMiklos Vajna
Change-Id: I28dd6c72c665abd95be6d14dc629296850e03e1d
2014-10-16writerfilter: make dmapper logging a runtime decision, not a buildtime oneMiklos Vajna
It's still only enabled in debug builds, but it now requires an environment variable, not rebuilding with dbglevel=2. Change-Id: I970c7bfe0b3f547429ef37f37406a095a60c34ff
2014-10-16fdo#84854 it seems long is not enough on 32 bitDavid Tardon
Fraction used BigInt internally for computations, rational does nothing like that. Change-Id: I3e9b25074f979bc291208f7c6362c3c40eb77ff5
2014-10-16fdo#77716 DOCX import: fix handling of user-defined Standard styleMiklos Vajna
Change-Id: I2cbd9cc0848bfb302bfa0c463a810e7f8231e47b
2014-10-16writerfilter: check for DEBUG_DOMAINMAPPER, not OSL_DEBUG_LEVEL explicitlyMiklos Vajna
Previously code only built if DEBUG_DOMAINMAPPER was exactly defined with OSL_DEBUG_LEVEL was > 1, as they these conditions were used for the same purpose. Change all this dmapper XML dumping code to consistently use DEBUG_DOMAINMAPPER, so later it'll be possible to change when it's defined without breaking the build. Change-Id: I32442cf098162c7d7c9eb7c454094685ab654b74
2014-10-16writerfilter: fix include guardMiklos Vajna
Change-Id: I8c5c8a4e8fbb6e6a2e955c4f544786a2256e6342
2014-10-16DEBUG_WRAP_POLYGON_HANDLER would be never definedMiklos Vajna
Change-Id: I24e1379d136122906deddd298e456728b3be0956
2014-10-15writerfilter: call to SAL_WARN() is not expensiveMiklos Vajna
So guards like '#if OSL_DEBUG_LEVEL > 0' around it can be dropped in most cases. Also, dumping the hex value of token IDs no longer makes sense, now that doctok is gone. Change-Id: I2c0d466e4bdde63d271a83aa4e7eebb52294e363
2014-10-15More -Werror,-Wunused-private-fieldStephan Bergmann
...detected with a modified trunk Clang with > Index: lib/Sema/SemaDeclCXX.cpp > =================================================================== > --- lib/Sema/SemaDeclCXX.cpp (revision 219190) > +++ lib/Sema/SemaDeclCXX.cpp (working copy) > @@ -1917,9 +1917,10 @@ > const Type *T = FD.getType()->getBaseElementTypeUnsafe(); > // FIXME: Destruction of ObjC lifetime types has side-effects. > if (const CXXRecordDecl *RD = T->getAsCXXRecordDecl()) > - return !RD->isCompleteDefinition() || > - !RD->hasTrivialDefaultConstructor() || > - !RD->hasTrivialDestructor(); > + return !RD->hasAttr<WarnUnusedAttr>() && > + (!RD->isCompleteDefinition() || > + !RD->hasTrivialDefaultConstructor() || > + !RD->hasTrivialDestructor()); > return false; > } > > @@ -3517,9 +3518,11 @@ > bool addFieldInitializer(CXXCtorInitializer *Init) { > AllToInit.push_back(Init); > > +#if 0 > // Check whether this initializer makes the field "used". > if (Init->getInit()->HasSideEffects(S.Context)) > S.UnusedPrivateFields.remove(Init->getAnyMember()); > +#endif > > return false; > } to warn about members of SAL_WARN_UNUSED-annotated class types, and warn about initializations with side effects (cf. <http://lists.cs.uiuc.edu/pipermail/cfe-dev/2014-October/039602.html> "-Wunused-private-field distracted by side effects"). Change-Id: I3f3181c4eb8180ca28e1fa3dffc9dbe1002c6628
2014-10-15fdo#82860 RTF import: fix handling of SHAPE fieldsMiklos Vajna
No need to use fieldmarks for these. Change-Id: I8d2c797f2b00be88e445dab0dd69cb1a9556c02c
2014-10-14fdo#82071 RTF import: get rid of unexpected underlining in TOC fieldMiklos Vajna
Regression from commit 9679e9c23216decb5f9f25f85b04cb3f25211111 (fdo#69649 Fix for pre-rendered Table Of Contents, 2013-12-30), now that we handle hand-edited TOC, it's necessary to properly track correctly if a property came from a style or as a direct formatting. Fix RTFDocumentImpl::getProperties() to detect direct formatting that cames from a char style and would result in attribute tokens. Change-Id: Iab5a14770de43249961c280a5dc698200abc8f49
2014-10-13Use comphelper::SequenceAsVectorMiklos Vajna
Change-Id: I0af333551bdd32400b795d37de0d6240e68dd6b6
2014-10-13create a macro library for implementing bit-flags typesNoel Grandin
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>, changed from a macro- to a template-based solution. (Unfortunately MSVC 2012 does not support explicit conversion operators. Worked around that with explicit #ifs rather than some HAVE_EXPLICIT_CONVERSION_OPERATORS and SAL_EXPLICIT_CONVERSION_OPERATOR ainticipating we hopefully soon move to a baseline that requires unconditional support for them.) Change-Id: I4a89643b218d247e8e4a861faba458ec6dfe1396
2014-10-13Avoid manual realloc, use comphelper::SequenceAsVector insteadMiklos Vajna
Change-Id: I26c6bcf7361bbb787fcb4133d05b0a668fd72d01
2014-10-12Remove dead codeMiklos Vajna
Only doctok produced these tokens, so no need to handle them anymore. Change-Id: Ied7df2515ac86562dd5ce782a1f01158fe3f684e
2014-10-12Clean up now unnecessary boost::bind() magic in RTFSdrImport::initShape()Miklos Vajna
Change-Id: Ie373098959f8b3e04fe955a08031a4221faab3cc
2014-10-12RTF filter: fix \acc* handlingMiklos Vajna
The exporter didn't write circle and underdot at all. Change-Id: Ia8f45f2b03fb14e9a0027ec24ee7f36adc8c018d
2014-10-12DOCX filter: fix <w:em> handlingMiklos Vajna
The real news here is that "comma" and "dot" was swapped on export, the rest is just a fixup of recent breakage. Change-Id: I54045f5837652dc38a30361e21ced25aeaf58257
2014-10-12Typo: compatability->compatibilityJulien Nabet
Change-Id: If0b98a30452a9d1fcc340173deb6856755926471