LibreOffice Module sc (master)  1
vbacharacters.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3  * This file is part of the LibreOffice project.
4  *
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  *
9  * This file incorporates work covered by the following license notice:
10  *
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 .
18  */
19 #ifndef INCLUDED_SC_SOURCE_UI_VBA_VBACHARACTERS_HXX
20 #define INCLUDED_SC_SOURCE_UI_VBA_VBACHARACTERS_HXX
21 
22 #include <ooo/vba/excel/XCharacters.hpp>
23 #include <com/sun/star/uno/XComponentContext.hpp>
24 #include <com/sun/star/text/XSimpleText.hpp>
25 
27 #include "vbapalette.hxx"
29 
31 {
32 private:
33  css::uno::Reference< css::text::XTextRange > m_xTextRange;
34  css::uno::Reference< css::text::XSimpleText > m_xSimpleText;
36  // Add because of MSO has different behavior.
37  bool bReplace;
38 public:
41  ScVbaCharacters( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext >& xContext, const ScVbaPalette& dPalette, const css::uno::Reference< css::text::XSimpleText >& xRange, const css::uno::Any& Start, const css::uno::Any& Length, bool bReplace = false );
42 
43  // Attributes
44  virtual OUString SAL_CALL getCaption() override;
45  virtual void SAL_CALL setCaption( const OUString& _caption ) override;
46  virtual ::sal_Int32 SAL_CALL getCount() override;
47  virtual OUString SAL_CALL getText() override;
48  virtual void SAL_CALL setText( const OUString& _text ) override;
49  virtual css::uno::Reference< ov::excel::XFont > SAL_CALL getFont() override;
50  virtual void SAL_CALL setFont( const css::uno::Reference< ov::excel::XFont >& _font ) override;
51 
52  // Methods
53  virtual void SAL_CALL Insert( const OUString& String ) override;
54  virtual void SAL_CALL Delete( ) override;
55 
56  // XHelperInterface
57  virtual OUString getServiceImplName() override;
58  virtual css::uno::Sequence<OUString> getServiceNames() override;
59 
60 };
61 
62 #endif /* SC_VBA_CHARACTER_HXX */
63 
64 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
ScVbaCharacters(const css::uno::Reference< ov::XHelperInterface > &xParent, const css::uno::Reference< css::uno::XComponentContext > &xContext, const ScVbaPalette &dPalette, const css::uno::Reference< css::text::XSimpleText > &xRange, const css::uno::Any &Start, const css::uno::Any &Length, bool bReplace=false)
css::uno::Reference< css::text::XSimpleText > m_xSimpleText
InheritedHelperInterfaceWeakImpl< ov::excel::XCharacters > ScVbaCharacters_BASE
virtual void SAL_CALL setText(const OUString &_text) override
virtual void SAL_CALL Delete() override
virtual OUString getServiceImplName() override
virtual OUString SAL_CALL getText() override
virtual void SAL_CALL setCaption(const OUString &_caption) override
virtual ::sal_Int32 SAL_CALL getCount() override
virtual css::uno::Sequence< OUString > getServiceNames() override
virtual OUString SAL_CALL getCaption() override
virtual void SAL_CALL setFont(const css::uno::Reference< ov::excel::XFont > &_font) override
virtual css::uno::Reference< ov::excel::XFont > SAL_CALL getFont() override
ScVbaPalette m_aPalette
virtual void SAL_CALL Insert(const OUString &String) override
css::uno::Reference< css::text::XTextRange > m_xTextRange