summaryrefslogtreecommitdiff
path: root/sd/qa/unit/data
AgeCommit message (Collapse)AuthorFilesLines
2016-08-18screenshots: add dialog test cases for svxArmin Le Grand1-9/+15
All *.ui files create a screenshot, but not all look useful Change-Id: I5aeec438b90488ea19cdb1251fee7dcf23e1c2cb
2016-08-18screenshots: add dialog test cases for writerArmin Le Grand1-1/+4
Writer has currently no known dialogs that get created with an opened writer document. There are some ui files that do not work with fallback (7), but most work (167). Not all look good, though. Change-Id: I92a6a5077e3a8c93148e162455093399ba1f99ed
2016-08-18screenshots: fix fallback cases for sd and scArmin Le Grand1-9/+10
Change-Id: I27dab5552e3924df30c8b09c46994b2d645bcde9
2016-08-18screenshots: fallback screenshot to ui filesArmin Le Grand1-0/+66
Besides the already existing methods to dump adapted dialogs and create and dump fallback dialogs I added a possibility to process a given input file which may contain a list of UXMLDescription files (*.ui files), one per line. This file is processed (empty lines and comment lines using '#' allowed) and for each descriptor first tries to find a known, adapted dialog. If found it gets used, else fallback is tried. Added ui-definition files for sd and sc which contain all ui-files from these dialogs. Adapted the test base class to hold the needed functionality. Change-Id: I1d4c64af8cd5d9c89a53b193951c3e49669f5852
2016-08-11Convert handles of built-in shapes in Impress when exporting to PPTX.Mark Hung1-0/+0
For those shapes exported as OOXML preset shapes, their AdjustmentValues property was exported as the list of adjustment values ( avLst ) in the exported PPTX file. This works for shapes imported from PPTX, whose AdjustmentValues is exactly the same as avLst of the original PPTX file. For built-in shapes in Impress, avLst and AdjustmentValues would not be the same because the path and the equation created by LibreOffice and OOXML are not the same. This patch convert position of handles to adjustment values according to the shape type case by case. It also adds default values if the built-in shape in Impress has fewer handles then the exported preset shape because Powerpoint seems to be very strict about the number of values in avLst, and deemed the file as corrupted if any of defined adjustment values is missing. Round-rectangular-callouts, rectangular-callout, and round-callouts are added to the blacklist so that they are exported as preset shapes. Change-Id: Icd1284790607e927b6a9a614ac463a96cadedd81 Reviewed-on: https://gerrit.libreoffice.org/26479 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mark Hung <marklh9@gmail.com>
2016-07-25sd: OOoXML import: fix loss of animationsMichael Stahl1-0/+0
There are 2 different animation formats, legacy one used in OOoXML format, based on presentation:animations element, and SMIL based one used in ODF format, based on a node hierarchy with <anim:par presentation:node-type="timing-root"> at the top. The problem is that when the legacy animations are imported, they are not immediately set on the draw-page in the same way as the new animations are imported. "soffice --convert-to odp ooo28334-1.sxi" loses all of the animations, whereas loading the file in the UI and storing it all animations are converted, and if you use API load/store methods some are converted and some not depending on timing. The problem is that there is a necessary conversion step MainSequence::implRebuild() that needs to happen after all the EffectMigration calls for a particular SdPage are finished, which is only triggered by a timer MainSequence::onTimerHdl(). Fix it by forcing a call to implRebuild() from DrawDocShell::Load(). Note: SdDrawDocument::NewOrLoadCompleted() is a horribly misleading function name as it is actually called *before* loading the document. Change-Id: I9881cb9bf2ae6ccc5fcf06602343f2d0e0704699
2016-06-30tdf#100179 correct cell merging in pptx.Mark Hung1-0/+0
Change-Id: I7a5bc6fb33c64d1ff398986eff5b960fe037df4d Reviewed-on: https://gerrit.libreoffice.org/25791 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mark Hung <marklh9@gmail.com>
2016-06-29Reinstate: tdf#99729: fix text alignment (no autofit & no full width)Caolán McNamara2-0/+0
with extra disposes to shutdown the test thingies in the right order This reverts commit a4780b3c8b45261e59ed3cbb34c4463d58ad8079. Change-Id: I13282d6bc54a0dceb3ed91a04cd438a9011154fe Reviewed-on: https://gerrit.libreoffice.org/26756 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2016-06-29Revert "tdf#99729: fix text alignment (no autofit & no full width)"Miklos Vajna2-0/+0
This reverts commit 0cb200d000fad8ba31c7400e08cd031823f27308. Even if it was verified by Jenkins, it broke CppunitTest_sd_import_tests on a number of tinderboxes. Need to at least find out how to reliably trigger the crash and fix it before it goes in again. Change-Id: I7ed52cae559648ec101b7a343046a7d74a7c48d3
2016-06-28tdf#99729: fix text alignment (no autofit & no full width)Mike Kaganski2-0/+0
If TextBox contained text that is larger than the box, and autofit was off, and autosize was off, and full width was off, then text always aligned to box's left top corner, regardless of text anchor setting. Related problem (i103454) was fixed in 2009 by Armin Le Grand, but only for full width text. This patch extends the scope of that fix to correctly process other cases. The fix introduces a new compatibility flag: AnchoredTextOverflowLegacy If it is true, then old behaviour is retained. It is always false for new documents and imported documents. When opening existing ODF documents, it's true by default, unless it is explicitly set in settings.xml. Unfortunately, I couldn't find a way to access the document model from any of SfxBaseModel::load() or SfxObjectShell::DoLoad, where it could enable setting the compatibility flag universally when loading own format. Instead, I had to do it individually in each of SfxObjectShell::Load() implementations. Unit test is included. Change-Id: Ifad79d546739daafff59fb6c7fb0dce51babc53d Reviewed-on: https://gerrit.libreoffice.org/26737 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2016-06-28ODP export: add embedded pdf supportMiklos Vajna1-0/+0
This is basically the draw shape equivalent of SwGrfNode::GetReplacementGrfObj(), that already had explicit code for PDF purposes. Change-Id: I00a619082f59a3e377d45c3a59615cadae295586 Reviewed-on: https://gerrit.libreoffice.org/26724 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-06-10Slideshow: Add 'Oval' Shape Transition variantMayank Gupta1-0/+0
Committer's note: There is no Oval or Ellipse transition in MSO formats, so fallback to circle on export to those. Change-Id: Ibc3d617d3bb94bdd0702bb4d60ce5fbe2eea8e24 Reviewed-on: https://gerrit.libreoffice.org/23661 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org>
2016-06-09Revert "Slideshow: Add 'Oval' Shape Transition variant"jan iversen1-0/+0
The patch caused problems with the export filter tests, to check that you need to add --with-export-validation to your autopen.input see https://cgit.freedesktop.org/libreoffice/contrib/dev-tools/tree/export-validation for more info on how to set it up This reverts commit 248c5ea771255b54e64394458a321ccf829bbd02. Change-Id: Ib3b8fa7bf80630feeca1f24dfb1ceb5a945d7162 Reviewed-on: https://gerrit.libreoffice.org/26114 Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org>
2016-06-09Slideshow: Add 'Oval' Shape Transition variantMayank Gupta1-0/+0
Change-Id: Ibc3d617d3bb94bdd0702bb4d60ce5fbe2eea8e24 Reviewed-on: https://gerrit.libreoffice.org/23661 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org>
2016-05-31tdf#93883 don't add space to empty paragraph when bullet is turned off.Mark Hung1-0/+0
Change-Id: Ia1bad61cb5585dae0501e8cd657fc84bfea60ab2 Reviewed-on: https://gerrit.libreoffice.org/25679 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
2016-05-19tdf#49561: PPT import: Avoid to override formatting from StyleTextPropAtomMatus Uzak1-0/+0
Change-Id: Id874cb369b08eb7f8226413c6541fe6cd18eceaa Reviewed-on: https://gerrit.libreoffice.org/24662 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2016-05-05tdf#93124: Fix incorrect text fit in imported PPT - take twoMike Kaganski1-0/+0
This patch just fixes incorrect decision when the block alignment must be applied. Also, unit test is included. Change-Id: I458184778c5e9e115d1a4eac749ecb6991b227a8 Reviewed-on: https://gerrit.libreoffice.org/24648 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2016-04-29tdf#99030: PPTX import: Fixed lost slide background colorMatus Uzak1-0/+0
Regression from commit f3d1ac7 Change-Id: I5cb9fe1bb6c753c34b49e72194a9fbe4c10c1654 Reviewed-on: https://gerrit.libreoffice.org/23930 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-04-29tdf#90736: PPTX import: Improved table border line style supportMatus Uzak1-0/+0
Map preset line dash values from ooxml to the smaller set of LO's predefined table border line styles. Map custom dashing scheme to a simple dashed line style. Change-Id: Ia81d94cb7e20b05f1c2cc0c20c8ad398c5613d6c Reviewed-on: https://gerrit.libreoffice.org/24048 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-04-19tdf#99396 SvxTableController::SetVertical: implement undo supportMiklos Vajna1-0/+0
All the table and cell objects know how to undo this change, what was missing is the begin/end undo calls and the broadcast of the cell format change. Change-Id: I3dfd203faf5c579da2937fedab5647129a8e903a Reviewed-on: https://gerrit.libreoffice.org/24247 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-04-12tdf#99224 PPTX export: implement support for images with textMiklos Vajna1-0/+0
In case an image had text, then ShapeExport::WriteGraphicObjectShapePart() wanted to write "only the text", but PowerPointShapeExport::WriteTextShape() had no idea how to write an image, so at the end nothing was exported. Change-Id: I6c1ad0b41d4c5dc260b952322fb8a59e7f175603
2016-03-29tdf#95932: PPTX import: Incorrect inheritance of shape styleMatus Uzak1-0/+0
Inheritance Order: 1. Reference Shape's properties, 2. Shape style, 3. Shape properties. You MUST NOT inherit reference shape's style, because it's already part of inherited reference shape's properties. That would overwrite shape properties applied at point 3, at slide layout/master level. Change-Id: Id1ab550295988b0087a67c6819dfe32f84825e4e Reviewed-on: https://gerrit.libreoffice.org/23182 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-03-23tdf#93868: PPTX import: Incorrect inheritance of shape fill propertiesMatus Uzak1-0/+0
DrawingML: The useBgFill attribute specifies that the shape fill should be set to that of the slide background. Change-Id: I8b568e730f00326d51e7b604579f4ff990b26f8a Reviewed-on: https://gerrit.libreoffice.org/23039 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-03-20Revert "tdf#93124: Fix incorrect text fit in imported PPT"Thorsten Behrens1-0/+0
Change broke autofit feature, see bugreport. This reverts commit 5ca1f04976930c6fd656ebf89d667c80e2466897.
2016-03-19tdf#93124: Fix incorrect text fit in imported PPTMike Kaganski1-0/+0
To make text adjustment to full width, the alignment optimizations had to be removed, and bAutoFit was removed, too. Allso, to fix tdf#41245 again, the SDRTEXTFIT_AUTOFIT that is set in SdStyleSheetPool::CreateLayoutStyleSheets had to be overridden. I touch the following commits: http://cgit.freedesktop.org/libreoffice/core/commit/?id=d2000efb31f864e912c6cf52760eea0e602b6893 http://cgit.freedesktop.org/libreoffice/core/commit/?id=3550256daa5451c1d51d220d5489c1b20150c374 http://cgit.freedesktop.org/libreoffice/core/commit/?id=812aff65ad0661fed9687a429c763dc8f2144a0c Change-Id: I7f7934e2982baf0240c740e09fcb9bd348079064 Reviewed-on: https://gerrit.libreoffice.org/18895 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-03-10tdf#89927: PPTX import: Incorrect inheritance of text run fill propertiesMatus Uzak1-0/+0
Make use of FillProperties in TextCharacterProperties. DrawingML: Fill related elements in Text Run Properties are in sync with Table Cell Properties and all of Line Properties. Change-Id: I7c513ecfc5f94cf49e98a657384b5c0f5dddc1c7 Reviewed-on: https://gerrit.libreoffice.org/22979 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-03-04tdf#62255,tdf#92058: PPTX import: Incorrect inheritance of default table styleMatus Uzak1-0/+0
The default table style defined in tableStyles.xml file can be used when a table is initially inserted into a document. It must not be applied by default to any of the tables not referencing a table style explicitly from the tableStyleId element. Change-Id: I025cdfba352c87a32f9a1e297fbc8b9fc2c8c0a4 Reviewed-on: https://gerrit.libreoffice.org/22619 Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de> Tested-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-02-29crashtesting: sync PageProperties::SetStyleSheet with GetStyleSheetCaolán McNamara1-0/+0
PageProperties::GetStyleSheet returns 0 so PageProperties::SetStyleSheet should do nothing Change-Id: If627ba3e31b14ff5178f45125f0ce6e4dbf93ec0
2016-02-27xmloff: tdf#97808: allow empty draw:marker-start/marker-end/stroke-dashMichael Stahl1-0/+30
Apparently these are allowed to be empty, which means "nothing". (regression from db1d278dcc308c73eb5edebc20481c96e7f479d8) Change-Id: I13f7998e0986b26c34929afd40b1b4f0fc9efdff
2016-02-08Export and import of additional fields in ImpressRosemary Sebastian5-0/+0
These include - Author - Page Count - Page Name Export and import of slide number was already implemented. A test for the same has been added along with the tests for the newly implemented field exports. In sdmodeltestbase.hxx a new method getTextFieldFromPage has been added to reduce copy-paste code Change-Id: Icf54b91a7db4b3cccd9d0666a2706e3cc2a89d9a Reviewed-on: https://gerrit.libreoffice.org/22065 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-02-05crashtesting: old files using StartWithNavigator fail to loadCaolán McNamara1-0/+0
regression from... commit 2503a1e99df463aef1bf87c94b7b4a8ee3554efe Date: Wed Jan 27 12:19:28 2016 -0500 tdf#96414 Remove showing navigator during slideshow This isn't very user-friendly and the presenter console does a much better job of this. Change-Id: I10bec1bcd2305524446a20a34494c265330e4c10
2016-02-03add EDB-39395-1 test-caseCaolán McNamara1-0/+0
Change-Id: I3e611a3a647245d40ba808fdef7b64b877285fdc
2016-02-03add EDB-39397-1 test-caseCaolán McNamara1-0/+0
Change-Id: I08b8d0247625745665aa9f048bf3fae028c7c36f
2016-02-02Export and import of file name fieldRosemary Sebastian1-0/+0
Change-Id: Ic2c8ce0ff2a54079ef81f6ce2770497a9d22c7b6 Reviewed-on: https://gerrit.libreoffice.org/21902 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-01-27Format the datetime fields properly on importRosemary Sebastian2-0/+0
Make sure that, after export, the datetime fields in impress are imported with the correct number format. Change-Id: I5565fef69b3a62e7dd59ea0d39cde151fb0af976 Reviewed-on: https://gerrit.libreoffice.org/21610 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
2016-01-21starmath: fix OOXML export of non-BMP UnicodeMichael Stahl1-0/+0
Change-Id: Iafaeb9ea2e96ee6d8cc96174731ba3845c230b5e
2016-01-15ugh, forgot to git add the test documentMichael Stahl1-0/+0
Change-Id: Ia10730e07de3bd86f54c7fc0ba5ae55f350ce149
2016-01-05tdf#96708: don't modify document while copying to clipboardMike Kaganski1-0/+0
I.e., don't try to create auto-layout for clipboard pages which don't contain one; don't resize objects to text. Also, don't invalidate items that are equal to defaults, because explicitly set items are not the same as absent items: pasting an object without an item makes the property to inherit new target's default, while when the item is present, the default doesn't apply. Also, don't consider selected state of the page while stringifying - this makes selected page string to differ from not-selected clipboard page. Change-Id: I172e03e1a8c428e5fcae3a116cc9ad8de79f1a87 Reviewed-on: https://gerrit.libreoffice.org/20871 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Andras Timar <andras.timar@collabora.com>
2015-12-22tdf#96051: FILESAVE: Roundtrip any PPTX file with Shapes creates invalid OOXMLZolnai Tamás1-0/+0
Revert "bnc#584721: Import subtitle block to master slides" This reverts commit b3d50feaa87b670baf68288974005ac26ad31736. It seems the imported subtitle block makes export corrupt the output. Better to have a valid output. Change-Id: I1a3d4f03e4fa0c4431a5394495682a1b9d7677bc
2015-12-14tdf#96206: Avoid scaling objects while copying to clipboardMike Kaganski1-0/+0
... to prevent duplicating masters on slide copy-paste. Also fixed a 10-year copy-paste error (pRefPage wasn't replaced with pNPage). Fixed argument evaluation order issue (aStream.GetEndOfData() depends on Flush() but doesn't call it, so will return incorrect result if called before aStream.GetBuffer()). Replaced compare of hashes with results of stringify(), because it removes useless overhead (hashes are calculated from stringify() anyway, and are not cached anywhere). Removed Flush() called from SvMemoryStream::GetBuffer(), because it calls GetData(), which calls Flush() itself. Thanks to Andras Timar for unit test framework. Change-Id: Ia46d4e9a017fc628d424949a9d229045a249a4ca Reviewed-on: https://gerrit.libreoffice.org/20367 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2015-11-21tdf#92527 unit testAndras Timar1-0/+2
Change-Id: I05eb8e99d919eea267df174e948cec29bdf04e75 Reviewed-on: https://gerrit.libreoffice.org/20100 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Andras Timar <andras.timar@collabora.com>
2015-11-18pptx: import/export of honeycomb slide transitionTomaž Vajngerl1-0/+0
Change-Id: I3edb77d5b046691e64d600d61dcd44e892c31301
2015-11-13slideshow: add "glitter" slide transitionTomaž Vajngerl1-0/+0
Change-Id: Ie89b64c4399cd0092eee579660c9fe85f8ca8e73
2015-11-09pptx: import "Vortex" and "Ripple" transition + testTomaž Vajngerl1-0/+0
Change-Id: I29d71e9c07c4964275c13772cdb6042624550acb
2015-11-08pptx: export/import newsflash and comb slide transitions + testTomaž Vajngerl1-0/+0
Change-Id: I8ec2e1bc6d6f46f741252085f68edc6c284124b6
2015-11-05sd: add support for svg export unit testsMarco Cecchetti1-0/+0
Change-Id: Iafeaecad612b724c4eeb85e0c01c942afb6445d8
2015-10-09xmloff: fix ODF import of gradient draw:angle attribute a bitMichael Stahl1-0/+212
ODF 1.2 part 3, 18.3.1 angle, says "An angle, as defined in §4.1 of [SVG]" and "If no unit identifier is specified, the value is assumed to be in degrees." Unfortunately OOo could only read and write 10th of degree here. See also https://issues.oasis-open.org/browse/OFFICE-3774 As the first step towards fixing that, implement the import for draw:angle values with an angle unit identifier, but leave the import as-is if the angle identifier is missing. Change-Id: Ib88d417c03998ebcfc569b01492f0e1f851bbc85
2015-09-18check stream status and string lengthsCaolán McNamara1-0/+0
Change-Id: I99f3d4a2ec760228f485d01fce856deb9c068431
2015-09-14tdf#91293: Preserve hyperlink on URL field OOXML exportKatarina Behrens1-0/+0
The fix is twofold: 1.Get URL property from the underlying text field, not from the text run -- put text field properties into rXPropSet (that's what GETA macro later queries), not into rRun 6a043e9c0acff20e1618ca8ec15c21d5d0fd0d37 does s/rXPropSet/rRun/ afaics for no good reason 2. Retrieve string content from URL field early, so that the test for empty text content doesn't fire Change-Id: I4317e4a2f6f2e6f15c30932adc80f1227e010af0 Reviewed-on: https://gerrit.libreoffice.org/18031 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com> Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
2015-09-04tdf#93097 oox: fix import of metadata from non-relative stream pathsMiklos Vajna1-0/+0
Commit ef2668bad976f1fbb70759887cafd35ea7833655 (PPTX import: fix missing document metadata, 2014-08-28) implemented metadata import for the PPTX filter, but in case the metadata stream is not an existing one, then OHierarchyHolder_Impl::GetListPathFromString() invoked by OStorage::openStreamElementByHierarchicalName() throws. The bugdoc is generated by a 3rd-party tool that always starts the stream path with a slash, and MSO seems to just ignore that: so let's do the same to be able to open the document. Change-Id: I6c0715adeb19b9055669f6a45055415dd2c44e28