diff options
author | Ivo Hinkelmann <ihi@openoffice.org> | 2009-06-12 09:36:34 +0000 |
---|---|---|
committer | Ivo Hinkelmann <ihi@openoffice.org> | 2009-06-12 09:36:34 +0000 |
commit | 1d7964c5ff579ff93067dc1c3e45b522e3cb2b4e (patch) | |
tree | b2454b11151382642ef2a24c80fb1a47b45b8bc6 /sw/source/ui/envelp | |
parent | 2e11a6b039a798150dc59a6c43d73cb0d27c0ab5 (diff) |
CWS-TOOLING: integrate CWS unifypaper01
2009-05-27 17:14:41 +0200 cmc r272362 : #i92819#, psprint moved into vcl
2009-05-19 15:45:46 +0200 cmc r272083 : #i92819# having difficultly in getting this right under windows
2009-05-18 18:04:22 +0200 cmc r272043 : #i92819# missing some export magic somewhere
2009-05-18 15:34:18 +0200 cmc r272028 : #i92819# get depends right
2009-05-18 11:50:43 +0200 cmc r272010 : ##i92819# fix import/export stuff
2009-05-18 10:07:00 +0200 cmc r272000 : #i92819# fix window imp name
2009-05-16 15:17:23 +0200 cmc r271975 : #i92819# fix win paper names
2009-05-16 11:11:29 +0200 cmc r271974 : #i92819# std::abs prolematic for msvc
2009-05-15 15:36:56 +0200 cmc r271941 : #i92819# handle missing setting, at least on mac
2009-05-15 10:13:44 +0200 cmc r271927 : #i92819# adjust for moved page dialog
2009-05-14 13:47:14 +0200 cmc r271887 : remove dead files that reappeared
2009-05-14 09:57:17 +0200 cmc r271872 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@271830 (milestone: DEV300:m48)
2009-05-11 12:27:18 +0200 cmc r271763 : #i92819# check return value
2009-05-06 17:28:25 +0200 cmc r271602 : #i92819# these B4/B5s are the JIS ones according to their dimensions
2009-05-06 17:17:03 +0200 cmc r271601 : #i92819# micro-optimization
2009-05-03 18:20:48 +0200 cmc r271434 : #i92819# paper libs
2009-05-03 16:08:32 +0200 cmc r271433 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@271427 (milestone: DEV300:m47)
2009-04-06 15:33:37 +0200 cmc r270556 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@270033 (milestone: DEV300:m45)
2009-03-12 14:36:35 +0100 cmc r269415 : #i92819# merge paper utilities
2009-03-11 13:44:27 +0100 cmc r269328 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@269297 (milestone: DEV300:m43)
2009-03-09 14:42:07 +0100 cmc r269190 : remove config_office from synced version
2009-03-09 14:34:50 +0100 cmc r269187 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@268395 (milestone: DEV300:m42)
2009-03-09 12:11:29 +0100 cmc r269077 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@265758 (milestone: DEV300:m38)
2009-03-06 17:17:39 +0100 cmc r269027 : #i92819# paper goo
2008-12-04 11:29:30 +0100 cmc r264826 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@264807 (milestone: DEV300:m37)
2008-11-26 10:33:06 +0100 cmc r264357 : CWS-TOOLING: rebase CWS unifypaper01 to trunk@264325 (milestone: DEV300:m36)
2008-11-21 14:09:36 +0100 cmc r264138 : #i92819# paper consolidation
Diffstat (limited to 'sw/source/ui/envelp')
-rw-r--r-- | sw/source/ui/envelp/envfmt.cxx | 26 | ||||
-rw-r--r-- | sw/source/ui/envelp/envimg.cxx | 5 |
2 files changed, 16 insertions, 15 deletions
diff --git a/sw/source/ui/envelp/envfmt.cxx b/sw/source/ui/envelp/envfmt.cxx index 51c9018315ee..f6fb3f596a35 100644 --- a/sw/source/ui/envelp/envfmt.cxx +++ b/sw/source/ui/envelp/envfmt.cxx @@ -179,11 +179,11 @@ SwEnvFmtPage::SwEnvFmtPage(Window* pParent, const SfxItemSet& rSet) : aSizeFormatBox .SetSelectHdl(LINK(this, SwEnvFmtPage, FormatHdl)); // aSizeFormatBox - for (USHORT i = SVX_PAPER_A3; i <= SVX_PAPER_KAI32BIG; i++) + for (USHORT i = PAPER_A3; i <= PAPER_KAI32BIG; i++) { - if (i != SVX_PAPER_USER) + if (i != PAPER_USER) { - String aPaperName = SvxPaperInfo::GetName((SvxPaper) i), + String aPaperName = SvxPaperInfo::GetName((Paper) i), aEntryName; USHORT nPos = 0; @@ -200,8 +200,8 @@ SwEnvFmtPage::SwEnvFmtPage(Window* pParent, const SfxItemSet& rSet) : aIDs.Insert((USHORT) i, nPos); } } - aSizeFormatBox.InsertEntry(SvxPaperInfo::GetName(SVX_PAPER_USER)); - aIDs.Insert((USHORT) SVX_PAPER_USER, aIDs.Count()); + aSizeFormatBox.InsertEntry(SvxPaperInfo::GetName(PAPER_USER)); + aIDs.Insert((USHORT) PAPER_USER, aIDs.Count()); } @@ -228,14 +228,14 @@ IMPL_LINK_INLINE_START( SwEnvFmtPage, ModifyHdl, Edit *, pEdit ) if (pEdit == &aSizeWidthField || pEdit == &aSizeHeightField) { - SvxPaper ePaper = SvxPaperInfo::GetPaper( + Paper ePaper = SvxPaperInfo::GetSvxPaper( Size(lHeight, lWidth), MAP_TWIP, TRUE); for (USHORT i = 0; i < aIDs.Count(); i++) if (aIDs[i] == (USHORT)ePaper) aSizeFormatBox.SelectEntryPos(i); // Benutzergroesse merken - if (aIDs[aSizeFormatBox.GetSelectEntryPos()] == (USHORT)SVX_PAPER_USER) + if (aIDs[aSizeFormatBox.GetSelectEntryPos()] == (USHORT)PAPER_USER) { lUserW = lWidth ; lUserH = lHeight; @@ -470,9 +470,9 @@ IMPL_LINK( SwEnvFmtPage, FormatHdl, ListBox *, EMPTYARG ) long lAddrFromTop; USHORT nPaper = aIDs[aSizeFormatBox.GetSelectEntryPos()]; - if (nPaper != (USHORT)SVX_PAPER_USER) + if (nPaper != (USHORT)PAPER_USER) { - Size aSz = SvxPaperInfo::GetPaperSize((SvxPaper)nPaper); + Size aSz = SvxPaperInfo::GetPaperSize((Paper)nPaper); lWidth = Max(aSz.Width(), aSz.Height()); lHeight = Min(aSz.Width(), aSz.Height()); } @@ -581,7 +581,7 @@ void SwEnvFmtPage::FillItem(SwEnvItem& rItem) rItem.lSendFromTop = static_cast< sal_Int32 >(GetFldVal(aSendTopField )); USHORT nPaper = aIDs[aSizeFormatBox.GetSelectEntryPos()]; - if (nPaper == (USHORT)SVX_PAPER_USER) + if (nPaper == (USHORT)PAPER_USER) { long lWVal = static_cast< long >(GetFldVal(aSizeWidthField )); long lHVal = static_cast< long >(GetFldVal(aSizeHeightField)); @@ -590,8 +590,8 @@ void SwEnvFmtPage::FillItem(SwEnvItem& rItem) } else { - long lWVal = SvxPaperInfo::GetPaperSize((SvxPaper)nPaper).Width (); - long lHVal = SvxPaperInfo::GetPaperSize((SvxPaper)nPaper).Height(); + long lWVal = SvxPaperInfo::GetPaperSize((Paper)nPaper).Width (); + long lHVal = SvxPaperInfo::GetPaperSize((Paper)nPaper).Height(); rItem.lWidth = Max(lWVal, lHVal); rItem.lHeight = Min(lWVal, lHVal); } @@ -614,7 +614,7 @@ void __EXPORT SwEnvFmtPage::Reset(const SfxItemSet& rSet) { const SwEnvItem& rItem = (const SwEnvItem&) rSet.Get(FN_ENVELOP); - SvxPaper ePaper = SvxPaperInfo::GetPaper( + Paper ePaper = SvxPaperInfo::GetSvxPaper( Size( Min(rItem.lWidth, rItem.lHeight), Max(rItem.lWidth, rItem.lHeight)), MAP_TWIP, TRUE); for (USHORT i = 0; i < (USHORT) aIDs.Count(); i++) diff --git a/sw/source/ui/envelp/envimg.cxx b/sw/source/ui/envelp/envimg.cxx index aada68947ceb..fa1744ca1ae5 100644 --- a/sw/source/ui/envelp/envimg.cxx +++ b/sw/source/ui/envelp/envimg.cxx @@ -119,8 +119,9 @@ SwEnvItem::SwEnvItem() : aSendText = MakeSender(); lSendFromLeft = 566; // 1 cm lSendFromTop = 566; // 1 cm - lWidth = lC65Width; - lHeight = lC65Height; + Size aEnvSz = SvxPaperInfo::GetPaperSize(PAPER_ENV_C65); + lWidth = aEnvSz.Width(); + lHeight = aEnvSz.Height(); eAlign = ENV_HOR_LEFT; bPrintFromAbove = TRUE; lShiftRight = 0; |