tdf#130857 qt weld: Implement QtInstanceWidget::strip_mnemonic
[LibreOffice.git] / writerperfect / qa / unit / WpftFilterTestBase.hxx
blob8f929e9f7dfdd75c3cb3fbd9cc541edaeb053c7f
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
10 #pragma once
12 #include "wpftqahelperdllapi.h"
14 #include <string_view>
15 #include <unordered_map>
17 #include <com/sun/star/uno/Reference.hxx>
19 #include <rtl/ustring.hxx>
21 #include <unotest/filters-test.hxx>
23 #include "WpftFilterFixture.hxx"
25 namespace com
27 namespace sun
29 namespace star
31 namespace document
33 class XFilter;
39 namespace writerperfect
41 namespace test
43 typedef std::unordered_map<OUString, bool> WpftOptionalMap_t;
45 class WPFTQAHELPER_DLLPUBLIC WpftFilterTestBase : public ::test::FiltersTest,
46 public WpftFilterFixture
48 public:
49 explicit WpftFilterTestBase(const OUString& rFactoryURL);
51 protected:
52 void doTest(const OUString& rFilter, std::u16string_view rPath);
53 void doTest(const OUString& rFilter, std::u16string_view rPath,
54 const WpftOptionalMap_t& rOptionalMap);
56 private:
57 virtual bool load(const OUString&, const OUString& rURL, const OUString&, SfxFilterFlags,
58 SotClipboardFormatId, unsigned int) override;
60 private:
61 const OUString m_aFactoryURL;
62 css::uno::Reference<css::document::XFilter> m_xFilter;
63 const WpftOptionalMap_t* m_pOptionalMap;
68 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */