sc: filter: rtf: add method "AddFont"
[LibreOffice.git] / include / sfx2 / sfxdlg.hxx
blobba30626937e82b9cf64a2c63357800912683437f
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/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #ifndef INCLUDED_SFX2_SFXDLG_HXX
20 #define INCLUDED_SFX2_SFXDLG_HXX
22 #include <sal/config.h>
23 #include <sfx2/dllapi.h>
25 #include <vcl/abstdlg.hxx>
27 #include <sot/formats.hxx>
28 #include <sfx2/tabdlg.hxx>
29 #include <com/sun/star/uno/Reference.h>
31 class SfxItemSet;
32 class SfxItemPool;
33 class SvObjectServerList;
34 class TransferableDataHelper;
35 class SvGlobalName;
37 namespace sfx2
39 class LinkManager;
40 class SvBaseLink;
43 namespace com::sun::star::embed { class XEmbeddedObject; }
44 namespace com::sun::star::embed { class XStorage; }
45 namespace com::sun::star::io { class XInputStream; }
46 namespace com::sun::star::uno { class Any; }
48 class SfxAbstractDialog : virtual public VclAbstractDialog
50 protected:
51 virtual ~SfxAbstractDialog() override = default;
52 public:
53 /** Get a set of items changed in the dialog.
55 virtual const SfxItemSet* GetOutputItemSet() const = 0;
56 virtual void SetText( const OUString& rStr ) = 0;
59 class SfxAbstractTabDialog : virtual public SfxAbstractDialog
61 protected:
62 virtual ~SfxAbstractTabDialog() override = default;
63 public:
64 virtual void SetCurPageId( const OString &rName ) = 0;
65 virtual WhichRangesContainer GetInputRanges( const SfxItemPool& ) = 0;
66 virtual void SetInputSet( const SfxItemSet* pInSet ) = 0;
69 class SfxAbstractApplyTabDialog : virtual public SfxAbstractTabDialog
71 protected:
72 virtual ~SfxAbstractApplyTabDialog() override = default;
73 public:
74 virtual void SetApplyHdl( const Link<LinkParamNone*,void>& rLink ) = 0;
77 class SfxAbstractInsertObjectDialog : virtual public VclAbstractDialog
79 protected:
80 virtual ~SfxAbstractInsertObjectDialog() override = default;
81 public:
82 virtual css::uno::Reference < css::embed::XEmbeddedObject > GetObject()=0;
83 virtual css::uno::Reference< css::io::XInputStream > GetIconIfIconified( OUString* pGraphicMediaType )=0;
84 virtual bool IsCreateNew()=0;
87 class SfxAbstractPasteDialog : virtual public VclAbstractDialog
89 protected:
90 virtual ~SfxAbstractPasteDialog() override = default;
91 public:
92 virtual void Insert( SotClipboardFormatId nFormat, const OUString & rFormatName ) = 0;
93 virtual void InsertUno( const OUString& sCmd, const OUString& sLabel ) = 0;
94 virtual void SetObjName( const SvGlobalName & rClass, const OUString & rObjName ) = 0;
95 virtual void PreGetFormat( const TransferableDataHelper& aHelper ) = 0;
96 virtual SotClipboardFormatId GetFormatOnly() = 0;
97 virtual SotClipboardFormatId GetFormat( const TransferableDataHelper& aHelper ) = 0;
100 class SfxAbstractLinksDialog : virtual public VclAbstractDialog
102 protected:
103 virtual ~SfxAbstractLinksDialog() override = default;
106 class AbstractScriptSelectorDialog : virtual public VclAbstractDialog
108 protected:
109 virtual ~AbstractScriptSelectorDialog() override = default;
110 public:
111 virtual OUString GetScriptURL() const = 0;
112 virtual void SetRunLabel() = 0;
115 namespace com::sun::star::frame { class XFrame; }
117 class SFX2_DLLPUBLIC SfxAbstractDialogFactory : virtual public VclAbstractDialogFactory
119 public:
120 virtual ~SfxAbstractDialogFactory() override; // needed for export of vtable
121 static SfxAbstractDialogFactory* Create();
122 virtual VclPtr<VclAbstractDialog> CreateFrameDialog(weld::Window* pParent, const css::uno::Reference< css::frame::XFrame >& rFrame, sal_uInt32 nResId, const OUString& rParameter) = 0;
123 virtual VclPtr<SfxAbstractTabDialog> CreateAutoCorrTabDialog(weld::Window* pParent, const SfxItemSet* pAttrSet) = 0;
124 virtual VclPtr<SfxAbstractTabDialog> CreateCustomizeTabDialog(weld::Window* pParent,
125 const SfxItemSet* pAttrSet,
126 const css::uno::Reference< css::frame::XFrame >& xViewFrame ) = 0;
127 virtual CreateTabPage GetTabPageCreatorFunc( sal_uInt16 nId ) = 0;
128 virtual GetTabPageRanges GetTabPageRangesFunc( sal_uInt16 nId ) = 0;
129 virtual VclPtr<SfxAbstractInsertObjectDialog> CreateInsertObjectDialog(weld::Window* pParent, const OUString& rCommand,
130 const css::uno::Reference < css::embed::XStorage >& xStor,
131 const SvObjectServerList* pList )=0;
132 virtual VclPtr<VclAbstractDialog> CreateEditObjectDialog(weld::Window* pParent, const OUString& rCommand,
133 const css::uno::Reference < css::embed::XEmbeddedObject >& xObj )=0;
134 virtual VclPtr<SfxAbstractPasteDialog> CreatePasteDialog(weld::Window* pParent) = 0;
135 virtual VclPtr<SfxAbstractLinksDialog> CreateLinksDialog(weld::Window* pParent, sfx2::LinkManager* pMgr, bool bHTML=false, sfx2::SvBaseLink* p=nullptr) = 0;
136 virtual VclPtr<VclAbstractDialog> CreateSvxScriptOrgDialog(weld::Window* pParent, const OUString& rLanguage) = 0;
138 virtual VclPtr<AbstractScriptSelectorDialog> CreateScriptSelectorDialog(weld::Window* pParent,
139 const css::uno::Reference< css::frame::XFrame >& rxFrame) = 0;
141 virtual void ShowAsyncScriptErrorDialog( weld::Window* pParent, const css::uno::Any& rException ) = 0;
143 virtual VclPtr<VclAbstractDialog> CreateOptionsDialog(
144 weld::Window* pParent, const OUString& rExtensionId ) = 0;
146 virtual VclPtr<VclAbstractDialog> CreateAboutDialog(weld::Window* _pParent) = 0;
148 virtual VclPtr<VclAbstractDialog> CreateTipOfTheDayDialog(weld::Window* _pParent) = 0;
150 virtual VclPtr<VclAbstractDialog> CreateToolbarmodeDialog(weld::Window* _pParent) = 0;
153 #endif
155 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */