diff options
author | Oliver Specht <os@openoffice.org> | 2002-06-26 09:31:06 +0000 |
---|---|---|
committer | Oliver Specht <os@openoffice.org> | 2002-06-26 09:31:06 +0000 |
commit | a8f361754e34101ffefbdd67ca747d20ceaab00c (patch) | |
tree | df2d769c9531f4ca3363851a44cb3033927ea62a /sw/source/ui/frmdlg | |
parent | 6b7ee6c9703f95ae399069831da9dea4203add5a (diff) |
#96980# enable relative width up to 254
Diffstat (limited to 'sw/source/ui/frmdlg')
-rw-r--r-- | sw/source/ui/frmdlg/frmpage.cxx | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/sw/source/ui/frmdlg/frmpage.cxx b/sw/source/ui/frmdlg/frmpage.cxx index dfeb0fb5c9ad..d017bf41d1e4 100644 --- a/sw/source/ui/frmdlg/frmpage.cxx +++ b/sw/source/ui/frmdlg/frmpage.cxx @@ -2,9 +2,9 @@ * * $RCSfile: frmpage.cxx,v $ * - * $Revision: 1.19 $ + * $Revision: 1.20 $ * - * last change: $Author: os $ $Date: 2002-05-03 15:54:56 $ + * last change: $Author: os $ $Date: 2002-06-26 10:31:06 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -214,6 +214,7 @@ struct RelationMap ULONG nLBRelation; USHORT nRelation; }; +#define MAX_PERCENT_WIDTH 254L #define LB_FRAME 0x00000001L // Textbereich des Absatzes #define LB_PRTAREA 0x00000002L // Textbereich des Absatzes + Einzuege @@ -919,7 +920,7 @@ BOOL SwFrmPage::FillItemSet(SfxItemSet &rSet) if (aRelWidthCB.IsChecked()) { - aSz.SetWidthPercent((BYTE)Min(100L, aWidthED.Convert(aWidthED.Normalize(nNewWidth), FUNIT_TWIP, FUNIT_CUSTOM))); + aSz.SetWidthPercent((BYTE)Min(MAX_PERCENT_WIDTH, aWidthED.Convert(aWidthED.Normalize(nNewWidth), FUNIT_TWIP, FUNIT_CUSTOM))); } else aSz.SetWidthPercent(0); @@ -1438,7 +1439,10 @@ IMPL_LINK( SwFrmPage, MirrorHdl, CheckBox *, pBtn ) IMPL_LINK( SwFrmPage, RelSizeClickHdl, CheckBox *, pBtn ) { if (pBtn == &aRelWidthCB) + { aWidthED.ShowPercent(pBtn->IsChecked()); + aWidthED.MetricField::SetMax(MAX_PERCENT_WIDTH); + } else aHeightED.ShowPercent(pBtn->IsChecked()); |