summaryrefslogtreecommitdiff
path: root/sw/source/ui/frmdlg/colmgr.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/ui/frmdlg/colmgr.cxx')
-rw-r--r--sw/source/ui/frmdlg/colmgr.cxx34
1 files changed, 17 insertions, 17 deletions
diff --git a/sw/source/ui/frmdlg/colmgr.cxx b/sw/source/ui/frmdlg/colmgr.cxx
index 0e18946af778..90f695aa8ae5 100644
--- a/sw/source/ui/frmdlg/colmgr.cxx
+++ b/sw/source/ui/frmdlg/colmgr.cxx
@@ -45,12 +45,12 @@
-void FitToActualSize(SwFmtCol& rCol, USHORT nWidth)
+void FitToActualSize(SwFmtCol& rCol, sal_uInt16 nWidth)
{
- const USHORT nCount = rCol.GetColumns().Count();
- for(USHORT i = 0; i < nCount; ++i)
+ const sal_uInt16 nCount = rCol.GetColumns().Count();
+ for(sal_uInt16 i = 0; i < nCount; ++i)
{
- const USHORT nTmp = rCol.CalcColWidth(i, nWidth);
+ const sal_uInt16 nTmp = rCol.CalcColWidth(i, nWidth);
rCol.GetColumns()[i]->SetWishWidth(nTmp);
}
rCol.SetWishWidth(nWidth);
@@ -64,7 +64,7 @@ void FitToActualSize(SwFmtCol& rCol, USHORT nWidth)
-void SwColMgr::SetCount(USHORT nCount, USHORT nGutterWidth)
+void SwColMgr::SetCount(sal_uInt16 nCount, sal_uInt16 nGutterWidth)
{
aFmtCol.Init(nCount, nGutterWidth, nWidth);
aFmtCol.SetWishWidth(nWidth);
@@ -73,9 +73,9 @@ void SwColMgr::SetCount(USHORT nCount, USHORT nGutterWidth)
-USHORT SwColMgr::GetGutterWidth( USHORT nPos ) const
+sal_uInt16 SwColMgr::GetGutterWidth( sal_uInt16 nPos ) const
{
- USHORT nRet;
+ sal_uInt16 nRet;
if(nPos == USHRT_MAX )
nRet = GetCount() > 1 ? aFmtCol.GetGutterWidth() : DEF_GUTTER_WIDTH;
else
@@ -92,7 +92,7 @@ USHORT SwColMgr::GetGutterWidth( USHORT nPos ) const
--------------------------------------------------*/
-void SwColMgr::SetGutterWidth(USHORT nGutterWidth, USHORT nPos )
+void SwColMgr::SetGutterWidth(sal_uInt16 nGutterWidth, sal_uInt16 nPos )
{
if(nPos == USHRT_MAX)
aFmtCol.SetGutterWidth(nGutterWidth, nWidth);
@@ -100,7 +100,7 @@ void SwColMgr::SetGutterWidth(USHORT nGutterWidth, USHORT nPos )
{
DBG_ASSERT(nPos < GetCount() - 1, "Spalte ueberindiziert" );
SwColumns& rCols = aFmtCol.GetColumns();
- USHORT nGutterWidth2 = nGutterWidth / 2;
+ sal_uInt16 nGutterWidth2 = nGutterWidth / 2;
rCols.GetObject(nPos)->SetRight(nGutterWidth2);
rCols.GetObject(nPos + 1)->SetLeft(nGutterWidth2);
}
@@ -122,7 +122,7 @@ short SwColMgr::GetLineHeightPercent() const
void SwColMgr::SetLineHeightPercent(short nPercent)
{
ASSERT(nPercent <= 100, LineHeight darf nur bis 100 % gross sein);
- aFmtCol.SetLineHeight((BYTE)nPercent);
+ aFmtCol.SetLineHeight((sal_uInt8)nPercent);
}
/*------------------------------------------------------------------------
Beschreibung: Spaltenbreite
@@ -130,7 +130,7 @@ void SwColMgr::SetLineHeightPercent(short nPercent)
-USHORT SwColMgr::GetColWidth(USHORT nIdx) const
+sal_uInt16 SwColMgr::GetColWidth(sal_uInt16 nIdx) const
{
ASSERT(nIdx < GetCount(), Spaltenarray ueberindiziert.);
return aFmtCol.CalcPrtColWidth(nIdx, nWidth);
@@ -138,7 +138,7 @@ USHORT SwColMgr::GetColWidth(USHORT nIdx) const
-void SwColMgr::SetColWidth(USHORT nIdx, USHORT nWd)
+void SwColMgr::SetColWidth(sal_uInt16 nIdx, sal_uInt16 nWd)
{
ASSERT(nIdx < GetCount(), Spaltenarray ueberindiziert.);
aFmtCol.GetColumns()[nIdx]->SetWishWidth(nWd);
@@ -151,7 +151,7 @@ void SwColMgr::SetColWidth(USHORT nIdx, USHORT nWd)
-void SwColMgr::SetActualWidth(USHORT nW)
+void SwColMgr::SetActualWidth(sal_uInt16 nW)
{
nWidth = nW;
::FitToActualSize(aFmtCol, nW);
@@ -163,18 +163,18 @@ void SwColMgr::SetActualWidth(USHORT nW)
-SwColMgr::SwColMgr(const SfxItemSet& rSet, USHORT nActWidth) :
+SwColMgr::SwColMgr(const SfxItemSet& rSet, sal_uInt16 nActWidth) :
aFmtCol((const SwFmtCol&)rSet.Get(RES_COL)),
nWidth(nActWidth)
{
if(nWidth == USHRT_MAX)
{
- nWidth = (USHORT)((const SwFmtFrmSize&)rSet.Get(RES_FRM_SIZE)).GetWidth();
+ nWidth = (sal_uInt16)((const SwFmtFrmSize&)rSet.Get(RES_FRM_SIZE)).GetWidth();
if (nWidth < MINLAY)
nWidth = USHRT_MAX;
const SvxLRSpaceItem &rLR = (const SvxLRSpaceItem&)rSet.Get(RES_LR_SPACE);
- nWidth = nWidth - (USHORT)rLR.GetLeft();
- nWidth = nWidth - (USHORT)rLR.GetRight();
+ nWidth = nWidth - (sal_uInt16)rLR.GetLeft();
+ nWidth = nWidth - (sal_uInt16)rLR.GetRight();
}
::FitToActualSize(aFmtCol, nWidth);
}