nss: upgrade to release 3.73
[LibreOffice.git] / sw / source / core / inc / notxtfrm.hxx
blob4e67a547956126d1af064458da7083480137a8e8
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_SW_SOURCE_CORE_INC_NOTXTFRM_HXX
20 #define INCLUDED_SW_SOURCE_CORE_INC_NOTXTFRM_HXX
22 #include "cntfrm.hxx"
23 #include <node.hxx>
24 // MM02
25 #include <svx/sdr/contact/viewcontact.hxx>
27 class SwNoTextNode;
28 class OutputDevice;
29 class SwBorderAttrs;
30 struct SwCursorMoveState;
32 class SwNoTextFrame: public SwContentFrame
34 private:
35 friend void FrameFinit();
36 const Size& GetSize() const;
38 void Format ( vcl::RenderContext* pRenderContext, const SwBorderAttrs *pAttrs = nullptr ) override;
39 void PaintPicture( vcl::RenderContext*, const SwRect& ) const;
41 virtual void DestroyImpl() override;
42 virtual ~SwNoTextFrame() override;
44 // RotateFlyFrame3 add TransformableSwFrame
45 std::unique_ptr< TransformableSwFrame > mpTransformableSwFrame;
47 // RotateFlyFrame3 - Support for inner frame of a SwGrfNode.
48 // Only for local data extraction. To uniquely access information
49 // for local transformation, use getFrameArea(Print)Transformation.
50 friend double getLocalFrameRotation_from_SwNoTextFrame(const SwNoTextFrame& rNoTextFrame);
51 double getLocalFrameRotation() const;
53 void ClearCache();
55 // MM02
56 std::unique_ptr<sdr::contact::ViewContact> mpViewContact;
57 sdr::contact::ViewContact& GetViewContact() const;
58 void OnGraphicArrived();
60 protected:
61 virtual void MakeAll(vcl::RenderContext* pRenderContext) override;
62 virtual void SwClientNotify(const SwModify&, const SfxHint&) override;
64 public:
65 SwNoTextFrame( SwNoTextNode * const, SwFrame* );
67 const SwContentNode *GetNode() const
68 { return static_cast<SwContentNode const*>(GetDep()); }
69 SwContentNode *GetNode()
70 { return static_cast<SwContentNode *>(GetDep()); }
72 virtual bool LeftMargin(SwPaM *) const override;
73 virtual bool RightMargin(SwPaM *, bool bAPI = false) const override;
75 virtual void PaintSwFrame( vcl::RenderContext& rRenderContext, SwRect const&,
76 SwPrintData const*const pPrintData = nullptr ) const override;
77 virtual bool GetCharRect( SwRect &, const SwPosition&,
78 SwCursorMoveState* = nullptr, bool bAllowFarAway = true ) const override;
79 virtual bool GetModelPositionForViewPoint(SwPosition* pPos, Point& aPoint,
80 SwCursorMoveState* = nullptr, bool bTestBackground = false) const override;
82 void GetGrfArea( SwRect &rRect, SwRect * ) const;
84 bool IsTransparent() const;
86 void StopAnimation( const OutputDevice* = nullptr ) const;
87 bool HasAnimation() const;
89 // RotateFlyFrame3 - Support for Transformations
90 bool isTransformableSwFrame() const { return bool(mpTransformableSwFrame); }
91 TransformableSwFrame* getTransformableSwFrame() { return mpTransformableSwFrame.get(); }
92 const TransformableSwFrame* getTransformableSwFrame() const { return mpTransformableSwFrame.get(); }
94 // RotateFlyFrame3 - Support for Transformations
95 virtual basegfx::B2DHomMatrix getFrameAreaTransformation() const override;
96 virtual basegfx::B2DHomMatrix getFramePrintAreaTransformation() const override;
98 // RotateFlyFrame3 - Support for Transformations
99 virtual void transform_translate(const Point& rOffset) override;
102 #endif
104 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */