svdotxed.cxx (c0739476) | svdotxed.cxx (26734c99) |
---|---|
1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 55 unchanged lines hidden (view full) --- 64 mbInEditMode = sal_True; 65 66 sal_uInt16 nOutlinerMode = OUTLINERMODE_OUTLINEOBJECT; 67 if ( !IsOutlText() ) 68 nOutlinerMode = OUTLINERMODE_TEXTOBJECT; 69 rOutl.Init( nOutlinerMode ); 70 rOutl.SetRefDevice( pModel->GetRefDevice() ); 71 | 1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 55 unchanged lines hidden (view full) --- 64 mbInEditMode = sal_True; 65 66 sal_uInt16 nOutlinerMode = OUTLINERMODE_OUTLINEOBJECT; 67 if ( !IsOutlText() ) 68 nOutlinerMode = OUTLINERMODE_TEXTOBJECT; 69 rOutl.Init( nOutlinerMode ); 70 rOutl.SetRefDevice( pModel->GetRefDevice() ); 71 |
72 const sal_Bool bFitToSize(GetFitToSize()); | 72 SdrFitToSizeType eFit=GetFitToSize(); 73 FASTBOOL bFitToSize=(eFit==SDRTEXTFIT_PROPORTIONAL || eFit==SDRTEXTFIT_ALLLINES); |
73 FASTBOOL bContourFrame=IsContourTextFrame(); 74 ImpSetTextEditParams(); 75 76 if (!bContourFrame) { 77 sal_uIntPtr nStat=rOutl.GetControlWord(); 78 nStat|=EE_CNTRL_AUTOPAGESIZE; 79 if (bFitToSize) nStat|=EE_CNTRL_STRETCHING; else nStat&=~EE_CNTRL_STRETCHING; 80 rOutl.SetControlWord(nStat); --- 55 unchanged lines hidden (view full) --- 136 rOutl.UpdateFields(); 137 rOutl.ClearModifyFlag(); 138 139 return sal_True; 140} 141 142void SdrTextObj::TakeTextEditArea(Size* pPaperMin, Size* pPaperMax, Rectangle* pViewInit, Rectangle* pViewMin) const 143{ | 74 FASTBOOL bContourFrame=IsContourTextFrame(); 75 ImpSetTextEditParams(); 76 77 if (!bContourFrame) { 78 sal_uIntPtr nStat=rOutl.GetControlWord(); 79 nStat|=EE_CNTRL_AUTOPAGESIZE; 80 if (bFitToSize) nStat|=EE_CNTRL_STRETCHING; else nStat&=~EE_CNTRL_STRETCHING; 81 rOutl.SetControlWord(nStat); --- 55 unchanged lines hidden (view full) --- 137 rOutl.UpdateFields(); 138 rOutl.ClearModifyFlag(); 139 140 return sal_True; 141} 142 143void SdrTextObj::TakeTextEditArea(Size* pPaperMin, Size* pPaperMax, Rectangle* pViewInit, Rectangle* pViewMin) const 144{ |
144 const sal_Bool bFitToSize(GetFitToSize()); | 145 SdrFitToSizeType eFit=GetFitToSize(); 146 FASTBOOL bFitToSize=(eFit==SDRTEXTFIT_PROPORTIONAL || eFit==SDRTEXTFIT_ALLLINES); |
145 Size aPaperMin,aPaperMax; 146 Rectangle aViewInit; 147 TakeTextAnchorRect(aViewInit); 148 if (aGeo.nDrehWink!=0) { 149 Point aCenter(aViewInit.Center()); 150 aCenter-=aViewInit.TopLeft(); 151 Point aCenter0(aCenter); 152 RotatePoint(aCenter,Point(),aGeo.nSin,aGeo.nCos); --- 167 unchanged lines hidden (view full) --- 320{ 321 if (pEdtOutl!=NULL) { 322 FASTBOOL bUpdMerk=pEdtOutl->GetUpdateMode(); 323 if (bUpdMerk) pEdtOutl->SetUpdateMode(sal_False); 324 Size aPaperMin; 325 Size aPaperMax; 326 Rectangle aEditArea; 327 TakeTextEditArea(&aPaperMin,&aPaperMax,&aEditArea,NULL); | 147 Size aPaperMin,aPaperMax; 148 Rectangle aViewInit; 149 TakeTextAnchorRect(aViewInit); 150 if (aGeo.nDrehWink!=0) { 151 Point aCenter(aViewInit.Center()); 152 aCenter-=aViewInit.TopLeft(); 153 Point aCenter0(aCenter); 154 RotatePoint(aCenter,Point(),aGeo.nSin,aGeo.nCos); --- 167 unchanged lines hidden (view full) --- 322{ 323 if (pEdtOutl!=NULL) { 324 FASTBOOL bUpdMerk=pEdtOutl->GetUpdateMode(); 325 if (bUpdMerk) pEdtOutl->SetUpdateMode(sal_False); 326 Size aPaperMin; 327 Size aPaperMax; 328 Rectangle aEditArea; 329 TakeTextEditArea(&aPaperMin,&aPaperMax,&aEditArea,NULL); |
330 //SdrFitToSizeType eFit=GetFitToSize(); 331 //FASTBOOL bFitToSize=(eFit==SDRTEXTFIT_PROPORTIONAL || eFit==SDRTEXTFIT_ALLLINES); |
|
328 FASTBOOL bContourFrame=IsContourTextFrame(); | 332 FASTBOOL bContourFrame=IsContourTextFrame(); |
333 //EVAnchorMode eAM=(EVAnchorMode)GetOutlinerViewAnchorMode(); 334 //sal_uIntPtr nViewAnz=pEdtOutl->GetViewCount(); |
|
329 pEdtOutl->SetMinAutoPaperSize(aPaperMin); 330 pEdtOutl->SetMaxAutoPaperSize(aPaperMax); 331 pEdtOutl->SetPaperSize(Size()); 332 if (bContourFrame) { 333 Rectangle aAnchorRect; 334 TakeTextAnchorRect(aAnchorRect); 335 ImpSetContourPolygon(*pEdtOutl,aAnchorRect, sal_True); 336 } 337 if (bUpdMerk) pEdtOutl->SetUpdateMode(sal_True); 338 } 339} 340 | 335 pEdtOutl->SetMinAutoPaperSize(aPaperMin); 336 pEdtOutl->SetMaxAutoPaperSize(aPaperMax); 337 pEdtOutl->SetPaperSize(Size()); 338 if (bContourFrame) { 339 Rectangle aAnchorRect; 340 TakeTextAnchorRect(aAnchorRect); 341 ImpSetContourPolygon(*pEdtOutl,aAnchorRect, sal_True); 342 } 343 if (bUpdMerk) pEdtOutl->SetUpdateMode(sal_True); 344 } 345} 346 |