1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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 #include <svx/sdr/properties/connectorproperties.hxx>
21 #include <svl/itemset.hxx>
22 #include <svl/style.hxx>
23 #include <svx/svddef.hxx>
24 #include <editeng/eeitem.hxx>
25 #include <svx/svdoedge.hxx>
27 //////////////////////////////////////////////////////////////////////////////
33 // create a new itemset
34 SfxItemSet
& ConnectorProperties::CreateObjectSpecificItemSet(SfxItemPool
& rPool
)
36 return *(new SfxItemSet(rPool
,
38 // range from SdrAttrObj
39 SDRATTR_START
, SDRATTR_SHADOW_LAST
,
40 SDRATTR_MISC_FIRST
, SDRATTR_MISC_LAST
,
41 SDRATTR_TEXTDIRECTION
, SDRATTR_TEXTDIRECTION
,
43 // range from SdrEdgeObj
44 SDRATTR_EDGE_FIRST
, SDRATTR_EDGE_LAST
,
46 // range from SdrTextObj
47 EE_ITEMS_START
, EE_ITEMS_END
,
53 ConnectorProperties::ConnectorProperties(SdrObject
& rObj
)
54 : TextProperties(rObj
)
58 ConnectorProperties::ConnectorProperties(const ConnectorProperties
& rProps
, SdrObject
& rObj
)
59 : TextProperties(rProps
, rObj
)
63 ConnectorProperties::~ConnectorProperties()
67 BaseProperties
& ConnectorProperties::Clone(SdrObject
& rObj
) const
69 return *(new ConnectorProperties(*this, rObj
));
72 void ConnectorProperties::ItemSetChanged(const SfxItemSet
& rSet
)
74 SdrEdgeObj
& rObj
= (SdrEdgeObj
&)GetSdrObject();
77 TextProperties::ItemSetChanged(rSet
);
80 rObj
.ImpSetAttrToEdgeInfo();
83 void ConnectorProperties::SetStyleSheet(SfxStyleSheet
* pNewStyleSheet
, sal_Bool bDontRemoveHardAttr
)
85 SdrEdgeObj
& rObj
= (SdrEdgeObj
&)GetSdrObject();
88 TextProperties::SetStyleSheet(pNewStyleSheet
, bDontRemoveHardAttr
);
91 rObj
.ImpSetAttrToEdgeInfo();
93 } // end of namespace properties
94 } // end of namespace sdr
96 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */