Lines 95-101
Link Here
|
95 |
|
95 |
|
96 |
//----------------------------------------------------------------------- |
96 |
//----------------------------------------------------------------------- |
97 |
|
97 |
|
98 |
SwWriteTableCol::SwWriteTableCol(USHORT nPosition) |
98 |
SwWriteTableCol::SwWriteTableCol(sal_uInt32 nPosition) |
99 |
: nPos(nPosition), nWidthOpt(0), bRelWidthOpt(false), bOutWidth(true), |
99 |
: nPos(nPosition), nWidthOpt(0), bRelWidthOpt(false), bOutWidth(true), |
100 |
bLeftBorder(true), bRightBorder(true) |
100 |
bLeftBorder(true), bRightBorder(true) |
101 |
{ |
101 |
{ |
Lines 103-115
Link Here
|
103 |
|
103 |
|
104 |
//----------------------------------------------------------------------- |
104 |
//----------------------------------------------------------------------- |
105 |
|
105 |
|
106 |
long SwWriteTable::GetBoxWidth( const SwTableBox *pBox ) |
106 |
sal_uInt32 SwWriteTable::GetBoxWidth( const SwTableBox *pBox ) |
107 |
{ |
107 |
{ |
108 |
const SwFrmFmt *pFmt = pBox->GetFrmFmt(); |
108 |
const SwFrmFmt *pFmt = pBox->GetFrmFmt(); |
109 |
const SwFmtFrmSize& aFrmSize= |
109 |
const SwFmtFrmSize& aFrmSize= |
110 |
(const SwFmtFrmSize&)pFmt->GetFmtAttr( RES_FRM_SIZE ); |
110 |
(const SwFmtFrmSize&)pFmt->GetFmtAttr( RES_FRM_SIZE ); |
111 |
|
111 |
|
112 |
return aFrmSize.GetSize().Width(); |
112 |
return sal::static_int_cast<sal_uInt32>(aFrmSize.GetSize().Width()); |
113 |
} |
113 |
} |
114 |
|
114 |
|
115 |
long SwWriteTable::GetLineHeight( const SwTableLine *pLine ) |
115 |
long SwWriteTable::GetLineHeight( const SwTableLine *pLine ) |
Lines 422-430
Link Here
|
422 |
} |
422 |
} |
423 |
|
423 |
|
424 |
void SwWriteTable::CollectTableRowsCols( long nStartRPos, |
424 |
void SwWriteTable::CollectTableRowsCols( long nStartRPos, |
425 |
USHORT nStartCPos, |
425 |
sal_uInt32 nStartCPos, |
426 |
long nParentLineHeight, |
426 |
long nParentLineHeight, |
427 |
USHORT nParentLineWidth, |
427 |
sal_uInt32 nParentLineWidth, |
428 |
const SwTableLines& rLines, |
428 |
const SwTableLines& rLines, |
429 |
USHORT nDepth ) |
429 |
USHORT nDepth ) |
430 |
{ |
430 |
{ |
Lines 432-438
Link Here
|
432 |
USHORT nLines = rLines.Count(); |
432 |
USHORT nLines = rLines.Count(); |
433 |
|
433 |
|
434 |
#ifndef PRODUCT |
434 |
#ifndef PRODUCT |
435 |
USHORT nEndCPos = 0; |
435 |
sal_uInt32 nEndCPos = 0; |
436 |
#endif |
436 |
#endif |
437 |
|
437 |
|
438 |
long nRPos = nStartRPos; |
438 |
long nRPos = nStartRPos; |
Lines 487-502
Link Here
|
487 |
const SwTableBoxes& rBoxes = pLine->GetTabBoxes(); |
487 |
const SwTableBoxes& rBoxes = pLine->GetTabBoxes(); |
488 |
USHORT nBoxes = rBoxes.Count(); |
488 |
USHORT nBoxes = rBoxes.Count(); |
489 |
|
489 |
|
490 |
USHORT nCPos = nStartCPos; |
490 |
sal_uInt32 nCPos = nStartCPos; |
491 |
for( USHORT nBox=0; nBox<nBoxes; nBox++ ) |
491 |
for( USHORT nBox=0; nBox<nBoxes; nBox++ ) |
492 |
{ |
492 |
{ |
493 |
const SwTableBox *pBox = rBoxes[nBox]; |
493 |
const SwTableBox *pBox = rBoxes[nBox]; |
494 |
|
494 |
|
495 |
USHORT nOldCPos = nCPos; |
495 |
sal_uInt32 nOldCPos = nCPos; |
496 |
|
496 |
|
497 |
if( nBox < nBoxes-1 || (nParentLineWidth==0 && nLine==0) ) |
497 |
if( nBox < nBoxes-1 || (nParentLineWidth==0 && nLine==0) ) |
498 |
{ |
498 |
{ |
499 |
nCPos = nCPos + (USHORT)GetBoxWidth( pBox ); |
499 |
nCPos = nCPos + GetBoxWidth( pBox ); |
500 |
SwWriteTableCol *pCol = new SwWriteTableCol( nCPos ); |
500 |
SwWriteTableCol *pCol = new SwWriteTableCol( nCPos ); |
501 |
|
501 |
|
502 |
USHORT nCol; |
502 |
USHORT nCol; |
Lines 515-521
Link Here
|
515 |
else |
515 |
else |
516 |
{ |
516 |
{ |
517 |
#ifndef PRODUCT |
517 |
#ifndef PRODUCT |
518 |
USHORT nCheckPos = nCPos + (USHORT)GetBoxWidth( pBox ); |
518 |
sal_uInt32 nCheckPos = nCPos + GetBoxWidth( pBox ); |
519 |
if( !nEndCPos ) |
519 |
if( !nEndCPos ) |
520 |
{ |
520 |
{ |
521 |
nEndCPos = nCheckPos; |
521 |
nEndCPos = nCheckPos; |
Lines 553-561
Link Here
|
553 |
|
553 |
|
554 |
|
554 |
|
555 |
void SwWriteTable::FillTableRowsCols( long nStartRPos, USHORT nStartRow, |
555 |
void SwWriteTable::FillTableRowsCols( long nStartRPos, USHORT nStartRow, |
556 |
USHORT nStartCPos, USHORT nStartCol, |
556 |
sal_uInt32 nStartCPos, USHORT nStartCol, |
557 |
long nParentLineHeight, |
557 |
long nParentLineHeight, |
558 |
USHORT nParentLineWidth, |
558 |
sal_uInt32 nParentLineWidth, |
559 |
const SwTableLines& rLines, |
559 |
const SwTableLines& rLines, |
560 |
const SvxBrushItem* pParentBrush, |
560 |
const SvxBrushItem* pParentBrush, |
561 |
USHORT nDepth, |
561 |
USHORT nDepth, |
Lines 658-664
Link Here
|
658 |
} |
658 |
} |
659 |
|
659 |
|
660 |
USHORT nBoxes = rBoxes.Count(); |
660 |
USHORT nBoxes = rBoxes.Count(); |
661 |
USHORT nCPos = nStartCPos; |
661 |
sal_uInt32 nCPos = nStartCPos; |
662 |
USHORT nCol = nStartCol; |
662 |
USHORT nCol = nStartCol; |
663 |
|
663 |
|
664 |
for( USHORT nBox=0; nBox<nBoxes; nBox++ ) |
664 |
for( USHORT nBox=0; nBox<nBoxes; nBox++ ) |
Lines 666-675
Link Here
|
666 |
const SwTableBox *pBox = rBoxes[nBox]; |
666 |
const SwTableBox *pBox = rBoxes[nBox]; |
667 |
|
667 |
|
668 |
// Position der letzten ueberdeckten Spalte ermitteln |
668 |
// Position der letzten ueberdeckten Spalte ermitteln |
669 |
USHORT nOldCPos = nCPos; |
669 |
sal_uInt32 nOldCPos = nCPos; |
670 |
if( nBox < nBoxes-1 || (nParentLineWidth==0 && nLine==0) ) |
670 |
if( nBox < nBoxes-1 || (nParentLineWidth==0 && nLine==0) ) |
671 |
{ |
671 |
{ |
672 |
nCPos = nCPos + (USHORT)GetBoxWidth( pBox ); |
672 |
nCPos = nCPos + GetBoxWidth( pBox ); |
673 |
if( nBox==nBoxes-1 ) |
673 |
if( nBox==nBoxes-1 ) |
674 |
nParentLineWidth = nCPos - nStartCPos; |
674 |
nParentLineWidth = nCPos - nStartCPos; |
675 |
} |
675 |
} |