summaryrefslogtreecommitdiff
path: root/oox
AgeCommit message (Collapse)Author
2022-04-20Advanced Diagram support: Use better association Model<->XShapeArmin Le Grand (Allotropia)
To have a more direct and more reliable association between the XShape/oox::Shape and the model data svx::diagram::Point I added optional usage of the Model-UUID for that at the oox::Shape. Also added a 'fake' UUID to work with the BackgroundShape's attributes. Changed all preserve/rescue code to work based on that. Also cleanups/comments and preparations of some flags in the Diagram ModelData to steer behaviour on re-ceration. Change-Id: Ie30effdff34dcdbbc79a766de09157b2a3bd97d3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133168 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-04-19new loplugin:stringviewvar looks for OUString vars that can beNoel Grandin
... that can be string_view Change-Id: I0ddf66725e08b58e866a764f57200dd188b9f639 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133066 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-18oox: move DataTableConverter into own fileTomaž Vajngerl
Change-Id: I3dce87ecd5b8f69862f26edb66fe54c6acee8660 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133117 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2022-04-17ofz: Null-dereferenceCaolán McNamara
Change-Id: Ib058458860f606736455ae997a6f7f74de5585bf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133104 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-04-15tdf#109169 use custGeom for Octagon Bevel shapeRegina Henschel
The shapes 'Octagon Bevel', type col_60da8460, and 'Diamond Bevel', type col-502ad400, are LO specific preset shapes. They have neither a counterpart in MS binary nor in OOXML. So they need to be exported with custGeom. To force custGeom these shape types are moved from vDenylist to vAllowlist. These shapes were exported as prst='rect' before. Change-Id: I9619345812b6dba8f14ec2cc6a92ae808a56b595 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133069 Tested-by: Jenkins Reviewed-by: Regina Henschel <rb.henschel@t-online.de>
2022-04-15oox: move DataTable{Context,Model} into own file, prop. "showKeys"Tomaž Vajngerl
Move DataTableContext and DataTableModel into its own files and add the missing "showKeys" property of the data table (dTable). Change-Id: I44fb436000c7f00a596fc9b12489d15ea1368e68 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133021 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2022-04-14use more string_view in ooxNoel Grandin
Change-Id: I25fe1cbfae43bb533e7dfc2561d0b70976aa6a40 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132985 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-14Advanced Diagram support: Secure properties at Diagram ModelDataArmin Le Grand (Allotropia)
Additionally to the Text/Attributes already saved/secured after Diagram import, secure more data that is part of the Diagram ModelData. This is about attributes (e.g. FillStyle/LineStyle, TextAttributes, ...) in UNO API formt that will be secured/ attached to the Diagram ModelData in it's svx::diagram::Point structure. This is done for all those entries for which a XShape will/ would be incarnated, thus associated to entries that will get a visualization, including the BackgroundObject. From that data, at re-creation time, the attributes can be re-applied to the re-created XShape(s), also after changes to the Diagram Model Data (e.g. Add/Remove). This is - besides the already added securing of the Style/ Theme - a 2nd method for lossless re-creation. For the BackgroundObject - if it has FillStyles - it is even the only method to secure that data and thus necessary for that case. The selection of atributes that gets secured is minimal for now and may/need to be extended for existing cases accordingly. Change-Id: Ie9b72b9b9135113cf858d57fe6cd8622d736c4a4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132976 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-04-13loplugin:stringviewparam whitelist some more functionsNoel Grandin
for which we have o3tl:: equivalents Change-Id: I4670fd8b703ac47214be213f41e88d1c6ede7032 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132913 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-12loplugin:stringview more o3tl conversionNoel Grandin
look for call sequences that can use string_view and the new o3tl functions in o3tl/string_view.hxx Also add a few more wrappers to said #include file Change-Id: I05d8752cc67a7b55b0b57e8eed803bd06bfcd9ea Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132840 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-11loplugin:stringview add check for getToken().toInt32Noel Grandin
where we can convert that to o3tl::toInt32(o3tl::getToken( and avoid the heap allocation of a temporary string Change-Id: Ib11c19c6e6cdc0de3e551affd3578d181e292de4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132810 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-11Advanced Diagram support: Make Style/Theme info availableArmin Le Grand (Allotropia)
The Style/Theme information is central for re-creating the Diagram shape representation. Make that data available in the ModelData classes in svx. With that information, a re- creation with all needed attributes is possible, e.g. when the model gets changed (remove/add data entries). Also some cleanups done. Change-Id: Icd925c9731891092f1ddd96c8feb165e1f846f4f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132738 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-04-10loplugin:stringview check for getToken and trimNoel Grandin
since we now have o3tl versions of those that work on string_view. Also improve those o3tl functions to support both string_view and u16string_view Change-Id: Iacab2996becec62aa78a5597c52d983bb784749a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132755 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-08move comphelper::string::toInt32 to o3tlNoel Grandin
so we can use it in places where we cannot include comphelper Change-Id: Iba0ba3e4c0dcf0f9d1f09092a77c3b2010ec4f6d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132732 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-08use more subView when converting to Int32Noel Grandin
Change-Id: I54e3ddf79ba793fd4328bf8bda7f949b65349651 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132693 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-06tdf#148327 docx export: fix puzzle shapeAttila Bakos (NISZ)
There is an exporter class for preset shapes, namely the DMLPresetShapeExporter, which in its ctor calls the msfilter::GetShapeName() converter method where the puzzle cause exception. To avoid this return with false to export it with custgeom in time. Change-Id: I8d29bf551638a66abf381c9cb8f6a0eebc881195 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132567 Tested-by: Jenkins Reviewed-by: Attila Bakos <bakos.attilakaroly@nisz.hu> Reviewed-by: Regina Henschel <rb.henschel@t-online.de>
2022-04-06Advanced Diagram support: Enhance BackgroundShape handlingArmin Le Grand (Allotropia)
The BackgroundShape may have a FillStyle after import, so do handle that FillStyle accordingly. Also enhance breaking the Group by keeping that shape in that case and deactivate Move/Size change lock for it. Also Undo needed. Change-Id: Iccdb236a2311275efc07162fd4bd2cfc252fd437 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132626 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-04-05Fix typosAndrea Gelmini
Change-Id: Idcb10d0cc0759473e95e47afec7ed69853628612 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132587 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2022-04-05Advanced Diagram support: Move Diagram Text information to svxArmin Le Grand (Allotropia)
In a next step to get the Diagram mechanism/ModelData independent from oox, I moved the Text ModelData to svx, using a TextBody struct. This is a 1st move that covers most of what the algorithms to handle Diagram re-layout and other functionality use. This will potentially have to be extended accordingly when missing data is detected. It is potentially much more simple as the oox TextBody, by purpose. Due to functionality using that data I could now massively move more of it to svx. Change-Id: I6d6e6c572f119aeefa4e91eff56f58f3ceb6a31e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132523 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-04-05Fix typosAndrea Gelmini
Change-Id: Ieb57b614962b398a19d87e0a7427d897b38cf37c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132536 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-04-05Removed execution bits on odp fileAndrea Gelmini
Change-Id: I32aa1660f4b83b349fd6e231fd08eac36d342973 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132534 Tested-by: Julien Nabet <serval2412@yahoo.fr> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-04-04tdf#100391 calculate true textarea rect for custGeomRegina Henschel
Without the fix the attributes for <a:rect> were set to 'l', 't', 'r' and 'b'. That means that the textarea rectangle equals the shape rectangle. That is the default and works for many shapes. But 'Puzzle' has a smaller textarea rectangle, for example. Because the values in draw:text-areas are relative to the internal coordinate system given by draw:viewBox in ODF, but the values in <a:rect> are relative to the shape coordinate system in OOXML, we cannot simple write the current absolute values but need to calculate them depending on actual width and height. For that we need guides. The patch introduces a guide list. Currently the list contains only the guides for the textarea rectangle, but it can be extended when export of handles will be implemented one day. Change-Id: I1050627ef6459ab5f8fafa939d7905122870c903 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132489 Tested-by: Jenkins Reviewed-by: Regina Henschel <rb.henschel@t-online.de>
2022-04-04sc: add support for xr2 namespace and read uid of sparkline groupTomaž Vajngerl
Change-Id: I470819a89338f4fb1d9b2486ffb4d93f8eb42844 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132504 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2022-04-04tdf#53970 PPTX: fix broken export of linked media filesTünde Tóth
Missing TargetMode="External" in the export of linked media files resulted corrupted PPTX. Change-Id: I76246db331d199810a5b413d44bec95283e88e47 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132402 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-04-03loplugin:stringviewparam convert methods using matchNoel Grandin
which converts to a combination of substr and o3tl::starts_with Change-Id: I5b01a181b9e6bee3483e4f49f1a9426abcc682d0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132458 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-04-02loplugin:stringviewparam convert methods using indexOfNoel Grandin
.. and lastIndexOf, which convert to find and rfind Change-Id: I6c4156cf904774c0d867f85a4c2785dba7593f62 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132445 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-31Advanced Diagram support: Move class DiagramData to svx AFAPArmin Le Grand (Allotropia)
Splitted and moved parts of DiagramData class to svx as peparation to access from there. Done as pure virtual class so that no incarnations will be possible, also made the constructor protected. The derived class in oox hosts all functionality/data which involves usage/modification of oox::Shape class. That way we get closer to get the Diagram DataModel isloated/seperated. Not-yet moved is the String/Text holding data, it's still in oox. Moving that one will be next, that will allow to migrate quite some more functionalty to svx. Change-Id: I389dbf3ebf6171b8175cf30be7bbc8c20d9a38e1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132303 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-03-30tdf#74670 tdf#91286 PPTX XLSX export: save image onceTünde Tóth
Impress and Calc used to dump the same image file as many times as it was featured in the document, resulting redundant, sometimes huge documents. Note: using only checksum to recognize image duplication is a regression, because checksum collision results image loss. This is a very unlikely event, and the following commits have got the same problem. The solution is comparing the images with the same checksum byte for byte. See also commit b484e9814c66d8d51cea974390963a6944bc9d73 "tdf#83227 oox: reuse RelId in DML/VML export for the same graphic" and commit 797fef38612fb2fd62d1f6591619b9361e526bca "tdf#118535 DOCX export: save header image once". Change-Id: I9f233d521941381746634cf4f9b5991da0dadda9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131928 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-03-30ofz#46160 Use-of-uninitialized-valueCaolán McNamara
Change-Id: Ic39fd3579623563adf16025442bb634a273decb7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132298 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-30ofz#46160 Null-dereference READCaolán McNamara
Change-Id: Id33a39a7a65849a4ca98b43a88e60d5a96eaf5de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132297 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-30Extract 'switch' block out of WriteCustomGeometryRegina Henschel
This is a follow up to commit 2029b2f6dd0109c5892e5ac5640022b31fe42fd2. That commit has increased the line count of WriteCustomGeometry to more than 500. This patch splits it to a main part of about 230 lines and a new method for the previous 'switch' block of about 300 lines. That makes the loops in the main part better readable. Change-Id: Ied4378f54e7c8dc7965a5b1db15baf0b35f63f59 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132274 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-03-29tdf#89449 PPTX import: fix line connectorsTibor Nagy
Line connectors were imported as plain shapes, losing their functionality during editing, i.e. keeping connections of boxes and other shapes. Change-Id: I0f1562be2dbcce0e45eb209c6ca4e035731039e1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131303 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-03-29tdf#135923 DOCX shape import: set text colorTünde Tóth
to the character color of the shape if it is not comes from direct formatting. Change-Id: I3f0a3e952b5449a6d92c5bb273d353a561f3e3dc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130922 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-03-29tdf#53970 PPTX: fix export of embedded media filesTünde Tóth
Embedded media files lost in documents created with Impress after PPTX export. Change-Id: I453b58f9cfa6a33653e9216fb82b66970a9ec31b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132095 Tested-by: Jenkins Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
2022-03-28-Werror,-Wunused-but-set-variableStephan Bergmann
...since 9e87a00e11486a2be64b0dc2799e3efca4b000cc "oox: replace PUT_PROP macro with comphelper::makePropertyValue() calls" Change-Id: Ic90e6e579e0d546454d2acd8c3fb5b5ac50f9f5a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132223 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2022-03-28Advanced Diagram support: Move data classes to svxArmin Le Grand (Allotropia)
As preparation for own im/export move data classes for which that is now possible to svx Made TypeConstant more safe, also sorted it. Corrected an error there. Secured TypeConstant usage by identifying usages (mnType -> mnXMLType). Had to convert from oox::OptValue to std::optional since 1st is not available in svx in datamodelcontext.cxx. That makes the test work and the test-file load corrrectly. Change-Id: Ifee008caf486ddb6b52a347dc08e7e053c49ef49 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132195 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-03-27Fix typosAndrea Gelmini
Change-Id: I003bd994be4a6a089dfacca1558e84324bf7fc1f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132145 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2022-03-26Advanced Diagram support: Preparations to make oox-Shape temporaryArmin Le Grand (Allotropia)
When we come from the LO-side of things and need to (re)create the Diagram, no oox-Shapes can exist by definition. That forces to see oox-Shapes as temporary helper objects. Since some ModelData is at the oox-Shape after importing a Diagram that data needs to be identified and added to the Diagram ModelData. On the other path, when (re)creating a Diagram from the ModelData, oox-Shapes are needed to use the currently existing mechanism in the import-Filter to create XShapes froom the oox-Shapes. In that path, the Diagram ModelData needs to be applied to the newly created oox-Shape. For now I have identified e.g. the Text as such data value. In the future there may be more ModelData of that type identified and may need to be added. To support that, I have added methods to do that. It may even be feasible in debug builds to add code to compare the imported oox-Shape with a temporarily (re)created one to allow easier identification of yet missing secured/copied ModelData. To make that mechanism obligatory I have added code in DiagramData::build() that deletes all oox-Shapes which were created at Diagam import. This is necessary. That way, the (re)creation is used for Diagram re-creation and can be already used and tested. Deleting all oox-Shapes in build() immediately triggered an error in a UnitTest: testPictureStrip. This shows that here some ModelData in form of BitmapData is not secured - proof of concept and what I described above. To get forward, I adapted to not delete oox-Shapes when Diagram import is executed. Thus, the UnitTests work, and the ReCreate can be used to trigger that behaviour. As an end result this has to be re-activated. It allows now to search and add the missing model data from the test file used in that UnitTest. Change-Id: I6bc39a0898c7be1b4c656875f6d7508c36c9bea8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132127 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-03-25tdf#147978 export subpaths individually in custGeomRegina Henschel
...and implement export of all missing commands, use existing viewBox if suitable, use one EnhancedCustomShape2d move WriteCustomGeometryPoint to protected, make GetCustomGeometryPointValue local The fix solves tdf#100390 too. Without the fix the entire enhanced-path was exported as one element <a:path>. The command F was applied to the whole drawing but should affect only the subpath. The implementation is changed so that each subpath gets its own element <a:path> and command F acts only on its subpath. Support for export of handles and equations is still a long way off. Thus there is no reason to tread shapes with and without handles different. Shapes with handles had used method WritePolyPolygon, but that is not able to handle subpaths. So have desided to use method WriteCustomGeometry for all cases. To get shapes exported regardless of path commands I have added the export for the missing commands. I have removed the no longer used method WritePolyPolygon. The special treatment of shapes "moon" and "mso-spt89" (right up arrow) in export is no longer needed. Related code parts are removed. The unit test testFlipAndRotateCustomShape is adapted. In case the method WriteCustomGeometry fails, the enhanced-path is invalid. In that case an minimal custGeom is written in case of docx. Shapes whose drawing does not touch all edges of the snap rectangle were exported with wrong position and size of the drawing inside the snap rectangle. That is fixed by using an existing ViewBox for the OOXML path size. The old way of creating a path size from point coordinates is only used if the shape has no suitable ViewBox. The point values in unit test SdOOXMLExportTest2::testTdf111798 are adapted to path size 21600 x 21600 and traverse direction of the points is corrected. The resulting shape outline is still the same as before. The expected xml is updated for file tdf92001.odp in SdImportTest::testDocumentLayout. The resulting shape outline is the same, because the shape touches the edges of the snap rectangle. The case, that the shape outline does not touch a edge of the snap rectangle is tested in SdOOXMLExportTest3::testEnhancedPathViewBox. Still missing is the case, that ViewBox has other left,top than 0,0. In that case all coordinates would have to be shifted because the path size in OOXML has only width and height but not left,top. That will not be included in this patch. Change-Id: Ib1736d6a08371f4d98411d2769275f0580cd0030 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131837 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-03-24Fix typosAndrea Gelmini
Change-Id: Iccb89d32b83b7f7035557ad7c0634f66f4c947d3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132082 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-03-24Advanced Diagram support: Continue isolate oox-ShapesArmin Le Grand (Allotropia)
As preparations to use the Diagram ModelData further isolate it from the oox-library-only drawingML Shape used for import. It is necessary to completely isolate the Diagram ModelData from the Diagram import mechanism as a preparation to be able to re-create that Shapes on-demand anytime if needed for re-layout(s). Also removed one unused loadDiagram implementation and streamlined the AdvancedDiagramHelper some more. Change-Id: I7a7c55389e0d00f70c02db73ce2c3ff9ce7a5b22 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132058 Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@me.com>
2022-03-24sd theme: add PPTX export for shape fill colorMiklos Vajna
Do this only in case there are no effects on the color, as that is not yet handled. Note that the theme color was already stored in the grab-bag, so this is primarily interesting in case the theme color was changed or the source format was ODP. Change-Id: Ia4995be68d5f243875632eec4aaf8afbb8f4d5cc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131984 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2022-03-23correct misleading commentSarper Akdemir
Corrects copy/paste residue with the correct content Change-Id: Ie10a4db728de154ebbdaf6c7902b28c71c815456 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131957 Tested-by: Jenkins Reviewed-by: Sarper Akdemir <sarper.akdemir@collabora.com>
2022-03-17tdf#147766 Export empty lines as line with noFillGülşah Köse
We have a case that 0 width line but has auto color. If that case exported there is no line over there, LO handles normally but MSO draws back borders as default. To prevent this we have to export them as line with noFill. testTableBorderLineStyle change reverts a workaround for 3faf005a367cbd28077403bf93810bbaf4805851 testBnc480256 Cell(1,0) still invisible. We are just checking this with another way. Change-Id: If5f6d2dbdba5c295d58307fcfe3b37629ede8a8e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131532 Tested-by: Jenkins Reviewed-by: Justin Luth <jluth@mail.com> Reviewed-by: Gülşah Köse <gulsah.kose@collabora.com>
2022-03-15Simplify GetOOXMLPresetGeometry and GETVMLShapeTypeMike Kaganski
Let them use types that know string lengths, don't require conversion, and are convenient at call sites. Also inline the maps initialization, instead of having separate arrays and initialization loops. Change-Id: Id4469f3f99f3f0eb2cd83f0671cf892df4e420a0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131550 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-03-14simplify GetOOXMLPresetGeometryNoel Grandin
all the call sites are using OUString, so push the utf8 conversion into the function Change-Id: I875249b8702cde63737fd42dc1d1592be059cc11 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131525 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-13Fix typosAndrea Gelmini
Change-Id: I9f583937da2cf49fc9013d9e36d63fff312ccb92 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131495 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2022-03-13Fix typo in codeAndrea Gelmini
Change-Id: Ide7c82fadf701e8f16468c153d871757d6a92569 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131496 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Jenkins
2022-03-12Introduce FastAttributeList::add(NS) taking std::u16string_viewMike Kaganski
... and simplify some places removing explicit conversions from OUString to OString. Change-Id: I4cdf9f3ee3101b3d00a0bbba53a983ed3bebce4f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131445 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-03-11loplugin:constparamsNoel Grandin
Change-Id: I5f184f93dbdb414514855c85c9dc1624e7ec8636 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131337 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>