summaryrefslogtreecommitdiff
path: root/svx/source/customshapes
diff options
context:
space:
mode:
authorKurt Zenker <kz@openoffice.org>2004-06-28 15:19:31 +0000
committerKurt Zenker <kz@openoffice.org>2004-06-28 15:19:31 +0000
commit9ac5f06003b56e714a2b1e0b529a7d228ebf4dfa (patch)
tree48fd0a057cc2d8a76f8b3fe3037e4974d712ba07 /svx/source/customshapes
parent0be4cba6b9d35cde72ad20c518f03106db6e6376 (diff)
INTEGRATION: CWS impress14ea (1.2.132); FILE MERGED
2004/06/17 16:27:41 sj 1.2.132.1: #114297# added gluepoint support for customshapes
Diffstat (limited to 'svx/source/customshapes')
-rw-r--r--svx/source/customshapes/EnhancedCustomShapeGeometry.cxx27
-rw-r--r--svx/source/customshapes/EnhancedCustomShapeGeometry.hxx5
2 files changed, 28 insertions, 4 deletions
diff --git a/svx/source/customshapes/EnhancedCustomShapeGeometry.cxx b/svx/source/customshapes/EnhancedCustomShapeGeometry.cxx
index de841dc95c6d..8fa67fa208f7 100644
--- a/svx/source/customshapes/EnhancedCustomShapeGeometry.cxx
+++ b/svx/source/customshapes/EnhancedCustomShapeGeometry.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: EnhancedCustomShapeGeometry.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: rt $ $Date: 2004-04-02 14:04:29 $
+ * last change: $Author: kz $ $Date: 2004-06-28 16:19:17 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -62,6 +62,9 @@
#ifndef _ENHANCEDCUSTOMSHAPEGEOMETRY_HXX
#include "EnhancedCustomShapeGeometry.hxx"
#endif
+#ifndef _DRAFTS_COM_SUN_STAR_DRAWING_ENHANCEDCUSTOMSHAPEGLUEPOINTTYPE_HPP_
+#include <drafts/com/sun/star/drawing/EnhancedCustomShapeGluePointType.hpp>
+#endif
/*
static const SvxMSDffVertPair Vert[] =
@@ -5330,6 +5333,26 @@ const sal_Bool IsCustomShapeFilledByDefault( MSO_SPT eSpType )
bIsFilledByDefault = ( mso_DefaultFillingTable[ i >> 4 ] & ( 1 << ( i & 0xf ) ) ) == 0;
return bIsFilledByDefault;
}
+const sal_Int16 GetCustomShapeConnectionTypeDefault( MSO_SPT eSpType )
+{
+ sal_Int16 nGluePointType = drafts::com::sun::star::drawing::EnhancedCustomShapeGluePointType::SEGMENTS;
+ const mso_CustomShape* pDefCustomShape = GetCustomShapeContent( eSpType );
+ if ( pDefCustomShape && pDefCustomShape->nGluePoints )
+ nGluePointType = drafts::com::sun::star::drawing::EnhancedCustomShapeGluePointType::CUSTOM;
+ else
+ {
+ switch( eSpType )
+ {
+ case mso_sptRectangle :
+ case mso_sptPictureFrame :
+ case mso_sptFlowChartProcess :
+ case mso_sptTextPlainText :
+ case mso_sptTextBox :
+ nGluePointType = drafts::com::sun::star::drawing::EnhancedCustomShapeGluePointType::RECT;
+ }
+ }
+ return nGluePointType;
+}
static const sal_uInt16 msoSortFilledObjectsToBackTable[] =
{
0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0400, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000
diff --git a/svx/source/customshapes/EnhancedCustomShapeGeometry.hxx b/svx/source/customshapes/EnhancedCustomShapeGeometry.hxx
index 26c83b61c6cd..5d45312068a8 100644
--- a/svx/source/customshapes/EnhancedCustomShapeGeometry.hxx
+++ b/svx/source/customshapes/EnhancedCustomShapeGeometry.hxx
@@ -2,9 +2,9 @@
*
* $RCSfile: EnhancedCustomShapeGeometry.hxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: rt $ $Date: 2004-04-02 14:04:40 $
+ * last change: $Author: kz $ $Date: 2004-06-28 16:19:31 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -134,6 +134,7 @@ struct mso_CustomShape
const sal_Bool SortFilledObjectsToBackByDefault( MSO_SPT eSpType );
const sal_Bool IsCustomShapeFilledByDefault( MSO_SPT eSpType );
+const sal_Int16 GetCustomShapeConnectionTypeDefault( MSO_SPT eSpType );
const mso_CustomShape* GetCustomShapeContent( MSO_SPT eSpType );
#endif