summaryrefslogtreecommitdiff
path: root/sw/qa/extras/odfexport
AgeCommit message (Collapse)AuthorFilesLines
2015-06-23tdf#91228: need to check the format's IsLockModified(), not the node'sMichael Stahl2-0/+9
commit 9f01951b858453684f2622541af0eb85d4544fc6 also did the extra Remove/Add for Draw fly objects, and it turns out that that's actually wrong because SwTextFlyCnt::SetAnchor() will set the anchor without locking anything if it's a Draw object. Replace it with a different hack in SetAnchor() that applies only if it calls LockModify(). Thanks to Varun Dhall for creating a reproducer document. Not sure if the LockModify() could be replaced completely, perhaps it's just an optimization to avoid re-creating layout frames for the fly. (cherry picked from commit fae87e03ea3829718ec0381ed3b04ceb52c23720) Conflicts: sw/source/core/txtnode/atrflyin.cxx sw/source/core/txtnode/thints.cxx Added test for redline with as-char frame fixed by commits 4dd2e61 and fae87e0 Reviewed-by: Michael Stahl <mstahl@redhat.com> (cherry picked from commit f36ac1aa3bef5ba218f3dae24f260ce7e4afba95) Change-Id: Ib3236f289c2c4202d48ac378a53ce02130d4ce2c Reviewed-on: https://gerrit.libreoffice.org/16323 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
2015-01-19fdo#84714 ODT export: write <loext:table> inside <draw:custom-shape>Miklos Vajna2-0/+10
(cherry picked from commit e4de5b40eb7220da2d337eb98d7905a98dc12c72) (cherry picked from commit 80eb001e6a861c68f2915d4eebded5e36e1875f6) Change-Id: I543ec24f8825bcc7c35acc106402f4fc6b4b5d79 Reviewed-on: https://gerrit.libreoffice.org/13858 Tested-by: Michael Stahl <mstahl@redhat.com> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2015-01-07fdo#86963 SwXShape: don't ask SwTextBoxHelper for ZOrder of child shapesMiklos Vajna2-0/+8
Regression from commit 01fc08c0b5c57fef8ad3755672f4266d85e849a5 (fdo#85554 SwXShape: fix getting ZOrder property when doc contains TextBoxes, 2014-11-20), the problem was that we returned wrong ZOrder of shapes inside group shapes. In SwXShape::getPropertyValue(), pObj points to the Writer-interfacing outermost group shape in case of shapes contained by group shapes, while GetSvxShape() gives access to the real shape. Given that TextBoxes are only possible at the highest level (and not inside group shapes), just check if the two pointers are the same: when not, then no need to convert anything. With this, child shapes get back their original ZOrder -- before in case the group shape had ZOrder=0, all its child shapes had ZOrder=0 as well. (cherry picked from commit 97952280f0adbe195e6a2e0bab8a21a7e352a721) Conflicts: sw/qa/extras/odfexport/odfexport.cxx Change-Id: I9c4097154130cd04f6ab2f2082abafc1d4333872 Reviewed-on: https://gerrit.libreoffice.org/13562 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-11-16Related fdo#82953: Forget package URL of image after it is loadedZolnai Tamás2-0/+50
It causes problems if we handle those imported images differently which are identified by a package URL, so after the first load remove this URL and handle images on the same way as inserted images. Some related bugs: * #i44367# * #i124946# * #i114361# * fdo#73270 The image in the test document has a special ID which is different from that one which is generated by LO internally so after ODF export the new generated image URL is different from the imported one. Change-Id: I4e7d3490674c5f86bec5c7c6e1c975dcafd7c265
2014-10-04sw textboxes: reimplement ODF import/exportMiklos Vajna1-0/+0
Turns out that for normal TextFrames and rectangular drawinglayer shapes, the engine is written in ODF implicitly. Use the same trick to describe if the shape content should be rendered by SW or editeng. This reverts 9d310ecfce3c2fc481b125e1493a534e2107a68e (sw textboxes: implement ODF import/export, 2014-06-02). Change-Id: Id8afa6368bedcd293e578244abb58e18949bec8d
2014-09-15CppunitTest_sw_odfexport: enable on WindowsMiklos Vajna1-1/+1
Change-Id: Ic0444a08eb4afce7d80ab5a9180d45ff8ec3b3c8
2014-07-10fdo#79358: ODF export: fix index boolean property exportMichael Stahl2-0/+22
Due to inverted conditional, only the default values were exported, not the non-default ones... (regression from 8a81f542a6ca566661305c53899b7e422cbaa432) Change-Id: I0b1fc828230695709db49e1643801842d947403c
2014-06-03ODF loext:text-box import/export testcaseMiklos Vajna2-0/+15
There is a lot more to test here, but for now just test that we can have tables and rounded corners at the same time. Change-Id: Ia9a4877202d1d040209f49a428b83633c58fc7c7
2014-04-17remove executable bitAndras Timar1-0/+0
Change-Id: I91f6e861f6d0dbea1b57ac73857e0c706b27f681
2014-03-27Second batch of adding SAL_OVERRIDE to overriding function declarationsStephan Bergmann1-1/+1
...mostly done with a rewriting Clang plugin, with just some manual tweaking necessary to fix poor macro usage. Change-Id: Ie656f9d653fc716f72ac175925272696d509038f
2014-02-25xmloff: import/export loext:rel-width/height-rel for Writer shapesMiklos Vajna1-2/+8
Change-Id: Ie6e4367a235038479287530bd08b0a89c6bb498b
2014-02-25xmloff: import style:rel-width/height for drawinglayer shapesMiklos Vajna2-0/+8
In case the underlying UNO object supports that, which is the case for Writer. Export was already working before. Change-Id: I4676c8349ebe1959da004d6e1a024a342da45049
2014-02-08ODF export/import: text vertical adjustment attribute of text framesZolnai Tamás2-0/+15
ODF standard handle 'textarea-vertical-align' as a 'graphic-property' which "specifies formatting properties for chart, draw, graphic, and frame elements". So this change fit to the standard. Change-Id: I956f512953380983c2c882e943178335fd4dbfeb
2014-01-30swpagerelsize: add layout testsMiklos Vajna1-0/+6
Change-Id: I0c5b606518ce782ffb5e48a859910c4e9e09c76d
2014-01-30swpagerelsize: implement ODF import/exportMiklos Vajna3-0/+19
Export rel-height-rel / rel-width-rel only in case rel-height / rel-width is non-zero, though. Change-Id: I36120cbd8679ac4fc072d1e7cf4dfc024836b5ac
2014-01-08123792: complete annotations on text ranges featureOliver-Rainer Wittmann1-4/+4
- rely annotations on text ranges on new annotation marks - support arbitrary text ranges for annotations - fix undo/redo regarding annotations an text ranges - support annotations on overlapping text ranges - fix *.docx import for annotations on overlapping text ranges - fix ODF import of annotations on text ranges cherry-picked from branch ooxml-osba (cherry picked from commit ebd2922ebd3cf2d3899fb80780d38f367197aadf) Conflicts: sw/Library_sw.mk sw/inc/IDocumentMarkAccess.hxx sw/inc/SidebarWin.hxx sw/inc/doc.hxx sw/inc/docufld.hxx sw/inc/hintids.hxx sw/inc/ndhints.hxx sw/inc/txatbase.hxx sw/inc/unobookmark.hxx sw/inc/unofield.hxx sw/inc/unoport.hxx sw/source/core/access/accpara.cxx sw/source/core/bastyp/init.cxx sw/source/core/crsr/bookmrk.cxx sw/source/core/crsr/findtxt.cxx sw/source/core/doc/dbgoutsw.cxx sw/source/core/doc/docbm.cxx sw/source/core/doc/doccorr.cxx sw/source/core/doc/docdde.cxx sw/source/core/doc/docedt.cxx sw/source/core/doc/docfld.cxx sw/source/core/doc/doclay.cxx sw/source/core/doc/tblrwcl.cxx sw/source/core/docnode/ndcopy.cxx sw/source/core/docnode/nodes.cxx sw/source/core/docnode/section.cxx sw/source/core/edit/edfld.cxx sw/source/core/fields/docufld.cxx sw/source/core/fields/postithelper.cxx sw/source/core/fields/reffld.cxx sw/source/core/inc/MarkManager.hxx sw/source/core/inc/crossrefbookmark.hxx sw/source/core/text/inftxt.cxx sw/source/core/text/itratr.cxx sw/source/core/text/txtfrm.cxx sw/source/core/txtnode/atrfld.cxx sw/source/core/txtnode/ndtxt.cxx sw/source/core/txtnode/thints.cxx sw/source/core/undo/undel.cxx sw/source/core/undo/undobj.cxx sw/source/core/unocore/unofield.cxx sw/source/core/unocore/unoport.cxx sw/source/core/unocore/unoportenum.cxx sw/source/filter/html/htmlatr.cxx sw/source/filter/html/htmlgrin.cxx sw/source/filter/html/wrthtml.cxx sw/source/filter/writer/writer.cxx sw/source/filter/ww1/fltshell.cxx sw/source/filter/ww8/wrtw8nds.cxx sw/source/filter/ww8/ww8par.cxx sw/source/ui/dialog/uiregionsw.cxx sw/source/ui/dochdl/swdtflvr.cxx sw/source/ui/docvw/PostItMgr.cxx sw/source/ui/docvw/SidebarWin.cxx sw/source/ui/fldui/fldmgr.cxx sw/source/ui/fldui/fldref.cxx sw/source/ui/inc/fldmgr.hxx sw/source/ui/inc/wrtsh.hxx sw/source/ui/shells/textfld.cxx sw/source/ui/uiview/view2.cxx sw/source/ui/utlui/navipi.cxx sw/source/ui/wrtsh/wrtsh2.cxx writerfilter/source/dmapper/DomainMapper_Impl.cxx writerfilter/source/dmapper/DomainMapper_Impl.hxx writerfilter/source/dmapper/PropertyMap.cxx xmloff/inc/txtfldi.hxx xmloff/source/text/txtfldi.cxx xmloff/source/text/txtparae.cxx Change-Id: Ie4cc467dbb837054c73742262ee20f35c151ff3f
2013-11-15CppunitTest_sw_{odfexport,odfimport,ooxmlexport}: consistent macro namingMiklos Vajna1-9/+9
Change-Id: I4dfcdc851fce49de25b3bd21f733f819a3d02eb3
2013-10-31sw/qa: 1 individual unit test per filter (import/export) testPierre-Eric Pelloux-Prayer1-51/+20
The goal is to have clearer failure message by distinguishing failures (only import, import and export, only export). Change-Id: Ic4fc5f7bfd7c9ddb0705597c3fb994e41d04b5ba Reviewed-on: https://gerrit.libreoffice.org/6289 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com> Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
2013-09-10Improve border equal check in filter tests 2.Zolnai Tamás1-20/+20
Change the order of words BORDER and EQUAL in the macro name to become consistent with other macro names. e.g. CPPUNIT_ASSERT_DOUBLES_EQUAL Use a function inside the macro to make it type safe. Add additional message to make clear why the test failed. Change-Id: I9fc7a5813adf2cac36ae831d438cec498232b06c Reviewed-on: https://gerrit.libreoffice.org/5885 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
2013-09-09Use hex color code in character border filter testsZolnai Tamás1-6/+6
Change-Id: I19bd1cbedd42101186fd4afbcd7af9afb630f857
2013-09-08Fix expected and actual order in odf export testZolnai Tamás1-13/+13
Change-Id: Ib8168112e297571cc99b39fbf365d888e2247da5
2013-09-08Improve border equal check in filter testsZolnai Tamás1-80/+40
With macro the error message will point to the right line. Check padding distinct. Change-Id: Id09fbf65350a7a3708923eb07d673068c2943b50
2013-08-27Reduce copy&paste by adding SwModelTestBase::getShape()Miklos Vajna1-3/+1
Change-Id: I3b73405c546427bb5676db30e297af36c18043e6
2013-08-24ODF filter: handle draw:shadow-opacity for Writer framesMiklos Vajna2-0/+11
Change-Id: I3ad39e5de5b6999d6c2182c1ec622ae7f873cafe
2013-08-23Fix types in new odf tests.Zolnai Tamás1-9/+9
Change-Id: I0339dd941c81d12688bd531178ce9f1d6b779375
2013-08-23ODF export/import of fine dashed border styleZolnai Tamás2-1/+1
Change-Id: Ia81385dd9952e90cd5ebb3d1bba38aff6f84d079
2013-08-23CharBrd 7: Border shadowZolnai Tamás2-0/+22
1, New character attribute - Add the three shadow members to font (width, color, location) 2, Painting - Extract the shadow painting to a local function and use that for character shadow (paintfrm.cxx) - Reduce the painting rectangle of background (shadow doesn't inherites the background of content) 3, Border merge - Use text portion join members to skip shadow when neccessary. 4, Vertical text - Get shadow space dependant from oritentation and border merge. 5, UNO API and ODF filter Paragraph: ParaShadowFormat -> Character: CharShadowFormat Change-Id: Ief4669990d238016c3ffc18a2609a3df7d9dddbf
2013-08-18Add test for drop caps odf filterZolnai Tamás2-0/+11
Change-Id: I52735c222e14e725fc01caa156cb8ea9671a36cc
2013-08-18CharBrd 8.2: Tests for UNO API and ODF filterZolnai Tamás2-0/+176
Use just those API tests which still alive. Export filter test use import so no need for distinct import tests. Change-Id: Idddc2ece10e20027551538f4e8c224edffa9bfe8
2013-06-16cppcheck: fix duplicateExpressionJulien Nabet1-1/+1
(It seemed logical to me, hope I'm not wrong) Change-Id: I2c1ffbe69b90655b260a7ecb41ab089b60b27b85 Reviewed-on: https://gerrit.libreoffice.org/4279 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
2013-04-30fdo#62336 - unit test for conversion failure.Michael Meeks1-0/+1
Turns out this depends on not doing layout, and so is a real corner-case. Change-Id: If9d2db6b1a0df94fc809fb353f2dbf2cf9ac1c9a
2013-04-26SwModelTestBase: add save(), next to load() and reload()Miklos Vajna1-7/+1
Change-Id: I15405dd6be64da689257aed50ba847f3741df3a1
2013-04-26fdo#58949 testcaseMiklos Vajna2-0/+25
Change-Id: I584efc83ef1643a683757ac369cd140f52610293
2013-04-22Move to MPLv2 license headers, with ESC decision and author's permission.Michael Meeks1-23/+4
2013-03-20fdo#60769 implement odf export of multi-paragraph comment rangesMiklos Vajna2-0/+28
Change-Id: Ifb850438586eb6589fde79d10ed9eef727368f42
2013-01-30sw: add textframe gradient ODF roundtrip testcaseMiklos Vajna2-0/+25
Change-Id: I346de7efd4e91f93e3f07ece1c6fe71d1ca53b8e
2012-12-21sw: add csv output for extra filter testsMiklos Vajna1-12/+4
Like the minimal filter tests, these tests are invoked from a single cppunit method since commit 0a30cb22a141c26b4eab43a478d32df0769596ec, so some info about exactly what file failed is necessary. If we are at it, also print the (re)loading time as well.
2012-11-18sw: move swmodeltestbase.hxx to qa/extras/inc/Miklos Vajna1-2/+1
If we already have such an include dir, let's have all headers there. Change-Id: I2100b5308e7fdad9d98cfde76434ff485aca20c7
2012-10-20sw: run export tests twiceMiklos Vajna1-17/+26
Export tests are in fact import-export-import tests. Given that we want to test the export filter here, it's handy to run the tests twice, first before the export (to detect if already the import filter fails) and also after the second import, to do the real test. So this should make it easier to detect when you have an export failure, but in fact the bug is in the import side. Change-Id: I26e3445f079a7fbd4e037218f7094a84e730b746 Requested-by: Pierre-Eric Pelloux-Prayer <pierre-eric@lanedo.com> Agreed-by: Lubos Lunak <l.lunak@suse.cz>
2012-10-09sw: add odf and ww8 regression tests for first page header/footerMiklos Vajna2-0/+22
Change-Id: Ic002f3cba79b6758475cf9d3153ae3063eb640a3
2012-09-26sw: remove unneeded using statements in qa/extrasMiklos Vajna1-2/+0
Change-Id: I23b77b9c8d245d84a045bdedda1584419f4fddda
2012-07-20fdo#38244 comment range odf import/export testcaseMiklos Vajna2-0/+95
Change-Id: I8cbaa30aa222404f55f5ff49474cf93e8b1bdac2