Anonymous avatar Anonymous committed 424afee Merge

merged DEV300_m98

Comments (0)

Files changed (205)

 8650e94f45129904b7dcb52e6519d0fb4a3c894d OOO330_m18
 41e86e55f8a9f2179f3d1fc1741116280d7a54e1 DEV300_m96
 19d9ebadebea40835d874a702fd86c8281d4cd52 DEV300_m97
+4b862a2efe512227164230653878e2cd029c0569 DEV300_m98

RepositoryFixes.mk

 
 
 ifeq ($(OS),WNT)
+ifneq ($(USE_MINGW),)
+gb_Library_FILENAMES := $(patsubst comphelper:icomphelper%,comphelper:icomphelp%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst cui:icui%,cui:icuin%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst i18nisolang1:ii18nisolang1%,i18nisolang1:ii18nisolang%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst i18nisolang1:iii18nisolang1%,i18nisolang1:iii18nisolang%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst sb:isb%,sb:basic%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst sfx:isfx%,sfx:sfx%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst svt:isvt%,svt:svtool%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst tl:itl%,tl:itools%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst vbahelper:ivbahelper%,vbahelper:vbahelper%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst vos3:ivos3%,vos3:ivos%,$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst xml2:ixml2%,xml2:libxml2$(gb_Library_IARCEXT),$(gb_Library_FILENAMES))
+gb_Library_FILENAMES := $(patsubst z:iz%,z:zlib%,$(gb_Library_FILENAMES))
+ifeq ($(gb_PRODUCT),$(true))
+gb_Library_FILENAMES := $(patsubst stl:istl%,stl:stlport_vc71%,$(gb_Library_FILENAMES))
+else
+gb_Library_FILENAMES := $(patsubst stl:istl%,stl:stlport_vc71_stldebug%,$(gb_Library_FILENAMES))
+endif
+gb_Library_NOILIBFILENAMES:=\
+	icuuc \
+	sot \
+	uwinapi \
+
+gb_Library_FILENAMES := $(filter-out $(foreach lib,$(gb_Library_NOILIBFILENAMES),$(lib):%),$(gb_Library_FILENAMES))
+gb_Library_FILENAMES += $(foreach lib,$(gb_Library_NOILIBFILENAMES),$(lib):$(lib)$(gb_Library_PLAINEXT))
+
+gb_Library_ILIBFILENAMES:=\
+	unicows \
+	uuid \
+
+gb_Library_DLLFILENAMES := $(filter-out $(foreach lib,$(gb_Library_ILIBFILENAMES),$(lib):%),$(gb_Library_DLLFILENAMES))
+gb_Library_DLLFILENAMES += $(foreach lib,$(gb_Library_ILIBFILENAMES),$(lib):$(PSDK_HOME)/lib/$(lib)$(gb_Library_ILIBEXT))
+
+gb_Library_DLLFILENAMES := $(patsubst comphelper:comphelper%,comphelper:comphelp4%,$(gb_Library_DLLFILENAMES))
+gb_Library_DLLFILENAMES := $(patsubst icuuc:icuuc%,icuuc:icuuc40%,$(gb_Library_DLLFILENAMES))
+gb_Library_DLLFILENAMES := $(patsubst ucbhelper:ucbhelper%,ucbhelper:ucbhelper4%,$(gb_Library_DLLFILENAMES))
+gb_Library_DLLFILENAMES := $(patsubst z:z%,z:zlib%,$(gb_Library_DLLFILENAMES))
+
+ifeq ($(USE_SYSTEM_STL),YES)
+gb_Library_FILENAMES := $(patsubst stl:%,stl:$(gb_Library_IARCSYSPRE)stdc++_s$(gb_Library_IARCSYSPRE),$(gb_Library_FILENAMES))
+gb_Library_TARGETS := $(filter-out stl,$(gb_Library_TARGETS))
+endif
+
+else
 gb_Library_FILENAMES := $(patsubst comphelper:icomphelper%,comphelper:icomphelp%,$(gb_Library_FILENAMES))
 gb_Library_FILENAMES := $(patsubst cui:icui%,cui:icuin%,$(gb_Library_FILENAMES))
 gb_Library_FILENAMES := $(patsubst i18nisolang1:ii18nisolang1%,i18nisolang1:ii18nisolang%,$(gb_Library_FILENAMES))
 
 endif
 
+endif
+
 ifeq ($(OS),SOLARIS)
 gb_Library_FILENAMES := $(patsubst comphelper:libcomphelper%,comphelper:libcomphelp4%,$(gb_Library_FILENAMES))
 gb_Library_FILENAMES := $(patsubst cppuhelper:libcppuhelper%,cppuhelper:libuno_cppuhelper%,$(gb_Library_FILENAMES))
 endif
 
 # vim: set noet sw=4 ts=4:
-

basic/source/basmgr/basicmanagerrepository.cxx

 
         // register as listener for the BasicManager being destroyed
         StartListening( *_out_rpBasicManager );
+
+        // #i104876: Library container must not be modified just after
+        // creation. This happens as side effect when creating default
+        // "Standard" libraries and needs to be corrected here
+        xBasicLibs->setModified( sal_False );
+        xDialogLibs->setModified( sal_False );
+
     }
 
     //--------------------------------------------------------------------

basic/source/classes/sbunoobj.cxx

 	return sbxToUnoValueImpl( pVar );
 }
 
+
+// Funktion, um einen globalen Bezeichner im
+// UnoScope zu suchen und fuer Sbx zu wrappen
+static bool implGetTypeByName( const String& rName, Type& rRetType )
+{
+	bool bSuccess = false;
+
+    Reference< XHierarchicalNameAccess > xTypeAccess = getTypeProvider_Impl();
+    if( xTypeAccess->hasByHierarchicalName( rName ) )
+    {
+        Any aRet = xTypeAccess->getByHierarchicalName( rName );
+		Reference< XTypeDescription > xTypeDesc;
+		aRet >>= xTypeDesc;
+
+        if( xTypeDesc.is() )
+        {
+			rRetType = Type( xTypeDesc->getTypeClass(), xTypeDesc->getName() );
+			bSuccess = true;
+        }
+    }
+	return bSuccess;
+}
+
+
 // Konvertierung von Sbx nach Uno mit bekannter Zielklasse
 Any sbxToUnoValue( SbxVariable* pVar, const Type& rType, Property* pUnoProperty )
 {
 		}
 		break;
 
+		case TypeClass_TYPE:
+		{
+			if( eBaseType == SbxOBJECT )
+			{
+				// XIdlClass?
+				Reference< XIdlClass > xIdlClass;
+
+				SbxBaseRef pObj = (SbxBase*)pVar->GetObject();
+				if( pObj && pObj->ISA(SbUnoObject) )
+				{
+					Any aUnoAny = ((SbUnoObject*)(SbxBase*)pObj)->getUnoAny();
+					aUnoAny >>= xIdlClass;
+				}
+
+				if( xIdlClass.is() )
+				{
+					::rtl::OUString aClassName = xIdlClass->getName();
+					Type aType( xIdlClass->getTypeClass(), aClassName.getStr() );
+					aRetVal <<= aType;
+				}
+			}
+			else if( eBaseType == SbxSTRING )
+			{
+				// String representing type?
+				String aTypeName = pVar->GetString();
+				Type aType;
+				bool bSuccess = implGetTypeByName( aTypeName, aType );
+				if( bSuccess )
+					aRetVal <<= aType;
+			}
+		}
+		break;
+
 		/* folgende Typen lassen wir erstmal weg
 		case TypeClass_SERVICE:			break;
 		case TypeClass_CLASS:			break;
     (void)pBasic;
     (void)bWrite;
 
+	static String aTypeTypeString( RTL_CONSTASCII_USTRINGPARAM("type") );
+
 	// 2 parameters needed
 	if ( rPar.Count() != 3 )
 	{
 	String aTypeName = rPar.Get(1)->GetString();
     SbxVariable* pVal = rPar.Get(2);
 
+	if( aTypeName == aTypeTypeString )
+	{
+		SbxDataType eBaseType = pVal->SbxValue::GetType();
+		String aValTypeName;
+		if( eBaseType == SbxSTRING )
+		{
+			aValTypeName = pVal->GetString();
+		}
+		else if( eBaseType == SbxOBJECT )
+		{
+			// XIdlClass?
+			Reference< XIdlClass > xIdlClass;
+
+			SbxBaseRef pObj = (SbxBase*)pVal->GetObject();
+			if( pObj && pObj->ISA(SbUnoObject) )
+			{
+				Any aUnoAny = ((SbUnoObject*)(SbxBase*)pObj)->getUnoAny();
+				aUnoAny >>= xIdlClass;
+			}
+
+			if( xIdlClass.is() )
+				aValTypeName = xIdlClass->getName();
+		}
+		Type aType;
+		bool bSuccess = implGetTypeByName( aValTypeName, aType );
+		if( bSuccess )
+		{
+			Any aTypeAny( aType );
+			SbxVariableRef refVar = rPar.Get(0);
+			SbxObjectRef xUnoAnyObject = new SbUnoAnyObject( aTypeAny );
+			refVar->PutObject( xUnoAnyObject );
+		}
+		return;
+	}
+
     // Check the type
     Reference< XHierarchicalNameAccess > xTypeAccess = getTypeProvider_Impl();
     Any aRet;

basic/source/runtime/dllmgr.cxx

         return e;
     }
     std::vector< char > * blob = data.newBlob();
-    blob->insert(blob->begin(), str.getStr(), str.getStr() + str.getLength());
+    blob->insert(
+        blob->begin(), str.getStr(), str.getStr() + str.getLength() + 1);
     *buffer = address(*blob);
     data.unmarshalStrings.push_back(StringData(variable, *buffer, special));
     return ERRCODE_NONE;

berkeleydb/makefile.mk

 db_LIBS=
 .IF "$(MINGW_SHARED_GXXLIB)"=="YES"
 CFLAGS+=-D_GLIBCXX_DLL
-db_LIBS+=-lstdc++_s
+db_LIBS+=$(MINGW_SHARED_LIBSTDCPP)
 .ENDIF
 db_LIBXSO_LIBS=$(LIBSTLPORT) $(db_LIBS)
 .IF "$(MINGW_SHARED_GCCLIB)"=="YES"

binfilter/inc/bf_so3/svstor.hxx

 {
 	pObj = (SvStorage *)SvStorage::ClassFactory()->CastAndAddRef( pObjP );
 }
-inline SvStorageRef::SvStorageRef( SotObject * pObjP, SvCastEnum )
-{
-	pObj = (SvStorage *)SvStorage::ClassFactory()->AggCastAndAddRef( pObjP );
-}
 
 }
 

cairo/cairo/makefile.mk

 cairo_CC+=-shared-libgcc
 .ENDIF
 .IF "$(MINGW_SHARED_GXXLIB)"=="YES"
-cairo_LIBS+=-lstdc++_s
+cairo_LIBS+=$(MINGW_SHARED_LIBSTDCPP)
 .ENDIF
 
 CONFIGURE_DIR=

chart2/source/controller/chartapiwrapper/ChartDataWrapper.cxx

 
     virtual bool setsCategories( bool bDataInColumns )
     {
-        return !bDataInColumns;
+        return bDataInColumns;
     }
 
     virtual void apply( const Reference< XComplexDescriptionAccess >& xDataAccess )

chart2/source/controller/dialogs/dlg_ObjectProperties.cxx

 #include "chartview/NumberFormatterWrapper.hxx"
 #include "AxisIndexDefines.hxx"
 #include "AxisHelper.hxx"
+#include "ExplicitCategoriesProvider.hxx"
 
 #include <com/sun/star/chart2/XAxis.hpp>
 #include <com/sun/star/chart2/XChartType.hpp>
         , m_bIsCrossingAxisIsCategoryAxis(false)
         , m_aCategories()
         , m_xChartDocument( 0 )
+        , m_bComplexCategoriesAxis( false )
 {
     rtl::OUString aParticleID = ObjectIdentifier::getParticleID( m_aObjectCID );
     m_bAffectsMultipleObjects = aParticleID.equals(C2U("ALLELEMENTS"));
                     if( m_bIsCrossingAxisIsCategoryAxis )
                         m_aCategories = DiagramHelper::getExplicitSimpleCategories( Reference< chart2::XChartDocument >( xChartModel, uno::UNO_QUERY) );
                 }
+
+                m_bComplexCategoriesAxis = false;
+                if ( nDimensionIndex == 0 && aData.AxisType == chart2::AxisType::CATEGORY )
+                {
+                    ExplicitCategoriesProvider aExplicitCategoriesProvider( xCooSys, xChartModel ); 
+                    m_bComplexCategoriesAxis = aExplicitCategoriesProvider.hasComplexCategories();
+                }
             }
         }
 
 {
     return m_xChartDocument;
 }
+bool ObjectPropertiesDialogParameter::IsComplexCategoriesAxis() const
+{
+    return m_bComplexCategoriesAxis;
+}
 
 //const USHORT nNoArrowDlg          = 1100;
 const USHORT nNoArrowNoShadowDlg    = 1101;
         {
             bool bShowStaggeringControls = m_pParameter->CanAxisLabelsBeStaggered();
             ((SchAxisLabelTabPage&)rPage).ShowStaggeringControls( bShowStaggeringControls );
+            ( dynamic_cast< SchAxisLabelTabPage& >( rPage ) ).SetComplexCategories( m_pParameter->IsComplexCategoriesAxis() );
             break;
         }
 

chart2/source/controller/dialogs/tp_AxisLabel.cxx

         m_nInitialDegrees( 0 ),
         m_bHasInitialDegrees( true ),
         m_bInitialStacking( false ),
-        m_bHasInitialStacking( true )
+        m_bHasInitialStacking( true ),
+        m_bComplexCategories( false )
 {
 	FreeResource();
 
 	}
 }
 
+void SchAxisLabelTabPage::SetComplexCategories( bool bComplexCategories )
+{
+    m_bComplexCategories = bComplexCategories;
+}
+
 // event handling routines
 // -----------------------
 
 	aRbAuto.Enable( bEnable );
 
 	aFlTextFlow.Enable( bEnable );
-	aCbTextOverlap.Enable( bEnable );
+	aCbTextOverlap.Enable( bEnable && !m_bComplexCategories );
 	aCbTextBreak.Enable( bEnable );
 
     m_aFtTextDirection.Enable( bEnable );

chart2/source/controller/dialogs/tp_AxisLabel.hxx

     bool                m_bHasInitialDegrees;       /// false = DialControl in tristate
     bool                m_bInitialStacking;
     bool                m_bHasInitialStacking;      /// false = checkbox in tristate
+    bool                m_bComplexCategories;
 
     DECL_LINK ( ToggleShowLabel, void* );
 
 	virtual void Reset( const SfxItemSet& rInAttrs );
 
     void ShowStaggeringControls( BOOL bShowStaggeringControls );
+    void SetComplexCategories( bool bComplexCategories );
 };
 //.............................................................................
 } //namespace chart

chart2/source/controller/inc/dlg_ObjectProperties.hxx

     ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XChartDocument >
         getDocument() const;
 
+    bool IsComplexCategoriesAxis() const;
+
 private:
 	rtl::OUString	m_aObjectCID;
 	ObjectType		m_eObjectType;
     ::com::sun::star::uno::Sequence< rtl::OUString > m_aCategories;
 
     ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XChartDocument > m_xChartDocument;
+
+    bool m_bComplexCategoriesAxis;
 };
 
 /*************************************************************************

chart2/source/view/axes/VCartesianAxis.cxx

 #include <com/sun/star/text/XText.hpp>
 #include <com/sun/star/text/WritingMode2.hpp>
 #include <editeng/unoprnms.hxx>
+#include <svx/unoshape.hxx>
+#include <svx/unoshtxt.hxx>
 
 #include <algorithm>
 #include <memory>
 
     //correctPositionForRotation
     LabelPositionHelper::correctPositionForRotation( xShape2DText
-        , rAxisProperties.m_aLabelAlignment, rAxisLabelProperties.fRotationAngleDegree, false );
+        , rAxisProperties.m_aLabelAlignment, rAxisLabelProperties.fRotationAngleDegree, rAxisProperties.m_bComplexCategories );
 
     return xShape2DText;
 }
     return pTickInfo;
 }
 
-B2DVector lcl_getLabelsDistance( TickIter& rIter, const B2DVector& rDistanceTickToText )
+B2DVector lcl_getLabelsDistance( TickIter& rIter, const B2DVector& rDistanceTickToText, double fRotationAngleDegree )
 {
     //calculates the height or width of a line of labels
     //thus a following line of labels can be shifted for that distance
         xShape2DText = pTickInfo->xTextShape;
         if( xShape2DText.is() )
         {
-            awt::Size aSize  = xShape2DText->getSize();
+            awt::Size aSize = ShapeFactory::getSizeAfterRotation( xShape2DText, fRotationAngleDegree );
             if(fabs(aStaggerDirection.getX())>fabs(aStaggerDirection.getY()))
                 nDistance = ::std::max(nDistance,aSize.Width);
             else
     }
 }
 
+bool lcl_hasWordBreak( const Reference< drawing::XShape >& rxShape )
+{
+    if ( rxShape.is() )
+    {
+        SvxShape* pShape = SvxShape::getImplementation( rxShape );
+        SvxShapeText* pShapeText = dynamic_cast< SvxShapeText* >( pShape );
+        if ( pShapeText )
+        {
+            SvxTextEditSource* pTextEditSource = dynamic_cast< SvxTextEditSource* >( pShapeText->GetEditSource() );
+            if ( pTextEditSource )
+            {
+                pTextEditSource->UpdateOutliner();
+                SvxTextForwarder* pTextForwarder = pTextEditSource->GetTextForwarder();
+                if ( pTextForwarder )
+                {
+                    USHORT nParaCount = pTextForwarder->GetParagraphCount();
+                    for ( USHORT nPara = 0; nPara < nParaCount; ++nPara )
+                    {
+                        USHORT nLineCount = pTextForwarder->GetLineCount( nPara );
+                        for ( USHORT nLine = 0; nLine < nLineCount; ++nLine )
+                        {
+                            USHORT nLineStart = 0;
+                            USHORT nLineEnd = 0;
+                            pTextForwarder->GetLineBoundaries( nLineStart, nLineEnd, nPara, nLine );
+                            USHORT nWordStart = 0;
+                            USHORT nWordEnd = 0;
+                            if ( pTextForwarder->GetWordIndices( nPara, nLineStart, nWordStart, nWordEnd ) &&
+                                 ( nWordStart != nLineStart ) )
+                            {
+                                return true;
+                            }
+                        }
+                    }
+                }
+            }
+        }
+    }
+
+    return false;
+}
+
 class MaxLabelEquidistantTickIter : public EquidistantTickIter
 {
     //iterate over first two and last two labels and the longest label
 
         recordMaximumTextSize( pTickInfo->xTextShape, rAxisLabelProperties.fRotationAngleDegree );
 
+         //better rotate if single words are broken apart
+        if( nLimitedSpaceForText>0 && !rAxisLabelProperties.bOverlapAllowed
+                && ::rtl::math::approxEqual( rAxisLabelProperties.fRotationAngleDegree, 0.0 )
+                && m_aAxisProperties.m_bComplexCategories
+                && lcl_hasWordBreak( pTickInfo->xTextShape ) )
+        {
+            rAxisLabelProperties.fRotationAngleDegree = 90;
+            rAxisLabelProperties.bLineBreakAllowed = false;
+            m_aAxisLabelProperties.fRotationAngleDegree = rAxisLabelProperties.fRotationAngleDegree;
+            removeTextShapesFromTicks();
+            return false;
+        }
+        
         //if NO OVERLAP -> remove overlapping shapes
         if( pLastVisibleNeighbourTickInfo && !rAxisLabelProperties.bOverlapAllowed )
         {
-            if( doesOverlap( pLastVisibleNeighbourTickInfo->xTextShape, pTickInfo->xTextShape, m_aAxisLabelProperties.fRotationAngleDegree ) )
+            if( doesOverlap( pLastVisibleNeighbourTickInfo->xTextShape, pTickInfo->xTextShape, rAxisLabelProperties.fRotationAngleDegree ) )
             {
                 bool bOverlapAlsoAfterSwitchingOnAutoStaggering = true;
                 if( !bIsStaggered && isAutoStaggeringOfLabelsAllowed( rAxisLabelProperties, bIsHorizontalAxis, bIsVerticalAxis ) )
             ::std::auto_ptr< TickIter > apTickIter = createLabelTickIterator( nTextLevel );
             if(apTickIter.get())
             {
+                double fRotationAngleDegree = m_aAxisLabelProperties.fRotationAngleDegree;
                 if( nTextLevel>0 )
+                {
                     lcl_shiftLables( *apTickIter.get(), aCummulatedLabelsDistance );
+                    fRotationAngleDegree = 0.0;
+                }
                 aCummulatedLabelsDistance += lcl_getLabelsDistance( *apTickIter.get()
-                    , pTickmarkHelper2D->getDistanceAxisTickToText( m_aAxisProperties ) );
+                    , pTickmarkHelper2D->getDistanceAxisTickToText( m_aAxisProperties )
+                    , fRotationAngleDegree );
             }
         }
     }
 
         lcl_shiftLables( aOuterIter
             , lcl_getLabelsDistance( aInnerIter
-                , pTickmarkHelper2D->getDistanceAxisTickToText( m_aAxisProperties ) ) );
+                , pTickmarkHelper2D->getDistanceAxisTickToText( m_aAxisProperties ), 0.0 ) );
     }
 }
 
                         nScreenDistanceBetweenTicks*=2; //the above used tick iter does contain also the sub ticks -> thus the given distance is only the half
                 }
 
-                AxisLabelProperties aCopy(m_aAxisLabelProperties);
-                aCopy.bRhythmIsFix = true;
-                aCopy.nRhythm = 1;
-                AxisLabelProperties& rAxisLabelProperties = nTextLevel==0 ? m_aAxisLabelProperties : aCopy;
+                AxisLabelProperties aComplexProps(m_aAxisLabelProperties);
+                if( m_aAxisProperties.m_bComplexCategories )
+                {
+                    if( nTextLevel==0 )
+                    {
+                        aComplexProps.bLineBreakAllowed = true;
+                        aComplexProps.bOverlapAllowed = !::rtl::math::approxEqual( aComplexProps.fRotationAngleDegree, 0.0 );
+                    }
+                    else
+                    {
+                        aComplexProps.bOverlapAllowed = true;
+                        aComplexProps.bRhythmIsFix = true;
+                        aComplexProps.nRhythm = 1;
+                        aComplexProps.fRotationAngleDegree = 0.0;
+                    }
+                }
+                AxisLabelProperties& rAxisLabelProperties =  m_aAxisProperties.m_bComplexCategories ? aComplexProps : m_aAxisLabelProperties;
                 while( !createTextShapes( m_xTextTarget, *apTickIter.get(), rAxisLabelProperties, pTickmarkHelper2D, nScreenDistanceBetweenTicks ) )
                 {
                 };
 
         ::std::vector< ::std::vector< TickInfo > >::iterator aDepthIter = m_aAllTickInfos.begin();
         const ::std::vector< ::std::vector< TickInfo > >::const_iterator aDepthEnd  = m_aAllTickInfos.end();
-        for( ; aDepthIter != aDepthEnd; aDepthIter++ )
+        for( sal_Int32 nDepth=0; aDepthIter != aDepthEnd; aDepthIter++, nDepth++ )
         {
             ::std::vector< TickInfo >::iterator aTickIter = aDepthIter->begin();
             const ::std::vector< TickInfo >::const_iterator aTickEnd  = aDepthIter->end();
                         static_cast<sal_Int32>(aTickScreenPos2D.getX())
                         ,static_cast<sal_Int32>(aTickScreenPos2D.getY()));
 
+                    double fRotationAngleDegree = m_aAxisLabelProperties.fRotationAngleDegree;
+                    if( nDepth>0 )
+                        fRotationAngleDegree = 0.0;
+
                     // #i78696# use mathematically correct rotation now
-                    const double fRotationAnglePi(m_aAxisLabelProperties.fRotationAngleDegree * (F_PI / -180.0));
+                    const double fRotationAnglePi(fRotationAngleDegree * (F_PI / -180.0));
                     uno::Any aATransformation = ShapeFactory::makeTransformation(aAnchorScreenPosition2D, fRotationAnglePi);
 
                     //set new position
 
                     //correctPositionForRotation
                     LabelPositionHelper::correctPositionForRotation( xShape2DText
-                        , m_aAxisProperties.m_aLabelAlignment, m_aAxisLabelProperties.fRotationAngleDegree, false );
+                        , m_aAxisProperties.m_aLabelAlignment, fRotationAngleDegree, m_aAxisProperties.m_bComplexCategories );
                 }                
             }
         }
                 ::std::auto_ptr< TickIter > apTickIter = createLabelTickIterator( nTextLevel );
                 if( apTickIter.get() )
                 {
-                    B2DVector aLabelsDistance( lcl_getLabelsDistance( *apTickIter.get(), pTickmarkHelper2D->getDistanceAxisTickToText( m_aAxisProperties, false ) ) );
+                    double fRotationAngleDegree = m_aAxisLabelProperties.fRotationAngleDegree;
+                    if( nTextLevel>0 )
+                        fRotationAngleDegree = 0.0;
+                    B2DVector aLabelsDistance( lcl_getLabelsDistance( *apTickIter.get(), pTickmarkHelper2D->getDistanceAxisTickToText( m_aAxisProperties, false ), fRotationAngleDegree ) );
                     sal_Int32 nCurrentLength = static_cast<sal_Int32>(aLabelsDistance.getLength());
                     aTickmarkPropertiesList.push_back( m_aAxisProperties.makeTickmarkPropertiesForComplexCategories( nOffset + nCurrentLength, 0, nTextLevel ) );
                     nOffset += nCurrentLength;
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.