diff options
-rw-r--r-- | sw/source/ui/envelp/envfmt.cxx | 32 | ||||
-rw-r--r-- | sw/source/ui/envelp/envlop1.cxx | 36 | ||||
-rw-r--r-- | sw/source/ui/envelp/envprt.cxx | 18 | ||||
-rw-r--r-- | sw/source/uibase/app/appenv.cxx | 30 | ||||
-rw-r--r-- | sw/source/uibase/envelp/envimg.cxx | 198 | ||||
-rw-r--r-- | sw/source/uibase/inc/envimg.hxx | 26 |
6 files changed, 170 insertions, 170 deletions
diff --git a/sw/source/ui/envelp/envfmt.cxx b/sw/source/ui/envelp/envfmt.cxx index bedd8bb47fd9..0dc857836407 100644 --- a/sw/source/ui/envelp/envfmt.cxx +++ b/sw/source/ui/envelp/envfmt.cxx @@ -481,25 +481,25 @@ DeactivateRC SwEnvFormatPage::DeactivatePage(SfxItemSet* _pSet) void SwEnvFormatPage::FillItem(SwEnvItem& rItem) { - rItem.lAddrFromLeft = static_cast< sal_Int32 >(GetFieldVal(*m_pAddrLeftField)); - rItem.lAddrFromTop = static_cast< sal_Int32 >(GetFieldVal(*m_pAddrTopField )); - rItem.lSendFromLeft = static_cast< sal_Int32 >(GetFieldVal(*m_pSendLeftField)); - rItem.lSendFromTop = static_cast< sal_Int32 >(GetFieldVal(*m_pSendTopField )); + rItem.m_nAddrFromLeft = static_cast< sal_Int32 >(GetFieldVal(*m_pAddrLeftField)); + rItem.m_nAddrFromTop = static_cast< sal_Int32 >(GetFieldVal(*m_pAddrTopField )); + rItem.m_nSendFromLeft = static_cast< sal_Int32 >(GetFieldVal(*m_pSendLeftField)); + rItem.m_nSendFromTop = static_cast< sal_Int32 >(GetFieldVal(*m_pSendTopField )); const sal_uInt16 nPaper = aIDs[m_pSizeFormatBox->GetSelectedEntryPos()]; if (nPaper == (sal_uInt16)PAPER_USER) { long lWVal = static_cast< long >(GetFieldVal(*m_pSizeWidthField )); long lHVal = static_cast< long >(GetFieldVal(*m_pSizeHeightField)); - rItem.lWidth = std::max(lWVal, lHVal); - rItem.lHeight = std::min(lWVal, lHVal); + rItem.m_nWidth = std::max(lWVal, lHVal); + rItem.m_nHeight = std::min(lWVal, lHVal); } else { long lWVal = SvxPaperInfo::GetPaperSize((Paper)nPaper).Width (); long lHVal = SvxPaperInfo::GetPaperSize((Paper)nPaper).Height(); - rItem.lWidth = std::max(lWVal, lHVal); - rItem.lHeight = std::min(lWVal, lHVal); + rItem.m_nWidth = std::max(lWVal, lHVal); + rItem.m_nHeight = std::min(lWVal, lHVal); } } @@ -515,19 +515,19 @@ void SwEnvFormatPage::Reset(const SfxItemSet* rSet) const SwEnvItem& rItem = static_cast<const SwEnvItem&>( rSet->Get(FN_ENVELOP)); Paper ePaper = SvxPaperInfo::GetSvxPaper( - Size( std::min(rItem.lWidth, rItem.lHeight), - std::max(rItem.lWidth, rItem.lHeight)), MapUnit::MapTwip); + Size( std::min(rItem.m_nWidth, rItem.m_nHeight), + std::max(rItem.m_nWidth, rItem.m_nHeight)), MapUnit::MapTwip); for (size_t i = 0; i < aIDs.size(); ++i) if (aIDs[i] == (sal_uInt16)ePaper) m_pSizeFormatBox->SelectEntryPos(static_cast<sal_Int32>(i)); // Metric fields - SetFieldVal(*m_pAddrLeftField, rItem.lAddrFromLeft); - SetFieldVal(*m_pAddrTopField, rItem.lAddrFromTop ); - SetFieldVal(*m_pSendLeftField, rItem.lSendFromLeft); - SetFieldVal(*m_pSendTopField, rItem.lSendFromTop ); - SetFieldVal(*m_pSizeWidthField , std::max(rItem.lWidth, rItem.lHeight)); - SetFieldVal(*m_pSizeHeightField , std::min(rItem.lWidth, rItem.lHeight)); + SetFieldVal(*m_pAddrLeftField, rItem.m_nAddrFromLeft); + SetFieldVal(*m_pAddrTopField, rItem.m_nAddrFromTop ); + SetFieldVal(*m_pSendLeftField, rItem.m_nSendFromLeft); + SetFieldVal(*m_pSendTopField, rItem.m_nSendFromTop ); + SetFieldVal(*m_pSizeWidthField , std::max(rItem.m_nWidth, rItem.m_nHeight)); + SetFieldVal(*m_pSizeHeightField , std::min(rItem.m_nWidth, rItem.m_nHeight)); SetMinMax(); DELETEZ(GetParentSwEnvDlg()->pSenderSet); diff --git a/sw/source/ui/envelp/envlop1.cxx b/sw/source/ui/envelp/envlop1.cxx index 19a9b1e5d33d..0f61aaba3b83 100644 --- a/sw/source/ui/envelp/envlop1.cxx +++ b/sw/source/ui/envelp/envlop1.cxx @@ -73,8 +73,8 @@ void SwEnvPreview::Paint(vcl::RenderContext& rRenderContext, const tools::Rectan const SwEnvItem& rItem = static_cast<SwEnvDlg*>(GetParentDialog())->aEnvItem; - const long nPageW = std::max(rItem.lWidth, rItem.lHeight); - const long nPageH = std::min(rItem.lWidth, rItem.lHeight); + const long nPageW = std::max(rItem.m_nWidth, rItem.m_nHeight); + const long nPageH = std::min(rItem.m_nWidth, rItem.m_nHeight); const double f = 0.8 * std::min( double(GetOutputSizePixel().Width()) / double(nPageW), @@ -97,22 +97,22 @@ void SwEnvPreview::Paint(vcl::RenderContext& rRenderContext, const tools::Rectan rRenderContext.DrawRect(tools::Rectangle(Point(nX, nY), Size(nW, nH))); // Sender - if (rItem.bSend) + if (rItem.m_bSend) { - const long nSendX = nX + static_cast<long>(f * rItem.lSendFromLeft); - const long nSendY = nY + static_cast<long>(f * rItem.lSendFromTop ); - const long nSendW = static_cast<long>(f * (rItem.lAddrFromLeft - rItem.lSendFromLeft)); - const long nSendH = static_cast<long>(f * (rItem.lAddrFromTop - rItem.lSendFromTop - 566)); + const long nSendX = nX + static_cast<long>(f * rItem.m_nSendFromLeft); + const long nSendY = nY + static_cast<long>(f * rItem.m_nSendFromTop ); + const long nSendW = static_cast<long>(f * (rItem.m_nAddrFromLeft - rItem.m_nSendFromLeft)); + const long nSendH = static_cast<long>(f * (rItem.m_nAddrFromTop - rItem.m_nSendFromTop - 566)); rRenderContext.SetFillColor(aMedium); rRenderContext.DrawRect(tools::Rectangle(Point(nSendX, nSendY), Size(nSendW, nSendH))); } // Addressee - const long nAddrX = nX + static_cast<long>(f * rItem.lAddrFromLeft); - const long nAddrY = nY + static_cast<long>(f * rItem.lAddrFromTop ); - const long nAddrW = static_cast<long>(f * (nPageW - rItem.lAddrFromLeft - 566)); - const long nAddrH = static_cast<long>(f * (nPageH - rItem.lAddrFromTop - 566)); + const long nAddrX = nX + static_cast<long>(f * rItem.m_nAddrFromLeft); + const long nAddrY = nY + static_cast<long>(f * rItem.m_nAddrFromTop ); + const long nAddrW = static_cast<long>(f * (nPageW - rItem.m_nAddrFromLeft - 566)); + const long nAddrH = static_cast<long>(f * (nPageH - rItem.m_nAddrFromTop - 566)); rRenderContext.SetFillColor(aMedium); rRenderContext.DrawRect(tools::Rectangle(Point(nAddrX, nAddrY), Size(nAddrW, nAddrH))); @@ -281,7 +281,7 @@ IMPL_LINK_NOARG(SwEnvPage, FieldHdl, Button*, void) IMPL_LINK_NOARG(SwEnvPage, SenderHdl, Button*, void) { const bool bEnable = m_pSenderBox->IsChecked(); - GetParentSwEnvDlg()->aEnvItem.bSend = bEnable; + GetParentSwEnvDlg()->aEnvItem.m_bSend = bEnable; m_pSenderEdit->Enable(bEnable); if ( bEnable ) { @@ -339,9 +339,9 @@ DeactivateRC SwEnvPage::DeactivatePage(SfxItemSet* _pSet) void SwEnvPage::FillItem(SwEnvItem& rItem) { - rItem.aAddrText = m_pAddrEdit->GetText(); - rItem.bSend = m_pSenderBox->IsChecked(); - rItem.aSendText = m_pSenderEdit->GetText(); + rItem.m_aAddrText = m_pAddrEdit->GetText(); + rItem.m_bSend = m_pSenderBox->IsChecked(); + rItem.m_aSendText = m_pSenderEdit->GetText(); } bool SwEnvPage::FillItemSet(SfxItemSet* rSet) @@ -354,9 +354,9 @@ bool SwEnvPage::FillItemSet(SfxItemSet* rSet) void SwEnvPage::Reset(const SfxItemSet* rSet) { SwEnvItem aItem = static_cast<const SwEnvItem&>( rSet->Get(FN_ENVELOP)); - m_pAddrEdit->SetText(convertLineEnd(aItem.aAddrText, GetSystemLineEnd())); - m_pSenderEdit->SetText(convertLineEnd(aItem.aSendText, GetSystemLineEnd())); - m_pSenderBox->Check (aItem.bSend); + m_pAddrEdit->SetText(convertLineEnd(aItem.m_aAddrText, GetSystemLineEnd())); + m_pSenderEdit->SetText(convertLineEnd(aItem.m_aSendText, GetSystemLineEnd())); + m_pSenderBox->Check (aItem.m_bSend); m_pSenderBox->GetClickHdl().Call(m_pSenderBox); } diff --git a/sw/source/ui/envelp/envprt.cxx b/sw/source/ui/envelp/envprt.cxx index 397e675f9f0f..9a410b6130bc 100644 --- a/sw/source/ui/envelp/envprt.cxx +++ b/sw/source/ui/envelp/envprt.cxx @@ -137,7 +137,7 @@ IMPL_LINK_NOARG(SwEnvPrtPage, AlignHdl, ToolBox *, void) { // GetCurItemId() == 0 is possible! const SwEnvItem& rItem = static_cast<const SwEnvItem&>( GetItemSet().Get(FN_ENVELOP) ); - m_pAlignBox->CheckItem(m_aIds[rItem.eAlign]); + m_pAlignBox->CheckItem(m_aIds[rItem.m_eAlign]); } } @@ -171,10 +171,10 @@ void SwEnvPrtPage::FillItem(SwEnvItem& rItem) } } - rItem.eAlign = (SwEnvAlign)nOrient; - rItem.bPrintFromAbove = m_pTopButton->IsChecked(); - rItem.lShiftRight = static_cast< sal_Int32 >(GetFieldVal(*m_pRightField)); - rItem.lShiftDown = static_cast< sal_Int32 >(GetFieldVal(*m_pDownField )); + rItem.m_eAlign = (SwEnvAlign)nOrient; + rItem.m_bPrintFromAbove = m_pTopButton->IsChecked(); + rItem.m_nShiftRight = static_cast< sal_Int32 >(GetFieldVal(*m_pRightField)); + rItem.m_nShiftDown = static_cast< sal_Int32 >(GetFieldVal(*m_pDownField )); } bool SwEnvPrtPage::FillItemSet(SfxItemSet* rSet) @@ -188,15 +188,15 @@ void SwEnvPrtPage::Reset(const SfxItemSet* rSet) { // Read item const SwEnvItem& rItem = static_cast<const SwEnvItem&>( rSet->Get(FN_ENVELOP) ); - m_pAlignBox->CheckItem(m_aIds[rItem.eAlign]); + m_pAlignBox->CheckItem(m_aIds[rItem.m_eAlign]); - if (rItem.bPrintFromAbove) + if (rItem.m_bPrintFromAbove) m_pTopButton->Check(); else m_pBottomButton->Check(); - SetFieldVal(*m_pRightField, rItem.lShiftRight); - SetFieldVal(*m_pDownField , rItem.lShiftDown ); + SetFieldVal(*m_pRightField, rItem.m_nShiftRight); + SetFieldVal(*m_pDownField , rItem.m_nShiftDown ); ActivatePage(*rSet); ClickHdl(m_pTopButton); diff --git a/sw/source/uibase/app/appenv.cxx b/sw/source/uibase/app/appenv.cxx index 447205517e6e..6fb3b0b6b126 100644 --- a/sw/source/uibase/app/appenv.cxx +++ b/sw/source/uibase/app/appenv.cxx @@ -350,13 +350,13 @@ void SwModule::InsertEnv( SfxRequest& rReq ) if ( aPaperSize.Width() > aPaperSize.Height() ) Swap( aPaperSize ); - long lLeft = rItem.lShiftRight, - lUpper = rItem.lShiftDown; + long lLeft = rItem.m_nShiftRight, + lUpper = rItem.m_nShiftDown; - sal_uInt16 nPageW = (sal_uInt16) std::max(rItem.lWidth, rItem.lHeight), - nPageH = (sal_uInt16) std::min(rItem.lWidth, rItem.lHeight); + sal_uInt16 nPageW = (sal_uInt16) std::max(rItem.m_nWidth, rItem.m_nHeight), + nPageH = (sal_uInt16) std::min(rItem.m_nWidth, rItem.m_nHeight); - switch (rItem.eAlign) + switch (rItem.m_eAlign) { case ENV_HOR_LEFT: break; case ENV_HOR_CNTR: lLeft += std::max(0L, long(aPaperSize.Width() - nPageW)) / 2; @@ -401,8 +401,8 @@ void SwModule::InsertEnv( SfxRequest& rReq ) pDesc->SetFollow(pFollow); // Landscape - pDesc->SetLandscape( rItem.eAlign >= ENV_VER_LEFT && - rItem.eAlign <= ENV_VER_RGHT); + pDesc->SetLandscape( rItem.m_eAlign >= ENV_VER_LEFT && + rItem.m_eAlign <= ENV_VER_RGHT); // Apply page description @@ -425,19 +425,19 @@ void SwModule::InsertEnv( SfxRequest& rReq ) aMgr.SetLRSpace( 0L, 0L ); // Sender - if (rItem.bSend) + if (rItem.m_bSend) { pSh->SttEndDoc(true); aMgr.InsertFlyFrame(RndStdIds::FLY_AT_PAGE, - Point(rItem.lSendFromLeft + lLeft, rItem.lSendFromTop + lUpper), - Size (rItem.lAddrFromLeft - rItem.lSendFromLeft, 0)); + Point(rItem.m_nSendFromLeft + lLeft, rItem.m_nSendFromTop + lUpper), + Size (rItem.m_nAddrFromLeft - rItem.m_nSendFromLeft, 0)); pSh->EnterSelFrameMode(); pSh->SetFlyName(sSendMark); pSh->UnSelectFrame(); pSh->LeaveSelFrameMode(); pSh->SetTextFormatColl( pSend ); - InsertLabEnvText( *pSh, aFieldMgr, rItem.aSendText ); + InsertLabEnvText( *pSh, aFieldMgr, rItem.m_aSendText ); aMgr.UpdateAttrMgr(); } @@ -445,14 +445,14 @@ void SwModule::InsertEnv( SfxRequest& rReq ) pSh->SttEndDoc(true); aMgr.InsertFlyFrame(RndStdIds::FLY_AT_PAGE, - Point(rItem.lAddrFromLeft + lLeft, rItem.lAddrFromTop + lUpper), - Size (nPageW - rItem.lAddrFromLeft - 566, 0)); + Point(rItem.m_nAddrFromLeft + lLeft, rItem.m_nAddrFromTop + lUpper), + Size (nPageW - rItem.m_nAddrFromLeft - 566, 0)); pSh->EnterSelFrameMode(); pSh->SetFlyName(sAddrMark); pSh->UnSelectFrame(); pSh->LeaveSelFrameMode(); pSh->SetTextFormatColl( pAddr ); - InsertLabEnvText(*pSh, aFieldMgr, rItem.aAddrText); + InsertLabEnvText(*pSh, aFieldMgr, rItem.m_aAddrText); // Move Flys to the "old" pages if (!aFlyArr.empty()) @@ -472,7 +472,7 @@ void SwModule::InsertEnv( SfxRequest& rReq ) { pFrame->GetFrame().Appear(); - if ( rItem.aAddrText.indexOf('<') >= 0 ) + if ( rItem.m_aAddrText.indexOf('<') >= 0 ) { static sal_uInt16 const aInva[] = { diff --git a/sw/source/uibase/envelp/envimg.cxx b/sw/source/uibase/envelp/envimg.cxx index 8e4b46113e32..aa6c03d2ae7a 100644 --- a/sw/source/uibase/envelp/envimg.cxx +++ b/sw/source/uibase/envelp/envimg.cxx @@ -93,38 +93,38 @@ OUString MakeSender() SwEnvItem::SwEnvItem() : SfxPoolItem(FN_ENVELOP) { - aAddrText = aEmptyOUStr; - bSend = true; - aSendText = MakeSender(); - lSendFromLeft = 566; // 1 cm - lSendFromTop = 566; // 1 cm + m_aAddrText = aEmptyOUStr; + m_bSend = true; + m_aSendText = MakeSender(); + m_nSendFromLeft = 566; // 1 cm + m_nSendFromTop = 566; // 1 cm Size aEnvSz = SvxPaperInfo::GetPaperSize(PAPER_ENV_C65); - lWidth = aEnvSz.Width(); - lHeight = aEnvSz.Height(); - eAlign = ENV_HOR_LEFT; - bPrintFromAbove = true; - lShiftRight = 0; - lShiftDown = 0; + m_nWidth = aEnvSz.Width(); + m_nHeight = aEnvSz.Height(); + m_eAlign = ENV_HOR_LEFT; + m_bPrintFromAbove = true; + m_nShiftRight = 0; + m_nShiftDown = 0; - lAddrFromLeft = std::max(lWidth, lHeight) / 2; - lAddrFromTop = std::min(lWidth, lHeight) / 2; + m_nAddrFromLeft = std::max(m_nWidth, m_nHeight) / 2; + m_nAddrFromTop = std::min(m_nWidth, m_nHeight) / 2; } SwEnvItem& SwEnvItem::operator =(const SwEnvItem& rItem) { - aAddrText = rItem.aAddrText; - bSend = rItem.bSend; - aSendText = rItem.aSendText; - lSendFromLeft = rItem.lSendFromLeft; - lSendFromTop = rItem.lSendFromTop; - lAddrFromLeft = rItem.lAddrFromLeft; - lAddrFromTop = rItem.lAddrFromTop; - lWidth = rItem.lWidth; - lHeight = rItem.lHeight; - eAlign = rItem.eAlign; - bPrintFromAbove = rItem.bPrintFromAbove; - lShiftRight = rItem.lShiftRight; - lShiftDown = rItem.lShiftDown; + m_aAddrText = rItem.m_aAddrText; + m_bSend = rItem.m_bSend; + m_aSendText = rItem.m_aSendText; + m_nSendFromLeft = rItem.m_nSendFromLeft; + m_nSendFromTop = rItem.m_nSendFromTop; + m_nAddrFromLeft = rItem.m_nAddrFromLeft; + m_nAddrFromTop = rItem.m_nAddrFromTop; + m_nWidth = rItem.m_nWidth; + m_nHeight = rItem.m_nHeight; + m_eAlign = rItem.m_eAlign; + m_bPrintFromAbove = rItem.m_bPrintFromAbove; + m_nShiftRight = rItem.m_nShiftRight; + m_nShiftDown = rItem.m_nShiftDown; return *this; } @@ -132,19 +132,19 @@ bool SwEnvItem::operator ==(const SfxPoolItem& rItem) const { const SwEnvItem& rEnv = static_cast<const SwEnvItem&>( rItem); - return aAddrText == rEnv.aAddrText && - bSend == rEnv.bSend && - aSendText == rEnv.aSendText && - lSendFromLeft == rEnv.lSendFromLeft && - lSendFromTop == rEnv.lSendFromTop && - lAddrFromLeft == rEnv.lAddrFromLeft && - lAddrFromTop == rEnv.lAddrFromTop && - lWidth == rEnv.lWidth && - lHeight == rEnv.lHeight && - eAlign == rEnv.eAlign && - bPrintFromAbove == rEnv.bPrintFromAbove && - lShiftRight == rEnv.lShiftRight && - lShiftDown == rEnv.lShiftDown; + return m_aAddrText == rEnv.m_aAddrText && + m_bSend == rEnv.m_bSend && + m_aSendText == rEnv.m_aSendText && + m_nSendFromLeft == rEnv.m_nSendFromLeft && + m_nSendFromTop == rEnv.m_nSendFromTop && + m_nAddrFromLeft == rEnv.m_nAddrFromLeft && + m_nAddrFromTop == rEnv.m_nAddrFromTop && + m_nWidth == rEnv.m_nWidth && + m_nHeight == rEnv.m_nHeight && + m_eAlign == rEnv.m_eAlign && + m_bPrintFromAbove == rEnv.m_bPrintFromAbove && + m_nShiftRight == rEnv.m_nShiftRight && + m_nShiftDown == rEnv.m_nShiftDown; } SfxPoolItem* SwEnvItem::Clone(SfxItemPool*) const @@ -168,46 +168,46 @@ SwEnvCfgItem::SwEnvCfgItem() : { switch(nProp) { - case 0: pValues[nProp] >>= aEnvItem.aAddrText; break;// "Inscription/Addressee", - case 1: pValues[nProp] >>= aEnvItem.aSendText; break;// "Inscription/Sender", - case 2: aEnvItem.bSend = *o3tl::doAccess<bool>(pValues[nProp]); break;// "Inscription/UseSender", + case 0: pValues[nProp] >>= aEnvItem.m_aAddrText; break;// "Inscription/Addressee", + case 1: pValues[nProp] >>= aEnvItem.m_aSendText; break;// "Inscription/Sender", + case 2: aEnvItem.m_bSend = *o3tl::doAccess<bool>(pValues[nProp]); break;// "Inscription/UseSender", case 3: - pValues[nProp] >>= aEnvItem.lAddrFromLeft;// "Format/AddresseeFromLeft", - aEnvItem.lAddrFromLeft = convertMm100ToTwip(aEnvItem.lAddrFromLeft); + pValues[nProp] >>= aEnvItem.m_nAddrFromLeft;// "Format/AddresseeFromLeft", + aEnvItem.m_nAddrFromLeft = convertMm100ToTwip(aEnvItem.m_nAddrFromLeft); break; case 4: - pValues[nProp] >>= aEnvItem.lAddrFromTop; // "Format/AddresseeFromTop", - aEnvItem.lAddrFromTop = convertMm100ToTwip(aEnvItem.lAddrFromTop); + pValues[nProp] >>= aEnvItem.m_nAddrFromTop; // "Format/AddresseeFromTop", + aEnvItem.m_nAddrFromTop = convertMm100ToTwip(aEnvItem.m_nAddrFromTop); break; case 5: - pValues[nProp] >>= aEnvItem.lSendFromLeft; // "Format/SenderFromLeft", - aEnvItem.lSendFromLeft = convertMm100ToTwip(aEnvItem.lSendFromLeft); + pValues[nProp] >>= aEnvItem.m_nSendFromLeft; // "Format/SenderFromLeft", + aEnvItem.m_nSendFromLeft = convertMm100ToTwip(aEnvItem.m_nSendFromLeft); break; case 6: - pValues[nProp] >>= aEnvItem.lSendFromTop;// "Format/SenderFromTop", - aEnvItem.lSendFromTop = convertMm100ToTwip(aEnvItem.lSendFromTop); + pValues[nProp] >>= aEnvItem.m_nSendFromTop;// "Format/SenderFromTop", + aEnvItem.m_nSendFromTop = convertMm100ToTwip(aEnvItem.m_nSendFromTop); break; case 7: - pValues[nProp] >>= aEnvItem.lWidth; // "Format/Width", - aEnvItem.lWidth = convertMm100ToTwip(aEnvItem.lWidth); + pValues[nProp] >>= aEnvItem.m_nWidth; // "Format/Width", + aEnvItem.m_nWidth = convertMm100ToTwip(aEnvItem.m_nWidth); break; case 8: - pValues[nProp] >>= aEnvItem.lHeight; // "Format/Height", - aEnvItem.lHeight = convertMm100ToTwip(aEnvItem.lHeight); + pValues[nProp] >>= aEnvItem.m_nHeight; // "Format/Height", + aEnvItem.m_nHeight = convertMm100ToTwip(aEnvItem.m_nHeight); break; case 9: { sal_Int32 nTemp = 0; - pValues[nProp] >>= nTemp; aEnvItem.eAlign = (SwEnvAlign)nTemp; break;// "Print/Alignment", + pValues[nProp] >>= nTemp; aEnvItem.m_eAlign = (SwEnvAlign)nTemp; break;// "Print/Alignment", } - case 10: aEnvItem.bPrintFromAbove = *o3tl::doAccess<bool>(pValues[nProp]); break;// "Print/FromAbove", + case 10: aEnvItem.m_bPrintFromAbove = *o3tl::doAccess<bool>(pValues[nProp]); break;// "Print/FromAbove", case 11: - pValues[nProp] >>= aEnvItem.lShiftRight; - aEnvItem.lShiftRight = convertMm100ToTwip(aEnvItem.lShiftRight);// "Print/Right", + pValues[nProp] >>= aEnvItem.m_nShiftRight; + aEnvItem.m_nShiftRight = convertMm100ToTwip(aEnvItem.m_nShiftRight);// "Print/Right", break; case 12: - pValues[nProp] >>= aEnvItem.lShiftDown; - aEnvItem.lShiftDown = convertMm100ToTwip(aEnvItem.lShiftDown); + pValues[nProp] >>= aEnvItem.m_nShiftDown; + aEnvItem.m_nShiftDown = convertMm100ToTwip(aEnvItem.m_nShiftDown); break;// "Print/Down" } } @@ -229,19 +229,19 @@ void SwEnvCfgItem::ImplCommit() { switch(nProp) { - case 0: pValues[nProp] <<= aEnvItem.aAddrText; break;// "Inscription/Addressee", - case 1: pValues[nProp] <<= aEnvItem.aSendText; break;// "Inscription/Sender", - case 2: pValues[nProp] <<= aEnvItem.bSend; break;// "Inscription/UseSender", - case 3: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lAddrFromLeft)) ; break;// "Format/AddresseeFromLeft", - case 4: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lAddrFromTop)) ; break;// "Format/AddresseeFromTop", - case 5: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lSendFromLeft)) ; break;// "Format/SenderFromLeft", - case 6: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lSendFromTop)) ; break;// "Format/SenderFromTop", - case 7: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lWidth)) ; break;// "Format/Width", - case 8: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lHeight)) ; break;// "Format/Height", - case 9: pValues[nProp] <<= sal_Int32(aEnvItem.eAlign); break;// "Print/Alignment", - case 10: pValues[nProp] <<= aEnvItem.bPrintFromAbove; break;// "Print/FromAbove", - case 11: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lShiftRight));break; // "Print/Right", - case 12: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.lShiftDown)); break;// "Print/Down" + case 0: pValues[nProp] <<= aEnvItem.m_aAddrText; break;// "Inscription/Addressee", + case 1: pValues[nProp] <<= aEnvItem.m_aSendText; break;// "Inscription/Sender", + case 2: pValues[nProp] <<= aEnvItem.m_bSend; break;// "Inscription/UseSender", + case 3: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nAddrFromLeft)) ; break;// "Format/AddresseeFromLeft", + case 4: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nAddrFromTop)) ; break;// "Format/AddresseeFromTop", + case 5: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nSendFromLeft)) ; break;// "Format/SenderFromLeft", + case 6: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nSendFromTop)) ; break;// "Format/SenderFromTop", + case 7: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nWidth)) ; break;// "Format/Width", + case 8: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nHeight)) ; break;// "Format/Height", + case 9: pValues[nProp] <<= sal_Int32(aEnvItem.m_eAlign); break;// "Print/Alignment", + case 10: pValues[nProp] <<= aEnvItem.m_bPrintFromAbove; break;// "Print/FromAbove", + case 11: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nShiftRight));break; // "Print/Right", + case 12: pValues[nProp] <<= static_cast <sal_Int32>(convertTwipToMm100(aEnvItem.m_nShiftDown)); break;// "Print/Down" } } PutProperties(aNames, aValues); @@ -282,19 +282,19 @@ bool SwEnvItem::QueryValue( Any& rVal, sal_uInt8 nMemberId ) const bool bRet = true; switch(nMemberId & ~CONVERT_TWIPS) { - case MID_ENV_ADDR_TEXT : rVal <<= aAddrText; break; - case MID_ENV_SEND : rVal <<= bSend; break; - case MID_SEND_TEXT : rVal <<= aSendText; break; - case MID_ENV_ADDR_FROM_LEFT : rVal <<= lAddrFromLeft; break; - case MID_ENV_ADDR_FROM_TOP : rVal <<= lAddrFromTop; break; - case MID_ENV_SEND_FROM_LEFT : rVal <<= lSendFromLeft; break; - case MID_ENV_SEND_FROM_TOP : rVal <<= lSendFromTop; break; - case MID_ENV_WIDTH : rVal <<= lWidth; break; - case MID_ENV_HEIGHT : rVal <<= lHeight; break; - case MID_ENV_ALIGN : rVal <<= (sal_Int16) eAlign; break; - case MID_ENV_PRINT_FROM_ABOVE : rVal <<= bPrintFromAbove; break; - case MID_ENV_SHIFT_RIGHT : rVal <<= lShiftRight; break; - case MID_ENV_SHIFT_DOWN : rVal <<= lShiftDown; break; + case MID_ENV_ADDR_TEXT : rVal <<= m_aAddrText; break; + case MID_ENV_SEND : rVal <<= m_bSend; break; + case MID_SEND_TEXT : rVal <<= m_aSendText; break; + case MID_ENV_ADDR_FROM_LEFT : rVal <<= m_nAddrFromLeft; break; + case MID_ENV_ADDR_FROM_TOP : rVal <<= m_nAddrFromTop; break; + case MID_ENV_SEND_FROM_LEFT : rVal <<= m_nSendFromLeft; break; + case MID_ENV_SEND_FROM_TOP : rVal <<= m_nSendFromTop; break; + case MID_ENV_WIDTH : rVal <<= m_nWidth; break; + case MID_ENV_HEIGHT : rVal <<= m_nHeight; break; + case MID_ENV_ALIGN : rVal <<= (sal_Int16) m_eAlign; break; + case MID_ENV_PRINT_FROM_ABOVE : rVal <<= m_bPrintFromAbove; break; + case MID_ENV_SHIFT_RIGHT : rVal <<= m_nShiftRight; break; + case MID_ENV_SHIFT_DOWN : rVal <<= m_nShiftDown; break; default: OSL_FAIL("Wrong memberId"); bRet = false; @@ -307,26 +307,26 @@ bool SwEnvItem::PutValue(const Any& rVal, sal_uInt8 nMemberId) bool bRet = false; switch(nMemberId & ~CONVERT_TWIPS) { - case MID_ENV_ADDR_TEXT : bRet = (rVal >>= aAddrText); break; - case MID_ENV_SEND : bRet = (rVal >>= bSend); break; - case MID_SEND_TEXT : bRet = (rVal >>= aSendText); break; - case MID_ENV_ADDR_FROM_LEFT : bRet = (rVal >>= lAddrFromLeft); break; - case MID_ENV_ADDR_FROM_TOP : bRet = (rVal >>= lAddrFromTop); break; - case MID_ENV_SEND_FROM_LEFT : bRet = (rVal >>= lSendFromLeft); break; - case MID_ENV_SEND_FROM_TOP : bRet = (rVal >>= lSendFromTop); break; - case MID_ENV_WIDTH : bRet = (rVal >>= lWidth); break; - case MID_ENV_HEIGHT : bRet = (rVal >>= lHeight); break; + case MID_ENV_ADDR_TEXT : bRet = (rVal >>= m_aAddrText); break; + case MID_ENV_SEND : bRet = (rVal >>= m_bSend); break; + case MID_SEND_TEXT : bRet = (rVal >>= m_aSendText); break; + case MID_ENV_ADDR_FROM_LEFT : bRet = (rVal >>= m_nAddrFromLeft); break; + case MID_ENV_ADDR_FROM_TOP : bRet = (rVal >>= m_nAddrFromTop); break; + case MID_ENV_SEND_FROM_LEFT : bRet = (rVal >>= m_nSendFromLeft); break; + case MID_ENV_SEND_FROM_TOP : bRet = (rVal >>= m_nSendFromTop); break; + case MID_ENV_WIDTH : bRet = (rVal >>= m_nWidth); break; + case MID_ENV_HEIGHT : bRet = (rVal >>= m_nHeight); break; case MID_ENV_ALIGN : { sal_Int16 nTemp = 0; bRet = (rVal >>= nTemp); if (bRet) - eAlign = SwEnvAlign(nTemp); + m_eAlign = SwEnvAlign(nTemp); break; } - case MID_ENV_PRINT_FROM_ABOVE : bRet = (rVal >>= bPrintFromAbove); break; - case MID_ENV_SHIFT_RIGHT : bRet = (rVal >>= lShiftRight); break; - case MID_ENV_SHIFT_DOWN : bRet = (rVal >>= lShiftDown); break; + case MID_ENV_PRINT_FROM_ABOVE : bRet = (rVal >>= m_bPrintFromAbove); break; + case MID_ENV_SHIFT_RIGHT : bRet = (rVal >>= m_nShiftRight); break; + case MID_ENV_SHIFT_DOWN : bRet = (rVal >>= m_nShiftDown); break; default: OSL_FAIL("Wrong memberId"); } diff --git a/sw/source/uibase/inc/envimg.hxx b/sw/source/uibase/inc/envimg.hxx index 7806119adb45..6293e104144f 100644 --- a/sw/source/uibase/inc/envimg.hxx +++ b/sw/source/uibase/inc/envimg.hxx @@ -39,19 +39,19 @@ class SW_DLLPUBLIC SwEnvItem : public SfxPoolItem { public: - OUString aAddrText; // text for receiver - bool bSend; // sender? - OUString aSendText; // text for sender - sal_Int32 lAddrFromLeft; // left gap for receiver (twips) - sal_Int32 lAddrFromTop; // upper gap for receiver (twips) - sal_Int32 lSendFromLeft; // left gap for sender (twips) - sal_Int32 lSendFromTop; // upper gap for sender (twips) - sal_Int32 lWidth; // envelope's width (twips) - sal_Int32 lHeight; // envelope's height (twips) - SwEnvAlign eAlign; // alignment at indent - bool bPrintFromAbove; // print from above? - sal_Int32 lShiftRight; // shift to right (twips) - sal_Int32 lShiftDown; // shift down (twips) + OUString m_aAddrText; // text for receiver + bool m_bSend; // sender? + OUString m_aSendText; // text for sender + sal_Int32 m_nAddrFromLeft; // left gap for receiver (twips) + sal_Int32 m_nAddrFromTop; // upper gap for receiver (twips) + sal_Int32 m_nSendFromLeft; // left gap for sender (twips) + sal_Int32 m_nSendFromTop; // upper gap for sender (twips) + sal_Int32 m_nWidth; // envelope's width (twips) + sal_Int32 m_nHeight; // envelope's height (twips) + SwEnvAlign m_eAlign; // alignment at indent + bool m_bPrintFromAbove; // print from above? + sal_Int32 m_nShiftRight; // shift to right (twips) + sal_Int32 m_nShiftDown; // shift down (twips) SwEnvItem(); |