LibreOffice Module forms (master) 1
richtextengine.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#pragma once
20
21#include <editeng/editeng.hxx>
22#include <tools/link.hxx>
23
24#include <vector>
25
26class SfxItemPool;
27class EditStatus;
28
29namespace frm
30{
31
33 {
34 public:
35 virtual void EditEngineStatusChanged( const EditStatus& _rStatus ) = 0;
36
37 protected:
39 };
40
41 class RichTextEngine final : public EditEngine
42 {
43 private:
44 ::std::vector< IEngineStatusListener* > m_aStatusListeners;
45
46 public:
47 static RichTextEngine* Create();
49
50 virtual ~RichTextEngine( ) override;
51
52 // for multiplexing the StatusChanged events of the edit engine
54 void revokeEngineStatusListener( IEngineStatusListener const * _pListener );
55
56 private:
59 explicit RichTextEngine( SfxItemPool* _pPool );
60
61 RichTextEngine( const RichTextEngine& ) = delete;
63
64 DECL_LINK( EditEngineStatusChanged, EditStatus&, void );
65 };
66
67
68} // namespace frm
69
70
71/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual void EditEngineStatusChanged(const EditStatus &_rStatus)=0
RichTextEngine(SfxItemPool *_pPool)
constructs a new RichTextEngine.
RichTextEngine(const RichTextEngine &)=delete
void revokeEngineStatusListener(IEngineStatusListener const *_pListener)
RichTextEngine & operator=(const RichTextEngine &)=delete
static RichTextEngine * Create()
DECL_LINK(EditEngineStatusChanged, EditStatus &, void)
void registerEngineStatusListener(IEngineStatusListener *_pListener)
::std::vector< IEngineStatusListener * > m_aStatusListeners
RichTextEngine * Clone()
virtual ~RichTextEngine() override
ListBox is a bit confusing / different from other form components, so here are a few notes:
Definition: BaseListBox.hxx:25