1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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/.
14 #include <cppuhelper/implbase.hxx>
16 #include <com/sun/star/document/XFilter.hpp>
17 #include <com/sun/star/document/XExporter.hpp>
18 #include <com/sun/star/lang/XServiceInfo.hpp>
20 namespace com::sun::star::uno
22 class XComponentContext
;
25 namespace writerperfect
29 struct FixedLayoutPage
;
32 /// EPUB export XFilter implementation.
33 class EPUBExportFilter
34 : public cppu::WeakImplHelper
<css::document::XFilter
, css::document::XExporter
,
35 css::lang::XServiceInfo
>
37 css::uno::Reference
<css::uno::XComponentContext
> mxContext
;
38 css::uno::Reference
<css::lang::XComponent
> mxSourceDocument
;
41 EPUBExportFilter(css::uno::Reference
<css::uno::XComponentContext
> xContext
);
45 filter(const css::uno::Sequence
<css::beans::PropertyValue
>& rDescriptor
) override
;
46 void SAL_CALL
cancel() override
;
50 setSourceDocument(const css::uno::Reference
<css::lang::XComponent
>& xDocument
) override
;
53 OUString SAL_CALL
getImplementationName() override
;
54 sal_Bool SAL_CALL
supportsService(const OUString
& rServiceName
) override
;
55 css::uno::Sequence
<OUString
> SAL_CALL
getSupportedServiceNames() override
;
57 /// Gives the default EPUB version.
58 static sal_Int32
GetDefaultVersion();
59 /// Gives the default split method.
60 static sal_Int32
GetDefaultSplitMethod();
61 /// Gives the default layout method.
62 static sal_Int32
GetDefaultLayoutMethod();
65 /// Create page metafiles in case of fixed layout.
66 void CreateMetafiles(std::vector
<exp::FixedLayoutPage
>& rPageMetafiles
);
69 } // namespace writerperfect
71 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */