diff options
author | Thomas Lange [tl] <tl@openoffice.org> | 2010-09-02 11:59:37 +0200 |
---|---|---|
committer | Thomas Lange [tl] <tl@openoffice.org> | 2010-09-02 11:59:37 +0200 |
commit | 39a07e2c39b4cc2f8aca23c8e3ae90df8088e0c6 (patch) | |
tree | e29923586844dc83ef9e03b9b8865b87ce38a958 | |
parent | 130109b6ac401601890add1416801b6f2f248552 (diff) |
cws tl82: #i114267# remove unused code
-rwxr-xr-x[-rw-r--r--] | sw/source/ui/uiview/pview.cxx | 488 | ||||
-rwxr-xr-x[-rw-r--r--] | sw/source/ui/uiview/pview.src | 293 | ||||
-rwxr-xr-x[-rw-r--r--] | sw/source/ui/uiview/view.hrc | 1 |
3 files changed, 1 insertions, 781 deletions
diff --git a/sw/source/ui/uiview/pview.cxx b/sw/source/ui/uiview/pview.cxx index d499add5ad53..ca109fc5e950 100644..100755 --- a/sw/source/ui/uiview/pview.cxx +++ b/sw/source/ui/uiview/pview.cxx @@ -217,8 +217,7 @@ SwPreViewZoomDlg::SwPreViewZoomDlg( SwPagePreViewWin& rParent ) : Beschreibung: --------------------------------------------------------------------*/ - - SwPreViewZoomDlg::~SwPreViewZoomDlg() {} +SwPreViewZoomDlg::~SwPreViewZoomDlg() {} void SwPreViewZoomDlg::Apply() @@ -228,491 +227,6 @@ void SwPreViewZoomDlg::Apply() BYTE(aColEdit.GetValue()) ); } -/* */ -/* -----------------20.08.98 15:25------------------- - * Vorschau fuer den Seitendruck - * --------------------------------------------------*/ -struct PrintSettingsStruct; -class PrtPrvWindow : public Window -{ - const PrintSettingsStruct& rSettings; - - virtual void Paint(const Rectangle&); -public : - PrtPrvWindow(Window* pParent, const ResId& rResId, const PrintSettingsStruct& rSett) : - Window(pParent, rResId), rSettings(rSett){} -}; -/*-------------------------------------------------------------------- - Beschreibung: Optionen fuer das Drucken der Preview - --------------------------------------------------------------------*/ -struct PrintSettingsStruct -{ - Size aPageMaxSize; // groesste Seite - Size aPrtSize; // Papiergroesse - Size aPrvPrtSize; // Groesse innerhalb der LRTB-Raender - Size aGridSize; // Groesse fuer jede Seite, enthaelt je - // die Haelfte von H- und V-Distance - - long nLeft; - long nRight; - long nTop; - long nBottom; - long nHori; - long nVert; - - USHORT nRows; - USHORT nCols; - - BOOL bPrinterLandscape; // Ausrichtung -}; - -class SwPreviewPrintOptionsDialog : public SvxStandardDialog -{ - FixedLine aRowColFL; - FixedText aRowsFT; - NumericField aRowsNF; - FixedText aColsFT; - NumericField aColsNF; - - FixedLine aMarginFL; - FixedText aLSpaceFT; - MetricField aLSpaceMF; - FixedText aRSpaceFT; - MetricField aRSpaceMF; - FixedText aTSpaceFT; - MetricField aTSpaceMF; - FixedText aBSpaceFT; - MetricField aBSpaceMF; - FixedLine aDistanceFL; - FixedText aHSpaceFT; - MetricField aHSpaceMF; - FixedText aVSpaceFT; - MetricField aVSpaceMF; - - RadioButton aLandscapeRB; - RadioButton aPortraitRB; - FixedLine aOrientationFL; - - PrtPrvWindow aPreviewWin; - - OKButton aOkBtn; - CancelButton aCancelBtn; - HelpButton aHelpBtn; - - PushButton aStandardPB; - - SwPagePreView& rPreView; - SwPagePreViewWin& rParentWin; - PrintSettingsStruct aSettings; -/* Size aPageMaxSize; - Size aPrtSize; - - BOOL bOrientation; -*/ - BOOL bStandard; - - virtual void Apply(); - void FillControls(SwPagePreViewPrtData& rData); - - DECL_LINK( ModifyHdl, Edit* ); - DECL_LINK( StandardHdl, PushButton* ); - -public: - SwPreviewPrintOptionsDialog(SwPagePreViewWin& rParent, SwPagePreView& rView); - ~SwPreviewPrintOptionsDialog(); -}; - -/* -----------------19.08.98 13:35------------------- - * - * --------------------------------------------------*/ -SwPreviewPrintOptionsDialog::SwPreviewPrintOptionsDialog( SwPagePreViewWin& rParent, SwPagePreView& rView ) : - SvxStandardDialog( &rParent, SW_RES(DLG_PAGEPREVIEW_PRINTOPTIONS) ), - aRowColFL(this,SW_RES( FL_ROWCOL)), - aRowsFT(this,SW_RES( FT_ROWS)), - aRowsNF(this,SW_RES( NF_ROWS)), - aColsFT(this,SW_RES( FT_COLS)), - aColsNF(this,SW_RES( NF_COLS)), - aMarginFL(this,SW_RES( FL_MARGINS)), - aLSpaceFT(this,SW_RES( FT_LMARGIN)), - aLSpaceMF(this,SW_RES( MF_LMARGIN)), - aRSpaceFT(this,SW_RES( FT_RMARGIN)), - aRSpaceMF(this,SW_RES( MF_RMARGIN)), - aTSpaceFT(this,SW_RES( FT_TMARGIN)), - aTSpaceMF(this,SW_RES( MF_TMARGIN)), - aBSpaceFT(this,SW_RES( FT_BMARGIN)), - aBSpaceMF(this,SW_RES( MF_BMARGIN)), - aDistanceFL(this,SW_RES(FL_DISTANCE)), - aHSpaceFT(this,SW_RES( FT_HMARGIN)), - aHSpaceMF(this,SW_RES( MF_HMARGIN)), - aVSpaceFT(this,SW_RES( FT_VMARGIN)), - aVSpaceMF(this,SW_RES( MF_VMARGIN)), - aLandscapeRB(this,SW_RES( RB_LANDSCAPE)), - aPortraitRB(this,SW_RES( RB_PORTRAIT)), - aOrientationFL(this,SW_RES( FL_ORIENTATION)), - aPreviewWin(this,SW_RES( WIN_PREVIEW), aSettings), - aOkBtn(this,SW_RES(BT_OK)), - aCancelBtn(this,SW_RES(BT_CANCEL)), - aHelpBtn(this,SW_RES(BT_HELP)), - aStandardPB(this,SW_RES(PB_STANDARD)), - rPreView(rView), - rParentWin(rParent), - bStandard(TRUE) -{ - FreeResource(); - ViewShell& rViewSh = *rPreView.GetViewShell(); - // OD 18.12.2002 #103492# - aSettings.aPageMaxSize = rViewSh.PagePreviewLayout()->GetMaxPageSize(); - SfxPrinter* pPrinter = rViewSh.getIDocumentDeviceAccess()->getPrinter( true ); - aSettings.aPrtSize = pPrinter->GetPaperSize(); - //#97682# make sure that no division by zero occurs - if(!aSettings.aPrtSize.Width() || !aSettings.aPrtSize.Height()) - aSettings.aPrtSize = SvxPaperInfo::GetPaperSize(PAPER_A4); - aSettings.bPrinterLandscape = pPrinter->GetOrientation() == ORIENTATION_LANDSCAPE; - - - SwDocShell* pDocShell = rPreView.GetDocShell(); - const SwMasterUsrPref *pUsrPref = SW_MOD()->GetUsrPref(0 != PTR_CAST(SwWebDocShell, pDocShell)); - FieldUnit eFieldUnit = pUsrPref->GetMetric(); - ::SetFieldUnit( aLSpaceMF, eFieldUnit ); - ::SetFieldUnit( aRSpaceMF, eFieldUnit ); - ::SetFieldUnit( aTSpaceMF, eFieldUnit ); - ::SetFieldUnit( aBSpaceMF, eFieldUnit ); - ::SetFieldUnit( aHSpaceMF, eFieldUnit ); - ::SetFieldUnit( aVSpaceMF, eFieldUnit ); - - SwDoc* pDoc = pDocShell->GetDoc(); - SwPagePreViewPrtData aData; - if(pDoc->GetPreViewPrtData()) - { - aData = *pDoc->GetPreViewPrtData(); - bStandard = FALSE; - } - else - { - // Orientation der PreviewData an den Drucker anpassen - aData.SetLandscape(aSettings.bPrinterLandscape); - aData.SetRow(rParent.GetRow()); - aData.SetCol(rParent.GetCol()); - } - FillControls(aData); - - aLSpaceMF.SaveValue(); - aRSpaceMF.SaveValue(); - aTSpaceMF.SaveValue(); - aBSpaceMF.SaveValue(); - aHSpaceMF.SaveValue(); - aVSpaceMF.SaveValue(); - aRowsNF.SaveValue(); - aColsNF.SaveValue(); - aLandscapeRB.SaveValue(); - aPortraitRB.SaveValue(); - - aStandardPB.SetClickHdl(LINK(this, SwPreviewPrintOptionsDialog, StandardHdl)); - Link aLk = LINK(this, SwPreviewPrintOptionsDialog, ModifyHdl); - aLSpaceMF.SetUpHdl(aLk); - aRSpaceMF.SetUpHdl(aLk); - aTSpaceMF.SetUpHdl(aLk); - aBSpaceMF.SetUpHdl(aLk); - aHSpaceMF.SetUpHdl(aLk); - aVSpaceMF.SetUpHdl(aLk); - aRowsNF.SetUpHdl(aLk); - aColsNF.SetUpHdl(aLk); - aLSpaceMF.SetDownHdl(aLk); - aRSpaceMF.SetDownHdl(aLk); - aTSpaceMF.SetDownHdl(aLk); - aBSpaceMF.SetDownHdl(aLk); - aHSpaceMF.SetDownHdl(aLk); - aVSpaceMF.SetDownHdl(aLk); - aRowsNF.SetDownHdl(aLk); - aColsNF.SetDownHdl(aLk); - aLSpaceMF.SetLoseFocusHdl(aLk); - aRSpaceMF.SetLoseFocusHdl(aLk); - aTSpaceMF.SetLoseFocusHdl(aLk); - aBSpaceMF.SetLoseFocusHdl(aLk); - aHSpaceMF.SetLoseFocusHdl(aLk); - aVSpaceMF.SetLoseFocusHdl(aLk); - aRowsNF.SetLoseFocusHdl(aLk); - aColsNF.SetLoseFocusHdl(aLk); - aLandscapeRB.SetClickHdl(aLk); - aPortraitRB.SetClickHdl(aLk); - - ModifyHdl(0); - if(bStandard) - StandardHdl(&aStandardPB); -} - - -/* -----------------19.08.98 13:36------------------- - * - * --------------------------------------------------*/ -SwPreviewPrintOptionsDialog::~SwPreviewPrintOptionsDialog() -{ -} -/* -----------------12.11.98 11:32------------------- - * - * --------------------------------------------------*/ -void SwPreviewPrintOptionsDialog::FillControls(SwPagePreViewPrtData& rData) -{ - aLSpaceMF.SetValue(aLSpaceMF.Normalize(rData.GetLeftSpace() ), FUNIT_TWIP); - aRSpaceMF.SetValue(aRSpaceMF.Normalize(rData.GetRightSpace() ), FUNIT_TWIP); - aTSpaceMF.SetValue(aTSpaceMF.Normalize(rData.GetTopSpace() ), FUNIT_TWIP); - aBSpaceMF.SetValue(aBSpaceMF.Normalize(rData.GetBottomSpace()), FUNIT_TWIP); - aHSpaceMF.SetValue(aHSpaceMF.Normalize(rData.GetHorzSpace() ), FUNIT_TWIP); - aVSpaceMF.SetValue(aVSpaceMF.Normalize(rData.GetVertSpace() ), FUNIT_TWIP); - aRowsNF.SetValue(rData.GetRow()); - aColsNF.SetValue(rData.GetCol()); - aSettings.bPrinterLandscape ? aLandscapeRB.Check() : aPortraitRB.Check(); - // wenn Drucker und Einstellungen nicht uebereinstimmen, dann Seiten tauschen - if( rData.GetLandscape() != aSettings.bPrinterLandscape ) - { - Size aTmp(aSettings.aPrtSize.Height(), aSettings.aPrtSize.Width()); - aSettings.aPrtSize = aTmp; - aSettings.bPrinterLandscape = !aSettings.bPrinterLandscape; - // nochmal setzen, denn auch wenn nur die Default-Orientierung dem Drucker - // angepasst wurde, sollen die Einstellungen gespeichert werden - aSettings.bPrinterLandscape ? aLandscapeRB.Check() : aPortraitRB.Check(); - } - aLandscapeRB.SaveValue(); - aPortraitRB.SaveValue(); - - aSettings.nLeft = rData.GetLeftSpace() ; - aSettings.nRight = rData.GetRightSpace() ; - aSettings.nTop = rData.GetTopSpace() ; - aSettings.nBottom = rData.GetBottomSpace(); - aSettings.nHori = rData.GetHorzSpace() ; - aSettings.nVert = rData.GetVertSpace() ; - aSettings.nRows = rData.GetRow() ; - aSettings.nCols = rData.GetCol() ; - aSettings.aPrvPrtSize = aSettings.aPrtSize ; -} - -/* -----------------19.08.98 14:31------------------- - * - * --------------------------------------------------*/ -void SwPreviewPrintOptionsDialog::Apply() -{ - - SwDoc* pDoc = rPreView.GetDocShell()->GetDoc(); - if(bStandard) - pDoc->SetPreViewPrtData(0); - else if( aLSpaceMF.GetSavedValue() != aLSpaceMF.GetText() || - aRSpaceMF.GetSavedValue() != aRSpaceMF.GetText() || - aTSpaceMF.GetSavedValue() != aTSpaceMF.GetText() || - aBSpaceMF.GetSavedValue() != aBSpaceMF.GetText() || - aHSpaceMF.GetSavedValue() != aHSpaceMF.GetText() || - aVSpaceMF.GetSavedValue() != aVSpaceMF.GetText() || - aRowsNF.GetSavedValue() != aRowsNF.GetText() || - aColsNF.GetSavedValue() != aColsNF.GetText() || - aLandscapeRB.GetSavedValue() != aLandscapeRB.IsChecked() || - aPortraitRB.GetSavedValue() != aPortraitRB.IsChecked() ) - { - SwPagePreViewPrtData aData; - if(pDoc->GetPreViewPrtData()) - aData = *pDoc->GetPreViewPrtData(); - aData.SetLeftSpace( static_cast< ULONG >(aLSpaceMF.Denormalize(aLSpaceMF.GetValue(FUNIT_TWIP))) ); - aData.SetRightSpace( static_cast< ULONG >(aRSpaceMF.Denormalize(aRSpaceMF.GetValue(FUNIT_TWIP))) ); - aData.SetTopSpace( static_cast< ULONG >(aTSpaceMF.Denormalize(aTSpaceMF.GetValue(FUNIT_TWIP))) ); - aData.SetBottomSpace( static_cast< ULONG >(aBSpaceMF.Denormalize(aBSpaceMF.GetValue(FUNIT_TWIP))) ); - - aData.SetHorzSpace( static_cast< ULONG >(aHSpaceMF.Denormalize(aHSpaceMF.GetValue(FUNIT_TWIP))) ); - aData.SetVertSpace( static_cast< ULONG >(aVSpaceMF.Denormalize(aVSpaceMF.GetValue(FUNIT_TWIP))) ); - aData.SetRow((BYTE)aRowsNF.GetValue()); - aData.SetCol((BYTE)aColsNF.GetValue()); - aData.SetLandscape(aLandscapeRB.IsChecked()); - - ViewShell& rViewSh = *rPreView.GetViewShell(); - SfxPrinter* pPrinter = rViewSh.getIDocumentDeviceAccess()->getPrinter( true ); - if((pPrinter->GetOrientation() == ORIENTATION_LANDSCAPE) - != aData.GetLandscape()) - pPrinter->SetOrientation(aData.GetLandscape() ? ORIENTATION_LANDSCAPE : ORIENTATION_PORTRAIT); - - - pDoc->SetPreViewPrtData(&aData); - - } -} -/* -----------------20.08.98 08:48------------------- - * - * --------------------------------------------------*/ -IMPL_LINK( SwPreviewPrintOptionsDialog, ModifyHdl, Edit*, pEdit ) -{ - if(bStandard && pEdit) - { - aLSpaceMF.SetUserValue(aLSpaceMF.GetValue()); - aRSpaceMF.SetUserValue(aRSpaceMF.GetValue()); - aTSpaceMF.SetUserValue(aTSpaceMF.GetValue()); - aBSpaceMF.SetUserValue(aBSpaceMF.GetValue()); - aHSpaceMF.SetUserValue(aHSpaceMF.GetValue()); - aVSpaceMF.SetUserValue(aVSpaceMF.GetValue()); - aRowsNF. SetUserValue(aRowsNF .GetValue()); - aColsNF. SetUserValue(aColsNF .GetValue()); - - bStandard = FALSE; - } - BOOL bOrientChanged = aSettings.bPrinterLandscape != aLandscapeRB.IsChecked();; - if(pEdit == &aLSpaceMF) - aSettings.nLeft = static_cast< long >(aLSpaceMF.Denormalize(aLSpaceMF.GetValue(FUNIT_TWIP))); - else if(pEdit == &aRSpaceMF) - aSettings.nRight = static_cast< long >(aRSpaceMF.Denormalize(aRSpaceMF.GetValue(FUNIT_TWIP))); - else if(pEdit == &aTSpaceMF) - aSettings.nTop = static_cast< long >(aTSpaceMF.Denormalize(aTSpaceMF.GetValue(FUNIT_TWIP))); - else if(pEdit == &aBSpaceMF) - aSettings.nBottom = static_cast< long >(aBSpaceMF.Denormalize(aBSpaceMF.GetValue(FUNIT_TWIP))); - else if(pEdit == &aHSpaceMF) - aSettings.nHori = static_cast< long >(aHSpaceMF.Denormalize(aHSpaceMF.GetValue(FUNIT_TWIP))); - else if(pEdit == &aVSpaceMF) - aSettings.nVert = static_cast< long >(aVSpaceMF.Denormalize(aVSpaceMF.GetValue(FUNIT_TWIP))); - else if(pEdit == &aRowsNF) - aSettings.nRows = (USHORT)aRowsNF.GetValue(); - else if(pEdit == &aColsNF) - aSettings.nCols = (USHORT)aColsNF.GetValue(); - else if(pEdit == (Edit*)&aLandscapeRB) - aSettings.bPrinterLandscape = aLandscapeRB.IsChecked(); - else if(pEdit == (Edit*)&aPortraitRB) - aSettings.bPrinterLandscape = aLandscapeRB.IsChecked(); - - if(bOrientChanged) - { - Size aTmp(aSettings.aPrtSize.Height(), aSettings.aPrtSize.Width()); - aSettings.aPrtSize = aTmp; - } - - - aSettings.aPrvPrtSize = Size(aSettings.aPrtSize.Width() - aSettings.nRight - aSettings.nLeft, - aSettings.aPrtSize.Height() - aSettings.nTop - aSettings.nBottom); - aSettings.aGridSize = Size(aSettings.aPrvPrtSize.Width() / aSettings.nCols, - aSettings.aPrvPrtSize.Height() / aSettings.nRows ); - // was fehlt noch: Orientation auswerten, minimalrand ausrechnen, Beispiel fuettern - - - //am Ende Maximalwerte setzen - long n20Percent = aSettings.aPrtSize.Width() / 5; - aLSpaceMF.SetMax(aLSpaceMF.Normalize(aSettings.aPrtSize.Width() - aSettings.nRight - n20Percent), FUNIT_TWIP); - aRSpaceMF.SetMax(aRSpaceMF.Normalize(aSettings.aPrtSize.Width() - aSettings.nLeft - n20Percent), FUNIT_TWIP); - n20Percent = aSettings.aPrtSize.Height() / 5; - aTSpaceMF.SetMax(aTSpaceMF.Normalize(aSettings.aPrtSize.Height() - aSettings.nBottom - n20Percent), FUNIT_TWIP); - aBSpaceMF.SetMax(aBSpaceMF.Normalize(aSettings.aPrtSize.Height() - aSettings.nTop - n20Percent), FUNIT_TWIP); - - long n80Percent = aSettings.aPrvPrtSize.Width() * 4 / 5; - aHSpaceMF.SetMax(aHSpaceMF.Normalize(n80Percent / aSettings.nRows), FUNIT_TWIP); - n80Percent = aSettings.aPrvPrtSize.Height()* 4 / 5; - aVSpaceMF.SetMax(aVSpaceMF.Normalize(n80Percent / aSettings.nCols), FUNIT_TWIP); - aHSpaceMF.Enable(aSettings.nCols > 1); - aVSpaceMF.Enable(aSettings.nRows > 1); - aRowsNF.SetMin(1);// nur damit auch nach Standard wieder der Inhalt angezeigt wird - aColsNF.SetMin(1); - - - aPreviewWin.Invalidate(); - return 0; -} -/* -----------------28.08.98 14:59------------------- - * - * --------------------------------------------------*/ -IMPL_LINK( SwPreviewPrintOptionsDialog, StandardHdl, PushButton*, EMPTYARG ) -{ - SetUpdateMode(TRUE); - SwPagePreViewPrtData aData; - aData.SetRow(rParentWin.GetRow()); - aData.SetCol(rParentWin.GetCol()); - FillControls(aData); - bStandard = TRUE; - aLSpaceMF.SetText(aEmptyStr); - aRSpaceMF.SetText(aEmptyStr); - aTSpaceMF.SetText(aEmptyStr); - aBSpaceMF.SetText(aEmptyStr); - aHSpaceMF.SetText(aEmptyStr); - aVSpaceMF.SetText(aEmptyStr); - aPreviewWin.Invalidate(); - SetUpdateMode(FALSE); - return 0; -} -/* -----------------20.08.98 15:28------------------- - * Preview anzeigen - * --------------------------------------------------*/ -void PrtPrvWindow::Paint(const Rectangle&) -{ - Size aWinSize(GetOutputSizePixel()); - long nWidth = rSettings.aPrtSize.Width(); - long nHeight = rSettings.aPrtSize.Height(); - BOOL bHoriValid = (aWinSize.Width() * 100 / aWinSize.Height()) < - (rSettings.aPrtSize.Width() * 100/ rSettings.aPrtSize.Height()); - Fraction aXScale( aWinSize.Width(), Max( nWidth , 1L ) ); - Fraction aYScale( aWinSize.Height(), Max( nHeight, 1L ) ); - MapMode aMapMode( GetMapMode() ); - aMapMode.SetScaleX( bHoriValid ? aXScale : aYScale); - aMapMode.SetScaleY( bHoriValid ? aXScale : aYScale); - SetMapMode( aMapMode ); - - aWinSize = GetOutputSize(); - - Point aOffset(0,0); - if(bHoriValid) - aOffset.Y() = (aWinSize.Height() - rSettings.aPrtSize.Height()) / 2; - else - aOffset.X() = (aWinSize.Width() - rSettings.aPrtSize.Width()) / 2;; - - - BOOL bUseSystemColors = SvtAccessibilityOptions().GetIsForPagePreviews() - && GetSettings().GetStyleSettings().GetHighContrastMode(); - - //der weisse Seitenhintergrund - Rectangle aRect(aOffset, rSettings.aPrtSize); - if(bUseSystemColors) - { - SetFillColor( GetSettings().GetStyleSettings().GetWindowColor() ); - SetLineColor( SwViewOption::GetFontColor() ); - } - else - { - SetFillColor( Color( COL_WHITE ) ); - SetLineColor(Color( COL_BLACK ) ); - } - - DrawRect(aRect); - - Point aTL(aOffset); - aTL.X() += rSettings.nLeft; - aTL.Y() += rSettings.nTop; - - Size aPrvPageSize((rSettings.aPrvPrtSize.Width() - (rSettings.nCols - 1) * rSettings.nHori) / rSettings.nCols, - (rSettings.aPrvPrtSize.Height() - (rSettings.nRows - 1) * rSettings.nVert) / rSettings.nRows); - // jetzt muss noch das unterschiedliche Groessenverhaeltnis berechnet werden, um es an - // der richtigen Seite abzuziehen. - //... - long nSourceScale = rSettings.aPageMaxSize.Width() * 100 / rSettings.aPageMaxSize.Height(); - long nDestScale = aPrvPageSize.Width() * 100 / aPrvPageSize.Height() ; - if(nSourceScale > nDestScale) // die Seite ist relativ breiter als das vorhandene Rechteck - { - aPrvPageSize.Height() = aPrvPageSize.Width() * 100 / nSourceScale; - } - else - { - aPrvPageSize.Width() = aPrvPageSize.Height() * nSourceScale / 100; - } - - if(bUseSystemColors) - SetFillColor( GetSettings().GetStyleSettings().GetWindowColor() ); - else - SetFillColor( Color( COL_GRAY ) ); - - - aRect = Rectangle(aTL, aPrvPageSize); - for(USHORT i = 0; i < rSettings.nRows; i++) - { - for(USHORT j = 0; j < rSettings.nCols; j++) - { - DrawRect(aRect); - aRect.Move(aPrvPageSize.Width() + rSettings.nHori, 0); - } - - aRect.Move( 0, aPrvPageSize.Height() + rSettings.nVert); - aRect.SetPos(Point(aTL.X(), aRect.TopLeft().Y())); - } - //rSettings; -} - -/* */ /*-------------------------------------------------------------------- Beschreibung: --------------------------------------------------------------------*/ diff --git a/sw/source/ui/uiview/pview.src b/sw/source/ui/uiview/pview.src index 53f672dbdb60..1a8833e76b34 100644..100755 --- a/sw/source/ui/uiview/pview.src +++ b/sw/source/ui/uiview/pview.src @@ -29,272 +29,7 @@ #include "pview.hrc" #include "helpid.h" #include "cmdid.h" -ModalDialog DLG_PAGEPREVIEW_PRINTOPTIONS -{ - HelpID = HID_DLG_PRV_PRT_OPTIONS ; - OutputSize = TRUE ; - SVLook = TRUE ; - Moveable = TRUE ; - Size = MAP_APPFONT ( 312 , 131 ) ; - FixedLine FL_ROWCOL - { - Pos = MAP_APPFONT ( 6 , 3 ) ; - Size = MAP_APPFONT ( 150 , 8 ) ; - - Text [ en-US ] = "Distribution"; - }; - FixedText FT_ROWS - { - Pos = MAP_APPFONT ( 12 , 15 ) ; - Size = MAP_APPFONT ( 30 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "Ro~ws"; - }; - NumericField NF_ROWS - { - Border = TRUE ; - Pos = MAP_APPFONT ( 45 , 14 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = PVIEW_MIN_ROW ; - Maximum = PVIEW_MAX_ROW ; - Value = 1 ; - First = PVIEW_MIN_COL ; - Last = PVIEW_MAX_COL ; - }; - FixedText FT_COLS - { - Pos = MAP_APPFONT ( 84 , 15 ) ; - Size = MAP_APPFONT ( 30 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "~Columns"; - }; - NumericField NF_COLS - { - Border = TRUE ; - Pos = MAP_APPFONT ( 117 , 14 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - TabStop = TRUE ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - Minimum = PVIEW_MIN_COL ; - Maximum = PVIEW_MAX_COL ; - Value = 1 ; - First = PVIEW_MIN_COL ; - Last = PVIEW_MAX_COL ; - }; - FixedLine FL_MARGINS - { - Pos = MAP_APPFONT ( 6 , 32 ) ; - Size = MAP_APPFONT ( 150 , 8 ) ; - Text [ en-US ] = "Margins"; - }; - FixedText FT_LMARGIN - { - Pos = MAP_APPFONT ( 12 , 44 ) ; - Size = MAP_APPFONT ( 30 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "L~eft"; - }; - MetricField MF_LMARGIN - { - Border = TRUE ; - Pos = MAP_APPFONT ( 45 , 43 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - DecimalDigits = 1 ; - Unit = FUNIT_CM ; - SpinSize = 10 ; - Minimum = 0 ; - Maximum = 9999 ; - First = 0 ; - Last = 2000 ; - }; - FixedText FT_RMARGIN - { - Pos = MAP_APPFONT ( 84 , 44 ) ; - Size = MAP_APPFONT ( 30 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "~Right"; - }; - MetricField MF_RMARGIN - { - Border = TRUE ; - Pos = MAP_APPFONT ( 117 , 43 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - DecimalDigits = 1 ; - Unit = FUNIT_CM ; - SpinSize = 10 ; - Minimum = 0 ; - Maximum = 9999 ; - First = 0 ; - Last = 2000 ; - }; - FixedText FT_TMARGIN - { - Pos = MAP_APPFONT ( 12 , 59 ) ; - Size = MAP_APPFONT ( 30 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "~Top"; - }; - MetricField MF_TMARGIN - { - Border = TRUE ; - Pos = MAP_APPFONT ( 45 , 58 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - DecimalDigits = 1 ; - Unit = FUNIT_CM ; - SpinSize = 10 ; - Minimum = 0 ; - Maximum = 9999 ; - First = 0 ; - Last = 2000 ; - }; - FixedText FT_BMARGIN - { - Pos = MAP_APPFONT ( 84 , 59 ) ; - Size = MAP_APPFONT ( 30 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "~Bottom"; - }; - MetricField MF_BMARGIN - { - Border = TRUE ; - Pos = MAP_APPFONT ( 117 , 58 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - DecimalDigits = 1 ; - Unit = FUNIT_CM ; - SpinSize = 10 ; - Minimum = 0 ; - Maximum = 9999 ; - First = 0 ; - Last = 2000 ; - }; - FixedLine FL_DISTANCE - { - Pos = MAP_APPFONT ( 6 , 76 ) ; - Size = MAP_APPFONT ( 150 , 8 ) ; - - Text [ en-US ] = "Spacing"; - }; - FixedText FT_HMARGIN - { - Pos = MAP_APPFONT ( 12 , 88 ) ; - Size = MAP_APPFONT ( 30 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "Hori~zontal"; - }; - - MetricField MF_HMARGIN - { - Border = TRUE ; - Pos = MAP_APPFONT ( 45 , 87 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - DecimalDigits = 1 ; - Unit = FUNIT_CM ; - SpinSize = 10 ; - Minimum = 0 ; - Maximum = 9999 ; - First = 0 ; - Last = 2000 ; - }; - FixedText FT_VMARGIN - { - Pos = MAP_APPFONT ( 84 , 88 ) ; - Size = MAP_APPFONT ( 32 , 10 ) ; - Left = TRUE ; - Text [ en-US ] = "~Vertically"; - }; - - MetricField MF_VMARGIN - { - Border = TRUE ; - Pos = MAP_APPFONT ( 117 , 87 ) ; - Size = MAP_APPFONT ( 36 , 12 ) ; - Left = TRUE ; - Repeat = TRUE ; - Spin = TRUE ; - DecimalDigits = 1 ; - Unit = FUNIT_CM ; - SpinSize = 10 ; - Minimum = 0 ; - Maximum = 9999 ; - First = 0 ; - Last = 2000 ; - }; - FixedLine FL_ORIENTATION - { - Pos = MAP_APPFONT ( 6 , 102 ) ; - Size = MAP_APPFONT ( 150 , 8 ) ; - Text [ en-US ] = "Format"; - }; - RadioButton RB_LANDSCAPE - { - Pos = MAP_APPFONT ( 12 , 113 ) ; - Size = MAP_APPFONT ( 60 , 12 ) ; - TabStop = TRUE ; - Group = TRUE ; - Text [ en-US ] = "~Landscape"; - }; - RadioButton RB_PORTRAIT - { - Pos = MAP_APPFONT ( 84 , 113 ) ; - Size = MAP_APPFONT ( 60 , 12 ) ; - Text [ en-US ] = "P~ortrait"; - }; - Window WIN_PREVIEW - { - Pos = MAP_APPFONT ( 162 , 7 ) ; - Size = MAP_APPFONT ( 90 , 113 ) ; - }; - - OKButton BT_OK - { - Pos = MAP_APPFONT ( 258 , 6 ) ; - Size = MAP_APPFONT ( 50 , 14 ) ; - TabStop = TRUE ; - DefButton = TRUE ; - }; - CancelButton BT_CANCEL - { - Pos = MAP_APPFONT ( 258 , 23 ) ; - Size = MAP_APPFONT ( 50 , 14 ) ; - TabStop = TRUE ; - }; - HelpButton BT_HELP - { - Pos = MAP_APPFONT ( 258 , 49 ) ; - Size = MAP_APPFONT ( 50 , 14 ) ; - TabStop = TRUE ; - }; - PushButton PB_STANDARD - { - Pos = MAP_APPFONT ( 258 , 66 ) ; - Size = MAP_APPFONT ( 50 , 14 ) ; - TabStop = TRUE ; - Text [ en-US ] = "~Default"; - }; - Text [ en-US ] = "Print Options"; -}; ModalDialog DLG_PAGEPREVIEW_ZOOM { HelpID = HID_PPREV_ZOOM ; @@ -460,31 +195,3 @@ ToolBox RID_PVIEW_TOOLBOX Scroll = TRUE ; }; - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/sw/source/ui/uiview/view.hrc b/sw/source/ui/uiview/view.hrc index 8697a7e4ed63..d2aa60494801 100644..100755 --- a/sw/source/ui/uiview/view.hrc +++ b/sw/source/ui/uiview/view.hrc @@ -77,7 +77,6 @@ #define DLG_SPECIAL_FORCED (RC_VIEW_BEGIN) #define DLG_PAGEPREVIEW_ZOOM (RC_VIEW_BEGIN + 1) -#define DLG_PAGEPREVIEW_PRINTOPTIONS (RC_VIEW_BEGIN + 2) // Ueberlaufpruefung ----------------------------------------------------- |