tdf#130857 qt weld: Implement QtInstanceWidget::strip_mnemonic
[LibreOffice.git] / include / svx / sdr / contact / viewcontactofsdrobj.hxx
blob788c8058d9f51ce8cf3f42031559773cb8929ffe
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 .
20 #ifndef INCLUDED_SVX_SDR_CONTACT_VIEWCONTACTOFSDROBJ_HXX
21 #define INCLUDED_SVX_SDR_CONTACT_VIEWCONTACTOFSDROBJ_HXX
23 #include <sal/types.h>
24 #include <svx/sdr/contact/viewcontact.hxx>
25 #include <svx/svxdllapi.h>
27 class SdrObject;
29 namespace sdr::contact {
31 class SVXCORE_DLLPUBLIC ViewContactOfSdrObj : public ViewContact
33 protected:
34 // the owner of this ViewContact. Set from constructor and not
35 // to be changed in any way.
36 SdrObject& mrObject;
38 // Create an Object-Specific ViewObjectContact, set ViewContact and
39 // ObjectContact. Always needs to return something.
40 virtual ViewObjectContact& CreateObjectSpecificViewObjectContact(ObjectContact& rObjectContact) override;
42 public:
43 // access to SdrObject
44 SdrObject& GetSdrObject() const
46 return mrObject;
49 // basic constructor, used from SdrObject.
50 explicit ViewContactOfSdrObj(SdrObject& rObj);
51 virtual ~ViewContactOfSdrObj() override;
53 // Access to possible sub-hierarchy
54 virtual sal_uInt32 GetObjectCount() const override;
55 virtual ViewContact& GetViewContact(sal_uInt32 nIndex) const override;
56 virtual ViewContact* GetParentContact() const override;
58 // React on changes of the object of this ViewContact
59 virtual void ActionChanged() override;
61 /// override for accessing the SdrObject
62 virtual SdrObject* TryToGetSdrObject() const override;
65 // primitive stuff
67 // add Gluepoints (if available)
68 virtual drawinglayer::primitive2d::Primitive2DContainer createGluePointPrimitive2DSequence() const override;
70 // allow embedding if needed (e.g. for SdrObjects, evtl. Name, Title and description get added). This
71 // is a helper normally used from getViewIndependentPrimitive2DContainer(), but there is one exception
72 // for 3D scenes
73 virtual drawinglayer::primitive2d::Primitive2DContainer embedToObjectSpecificInformation(drawinglayer::primitive2d::Primitive2DContainer aSource) const override;
78 #endif // INCLUDED_SVX_SDR_CONTACT_VIEWCONTACTOFSDROBJ_HXX
80 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */