2010-10-12 15:53:47 +02:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2012-11-21 22:06:52 +00:00
|
|
|
/*
|
|
|
|
* This file is part of the LibreOffice project.
|
2004-04-02 13:13:28 +00:00
|
|
|
*
|
2012-11-21 22:06:52 +00:00
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
2004-04-02 13:13:28 +00:00
|
|
|
*
|
2012-11-21 22:06:52 +00:00
|
|
|
* This file incorporates work covered by the following license notice:
|
2004-04-02 13:13:28 +00:00
|
|
|
*
|
2012-11-21 22:06:52 +00:00
|
|
|
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
* contributor license agreements. See the NOTICE file distributed
|
|
|
|
* with this work for additional information regarding copyright
|
|
|
|
* ownership. The ASF licenses this file to you under the Apache
|
|
|
|
* License, Version 2.0 (the "License"); you may not use this file
|
|
|
|
* except in compliance with the License. You may obtain a copy of
|
|
|
|
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
|
|
|
*/
|
2006-09-17 04:53:22 +00:00
|
|
|
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/svdoashp.hxx>
|
2010-04-20 15:55:51 +02:00
|
|
|
#include "svx/unoapi.hxx"
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/unoshape.hxx>
|
2004-04-02 13:13:28 +00:00
|
|
|
#include <ucbhelper/content.hxx>
|
|
|
|
#include <unotools/datetime.hxx>
|
2004-10-04 16:54:06 +00:00
|
|
|
#include <sfx2/lnkbase.hxx>
|
2004-04-02 13:13:28 +00:00
|
|
|
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
|
|
|
|
#include <com/sun/star/drawing/XShape.hpp>
|
2005-03-01 18:10:56 +00:00
|
|
|
#include <com/sun/star/drawing/XCustomShapeEngine.hpp>
|
2004-04-02 13:13:28 +00:00
|
|
|
#include <com/sun/star/drawing/PolyPolygonBezierCoords.hpp>
|
|
|
|
#include <com/sun/star/beans/PropertyValue.hpp>
|
|
|
|
#include <com/sun/star/awt/Rectangle.hpp>
|
|
|
|
#include <comphelper/processfactory.hxx>
|
2009-10-16 00:05:16 +02:00
|
|
|
#include <svl/urihelper.hxx>
|
2004-04-02 13:13:28 +00:00
|
|
|
#include <com/sun/star/uno/Sequence.h>
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/svdogrp.hxx>
|
2012-07-01 01:06:04 +02:00
|
|
|
#include <tools/helpers.hxx>
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/svddrag.hxx>
|
|
|
|
#include <svx/xpool.hxx>
|
|
|
|
#include <svx/xpoly.hxx>
|
2014-07-10 20:56:43 +02:00
|
|
|
#include <svx/svddrgmt.hxx>
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/svdmodel.hxx>
|
|
|
|
#include <svx/svdpage.hxx>
|
2010-04-20 15:55:51 +02:00
|
|
|
#include "svx/svditer.hxx"
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/svdobj.hxx>
|
|
|
|
#include <svx/svdtrans.hxx>
|
|
|
|
#include <svx/svdetc.hxx>
|
2013-10-22 15:58:57 +03:00
|
|
|
#include <svx/svdoedge.hxx>
|
2014-05-06 14:35:49 +03:00
|
|
|
#include "svdglob.hxx"
|
2013-10-22 15:58:57 +03:00
|
|
|
#include "svx/svdstr.hrc"
|
2010-01-07 18:52:36 +01:00
|
|
|
#include <editeng/eeitem.hxx>
|
|
|
|
#include "editeng/editstat.hxx"
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/svdoutl.hxx>
|
2010-01-07 18:52:36 +01:00
|
|
|
#include <editeng/outlobj.hxx>
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/sdtfchim.hxx>
|
2013-04-18 18:26:28 +02:00
|
|
|
#include "svx/EnhancedCustomShapeGeometry.hxx"
|
|
|
|
#include "svx/EnhancedCustomShapeTypeNames.hxx"
|
|
|
|
#include "svx/EnhancedCustomShape2d.hxx"
|
2004-11-26 13:29:31 +00:00
|
|
|
#include <com/sun/star/beans/PropertyValues.hpp>
|
2005-03-01 18:10:56 +00:00
|
|
|
#include <com/sun/star/drawing/EnhancedCustomShapeAdjustmentValue.hpp>
|
|
|
|
#include <com/sun/star/drawing/EnhancedCustomShapeParameterPair.hpp>
|
|
|
|
#include <com/sun/star/drawing/EnhancedCustomShapeTextFrame.hpp>
|
|
|
|
#include <com/sun/star/drawing/EnhancedCustomShapeSegment.hpp>
|
|
|
|
#include <com/sun/star/drawing/EnhancedCustomShapeSegmentCommand.hpp>
|
2010-01-07 18:52:36 +01:00
|
|
|
#include <editeng/writingmodeitem.hxx>
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/xlnclit.hxx>
|
|
|
|
#include <svx/svxids.hrc>
|
2009-10-16 00:05:16 +02:00
|
|
|
#include <svl/whiter.hxx>
|
2014-05-06 14:52:33 +03:00
|
|
|
#include <sdr/properties/customshapeproperties.hxx>
|
|
|
|
#include <sdr/contact/viewcontactofsdrobjcustomshape.hxx>
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/xlntrit.hxx>
|
|
|
|
#include <svx/xfltrit.hxx>
|
|
|
|
#include <svx/xflclit.hxx>
|
|
|
|
#include <svx/xflgrit.hxx>
|
|
|
|
#include <svx/xflhtit.hxx>
|
|
|
|
#include <svx/xbtmpit.hxx>
|
2004-11-18 10:07:11 +00:00
|
|
|
#include <vcl/bmpacc.hxx>
|
2007-06-27 18:04:40 +00:00
|
|
|
#include <svx/svdview.hxx>
|
2006-11-14 12:44:11 +00:00
|
|
|
#include <basegfx/polygon/b2dpolypolygontools.hxx>
|
|
|
|
#include <basegfx/matrix/b2dhommatrix.hxx>
|
2009-09-22 18:14:05 +02:00
|
|
|
#include <basegfx/matrix/b2dhommatrixtools.hxx>
|
2011-06-21 09:11:28 +02:00
|
|
|
#include <basegfx/tools/unotools.hxx>
|
2012-04-28 22:56:47 +09:00
|
|
|
#include "svdconv.hxx"
|
2014-11-19 10:57:27 -05:00
|
|
|
#include <svdobjplusdata.hxx>
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
using namespace ::com::sun::star;
|
|
|
|
using namespace ::com::sun::star::uno;
|
|
|
|
using namespace ::com::sun::star::lang;
|
|
|
|
using namespace ::com::sun::star::beans;
|
|
|
|
using namespace ::com::sun::star::drawing;
|
|
|
|
|
2011-05-09 13:28:30 +02:00
|
|
|
static void lcl_ShapeSegmentFromBinary( EnhancedCustomShapeSegment& rSegInfo, sal_uInt16 nSDat )
|
|
|
|
{
|
|
|
|
switch( nSDat >> 8 )
|
|
|
|
{
|
|
|
|
case 0x00 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::LINETO;
|
|
|
|
rSegInfo.Count = nSDat & 0xff;
|
|
|
|
if ( !rSegInfo.Count )
|
|
|
|
rSegInfo.Count = 1;
|
|
|
|
break;
|
|
|
|
case 0x20 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::CURVETO;
|
|
|
|
rSegInfo.Count = nSDat & 0xff;
|
|
|
|
if ( !rSegInfo.Count )
|
|
|
|
rSegInfo.Count = 1;
|
|
|
|
break;
|
|
|
|
case 0x40 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::MOVETO;
|
|
|
|
rSegInfo.Count = nSDat & 0xff;
|
|
|
|
if ( !rSegInfo.Count )
|
|
|
|
rSegInfo.Count = 1;
|
|
|
|
break;
|
|
|
|
case 0x60 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::CLOSESUBPATH;
|
|
|
|
rSegInfo.Count = 0;
|
|
|
|
break;
|
|
|
|
case 0x80 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::ENDSUBPATH;
|
|
|
|
rSegInfo.Count = 0;
|
|
|
|
break;
|
|
|
|
case 0xa1 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::ANGLEELLIPSETO;
|
|
|
|
rSegInfo.Count = ( nSDat & 0xff ) / 3;
|
|
|
|
break;
|
|
|
|
case 0xa2 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::ANGLEELLIPSE;
|
|
|
|
rSegInfo.Count = ( nSDat & 0xff ) / 3;
|
|
|
|
break;
|
|
|
|
case 0xa3 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::ARCTO;
|
|
|
|
rSegInfo.Count = ( nSDat & 0xff ) >> 2;
|
|
|
|
break;
|
|
|
|
case 0xa4 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::ARC;
|
|
|
|
rSegInfo.Count = ( nSDat & 0xff ) >> 2;
|
|
|
|
break;
|
|
|
|
case 0xa5 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::CLOCKWISEARCTO;
|
|
|
|
rSegInfo.Count = ( nSDat & 0xff ) >> 2;
|
|
|
|
break;
|
|
|
|
case 0xa6 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::CLOCKWISEARC;
|
|
|
|
rSegInfo.Count = ( nSDat & 0xff ) >> 2;
|
|
|
|
break;
|
|
|
|
case 0xa7 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::ELLIPTICALQUADRANTX;
|
|
|
|
rSegInfo.Count = nSDat & 0xff;
|
|
|
|
break;
|
|
|
|
case 0xa8 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::ELLIPTICALQUADRANTY;
|
|
|
|
rSegInfo.Count = nSDat & 0xff;
|
|
|
|
break;
|
|
|
|
case 0xaa :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::NOFILL;
|
|
|
|
rSegInfo.Count = 0;
|
|
|
|
break;
|
|
|
|
case 0xab :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::NOSTROKE;
|
|
|
|
rSegInfo.Count = 0;
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
case 0xf8 :
|
|
|
|
rSegInfo.Command = EnhancedCustomShapeSegmentCommand::UNKNOWN;
|
|
|
|
rSegInfo.Count = nSDat;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2005-09-28 11:40:42 +00:00
|
|
|
static MSO_SPT ImpGetCustomShapeType( const SdrObjCustomShape& rCustoShape )
|
|
|
|
{
|
|
|
|
MSO_SPT eRetValue = mso_sptNil;
|
|
|
|
|
2015-06-11 14:19:13 +02:00
|
|
|
OUString aEngine( static_cast<const SfxStringItem&>( rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE ) ).GetValue() );
|
2012-04-06 19:49:53 +02:00
|
|
|
if ( aEngine.isEmpty() || aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
OUString sShapeType;
|
|
|
|
const OUString sType( "Type" );
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrCustomShapeGeometryItem& rGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
|
|
|
|
const Any* pAny = rGeometryItem.GetPropertyValueByName( sType );
|
2005-09-28 11:40:42 +00:00
|
|
|
if ( pAny && ( *pAny >>= sShapeType ) )
|
|
|
|
eRetValue = EnhancedCustomShapeTypeNames::Get( sShapeType );
|
|
|
|
}
|
|
|
|
return eRetValue;
|
|
|
|
};
|
|
|
|
|
2013-04-07 23:05:56 +09:00
|
|
|
static bool ImpVerticalSwitch( const SdrObjCustomShape& rCustoShape )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bool bRet = false;
|
2005-09-28 11:40:42 +00:00
|
|
|
MSO_SPT eShapeType( ImpGetCustomShapeType( rCustoShape ) );
|
|
|
|
switch( eShapeType )
|
|
|
|
{
|
|
|
|
case mso_sptAccentBorderCallout90 : // 2 ortho
|
|
|
|
case mso_sptBorderCallout1 : // 2 diag
|
|
|
|
case mso_sptBorderCallout2 : // 3
|
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bRet = true;
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
break;
|
2006-06-19 15:40:23 +00:00
|
|
|
default: break;
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
return bRet;
|
|
|
|
}
|
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
// #i37011# create a clone with all attributes changed to shadow attributes
|
|
|
|
// and translation executed, too.
|
|
|
|
SdrObject* ImpCreateShadowObjectClone(const SdrObject& rOriginal, const SfxItemSet& rOriginalSet)
|
|
|
|
{
|
|
|
|
SdrObject* pRetval = 0L;
|
2014-10-17 10:35:35 +02:00
|
|
|
const bool bShadow(static_cast<const SdrOnOffItem&>(rOriginalSet.Get(SDRATTR_SHADOW)).GetValue());
|
2004-11-18 10:07:11 +00:00
|
|
|
|
|
|
|
if(bShadow)
|
|
|
|
{
|
|
|
|
// create a shadow representing object
|
2014-10-17 10:35:35 +02:00
|
|
|
const sal_Int32 nXDist(static_cast<const SdrMetricItem&>(rOriginalSet.Get(SDRATTR_SHADOWXDIST)).GetValue());
|
|
|
|
const sal_Int32 nYDist(static_cast<const SdrMetricItem&>(rOriginalSet.Get(SDRATTR_SHADOWYDIST)).GetValue());
|
|
|
|
const ::Color aShadowColor(static_cast<const XColorItem&>(rOriginalSet.Get(SDRATTR_SHADOWCOLOR)).GetColorValue());
|
|
|
|
const sal_uInt16 nShadowTransparence(static_cast<const SdrPercentItem&>(rOriginalSet.Get(SDRATTR_SHADOWTRANSPARENCE)).GetValue());
|
2004-11-18 10:07:11 +00:00
|
|
|
pRetval = rOriginal.Clone();
|
|
|
|
DBG_ASSERT(pRetval, "ImpCreateShadowObjectClone: Could not clone object (!)");
|
|
|
|
|
|
|
|
// look for used stuff
|
|
|
|
SdrObjListIter aIterator(rOriginal);
|
2013-04-07 23:05:56 +09:00
|
|
|
bool bLineUsed(false);
|
|
|
|
bool bAllFillUsed(false);
|
|
|
|
bool bSolidFillUsed(false);
|
|
|
|
bool bGradientFillUsed(false);
|
|
|
|
bool bHatchFillUsed(false);
|
|
|
|
bool bBitmapFillUsed(false);
|
2004-11-18 10:07:11 +00:00
|
|
|
|
|
|
|
while(aIterator.IsMore())
|
|
|
|
{
|
|
|
|
SdrObject* pObj = aIterator.Next();
|
2014-10-17 10:35:35 +02:00
|
|
|
drawing::FillStyle eFillStyle = static_cast<const XFillStyleItem&>(pObj->GetMergedItem(XATTR_FILLSTYLE)).GetValue();
|
2004-11-18 10:07:11 +00:00
|
|
|
|
|
|
|
if(!bLineUsed)
|
|
|
|
{
|
2014-11-21 20:48:11 +02:00
|
|
|
drawing::LineStyle eLineStyle = static_cast<const XLineStyleItem&>(pObj->GetMergedItem(XATTR_LINESTYLE)).GetValue();
|
2004-11-18 10:07:11 +00:00
|
|
|
|
2014-11-21 20:48:11 +02:00
|
|
|
if(drawing::LineStyle_NONE != eLineStyle)
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bLineUsed = true;
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if(!bAllFillUsed)
|
|
|
|
{
|
2014-07-18 18:07:36 +02:00
|
|
|
if(!bSolidFillUsed && drawing::FillStyle_SOLID == eFillStyle)
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bSolidFillUsed = true;
|
2013-03-25 23:02:47 +01:00
|
|
|
bAllFillUsed = (bSolidFillUsed && bGradientFillUsed && bHatchFillUsed && bBitmapFillUsed);
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
2014-07-18 18:07:36 +02:00
|
|
|
if(!bGradientFillUsed && drawing::FillStyle_GRADIENT == eFillStyle)
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bGradientFillUsed = true;
|
2013-03-25 23:02:47 +01:00
|
|
|
bAllFillUsed = (bSolidFillUsed && bGradientFillUsed && bHatchFillUsed && bBitmapFillUsed);
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
2014-07-18 18:07:36 +02:00
|
|
|
if(!bHatchFillUsed && drawing::FillStyle_HATCH == eFillStyle)
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bHatchFillUsed = true;
|
2013-03-25 23:02:47 +01:00
|
|
|
bAllFillUsed = (bSolidFillUsed && bGradientFillUsed && bHatchFillUsed && bBitmapFillUsed);
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
2014-07-18 18:07:36 +02:00
|
|
|
if(!bBitmapFillUsed && drawing::FillStyle_BITMAP == eFillStyle)
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bBitmapFillUsed = true;
|
2013-03-25 23:02:47 +01:00
|
|
|
bAllFillUsed = (bSolidFillUsed && bGradientFillUsed && bHatchFillUsed && bBitmapFillUsed);
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// translate to shadow coordinates
|
|
|
|
pRetval->NbcMove(Size(nXDist, nYDist));
|
|
|
|
|
|
|
|
// set items as needed
|
|
|
|
SfxItemSet aTempSet(rOriginalSet);
|
|
|
|
|
2011-05-09 13:28:30 +02:00
|
|
|
// if a SvxWritingModeItem (Top->Bottom) is set the text object
|
2005-01-27 15:16:54 +00:00
|
|
|
// is creating a paraobject, but paraobjects can not be created without model. So
|
|
|
|
// we are preventing the crash by setting the writing mode always left to right,
|
|
|
|
// this is not bad since our shadow geometry does not contain text.
|
2007-05-10 13:58:14 +00:00
|
|
|
aTempSet.Put( SvxWritingModeItem( com::sun::star::text::WritingMode_LR_TB, SDRATTR_TEXTDIRECTION ) );
|
2005-01-27 15:16:54 +00:00
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
// no shadow
|
2014-08-05 08:59:37 +02:00
|
|
|
aTempSet.Put(makeSdrShadowItem(false));
|
2014-08-18 10:55:03 +02:00
|
|
|
aTempSet.Put(makeSdrShadowXDistItem(0L));
|
|
|
|
aTempSet.Put(makeSdrShadowYDistItem(0L));
|
2004-11-18 10:07:11 +00:00
|
|
|
|
2012-02-02 11:40:51 +01:00
|
|
|
// line color and transparency like shadow
|
2004-11-18 10:07:11 +00:00
|
|
|
if(bLineUsed)
|
|
|
|
{
|
2013-09-20 09:49:51 +02:00
|
|
|
aTempSet.Put(XLineColorItem(OUString(), aShadowColor));
|
2004-11-18 10:07:11 +00:00
|
|
|
aTempSet.Put(XLineTransparenceItem(nShadowTransparence));
|
|
|
|
}
|
|
|
|
|
2012-02-02 11:40:51 +01:00
|
|
|
// fill color and transparency like shadow
|
2004-11-18 10:07:11 +00:00
|
|
|
if(bSolidFillUsed)
|
|
|
|
{
|
2013-09-20 09:49:51 +02:00
|
|
|
aTempSet.Put(XFillColorItem(OUString(), aShadowColor));
|
2004-11-18 10:07:11 +00:00
|
|
|
aTempSet.Put(XFillTransparenceItem(nShadowTransparence));
|
|
|
|
}
|
|
|
|
|
2012-02-02 11:40:51 +01:00
|
|
|
// gradient and transparency like shadow
|
2004-11-18 10:07:11 +00:00
|
|
|
if(bGradientFillUsed)
|
|
|
|
{
|
2014-10-17 10:35:35 +02:00
|
|
|
XGradient aGradient(static_cast<const XFillGradientItem&>(rOriginalSet.Get(XATTR_FILLGRADIENT)).GetGradientValue());
|
2004-11-18 10:07:11 +00:00
|
|
|
sal_uInt8 nStartLuminance(aGradient.GetStartColor().GetLuminance());
|
|
|
|
sal_uInt8 nEndLuminance(aGradient.GetEndColor().GetLuminance());
|
|
|
|
|
|
|
|
if(aGradient.GetStartIntens() != 100)
|
|
|
|
{
|
|
|
|
nStartLuminance = (sal_uInt8)(nStartLuminance * ((double)aGradient.GetStartIntens() / 100.0));
|
|
|
|
}
|
|
|
|
|
|
|
|
if(aGradient.GetEndIntens() != 100)
|
|
|
|
{
|
|
|
|
nEndLuminance = (sal_uInt8)(nEndLuminance * ((double)aGradient.GetEndIntens() / 100.0));
|
|
|
|
}
|
|
|
|
|
2006-03-29 11:30:07 +00:00
|
|
|
::Color aStartColor(
|
2004-11-18 10:07:11 +00:00
|
|
|
(sal_uInt8)((nStartLuminance * aShadowColor.GetRed()) / 256),
|
|
|
|
(sal_uInt8)((nStartLuminance * aShadowColor.GetGreen()) / 256),
|
|
|
|
(sal_uInt8)((nStartLuminance * aShadowColor.GetBlue()) / 256));
|
|
|
|
|
2006-03-29 11:30:07 +00:00
|
|
|
::Color aEndColor(
|
2004-11-18 10:07:11 +00:00
|
|
|
(sal_uInt8)((nEndLuminance * aShadowColor.GetRed()) / 256),
|
|
|
|
(sal_uInt8)((nEndLuminance * aShadowColor.GetGreen()) / 256),
|
|
|
|
(sal_uInt8)((nEndLuminance * aShadowColor.GetBlue()) / 256));
|
|
|
|
|
|
|
|
aGradient.SetStartColor(aStartColor);
|
|
|
|
aGradient.SetEndColor(aEndColor);
|
2011-08-23 22:26:15 -07:00
|
|
|
aTempSet.Put(XFillGradientItem(aGradient));
|
2004-11-18 10:07:11 +00:00
|
|
|
aTempSet.Put(XFillTransparenceItem(nShadowTransparence));
|
|
|
|
}
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// hatch and transparency like shadow
|
2004-11-18 10:07:11 +00:00
|
|
|
if(bHatchFillUsed)
|
|
|
|
{
|
2014-10-17 10:35:35 +02:00
|
|
|
XHatch aHatch(static_cast<const XFillHatchItem&>(rOriginalSet.Get(XATTR_FILLHATCH)).GetHatchValue());
|
2004-11-18 10:07:11 +00:00
|
|
|
aHatch.SetColor(aShadowColor);
|
|
|
|
aTempSet.Put(XFillHatchItem(aTempSet.GetPool(), aHatch));
|
|
|
|
aTempSet.Put(XFillTransparenceItem(nShadowTransparence));
|
|
|
|
}
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// bitmap and transparency like shadow
|
2004-11-18 10:07:11 +00:00
|
|
|
if(bBitmapFillUsed)
|
|
|
|
{
|
2014-10-17 10:35:35 +02:00
|
|
|
GraphicObject aGraphicObject(static_cast<const XFillBitmapItem&>(rOriginalSet.Get(XATTR_FILLBITMAP)).GetGraphicObject());
|
2012-05-10 09:29:55 +00:00
|
|
|
const BitmapEx aBitmapEx(aGraphicObject.GetGraphic().GetBitmapEx());
|
|
|
|
Bitmap aBitmap(aBitmapEx.GetBitmap());
|
2004-11-18 10:07:11 +00:00
|
|
|
|
2012-05-10 09:29:55 +00:00
|
|
|
if(!aBitmap.IsEmpty())
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
2012-05-10 09:29:55 +00:00
|
|
|
BitmapReadAccess* pReadAccess = aBitmap.AcquireReadAccess();
|
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
if(pReadAccess)
|
|
|
|
{
|
2012-05-10 09:29:55 +00:00
|
|
|
Bitmap aDestBitmap(aBitmap.GetSizePixel(), 24L);
|
2004-11-18 10:07:11 +00:00
|
|
|
BitmapWriteAccess* pWriteAccess = aDestBitmap.AcquireWriteAccess();
|
|
|
|
|
|
|
|
if(pWriteAccess)
|
|
|
|
{
|
2015-05-28 15:44:10 +02:00
|
|
|
for(long y(0L); y < pReadAccess->Height(); y++)
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
2015-05-28 15:44:10 +02:00
|
|
|
for(long x(0L); x < pReadAccess->Width(); x++)
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
|
|
|
sal_uInt16 nLuminance((sal_uInt16)pReadAccess->GetLuminance(y, x) + 1);
|
|
|
|
const BitmapColor aDestColor(
|
|
|
|
(sal_uInt8)((nLuminance * (sal_uInt16)aShadowColor.GetRed()) >> 8L),
|
|
|
|
(sal_uInt8)((nLuminance * (sal_uInt16)aShadowColor.GetGreen()) >> 8L),
|
|
|
|
(sal_uInt8)((nLuminance * (sal_uInt16)aShadowColor.GetBlue()) >> 8L));
|
|
|
|
pWriteAccess->SetPixel(y, x, aDestColor);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-04-01 16:23:59 +02:00
|
|
|
Bitmap::ReleaseAccess(pWriteAccess);
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
|
2015-04-01 16:23:59 +02:00
|
|
|
Bitmap::ReleaseAccess(pReadAccess);
|
2012-05-10 09:29:55 +00:00
|
|
|
|
|
|
|
if(aBitmapEx.IsTransparent())
|
|
|
|
{
|
|
|
|
if(aBitmapEx.IsAlpha())
|
|
|
|
{
|
|
|
|
aGraphicObject.SetGraphic(Graphic(BitmapEx(aDestBitmap, aBitmapEx.GetAlpha())));
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
aGraphicObject.SetGraphic(Graphic(BitmapEx(aDestBitmap, aBitmapEx.GetMask())));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
aGraphicObject.SetGraphic(Graphic(aDestBitmap));
|
|
|
|
}
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2012-05-10 09:29:55 +00:00
|
|
|
aTempSet.Put(XFillBitmapItem(aTempSet.GetPool(), aGraphicObject));
|
2004-11-18 10:07:11 +00:00
|
|
|
aTempSet.Put(XFillTransparenceItem(nShadowTransparence));
|
|
|
|
}
|
|
|
|
|
|
|
|
// set attributes and paint shadow object
|
2005-04-12 15:54:41 +00:00
|
|
|
pRetval->SetMergedItemSet( aTempSet );
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
return pRetval;
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
|
2012-12-18 08:00:17 +01:00
|
|
|
Reference< XCustomShapeEngine > SdrObjCustomShape::GetCustomShapeEngine() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2012-12-18 08:00:17 +01:00
|
|
|
if (mxCustomShapeEngine.is())
|
|
|
|
return mxCustomShapeEngine;
|
|
|
|
|
2015-06-11 14:19:13 +02:00
|
|
|
OUString aEngine(static_cast<const SfxStringItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue());
|
2013-09-04 13:43:19 +02:00
|
|
|
if ( aEngine.isEmpty() )
|
|
|
|
aEngine = "com.sun.star.drawing.EnhancedCustomShapeEngine";
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2013-03-08 14:06:05 +02:00
|
|
|
Reference< XComponentContext > xContext( ::comphelper::getProcessComponentContext() );
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2012-12-18 08:00:17 +01:00
|
|
|
Reference< XShape > aXShape = GetXShapeForSdrObject(const_cast<SdrObjCustomShape*>(this));
|
2005-04-12 15:54:41 +00:00
|
|
|
if ( aXShape.is() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-05-11 18:18:15 +02:00
|
|
|
Sequence< Any > aArgument( 1 );
|
|
|
|
Sequence< PropertyValue > aPropValues( 1 );
|
|
|
|
aPropValues[ 0 ].Name = "CustomShape";
|
|
|
|
aPropValues[ 0 ].Value <<= aXShape;
|
|
|
|
aArgument[ 0 ] <<= aPropValues;
|
|
|
|
Reference< XInterface > xInterface( xContext->getServiceManager()->createInstanceWithArgumentsAndContext( aEngine, aArgument, xContext ) );
|
|
|
|
if ( xInterface.is() )
|
|
|
|
mxCustomShapeEngine = Reference< XCustomShapeEngine >( xInterface, UNO_QUERY );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2012-12-18 08:00:17 +01:00
|
|
|
|
|
|
|
return mxCustomShapeEngine;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2012-12-18 08:00:17 +01:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
const SdrObject* SdrObjCustomShape::GetSdrObjectFromCustomShape() const
|
|
|
|
{
|
2004-10-12 13:17:22 +00:00
|
|
|
if ( !mXRenderedCustomShape.is() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2012-12-18 08:00:17 +01:00
|
|
|
Reference< XCustomShapeEngine > xCustomShapeEngine( GetCustomShapeEngine() );
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( xCustomShapeEngine.is() )
|
2014-07-11 09:19:59 +02:00
|
|
|
const_cast<SdrObjCustomShape*>(this)->mXRenderedCustomShape = xCustomShapeEngine->render();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2004-10-12 13:17:22 +00:00
|
|
|
SdrObject* pRenderedCustomShape = mXRenderedCustomShape.is()
|
|
|
|
? GetSdrObjectFromXShape( mXRenderedCustomShape )
|
|
|
|
: NULL;
|
2004-04-02 13:13:28 +00:00
|
|
|
return pRenderedCustomShape;
|
|
|
|
}
|
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
// #i37011# Shadow geometry creation
|
|
|
|
const SdrObject* SdrObjCustomShape::GetSdrObjectShadowFromCustomShape() const
|
|
|
|
{
|
|
|
|
if(!mpLastShadowGeometry)
|
|
|
|
{
|
|
|
|
const SdrObject* pSdrObject = GetSdrObjectFromCustomShape();
|
|
|
|
if(pSdrObject)
|
|
|
|
{
|
|
|
|
const SfxItemSet& rOriginalSet = GetObjectItemSet();
|
2014-10-17 10:35:35 +02:00
|
|
|
const bool bShadow(static_cast<const SdrOnOffItem&>(rOriginalSet.Get( SDRATTR_SHADOW )).GetValue());
|
2004-11-18 10:07:11 +00:00
|
|
|
|
|
|
|
if(bShadow)
|
|
|
|
{
|
|
|
|
// create a clone with all attributes changed to shadow attributes
|
|
|
|
// and translation executed, too.
|
2014-07-11 09:19:59 +02:00
|
|
|
const_cast<SdrObjCustomShape*>(this)->mpLastShadowGeometry =
|
|
|
|
ImpCreateShadowObjectClone(*pSdrObject, rOriginalSet);
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
return mpLastShadowGeometry;
|
|
|
|
}
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::IsTextPath() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sTextPath( "TextPath" );
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bTextPathOn = false;
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
|
|
|
|
const Any* pAny = rGeometryItem.GetPropertyValueByName( sTextPath, sTextPath );
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= bTextPathOn;
|
|
|
|
return bTextPathOn;
|
|
|
|
}
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::UseNoFillStyle() const
|
2004-10-12 13:17:22 +00:00
|
|
|
{
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bRet = false;
|
2013-04-07 12:06:47 +02:00
|
|
|
OUString sShapeType;
|
|
|
|
const OUString sType( "Type" );
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrCustomShapeGeometryItem& rGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
|
|
|
|
const Any* pAny = rGeometryItem.GetPropertyValueByName( sType );
|
2004-10-12 13:17:22 +00:00
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= sShapeType;
|
2015-04-27 15:29:17 +02:00
|
|
|
bRet = !IsCustomShapeFilledByDefault( EnhancedCustomShapeTypeNames::Get( sType ) );
|
2004-10-12 13:17:22 +00:00
|
|
|
|
|
|
|
return bRet;
|
|
|
|
}
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::IsMirroredX() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bMirroredX = false;
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sMirroredX( "MirroredX" );
|
2004-04-02 13:13:28 +00:00
|
|
|
com::sun::star::uno::Any* pAny = aGeometryItem.GetPropertyValueByName( sMirroredX );
|
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= bMirroredX;
|
|
|
|
return bMirroredX;
|
|
|
|
}
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::IsMirroredY() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bMirroredY = false;
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sMirroredY( "MirroredY" );
|
2004-04-02 13:13:28 +00:00
|
|
|
com::sun::star::uno::Any* pAny = aGeometryItem.GetPropertyValueByName( sMirroredY );
|
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= bMirroredY;
|
|
|
|
return bMirroredY;
|
|
|
|
}
|
2014-03-10 11:09:59 +02:00
|
|
|
void SdrObjCustomShape::SetMirroredX( const bool bMirrorX )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sMirroredX( "MirroredX" );
|
2004-04-02 13:13:28 +00:00
|
|
|
PropertyValue aPropVal;
|
|
|
|
aPropVal.Name = sMirroredX;
|
|
|
|
aPropVal.Value <<= bMirrorX;
|
|
|
|
aGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
SetMergedItem( aGeometryItem );
|
|
|
|
}
|
2014-03-10 11:09:59 +02:00
|
|
|
void SdrObjCustomShape::SetMirroredY( const bool bMirrorY )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sMirroredY( "MirroredY" );
|
2004-04-02 13:13:28 +00:00
|
|
|
PropertyValue aPropVal;
|
|
|
|
aPropVal.Name = sMirroredY;
|
|
|
|
aPropVal.Value <<= bMirrorY;
|
|
|
|
aGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
SetMergedItem( aGeometryItem );
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2012-04-09 18:24:11 +05:30
|
|
|
bool SdrObjCustomShape::IsPostRotate() const
|
|
|
|
{
|
|
|
|
const com::sun::star::uno::Any* pAny;
|
|
|
|
bool bPostRotate = false;
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
|
2012-04-09 18:24:11 +05:30
|
|
|
pAny = rGeometryItem.GetPropertyValueByName( "IsPostRotateAngle" );
|
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= bPostRotate;
|
|
|
|
return bPostRotate;
|
|
|
|
}
|
|
|
|
|
2012-01-11 15:24:27 +05:30
|
|
|
double SdrObjCustomShape::GetExtraTextRotation( const bool bPreRotation ) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
const com::sun::star::uno::Any* pAny;
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sTextRotateAngle( "TextRotateAngle" );
|
|
|
|
const OUString sTextPreRotateAngle( "TextPreRotateAngle" );
|
2012-01-11 15:24:27 +05:30
|
|
|
pAny = rGeometryItem.GetPropertyValueByName( bPreRotation ? sTextPreRotateAngle : sTextRotateAngle );
|
2004-04-02 13:13:28 +00:00
|
|
|
double fExtraTextRotateAngle = 0.0;
|
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= fExtraTextRotateAngle;
|
|
|
|
return fExtraTextRotateAngle;
|
|
|
|
}
|
2012-12-18 08:00:17 +01:00
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::GetTextBounds( Rectangle& rTextBound ) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bRet = false;
|
2012-12-18 08:00:17 +01:00
|
|
|
|
|
|
|
Reference< XCustomShapeEngine > xCustomShapeEngine( GetCustomShapeEngine() );
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( xCustomShapeEngine.is() )
|
|
|
|
{
|
|
|
|
awt::Rectangle aR( xCustomShapeEngine->getTextBounds() );
|
2012-02-27 18:03:21 +05:30
|
|
|
if ( aR.Width > 1 && aR.Height > 1 )
|
2006-08-14 08:39:18 +00:00
|
|
|
{
|
|
|
|
rTextBound = Rectangle( Point( aR.X, aR.Y ), Size( aR.Width, aR.Height ) );
|
2014-03-10 11:09:59 +02:00
|
|
|
bRet = true;
|
2006-08-14 08:39:18 +00:00
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
return bRet;
|
|
|
|
}
|
2014-07-11 09:19:59 +02:00
|
|
|
basegfx::B2DPolyPolygon SdrObjCustomShape::GetLineGeometry( const bool bBezierAllowed ) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2006-11-14 12:44:11 +00:00
|
|
|
basegfx::B2DPolyPolygon aRetval;
|
2014-07-11 09:19:59 +02:00
|
|
|
Reference< XCustomShapeEngine > xCustomShapeEngine( GetCustomShapeEngine() );
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( xCustomShapeEngine.is() )
|
|
|
|
{
|
|
|
|
com::sun::star::drawing::PolyPolygonBezierCoords aBezierCoords = xCustomShapeEngine->getLineGeometry();
|
|
|
|
try
|
|
|
|
{
|
2011-06-21 09:11:28 +02:00
|
|
|
aRetval = basegfx::unotools::polyPolygonBezierToB2DPolyPolygon( aBezierCoords );
|
2007-07-18 09:57:06 +00:00
|
|
|
if ( !bBezierAllowed && aRetval.areControlPointsUsed())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2006-11-14 12:44:11 +00:00
|
|
|
aRetval = basegfx::tools::adaptiveSubdivideByAngle(aRetval);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
2012-01-06 00:03:58 +09:00
|
|
|
catch ( const com::sun::star::lang::IllegalArgumentException & )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
2006-11-14 12:44:11 +00:00
|
|
|
return aRetval;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > SdrObjCustomShape::GetInteractionHandles() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
std::vector< SdrCustomShapeInteraction > xRet;
|
2007-08-02 17:27:59 +00:00
|
|
|
try
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
Reference< XCustomShapeEngine > xCustomShapeEngine( GetCustomShapeEngine() );
|
2007-08-02 17:27:59 +00:00
|
|
|
if ( xCustomShapeEngine.is() )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2007-08-02 17:27:59 +00:00
|
|
|
int i;
|
|
|
|
Sequence< Reference< XCustomShapeHandle > > xInteractionHandles( xCustomShapeEngine->getInteraction() );
|
|
|
|
for ( i = 0; i < xInteractionHandles.getLength(); i++ )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2007-08-02 17:27:59 +00:00
|
|
|
if ( xInteractionHandles[ i ].is() )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2007-08-02 17:27:59 +00:00
|
|
|
SdrCustomShapeInteraction aSdrCustomShapeInteraction;
|
|
|
|
aSdrCustomShapeInteraction.xInteraction = xInteractionHandles[ i ];
|
|
|
|
aSdrCustomShapeInteraction.aPosition = xInteractionHandles[ i ]->getPosition();
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2015-04-24 14:53:01 +02:00
|
|
|
CustomShapeHandleModes nMode = CustomShapeHandleModes::NONE;
|
2007-08-02 17:27:59 +00:00
|
|
|
switch( ImpGetCustomShapeType( *this ) )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2007-08-02 17:27:59 +00:00
|
|
|
case mso_sptAccentBorderCallout90 : // 2 ortho
|
|
|
|
{
|
2014-06-20 21:48:02 +02:00
|
|
|
if (i == 0)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_FIXED | CustomShapeHandleModes::CREATE_FIXED;
|
2014-06-20 21:48:02 +02:00
|
|
|
else if (i == 1)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_ABSOLUTE_X | CustomShapeHandleModes::RESIZE_ABSOLUTE_Y | CustomShapeHandleModes::MOVE_SHAPE | CustomShapeHandleModes::ORTHO4;
|
2007-08-02 17:27:59 +00:00
|
|
|
}
|
|
|
|
break;
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2007-08-02 17:27:59 +00:00
|
|
|
case mso_sptWedgeRectCallout :
|
|
|
|
case mso_sptWedgeRRectCallout :
|
|
|
|
case mso_sptCloudCallout :
|
|
|
|
case mso_sptWedgeEllipseCallout :
|
|
|
|
{
|
2014-06-20 21:48:02 +02:00
|
|
|
if (i == 0)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_FIXED;
|
2007-08-02 17:27:59 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case mso_sptBorderCallout1 : // 2 diag
|
|
|
|
{
|
2014-06-20 21:48:02 +02:00
|
|
|
if (i == 0)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_FIXED | CustomShapeHandleModes::CREATE_FIXED;
|
2014-06-20 21:48:02 +02:00
|
|
|
else if (i == 1)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_ABSOLUTE_X | CustomShapeHandleModes::RESIZE_ABSOLUTE_Y | CustomShapeHandleModes::MOVE_SHAPE;
|
2007-08-02 17:27:59 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
case mso_sptBorderCallout2 : // 3
|
|
|
|
{
|
2014-06-20 21:48:02 +02:00
|
|
|
if (i == 0)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_FIXED | CustomShapeHandleModes::CREATE_FIXED;
|
2014-06-20 21:48:02 +02:00
|
|
|
else if (i == 2)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_ABSOLUTE_X | CustomShapeHandleModes::RESIZE_ABSOLUTE_Y | CustomShapeHandleModes::MOVE_SHAPE;
|
2007-08-02 17:27:59 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
case mso_sptCallout90 :
|
|
|
|
case mso_sptAccentCallout90 :
|
|
|
|
case mso_sptBorderCallout90 :
|
|
|
|
case mso_sptCallout1 :
|
|
|
|
case mso_sptCallout2 :
|
|
|
|
case mso_sptCallout3 :
|
|
|
|
case mso_sptAccentCallout1 :
|
|
|
|
case mso_sptAccentCallout2 :
|
|
|
|
case mso_sptAccentCallout3 :
|
|
|
|
case mso_sptBorderCallout3 :
|
|
|
|
case mso_sptAccentBorderCallout1 :
|
|
|
|
case mso_sptAccentBorderCallout2 :
|
|
|
|
case mso_sptAccentBorderCallout3 :
|
|
|
|
{
|
2014-06-20 21:48:02 +02:00
|
|
|
if (i == 0)
|
2015-04-24 14:53:01 +02:00
|
|
|
nMode |= CustomShapeHandleModes::RESIZE_FIXED | CustomShapeHandleModes::CREATE_FIXED;
|
2007-08-02 17:27:59 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
default: break;
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
2007-08-02 17:27:59 +00:00
|
|
|
aSdrCustomShapeInteraction.nMode = nMode;
|
|
|
|
xRet.push_back( aSdrCustomShapeInteraction );
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2007-08-02 17:27:59 +00:00
|
|
|
catch( const uno::RuntimeException& )
|
|
|
|
{
|
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
return xRet;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
// BaseProperties section
|
2006-06-19 15:40:23 +00:00
|
|
|
#define DEFAULT_MINIMUM_SIGNED_COMPARE ((sal_Int32)0x80000000)
|
|
|
|
#define DEFAULT_MAXIMUM_SIGNED_COMPARE ((sal_Int32)0x7fffffff)
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2011-05-09 13:28:30 +02:00
|
|
|
static sal_Int32 GetNumberOfProperties ( const SvxMSDffHandle* pData )
|
|
|
|
{
|
2015-04-22 13:33:08 +02:00
|
|
|
sal_Int32 nPropertiesNeeded=1; // position is always needed
|
|
|
|
SvxMSDffHandleFlags nFlags = pData->nFlags;
|
2011-05-09 13:28:30 +02:00
|
|
|
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::MIRRORED_X )
|
2011-05-09 13:28:30 +02:00
|
|
|
nPropertiesNeeded++;
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::MIRRORED_Y )
|
2011-05-09 13:28:30 +02:00
|
|
|
nPropertiesNeeded++;
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::SWITCHED )
|
2011-05-09 13:28:30 +02:00
|
|
|
nPropertiesNeeded++;
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::POLAR )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
|
|
|
nPropertiesNeeded++;
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::RADIUS_RANGE )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
|
|
|
if ( pData->nRangeXMin != DEFAULT_MINIMUM_SIGNED_COMPARE )
|
|
|
|
nPropertiesNeeded++;
|
|
|
|
if ( pData->nRangeXMax != DEFAULT_MAXIMUM_SIGNED_COMPARE )
|
|
|
|
nPropertiesNeeded++;
|
|
|
|
}
|
|
|
|
}
|
2015-04-22 13:33:08 +02:00
|
|
|
else if ( nFlags & SvxMSDffHandleFlags::RANGE )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
|
|
|
if ( pData->nRangeXMin != DEFAULT_MINIMUM_SIGNED_COMPARE )
|
|
|
|
nPropertiesNeeded++;
|
|
|
|
if ( pData->nRangeXMax != DEFAULT_MAXIMUM_SIGNED_COMPARE )
|
|
|
|
nPropertiesNeeded++;
|
|
|
|
if ( pData->nRangeYMin != DEFAULT_MINIMUM_SIGNED_COMPARE )
|
|
|
|
nPropertiesNeeded++;
|
|
|
|
if ( pData->nRangeYMax != DEFAULT_MAXIMUM_SIGNED_COMPARE )
|
|
|
|
nPropertiesNeeded++;
|
|
|
|
}
|
|
|
|
|
|
|
|
return nPropertiesNeeded;
|
|
|
|
}
|
|
|
|
|
|
|
|
static void lcl_ShapePropertiesFromDFF( const SvxMSDffHandle* pData, com::sun::star::beans::PropertyValues& rPropValues )
|
|
|
|
{
|
2015-04-22 13:33:08 +02:00
|
|
|
SvxMSDffHandleFlags nFlags = pData->nFlags;
|
|
|
|
sal_Int32 n=0;
|
2011-05-09 13:28:30 +02:00
|
|
|
|
|
|
|
// POSITION
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sPosition( "Position" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameterPair aPosition;
|
2013-03-11 14:53:19 +09:00
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aPosition.First, pData->nPositionX, true, true );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aPosition.Second, pData->nPositionY, true, false );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sPosition;
|
|
|
|
rPropValues[ n++ ].Value <<= aPosition;
|
|
|
|
}
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::MIRRORED_X )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sMirroredX( "MirroredX" );
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bMirroredX = true;
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sMirroredX;
|
|
|
|
rPropValues[ n++ ].Value <<= bMirroredX;
|
|
|
|
}
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::MIRRORED_Y )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sMirroredY( "MirroredY" );
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bMirroredY = true;
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sMirroredY;
|
|
|
|
rPropValues[ n++ ].Value <<= bMirroredY;
|
|
|
|
}
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::SWITCHED )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sSwitched( "Switched" );
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bSwitched = true;
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sSwitched;
|
|
|
|
rPropValues[ n++ ].Value <<= bSwitched;
|
|
|
|
}
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::POLAR )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sPolar( "Polar" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameterPair aCenter;
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aCenter.First, pData->nCenterX,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::CENTER_X_IS_SPECIAL ), true );
|
2011-05-09 13:28:30 +02:00
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aCenter.Second, pData->nCenterY,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::CENTER_Y_IS_SPECIAL ), false );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sPolar;
|
|
|
|
rPropValues[ n++ ].Value <<= aCenter;
|
2015-04-22 13:33:08 +02:00
|
|
|
if ( nFlags & SvxMSDffHandleFlags::RADIUS_RANGE )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
|
|
|
if ( pData->nRangeXMin != DEFAULT_MINIMUM_SIGNED_COMPARE )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sRadiusRangeMinimum( "RadiusRangeMinimum" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameter aRadiusRangeMinimum;
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aRadiusRangeMinimum, pData->nRangeXMin,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::RANGE_X_MIN_IS_SPECIAL ), true );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sRadiusRangeMinimum;
|
|
|
|
rPropValues[ n++ ].Value <<= aRadiusRangeMinimum;
|
|
|
|
}
|
|
|
|
if ( pData->nRangeXMax != DEFAULT_MAXIMUM_SIGNED_COMPARE )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sRadiusRangeMaximum( "RadiusRangeMaximum" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameter aRadiusRangeMaximum;
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aRadiusRangeMaximum, pData->nRangeXMax,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::RANGE_X_MAX_IS_SPECIAL ), false );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sRadiusRangeMaximum;
|
|
|
|
rPropValues[ n++ ].Value <<= aRadiusRangeMaximum;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2015-04-22 13:33:08 +02:00
|
|
|
else if ( nFlags & SvxMSDffHandleFlags::RANGE )
|
2011-05-09 13:28:30 +02:00
|
|
|
{
|
|
|
|
if ( pData->nRangeXMin != DEFAULT_MINIMUM_SIGNED_COMPARE )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sRangeXMinimum( "RangeXMinimum" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameter aRangeXMinimum;
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aRangeXMinimum, pData->nRangeXMin,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::RANGE_X_MIN_IS_SPECIAL ), true );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sRangeXMinimum;
|
|
|
|
rPropValues[ n++ ].Value <<= aRangeXMinimum;
|
|
|
|
}
|
|
|
|
if ( pData->nRangeXMax != DEFAULT_MAXIMUM_SIGNED_COMPARE )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sRangeXMaximum( "RangeXMaximum" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameter aRangeXMaximum;
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aRangeXMaximum, pData->nRangeXMax,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::RANGE_X_MAX_IS_SPECIAL ), false );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sRangeXMaximum;
|
|
|
|
rPropValues[ n++ ].Value <<= aRangeXMaximum;
|
|
|
|
}
|
|
|
|
if ( pData->nRangeYMin != DEFAULT_MINIMUM_SIGNED_COMPARE )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sRangeYMinimum( "RangeYMinimum" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameter aRangeYMinimum;
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aRangeYMinimum, pData->nRangeYMin,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::RANGE_Y_MIN_IS_SPECIAL ), true );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sRangeYMinimum;
|
|
|
|
rPropValues[ n++ ].Value <<= aRangeYMinimum;
|
|
|
|
}
|
|
|
|
if ( pData->nRangeYMax != DEFAULT_MAXIMUM_SIGNED_COMPARE )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sRangeYMaximum( "RangeYMaximum" );
|
2011-05-09 13:28:30 +02:00
|
|
|
::com::sun::star::drawing::EnhancedCustomShapeParameter aRangeYMaximum;
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeHandleParameter( aRangeYMaximum, pData->nRangeYMax,
|
2015-04-22 13:33:08 +02:00
|
|
|
bool( nFlags & SvxMSDffHandleFlags::RANGE_Y_MAX_IS_SPECIAL ), false );
|
2011-05-09 13:28:30 +02:00
|
|
|
rPropValues[ n ].Name = sRangeYMaximum;
|
|
|
|
rPropValues[ n++ ].Value <<= aRangeYMaximum;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
sdr::properties::BaseProperties* SdrObjCustomShape::CreateObjectSpecificProperties()
|
|
|
|
{
|
|
|
|
return new sdr::properties::CustomShapeProperties(*this);
|
|
|
|
}
|
|
|
|
|
|
|
|
TYPEINIT1(SdrObjCustomShape,SdrTextObj);
|
|
|
|
SdrObjCustomShape::SdrObjCustomShape() :
|
|
|
|
SdrTextObj(),
|
2004-11-18 10:07:11 +00:00
|
|
|
fObjectRotation( 0.0 ),
|
|
|
|
mpLastShadowGeometry(0L)
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2013-01-09 14:49:01 +00:00
|
|
|
bClosedObj = true; // custom shapes may be filled
|
2014-03-10 11:09:59 +02:00
|
|
|
bTextFrame = true;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
SdrObjCustomShape::~SdrObjCustomShape()
|
|
|
|
{
|
2004-11-18 10:07:11 +00:00
|
|
|
// delete buffered display geometry
|
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
void SdrObjCustomShape::MergeDefaultAttributes( const OUString* pType )
|
2004-11-26 13:29:31 +00:00
|
|
|
{
|
|
|
|
PropertyValue aPropVal;
|
2013-04-07 12:06:47 +02:00
|
|
|
OUString sShapeType;
|
|
|
|
const OUString sType( "Type" );
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
|
2012-01-14 12:10:39 -02:00
|
|
|
if ( pType && !pType->isEmpty() )
|
2004-11-26 13:29:31 +00:00
|
|
|
{
|
2008-04-18 12:26:12 +00:00
|
|
|
sal_Int32 nType = pType->toInt32();
|
|
|
|
if ( nType )
|
|
|
|
sShapeType = EnhancedCustomShapeTypeNames::Get( static_cast< MSO_SPT >( nType ) );
|
|
|
|
else
|
|
|
|
sShapeType = *pType;
|
|
|
|
|
2004-11-26 13:29:31 +00:00
|
|
|
aPropVal.Name = sType;
|
2008-04-18 12:26:12 +00:00
|
|
|
aPropVal.Value <<= sShapeType;
|
2004-11-26 13:29:31 +00:00
|
|
|
aGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
Any *pAny = aGeometryItem.GetPropertyValueByName( sType );
|
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= sShapeType;
|
|
|
|
}
|
|
|
|
MSO_SPT eSpType = EnhancedCustomShapeTypeNames::Get( sShapeType );
|
|
|
|
|
|
|
|
const sal_Int32* pDefData = NULL;
|
|
|
|
const mso_CustomShape* pDefCustomShape = GetCustomShapeContent( eSpType );
|
|
|
|
if ( pDefCustomShape )
|
|
|
|
pDefData = pDefCustomShape->pDefData;
|
|
|
|
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeAdjustmentValue > seqAdjustmentValues;
|
2004-11-26 13:29:31 +00:00
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
|
|
|
// AdjustmentValues
|
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sAdjustmentValues( "AdjustmentValues" );
|
2004-11-26 13:29:31 +00:00
|
|
|
const Any* pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sAdjustmentValues );
|
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= seqAdjustmentValues;
|
|
|
|
if ( pDefCustomShape && pDefData ) // now check if we have to default some adjustment values
|
|
|
|
{
|
|
|
|
// first check if there are adjustment values are to be appended
|
|
|
|
sal_Int32 i, nAdjustmentValues = seqAdjustmentValues.getLength();
|
|
|
|
sal_Int32 nAdjustmentDefaults = *pDefData++;
|
|
|
|
if ( nAdjustmentDefaults > nAdjustmentValues )
|
|
|
|
{
|
|
|
|
seqAdjustmentValues.realloc( nAdjustmentDefaults );
|
|
|
|
for ( i = nAdjustmentValues; i < nAdjustmentDefaults; i++ )
|
|
|
|
{
|
|
|
|
seqAdjustmentValues[ i ].Value <<= pDefData[ i ];
|
2012-01-24 12:43:39 +05:30
|
|
|
seqAdjustmentValues[ i ].State = com::sun::star::beans::PropertyState_DIRECT_VALUE;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
// check if there are defaulted adjustment values that should be filled the hard coded defaults (pDefValue)
|
|
|
|
sal_Int32 nCount = nAdjustmentValues > nAdjustmentDefaults ? nAdjustmentDefaults : nAdjustmentValues;
|
|
|
|
for ( i = 0; i < nCount; i++ )
|
|
|
|
{
|
|
|
|
if ( seqAdjustmentValues[ i ].State != com::sun::star::beans::PropertyState_DIRECT_VALUE )
|
2010-02-26 15:42:12 +01:00
|
|
|
{
|
2004-11-26 13:29:31 +00:00
|
|
|
seqAdjustmentValues[ i ].Value <<= pDefData[ i ];
|
2010-02-26 15:42:12 +01:00
|
|
|
seqAdjustmentValues[ i ].State = com::sun::star::beans::PropertyState_DIRECT_VALUE;
|
|
|
|
}
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
aPropVal.Name = sAdjustmentValues;
|
|
|
|
aPropVal.Value <<= seqAdjustmentValues;
|
|
|
|
aGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
|
|
|
// Coordsize
|
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sViewBox( "ViewBox" );
|
2004-11-26 13:29:31 +00:00
|
|
|
const Any* pViewBox = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sViewBox );
|
|
|
|
com::sun::star::awt::Rectangle aViewBox;
|
|
|
|
if ( !pViewBox || !(*pViewBox >>= aViewBox ) )
|
|
|
|
{
|
|
|
|
if ( pDefCustomShape )
|
|
|
|
{
|
|
|
|
aViewBox.X = 0;
|
|
|
|
aViewBox.Y = 0;
|
|
|
|
aViewBox.Width = pDefCustomShape->nCoordWidth;
|
|
|
|
aViewBox.Height= pDefCustomShape->nCoordHeight;
|
|
|
|
aPropVal.Name = sViewBox;
|
|
|
|
aPropVal.Value <<= aViewBox;
|
|
|
|
aGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sPath( "Path" );
|
2004-11-26 13:29:31 +00:00
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
|
|
|
// Path/Coordinates
|
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sCoordinates( "Coordinates" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sCoordinates );
|
|
|
|
if ( !pAny && pDefCustomShape && pDefCustomShape->nVertices && pDefCustomShape->pVertices )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair> seqCoordinates;
|
2004-11-26 13:29:31 +00:00
|
|
|
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nVertices;
|
|
|
|
seqCoordinates.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqCoordinates[ i ].First, pDefCustomShape->pVertices[ i ].nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqCoordinates[ i ].Second, pDefCustomShape->pVertices[ i ].nValB );
|
|
|
|
}
|
|
|
|
aPropVal.Name = sCoordinates;
|
|
|
|
aPropVal.Value <<= seqCoordinates;
|
|
|
|
aGeometryItem.SetPropertyValue( sPath, aPropVal );
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
// Path/GluePoints
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sGluePoints( "GluePoints" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sGluePoints );
|
|
|
|
if ( !pAny && pDefCustomShape && pDefCustomShape->nGluePoints && pDefCustomShape->pGluePoints )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair> seqGluePoints;
|
2004-11-26 13:29:31 +00:00
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nGluePoints;
|
|
|
|
seqGluePoints.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqGluePoints[ i ].First, pDefCustomShape->pGluePoints[ i ].nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqGluePoints[ i ].Second, pDefCustomShape->pGluePoints[ i ].nValB );
|
|
|
|
}
|
|
|
|
aPropVal.Name = sGluePoints;
|
|
|
|
aPropVal.Value <<= seqGluePoints;
|
|
|
|
aGeometryItem.SetPropertyValue( sPath, aPropVal );
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
// Path/Segments
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sSegments( "Segments" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sSegments );
|
|
|
|
if ( !pAny && pDefCustomShape && pDefCustomShape->nElements && pDefCustomShape->pElements )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeSegment > seqSegments;
|
2004-11-26 13:29:31 +00:00
|
|
|
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nElements;
|
|
|
|
seqSegments.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShapeSegment& rSegInfo = seqSegments[ i ];
|
|
|
|
sal_uInt16 nSDat = pDefCustomShape->pElements[ i ];
|
2011-05-09 13:28:30 +02:00
|
|
|
lcl_ShapeSegmentFromBinary( rSegInfo, nSDat );
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
aPropVal.Name = sSegments;
|
|
|
|
aPropVal.Value <<= seqSegments;
|
|
|
|
aGeometryItem.SetPropertyValue( sPath, aPropVal );
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
// Path/StretchX
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sStretchX( "StretchX" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sStretchX );
|
|
|
|
if ( !pAny && pDefCustomShape )
|
|
|
|
{
|
|
|
|
sal_Int32 nXRef = pDefCustomShape->nXRef;
|
2006-06-19 15:40:23 +00:00
|
|
|
if ( ( nXRef != DEFAULT_MINIMUM_SIGNED_COMPARE ) )
|
2004-11-26 13:29:31 +00:00
|
|
|
{
|
|
|
|
aPropVal.Name = sStretchX;
|
|
|
|
aPropVal.Value <<= nXRef;
|
|
|
|
aGeometryItem.SetPropertyValue( sPath, aPropVal );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
// Path/StretchY
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sStretchY( "StretchY" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sStretchY );
|
|
|
|
if ( !pAny && pDefCustomShape )
|
|
|
|
{
|
|
|
|
sal_Int32 nYRef = pDefCustomShape->nYRef;
|
2006-06-19 15:40:23 +00:00
|
|
|
if ( ( nYRef != DEFAULT_MINIMUM_SIGNED_COMPARE ) )
|
2004-11-26 13:29:31 +00:00
|
|
|
{
|
|
|
|
aPropVal.Name = sStretchY;
|
|
|
|
aPropVal.Value <<= nYRef;
|
|
|
|
aGeometryItem.SetPropertyValue( sPath, aPropVal );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
// Path/TextFrames
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sTextFrames( "TextFrames" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sTextFrames );
|
|
|
|
if ( !pAny && pDefCustomShape && pDefCustomShape->nTextRect && pDefCustomShape->pTextRect )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeTextFrame > seqTextFrames;
|
2004-11-26 13:29:31 +00:00
|
|
|
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nTextRect;
|
|
|
|
seqTextFrames.realloc( nCount );
|
|
|
|
const SvxMSDffTextRectangles* pRectangles = pDefCustomShape->pTextRect;
|
|
|
|
for ( i = 0; i < nCount; i++, pRectangles++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames[ i ].TopLeft.First, pRectangles->nPairA.nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames[ i ].TopLeft.Second, pRectangles->nPairA.nValB );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames[ i ].BottomRight.First, pRectangles->nPairB.nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames[ i ].BottomRight.Second, pRectangles->nPairB.nValB );
|
|
|
|
}
|
|
|
|
aPropVal.Name = sTextFrames;
|
|
|
|
aPropVal.Value <<= seqTextFrames;
|
|
|
|
aGeometryItem.SetPropertyValue( sPath, aPropVal );
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
// Equations
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sEquations( "Equations" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sEquations );
|
|
|
|
if ( !pAny && pDefCustomShape && pDefCustomShape->nCalculation && pDefCustomShape->pCalculation )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
com::sun::star::uno::Sequence< OUString > seqEquations;
|
2004-11-26 13:29:31 +00:00
|
|
|
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nCalculation;
|
|
|
|
seqEquations.realloc( nCount );
|
|
|
|
const SvxMSDffCalculationData* pData = pDefCustomShape->pCalculation;
|
|
|
|
for ( i = 0; i < nCount; i++, pData++ )
|
|
|
|
seqEquations[ i ] = EnhancedCustomShape2d::GetEquation( pData->nFlags, pData->nVal[ 0 ], pData->nVal[ 1 ], pData->nVal[ 2 ] );
|
|
|
|
aPropVal.Name = sEquations;
|
|
|
|
aPropVal.Value <<= seqEquations;
|
|
|
|
aGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
// Handles
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sHandles( "Handles" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sHandles );
|
|
|
|
if ( !pAny && pDefCustomShape && pDefCustomShape->nHandles && pDefCustomShape->pHandles )
|
|
|
|
{
|
|
|
|
com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValues > seqHandles;
|
|
|
|
|
2011-05-09 13:28:30 +02:00
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nHandles;
|
2004-11-26 13:29:31 +00:00
|
|
|
const SvxMSDffHandle* pData = pDefCustomShape->pHandles;
|
|
|
|
seqHandles.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++, pData++ )
|
|
|
|
{
|
2011-05-09 13:28:30 +02:00
|
|
|
sal_Int32 nPropertiesNeeded;
|
2004-11-26 13:29:31 +00:00
|
|
|
com::sun::star::beans::PropertyValues& rPropValues = seqHandles[ i ];
|
2011-05-09 13:28:30 +02:00
|
|
|
nPropertiesNeeded = GetNumberOfProperties( pData );
|
2004-11-26 13:29:31 +00:00
|
|
|
rPropValues.realloc( nPropertiesNeeded );
|
2011-05-09 13:28:30 +02:00
|
|
|
lcl_ShapePropertiesFromDFF( pData, rPropValues );
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
aPropVal.Name = sHandles;
|
|
|
|
aPropVal.Value <<= seqHandles;
|
|
|
|
aGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
}
|
|
|
|
SetMergedItem( aGeometryItem );
|
|
|
|
}
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::IsDefaultGeometry( const DefaultType eDefaultType ) const
|
2004-11-26 13:29:31 +00:00
|
|
|
{
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bIsDefaultGeometry = false;
|
2004-11-26 13:29:31 +00:00
|
|
|
|
|
|
|
PropertyValue aPropVal;
|
2013-04-07 12:06:47 +02:00
|
|
|
OUString sShapeType;
|
|
|
|
const OUString sType( "Type" );
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
|
2004-11-26 13:29:31 +00:00
|
|
|
|
2014-10-17 10:35:35 +02:00
|
|
|
const Any *pAny = aGeometryItem.GetPropertyValueByName( sType );
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= sShapeType;
|
|
|
|
|
|
|
|
MSO_SPT eSpType = EnhancedCustomShapeTypeNames::Get( sShapeType );
|
|
|
|
|
|
|
|
const mso_CustomShape* pDefCustomShape = GetCustomShapeContent( eSpType );
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sPath( "Path" );
|
2004-11-26 13:29:31 +00:00
|
|
|
switch( eDefaultType )
|
|
|
|
{
|
|
|
|
case DEFAULT_VIEWBOX :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sViewBox( "ViewBox" );
|
2004-11-26 13:29:31 +00:00
|
|
|
const Any* pViewBox = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sViewBox );
|
|
|
|
com::sun::star::awt::Rectangle aViewBox;
|
|
|
|
if ( pViewBox && ( *pViewBox >>= aViewBox ) )
|
|
|
|
{
|
|
|
|
if ( ( aViewBox.Width == pDefCustomShape->nCoordWidth )
|
|
|
|
&& ( aViewBox.Height == pDefCustomShape->nCoordHeight ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_PATH :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sCoordinates( "Coordinates" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sCoordinates );
|
|
|
|
if ( pAny && pDefCustomShape && pDefCustomShape->nVertices && pDefCustomShape->pVertices )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair> seqCoordinates1, seqCoordinates2;
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( *pAny >>= seqCoordinates1 )
|
|
|
|
{
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nVertices;
|
|
|
|
seqCoordinates2.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqCoordinates2[ i ].First, pDefCustomShape->pVertices[ i ].nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqCoordinates2[ i ].Second, pDefCustomShape->pVertices[ i ].nValB );
|
|
|
|
}
|
|
|
|
if ( seqCoordinates1 == seqCoordinates2 )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
else if ( pDefCustomShape && ( ( pDefCustomShape->nVertices == 0 ) || ( pDefCustomShape->pVertices == 0 ) ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_GLUEPOINTS :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sGluePoints( "GluePoints" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sGluePoints );
|
|
|
|
if ( pAny && pDefCustomShape && pDefCustomShape->nGluePoints && pDefCustomShape->pGluePoints )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeParameterPair> seqGluePoints1, seqGluePoints2;
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( *pAny >>= seqGluePoints1 )
|
|
|
|
{
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nGluePoints;
|
|
|
|
seqGluePoints2.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqGluePoints2[ i ].First, pDefCustomShape->pGluePoints[ i ].nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqGluePoints2[ i ].Second, pDefCustomShape->pGluePoints[ i ].nValB );
|
|
|
|
}
|
|
|
|
if ( seqGluePoints1 == seqGluePoints2 )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
else if ( pDefCustomShape && ( pDefCustomShape->nGluePoints == 0 ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_SEGMENTS :
|
|
|
|
{
|
2014-02-25 20:51:35 +01:00
|
|
|
// Path/Segments
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sSegments( "Segments" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sSegments );
|
|
|
|
if ( pAny )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeSegment > seqSegments1, seqSegments2;
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( *pAny >>= seqSegments1 )
|
|
|
|
{
|
|
|
|
if ( pDefCustomShape && pDefCustomShape->nElements && pDefCustomShape->pElements )
|
|
|
|
{
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nElements;
|
|
|
|
if ( nCount )
|
|
|
|
{
|
|
|
|
seqSegments2.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShapeSegment& rSegInfo = seqSegments2[ i ];
|
|
|
|
sal_uInt16 nSDat = pDefCustomShape->pElements[ i ];
|
2011-05-09 13:28:30 +02:00
|
|
|
lcl_ShapeSegmentFromBinary( rSegInfo, nSDat );
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
if ( seqSegments1 == seqSegments2 )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
// check if its the default segment description ( M L Z N )
|
|
|
|
if ( seqSegments1.getLength() == 4 )
|
|
|
|
{
|
|
|
|
if ( ( seqSegments1[ 0 ].Command == EnhancedCustomShapeSegmentCommand::MOVETO )
|
|
|
|
&& ( seqSegments1[ 1 ].Command == EnhancedCustomShapeSegmentCommand::LINETO )
|
|
|
|
&& ( seqSegments1[ 2 ].Command == EnhancedCustomShapeSegmentCommand::CLOSESUBPATH )
|
|
|
|
&& ( seqSegments1[ 3 ].Command == EnhancedCustomShapeSegmentCommand::ENDSUBPATH ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if ( pDefCustomShape && ( ( pDefCustomShape->nElements == 0 ) || ( pDefCustomShape->pElements == 0 ) ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_STRETCHX :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sStretchX( "StretchX" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sStretchX );
|
|
|
|
if ( pAny && pDefCustomShape )
|
|
|
|
{
|
2006-11-21 16:13:09 +00:00
|
|
|
sal_Int32 nStretchX = 0;
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( *pAny >>= nStretchX )
|
|
|
|
{
|
|
|
|
if ( pDefCustomShape->nXRef == nStretchX )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
2006-06-19 15:40:23 +00:00
|
|
|
else if ( pDefCustomShape && ( pDefCustomShape->nXRef == DEFAULT_MINIMUM_SIGNED_COMPARE ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_STRETCHY :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sStretchY( "StretchY" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sStretchY );
|
|
|
|
if ( pAny && pDefCustomShape )
|
|
|
|
{
|
2006-11-21 16:13:09 +00:00
|
|
|
sal_Int32 nStretchY = 0;
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( *pAny >>= nStretchY )
|
|
|
|
{
|
|
|
|
if ( pDefCustomShape->nYRef == nStretchY )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
2006-06-19 15:40:23 +00:00
|
|
|
else if ( pDefCustomShape && ( pDefCustomShape->nYRef == DEFAULT_MINIMUM_SIGNED_COMPARE ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_EQUATIONS :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sEquations( "Equations" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sEquations );
|
|
|
|
if ( pAny && pDefCustomShape && pDefCustomShape->nCalculation && pDefCustomShape->pCalculation )
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
com::sun::star::uno::Sequence< OUString > seqEquations1, seqEquations2;
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( *pAny >>= seqEquations1 )
|
|
|
|
{
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nCalculation;
|
|
|
|
seqEquations2.realloc( nCount );
|
|
|
|
|
|
|
|
const SvxMSDffCalculationData* pData = pDefCustomShape->pCalculation;
|
|
|
|
for ( i = 0; i < nCount; i++, pData++ )
|
|
|
|
seqEquations2[ i ] = EnhancedCustomShape2d::GetEquation( pData->nFlags, pData->nVal[ 0 ], pData->nVal[ 1 ], pData->nVal[ 2 ] );
|
|
|
|
|
|
|
|
if ( seqEquations1 == seqEquations2 )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
else if ( pDefCustomShape && ( ( pDefCustomShape->nCalculation == 0 ) || ( pDefCustomShape->pCalculation == 0 ) ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_TEXTFRAMES :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sTextFrames( "TextFrames" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sPath, sTextFrames );
|
|
|
|
if ( pAny && pDefCustomShape && pDefCustomShape->nTextRect && pDefCustomShape->pTextRect )
|
|
|
|
{
|
2005-03-01 18:10:56 +00:00
|
|
|
com::sun::star::uno::Sequence< com::sun::star::drawing::EnhancedCustomShapeTextFrame > seqTextFrames1, seqTextFrames2;
|
2004-11-26 13:29:31 +00:00
|
|
|
if ( *pAny >>= seqTextFrames1 )
|
|
|
|
{
|
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nTextRect;
|
|
|
|
seqTextFrames2.realloc( nCount );
|
|
|
|
const SvxMSDffTextRectangles* pRectangles = pDefCustomShape->pTextRect;
|
|
|
|
for ( i = 0; i < nCount; i++, pRectangles++ )
|
|
|
|
{
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames2[ i ].TopLeft.First, pRectangles->nPairA.nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames2[ i ].TopLeft.Second, pRectangles->nPairA.nValB );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames2[ i ].BottomRight.First, pRectangles->nPairB.nValA );
|
|
|
|
EnhancedCustomShape2d::SetEnhancedCustomShapeParameter( seqTextFrames2[ i ].BottomRight.Second, pRectangles->nPairB.nValB );
|
|
|
|
}
|
|
|
|
if ( seqTextFrames1 == seqTextFrames2 )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
else if ( pDefCustomShape && ( ( pDefCustomShape->nTextRect == 0 ) || ( pDefCustomShape->pTextRect == 0 ) ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DEFAULT_HANDLES :
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sHandles( "Handles" );
|
2004-11-26 13:29:31 +00:00
|
|
|
pAny = ((SdrCustomShapeGeometryItem&)aGeometryItem).GetPropertyValueByName( sHandles );
|
|
|
|
if ( pAny && pDefCustomShape && pDefCustomShape->nHandles && pDefCustomShape->pHandles )
|
|
|
|
{
|
|
|
|
com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValues > seqHandles1, seqHandles2;
|
|
|
|
if ( *pAny >>= seqHandles1 )
|
|
|
|
{
|
2011-05-09 13:28:30 +02:00
|
|
|
sal_Int32 i, nCount = pDefCustomShape->nHandles;
|
2004-11-26 13:29:31 +00:00
|
|
|
const SvxMSDffHandle* pData = pDefCustomShape->pHandles;
|
|
|
|
seqHandles2.realloc( nCount );
|
|
|
|
for ( i = 0; i < nCount; i++, pData++ )
|
|
|
|
{
|
2011-05-09 13:28:30 +02:00
|
|
|
sal_Int32 nPropertiesNeeded;
|
2004-11-26 13:29:31 +00:00
|
|
|
com::sun::star::beans::PropertyValues& rPropValues = seqHandles2[ i ];
|
2011-05-09 13:28:30 +02:00
|
|
|
nPropertiesNeeded = GetNumberOfProperties( pData );
|
2004-11-26 13:29:31 +00:00
|
|
|
rPropValues.realloc( nPropertiesNeeded );
|
2011-05-09 13:28:30 +02:00
|
|
|
lcl_ShapePropertiesFromDFF( pData, rPropValues );
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
if ( seqHandles1 == seqHandles2 )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
else if ( pDefCustomShape && ( ( pDefCustomShape->nHandles == 0 ) || ( pDefCustomShape->pHandles == 0 ) ) )
|
2014-03-10 11:09:59 +02:00
|
|
|
bIsDefaultGeometry = true;
|
2004-11-26 13:29:31 +00:00
|
|
|
}
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
return bIsDefaultGeometry;
|
|
|
|
}
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
void SdrObjCustomShape::TakeObjInfo(SdrObjTransformInfoRec& rInfo) const
|
|
|
|
{
|
2004-10-12 13:17:22 +00:00
|
|
|
rInfo.bResizeFreeAllowed=fObjectRotation == 0.0;
|
2014-01-28 19:57:37 +01:00
|
|
|
rInfo.bResizePropAllowed=true;
|
|
|
|
rInfo.bRotateFreeAllowed=true;
|
|
|
|
rInfo.bRotate90Allowed =true;
|
|
|
|
rInfo.bMirrorFreeAllowed=true;
|
|
|
|
rInfo.bMirror45Allowed =true;
|
|
|
|
rInfo.bMirror90Allowed =true;
|
|
|
|
rInfo.bTransparenceAllowed = false;
|
|
|
|
rInfo.bGradientAllowed = false;
|
|
|
|
rInfo.bShearAllowed =true;
|
|
|
|
rInfo.bEdgeRadiusAllowed=false;
|
|
|
|
rInfo.bNoContortion =true;
|
2004-11-18 10:07:11 +00:00
|
|
|
|
|
|
|
// #i37011#
|
|
|
|
if ( mXRenderedCustomShape.is() )
|
|
|
|
{
|
|
|
|
const SdrObject* pRenderedCustomShape = GetSdrObjectFromXShape( mXRenderedCustomShape );
|
|
|
|
if ( pRenderedCustomShape )
|
|
|
|
{
|
|
|
|
// #i37262#
|
|
|
|
// Iterate self over the contained objects, since there are combinations of
|
|
|
|
// polygon and curve objects. In that case, aInfo.bCanConvToPath and
|
|
|
|
// aInfo.bCanConvToPoly would be false. What is needed here is an or, not an and.
|
|
|
|
SdrObjListIter aIterator(*pRenderedCustomShape);
|
|
|
|
while(aIterator.IsMore())
|
|
|
|
{
|
|
|
|
SdrObject* pCandidate = aIterator.Next();
|
|
|
|
SdrObjTransformInfoRec aInfo;
|
|
|
|
pCandidate->TakeObjInfo(aInfo);
|
|
|
|
|
|
|
|
// set path and poly conversion if one is possible since
|
|
|
|
// this object will first be broken
|
2012-02-29 10:58:21 +00:00
|
|
|
const bool bCanConvToPathOrPoly(aInfo.bCanConvToPath || aInfo.bCanConvToPoly);
|
2004-11-18 10:07:11 +00:00
|
|
|
if(rInfo.bCanConvToPath != bCanConvToPathOrPoly)
|
|
|
|
{
|
|
|
|
rInfo.bCanConvToPath = bCanConvToPathOrPoly;
|
|
|
|
}
|
|
|
|
|
|
|
|
if(rInfo.bCanConvToPoly != bCanConvToPathOrPoly)
|
|
|
|
{
|
|
|
|
rInfo.bCanConvToPoly = bCanConvToPathOrPoly;
|
|
|
|
}
|
|
|
|
|
|
|
|
if(rInfo.bCanConvToContour != aInfo.bCanConvToContour)
|
|
|
|
{
|
|
|
|
rInfo.bCanConvToContour = aInfo.bCanConvToContour;
|
|
|
|
}
|
2011-04-22 17:33:22 +02:00
|
|
|
|
|
|
|
if(rInfo.bShearAllowed != aInfo.bShearAllowed)
|
|
|
|
{
|
|
|
|
rInfo.bShearAllowed = aInfo.bShearAllowed;
|
|
|
|
}
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2010-02-12 16:56:44 +01:00
|
|
|
void SdrObjCustomShape::SetModel(SdrModel* pNewModel)
|
|
|
|
{
|
|
|
|
SdrTextObj::SetModel(pNewModel);
|
|
|
|
mXRenderedCustomShape.clear();
|
|
|
|
}
|
2009-10-27 15:01:25 +00:00
|
|
|
|
2011-01-10 16:11:35 +01:00
|
|
|
sal_uInt16 SdrObjCustomShape::GetObjIdentifier() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2011-01-10 16:11:35 +01:00
|
|
|
return sal_uInt16(OBJ_CUSTOMSHAPE);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
void SdrObjCustomShape::RecalcSnapRect()
|
|
|
|
{
|
|
|
|
SdrTextObj::RecalcSnapRect();
|
|
|
|
}
|
|
|
|
const Rectangle& SdrObjCustomShape::GetSnapRect() const
|
|
|
|
{
|
|
|
|
return SdrTextObj::GetSnapRect();
|
|
|
|
}
|
|
|
|
const Rectangle& SdrObjCustomShape::GetCurrentBoundRect() const
|
|
|
|
{
|
|
|
|
return SdrTextObj::GetCurrentBoundRect();
|
|
|
|
}
|
|
|
|
const Rectangle& SdrObjCustomShape::GetLogicRect() const
|
|
|
|
{
|
|
|
|
return SdrTextObj::GetLogicRect();
|
|
|
|
}
|
2013-09-19 10:11:03 +00:00
|
|
|
|
|
|
|
// #115391# This implementation is based on the TextFrame size of the CustomShape and the
|
|
|
|
// state of the ResizeShapeToFitText flag to correctly set TextMinFrameWidth/Height
|
|
|
|
void SdrObjCustomShape::AdaptTextMinSize()
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2013-09-19 10:11:03 +00:00
|
|
|
if(!pModel || !pModel->IsPasteResize())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-08-04 19:22:55 +02:00
|
|
|
const bool bResizeShapeToFitText(static_cast< const SdrOnOffItem& >(GetObjectItem(SDRATTR_TEXT_AUTOGROWHEIGHT)).GetValue());
|
2014-03-22 15:44:47 +01:00
|
|
|
SfxItemSet aSet(
|
|
|
|
*GetObjectItemSet().GetPool(),
|
|
|
|
SDRATTR_TEXT_MINFRAMEHEIGHT, SDRATTR_TEXT_AUTOGROWHEIGHT,
|
|
|
|
SDRATTR_TEXT_MINFRAMEWIDTH, SDRATTR_TEXT_AUTOGROWWIDTH, // contains SDRATTR_TEXT_MAXFRAMEWIDTH
|
|
|
|
0, 0);
|
2013-09-19 10:11:03 +00:00
|
|
|
bool bChanged(false);
|
|
|
|
|
|
|
|
if(bResizeShapeToFitText)
|
|
|
|
{
|
|
|
|
// always reset MinWidthHeight to zero to only rely on text size and frame size
|
|
|
|
// to allow resizing being completely dependent on text size only
|
2014-07-31 15:57:12 +02:00
|
|
|
aSet.Put(makeSdrTextMinFrameWidthItem(0));
|
|
|
|
aSet.Put(makeSdrTextMinFrameHeightItem(0));
|
2013-09-19 10:11:03 +00:00
|
|
|
bChanged = true;
|
|
|
|
}
|
|
|
|
else
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2013-09-19 10:11:03 +00:00
|
|
|
// recreate from CustomShape-specific TextBounds
|
2014-10-29 15:01:37 -04:00
|
|
|
Rectangle aTextBound(maRect);
|
2013-09-19 10:11:03 +00:00
|
|
|
|
|
|
|
if(GetTextBounds(aTextBound))
|
|
|
|
{
|
|
|
|
const long nHDist(GetTextLeftDistance() + GetTextRightDistance());
|
|
|
|
const long nVDist(GetTextUpperDistance() + GetTextLowerDistance());
|
|
|
|
const long nTWdt(std::max(long(0), (long)(aTextBound.GetWidth() - 1 - nHDist)));
|
|
|
|
const long nTHgt(std::max(long(0), (long)(aTextBound.GetHeight() - 1 - nVDist)));
|
|
|
|
|
2014-07-31 15:57:12 +02:00
|
|
|
aSet.Put(makeSdrTextMinFrameWidthItem(nTWdt));
|
|
|
|
aSet.Put(makeSdrTextMinFrameHeightItem(nTHgt));
|
2013-09-19 10:11:03 +00:00
|
|
|
bChanged = true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if(bChanged)
|
|
|
|
SetObjectItemSet(aSet);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2013-09-19 10:11:03 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void SdrObjCustomShape::NbcSetSnapRect( const Rectangle& rRect )
|
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
maRect = rRect;
|
|
|
|
ImpJustifyRect(maRect);
|
2013-09-19 10:11:03 +00:00
|
|
|
InvalidateRenderGeometry();
|
|
|
|
|
|
|
|
// #115391#
|
|
|
|
AdaptTextMinSize();
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
ImpCheckShear();
|
|
|
|
SetRectsDirty();
|
|
|
|
SetChanged();
|
|
|
|
}
|
2014-10-29 15:01:37 -04:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
void SdrObjCustomShape::SetSnapRect( const Rectangle& rRect )
|
|
|
|
{
|
2005-01-07 08:24:44 +00:00
|
|
|
Rectangle aBoundRect0;
|
|
|
|
if ( pUserCall )
|
|
|
|
aBoundRect0 = GetLastBoundRect();
|
2004-04-02 13:13:28 +00:00
|
|
|
NbcSetSnapRect( rRect );
|
2005-01-07 08:24:44 +00:00
|
|
|
BroadcastObjectChange();
|
|
|
|
SendUserCall(SDRUSERCALL_RESIZE,aBoundRect0);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2014-10-29 15:01:37 -04:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
void SdrObjCustomShape::NbcSetLogicRect( const Rectangle& rRect )
|
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
maRect = rRect;
|
|
|
|
ImpJustifyRect(maRect);
|
2007-08-02 17:27:59 +00:00
|
|
|
InvalidateRenderGeometry();
|
2013-09-19 10:11:03 +00:00
|
|
|
|
|
|
|
// #115391#
|
|
|
|
AdaptTextMinSize();
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
SetRectsDirty();
|
|
|
|
SetChanged();
|
|
|
|
}
|
2014-10-29 15:01:37 -04:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
void SdrObjCustomShape::SetLogicRect( const Rectangle& rRect )
|
|
|
|
{
|
2005-01-07 08:24:44 +00:00
|
|
|
Rectangle aBoundRect0;
|
|
|
|
if ( pUserCall )
|
|
|
|
aBoundRect0 = GetLastBoundRect();
|
2004-04-02 13:13:28 +00:00
|
|
|
NbcSetLogicRect(rRect);
|
2005-01-07 08:24:44 +00:00
|
|
|
BroadcastObjectChange();
|
|
|
|
SendUserCall(SDRUSERCALL_RESIZE,aBoundRect0);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2014-10-29 15:01:37 -04:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
void SdrObjCustomShape::Move( const Size& rSiz )
|
|
|
|
{
|
2004-10-12 13:17:22 +00:00
|
|
|
if ( rSiz.Width() || rSiz.Height() )
|
|
|
|
{
|
|
|
|
Rectangle aBoundRect0;
|
|
|
|
if ( pUserCall )
|
|
|
|
aBoundRect0 = GetLastBoundRect();
|
|
|
|
NbcMove(rSiz);
|
|
|
|
SetChanged();
|
|
|
|
BroadcastObjectChange();
|
|
|
|
SendUserCall(SDRUSERCALL_MOVEONLY,aBoundRect0);
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
void SdrObjCustomShape::NbcMove( const Size& rSiz )
|
|
|
|
{
|
|
|
|
SdrTextObj::NbcMove( rSiz );
|
2004-10-12 13:17:22 +00:00
|
|
|
if ( mXRenderedCustomShape.is() )
|
|
|
|
{
|
|
|
|
SdrObject* pRenderedCustomShape = GetSdrObjectFromXShape( mXRenderedCustomShape );
|
|
|
|
if ( pRenderedCustomShape )
|
2009-01-20 09:49:16 +00:00
|
|
|
{
|
|
|
|
// #i97149# the visualisation shape needs to be informed
|
|
|
|
// about change, too
|
|
|
|
pRenderedCustomShape->ActionChanged();
|
2004-10-12 13:17:22 +00:00
|
|
|
pRenderedCustomShape->NbcMove( rSiz );
|
2009-01-20 09:49:16 +00:00
|
|
|
}
|
2004-10-12 13:17:22 +00:00
|
|
|
}
|
2004-11-18 10:07:11 +00:00
|
|
|
|
|
|
|
// #i37011# adapt geometry shadow
|
|
|
|
if(mpLastShadowGeometry)
|
|
|
|
{
|
|
|
|
mpLastShadowGeometry->NbcMove( rSiz );
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2014-10-23 17:41:47 +02:00
|
|
|
void SdrObjCustomShape::Resize( const Point& rRef, const Fraction& xFact, const Fraction& yFact, bool bUnsetRelative )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2012-09-26 13:10:31 +02:00
|
|
|
SdrTextObj::Resize( rRef, xFact, yFact, bUnsetRelative );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2014-10-23 17:41:47 +02:00
|
|
|
void SdrObjCustomShape::NbcResize( const Point& rRef, const Fraction& rxFact, const Fraction& ryFact )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-10-23 17:41:47 +02:00
|
|
|
Fraction xFact( rxFact );
|
|
|
|
Fraction yFact( ryFact );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
|
|
|
// taking care of handles that should not been changed
|
2014-10-29 15:01:37 -04:00
|
|
|
Rectangle aOld( maRect );
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
SdrTextObj::NbcResize( rRef, xFact, yFact );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2014-10-23 17:41:47 +02:00
|
|
|
if ( ( xFact.GetNumerator() != xFact.GetDenominator() )
|
|
|
|
|| ( yFact.GetNumerator()!= yFact.GetDenominator() ) )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2014-10-23 17:41:47 +02:00
|
|
|
if ( ( ( xFact.GetNumerator() < 0 ) && ( xFact.GetDenominator() > 0 ) ) ||
|
|
|
|
( ( xFact.GetNumerator() > 0 ) && ( xFact.GetDenominator() < 0 ) ) )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2015-04-27 15:29:17 +02:00
|
|
|
SetMirroredX( !IsMirroredX() );
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
2014-10-23 17:41:47 +02:00
|
|
|
if ( ( ( yFact.GetNumerator() < 0 ) && ( yFact.GetDenominator() > 0 ) ) ||
|
|
|
|
( ( yFact.GetNumerator() > 0 ) && ( yFact.GetDenominator() < 0 ) ) )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2015-04-27 15:29:17 +02:00
|
|
|
SetMirroredY( !IsMirroredY() );
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2013-03-30 17:39:58 +01:00
|
|
|
for (std::vector< SdrCustomShapeInteraction >::const_iterator aIter( aInteractionHandles.begin() ), aEnd( aInteractionHandles.end() );
|
|
|
|
aIter != aEnd; ++aIter )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
try
|
|
|
|
{
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_FIXED )
|
2005-09-28 11:40:42 +00:00
|
|
|
aIter->xInteraction->setControllerPosition( aIter->aPosition );
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_ABSOLUTE_X )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
sal_Int32 nX = ( aIter->aPosition.X - aOld.Left() ) + maRect.Left();
|
2005-09-28 11:40:42 +00:00
|
|
|
aIter->xInteraction->setControllerPosition( com::sun::star::awt::Point( nX, aIter->xInteraction->getPosition().Y ) );
|
|
|
|
}
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_ABSOLUTE_Y )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
sal_Int32 nY = ( aIter->aPosition.Y - aOld.Top() ) + maRect.Top();
|
2005-09-28 11:40:42 +00:00
|
|
|
aIter->xInteraction->setControllerPosition( com::sun::star::awt::Point( aIter->xInteraction->getPosition().X, nY ) );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch ( const uno::RuntimeException& )
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2014-11-04 14:45:00 +02:00
|
|
|
void SdrObjCustomShape::NbcRotate( const Point& rRef, long nAngle, double sn, double cs )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bMirroredX = IsMirroredX();
|
|
|
|
bool bMirroredY = IsMirroredY();
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
fObjectRotation = fmod( fObjectRotation, 360.0 );
|
|
|
|
if ( fObjectRotation < 0 )
|
|
|
|
fObjectRotation = 360 + fObjectRotation;
|
|
|
|
|
|
|
|
// the rotation angle for ashapes is stored in fObjectRotation, this rotation
|
2014-11-04 14:45:00 +02:00
|
|
|
// has to be applied to the text object (which is internally using aGeo.nAngle).
|
2014-10-29 15:01:37 -04:00
|
|
|
SdrTextObj::NbcRotate( maRect.TopLeft(), -aGeo.nRotationAngle, // retrieving the unrotated text object
|
2014-10-15 07:53:32 +02:00
|
|
|
sin( (-aGeo.nRotationAngle) * F_PI18000 ),
|
|
|
|
cos( (-aGeo.nRotationAngle) * F_PI18000 ) );
|
|
|
|
aGeo.nRotationAngle = 0; // resetting aGeo data
|
2004-04-02 13:13:28 +00:00
|
|
|
aGeo.RecalcSinCos();
|
|
|
|
|
|
|
|
long nW = (long)( fObjectRotation * 100 ); // applying our object rotation
|
|
|
|
if ( bMirroredX )
|
2005-10-19 11:11:20 +00:00
|
|
|
nW = 36000 - nW;
|
|
|
|
if ( bMirroredY )
|
2004-04-02 13:13:28 +00:00
|
|
|
nW = 18000 - nW;
|
|
|
|
nW = nW % 36000;
|
|
|
|
if ( nW < 0 )
|
|
|
|
nW = 36000 + nW;
|
2014-10-29 15:01:37 -04:00
|
|
|
SdrTextObj::NbcRotate( maRect.TopLeft(), nW, // applying text rotation
|
2004-04-02 13:13:28 +00:00
|
|
|
sin( nW * F_PI18000 ),
|
|
|
|
cos( nW * F_PI18000 ) );
|
|
|
|
|
|
|
|
int nSwap = 0;
|
|
|
|
if ( bMirroredX )
|
|
|
|
nSwap ^= 1;
|
|
|
|
if ( bMirroredY )
|
|
|
|
nSwap ^= 1;
|
|
|
|
|
2014-11-04 14:45:00 +02:00
|
|
|
double fAngle = nAngle; // updating to our new object rotation
|
2014-11-04 13:31:01 +02:00
|
|
|
fAngle /= 100.0;
|
|
|
|
fObjectRotation = fmod( nSwap ? fObjectRotation - fAngle : fObjectRotation + fAngle, 360.0 );
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( fObjectRotation < 0 )
|
|
|
|
fObjectRotation = 360 + fObjectRotation;
|
|
|
|
|
2014-11-04 14:45:00 +02:00
|
|
|
SdrTextObj::NbcRotate( rRef, nAngle, sn, cs ); // applying text rotation
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void SdrObjCustomShape::NbcMirror( const Point& rRef1, const Point& rRef2 )
|
|
|
|
{
|
2012-12-11 13:43:12 +00:00
|
|
|
// TTTT: Fix for old mirroring, can be removed again in aw080
|
2004-04-02 13:13:28 +00:00
|
|
|
// storing horizontal and vertical flipping without modifying the rotate angle
|
2012-12-11 13:43:12 +00:00
|
|
|
// decompose other flipping to rotation and MirrorX.
|
|
|
|
long ndx = rRef2.X()-rRef1.X();
|
|
|
|
long ndy = rRef2.Y()-rRef1.Y();
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2012-12-11 13:43:12 +00:00
|
|
|
if(!ndx) // MirroredX
|
|
|
|
{
|
|
|
|
SetMirroredX(!IsMirroredX());
|
|
|
|
SdrTextObj::NbcMirror( rRef1, rRef2 );
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
if(!ndy) // MirroredY
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2012-12-11 13:43:12 +00:00
|
|
|
SetMirroredY(!IsMirroredY());
|
|
|
|
SdrTextObj::NbcMirror( rRef1, rRef2 );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2012-12-11 13:43:12 +00:00
|
|
|
else // neither horizontal nor vertical
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2012-12-11 13:43:12 +00:00
|
|
|
SetMirroredX(!IsMirroredX());
|
|
|
|
|
|
|
|
// call parent
|
|
|
|
SdrTextObj::NbcMirror( rRef1, rRef2 );
|
|
|
|
|
|
|
|
// update fObjectRotation
|
2014-10-15 07:53:32 +02:00
|
|
|
long nTextObjRotation = aGeo.nRotationAngle;
|
2014-11-04 13:31:01 +02:00
|
|
|
double fAngle = nTextObjRotation;
|
2012-12-11 13:43:12 +00:00
|
|
|
|
2014-11-04 13:31:01 +02:00
|
|
|
fAngle /= 100.0;
|
2012-12-11 13:43:12 +00:00
|
|
|
|
|
|
|
bool bSingleFlip = (IsMirroredX()!= IsMirroredY());
|
|
|
|
|
2014-11-04 13:31:01 +02:00
|
|
|
fObjectRotation = fmod( bSingleFlip ? -fAngle : fAngle, 360.0 );
|
2012-12-11 13:43:12 +00:00
|
|
|
|
|
|
|
if ( fObjectRotation < 0 )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2012-12-11 13:43:12 +00:00
|
|
|
fObjectRotation = 360.0 + fObjectRotation;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2012-12-11 13:43:12 +00:00
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2012-12-11 13:43:12 +00:00
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-11-04 14:45:00 +02:00
|
|
|
void SdrObjCustomShape::Shear( const Point& rRef, long nAngle, double tn, bool bVShear )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-11-04 14:45:00 +02:00
|
|
|
SdrTextObj::Shear( rRef, nAngle, tn, bVShear );
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2014-11-04 14:45:00 +02:00
|
|
|
void SdrObjCustomShape::NbcShear( const Point& rRef, long nAngle, double tn, bool bVShear )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2012-12-11 13:43:12 +00:00
|
|
|
// TTTT: Fix for old mirroring, can be removed again in aw080
|
2014-11-04 14:45:00 +02:00
|
|
|
SdrTextObj::NbcShear(rRef,nAngle,tn,bVShear);
|
2012-12-11 13:43:12 +00:00
|
|
|
|
|
|
|
// updating fObjectRotation
|
2014-10-15 07:53:32 +02:00
|
|
|
long nTextObjRotation = aGeo.nRotationAngle;
|
2014-11-04 13:31:01 +02:00
|
|
|
double fAngle = nTextObjRotation;
|
2012-12-11 13:43:12 +00:00
|
|
|
|
2014-11-04 13:31:01 +02:00
|
|
|
fAngle /= 100.0;
|
2012-12-11 13:43:12 +00:00
|
|
|
|
|
|
|
bool bSingleFlip = (IsMirroredX()!= IsMirroredY());
|
|
|
|
|
2014-11-04 13:31:01 +02:00
|
|
|
fObjectRotation = fmod( bSingleFlip ? -fAngle : fAngle, 360.0 );
|
2012-12-11 13:43:12 +00:00
|
|
|
|
|
|
|
if ( fObjectRotation < 0 )
|
2009-06-17 10:58:14 +00:00
|
|
|
{
|
2012-12-11 13:43:12 +00:00
|
|
|
fObjectRotation = 360.0 + fObjectRotation;
|
2009-06-17 10:58:14 +00:00
|
|
|
}
|
2012-12-11 13:43:12 +00:00
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2009-06-17 10:58:14 +00:00
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2009-06-17 10:58:14 +00:00
|
|
|
|
2011-01-10 16:11:35 +01:00
|
|
|
SdrGluePoint SdrObjCustomShape::GetVertexGluePoint(sal_uInt16 nPosNum) const
|
2009-06-17 10:58:14 +00:00
|
|
|
{
|
2012-01-24 12:43:39 +05:30
|
|
|
sal_Int32 nWdt = ImpGetLineWdt(); // #i25616#
|
2009-06-17 10:58:14 +00:00
|
|
|
|
|
|
|
// #i25616#
|
|
|
|
if(!LineIsOutsideGeometry())
|
|
|
|
{
|
|
|
|
nWdt++;
|
|
|
|
nWdt /= 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
Point aPt;
|
|
|
|
switch (nPosNum) {
|
2014-10-29 15:01:37 -04:00
|
|
|
case 0: aPt=maRect.TopCenter(); aPt.Y()-=nWdt; break;
|
|
|
|
case 1: aPt=maRect.RightCenter(); aPt.X()+=nWdt; break;
|
|
|
|
case 2: aPt=maRect.BottomCenter(); aPt.Y()+=nWdt; break;
|
|
|
|
case 3: aPt=maRect.LeftCenter(); aPt.X()-=nWdt; break;
|
2009-06-17 10:58:14 +00:00
|
|
|
}
|
2014-10-29 15:01:37 -04:00
|
|
|
if (aGeo.nShearAngle!=0) ShearPoint(aPt,maRect.TopLeft(),aGeo.nTan);
|
|
|
|
if (aGeo.nRotationAngle!=0) RotatePoint(aPt,maRect.TopLeft(),aGeo.nSin,aGeo.nCos);
|
2009-06-17 10:58:14 +00:00
|
|
|
aPt-=GetSnapRect().Center();
|
|
|
|
SdrGluePoint aGP(aPt);
|
2014-01-28 19:57:37 +01:00
|
|
|
aGP.SetPercent(false);
|
2009-06-17 10:58:14 +00:00
|
|
|
return aGP;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2004-06-28 15:20:02 +00:00
|
|
|
|
2005-02-17 08:08:18 +00:00
|
|
|
// #i38892#
|
|
|
|
void SdrObjCustomShape::ImpCheckCustomGluePointsAreAdded()
|
2004-06-28 15:20:02 +00:00
|
|
|
{
|
|
|
|
const SdrObject* pSdrObject = GetSdrObjectFromCustomShape();
|
2005-02-17 08:08:18 +00:00
|
|
|
|
|
|
|
if(pSdrObject)
|
2004-06-28 15:20:02 +00:00
|
|
|
{
|
|
|
|
const SdrGluePointList* pSource = pSdrObject->GetGluePointList();
|
2005-02-17 08:08:18 +00:00
|
|
|
|
|
|
|
if(pSource && pSource->GetCount())
|
|
|
|
{
|
|
|
|
if(!SdrTextObj::GetGluePointList())
|
|
|
|
{
|
|
|
|
SdrTextObj::ForceGluePointList();
|
|
|
|
}
|
|
|
|
|
2006-06-19 15:40:23 +00:00
|
|
|
const SdrGluePointList* pList = SdrTextObj::GetGluePointList();
|
2005-02-17 08:08:18 +00:00
|
|
|
|
|
|
|
if(pList)
|
|
|
|
{
|
|
|
|
SdrGluePointList aNewList;
|
|
|
|
sal_uInt16 a;
|
|
|
|
|
|
|
|
for(a = 0; a < pSource->GetCount(); a++)
|
|
|
|
{
|
|
|
|
SdrGluePoint aCopy((*pSource)[a]);
|
2014-01-28 19:57:37 +01:00
|
|
|
aCopy.SetUserDefined(false);
|
2005-02-17 08:08:18 +00:00
|
|
|
aNewList.Insert(aCopy);
|
|
|
|
}
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bMirroredX = IsMirroredX();
|
|
|
|
bool bMirroredY = IsMirroredY();
|
2009-06-17 10:58:14 +00:00
|
|
|
|
2014-10-21 08:56:06 +02:00
|
|
|
long nShearAngle = aGeo.nShearAngle;
|
2009-06-17 10:58:14 +00:00
|
|
|
double fTan = aGeo.nTan;
|
|
|
|
|
2014-10-21 08:56:06 +02:00
|
|
|
if ( aGeo.nRotationAngle || nShearAngle || bMirroredX || bMirroredY )
|
2009-06-17 10:58:14 +00:00
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
Polygon aPoly( maRect );
|
2014-10-21 08:56:06 +02:00
|
|
|
if( nShearAngle )
|
2009-06-17 10:58:14 +00:00
|
|
|
{
|
2011-01-10 16:11:35 +01:00
|
|
|
sal_uInt16 nPointCount=aPoly.GetSize();
|
|
|
|
for (sal_uInt16 i=0; i<nPointCount; i++)
|
2014-10-29 15:01:37 -04:00
|
|
|
ShearPoint(aPoly[i],maRect.Center(), fTan, false );
|
2009-06-17 10:58:14 +00:00
|
|
|
}
|
2014-10-15 07:53:32 +02:00
|
|
|
if ( aGeo.nRotationAngle )
|
2014-10-29 15:01:37 -04:00
|
|
|
aPoly.Rotate( maRect.Center(), aGeo.nRotationAngle / 10 );
|
2009-06-17 10:58:14 +00:00
|
|
|
|
|
|
|
Rectangle aBoundRect( aPoly.GetBoundRect() );
|
2014-10-29 15:01:37 -04:00
|
|
|
sal_Int32 nXDiff = aBoundRect.Left() - maRect.Left();
|
|
|
|
sal_Int32 nYDiff = aBoundRect.Top() - maRect.Top();
|
2009-06-17 10:58:14 +00:00
|
|
|
|
2014-10-21 08:56:06 +02:00
|
|
|
if (nShearAngle&&((bMirroredX&&!bMirroredY)||(bMirroredY&&!bMirroredX)))
|
2009-06-17 10:58:14 +00:00
|
|
|
{
|
2014-10-21 08:56:06 +02:00
|
|
|
nShearAngle = -nShearAngle;
|
2009-06-17 10:58:14 +00:00
|
|
|
fTan = -fTan;
|
|
|
|
}
|
|
|
|
|
2014-10-29 15:01:37 -04:00
|
|
|
Point aRef( maRect.GetWidth() / 2, maRect.GetHeight() / 2 );
|
2009-06-17 10:58:14 +00:00
|
|
|
for ( a = 0; a < aNewList.GetCount(); a++ )
|
|
|
|
{
|
|
|
|
SdrGluePoint& rPoint = aNewList[ a ];
|
|
|
|
Point aGlue( rPoint.GetPos() );
|
2014-10-21 08:56:06 +02:00
|
|
|
if ( nShearAngle )
|
2009-06-17 10:58:14 +00:00
|
|
|
ShearPoint( aGlue, aRef, fTan );
|
|
|
|
|
|
|
|
RotatePoint( aGlue, aRef, sin( fObjectRotation * F_PI180 ), cos( fObjectRotation * F_PI180 ) );
|
|
|
|
if ( bMirroredX )
|
2014-10-29 15:01:37 -04:00
|
|
|
aGlue.X() = maRect.GetWidth() - aGlue.X();
|
2009-06-17 10:58:14 +00:00
|
|
|
if ( bMirroredY )
|
2014-10-29 15:01:37 -04:00
|
|
|
aGlue.Y() = maRect.GetHeight() - aGlue.Y();
|
2009-06-17 10:58:14 +00:00
|
|
|
aGlue.X() -= nXDiff;
|
|
|
|
aGlue.Y() -= nYDiff;
|
|
|
|
rPoint.SetPos( aGlue );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2005-02-17 08:08:18 +00:00
|
|
|
for(a = 0; a < pList->GetCount(); a++)
|
|
|
|
{
|
|
|
|
const SdrGluePoint& rCandidate = (*pList)[a];
|
|
|
|
|
|
|
|
if(rCandidate.IsUserDefined())
|
|
|
|
{
|
|
|
|
aNewList.Insert(rCandidate);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// copy new list to local. This is NOT very convenient behavior, the local
|
|
|
|
// GluePointList should not be set, but we delivered by using GetGluePointList(),
|
2006-06-19 15:40:23 +00:00
|
|
|
// maybe on demand. Since the local object is changed here, this is assumed to
|
|
|
|
// be a result of GetGluePointList and thus the list is copied
|
|
|
|
if(pPlusData)
|
|
|
|
{
|
2012-01-31 13:39:16 -05:00
|
|
|
pPlusData->SetGluePoints(aNewList);
|
2006-06-19 15:40:23 +00:00
|
|
|
}
|
2005-02-17 08:08:18 +00:00
|
|
|
}
|
|
|
|
}
|
2004-06-28 15:20:02 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2005-02-17 08:08:18 +00:00
|
|
|
// #i38892#
|
|
|
|
const SdrGluePointList* SdrObjCustomShape::GetGluePointList() const
|
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
const_cast<SdrObjCustomShape*>(this)->ImpCheckCustomGluePointsAreAdded();
|
2005-02-17 08:08:18 +00:00
|
|
|
return SdrTextObj::GetGluePointList();
|
|
|
|
}
|
|
|
|
|
|
|
|
// #i38892#
|
2004-06-28 15:20:02 +00:00
|
|
|
SdrGluePointList* SdrObjCustomShape::ForceGluePointList()
|
|
|
|
{
|
2005-02-17 08:08:18 +00:00
|
|
|
if(SdrTextObj::ForceGluePointList())
|
2004-06-28 15:20:02 +00:00
|
|
|
{
|
2005-02-17 08:08:18 +00:00
|
|
|
ImpCheckCustomGluePointsAreAdded();
|
|
|
|
return SdrTextObj::ForceGluePointList();
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
return 0L;
|
2004-06-28 15:20:02 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2006-11-14 12:44:11 +00:00
|
|
|
sal_uInt32 SdrObjCustomShape::GetHdlCount() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2006-11-14 12:44:11 +00:00
|
|
|
const sal_uInt32 nBasicHdlCount(SdrTextObj::GetHdlCount());
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2006-11-14 12:44:11 +00:00
|
|
|
return ( aInteractionHandles.size() + nBasicHdlCount );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2006-11-14 12:44:11 +00:00
|
|
|
SdrHdl* SdrObjCustomShape::GetHdl( sal_uInt32 nHdlNum ) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
SdrHdl* pH = NULL;
|
2006-11-14 12:44:11 +00:00
|
|
|
const sal_uInt32 nBasicHdlCount(SdrTextObj::GetHdlCount());
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
if ( nHdlNum < nBasicHdlCount )
|
|
|
|
pH = SdrTextObj::GetHdl( nHdlNum );
|
|
|
|
else
|
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2006-11-14 12:44:11 +00:00
|
|
|
const sal_uInt32 nCustomShapeHdlNum(nHdlNum - nBasicHdlCount);
|
|
|
|
|
2005-09-28 11:40:42 +00:00
|
|
|
if ( nCustomShapeHdlNum < aInteractionHandles.size() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
if ( aInteractionHandles[ nCustomShapeHdlNum ].xInteraction.is() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
try
|
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
com::sun::star::awt::Point aPosition( aInteractionHandles[ nCustomShapeHdlNum ].xInteraction->getPosition() );
|
2004-04-02 13:13:28 +00:00
|
|
|
pH = new SdrHdl( Point( aPosition.X, aPosition.Y ), HDL_CUSTOMSHAPE1 );
|
|
|
|
pH->SetPointNum( nCustomShapeHdlNum );
|
2015-05-25 11:03:10 +02:00
|
|
|
pH->SetObj( const_cast<SdrObjCustomShape*>(this) );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
catch ( const uno::RuntimeException& )
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return pH;
|
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
bool SdrObjCustomShape::hasSpecialDrag() const
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
return true;
|
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
bool SdrObjCustomShape::beginSpecialDrag(SdrDragStat& rDrag) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
const SdrHdl* pHdl = rDrag.GetHdl();
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
|
|
|
|
if(pHdl && HDL_CUSTOMSHAPE1 == pHdl->GetKind())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
rDrag.SetEndDragChangesAttributes(true);
|
|
|
|
rDrag.SetNoSnap(true);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
else
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
const SdrHdl* pHdl2 = rDrag.GetHdl();
|
|
|
|
const SdrHdlKind eHdl((pHdl2 == NULL) ? HDL_MOVE : pHdl2->GetKind());
|
2005-09-28 11:40:42 +00:00
|
|
|
|
|
|
|
switch( eHdl )
|
|
|
|
{
|
|
|
|
case HDL_UPLFT :
|
|
|
|
case HDL_UPPER :
|
|
|
|
case HDL_UPRGT :
|
|
|
|
case HDL_LEFT :
|
|
|
|
case HDL_RIGHT :
|
|
|
|
case HDL_LWLFT :
|
|
|
|
case HDL_LOWER :
|
|
|
|
case HDL_LWRGT :
|
|
|
|
case HDL_MOVE :
|
|
|
|
{
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
break;
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
default:
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
{
|
|
|
|
return false;
|
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
}
|
2006-11-14 12:44:11 +00:00
|
|
|
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
return true;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-07-11 09:19:59 +02:00
|
|
|
void SdrObjCustomShape::DragResizeCustomShape( const Rectangle& rNewRect )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
Rectangle aOld( maRect );
|
2014-07-11 09:19:59 +02:00
|
|
|
bool bOldMirroredX( IsMirroredX() );
|
|
|
|
bool bOldMirroredY( IsMirroredY() );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
|
|
|
Rectangle aNewRect( rNewRect );
|
|
|
|
aNewRect.Justify();
|
|
|
|
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2014-07-11 09:19:59 +02:00
|
|
|
GeoStat aGeoStat( GetGeoStat() );
|
2014-10-29 15:01:37 -04:00
|
|
|
if ( aNewRect.TopLeft()!= maRect.TopLeft() &&
|
2014-10-21 08:56:06 +02:00
|
|
|
( aGeo.nRotationAngle || aGeo.nShearAngle ) )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
Point aNewPos( aNewRect.TopLeft() );
|
2014-10-21 08:56:06 +02:00
|
|
|
if ( aGeo.nShearAngle ) ShearPoint( aNewPos, aOld.TopLeft(), aGeoStat.nTan );
|
2014-10-15 07:53:32 +02:00
|
|
|
if ( aGeo.nRotationAngle ) RotatePoint(aNewPos, aOld.TopLeft(), aGeoStat.nSin, aGeoStat.nCos );
|
2005-09-28 11:40:42 +00:00
|
|
|
aNewRect.SetPos( aNewPos );
|
|
|
|
}
|
2014-10-29 15:01:37 -04:00
|
|
|
if ( aNewRect != maRect )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
SetLogicRect( aNewRect );
|
|
|
|
InvalidateRenderGeometry();
|
2005-09-28 11:40:42 +00:00
|
|
|
|
|
|
|
if ( rNewRect.Left() > rNewRect.Right() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
Point aTop( ( GetSnapRect().Left() + GetSnapRect().Right() ) >> 1, GetSnapRect().Top() );
|
2005-09-28 11:40:42 +00:00
|
|
|
Point aBottom( aTop.X(), aTop.Y() + 1000 );
|
2014-07-11 09:19:59 +02:00
|
|
|
NbcMirror( aTop, aBottom );
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
if ( rNewRect.Top() > rNewRect.Bottom() )
|
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
Point aLeft( GetSnapRect().Left(), ( GetSnapRect().Top() + GetSnapRect().Bottom() ) >> 1 );
|
2005-09-28 11:40:42 +00:00
|
|
|
Point aRight( aLeft.X() + 1000, aLeft.Y() );
|
2014-07-11 09:19:59 +02:00
|
|
|
NbcMirror( aLeft, aRight );
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
2009-06-17 10:58:14 +00:00
|
|
|
|
2013-03-30 17:39:58 +01:00
|
|
|
for (std::vector< SdrCustomShapeInteraction >::const_iterator aIter( aInteractionHandles.begin() ), aEnd( aInteractionHandles.end() );
|
|
|
|
aIter != aEnd ; ++aIter )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
try
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_FIXED )
|
2005-09-28 11:40:42 +00:00
|
|
|
aIter->xInteraction->setControllerPosition( aIter->aPosition );
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_ABSOLUTE_X )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
sal_Int32 nX;
|
|
|
|
if ( bOldMirroredX )
|
|
|
|
{
|
|
|
|
nX = ( aIter->aPosition.X - aOld.Right() );
|
|
|
|
if ( rNewRect.Left() > rNewRect.Right() )
|
2014-10-29 15:01:37 -04:00
|
|
|
nX = maRect.Left() - nX;
|
2005-09-28 11:40:42 +00:00
|
|
|
else
|
2014-10-29 15:01:37 -04:00
|
|
|
nX += maRect.Right();
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
nX = ( aIter->aPosition.X - aOld.Left() );
|
|
|
|
if ( rNewRect.Left() > rNewRect.Right() )
|
2014-10-29 15:01:37 -04:00
|
|
|
nX = maRect.Right() - nX;
|
2005-09-28 11:40:42 +00:00
|
|
|
else
|
2014-10-29 15:01:37 -04:00
|
|
|
nX += maRect.Left();
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
aIter->xInteraction->setControllerPosition( com::sun::star::awt::Point( nX, aIter->xInteraction->getPosition().Y ) );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_ABSOLUTE_Y )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
sal_Int32 nY;
|
|
|
|
if ( bOldMirroredY )
|
|
|
|
{
|
|
|
|
nY = ( aIter->aPosition.Y - aOld.Bottom() );
|
|
|
|
if ( rNewRect.Top() > rNewRect.Bottom() )
|
2014-10-29 15:01:37 -04:00
|
|
|
nY = maRect.Top() - nY;
|
2005-09-28 11:40:42 +00:00
|
|
|
else
|
2014-10-29 15:01:37 -04:00
|
|
|
nY += maRect.Bottom();
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
nY = ( aIter->aPosition.Y - aOld.Top() );
|
|
|
|
if ( rNewRect.Top() > rNewRect.Bottom() )
|
2014-10-29 15:01:37 -04:00
|
|
|
nY = maRect.Bottom() - nY;
|
2005-09-28 11:40:42 +00:00
|
|
|
else
|
2014-10-29 15:01:37 -04:00
|
|
|
nY += maRect.Top();
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
aIter->xInteraction->setControllerPosition( com::sun::star::awt::Point( aIter->xInteraction->getPosition().X, nY ) );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
catch ( const uno::RuntimeException& )
|
|
|
|
{
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2015-03-09 10:11:00 +00:00
|
|
|
void SdrObjCustomShape::DragMoveCustomShapeHdl( const Point& rDestination,
|
2014-07-11 09:19:59 +02:00
|
|
|
const sal_uInt16 nCustomShapeHdlNum, bool bMoveCalloutRectangle )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2005-09-28 11:40:42 +00:00
|
|
|
if ( nCustomShapeHdlNum < aInteractionHandles.size() )
|
|
|
|
{
|
|
|
|
SdrCustomShapeInteraction aInteractionHandle( aInteractionHandles[ nCustomShapeHdlNum ] );
|
|
|
|
if ( aInteractionHandle.xInteraction.is() )
|
|
|
|
{
|
|
|
|
try
|
|
|
|
{
|
2015-03-09 10:11:00 +00:00
|
|
|
com::sun::star::awt::Point aPt( rDestination.X(), rDestination.Y() );
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aInteractionHandle.nMode & CustomShapeHandleModes::MOVE_SHAPE && bMoveCalloutRectangle )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
sal_Int32 nXDiff = aPt.X - aInteractionHandle.aPosition.X;
|
|
|
|
sal_Int32 nYDiff = aPt.Y - aInteractionHandle.aPosition.Y;
|
|
|
|
|
2014-10-29 15:01:37 -04:00
|
|
|
maRect.Move( nXDiff, nYDiff );
|
2014-07-11 09:19:59 +02:00
|
|
|
aOutRect.Move( nXDiff, nYDiff );
|
|
|
|
maSnapRect.Move( nXDiff, nYDiff );
|
|
|
|
SetRectsDirty(true);
|
|
|
|
InvalidateRenderGeometry();
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2013-03-30 17:39:58 +01:00
|
|
|
for (std::vector< SdrCustomShapeInteraction >::const_iterator aIter( aInteractionHandles.begin() ), aEnd( aInteractionHandles.end() ) ;
|
|
|
|
aIter != aEnd; ++aIter)
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_FIXED )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
if ( aIter->xInteraction.is() )
|
|
|
|
aIter->xInteraction->setControllerPosition( aIter->aPosition );
|
|
|
|
}
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
aInteractionHandle.xInteraction->setControllerPosition( aPt );
|
|
|
|
}
|
|
|
|
catch ( const uno::RuntimeException& )
|
|
|
|
{
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
bool SdrObjCustomShape::applySpecialDrag(SdrDragStat& rDrag)
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
const SdrHdl* pHdl = rDrag.GetHdl();
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
const SdrHdlKind eHdl((pHdl == NULL) ? HDL_MOVE : pHdl->GetKind());
|
2006-11-14 12:44:11 +00:00
|
|
|
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
switch(eHdl)
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
case HDL_CUSTOMSHAPE1 :
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
rDrag.SetEndDragChangesGeoAndAttributes(true);
|
2014-07-11 09:19:59 +02:00
|
|
|
DragMoveCustomShapeHdl( rDrag.GetNow(), (sal_uInt16)pHdl->GetPointNum(), !rDrag.GetDragMethod()->IsShiftPressed() );
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
SetRectsDirty();
|
|
|
|
InvalidateRenderGeometry();
|
|
|
|
SetChanged();
|
2005-09-28 11:40:42 +00:00
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
case HDL_UPLFT :
|
|
|
|
case HDL_UPPER :
|
|
|
|
case HDL_UPRGT :
|
|
|
|
case HDL_LEFT :
|
|
|
|
case HDL_RIGHT :
|
|
|
|
case HDL_LWLFT :
|
|
|
|
case HDL_LOWER :
|
|
|
|
case HDL_LWRGT :
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
DragResizeCustomShape( ImpDragCalcRect(rDrag) );
|
2005-09-28 11:40:42 +00:00
|
|
|
break;
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
}
|
|
|
|
case HDL_MOVE :
|
|
|
|
{
|
|
|
|
Move(Size(rDrag.GetDX(), rDrag.GetDY()));
|
2005-09-28 11:40:42 +00:00
|
|
|
break;
|
|
|
|
}
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
default: break;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2006-11-14 12:44:11 +00:00
|
|
|
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
return true;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2005-09-28 11:40:42 +00:00
|
|
|
|
|
|
|
void SdrObjCustomShape::DragCreateObject( SdrDragStat& rStat )
|
|
|
|
{
|
|
|
|
Rectangle aRect1;
|
|
|
|
rStat.TakeCreateRect( aRect1 );
|
|
|
|
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
|
|
|
sal_uInt32 nDefaultObjectSizeWidth = 3000; // default width from SDOptions ?
|
|
|
|
sal_uInt32 nDefaultObjectSizeHeight= 3000;
|
|
|
|
|
|
|
|
if ( ImpVerticalSwitch( *this ) )
|
|
|
|
{
|
|
|
|
SetMirroredX( aRect1.Left() > aRect1.Right() );
|
|
|
|
|
|
|
|
aRect1 = Rectangle( rStat.GetNow(), Size( nDefaultObjectSizeWidth, nDefaultObjectSizeHeight ) );
|
|
|
|
// subtracting the horizontal difference of the latest handle from shape position
|
2011-12-06 01:28:00 +01:00
|
|
|
if ( !aInteractionHandles.empty() )
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
sal_Int32 nHandlePos = aInteractionHandles[ aInteractionHandles.size() - 1 ].xInteraction->getPosition().X;
|
2014-10-29 15:01:37 -04:00
|
|
|
aRect1.Move( maRect.Left() - nHandlePos, 0 );
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
ImpJustifyRect( aRect1 );
|
|
|
|
rStat.SetActionRect( aRect1 );
|
2014-10-29 15:01:37 -04:00
|
|
|
maRect = aRect1;
|
2005-09-28 11:40:42 +00:00
|
|
|
SetRectsDirty();
|
|
|
|
|
2013-03-30 17:39:58 +01:00
|
|
|
for (std::vector< SdrCustomShapeInteraction >::const_iterator aIter( aInteractionHandles.begin() ), aEnd( aInteractionHandles.end() );
|
|
|
|
aIter != aEnd ; ++aIter)
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
try
|
|
|
|
{
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::CREATE_FIXED )
|
2005-09-28 11:40:42 +00:00
|
|
|
aIter->xInteraction->setControllerPosition( awt::Point( rStat.GetStart().X(), rStat.GetStart().Y() ) );
|
|
|
|
}
|
|
|
|
catch ( const uno::RuntimeException& )
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2008-08-19 22:22:03 +00:00
|
|
|
SetBoundRectDirty();
|
2014-01-28 19:57:37 +01:00
|
|
|
bSnapRectDirty=true;
|
2005-09-28 11:40:42 +00:00
|
|
|
}
|
|
|
|
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::BegCreate( SdrDragStat& rDrag )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
return SdrTextObj::BegCreate( rDrag );
|
|
|
|
}
|
|
|
|
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::MovCreate(SdrDragStat& rStat)
|
2004-12-13 07:56:11 +00:00
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
SdrView* pView = rStat.GetView(); // #i37448#
|
2006-11-14 12:44:11 +00:00
|
|
|
if( pView && pView->IsSolidDragging() )
|
2004-12-13 07:56:11 +00:00
|
|
|
{
|
|
|
|
InvalidateRenderGeometry();
|
|
|
|
}
|
2005-09-28 11:40:42 +00:00
|
|
|
DragCreateObject( rStat );
|
|
|
|
SetRectsDirty();
|
2014-01-28 19:57:37 +01:00
|
|
|
return true;
|
2004-12-13 07:56:11 +00:00
|
|
|
}
|
|
|
|
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::EndCreate( SdrDragStat& rStat, SdrCreateCmd eCmd )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
DragCreateObject( rStat );
|
|
|
|
|
2013-09-19 10:11:03 +00:00
|
|
|
// #115391#
|
|
|
|
AdaptTextMinSize();
|
|
|
|
|
2005-09-28 11:40:42 +00:00
|
|
|
SetRectsDirty();
|
|
|
|
return ( eCmd == SDRCREATE_FORCEEND || rStat.GetPointAnz() >= 2 );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2006-11-14 12:44:11 +00:00
|
|
|
basegfx::B2DPolyPolygon SdrObjCustomShape::TakeCreatePoly(const SdrDragStat& /*rDrag*/) const
|
2004-10-12 13:17:22 +00:00
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
return GetLineGeometry( false );
|
2004-10-12 13:17:22 +00:00
|
|
|
}
|
|
|
|
|
2014-02-25 20:51:35 +01:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
// in context with the SdrObjCustomShape the SdrTextAutoGrowHeightItem == true -> Resize Shape to fit text,
|
|
|
|
// the SdrTextAutoGrowWidthItem == true -> Word wrap text in Shape
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::IsAutoGrowHeight() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
const SfxItemSet& rSet = GetMergedItemSet();
|
2014-10-17 10:35:35 +02:00
|
|
|
bool bIsAutoGrowHeight = static_cast<const SdrOnOffItem&>(rSet.Get(SDRATTR_TEXT_AUTOGROWHEIGHT)).GetValue();
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( bIsAutoGrowHeight && IsVerticalWriting() )
|
2014-10-17 10:35:35 +02:00
|
|
|
bIsAutoGrowHeight = !static_cast<const SdrOnOffItem&>(rSet.Get(SDRATTR_TEXT_WORDWRAP)).GetValue();
|
2004-04-02 13:13:28 +00:00
|
|
|
return bIsAutoGrowHeight;
|
|
|
|
}
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::IsAutoGrowWidth() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
const SfxItemSet& rSet = GetMergedItemSet();
|
2014-10-17 10:35:35 +02:00
|
|
|
bool bIsAutoGrowWidth = static_cast<const SdrOnOffItem&>(rSet.Get(SDRATTR_TEXT_AUTOGROWHEIGHT)).GetValue();
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( bIsAutoGrowWidth && !IsVerticalWriting() )
|
2014-10-17 10:35:35 +02:00
|
|
|
bIsAutoGrowWidth = !static_cast<const SdrOnOffItem&>(rSet.Get(SDRATTR_TEXT_WORDWRAP)).GetValue();
|
2004-04-02 13:13:28 +00:00
|
|
|
return bIsAutoGrowWidth;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* The following method is identical to the SdrTextObj::SetVerticalWriting method, the only difference
|
|
|
|
is that the SdrAutoGrowWidthItem and SdrAutoGrowHeightItem are not exchanged if the vertical writing
|
|
|
|
mode has been changed */
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
void SdrObjCustomShape::SetVerticalWriting( bool bVertical )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
ForceOutlinerParaObject();
|
|
|
|
|
2008-03-12 08:54:16 +00:00
|
|
|
OutlinerParaObject* pOutlinerParaObject = GetOutlinerParaObject();
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
DBG_ASSERT( pOutlinerParaObject, "SdrTextObj::SetVerticalWriting() without OutlinerParaObject!" );
|
|
|
|
|
|
|
|
if( pOutlinerParaObject )
|
|
|
|
{
|
CWS-TOOLING: integrate CWS aw063
2009-02-12 13:10:24 +0100 aw r267649 : #i99123# when a primitive is invisible, it is not sufficient to produce no output when decomposing, but to add invisible data using HitTestPrimitive2D. This is needed for the slideshow which relies on geometry data in MetaFiles when painting invisible objects
2009-02-12 13:08:39 +0100 aw r267648 : #i99123# do not ignore HitTestPrimitive2D, but draw empty rectangles instead. This is needed since Slideshow is based on getting MetaFile content when painting invisible objects
2009-02-11 16:04:28 +0100 aw r267620 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:04:10 +0100 aw r267619 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:03:56 +0100 aw r267618 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:03:39 +0100 aw r267617 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:03:21 +0100 aw r267615 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:02:48 +0100 aw r267614 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:02:24 +0100 aw r267613 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:02:01 +0100 aw r267612 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:01:32 +0100 aw r267611 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:01:05 +0100 aw r267610 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 16:00:15 +0100 aw r267608 : #i98788# made SfxItemPool destructor protected, added static ::Free method
2009-02-11 11:27:33 +0100 aw r267585 : #i98788# added missing include for STL
2009-02-10 17:46:50 +0100 aw r267570 : #i98788# added reaction on pool destruction
2009-02-10 17:11:58 +0100 aw r267562 : #i98788# added messaging mechanism to register for pool destruction
2009-02-10 13:35:35 +0100 aw r267549 : #i98788# removing changes, too complicated and risky for 3.1
2009-02-10 12:13:48 +0100 aw r267546 : #i98788# 4th round
2009-02-10 12:13:37 +0100 aw r267545 : #i98788# 4th round
2009-02-10 12:13:26 +0100 aw r267544 : #i98788# 4th round
2009-02-10 12:13:14 +0100 aw r267543 : #i98788# 4th round
2009-02-10 12:13:03 +0100 aw r267542 : #i98788# 4th round
2009-02-10 12:12:50 +0100 aw r267541 : #i98788# 4th round
2009-02-10 12:12:37 +0100 aw r267540 : #i98788# 4th round
2009-02-08 14:38:22 +0100 aw r267495 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:38:06 +0100 aw r267494 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:37:48 +0100 aw r267493 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:37:17 +0100 aw r267492 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:36:56 +0100 aw r267491 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:36:44 +0100 aw r267490 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:36:29 +0100 aw r267489 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:36:16 +0100 aw r267488 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:36:02 +0100 aw r267487 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-08 14:35:46 +0100 aw r267486 : #i98788# 3rd round of changes to SfxItemPool handling
2009-02-05 12:20:39 +0100 aw r267415 : #i98788# 2nd batch of adaptions for SfxItemPoolHolder addition
2009-02-04 15:12:54 +0100 aw r267385 : #i98788# added newline at EOF
2009-02-04 13:26:04 +0100 aw r267379 : #i98788# make SfxItemPool holdable
2009-02-04 13:25:40 +0100 aw r267378 : #i98788# make SfxItemPool holdable
2009-02-04 13:25:08 +0100 aw r267377 : #i98788# make SfxItemPool holdable
2009-02-04 13:24:42 +0100 aw r267376 : #i98788# make SfxItemPool holdable
2009-02-04 13:23:14 +0100 aw r267375 : #i98788# make SfxItemPool holdable
2009-02-04 13:23:02 +0100 aw r267374 : #i98788# make SfxItemPool holdable
2009-01-29 17:08:31 +0100 aw r267159 : #i97628# completed the fix
2009-01-29 17:08:15 +0100 aw r267158 : #i97628# completed the fix
2009-01-29 14:09:07 +0100 aw r267132 : #i97628# Corrected usage of ParagraphData in headers
2009-01-29 14:06:58 +0100 iha r267131 : #i98344# incorrect font size in charts
2009-01-29 12:13:46 +0100 aw r267115 : #i97628# back to old state; triggers too many errors in other modules
2009-01-29 12:03:51 +0100 aw r267114 : #i97628# enabled exceptions due to STL vector include
2009-01-29 11:21:37 +0100 aw r267107 : #i97628# added needed include
2009-01-28 17:58:29 +0100 aw r267077 : #i97628# first version of newly implemented OutlinerParaObject and adaptions
2009-01-28 17:58:12 +0100 aw r267076 : #i97628# first version of newly implemented OutlinerParaObject and adaptions
2009-01-28 17:57:51 +0100 aw r267074 : #i97628# first version of newly implemented OutlinerParaObject and adaptions
2009-01-28 17:57:21 +0100 aw r267073 : #i97628# first version of newly implemented OutlinerParaObject and adaptions
2009-01-27 17:07:33 +0100 aw r267011 : #i98402# added support for ViewRange when exporting MetaFiles in ObjectContactOfPageView::DoProcessDisplay to avoid to paint too much
2009-01-27 11:45:48 +0100 aw r266973 : #i98404# Added a warning to a place where a conversion to rectangle should not be copied from
2009-01-26 21:44:36 +0100 iha r266949 : #i98497# 3D charts are rendered with wrong size
2009-01-26 20:47:07 +0100 aw r266947 : #i98404# handle BackgroundColorPrimitive2D directly in PixelRenderers and avoid AA under all circumstances
2009-01-26 14:50:36 +0100 aw r266926 : #i98386# secured cloning of SdrObject in IMapUserData by boost::shared_prt usage
2009-01-26 12:51:30 +0100 aw r266916 : #i96581# added separated FontStretching and fallback for small X!=Y scale differences
2009-01-23 16:14:55 +0100 aw r266834 : #i96475# added missing implementation of TextDecoratedPortionPrimitive2D::getB2DRange
2009-01-23 15:24:34 +0100 aw r266826 : #i98405# fixed fallback to DrawAlphaRect to use the correctly sized rectangle
2009-01-23 13:34:43 +0100 aw r266813 : #i96474# fixed impSplitSingleWords for an unexpected case
2009-01-23 10:47:31 +0100 aw r266786 : #i98289#,#i96474# tooling and new flags for tasks
2009-01-23 10:47:20 +0100 aw r266785 : #i98289#,#i96474# tooling and new flags for tasks
2009-01-23 10:47:09 +0100 aw r266783 : #i98289#,#i96474# tooling and new flags for tasks
2009-01-23 10:46:58 +0100 aw r266782 : #i98289#,#i96474# tooling and new flags for tasks
2009-01-23 10:46:48 +0100 aw r266781 : #i98289#,#i96474# tooling and new flags for tasks
2009-03-04 14:16:02 +00:00
|
|
|
if(pOutlinerParaObject->IsVertical() != (bool)bVertical)
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
// get item settings
|
|
|
|
const SfxItemSet& rSet = GetObjectItemSet();
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// Also exchange horizontal and vertical adjust items
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrTextHorzAdjust eHorz = static_cast<const SdrTextHorzAdjustItem&>(rSet.Get(SDRATTR_TEXT_HORZADJUST)).GetValue();
|
|
|
|
SdrTextVertAdjust eVert = static_cast<const SdrTextVertAdjustItem&>(rSet.Get(SDRATTR_TEXT_VERTADJUST)).GetValue();
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
// rescue object size
|
|
|
|
Rectangle aObjectRect = GetSnapRect();
|
|
|
|
|
|
|
|
// prepare ItemSet to set exchanged width and height items
|
|
|
|
SfxItemSet aNewSet(*rSet.GetPool(),
|
|
|
|
SDRATTR_TEXT_AUTOGROWHEIGHT, SDRATTR_TEXT_AUTOGROWHEIGHT,
|
2011-11-27 23:21:00 +01:00
|
|
|
// Expanded item ranges to also support horizontal and vertical adjust.
|
2004-04-02 13:13:28 +00:00
|
|
|
SDRATTR_TEXT_VERTADJUST, SDRATTR_TEXT_VERTADJUST,
|
|
|
|
SDRATTR_TEXT_AUTOGROWWIDTH, SDRATTR_TEXT_HORZADJUST,
|
|
|
|
0, 0);
|
|
|
|
|
|
|
|
aNewSet.Put(rSet);
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// Exchange horizontal and vertical adjusts
|
2004-04-02 13:13:28 +00:00
|
|
|
switch(eVert)
|
|
|
|
{
|
|
|
|
case SDRTEXTVERTADJUST_TOP: aNewSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_RIGHT)); break;
|
|
|
|
case SDRTEXTVERTADJUST_CENTER: aNewSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_CENTER)); break;
|
|
|
|
case SDRTEXTVERTADJUST_BOTTOM: aNewSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_LEFT)); break;
|
|
|
|
case SDRTEXTVERTADJUST_BLOCK: aNewSet.Put(SdrTextHorzAdjustItem(SDRTEXTHORZADJUST_BLOCK)); break;
|
|
|
|
}
|
|
|
|
switch(eHorz)
|
|
|
|
{
|
|
|
|
case SDRTEXTHORZADJUST_LEFT: aNewSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_BOTTOM)); break;
|
|
|
|
case SDRTEXTHORZADJUST_CENTER: aNewSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_CENTER)); break;
|
|
|
|
case SDRTEXTHORZADJUST_RIGHT: aNewSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_TOP)); break;
|
|
|
|
case SDRTEXTHORZADJUST_BLOCK: aNewSet.Put(SdrTextVertAdjustItem(SDRTEXTVERTADJUST_BLOCK)); break;
|
|
|
|
}
|
|
|
|
|
2008-07-01 22:19:15 +00:00
|
|
|
pOutlinerParaObject = GetOutlinerParaObject();
|
|
|
|
if ( pOutlinerParaObject )
|
|
|
|
pOutlinerParaObject->SetVertical(bVertical);
|
2014-01-17 15:45:31 +00:00
|
|
|
SetObjectItemSet( aNewSet );
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
// restore object size
|
|
|
|
SetSnapRect(aObjectRect);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2014-06-27 13:43:13 +02:00
|
|
|
|
|
|
|
void SdrObjCustomShape::SuggestTextFrameSize(Size aSuggestedTextFrameSize)
|
|
|
|
{
|
|
|
|
m_aSuggestedTextFrameSize = aSuggestedTextFrameSize;
|
|
|
|
}
|
|
|
|
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::AdjustTextFrameWidthAndHeight(Rectangle& rR, bool bHgt, bool bWdt) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-06-27 13:43:13 +02:00
|
|
|
// Either we have text or the application has native text and suggested its size to us.
|
|
|
|
bool bHasText = HasText() || (m_aSuggestedTextFrameSize.Width() != 0 && m_aSuggestedTextFrameSize.Height() != 0);
|
|
|
|
if ( pModel && bHasText && !rR.IsEmpty() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2010-10-05 07:57:54 -05:00
|
|
|
bool bWdtGrow=bWdt && IsAutoGrowWidth();
|
|
|
|
bool bHgtGrow=bHgt && IsAutoGrowHeight();
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( bWdtGrow || bHgtGrow )
|
|
|
|
{
|
|
|
|
Rectangle aR0(rR);
|
|
|
|
long nHgt=0,nMinHgt=0,nMaxHgt=0;
|
|
|
|
long nWdt=0,nMinWdt=0,nMaxWdt=0;
|
|
|
|
Size aSiz(rR.GetSize()); aSiz.Width()--; aSiz.Height()--;
|
|
|
|
Size aMaxSiz(100000,100000);
|
|
|
|
Size aTmpSiz(pModel->GetMaxObjSize());
|
|
|
|
if (aTmpSiz.Width()!=0) aMaxSiz.Width()=aTmpSiz.Width();
|
|
|
|
if (aTmpSiz.Height()!=0) aMaxSiz.Height()=aTmpSiz.Height();
|
|
|
|
if (bWdtGrow)
|
|
|
|
{
|
|
|
|
nMinWdt=GetMinTextFrameWidth();
|
|
|
|
nMaxWdt=GetMaxTextFrameWidth();
|
|
|
|
if (nMaxWdt==0 || nMaxWdt>aMaxSiz.Width()) nMaxWdt=aMaxSiz.Width();
|
|
|
|
if (nMinWdt<=0) nMinWdt=1;
|
|
|
|
aSiz.Width()=nMaxWdt;
|
|
|
|
}
|
|
|
|
if (bHgtGrow)
|
|
|
|
{
|
|
|
|
nMinHgt=GetMinTextFrameHeight();
|
|
|
|
nMaxHgt=GetMaxTextFrameHeight();
|
|
|
|
if (nMaxHgt==0 || nMaxHgt>aMaxSiz.Height()) nMaxHgt=aMaxSiz.Height();
|
|
|
|
if (nMinHgt<=0) nMinHgt=1;
|
|
|
|
aSiz.Height()=nMaxHgt;
|
|
|
|
}
|
|
|
|
long nHDist=GetTextLeftDistance()+GetTextRightDistance();
|
|
|
|
long nVDist=GetTextUpperDistance()+GetTextLowerDistance();
|
|
|
|
aSiz.Width()-=nHDist;
|
|
|
|
aSiz.Height()-=nVDist;
|
|
|
|
if ( aSiz.Width() < 2 )
|
2011-11-27 23:21:00 +01:00
|
|
|
aSiz.Width() = 2; // minimum size=2
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( aSiz.Height() < 2 )
|
2011-11-27 23:21:00 +01:00
|
|
|
aSiz.Height() = 2; // minimum size=2
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2014-06-27 13:43:13 +02:00
|
|
|
if (HasText())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-06-27 13:43:13 +02:00
|
|
|
if(pEdtOutl)
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-06-27 13:43:13 +02:00
|
|
|
pEdtOutl->SetMaxAutoPaperSize( aSiz );
|
|
|
|
if (bWdtGrow)
|
|
|
|
{
|
|
|
|
Size aSiz2(pEdtOutl->CalcTextSize());
|
|
|
|
nWdt=aSiz2.Width()+1; // a little more tolerance
|
|
|
|
if (bHgtGrow) nHgt=aSiz2.Height()+1; // a little more tolerance
|
|
|
|
} else
|
|
|
|
{
|
|
|
|
nHgt=pEdtOutl->GetTextHeight()+1; // a little more tolerance
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-06-27 13:43:13 +02:00
|
|
|
Outliner& rOutliner=ImpGetDrawOutliner();
|
|
|
|
rOutliner.SetPaperSize(aSiz);
|
|
|
|
rOutliner.SetUpdateMode(true);
|
|
|
|
// TODO: add the optimization with bPortionInfoChecked again.
|
|
|
|
OutlinerParaObject* pOutlinerParaObject = GetOutlinerParaObject();
|
|
|
|
if( pOutlinerParaObject != NULL )
|
|
|
|
{
|
|
|
|
rOutliner.SetText(*pOutlinerParaObject);
|
2014-10-17 10:35:35 +02:00
|
|
|
rOutliner.SetFixedCellHeight(static_cast<const SdrTextFixedCellHeightItem&>(GetMergedItem(SDRATTR_TEXT_USEFIXEDCELLHEIGHT)).GetValue());
|
2014-06-27 13:43:13 +02:00
|
|
|
}
|
|
|
|
if ( bWdtGrow )
|
|
|
|
{
|
|
|
|
Size aSiz2(rOutliner.CalcTextSize());
|
|
|
|
nWdt=aSiz2.Width()+1; // a little more tolerance
|
|
|
|
if ( bHgtGrow )
|
|
|
|
nHgt=aSiz2.Height()+1; // a little more tolerance
|
|
|
|
}
|
|
|
|
else
|
|
|
|
nHgt = rOutliner.GetTextHeight()+1; // a little more tolerance
|
|
|
|
rOutliner.Clear();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
2014-06-27 13:43:13 +02:00
|
|
|
nHgt = m_aSuggestedTextFrameSize.Height();
|
|
|
|
nWdt = m_aSuggestedTextFrameSize.Width();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
if ( nWdt < nMinWdt )
|
|
|
|
nWdt = nMinWdt;
|
|
|
|
if ( nWdt > nMaxWdt )
|
|
|
|
nWdt = nMaxWdt;
|
|
|
|
nWdt += nHDist;
|
|
|
|
if ( nWdt < 1 )
|
2011-11-27 23:21:00 +01:00
|
|
|
nWdt = 1; // nHDist may also be negative
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( nHgt < nMinHgt )
|
|
|
|
nHgt = nMinHgt;
|
|
|
|
if ( nHgt > nMaxHgt )
|
|
|
|
nHgt = nMaxHgt;
|
|
|
|
nHgt+=nVDist;
|
|
|
|
if ( nHgt < 1 )
|
2011-11-27 23:21:00 +01:00
|
|
|
nHgt = 1; // nVDist may also be negative
|
2004-04-02 13:13:28 +00:00
|
|
|
long nWdtGrow = nWdt-(rR.Right()-rR.Left());
|
|
|
|
long nHgtGrow = nHgt-(rR.Bottom()-rR.Top());
|
|
|
|
if ( nWdtGrow == 0 )
|
2014-01-28 19:57:37 +01:00
|
|
|
bWdtGrow = false;
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( nHgtGrow == 0 )
|
2014-01-28 19:57:37 +01:00
|
|
|
bHgtGrow=false;
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( bWdtGrow || bHgtGrow )
|
|
|
|
{
|
|
|
|
if ( bWdtGrow )
|
|
|
|
{
|
|
|
|
SdrTextHorzAdjust eHAdj=GetTextHorizontalAdjust();
|
|
|
|
if ( eHAdj == SDRTEXTHORZADJUST_LEFT )
|
|
|
|
rR.Right()+=nWdtGrow;
|
|
|
|
else if ( eHAdj == SDRTEXTHORZADJUST_RIGHT )
|
|
|
|
rR.Left()-=nWdtGrow;
|
|
|
|
else
|
|
|
|
{
|
|
|
|
long nWdtGrow2=nWdtGrow/2;
|
|
|
|
rR.Left()-=nWdtGrow2;
|
|
|
|
rR.Right()=rR.Left()+nWdt;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if ( bHgtGrow )
|
|
|
|
{
|
|
|
|
SdrTextVertAdjust eVAdj=GetTextVerticalAdjust();
|
|
|
|
if ( eVAdj == SDRTEXTVERTADJUST_TOP )
|
|
|
|
rR.Bottom()+=nHgtGrow;
|
|
|
|
else if ( eVAdj == SDRTEXTVERTADJUST_BOTTOM )
|
|
|
|
rR.Top()-=nHgtGrow;
|
|
|
|
else
|
|
|
|
{
|
|
|
|
long nHgtGrow2=nHgtGrow/2;
|
|
|
|
rR.Top()-=nHgtGrow2;
|
|
|
|
rR.Bottom()=rR.Top()+nHgt;
|
|
|
|
}
|
|
|
|
}
|
2014-10-15 07:53:32 +02:00
|
|
|
if ( aGeo.nRotationAngle )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
Point aD1(rR.TopLeft());
|
|
|
|
aD1-=aR0.TopLeft();
|
|
|
|
Point aD2(aD1);
|
|
|
|
RotatePoint(aD2,Point(),aGeo.nSin,aGeo.nCos);
|
|
|
|
aD2-=aD1;
|
|
|
|
rR.Move(aD2.X(),aD2.Y());
|
|
|
|
}
|
2014-01-28 19:57:37 +01:00
|
|
|
return true;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2014-01-28 19:57:37 +01:00
|
|
|
return false;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2005-07-12 12:39:20 +00:00
|
|
|
|
2010-10-05 07:57:54 -05:00
|
|
|
Rectangle SdrObjCustomShape::ImpCalculateTextFrame( const bool bHgt, const bool bWdt )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-07-12 12:39:20 +00:00
|
|
|
Rectangle aReturnValue;
|
|
|
|
|
2014-10-29 15:01:37 -04:00
|
|
|
Rectangle aOldTextRect( maRect ); // <- initial text rectangle
|
2005-07-12 12:39:20 +00:00
|
|
|
|
2014-10-29 15:01:37 -04:00
|
|
|
Rectangle aNewTextRect( maRect ); // <- new text rectangle returned from the custom shape renderer,
|
2005-07-12 12:39:20 +00:00
|
|
|
GetTextBounds( aNewTextRect ); // it depends to the current logical shape size
|
|
|
|
|
|
|
|
Rectangle aAdjustedTextRect( aNewTextRect ); // <- new text rectangle is being tested by AdjustTextFrameWidthAndHeight to ensure
|
|
|
|
if ( AdjustTextFrameWidthAndHeight( aAdjustedTextRect, bHgt, bWdt ) ) // that the new text rectangle is matching the current text size from the outliner
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-10-20 10:45:44 +01:00
|
|
|
if (aAdjustedTextRect != aNewTextRect && aOldTextRect != aAdjustedTextRect &&
|
|
|
|
aNewTextRect.GetWidth() && aNewTextRect.GetHeight())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
aReturnValue = maRect;
|
2005-07-12 12:39:20 +00:00
|
|
|
double fXScale = (double)aOldTextRect.GetWidth() / (double)aNewTextRect.GetWidth();
|
|
|
|
double fYScale = (double)aOldTextRect.GetHeight() / (double)aNewTextRect.GetHeight();
|
|
|
|
double fRightDiff = (double)( aAdjustedTextRect.Right() - aNewTextRect.Right() ) * fXScale;
|
|
|
|
double fLeftDiff = (double)( aAdjustedTextRect.Left() - aNewTextRect.Left() ) * fXScale;
|
|
|
|
double fTopDiff = (double)( aAdjustedTextRect.Top() - aNewTextRect.Top() ) * fYScale;
|
|
|
|
double fBottomDiff= (double)( aAdjustedTextRect.Bottom()- aNewTextRect.Bottom()) * fYScale;
|
|
|
|
aReturnValue.Left() += (sal_Int32)fLeftDiff;
|
|
|
|
aReturnValue.Right() += (sal_Int32)fRightDiff;
|
|
|
|
aReturnValue.Top() += (sal_Int32)fTopDiff;
|
|
|
|
aReturnValue.Bottom() += (sal_Int32)fBottomDiff;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
2005-07-12 12:39:20 +00:00
|
|
|
return aReturnValue;
|
|
|
|
}
|
|
|
|
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::NbcAdjustTextFrameWidthAndHeight(bool bHgt, bool bWdt)
|
2005-07-12 12:39:20 +00:00
|
|
|
{
|
|
|
|
Rectangle aNewTextRect = ImpCalculateTextFrame( bHgt, bWdt );
|
2014-10-29 15:01:37 -04:00
|
|
|
bool bRet = !aNewTextRect.IsEmpty() && ( aNewTextRect != maRect );
|
2005-07-12 12:39:20 +00:00
|
|
|
if ( bRet )
|
|
|
|
{
|
2005-09-28 11:40:42 +00:00
|
|
|
// taking care of handles that should not been changed
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2014-10-29 15:01:37 -04:00
|
|
|
maRect = aNewTextRect;
|
2005-07-12 12:39:20 +00:00
|
|
|
SetRectsDirty();
|
|
|
|
SetChanged();
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2013-03-30 17:39:58 +01:00
|
|
|
for (std::vector< SdrCustomShapeInteraction >::const_iterator aIter( aInteractionHandles.begin() ), aEnd ( aInteractionHandles.end() );
|
|
|
|
aIter != aEnd ; ++aIter)
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
try
|
|
|
|
{
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_FIXED )
|
2005-09-28 11:40:42 +00:00
|
|
|
aIter->xInteraction->setControllerPosition( aIter->aPosition );
|
|
|
|
}
|
|
|
|
catch ( const uno::RuntimeException& )
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
2005-07-12 12:39:20 +00:00
|
|
|
InvalidateRenderGeometry();
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
return bRet;
|
|
|
|
}
|
2010-10-05 07:57:54 -05:00
|
|
|
bool SdrObjCustomShape::AdjustTextFrameWidthAndHeight(bool bHgt, bool bWdt)
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-07-12 12:39:20 +00:00
|
|
|
Rectangle aNewTextRect = ImpCalculateTextFrame( bHgt, bWdt );
|
2014-10-29 15:01:37 -04:00
|
|
|
bool bRet = !aNewTextRect.IsEmpty() && ( aNewTextRect != maRect );
|
2005-07-12 12:39:20 +00:00
|
|
|
if ( bRet )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2005-07-12 12:39:20 +00:00
|
|
|
Rectangle aBoundRect0;
|
|
|
|
if ( pUserCall )
|
|
|
|
aBoundRect0 = GetCurrentBoundRect();
|
2005-09-28 11:40:42 +00:00
|
|
|
|
|
|
|
// taking care of handles that should not been changed
|
2014-07-11 09:19:59 +02:00
|
|
|
std::vector< SdrCustomShapeInteraction > aInteractionHandles( GetInteractionHandles() );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2014-10-29 15:01:37 -04:00
|
|
|
maRect = aNewTextRect;
|
2005-07-12 12:39:20 +00:00
|
|
|
SetRectsDirty();
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2013-03-30 17:39:58 +01:00
|
|
|
for (std::vector< SdrCustomShapeInteraction >::const_iterator aIter( aInteractionHandles.begin() ), aEnd( aInteractionHandles.end() ) ;
|
|
|
|
aIter != aEnd ; ++aIter)
|
2005-09-28 11:40:42 +00:00
|
|
|
{
|
|
|
|
try
|
|
|
|
{
|
2015-04-24 14:53:01 +02:00
|
|
|
if ( aIter->nMode & CustomShapeHandleModes::RESIZE_FIXED )
|
2005-09-28 11:40:42 +00:00
|
|
|
aIter->xInteraction->setControllerPosition( aIter->aPosition );
|
|
|
|
}
|
|
|
|
catch ( const uno::RuntimeException& )
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2005-07-12 12:39:20 +00:00
|
|
|
InvalidateRenderGeometry();
|
|
|
|
SetChanged();
|
|
|
|
BroadcastObjectChange();
|
|
|
|
SendUserCall(SDRUSERCALL_RESIZE,aBoundRect0);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
return bRet;
|
|
|
|
}
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::BegTextEdit( SdrOutliner& rOutl )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
return SdrTextObj::BegTextEdit( rOutl );
|
|
|
|
}
|
|
|
|
void SdrObjCustomShape::TakeTextEditArea(Size* pPaperMin, Size* pPaperMax, Rectangle* pViewInit, Rectangle* pViewMin) const
|
|
|
|
{
|
|
|
|
Size aPaperMin,aPaperMax;
|
|
|
|
Rectangle aViewInit;
|
|
|
|
TakeTextAnchorRect( aViewInit );
|
2014-10-15 07:53:32 +02:00
|
|
|
if ( aGeo.nRotationAngle )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
Point aCenter(aViewInit.Center());
|
|
|
|
aCenter-=aViewInit.TopLeft();
|
|
|
|
Point aCenter0(aCenter);
|
|
|
|
RotatePoint(aCenter,Point(),aGeo.nSin,aGeo.nCos);
|
|
|
|
aCenter-=aCenter0;
|
|
|
|
aViewInit.Move(aCenter.X(),aCenter.Y());
|
|
|
|
}
|
|
|
|
Size aAnkSiz(aViewInit.GetSize());
|
2011-11-27 23:21:00 +01:00
|
|
|
aAnkSiz.Width()--; aAnkSiz.Height()--; // because GetSize() adds 1
|
2004-04-02 13:13:28 +00:00
|
|
|
Size aMaxSiz(1000000,1000000);
|
|
|
|
if (pModel!=NULL) {
|
|
|
|
Size aTmpSiz(pModel->GetMaxObjSize());
|
|
|
|
if (aTmpSiz.Width()!=0) aMaxSiz.Width()=aTmpSiz.Width();
|
|
|
|
if (aTmpSiz.Height()!=0) aMaxSiz.Height()=aTmpSiz.Height();
|
|
|
|
}
|
|
|
|
SdrTextHorzAdjust eHAdj(GetTextHorizontalAdjust());
|
|
|
|
SdrTextVertAdjust eVAdj(GetTextVerticalAdjust());
|
|
|
|
|
|
|
|
long nMinWdt = GetMinTextFrameWidth();
|
|
|
|
long nMinHgt = GetMinTextFrameHeight();
|
|
|
|
long nMaxWdt = GetMaxTextFrameWidth();
|
|
|
|
long nMaxHgt = GetMaxTextFrameHeight();
|
|
|
|
if (nMinWdt<1) nMinWdt=1;
|
|
|
|
if (nMinHgt<1) nMinHgt=1;
|
|
|
|
if ( nMaxWdt == 0 || nMaxWdt > aMaxSiz.Width() )
|
|
|
|
nMaxWdt = aMaxSiz.Width();
|
|
|
|
if ( nMaxHgt == 0 || nMaxHgt > aMaxSiz.Height() )
|
|
|
|
nMaxHgt=aMaxSiz.Height();
|
|
|
|
|
2014-10-17 10:35:35 +02:00
|
|
|
if (static_cast<const SdrOnOffItem&>(GetMergedItem(SDRATTR_TEXT_WORDWRAP)).GetValue())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
if ( IsVerticalWriting() )
|
|
|
|
{
|
|
|
|
nMaxHgt = aAnkSiz.Height();
|
|
|
|
nMinHgt = nMaxHgt;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
nMaxWdt = aAnkSiz.Width();
|
|
|
|
nMinWdt = nMaxWdt;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
aPaperMax.Width()=nMaxWdt;
|
|
|
|
aPaperMax.Height()=nMaxHgt;
|
|
|
|
|
|
|
|
aPaperMin.Width()=nMinWdt;
|
|
|
|
aPaperMin.Height()=nMinHgt;
|
|
|
|
|
|
|
|
if ( pViewMin )
|
|
|
|
{
|
|
|
|
*pViewMin = aViewInit;
|
|
|
|
|
|
|
|
long nXFree = aAnkSiz.Width() - aPaperMin.Width();
|
|
|
|
if ( eHAdj == SDRTEXTHORZADJUST_LEFT )
|
|
|
|
pViewMin->Right() -= nXFree;
|
|
|
|
else if ( eHAdj == SDRTEXTHORZADJUST_RIGHT )
|
|
|
|
pViewMin->Left() += nXFree;
|
|
|
|
else { pViewMin->Left() += nXFree / 2; pViewMin->Right() = pViewMin->Left() + aPaperMin.Width(); }
|
|
|
|
|
|
|
|
long nYFree = aAnkSiz.Height() - aPaperMin.Height();
|
|
|
|
if ( eVAdj == SDRTEXTVERTADJUST_TOP )
|
|
|
|
pViewMin->Bottom() -= nYFree;
|
|
|
|
else if ( eVAdj == SDRTEXTVERTADJUST_BOTTOM )
|
|
|
|
pViewMin->Top() += nYFree;
|
|
|
|
else { pViewMin->Top() += nYFree / 2; pViewMin->Bottom() = pViewMin->Top() + aPaperMin.Height(); }
|
|
|
|
}
|
|
|
|
|
|
|
|
if( IsVerticalWriting() )
|
|
|
|
aPaperMin.Width() = 0;
|
|
|
|
else
|
2011-05-09 13:28:30 +02:00
|
|
|
aPaperMin.Height() = 0;
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
if( eHAdj != SDRTEXTHORZADJUST_BLOCK )
|
|
|
|
aPaperMin.Width()=0;
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// For complete vertical adjust support, set paper min height to 0, here.
|
2006-06-19 15:40:23 +00:00
|
|
|
if(SDRTEXTVERTADJUST_BLOCK != eVAdj )
|
2004-04-02 13:13:28 +00:00
|
|
|
aPaperMin.Height() = 0;
|
|
|
|
|
|
|
|
if (pPaperMin!=NULL) *pPaperMin=aPaperMin;
|
|
|
|
if (pPaperMax!=NULL) *pPaperMax=aPaperMax;
|
|
|
|
if (pViewInit!=NULL) *pViewInit=aViewInit;
|
|
|
|
}
|
|
|
|
void SdrObjCustomShape::EndTextEdit( SdrOutliner& rOutl )
|
|
|
|
{
|
|
|
|
SdrTextObj::EndTextEdit( rOutl );
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
void SdrObjCustomShape::TakeTextAnchorRect( Rectangle& rAnchorRect ) const
|
|
|
|
{
|
|
|
|
if ( GetTextBounds( rAnchorRect ) )
|
|
|
|
{
|
|
|
|
Point aRotateRef( maSnapRect.Center() );
|
|
|
|
rAnchorRect.Left() += GetTextLeftDistance();
|
|
|
|
rAnchorRect.Top() += GetTextUpperDistance();
|
|
|
|
rAnchorRect.Right() -= GetTextRightDistance();
|
|
|
|
rAnchorRect.Bottom() -= GetTextLowerDistance();
|
|
|
|
ImpJustifyRect( rAnchorRect );
|
|
|
|
|
|
|
|
if ( rAnchorRect.GetWidth() < 2 )
|
|
|
|
rAnchorRect.Right() = rAnchorRect.Left() + 1; // minimal width is 2
|
|
|
|
if ( rAnchorRect.GetHeight() < 2 )
|
|
|
|
rAnchorRect.Bottom() = rAnchorRect.Top() + 1; // minimal height is 2
|
2014-10-15 07:53:32 +02:00
|
|
|
if ( aGeo.nRotationAngle )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
Point aP( rAnchorRect.TopLeft() );
|
|
|
|
RotatePoint( aP, aRotateRef, aGeo.nSin, aGeo. nCos );
|
|
|
|
rAnchorRect.SetPos( aP );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
SdrTextObj::TakeTextAnchorRect( rAnchorRect );
|
|
|
|
}
|
2010-10-05 07:57:54 -05:00
|
|
|
void SdrObjCustomShape::TakeTextRect( SdrOutliner& rOutliner, Rectangle& rTextRect, bool bNoEditText,
|
2011-03-23 18:01:22 +01:00
|
|
|
Rectangle* pAnchorRect, bool /*bLineWidth*/) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2011-11-27 23:21:00 +01:00
|
|
|
Rectangle aAnkRect; // Rect in which we anchor
|
2004-04-02 13:13:28 +00:00
|
|
|
TakeTextAnchorRect(aAnkRect);
|
|
|
|
SdrTextVertAdjust eVAdj=GetTextVerticalAdjust();
|
|
|
|
SdrTextHorzAdjust eHAdj=GetTextHorizontalAdjust();
|
2015-03-24 16:05:55 +02:00
|
|
|
EEControlBits nStat0=rOutliner.GetControlWord();
|
2004-04-02 13:13:28 +00:00
|
|
|
Size aNullSize;
|
|
|
|
|
2015-03-24 16:05:55 +02:00
|
|
|
rOutliner.SetControlWord(nStat0|EEControlBits::AUTOPAGESIZE);
|
2004-04-02 13:13:28 +00:00
|
|
|
rOutliner.SetMinAutoPaperSize(aNullSize);
|
|
|
|
sal_Int32 nMaxAutoPaperWidth = 1000000;
|
|
|
|
sal_Int32 nMaxAutoPaperHeight= 1000000;
|
|
|
|
|
|
|
|
long nAnkWdt=aAnkRect.GetWidth();
|
|
|
|
long nAnkHgt=aAnkRect.GetHeight();
|
|
|
|
|
2014-10-17 10:35:35 +02:00
|
|
|
if (static_cast<const SdrOnOffItem&>(GetMergedItem(SDRATTR_TEXT_WORDWRAP)).GetValue())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
if ( IsVerticalWriting() )
|
|
|
|
nMaxAutoPaperHeight = nAnkHgt;
|
|
|
|
else
|
|
|
|
nMaxAutoPaperWidth = nAnkWdt;
|
|
|
|
}
|
|
|
|
if(SDRTEXTHORZADJUST_BLOCK == eHAdj && !IsVerticalWriting())
|
|
|
|
{
|
|
|
|
rOutliner.SetMinAutoPaperSize(Size(nAnkWdt, 0));
|
|
|
|
}
|
|
|
|
|
|
|
|
if(SDRTEXTVERTADJUST_BLOCK == eVAdj && IsVerticalWriting())
|
|
|
|
{
|
|
|
|
rOutliner.SetMinAutoPaperSize(Size(0, nAnkHgt));
|
|
|
|
}
|
|
|
|
rOutliner.SetMaxAutoPaperSize( Size( nMaxAutoPaperWidth, nMaxAutoPaperHeight ) );
|
|
|
|
rOutliner.SetPaperSize( aNullSize );
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// put text into the Outliner - if necessary the use the text from the EditOutliner
|
2008-03-12 08:54:16 +00:00
|
|
|
OutlinerParaObject* pPara= GetOutlinerParaObject();
|
2004-04-02 13:13:28 +00:00
|
|
|
if (pEdtOutl && !bNoEditText)
|
|
|
|
pPara=pEdtOutl->CreateParaObject();
|
|
|
|
|
|
|
|
if (pPara)
|
|
|
|
{
|
2013-04-07 23:05:56 +09:00
|
|
|
bool bHitTest = false;
|
2004-04-02 13:13:28 +00:00
|
|
|
if( pModel )
|
|
|
|
bHitTest = &pModel->GetHitTestOutliner() == &rOutliner;
|
|
|
|
|
|
|
|
const SdrTextObj* pTestObj = rOutliner.GetTextObj();
|
|
|
|
if( !pTestObj || !bHitTest || pTestObj != this ||
|
2008-03-12 08:54:16 +00:00
|
|
|
pTestObj->GetOutlinerParaObject() != GetOutlinerParaObject() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
if( bHitTest )
|
|
|
|
rOutliner.SetTextObj( this );
|
|
|
|
|
2014-02-25 14:19:24 +02:00
|
|
|
rOutliner.SetUpdateMode(true);
|
2004-04-02 13:13:28 +00:00
|
|
|
rOutliner.SetText(*pPara);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
rOutliner.SetTextObj( NULL );
|
|
|
|
}
|
|
|
|
if (pEdtOutl && !bNoEditText && pPara)
|
|
|
|
delete pPara;
|
|
|
|
|
2014-02-25 14:19:24 +02:00
|
|
|
rOutliner.SetUpdateMode(true);
|
2004-04-02 13:13:28 +00:00
|
|
|
rOutliner.SetControlWord(nStat0);
|
|
|
|
|
2008-03-12 08:54:16 +00:00
|
|
|
SdrText* pText = getActiveText();
|
|
|
|
if( pText )
|
|
|
|
pText->CheckPortionInfo( rOutliner );
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
Point aTextPos(aAnkRect.TopLeft());
|
2011-11-27 23:21:00 +01:00
|
|
|
Size aTextSiz(rOutliner.GetPaperSize()); // GetPaperSize() has a little added tolerance, no?
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// For draw objects containing text correct horizontal/vertical alignment if text is bigger
|
2004-04-02 13:13:28 +00:00
|
|
|
// than the object itself. Without that correction, the text would always be
|
2011-11-27 23:21:00 +01:00
|
|
|
// formatted to the left edge (or top edge when vertical) of the draw object.
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
if( !IsTextFrame() )
|
|
|
|
{
|
|
|
|
if(aAnkRect.GetWidth() < aTextSiz.Width() && !IsVerticalWriting())
|
|
|
|
{
|
|
|
|
// Horizontal case here. Correct only if eHAdj == SDRTEXTHORZADJUST_BLOCK,
|
|
|
|
// else the alignment is wanted.
|
|
|
|
if(SDRTEXTHORZADJUST_BLOCK == eHAdj)
|
|
|
|
{
|
|
|
|
eHAdj = SDRTEXTHORZADJUST_CENTER;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if(aAnkRect.GetHeight() < aTextSiz.Height() && IsVerticalWriting())
|
|
|
|
{
|
|
|
|
// Vertical case here. Correct only if eHAdj == SDRTEXTVERTADJUST_BLOCK,
|
|
|
|
// else the alignment is wanted.
|
|
|
|
if(SDRTEXTVERTADJUST_BLOCK == eVAdj)
|
|
|
|
{
|
|
|
|
eVAdj = SDRTEXTVERTADJUST_CENTER;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if (eHAdj==SDRTEXTHORZADJUST_CENTER || eHAdj==SDRTEXTHORZADJUST_RIGHT)
|
|
|
|
{
|
|
|
|
long nFreeWdt=aAnkRect.GetWidth()-aTextSiz.Width();
|
|
|
|
if (eHAdj==SDRTEXTHORZADJUST_CENTER)
|
|
|
|
aTextPos.X()+=nFreeWdt/2;
|
|
|
|
if (eHAdj==SDRTEXTHORZADJUST_RIGHT)
|
|
|
|
aTextPos.X()+=nFreeWdt;
|
|
|
|
}
|
|
|
|
if (eVAdj==SDRTEXTVERTADJUST_CENTER || eVAdj==SDRTEXTVERTADJUST_BOTTOM)
|
|
|
|
{
|
|
|
|
long nFreeHgt=aAnkRect.GetHeight()-aTextSiz.Height();
|
|
|
|
if (eVAdj==SDRTEXTVERTADJUST_CENTER)
|
|
|
|
aTextPos.Y()+=nFreeHgt/2;
|
|
|
|
if (eVAdj==SDRTEXTVERTADJUST_BOTTOM)
|
|
|
|
aTextPos.Y()+=nFreeHgt;
|
|
|
|
}
|
2014-10-15 07:53:32 +02:00
|
|
|
if (aGeo.nRotationAngle!=0)
|
2004-04-02 13:13:28 +00:00
|
|
|
RotatePoint(aTextPos,aAnkRect.TopLeft(),aGeo.nSin,aGeo.nCos);
|
|
|
|
|
|
|
|
if (pAnchorRect)
|
|
|
|
*pAnchorRect=aAnkRect;
|
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// using rTextRect together with ContourFrame doesn't always work correctly
|
2004-04-02 13:13:28 +00:00
|
|
|
rTextRect=Rectangle(aTextPos,aTextSiz);
|
|
|
|
}
|
|
|
|
|
|
|
|
void SdrObjCustomShape::NbcSetOutlinerParaObject(OutlinerParaObject* pTextObject)
|
|
|
|
{
|
|
|
|
SdrTextObj::NbcSetOutlinerParaObject( pTextObject );
|
2008-08-19 22:22:03 +00:00
|
|
|
SetBoundRectDirty();
|
2014-03-10 11:09:59 +02:00
|
|
|
SetRectsDirty(true);
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2011-03-25 17:33:24 +01:00
|
|
|
SdrObjCustomShape* SdrObjCustomShape::Clone() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2011-03-25 17:33:24 +01:00
|
|
|
return CloneHelper< SdrObjCustomShape >();
|
|
|
|
}
|
|
|
|
|
|
|
|
SdrObjCustomShape& SdrObjCustomShape::operator=(const SdrObjCustomShape& rObj)
|
|
|
|
{
|
|
|
|
if( this == &rObj )
|
|
|
|
return *this;
|
2004-04-02 13:13:28 +00:00
|
|
|
SdrTextObj::operator=( rObj );
|
2011-03-25 17:33:24 +01:00
|
|
|
aName = rObj.aName;
|
|
|
|
fObjectRotation = rObj.fObjectRotation;
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2011-03-25 17:33:24 +01:00
|
|
|
return *this;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
2013-07-25 09:27:58 +01:00
|
|
|
OUString SdrObjCustomShape::TakeObjNameSingul() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2013-07-25 09:27:58 +01:00
|
|
|
OUStringBuffer sName(ImpGetResStr(STR_ObjNameSingulCUSTOMSHAPE));
|
|
|
|
OUString aNm(GetName());
|
|
|
|
if (!aNm.isEmpty())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2013-07-25 09:27:58 +01:00
|
|
|
sName.append(' ');
|
|
|
|
sName.append('\'');
|
|
|
|
sName.append(aNm);
|
|
|
|
sName.append('\'');
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
2013-07-25 09:27:58 +01:00
|
|
|
return sName.makeStringAndClear();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2013-07-25 20:35:59 +01:00
|
|
|
OUString SdrObjCustomShape::TakeObjNamePlural() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2013-07-25 20:35:59 +01:00
|
|
|
return ImpGetResStr(STR_ObjNamePluralCUSTOMSHAPE);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2008-10-17 08:40:10 +00:00
|
|
|
basegfx::B2DPolyPolygon SdrObjCustomShape::TakeXorPoly() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2014-07-11 09:19:59 +02:00
|
|
|
return GetLineGeometry( false );
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2006-11-14 12:44:11 +00:00
|
|
|
basegfx::B2DPolyPolygon SdrObjCustomShape::TakeContour() const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
const SdrObject* pSdrObject = GetSdrObjectFromCustomShape();
|
|
|
|
if ( pSdrObject )
|
2006-11-14 12:44:11 +00:00
|
|
|
return pSdrObject->TakeContour();
|
|
|
|
return basegfx::B2DPolyPolygon();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
SdrObject* SdrObjCustomShape::DoConvertToPolyObj(bool bBezier, bool bAddText) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2004-11-18 10:07:11 +00:00
|
|
|
// #i37011#
|
|
|
|
SdrObject* pRetval = 0L;
|
|
|
|
SdrObject* pRenderedCustomShape = 0L;
|
|
|
|
|
|
|
|
if ( !mXRenderedCustomShape.is() )
|
|
|
|
{
|
|
|
|
// force CustomShape
|
2014-07-11 09:19:59 +02:00
|
|
|
GetSdrObjectFromCustomShape();
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
if ( mXRenderedCustomShape.is() )
|
|
|
|
{
|
|
|
|
pRenderedCustomShape = GetSdrObjectFromXShape( mXRenderedCustomShape );
|
|
|
|
}
|
|
|
|
|
|
|
|
if ( pRenderedCustomShape )
|
|
|
|
{
|
|
|
|
SdrObject* pCandidate = pRenderedCustomShape->Clone();
|
|
|
|
DBG_ASSERT(pCandidate, "SdrObjCustomShape::DoConvertToPolyObj: Could not clone SdrObject (!)");
|
|
|
|
pCandidate->SetModel(GetModel());
|
2012-11-21 22:06:52 +00:00
|
|
|
pRetval = pCandidate->DoConvertToPolyObj(bBezier, bAddText);
|
2007-07-06 06:40:55 +00:00
|
|
|
SdrObject::Free( pCandidate );
|
2004-11-18 10:07:11 +00:00
|
|
|
|
|
|
|
if(pRetval)
|
|
|
|
{
|
2014-10-17 10:35:35 +02:00
|
|
|
const bool bShadow(static_cast<const SdrOnOffItem&>(GetMergedItem(SDRATTR_SHADOW)).GetValue());
|
2004-11-18 10:07:11 +00:00
|
|
|
if(bShadow)
|
|
|
|
{
|
2014-08-05 08:59:37 +02:00
|
|
|
pRetval->SetMergedItem(makeSdrShadowItem(true));
|
2004-11-18 10:07:11 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2012-11-21 22:06:52 +00:00
|
|
|
if(bAddText && HasText() && !IsTextPath())
|
2004-11-18 10:07:11 +00:00
|
|
|
{
|
|
|
|
pRetval = ImpConvertAddText(pRetval, bBezier);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
return pRetval;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
void SdrObjCustomShape::NbcSetStyleSheet( SfxStyleSheet* pNewStyleSheet, bool bDontRemoveHardAttr )
|
2004-10-12 13:17:22 +00:00
|
|
|
{
|
2005-01-28 16:09:06 +00:00
|
|
|
// #i40944#
|
|
|
|
InvalidateRenderGeometry();
|
2004-10-12 13:17:22 +00:00
|
|
|
SdrObject::NbcSetStyleSheet( pNewStyleSheet, bDontRemoveHardAttr );
|
|
|
|
}
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
void SdrObjCustomShape::SetPage( SdrPage* pNewPage )
|
|
|
|
{
|
|
|
|
SdrTextObj::SetPage( pNewPage );
|
|
|
|
|
2006-12-12 15:01:14 +00:00
|
|
|
if( pNewPage )
|
|
|
|
{
|
|
|
|
// invalidating rectangles by SetRectsDirty is not sufficient,
|
|
|
|
// AdjustTextFrameWidthAndHeight() also has to be made, both
|
|
|
|
// actions are done by NbcSetSnapRect
|
2014-10-29 15:01:37 -04:00
|
|
|
Rectangle aTmp( maRect ); //creating temporary rectangle #i61108#
|
2006-12-12 15:01:14 +00:00
|
|
|
NbcSetSnapRect( aTmp );
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
SdrObjGeoData* SdrObjCustomShape::NewGeoData() const
|
|
|
|
{
|
|
|
|
return new SdrAShapeObjGeoData;
|
|
|
|
}
|
|
|
|
|
|
|
|
void SdrObjCustomShape::SaveGeoData(SdrObjGeoData& rGeo) const
|
|
|
|
{
|
|
|
|
SdrTextObj::SaveGeoData( rGeo );
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrAShapeObjGeoData& rAGeo=static_cast<SdrAShapeObjGeoData&>(rGeo);
|
2004-04-02 13:13:28 +00:00
|
|
|
rAGeo.fObjectRotation = fObjectRotation;
|
|
|
|
rAGeo.bMirroredX = IsMirroredX();
|
|
|
|
rAGeo.bMirroredY = IsMirroredY();
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sAdjustmentValues( "AdjustmentValues" );
|
2014-10-17 10:35:35 +02:00
|
|
|
const Any* pAny = static_cast<const SdrCustomShapeGeometryItem&>( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ).GetPropertyValueByName( sAdjustmentValues );
|
2005-09-28 11:40:42 +00:00
|
|
|
if ( pAny )
|
|
|
|
*pAny >>= rAGeo.aAdjustmentSeq;
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void SdrObjCustomShape::RestGeoData(const SdrObjGeoData& rGeo)
|
|
|
|
{
|
|
|
|
SdrTextObj::RestGeoData( rGeo );
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrAShapeObjGeoData& rAGeo=static_cast<const SdrAShapeObjGeoData&>(rGeo);
|
2004-04-02 13:13:28 +00:00
|
|
|
fObjectRotation = rAGeo.fObjectRotation;
|
|
|
|
SetMirroredX( rAGeo.bMirroredX );
|
|
|
|
SetMirroredY( rAGeo.bMirroredY );
|
2005-09-28 11:40:42 +00:00
|
|
|
|
2014-10-17 10:35:35 +02:00
|
|
|
SdrCustomShapeGeometryItem rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
|
2013-04-07 12:06:47 +02:00
|
|
|
const OUString sAdjustmentValues( "AdjustmentValues" );
|
2005-09-28 11:40:42 +00:00
|
|
|
PropertyValue aPropVal;
|
|
|
|
aPropVal.Name = sAdjustmentValues;
|
|
|
|
aPropVal.Value <<= rAGeo.aAdjustmentSeq;
|
|
|
|
rGeometryItem.SetPropertyValue( aPropVal );
|
|
|
|
SetMergedItem( rGeometryItem );
|
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
InvalidateRenderGeometry();
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
2006-11-14 12:44:11 +00:00
|
|
|
void SdrObjCustomShape::TRSetBaseGeometry(const basegfx::B2DHomMatrix& rMatrix, const basegfx::B2DPolyPolygon& /*rPolyPolygon*/)
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
// break up matrix
|
2006-11-14 12:44:11 +00:00
|
|
|
basegfx::B2DTuple aScale;
|
|
|
|
basegfx::B2DTuple aTranslate;
|
|
|
|
double fRotate, fShearX;
|
|
|
|
rMatrix.decompose(aScale, aTranslate, fRotate, fShearX);
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2007-03-06 13:40:22 +00:00
|
|
|
// #i75086# Old DrawingLayer (GeoStat and geometry) does not support holding negative scalings
|
|
|
|
// in X and Y which equal a 180 degree rotation. Recognize it and react accordingly
|
|
|
|
if(basegfx::fTools::less(aScale.getX(), 0.0) && basegfx::fTools::less(aScale.getY(), 0.0))
|
|
|
|
{
|
|
|
|
aScale.setX(fabs(aScale.getX()));
|
|
|
|
aScale.setY(fabs(aScale.getY()));
|
|
|
|
fRotate = fmod(fRotate + F_PI, F_2PI);
|
|
|
|
}
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
// reset object shear and rotations
|
2015-04-24 16:55:01 -04:00
|
|
|
fObjectRotation = 0.0;
|
2014-10-15 07:53:32 +02:00
|
|
|
aGeo.nRotationAngle = 0;
|
2004-04-02 13:13:28 +00:00
|
|
|
aGeo.RecalcSinCos();
|
2014-10-21 08:56:06 +02:00
|
|
|
aGeo.nShearAngle = 0;
|
2004-04-02 13:13:28 +00:00
|
|
|
aGeo.RecalcTan();
|
|
|
|
|
|
|
|
// force metric to pool metric
|
2013-04-10 08:20:16 +00:00
|
|
|
const SfxMapUnit eMapUnit(GetObjectMapUnit());
|
2004-04-02 13:13:28 +00:00
|
|
|
if(eMapUnit != SFX_MAPUNIT_100TH_MM)
|
|
|
|
{
|
|
|
|
switch(eMapUnit)
|
|
|
|
{
|
|
|
|
case SFX_MAPUNIT_TWIP :
|
|
|
|
{
|
|
|
|
// position
|
2006-11-14 12:44:11 +00:00
|
|
|
aTranslate.setX(ImplMMToTwips(aTranslate.getX()));
|
|
|
|
aTranslate.setY(ImplMMToTwips(aTranslate.getY()));
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
// size
|
2006-11-14 12:44:11 +00:00
|
|
|
aScale.setX(ImplMMToTwips(aScale.getX()));
|
|
|
|
aScale.setY(ImplMMToTwips(aScale.getY()));
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
default:
|
|
|
|
{
|
2011-03-01 19:07:44 +01:00
|
|
|
OSL_FAIL("TRSetBaseGeometry: Missing unit translation to PoolMetric!");
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// if anchor is used, make position relative to it
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
if( pModel && pModel->IsWriter() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2006-11-14 12:44:11 +00:00
|
|
|
if(GetAnchorPos().X() || GetAnchorPos().Y())
|
|
|
|
{
|
|
|
|
aTranslate += basegfx::B2DTuple(GetAnchorPos().X(), GetAnchorPos().Y());
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// build and set BaseRect (use scale)
|
|
|
|
Point aPoint = Point();
|
2006-11-14 12:44:11 +00:00
|
|
|
Size aSize(FRound(aScale.getX()), FRound(aScale.getY()));
|
2012-08-14 16:12:53 +05:30
|
|
|
// fdo#47434 We need a valid rectangle here
|
|
|
|
if( !aSize.Height() ) aSize.setHeight( 1 );
|
|
|
|
if( !aSize.Width() ) aSize.setWidth( 1 );
|
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
Rectangle aBaseRect(aPoint, aSize);
|
|
|
|
SetSnapRect(aBaseRect);
|
|
|
|
|
|
|
|
// shear?
|
2009-06-17 10:58:14 +00:00
|
|
|
if(!basegfx::fTools::equalZero(fShearX))
|
|
|
|
{
|
|
|
|
GeoStat aGeoStat;
|
2013-09-04 15:58:19 +00:00
|
|
|
// #i123181# The fix for #121932# here was wrong, the trunk version does not correct the
|
|
|
|
// mirrored shear values, neither at the object level, nor on the API or XML level. Taking
|
|
|
|
// back the mirroring of the shear angle
|
2014-10-21 08:56:06 +02:00
|
|
|
aGeoStat.nShearAngle = FRound((atan(fShearX) / F_PI180) * 100.0);
|
2009-06-17 10:58:14 +00:00
|
|
|
aGeoStat.RecalcTan();
|
2014-10-21 08:56:06 +02:00
|
|
|
Shear(Point(), aGeoStat.nShearAngle, aGeoStat.nTan, false);
|
2009-06-17 10:58:14 +00:00
|
|
|
}
|
2006-11-14 12:44:11 +00:00
|
|
|
|
2004-04-02 13:13:28 +00:00
|
|
|
// rotation?
|
2007-08-02 16:29:13 +00:00
|
|
|
if(!basegfx::fTools::equalZero(fRotate))
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
GeoStat aGeoStat;
|
2007-08-02 16:29:13 +00:00
|
|
|
|
|
|
|
// #i78696#
|
2014-10-15 07:53:32 +02:00
|
|
|
// fRotate is mathematically correct, but aGeoStat.nRotationAngle is
|
2007-08-02 16:29:13 +00:00
|
|
|
// mirrored -> mirror value here
|
2014-10-15 07:53:32 +02:00
|
|
|
aGeoStat.nRotationAngle = NormAngle360(FRound(-fRotate / F_PI18000));
|
2004-04-02 13:13:28 +00:00
|
|
|
aGeoStat.RecalcSinCos();
|
2014-10-15 07:53:32 +02:00
|
|
|
Rotate(Point(), aGeoStat.nRotationAngle, aGeoStat.nSin, aGeoStat.nCos);
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// translate?
|
2007-08-02 16:29:13 +00:00
|
|
|
if(!aTranslate.equalZero())
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2006-11-14 12:44:11 +00:00
|
|
|
Move(Size(FRound(aTranslate.getX()), FRound(aTranslate.getY())));
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2014-11-04 14:45:00 +02:00
|
|
|
// taking fObjectRotation instead of aGeo.nAngle
|
2014-03-10 11:09:59 +02:00
|
|
|
bool SdrObjCustomShape::TRGetBaseGeometry(basegfx::B2DHomMatrix& rMatrix, basegfx::B2DPolyPolygon& /*rPolyPolygon*/) const
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
// get turn and shear
|
|
|
|
double fRotate = fObjectRotation * F_PI180;
|
2014-10-21 08:56:06 +02:00
|
|
|
double fShearX = (aGeo.nShearAngle / 100.0) * F_PI180;
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
// get aRect, this is the unrotated snaprect
|
2014-10-29 15:01:37 -04:00
|
|
|
Rectangle aRectangle(maRect);
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
bool bMirroredX = IsMirroredX();
|
|
|
|
bool bMirroredY = IsMirroredY();
|
2004-04-02 13:13:28 +00:00
|
|
|
if ( bMirroredX || bMirroredY )
|
|
|
|
{ // we have to retrieve the unmirrored rect
|
|
|
|
|
|
|
|
GeoStat aNewGeo( aGeo );
|
|
|
|
|
|
|
|
if ( bMirroredX )
|
|
|
|
{
|
2014-10-29 15:01:37 -04:00
|
|
|
Polygon aPol = Rect2Poly(maRect, aNewGeo);
|
2004-04-02 13:13:28 +00:00
|
|
|
Rectangle aBoundRect( aPol.GetBoundRect() );
|
|
|
|
|
|
|
|
Point aRef1( ( aBoundRect.Left() + aBoundRect.Right() ) >> 1, aBoundRect.Top() );
|
|
|
|
Point aRef2( aRef1.X(), aRef1.Y() + 1000 );
|
2011-01-10 16:11:35 +01:00
|
|
|
sal_uInt16 i;
|
2015-04-17 09:13:11 +02:00
|
|
|
sal_uInt16 nPointCount=aPol.GetSize();
|
|
|
|
for (i=0; i<nPointCount; i++)
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
MirrorPoint(aPol[i],aRef1,aRef2);
|
|
|
|
}
|
2011-11-27 23:21:00 +01:00
|
|
|
// mirror polygon and move it a bit
|
2004-04-02 13:13:28 +00:00
|
|
|
Polygon aPol0(aPol);
|
|
|
|
aPol[0]=aPol0[1];
|
|
|
|
aPol[1]=aPol0[0];
|
|
|
|
aPol[2]=aPol0[3];
|
|
|
|
aPol[3]=aPol0[2];
|
|
|
|
aPol[4]=aPol0[1];
|
|
|
|
Poly2Rect(aPol,aRectangle,aNewGeo);
|
|
|
|
}
|
|
|
|
if ( bMirroredY )
|
|
|
|
{
|
|
|
|
Polygon aPol( Rect2Poly( aRectangle, aNewGeo ) );
|
|
|
|
Rectangle aBoundRect( aPol.GetBoundRect() );
|
|
|
|
|
|
|
|
Point aRef1( aBoundRect.Left(), ( aBoundRect.Top() + aBoundRect.Bottom() ) >> 1 );
|
|
|
|
Point aRef2( aRef1.X() + 1000, aRef1.Y() );
|
2011-01-10 16:11:35 +01:00
|
|
|
sal_uInt16 i;
|
2015-04-17 09:13:11 +02:00
|
|
|
sal_uInt16 nPointCount=aPol.GetSize();
|
|
|
|
for (i=0; i<nPointCount; i++)
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
|
|
|
MirrorPoint(aPol[i],aRef1,aRef2);
|
|
|
|
}
|
2011-11-27 23:21:00 +01:00
|
|
|
// mirror polygon and move it a bit
|
2004-04-02 13:13:28 +00:00
|
|
|
Polygon aPol0(aPol);
|
2013-04-08 17:04:41 +00:00
|
|
|
aPol[0]=aPol0[1]; // This was WRONG for vertical (!)
|
2015-03-22 09:48:01 +01:00
|
|
|
aPol[1]=aPol0[0]; // #i121932# Despite my own comment above
|
2013-04-08 17:04:41 +00:00
|
|
|
aPol[2]=aPol0[3]; // it was *not* wrong even when the reordering
|
|
|
|
aPol[3]=aPol0[2]; // *seems* to be specific for X-Mirrorings. Oh
|
|
|
|
aPol[4]=aPol0[1]; // will I be happy when this old stuff is |gone| with aw080 (!)
|
2004-04-02 13:13:28 +00:00
|
|
|
Poly2Rect(aPol,aRectangle,aNewGeo);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// fill other values
|
2006-11-14 12:44:11 +00:00
|
|
|
basegfx::B2DTuple aScale(aRectangle.GetWidth(), aRectangle.GetHeight());
|
|
|
|
basegfx::B2DTuple aTranslate(aRectangle.Left(), aRectangle.Top());
|
2004-04-02 13:13:28 +00:00
|
|
|
|
2011-11-27 23:21:00 +01:00
|
|
|
// position may be relative to anchorpos, convert
|
CWS-TOOLING: integrate CWS aw059
2008-12-16 16:15:40 +0100 aw r265557 : #i95645# avoid expensive tries to stream in graphic data when stream is at end anyways
2008-12-15 16:49:58 +0100 wg r265512 : i97278
2008-12-12 16:02:15 +0100 aw r265427 : #i95645# new formulation was wrong in two places; thanks go to THB. Thanks!
2008-12-12 15:49:06 +0100 aw r265425 : #i95645# refined formulation of AA on/off constraints for VCLCanvas
2008-12-12 14:51:26 +0100 aw r265420 : #i95645# workaround for DrawTransparent of button hilighting when remote displayed; somehow GDI+ does bad dithering in that case
2008-12-12 13:23:00 +0100 aw r265414 : removed temporary build hack; it made it's way in using the rebase; with SVN the rebase is not based on pure checkouts, but uses local changes.
2008-12-11 19:35:59 +0100 aw r265352 : #i95645# need to switch off AA for WNT and UNX, the VCLCanvas is currently not able to handle AA correctly
2008-12-11 16:05:17 +0100 thb r265327 : #i95645# Changed defaults to on; as for the while svx dialog is not changed
2008-12-10 13:40:38 +0100 aw r265180 : #i95645# changed pixel snap to basegfx::fround
2008-12-10 13:25:45 +0100 aw r265177 : corrected linux warning
2008-12-10 12:28:02 +0100 aw r265167 : #i95645# added support for pixel snap/linux resp. no AA for mac (also pixel snap) when AA is switched off to the basegfx::B2DPolyPolygon painting VCL methods; needed for e.g. selection in SC and SW
2008-12-09 18:44:39 +0100 aw r265136 : #i95645# corrected filled path construction
2008-12-09 18:12:40 +0100 aw r265133 : #i95645# added support for non-AAd transparent paints
2008-12-09 18:11:58 +0100 aw r265132 : #i95645# forced selection without AA
2008-12-09 18:11:29 +0100 aw r265131 : #i88893# smoothed/corrected SW selection rects for transparent selection, forced selection without AA
2008-12-09 15:21:39 +0100 aw r265094 : #i95645# corrected FormControl full drag
2008-12-09 15:11:26 +0100 aw r265093 : #i95645# make gdiplus usages more safe when no line or fill color is selected
2008-12-09 14:30:09 +0100 aw r265085 : #i95645# added GDIPlus support
2008-12-09 13:41:06 +0100 aw r265081 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:46 +0100 aw r265080 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:40:29 +0100 aw r265079 : #i95645# added simple AA using GDIPlis to VCL
2008-12-09 13:33:16 +0100 aw r265078 : #i95645# changes to requirements, discussed with FPE
2008-12-08 14:11:39 +0100 aw r264995 : #i95646# added missing extra-wireframe for SdrDragObjOwn implementations when object has no border
2008-12-08 14:11:00 +0100 aw r264994 : #i95646# corrected RenderMarkerArrayPrimitive2D OutDev usage in VclProcessor2D
2008-12-08 12:15:10 +0100 ufi r264987 : aw059
2008-12-08 12:14:40 +0100 ufi r264986 : aw059
2008-12-05 13:16:18 +0100 aw r264905 : CWS-TOOLING: rebase CWS aw059 to trunk@264807 (milestone: DEV300:m37)
2008-12-04 11:29:48 +0100 aw r264827 : #i95645# corrected warning
2008-12-03 14:43:39 +0100 aw r264783 : #i95645# simplified overlay manager and objects to stl vector; added stuff to render some more overlay to primitive renderer to get AA support for WIN32
2008-12-03 14:42:43 +0100 aw r264782 : #i95645# added test for WIN32 for AA if cairo canvas is available
2008-12-03 14:42:13 +0100 aw r264781 : #i95645# removed unused options for writer selection overlay
2008-12-03 14:41:51 +0100 aw r264780 : #i95645# removed unused options for calc overlay
2008-12-03 14:41:21 +0100 aw r264779 : #i95645# small corrections in canvas renderer
2008-12-02 18:32:31 +0100 aw r264730 : #i95646# merged cairo version from THB's CWS cairosource01
2008-12-02 15:25:45 +0100 aw r264705 : #i95645# added helpers for the MarkerArrayPrimitive2D change which support buffered creation of the most used markers
2008-12-02 12:50:01 +0100 aw r264690 : #i95645# added a non-saved method IsAAPossibleOnThisSystem to SvtOptionsDrawinglayer to quickly test if AA can be offered on the system, added buffering of that check.
2008-12-02 12:48:51 +0100 aw r264689 : #i95645# unified MarkerArrayPrimitive2D to work bitmap-orientated, adapted usages. Added buffered preparation for needed markers. Minor adaptions for AA
2008-12-02 12:47:53 +0100 aw r264688 : #i95645# unified MarkerArrayPrimitive2D to no longer work on a enum and types of markers, but to use a BitmapEx (or any other Bitmap object) which will be displayed centerd and in discrete coordinates at positions. Adapted decomposition and all usages. Corrected minor stuff with grid primitive
2008-11-28 17:11:12 +0100 thb r264565 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:03:27 +0100 thb r264563 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 17:00:07 +0100 thb r264562 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-28 16:59:51 +0100 thb r264561 : #i95645# Added two more lists to config; to be able to differentiate canvas capabilities
2008-11-27 19:13:42 +0100 aw r264519 : #i95646# optimized getLength() a little bit
2008-11-27 19:12:50 +0100 aw r264518 : #i95646# corrected AA expansion of invalidate frame; buffered discrete distance at OM
2008-11-27 18:50:05 +0100 aw r264516 : #i95646# corrected fit to frame texts for WIN32
2008-11-27 15:32:15 +0100 aw r264496 : #i95646# helplines corrected
2008-11-27 15:32:05 +0100 aw r264495 : #i95646# helplines corrected
2008-11-27 15:01:30 +0100 aw r264492 : #i95646# enable AA support for old polygons, especially to get support for MetaFile output
2008-11-27 14:33:28 +0100 aw r264489 : #i95646# AA support for wireframe overlays
2008-11-27 13:40:54 +0100 aw r264485 : #i95646# added full repaint when AA option changes
2008-11-27 13:29:19 +0100 aw r264482 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 13:29:08 +0100 aw r264481 : #i95646# corrected handling of bSolidDragging config entries
2008-11-27 11:30:12 +0100 aw r264469 : #i95646# corrected IsAAPossibleOnThisSystem implementation
2008-11-26 16:33:04 +0100 aw r264420 : #i95646# adapted OfaViewTabPage to use disable mechanism for AA and HWAccel
2008-11-26 15:49:19 +0100 aw r264406 : #i95646# added DlgEdObj::getFullDragClone() to create specialized simple SdrUnoObj clones for solid dragging
2008-11-26 15:48:11 +0100 aw r264405 : #i95646# changed derivation of ViewObjectContactOfUnoControl to get a valid isPrimitiveVisible() implementation
2008-11-26 14:11:37 +0100 aw r264385 : #i88893# added new look for selection in sw
2008-11-26 11:32:33 +0100 aw r264360 : corrected compiler warning
2008-11-25 18:46:29 +0100 aw r264328 : #i95646# snapshot with FullDrag clones
2008-11-25 18:46:07 +0100 aw r264327 : #i95646# snapshot with FullDrag clones
2008-11-25 18:45:43 +0100 aw r264326 : #i95646# snapshot with FullDrag clones
2008-11-25 18:19:04 +0100 thb r264324 : #i96585# Added missing inline specifier
2008-11-25 13:16:25 +0100 aw r264285 : #i95646# next snapshot
2008-11-25 13:15:33 +0100 aw r264284 : #i95646# next snapshot
2008-11-25 13:15:12 +0100 aw r264283 : #i95646# next snapshot
2008-11-25 13:14:51 +0100 aw r264282 : #i95646# next snapshot
2008-11-20 13:40:49 +0100 aw r264045 : #i95646# stable snapshot
2008-11-20 13:40:29 +0100 aw r264044 : #i95646# stable snapshot
2008-11-20 13:40:06 +0100 aw r264043 : #i95646# stable snapshot
2008-11-20 13:39:45 +0100 aw r264042 : #i95646# stable snapshot
2008-11-18 11:53:39 +0100 aw r263758 : #i95646# snapshot for linux test build
2008-11-18 11:52:54 +0100 aw r263757 : #i95646# snapshot for linux test build
2008-11-18 11:52:02 +0100 aw r263756 : #i95646# snapshot for linux test build
2008-11-14 18:17:49 +0100 aw r263692 : #i95646# snapshot with most stuff working
2008-11-14 18:14:26 +0100 aw r263691 : #i95646# snapshot with most stuff working
2008-11-14 18:12:50 +0100 aw r263690 : #i95646# snapshot with most stuff working
2008-11-14 18:12:16 +0100 aw r263689 : #i95646# snapshot with most stuff working
2008-11-14 18:11:41 +0100 aw r263688 : #i95646# snapshot with most stuff working
2008-11-07 18:44:22 +0100 aw r263479 : #i95968# better support PrefMapMode; special for MAP_PIXEL was missing
2008-11-05 17:39:15 +0100 aw r263356 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 17:39:02 +0100 aw r263355 : #i95644# #i95645# #i95646# bigger change done, saving for another experiment
2008-11-05 12:28:32 +0100 aw r263350 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:27:51 +0100 aw r263349 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:58 +0100 aw r263348 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:26:17 +0100 aw r263347 : #i95644# #i95645# #i95646# in-between state before bigger change
2008-11-05 12:25:55 +0100 aw r263346 : #i95644# #i95645# #i95646# in-between state before bigger change
2009-01-05 13:44:12 +00:00
|
|
|
if( pModel && pModel->IsWriter() )
|
2004-04-02 13:13:28 +00:00
|
|
|
{
|
2006-11-14 12:44:11 +00:00
|
|
|
if(GetAnchorPos().X() || GetAnchorPos().Y())
|
|
|
|
{
|
|
|
|
aTranslate -= basegfx::B2DTuple(GetAnchorPos().X(), GetAnchorPos().Y());
|
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// force MapUnit to 100th mm
|
2013-04-10 08:20:16 +00:00
|
|
|
const SfxMapUnit eMapUnit(GetObjectMapUnit());
|
2004-04-02 13:13:28 +00:00
|
|
|
if(eMapUnit != SFX_MAPUNIT_100TH_MM)
|
|
|
|
{
|
|
|
|
switch(eMapUnit)
|
|
|
|
{
|
|
|
|
case SFX_MAPUNIT_TWIP :
|
|
|
|
{
|
2011-11-27 23:21:00 +01:00
|
|
|
// position
|
2006-11-14 12:44:11 +00:00
|
|
|
aTranslate.setX(ImplTwipsToMM(aTranslate.getX()));
|
|
|
|
aTranslate.setY(ImplTwipsToMM(aTranslate.getY()));
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
// size
|
2006-11-14 12:44:11 +00:00
|
|
|
aScale.setX(ImplTwipsToMM(aScale.getX()));
|
|
|
|
aScale.setY(ImplTwipsToMM(aScale.getY()));
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
default:
|
|
|
|
{
|
2011-03-01 19:07:44 +01:00
|
|
|
OSL_FAIL("TRGetBaseGeometry: Missing unit translation to 100th mm!");
|
2004-04-02 13:13:28 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// build matrix
|
2009-09-22 18:14:05 +02:00
|
|
|
rMatrix = basegfx::tools::createScaleShearXRotateTranslateB2DHomMatrix(
|
|
|
|
aScale,
|
|
|
|
basegfx::fTools::equalZero(fShearX) ? 0.0 : tan(fShearX),
|
|
|
|
basegfx::fTools::equalZero(fRotate) ? 0.0 : -fRotate,
|
|
|
|
aTranslate);
|
2006-11-14 12:44:11 +00:00
|
|
|
|
2014-03-10 11:09:59 +02:00
|
|
|
return false;
|
2006-11-14 12:44:11 +00:00
|
|
|
}
|
2004-04-02 13:13:28 +00:00
|
|
|
|
|
|
|
sdr::contact::ViewContact* SdrObjCustomShape::CreateObjectSpecificViewContact()
|
|
|
|
{
|
|
|
|
return new sdr::contact::ViewContactOfSdrObjCustomShape(*this);
|
|
|
|
}
|
|
|
|
|
2004-11-17 08:49:06 +00:00
|
|
|
// #i33136#
|
2013-04-07 12:06:47 +02:00
|
|
|
bool SdrObjCustomShape::doConstructOrthogonal(const OUString& rName)
|
2004-11-17 08:49:06 +00:00
|
|
|
{
|
|
|
|
bool bRetval(false);
|
2014-11-03 14:03:54 +02:00
|
|
|
static const char Imps_sNameASOrtho_quadrat[] = "quadrat";
|
|
|
|
static const char Imps_sNameASOrtho_round_quadrat[] = "round-quadrat";
|
|
|
|
static const char Imps_sNameASOrtho_circle[] = "circle";
|
|
|
|
static const char Imps_sNameASOrtho_circle_pie[] = "circle-pie";
|
|
|
|
static const char Imps_sNameASOrtho_ring[] = "ring";
|
2004-11-17 08:49:06 +00:00
|
|
|
|
2014-11-03 14:03:54 +02:00
|
|
|
if(rName.equalsIgnoreAsciiCase(Imps_sNameASOrtho_quadrat))
|
2004-11-17 08:49:06 +00:00
|
|
|
{
|
|
|
|
bRetval = true;
|
|
|
|
}
|
2014-11-03 14:03:54 +02:00
|
|
|
else if(rName.equalsIgnoreAsciiCase(Imps_sNameASOrtho_round_quadrat))
|
2004-11-17 08:49:06 +00:00
|
|
|
{
|
|
|
|
bRetval = true;
|
|
|
|
}
|
2014-11-03 14:03:54 +02:00
|
|
|
else if(rName.equalsIgnoreAsciiCase(Imps_sNameASOrtho_circle))
|
2004-11-17 08:49:06 +00:00
|
|
|
{
|
|
|
|
bRetval = true;
|
|
|
|
}
|
2014-11-03 14:03:54 +02:00
|
|
|
else if(rName.equalsIgnoreAsciiCase(Imps_sNameASOrtho_circle_pie))
|
2004-11-17 08:49:06 +00:00
|
|
|
{
|
|
|
|
bRetval = true;
|
|
|
|
}
|
2014-11-03 14:03:54 +02:00
|
|
|
else if(rName.equalsIgnoreAsciiCase(Imps_sNameASOrtho_ring))
|
2004-11-17 08:49:06 +00:00
|
|
|
{
|
|
|
|
bRetval = true;
|
|
|
|
}
|
|
|
|
|
|
|
|
return bRetval;
|
|
|
|
}
|
|
|
|
|
2004-11-18 10:07:11 +00:00
|
|
|
// #i37011# centralize throw-away of render geometry
|
|
|
|
void SdrObjCustomShape::InvalidateRenderGeometry()
|
|
|
|
{
|
2005-04-12 15:54:41 +00:00
|
|
|
mXRenderedCustomShape = 0L;
|
2007-07-06 06:40:55 +00:00
|
|
|
SdrObject::Free( mpLastShadowGeometry );
|
2004-11-18 10:07:11 +00:00
|
|
|
mpLastShadowGeometry = 0L;
|
|
|
|
}
|
|
|
|
|
2012-12-18 15:24:28 +01:00
|
|
|
void SdrObjCustomShape::impl_setUnoShape(const uno::Reference<uno::XInterface>& rxUnoShape)
|
|
|
|
{
|
|
|
|
SdrTextObj::impl_setUnoShape(rxUnoShape);
|
|
|
|
|
|
|
|
// The shape engine is created with _current_ shape. This means we
|
|
|
|
// _must_ reset it when the shape changes.
|
|
|
|
mxCustomShapeEngine.set(0);
|
|
|
|
}
|
|
|
|
|
2013-11-27 13:03:45 +00:00
|
|
|
OUString SdrObjCustomShape::GetCustomShapeName()
|
|
|
|
{
|
|
|
|
OUString sShapeName;
|
2015-06-11 14:19:13 +02:00
|
|
|
OUString aEngine( static_cast<const SfxStringItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue() );
|
2014-12-12 17:53:03 +01:00
|
|
|
if ( aEngine.isEmpty()
|
|
|
|
|| aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" )
|
2013-11-27 13:03:45 +00:00
|
|
|
{
|
|
|
|
OUString sShapeType;
|
|
|
|
const OUString sType("Type");
|
2014-10-17 10:35:35 +02:00
|
|
|
const SdrCustomShapeGeometryItem& rGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
|
|
|
|
const Any* pAny = rGeometryItem.GetPropertyValueByName( sType );
|
2013-11-27 13:03:45 +00:00
|
|
|
if ( pAny && ( *pAny >>= sShapeType ) )
|
|
|
|
sShapeName = EnhancedCustomShapeTypeNames::GetAccName( sShapeType );
|
|
|
|
}
|
|
|
|
return sShapeName;
|
|
|
|
}
|
|
|
|
|
2010-10-12 15:53:47 +02:00
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|