summaryrefslogtreecommitdiff
path: root/svtools/qa
AgeCommit message (Collapse)Author
2022-01-10use less SvStream::Flush()Noel Grandin
Flush() turns into a sync() on the device, which is pretty slow. Most of the time all we actually want to do is to flush the internal buffers from the SvStream. So expose the FlushBuffer method and use that where possible. And also means we don't need the mbDontFlushOnClose flag on SvStream any more. Change-Id: Ibe089b88b325f0fdc565200a97ce72cd26b7fcfb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128214 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-06-03HtmlWriter: add end tag checking and helper for attribute writingTomaž Vajngerl
Added an input variable to end to enter the name of which variable is ending. This is to check that the expected end tag is actually written. Added writeAttribute, which is independent from HtmlWriter and just writes the HTML attribute format to the stream. Change-Id: Ib00a4a37354cd1cb1781ba729ed4046a966e1eb1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116629 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2021-04-27use more string_view in tools/streamNoel Grandin
Change-Id: I2a957cd72d71fea717734488cdb3670e0bcdd6f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114657 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2020-12-29loplugin:stringviewparam: operator +Stephan Bergmann
Change-Id: I044dd21b63d7eb03224675584fa143009c6b6008 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108418 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-19don't mention VclBuilder in the dialog tests docsCaolán McNamara
Change-Id: Id18a25e3d3310342887757fe417769f4213b8a3c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107981 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2020-12-11Adapt the remaining OUString functions to std string_viewStephan Bergmann
...for LIBO_INTERNAL_ONLY. These had been missed by 1b43cceaea2084a0489db68cd0113508f34b6643 "Make many OUString functions take std::u16string_view parameters" because they did not match the multi-overload pattern that was addressed there, but they nevertheless benefit from being changed just as well (witness e.g. the various resulting changes from copy() to subView()). This showed a conversion from OStringChar to std::string_view to be missing (while the corresponding conversion form OUStringChar to std::u16string_view was already present). The improvement to loplugin:stringadd became necessary to fix > [CPT] compilerplugins/clang/test/stringadd.cxx > error: 'error' diagnostics expected but not seen: > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 43 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:42): simplify by merging with the preceding assignment [loplugin:stringadd] > File ~/lo/core/compilerplugins/clang/test/stringadd.cxx Line 61 (directive at ~/lo/core/compilerplugins/clang/test/stringadd.cxx:60): simplify by merging with the preceding assignment [loplugin:stringadd] > 2 errors generated. Change-Id: Ie40de0616a66e60e289c1af0ca60aed6f9ecc279 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107602 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2020-12-01tdf#42949 Fix new IWYU warnings in directories s*Gabor Kelemen
Except recently checked sc, sd, svx, sw Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ice1b86628e4f22a39f307b9c5fa567b6ab9d5acb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/106917 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-11-16tdf#123936 Formatting files in module svtools with clang-formatPhilipp Hofer
Change-Id: I56a49c7fec128eb47818ee664acf01434d24f88d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105715 Tested-by: Jenkins Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2020-08-15remove constructor with plain Bitmap from Graphic, use BitmapExTomaž Vajngerl
Change-Id: Ie429a10a8f54c6779d437ee4bc75a5ea0c427848 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100727 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-04-26fix make screenshot breakageCaolán McNamara
Change-Id: Ieb2a4ee7475de2f3f0b6de6c1f3a5c305805131f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92932 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2019-12-23sal_Char->char in svtools..svlNoel Grandin
Change-Id: Ideb61209e8795865bce6e0b1d667b34f8a8db4d9 Reviewed-on: https://gerrit.libreoffice.org/85713 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-10-23lok: svtools: change parameter from "ID" to "POS" in ValueSetUIObject classHenry Castro
The ValueSet control has an item list with a pair properties "(pos,id)". The "POS" parameter is the item "ID" not the position in the list and to not modify doc_sendDialogEvent function, let's have same uniform parameter for the action "SELECT". Change-Id: I5ce2cf0433bebcd77954f271c4aa09b0b446c0ab Reviewed-on: https://gerrit.libreoffice.org/81399 Tested-by: Jenkins Reviewed-by: Henry Castro <hcastro@collabora.com>
2019-10-23lok: svtools: create ValueSetUIObject classHenry Castro
The ValueSet control is used in Layouts panel inside Sidebar of the impress document. Once the LO server sends the UI data to the client side that is transformed to mobile view using Mobile Wizard framework. The loleaflet client side has to send commands for the user interactions like to touch an item. e.g. Send "WindowId SELECT ID=300" The unit test simulates the scenario, so the ValueSet control executes the action. Change-Id: Ib6ec5db6ce2777e819f81a9dae74c4641bb7053b Reviewed-on: https://gerrit.libreoffice.org/81141 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Henry Castro <hcastro@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/81354 Tested-by: Jenkins
2019-09-19tdf#42949 Fix IWYU warnings in svtools/Gabor Kelemen
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ifc70900022efcd089c0874bd46e0aacaef0efb72 Reviewed-on: https://gerrit.libreoffice.org/78767 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-09-15ditch wizarddialog.ui nowCaolán McNamara
Change-Id: I4c0b169849ccd255766bbadf4b1eac900a0b192f Reviewed-on: https://gerrit.libreoffice.org/78940 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-08-25pdfium: Use std::vector to hold the PdfData.Jan Holesovsky
This fixes the destruction of the static cache of the PDF data; without this, there were already missing uno runtime info. (cherry picked from commit 20055ebe1b27f716a2acf1f0f4dda2864ae811bf) Change-Id: I877c9ccf96c4b7eabf3d643e17f324d86d987f94 Reviewed-on: https://gerrit.libreoffice.org/77691 Tested-by: Jenkins Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
2019-07-31Improved loplugin:stringconstant (now that GCC 7 supports it): svtoolsStephan Bergmann
Change-Id: I4d42441adf5408e0281577078b0d5537acb02513 Reviewed-on: https://gerrit.libreoffice.org/76641 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2019-07-03Remove some unused includesMiklos Vajna
See tdf#42949 for motivation. Change-Id: I89c082d62409b40c8472b865cc60b0d10923c9c1 Reviewed-on: https://gerrit.libreoffice.org/75015 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-03-22GraphisObjectTest: Remove some unused test documentsTamás Zolnai
Change-Id: Id97a35cdef93f4e1b21e4c3d22918f1bae42aea9 Reviewed-on: https://gerrit.libreoffice.org/69563 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2019-03-07CppunitTest_svtools_html: use CPPUNIT_TEST_FIXTURE()Miklos Vajna
Change-Id: Icf4d3a649c5e6a53035c2a1573a8dd7154db2edd Reviewed-on: https://gerrit.libreoffice.org/68831 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-02-10loplugin:indentation in svtoolsNoel Grandin
Change-Id: I5535acdf828f78d69ba8f6b4c990f9139ed3319b Reviewed-on: https://gerrit.libreoffice.org/67566 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-10-04drop SvMemoryStream::GetBufferNoel Grandin
since it does the same thing as GetData() Change-Id: I18d35aa4e67ad7775987160c021863d0de90179b Reviewed-on: https://gerrit.libreoffice.org/61350 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-08-29XHTML import: <br></br> is one line breakMiklos Vajna
But only for XHTML, HTML stays unchanged to be in sync with web browsers. Change-Id: I3a1cf6651dab565bafece68963acb112ae715cdd Reviewed-on: https://gerrit.libreoffice.org/59727 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins
2018-06-01loplugin: look for CPPUNIT_ASSERT_EQUALS with params swappedNoel Grandin
idea originally from either tml or moggi, can't remember which Change-Id: Id78d75035036d3aa1666e33469c6eeb38f9e624d Reviewed-on: https://gerrit.libreoffice.org/55126 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2018-04-10remove swapping and link from GraphicObject and GraphicTomaž Vajngerl
Change-Id: If81127e0589b504909801bcbf392d2dec3a3efc1 Reviewed-on: https://gerrit.libreoffice.org/52244 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-04-10vcl: detach usage and remove GraphicManager and GraphicCacheTomaž Vajngerl
Also remove some GraphicObjectTest because they call into GraphicManager which now doesn't exist anymore. Change-Id: Ia434736d8611df629af3e897c878a7fb8bbe4706 Reviewed-on: https://gerrit.libreoffice.org/52243 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-03-11Move (and rename) graphic stuff from svtools to vclTomaž Vajngerl
This is preparing to change how GraphicManager works where it won't base itself around GraphicObject anymore but Graphic. No functional or cosmetic change was made to the classes, only changes that were needed because of the move and rename. The only thing that wasn't moved is the GraphicRenderer as it is not needed in vcl for now (but makes sense to move it in the future to keep graphic stuff together). grfmgr was renamed to GraphicObject as the GraphicManager will be changed a lot and most likely moved out, so the name grfmgr won't make any sense anymore. All the UNO implementations were renamed with a prefix Uno and used the same name as the class name. This is made to be more specific which are the Uno objects (for example graphic.cxx contained the implementation of XGraphic, which is similar to graph.cxx contains Graphic). Change-Id: I54a2fa6c7e997469aaa7770db05244adb9f64137 Reviewed-on: https://gerrit.libreoffice.org/51068 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2018-03-08svtools: allow writing characters with HtmlWriterMiklos Vajna
The sw HTML image export already uses HtmlWriter, so need to extend this to support XHTML alternate text, writing the character data directly is not an option. Change-Id: Iac3f2b9a3828175a5f1d0fb14ab505f8de389e52 Reviewed-on: https://gerrit.libreoffice.org/50965 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-02-28sw HTML export: allow custom XHTML namespace aliasMiklos Vajna
This helps in case the HTML filter expected to produce an XHTML fragment that has an explicit namespace alias for <http://www.w3.org/1999/xhtml>. This only has an effect when HtmlWriter is used to write elements, though. Change-Id: I161caf4bb6bc6d0c21a7a67433b08bb060b447f1 Reviewed-on: https://gerrit.libreoffice.org/50448 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2018-01-24Fix some IWYU warningsMiklos Vajna
Change-Id: I4b6e799c1afc2a762a3729ee89f3226c59a6eef8 Reviewed-on: https://gerrit.libreoffice.org/48462 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2018-01-16Fix typosAndrea Gelmini
Change-Id: I078626eaa3155cc429320cc8c1532003b382b22a Reviewed-on: https://gerrit.libreoffice.org/47855 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-12-14Related: tdf#114428 svtools HTML import: avoid XML declaration in body textMiklos Vajna
Just ignore it for now. Change-Id: Idf82af611370d957c6704cce250941a8a0b90637 Reviewed-on: https://gerrit.libreoffice.org/46388 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
2017-10-23loplugin:includeform: svtoolsStephan Bergmann
Change-Id: I7a25c2db8c097ae4512c8a8b7d8a272905b46e50
2017-09-22Ditch now unused GraphicExportDialog, GraphicExportOptionsDialogEike Rathke
That was a dead end anyway, trying to partly reimplement SvFilterOptionsDialog ExportDialog, instead of implementing the necessary bits to use that one which has everything. Change-Id: Icde7422f2c2d7e26c07dfe921a4abda41e222b09 Reviewed-on: https://gerrit.libreoffice.org/42503 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com>
2017-02-14vcl pdf import: change test documents to test bitmap fallbackMiklos Vajna
I.e. the test documents now reflect what is created by LO if you insert a PDF image into a document manually on master. Change-Id: Ibacce15220a21b159b5e987678c381a98a29fd1a
2017-02-13vcl pdf import: use pdfium instead of draw_pdf_importMiklos Vajna
Replace creating a full Draw component with direct pdfium library calls. This also means that the result is now a bitmap, not a metafile for now. Also decouple HAVE_FEATURE_PDFIMPORT and HAVE_FEATURE_PDFIUM, the first is the "import PDF into Draw" feature, the second is the "insert PDF as image" feature. Change-Id: I72c25642ec84cc831df362e02b1520c6e6d9adcf Reviewed-on: https://gerrit.libreoffice.org/34217 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2017-01-09second arg of deformed copy ctor isn't usedCaolán McNamara
except in the qa test Change-Id: I84d1a06194e4c11b218c417663f12195c9f76526 Reviewed-on: https://gerrit.libreoffice.org/32890 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2016-12-06loplugin:unnecessaryoverrideStephan Bergmann
Change-Id: Iac074bd6f59d2fc890459b45801d0a6143c3eb9e
2016-11-15Fix typosSamuel Mehrbrodt
Change-Id: I3e38b1d445c368c28e807202b94c603bd2b2c672 Reviewed-on: https://gerrit.libreoffice.org/30872 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
2016-11-10'make screenshot' use-after-free fixesStephan Bergmann
Change-Id: I4302d0d767a1bf50fd34a78e9aa0ad6d6b0c7a22
2016-11-10'make screenshot' loplugin fixesStephan Bergmann
Change-Id: Ibebcd1c1ebfea0ecdf9d90b6f8bcc8ceb87df456
2016-10-05Remove _TYPED suffix from tools/link.hxx macrosStephan Bergmann
...which was introduced with 3ead3ad52f9bb2f9d1d6cf8dfc73a0a25e6778ed "Gradually typed Link" to distinguish the new, typed versions from the old, untyped ones, but is no longer necessary since 382eb1a23c390154619c385414bdbe6f6e461173 "remove untyped Link<>" removed the old versions. Change-Id: I494025df486a16a45861fcd8192dfe0275b1103c
2016-08-18coverity#1371121 Unchecked return valueCaolán McNamara
Change-Id: I1413b62112922af8d6872de413ca7decc0d75875
2016-08-18screenshots: unify dumping of dialog test batch fileArmin Le Grand
Change-Id: Ia1e79216d9537c65f8b7362778a2e1ad3ec6c2c2
2016-08-18screenshots: add dialog test cases for svtoolsArmin Le Grand
All *.ui files create a screenshot, but not all look useful Change-Id: I7a7a6c3ab38e8890404082dd359ff5f4f1ebf9fd
2016-07-22Fix --disable-pdfimport buildMiklos Vajna
Change-Id: Ida06b892aea92cfe26fd62372e21ca611d8838d3 Reviewed-on: https://gerrit.libreoffice.org/27447 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-06-29vcl: handle PDF data in Read/WriteImpGraphic()Miklos Vajna
Initially I wrote the test to cover f7d6f3e4e3fda3cd4936880918e2831246634a3e (svtools: survive swapout/in of graphic with embedded pdf, 2016-06-28), but as it turns out the actual swapin/out code is in vcl, so extend that as well to support pdf data. Change-Id: I320ea729dce9440b84a5089607807322ea7b0b04 Reviewed-on: https://gerrit.libreoffice.org/26755 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
2016-05-27Convert GRAPHIC to scoped enumNoel Grandin
Change-Id: I1fd09a729cbda00f99841532e0dd3fa66bce7bea Reviewed-on: https://gerrit.libreoffice.org/25534 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-03-10Extract Directories from BootstrapFixtureBaseStephan Bergmann
(as some tests derive from the latter only for the Directories part, not for the setUp/tearDown overrides: those tests will be cleaned up next) Change-Id: Ib6b78eea868b8bc21d4cc6e8fd9e1d025deca05f Reviewed-on: https://gerrit.libreoffice.org/23078 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-07tdf#97703 removed empty setUp/tearDown methodsChirag Manwani
Change-Id: I244d481bce4723d172e26c0d31aab0a541334604 Reviewed-on: https://gerrit.libreoffice.org/22959 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>