Bump version to 6.4-15
[LibreOffice.git] / include / svx / sdr / contact / viewobjectcontactofsdrobj.hxx
blobcb7773c716f35d5b69a6930857e533cce33a559d
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_VIEWOBJECTCONTACTOFSDROBJ_HXX
21 #define INCLUDED_SVX_SDR_CONTACT_VIEWOBJECTCONTACTOFSDROBJ_HXX
23 #include <svx/sdr/contact/viewobjectcontact.hxx>
24 #include <boost/optional.hpp>
26 class SdrObject;
27 class SdrLayerIDSet;
28 class OutputDevice;
30 namespace sdr { namespace contact {
32 class SVX_DLLPUBLIC ViewObjectContactOfSdrObj : public ViewObjectContact
34 /** Test whether the primitive is visible on any layer from @c aLayers
36 This should be overridden by ViewObjectContacts of SDR classes
37 that have subparts which can be on different layers (that is,
38 SdrObjGroup .-)
40 virtual bool isPrimitiveVisibleOnAnyLayer(const SdrLayerIDSet& aLayers) const;
42 protected:
43 const SdrObject& getSdrObject() const;
45 public:
46 ViewObjectContactOfSdrObj(ObjectContact& rObjectContact, ViewContact& rViewContact);
47 virtual ~ViewObjectContactOfSdrObj() override;
49 virtual bool isPrimitiveVisible(const DisplayInfo& rDisplayInfo) const override;
51 /** retrieves the device which a PageView belongs to, starting from its ObjectContactOfPageView
53 Since #i72752#, the PaintWindow (and thus the OutputDevice) associated with a PageView is not
54 constant over its lifetime. Instead, during some paint operations, the PaintWindow/OutputDevice
55 might be temporarily patched.
57 This method cares for this, by retrieving the very original OutputDevice.
59 boost::optional<const OutputDevice&> getPageViewOutputDevice() const;
64 #endif // INCLUDED_SVX_SDR_CONTACT_VIEWOBJECTCONTACTOFSDROBJ_HXX
66 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */