summaryrefslogtreecommitdiff
path: root/svx/source/dialog
diff options
context:
space:
mode:
Diffstat (limited to 'svx/source/dialog')
-rw-r--r--svx/source/dialog/SpellDialogChildWindow.cxx9
-rw-r--r--svx/source/dialog/_bmpmask.cxx10
-rw-r--r--svx/source/dialog/_contdlg.cxx21
-rw-r--r--svx/source/dialog/bmpmask.hrc3
-rw-r--r--svx/source/dialog/bmpmask.src13
-rw-r--r--svx/source/dialog/charmap.cxx3
-rw-r--r--svx/source/dialog/checklbx.cxx8
-rw-r--r--svx/source/dialog/connctrl.cxx2
-rw-r--r--svx/source/dialog/contdlg.hrc1
-rw-r--r--svx/source/dialog/contdlg.src11
-rw-r--r--svx/source/dialog/contimp.hxx5
-rw-r--r--svx/source/dialog/contwnd.cxx3
-rw-r--r--svx/source/dialog/contwnd.hxx2
-rw-r--r--svx/source/dialog/ctredlin.cxx6
-rw-r--r--svx/source/dialog/ctredlin.hrc2
-rw-r--r--svx/source/dialog/ctredlin.src5
-rw-r--r--svx/source/dialog/databaseregistrationui.cxx12
-rw-r--r--svx/source/dialog/dialcontrol.cxx6
-rw-r--r--svx/source/dialog/dialmgr.cxx3
-rw-r--r--svx/source/dialog/dlgctl3d.cxx3
-rw-r--r--svx/source/dialog/dlgctrl.cxx5
-rw-r--r--svx/source/dialog/dlgutil.cxx4
-rw-r--r--svx/source/dialog/docrecovery.cxx56
-rw-r--r--svx/source/dialog/docrecovery.hrc3
-rw-r--r--svx/source/dialog/docrecovery.src12
-rw-r--r--svx/source/dialog/fntctrl.cxx15
-rw-r--r--svx/source/dialog/fontlb.cxx2
-rw-r--r--svx/source/dialog/fontwork.cxx26
-rw-r--r--svx/source/dialog/fontwork.hrc1
-rw-r--r--svx/source/dialog/fontwork.src55
-rw-r--r--svx/source/dialog/framelink.cxx204
-rw-r--r--svx/source/dialog/framelinkarray.cxx2
-rw-r--r--svx/source/dialog/frmdirlbox.cxx2
-rw-r--r--svx/source/dialog/frmsel.cxx45
-rw-r--r--svx/source/dialog/graphctl.cxx9
-rw-r--r--svx/source/dialog/grfflt.cxx484
-rw-r--r--svx/source/dialog/hdft.cxx26
-rw-r--r--svx/source/dialog/hyperdlg.cxx7
-rw-r--r--svx/source/dialog/hyprdlg.hxx6
-rw-r--r--svx/source/dialog/hyprlink.cxx72
-rw-r--r--svx/source/dialog/imapdlg.cxx35
-rw-r--r--svx/source/dialog/imapdlg.hrc1
-rw-r--r--svx/source/dialog/imapdlg.src7
-rw-r--r--svx/source/dialog/imapimp.hxx5
-rw-r--r--svx/source/dialog/imapwnd.cxx58
-rw-r--r--svx/source/dialog/imapwnd.hxx2
-rw-r--r--svx/source/dialog/langbox.cxx17
-rw-r--r--svx/source/dialog/langbox.src6
-rw-r--r--svx/source/dialog/linkwarn.cxx150
-rw-r--r--svx/source/dialog/linkwarn.hrc60
-rw-r--r--svx/source/dialog/linkwarn.src85
-rw-r--r--svx/source/dialog/makefile.mk1
-rw-r--r--svx/source/dialog/measctrl.cxx2
-rw-r--r--svx/source/dialog/optgrid.cxx24
-rw-r--r--svx/source/dialog/orienthelper.cxx3
-rw-r--r--svx/source/dialog/pagectrl.cxx11
-rw-r--r--svx/source/dialog/paraprev.cxx2
-rw-r--r--svx/source/dialog/passwd.cxx4
-rw-r--r--svx/source/dialog/pfiledlg.cxx11
-rw-r--r--svx/source/dialog/prtqry.cxx8
-rw-r--r--svx/source/dialog/relfld.cxx2
-rw-r--r--svx/source/dialog/rlrcitem.cxx2
-rw-r--r--svx/source/dialog/rlrcitem.hxx2
-rw-r--r--svx/source/dialog/rubydialog.cxx59
-rw-r--r--svx/source/dialog/ruler.hrc3
-rw-r--r--svx/source/dialog/ruler.src12
-rw-r--r--svx/source/dialog/rulritem.cxx74
-rw-r--r--svx/source/dialog/sendreportgen.cxx3
-rw-r--r--svx/source/dialog/sendreportunx.cxx3
-rw-r--r--svx/source/dialog/sendreportw32.cxx8
-rw-r--r--svx/source/dialog/simptabl.cxx11
-rw-r--r--svx/source/dialog/srchctrl.cxx2
-rw-r--r--svx/source/dialog/srchctrl.hxx2
-rw-r--r--svx/source/dialog/srchdlg.cxx122
-rw-r--r--svx/source/dialog/stddlg.cxx6
-rw-r--r--svx/source/dialog/strarray.cxx2
-rw-r--r--svx/source/dialog/svxbmpnumvalueset.cxx35
-rw-r--r--svx/source/dialog/svxdlg.cxx1
-rw-r--r--svx/source/dialog/svxgrahicitem.cxx3
-rw-r--r--svx/source/dialog/svxruler.cxx41
-rw-r--r--svx/source/dialog/swframeexample.cxx2
-rw-r--r--svx/source/dialog/swframeposstrings.cxx9
-rw-r--r--svx/source/dialog/txencbox.cxx2
-rw-r--r--svx/source/dialog/txenctab.cxx2
-rw-r--r--svx/source/dialog/wrapfield.cxx2
85 files changed, 811 insertions, 1255 deletions
diff --git a/svx/source/dialog/SpellDialogChildWindow.cxx b/svx/source/dialog/SpellDialogChildWindow.cxx
index f1e0da5d29..1ce369af35 100644
--- a/svx/source/dialog/SpellDialogChildWindow.cxx
+++ b/svx/source/dialog/SpellDialogChildWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -94,26 +95,22 @@ void SpellDialogChildWindow::AddAutoCorrection(
{
DBG_ERROR("AutoCorrection should have been overloaded - if available");
}
-/*-- 16.06.2008 10:11:57---------------------------------------------------
- -----------------------------------------------------------------------*/
bool SpellDialogChildWindow::HasGrammarChecking()
{
return false;
}
-/*-- 18.06.2008 12:26:35---------------------------------------------------
- -----------------------------------------------------------------------*/
bool SpellDialogChildWindow::IsGrammarChecking()
{
DBG_ERROR("Grammar checking should have been overloaded - if available");
return false;
}
-/*-- 18.06.2008 12:26:35---------------------------------------------------
- -----------------------------------------------------------------------*/
void SpellDialogChildWindow::SetGrammarChecking(bool )
{
DBG_ERROR("Grammar checking should have been overloaded - if available");
}
} // end of namespace ::svx
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/_bmpmask.cxx b/svx/source/dialog/_bmpmask.cxx
index 022478a824..d125982f48 100644
--- a/svx/source/dialog/_bmpmask.cxx
+++ b/svx/source/dialog/_bmpmask.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -446,8 +447,7 @@ SvxBmpMask::SvxBmpMask( SfxBindings *pBindinx,
pColTab ( NULL ),
aPipetteColor ( COL_WHITE ),
aSelItem ( SID_BMPMASK_EXEC, *this, *pBindinx ),
- maImgPipette ( BMP_RESID ( IMG_PIPETTE ) ),
- maImgPipetteH ( BMP_RESID ( IMG_PIPETTE_H ) )
+ maImgPipette ( BMP_RESID ( IMG_PIPETTE ) )
{
FreeResource();
@@ -1209,9 +1209,7 @@ void SvxBmpMask::DataChanged( const DataChangedEvent& rDCEvt )
void SvxBmpMask::ApplyStyle()
{
- bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
-
- aTbxPipette.SetItemImage( TBI_PIPETTE, bHighContrast ? maImgPipetteH : maImgPipette );
+ aTbxPipette.SetItemImage( TBI_PIPETTE, maImgPipette );
}
@@ -1239,3 +1237,5 @@ void SvxBmpMask::SetAccessibleNames (void)
sSourceColorN.AppendAscii (RTL_CONSTASCII_STRINGPARAM (" 4"));
aCbx4.SetAccessibleName (sSourceColorN);
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/_contdlg.cxx b/svx/source/dialog/_contdlg.cxx
index d73b0faafa..4829d0929b 100644
--- a/svx/source/dialog/_contdlg.cxx
+++ b/svx/source/dialog/_contdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,9 +38,7 @@
#include <sfx2/viewfrm.hxx>
#include <svtools/miscopt.hxx>
#include <unotools/localedatawrapper.hxx>
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
#define _SDR_NOITEMS
#define _SDR_NOTOUCH
@@ -287,8 +286,6 @@ void SvxContourDlg::ScaleContour( PolyPolygon& rContour, const Graphic& rGraphic
const MapMode aDispMap( eUnit );
const MapMode aGrfMap( rGraphic.GetPrefMapMode() );
const Size aGrfSize( rGraphic.GetPrefSize() );
- double fScaleX;
- double fScaleY;
Size aOrgSize;
Point aNewPoint;
BOOL bPixelMap = aGrfMap.GetMapUnit() == MAP_PIXEL;
@@ -300,8 +297,8 @@ void SvxContourDlg::ScaleContour( PolyPolygon& rContour, const Graphic& rGraphic
if ( aOrgSize.Width() && aOrgSize.Height() )
{
- fScaleX = (double) rDisplaySize.Width() / aOrgSize.Width();
- fScaleY = (double) rDisplaySize.Height() / aOrgSize.Height();
+ double fScaleX = (double) rDisplaySize.Width() / aOrgSize.Width();
+ double fScaleY = (double) rDisplaySize.Height() / aOrgSize.Height();
for ( USHORT j = 0, nPolyCount = rContour.Count(); j < nPolyCount; j++ )
{
@@ -398,8 +395,7 @@ SvxSuperContourDlg::SvxSuperContourDlg( SfxBindings *_pBindings, SfxChildWindow
nGrfChanged ( 0UL ),
bExecState ( FALSE ),
bGraphicLinked ( FALSE ),
- maImageList ( SVX_RES( CD_IMAPDLG ) ),
- maImageListH ( SVX_RES( CDH_IMAPDLG ) )
+ maImageList ( SVX_RES( CD_IMAPDLG ) )
{
ApplyImageList();
@@ -811,7 +807,7 @@ IMPL_LINK( SvxSuperContourDlg, Tbx1ClickHdl, ToolBox*, pTbx )
case( TBI_UNDO ):
{
- nGrfChanged = nGrfChanged ? nGrfChanged-- : 0UL;
+ nGrfChanged = nGrfChanged ? nGrfChanged - 1 : 0UL;
aRedoGraphic = aGraphic;
aGraphic = aUndoGraphic;
aUndoGraphic = Graphic();
@@ -1130,9 +1126,7 @@ IMPL_LINK( SvxSuperContourDlg, WorkplaceClickHdl, ContourWindow*, pWnd )
void SvxSuperContourDlg::ApplyImageList()
{
- bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
-
- ImageList& rImgLst = bHighContrast ? maImageListH : maImageList;
+ ImageList& rImgLst = maImageList;
aTbx1.SetImageList( rImgLst );
}
@@ -1153,9 +1147,10 @@ void SvxSuperContourDlg::DataChanged( const DataChangedEvent& rDCEvt )
IMPL_LINK( SvxSuperContourDlg, MiscHdl, void*, EMPTYARG )
{
- SvtMiscOptions aMiscOptions;
+ SvtMiscOptions aMiscOptions;
aTbx1.SetOutStyle( aMiscOptions.GetToolboxStyle() );
return 0L;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/bmpmask.hrc b/svx/source/dialog/bmpmask.hrc
index 79c9b60d3a..be2a2a9772 100644
--- a/svx/source/dialog/bmpmask.hrc
+++ b/svx/source/dialog/bmpmask.hrc
@@ -57,6 +57,3 @@
#define FT_2 2
#define FT_3 3
#define IMG_PIPETTE 11
-#define IMG_PIPETTE_H 12
-
-
diff --git a/svx/source/dialog/bmpmask.src b/svx/source/dialog/bmpmask.src
index 2c81fa7104..6332a80e07 100644
--- a/svx/source/dialog/bmpmask.src
+++ b/svx/source/dialog/bmpmask.src
@@ -104,7 +104,7 @@ DockingWindow RID_SVXDLG_BMPMASK
Last = 99 ;
SpinSize = 1 ;
Unit = FUNIT_CUSTOM ;
- CustomUnitText = " %" ;
+ CustomUnitText = "%" ;
};
ListBox LB_1
{
@@ -147,7 +147,7 @@ DockingWindow RID_SVXDLG_BMPMASK
Last = 99 ;
SpinSize = 1 ;
Unit = FUNIT_CUSTOM ;
- CustomUnitText = " %" ;
+ CustomUnitText = "%" ;
};
ListBox LB_2
{
@@ -190,7 +190,7 @@ DockingWindow RID_SVXDLG_BMPMASK
Last = 99 ;
SpinSize = 1 ;
Unit = FUNIT_CUSTOM ;
- CustomUnitText = " %" ;
+ CustomUnitText = "%" ;
};
ListBox LB_3
{
@@ -233,7 +233,7 @@ DockingWindow RID_SVXDLG_BMPMASK
Last = 99 ;
SpinSize = 1 ;
Unit = FUNIT_CUSTOM ;
- CustomUnitText = " %" ;
+ CustomUnitText = "%" ;
};
ListBox LB_4
{
@@ -308,11 +308,6 @@ DockingWindow RID_SVXDLG_BMPMASK
MASKCOLOR
};
- Image IMG_PIPETTE_H
- {
- ImageBitmap = Bitmap { File = "sc10350_h.bmp" ; };
- MASKCOLOR
- };
};
String RID_SVXDLG_BMPMASK_STR_TRANSP
diff --git a/svx/source/dialog/charmap.cxx b/svx/source/dialog/charmap.cxx
index 1dce3620a5..69370001a0 100644
--- a/svx/source/dialog/charmap.cxx
+++ b/svx/source/dialog/charmap.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -891,3 +892,5 @@ void SubsetMap::ApplyCharMap( const FontCharMap* pFontCharMap )
maSubsets.erase( it );
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/checklbx.cxx b/svx/source/dialog/checklbx.cxx
index 2e070cacdd..7d7f97518c 100644
--- a/svx/source/dialog/checklbx.cxx
+++ b/svx/source/dialog/checklbx.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,10 +62,8 @@ SvxCheckListBox::SvxCheckListBox( Window* pParent, const ResId& rResId ) :
// -----------------------------------------------------------------------
SvxCheckListBox::SvxCheckListBox( Window* pParent, const ResId& rResId,
- const Image& rNormalStaticImage,
- const Image& /*TODO#i72485# rHighContrastStaticImage*/ ) :
-
- SvTreeListBox( pParent, rResId )
+ const Image& rNormalStaticImage )
+ : SvTreeListBox( pParent, rResId )
{
Init_Impl();
@@ -275,3 +274,4 @@ SvLBoxEntry* SvxCheckListBox::InsertEntry( const XubString& rText, SvLBoxEntry*
return SvTreeListBox::InsertEntry( rText, pParent, bChildsOnDemand, nPos, pUserData, eButtonKind );
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/connctrl.cxx b/svx/source/dialog/connctrl.cxx
index be1a2d4528..3532ca6526 100644
--- a/svx/source/dialog/connctrl.cxx
+++ b/svx/source/dialog/connctrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -385,3 +386,4 @@ void SvxXConnectionPreview::DataChanged( const DataChangedEvent& rDCEvt )
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/contdlg.hrc b/svx/source/dialog/contdlg.hrc
index bf3bc84267..a58995d4a6 100644
--- a/svx/source/dialog/contdlg.hrc
+++ b/svx/source/dialog/contdlg.hrc
@@ -65,7 +65,6 @@
#define STB_STATUS 1
#define CD_IMAPDLG 1300
-#define CDH_IMAPDLG 1301
/******************************************************************************/
diff --git a/svx/source/dialog/contdlg.src b/svx/source/dialog/contdlg.src
index 16040d380a..6a81f513de 100644
--- a/svx/source/dialog/contdlg.src
+++ b/svx/source/dialog/contdlg.src
@@ -225,30 +225,29 @@ FloatingWindow RID_SVXDLG_CONTOUR
MASKCOLOR
CONTOURDLG_IDLIST
};
- ImageList CDH_IMAPDLG
- {
- Prefix = "cdh";
- MASKCOLOR
- CONTOURDLG_IDLIST
- };
};
+
/******************************************************************************/
String STR_CONTOURDLG_MODIFY
{
Text [ en-US ] = "The contour has been modified.\nDo you want to save the changes?" ;
};
+
String STR_CONTOURDLG_NEWPIPETTE
{
Text [ en-US ] = "Do you want to create a new contour?" ;
};
+
String STR_CONTOURDLG_WORKPLACE
{
Text [ en-US ] = "Setting a new workspace will\ncause the contour to be deleted.\nAre you sure you want to continue?" ;
};
+
String STR_CONTOURDLG_LINKED
{
Text [ en-US ] = "This graphic object is linked to the document. Do you want to unlink the graphics in order to edit it?" ;
};
+
/******************************************************************************/
diff --git a/svx/source/dialog/contimp.hxx b/svx/source/dialog/contimp.hxx
index 3689d19935..d6636c36e7 100644
--- a/svx/source/dialog/contimp.hxx
+++ b/svx/source/dialog/contimp.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef _CONTIMP_HXX_
#define _CONTIMP_HXX_
-#ifndef _CONTDLG_HXX
#include <svx/contdlg.hxx>
-#endif
#include "contwnd.hxx"
#include <vcl/toolbox.hxx>
#include <vcl/status.hxx>
@@ -68,7 +67,6 @@ class SvxSuperContourDlg : public SvxContourDlg
BOOL bUpdateGraphicLinked;
BOOL bGraphicLinked;
ImageList maImageList;
- ImageList maImageListH;
virtual void Resize();
virtual BOOL Close();
@@ -125,3 +123,4 @@ public:
#endif // _CONTIMP_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/contwnd.cxx b/svx/source/dialog/contwnd.cxx
index 43784ebbf7..b518d24431 100644
--- a/svx/source/dialog/contwnd.cxx
+++ b/svx/source/dialog/contwnd.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -356,3 +357,5 @@ void ContourWindow::Paint( const Rectangle& rRect )
}
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/contwnd.hxx b/svx/source/dialog/contwnd.hxx
index 43babce95e..51dbd51e98 100644
--- a/svx/source/dialog/contwnd.hxx
+++ b/svx/source/dialog/contwnd.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -88,3 +89,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/ctredlin.cxx b/svx/source/dialog/ctredlin.cxx
index b5e28ab6cf..c53a6344ef 100644
--- a/svx/source/dialog/ctredlin.cxx
+++ b/svx/source/dialog/ctredlin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -826,12 +827,8 @@ SvxTPFilter::SvxTPFilter( Window * pParent)
aStrMyName ( SVX_RES( STR_FILTER) ),
bModified (FALSE)
{
- Image aImgTimeHC( SVX_RES( IMG_TIME_H ) );
FreeResource();
- aIbClock.SetModeImage( aImgTimeHC, BMP_COLOR_HIGHCONTRAST );
- aIbClock2.SetModeImage( aImgTimeHC, BMP_COLOR_HIGHCONTRAST );
-
aDfDate.SetShowDateCentury( TRUE );
aDfDate2.SetShowDateCentury( TRUE );
@@ -1529,3 +1526,4 @@ SvxRedlinTable* SvxAcceptChgCtr::GetViewTable()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/ctredlin.hrc b/svx/source/dialog/ctredlin.hrc
index cba699d839..bb4c6cbaf9 100644
--- a/svx/source/dialog/ctredlin.hrc
+++ b/svx/source/dialog/ctredlin.hrc
@@ -50,7 +50,6 @@
#define LB_ACTION 18
#define CB_COMMENT 19
#define ED_COMMENT 20
-#define IMG_TIME_H 30
#define HG_VIEW 1
#define DG_VIEW 2
@@ -67,4 +66,3 @@
#define STR_TITLE4 4
#define STR_TITLE5 5
//
-
diff --git a/svx/source/dialog/ctredlin.src b/svx/source/dialog/ctredlin.src
index 3ca9f10480..c4ec0abab4 100644
--- a/svx/source/dialog/ctredlin.src
+++ b/svx/source/dialog/ctredlin.src
@@ -249,11 +249,6 @@ TabPage SID_REDLIN_FILTER_PAGE
Size = MAP_APPFONT ( 178 , 12 ) ;
TabStop = TRUE ;
};
- Image IMG_TIME_H
- {
- ImageBitmap = Bitmap { File = "time_h.bmp" ; };
- MASKCOLOR
- };
};
TabPage SID_REDLIN_VIEW_PAGE
{
diff --git a/svx/source/dialog/databaseregistrationui.cxx b/svx/source/dialog/databaseregistrationui.cxx
index 2d807f7b39..9afc8a4598 100644
--- a/svx/source/dialog/databaseregistrationui.cxx
+++ b/svx/source/dialog/databaseregistrationui.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,22 +32,15 @@
// === includes (declaration) ============================================
#include "svx/databaseregistrationui.hxx"
-// === includes (UNO) ====================================================
-// === /includes (UNO) ===================================================
-
// === includes (project) ================================================
#include <svx/svxdlg.hxx>
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
-//#include "connpooloptions.hxx"
-// === /includes (project) ===============================================
// === includes (global) =================================================
#include <sfx2/app.hxx>
#include <svl/itemset.hxx>
#include <vcl/msgbox.hxx>
-// === /includes (global) ================================================
+
namespace svx
{
@@ -67,3 +61,5 @@ namespace svx
}
} // namespace svx
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/dialcontrol.cxx b/svx/source/dialog/dialcontrol.cxx
index bd202fead1..f7dba318e5 100644
--- a/svx/source/dialog/dialcontrol.cxx
+++ b/svx/source/dialog/dialcontrol.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -76,6 +77,8 @@ private:
DialControlBmp::DialControlBmp( Window& rParent ) :
VirtualDevice( rParent, 0, 0 ),
mrParent( rParent ),
+ mnCenterX(0),
+ mnCenterY(0),
mbEnabled( true )
{
EnableRTL( FALSE );
@@ -265,6 +268,8 @@ DialControl_Impl::DialControl_Impl( Window& rParent ) :
maBmpBuffered( rParent ),
mpLinkField( 0 ),
mnAngle( 0 ),
+ mnCenterX( 0 ),
+ mnCenterY( 0 ),
mbNoRot( false )
{
}
@@ -570,3 +575,4 @@ void DialControlWrapper::SetControlValue( sal_Int32 nValue )
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/dialmgr.cxx b/svx/source/dialog/dialmgr.cxx
index d95dffb514..b2d0ba368a 100644
--- a/svx/source/dialog/dialmgr.cxx
+++ b/svx/source/dialog/dialmgr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,3 +53,5 @@ ResMgr* DialogsResMgr::GetResMgr()
return pResMgr;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/dlgctl3d.cxx b/svx/source/dialog/dlgctl3d.cxx
index 9d6644f5fb..a23c311fc2 100644
--- a/svx/source/dialog/dlgctl3d.cxx
+++ b/svx/source/dialog/dlgctl3d.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -1321,3 +1322,5 @@ IMPL_LINK( SvxLightCtl3D, InternalSelectionChange, void*, EMPTYARG)
//////////////////////////////////////////////////////////////////////////////
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/dlgctrl.cxx b/svx/source/dialog/dlgctrl.cxx
index d19e04dd93..6efc91d3c6 100644
--- a/svx/source/dialog/dlgctrl.cxx
+++ b/svx/source/dialog/dlgctrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
// include ---------------------------------------------------------------
#include <tools/shl.hxx>
-#ifndef _APP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
#include <svx/xtable.hxx>
#include <svx/xpool.hxx>
@@ -2285,3 +2284,5 @@ void SvxXShadowPreview::Paint( const Rectangle& )
// -----------------------------------------------------------------------
// eof
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/dlgutil.cxx b/svx/source/dialog/dlgutil.cxx
index cdafb622e7..10456fe702 100644
--- a/svx/source/dialog/dlgutil.cxx
+++ b/svx/source/dialog/dlgutil.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,7 +41,7 @@
FieldUnit GetModuleFieldUnit( const SfxItemSet& rSet )
{
- FieldUnit eUnit = FUNIT_INCH;
+ BOOL bUseCharUnit = FALSE;
const SfxPoolItem* pItem = NULL;
if ( SFX_ITEM_SET == rSet.GetItemState( SID_ATTR_METRIC, FALSE, &pItem ) )
eUnit = (FieldUnit)( (const SfxUInt16Item*)pItem )->GetValue();
@@ -53,3 +54,4 @@ FieldUnit GetModuleFieldUnit( const SfxItemSet& rSet )
return eUnit;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/docrecovery.cxx b/svx/source/dialog/docrecovery.cxx
index 3aa4ec8daa..a940f22da3 100644
--- a/svx/source/dialog/docrecovery.cxx
+++ b/svx/source/dialog/docrecovery.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,8 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_svx.hxx"
-#include <svx/dialmgr.hxx>
+#include <sal/macros.h>
+
+#include <svx/dialmgr.hxx>
#include <svx/dialogs.hrc>
#include "docrecovery.hxx"
#include "docrecovery.hrc"
@@ -44,14 +47,10 @@
#include <rtl/ustrbuf.hxx>
#include <vcl/scrbar.hxx>
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/unohlp.hxx>
-#endif
-//#include "com/sun/star/lang/XMultiServiceFactory.hpp"
#include <com/sun/star/task/XStatusIndicatorFactory.hpp>
#include <com/sun/star/lang/XInitialization.hpp>
-//#include <com/sun/star/beans/PropertyValue.hpp>
#include <com/sun/star/beans/NamedValue.hpp>
#include <com/sun/star/util/URL.hpp>
#include <com/sun/star/util/XURLTransformer.hpp>
@@ -100,7 +99,7 @@ void TabDialog4Recovery::addTabPage(IExtendedTabPage* pPage)
//===============================================
short TabDialog4Recovery::Execute()
{
- ::vos::OGuard aLock(Application::GetSolarMutex());
+ ::SolarMutexGuard aLock;
Show();
m_pActualPage = m_lTabPages.begin();
@@ -549,8 +548,7 @@ void SAL_CALL RecoveryCore::statusChanged(const css::frame::FeatureStateEvent& a
if (!sURL.Len())
sURL = aNew.TemplateURL;
INetURLObject aURL(sURL);
- aNew.StandardImage = SvFileInformationManager::GetFileImage(aURL, false, false);
- aNew.HCImage = SvFileInformationManager::GetFileImage(aURL, false, true );
+ aNew.StandardImage = SvFileInformationManager::GetFileImage(aURL, false);
/* set the right UI state for this item to NOT_RECOVERED_YET ... because nDocState shows the state of
the last emergency save operation before and is interessting for the used recovery core service only ...
@@ -559,7 +557,7 @@ void SAL_CALL RecoveryCore::statusChanged(const css::frame::FeatureStateEvent& a
aNew.RecoveryState = E_NOT_RECOVERED_YET;
// patch DisplayName! Because the document title contain more then the file name ...
- sal_Int32 i = aNew.DisplayName.indexOf(::rtl::OUString::createFromAscii(" - "));
+ sal_Int32 i = aNew.DisplayName.indexOf(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" - ")));
if (i > 0)
aNew.DisplayName = aNew.DisplayName.copy(0, i);
@@ -775,7 +773,6 @@ SaveDialog::SaveDialog(Window* pParent,
m_aTitleFT.SetFont(aFont);
m_aOkBtn.SetClickHdl( LINK( this, SaveDialog, OKButtonHdl ) );
-// m_aFileListLB.EnableInput( sal_False );
m_aFileListLB.SetControlBackground( rStyleSettings.GetDialogColor() );
// fill listbox with current open documents
@@ -808,7 +805,7 @@ IMPL_LINK( SaveDialog, OKButtonHdl, void*, EMPTYARG )
//===============================================
short SaveDialog::execute()
{
- ::vos::OGuard aLock(Application::GetSolarMutex());
+ ::SolarMutexGuard aLock;
// wait for user input "OK"
m_nResult = DLG_RET_UNKNOWN;
@@ -848,7 +845,6 @@ SaveProgressDialog::SaveProgressDialog(Window* pParent,
FreeResource();
PluginProgress* pProgress = new PluginProgress( &m_aProgrParent, pCore->getSMGR() );
m_xProgress = css::uno::Reference< css::task::XStatusIndicator >(static_cast< css::task::XStatusIndicator* >(pProgress), css::uno::UNO_QUERY_THROW);
-// m_aProgrBaseTxt = m_aProgrFT.GetText();
}
//===============================================
@@ -859,7 +855,7 @@ SaveProgressDialog::~SaveProgressDialog()
//===============================================
short SaveProgressDialog::Execute()
{
- ::vos::OGuard aLock(Application::GetSolarMutex());
+ ::SolarMutexGuard aLock;
m_pCore->setProgressHandler(m_xProgress);
m_pCore->setUpdateListener(this);
@@ -914,16 +910,12 @@ void RecovDocListEntry::Paint(const Point& aPos ,
const String* pTxt = 0;
RecovDocList* pList = static_cast< RecovDocList* >(&aDevice);
- BOOL bHC = aDevice.GetSettings().GetStyleSettings().GetHighContrastMode();
-
TURLInfo* pInfo = (TURLInfo*)pEntry->GetUserData();
switch(pInfo->RecoveryState)
{
case E_SUCCESSFULLY_RECOVERED :
{
pImg = &pList->m_aGreenCheckImg;
- if (bHC)
- pImg = &pList->m_aGreenCheckImgHC;
pTxt = &pList->m_aSuccessRecovStr;
}
break;
@@ -931,8 +923,6 @@ void RecovDocListEntry::Paint(const Point& aPos ,
case E_ORIGINAL_DOCUMENT_RECOVERED : // TODO must be renamed into ORIGINAL DOCUMENT recovered! Because its marked as yellow
{
pImg = &pList->m_aYellowCheckImg;
- if (bHC)
- pImg = &pList->m_aYellowCheckImgHC;
pTxt = &pList->m_aOrigDocRecovStr;
}
break;
@@ -940,8 +930,6 @@ void RecovDocListEntry::Paint(const Point& aPos ,
case E_RECOVERY_FAILED :
{
pImg = &pList->m_aRedCrossImg;
- if (bHC)
- pImg = &pList->m_aRedCrossImgHC;
pTxt = &pList->m_aRecovFailedStr;
}
break;
@@ -981,9 +969,6 @@ RecovDocList::RecovDocList( Window* pParent,
, m_aGreenCheckImg ( ResId(IMG_GREENCHECK,*rResId.GetResMgr() ) )
, m_aYellowCheckImg ( ResId(IMG_YELLOWCHECK,*rResId.GetResMgr() ) )
, m_aRedCrossImg ( ResId(IMG_REDCROSS,*rResId.GetResMgr() ) )
- , m_aGreenCheckImgHC ( ResId(IMG_GREENCHECK_HC,*rResId.GetResMgr() ) )
- , m_aYellowCheckImgHC ( ResId(IMG_YELLOWCHECK_HC,*rResId.GetResMgr() ) )
- , m_aRedCrossImgHC ( ResId(IMG_REDCROSS_HC,*rResId.GetResMgr() ) )
, m_aSuccessRecovStr ( ResId(STR_SUCCESSRECOV,*rResId.GetResMgr() ) )
, m_aOrigDocRecovStr ( ResId(STR_ORIGDOCRECOV,*rResId.GetResMgr() ) )
, m_aRecovFailedStr ( ResId(STR_RECOVFAILED,*rResId.GetResMgr() ) )
@@ -1104,8 +1089,6 @@ RecoveryDialog::RecoveryDialog(Window* pParent,
sName += impl_getStatusString( rInfo );
SvLBoxEntry* pEntry = m_aFileListLB.InsertEntry(sName, rInfo.StandardImage, rInfo.StandardImage);
pEntry->SetUserData((void*)&rInfo);
- m_aFileListLB.SetExpandedEntryBmp (pEntry, rInfo.HCImage, BMP_COLOR_HIGHCONTRAST);
- m_aFileListLB.SetCollapsedEntryBmp(pEntry, rInfo.HCImage, BMP_COLOR_HIGHCONTRAST);
}
// mark first item
@@ -1122,7 +1105,7 @@ RecoveryDialog::~RecoveryDialog()
//===============================================
short RecoveryDialog::execute()
{
- ::vos::OGuard aSolarLock(Application::GetSolarMutex());
+ ::SolarMutexGuard aSolarLock;
switch(m_eRecoveryState)
{
@@ -1658,7 +1641,7 @@ void BrokenRecoveryDialog::impl_askForSavePath()
short ErrorRepWelcomeDialog::execute()
{
- ::vos::OGuard aLock(Application::GetSolarMutex());
+ ::SolarMutexGuard aLock;
Show();
m_nResult = DLG_RET_UNKNOWN;
while(m_nResult == DLG_RET_UNKNOWN)
@@ -1768,7 +1751,7 @@ void BrokenRecoveryDialog::impl_askForSavePath()
short ErrorRepSendDialog::execute()
{
- ::vos::OGuard aLock(Application::GetSolarMutex());
+ ::SolarMutexGuard aLock;
Show();
m_nResult = DLG_RET_UNKNOWN;
while(m_nResult == DLG_RET_UNKNOWN)
@@ -1865,7 +1848,7 @@ void BrokenRecoveryDialog::impl_askForSavePath()
}
// loop through all the other windows and adjust their size
- for ( ; i < sizeof( pWins ) / sizeof( pWins[ 0 ] ); ++i, ++pCurrent )
+ for ( ; i < SAL_N_ELEMENTS( pWins ); ++i, ++pCurrent )
{
Size aSize = (*pCurrent)->GetSizePixel();
aSize.Width() -= nDelta;
@@ -1936,7 +1919,7 @@ void BrokenRecoveryDialog::impl_askForSavePath()
&maProxyServerEd, &maProxyPortFT, &maProxyPortEd, &maDescriptionFT
};
Window** pCurrent = pWins;
- for ( sal_uInt32 i = 0; i < sizeof( pWins ) / sizeof( pWins[ 0 ] ); ++i, ++pCurrent )
+ for ( sal_uInt32 i = 0; i < SAL_N_ELEMENTS( pWins ); ++i, ++pCurrent )
{
Point aPos = (*pCurrent)->GetPosPixel();
aPos.Y() -= nDelta;
@@ -2036,16 +2019,16 @@ void BrokenRecoveryDialog::impl_askForSavePath()
{
#if defined(WNT) || defined(OS2)
- OUString ustrValue = OUString::createFromAscii("${$BRAND_BASE_DIR/program/bootstrap.ini:UserInstallation}");
+ OUString ustrValue = OUString(RTL_CONSTASCII_USTRINGPARAM("${$BRAND_BASE_DIR/program/bootstrap.ini:UserInstallation}"));
#elif defined( MACOSX )
- OUString ustrValue = OUString::createFromAscii("~");
+ OUString ustrValue = OUString(RTL_CONSTASCII_USTRINGPARAM("~"));
#else
- OUString ustrValue = OUString::createFromAscii("$SYSUSERCONFIG");
+ OUString ustrValue = OUString(RTL_CONSTASCII_USTRINGPARAM("$SYSUSERCONFIG"));
#endif
Bootstrap::expandMacros( ustrValue );
#if defined(WNT) || defined(OS2)
- ustrValue += OUString::createFromAscii("/user/crashdata");
+ ustrValue += OUString(RTL_CONSTASCII_USTRINGPARAM("/user/crashdata"));
#endif
return ustrValue;
}
@@ -2096,7 +2079,7 @@ void BrokenRecoveryDialog::impl_askForSavePath()
::osl::File aFile( rURL );
printf( "Loading %s:", OString( rURL.getStr(), rURL.getLength(), osl_getThreadTextEncoding() ).getStr() );
- if ( ::osl::FileBase::E_None == aFile.open( OpenFlag_Read ) )
+ if ( ::osl::FileBase::E_None == aFile.open( osl_File_OpenFlag_Read ) )
{
::rtl::OString aContent;
::osl::FileBase::RC result;
@@ -2179,3 +2162,4 @@ void BrokenRecoveryDialog::impl_askForSavePath()
} // namespace DocRecovery
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/docrecovery.hrc b/svx/source/dialog/docrecovery.hrc
index ae6ddc84bc..4a5e22afce 100644
--- a/svx/source/dialog/docrecovery.hrc
+++ b/svx/source/dialog/docrecovery.hrc
@@ -105,9 +105,6 @@
#define IMG_GREENCHECK 14
#define IMG_YELLOWCHECK 15
#define IMG_REDCROSS 16
-#define IMG_GREENCHECK_HC 17
-#define IMG_YELLOWCHECK_HC 18
-#define IMG_REDCROSS_HC 19
#define STR_SUCCESSRECOV 20
#define STR_ORIGDOCRECOV 21
#define STR_RECOVFAILED 22
diff --git a/svx/source/dialog/docrecovery.src b/svx/source/dialog/docrecovery.src
index e73f4a919e..e8421ad2b4 100644
--- a/svx/source/dialog/docrecovery.src
+++ b/svx/source/dialog/docrecovery.src
@@ -213,26 +213,14 @@ TabPage RID_SVXPAGE_DOCRECOVERY_RECOVER
{
ImageBitmap = Bitmap { File = "nu01.png"; };
};
- Image IMG_GREENCHECK_HC
- {
- ImageBitmap = Bitmap { File = "nuh01.png"; };
- };
Image IMG_YELLOWCHECK
{
ImageBitmap = Bitmap { File = "nu04.png"; };
};
- Image IMG_YELLOWCHECK_HC
- {
- ImageBitmap = Bitmap { File = "nuh04.png"; };
- };
Image IMG_REDCROSS
{
ImageBitmap = Bitmap { File = "nu02.png"; };
};
- Image IMG_REDCROSS_HC
- {
- ImageBitmap = Bitmap { File = "nuh02.png"; };
- };
String STR_SUCCESSRECOV
{
Text[ en-US ] = "Successfully recovered";
diff --git a/svx/source/dialog/fntctrl.cxx b/svx/source/dialog/fntctrl.cxx
index db4459c95f..683fa038a8 100644
--- a/svx/source/dialog/fntctrl.cxx
+++ b/svx/source/dialog/fntctrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,9 +40,7 @@
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <comphelper/processfactory.hxx>
-#ifndef _COM_SUN_STAR_I18N_SCRIPTTYPE_HDL_
#include <com/sun/star/i18n/ScriptType.hdl>
-#endif
#ifndef _SVSTDARR_HXX
#define _SVSTDARR_USHORTS
@@ -148,7 +147,7 @@ class FontPrevWin_Impl
public:
inline FontPrevWin_Impl() :
pPrinter( NULL ), bDelPrinter( FALSE ),
- pColor( NULL ), pBackColor( 0 ),
+ pColor( NULL ), pBackColor( 0 ), nAscent( 0 ),
cStartBracket( 0 ), cEndBracket( 0 ), nFontWidthScale( 100 ),
bSelection( FALSE ), bGetSelection( FALSE ), bUseResText( FALSE ),
bTwoLines( FALSE ),
@@ -224,7 +223,7 @@ void FontPrevWin_Impl::_CheckScript()
{
Reference< XMultiServiceFactory > xMSF = ::comphelper::getProcessServiceFactory();
xBreak = Reference< XBreakIterator >(xMSF->createInstance(
- ::rtl::OUString::createFromAscii( "com.sun.star.i18n.BreakIterator" ) ),UNO_QUERY);
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.BreakIterator")) ),UNO_QUERY);
}
if( xBreak.is() )
{
@@ -803,23 +802,17 @@ void SvxFontPrevWindow::Paint( const Rectangle& )
pImpl->DrawPrev( this, pPrinter, aTmpPoint, rFont );
}
}
-/* -----------------------------04.12.00 16:26--------------------------------
- ---------------------------------------------------------------------------*/
BOOL SvxFontPrevWindow::IsTwoLines() const
{
return pImpl->bTwoLines;
}
-/* -----------------------------04.12.00 16:26--------------------------------
- ---------------------------------------------------------------------------*/
void SvxFontPrevWindow::SetTwoLines(BOOL bSet)
{
pImpl->bTwoLines = bSet;}
-/* -----------------------------04.12.00 16:26--------------------------------
- ---------------------------------------------------------------------------*/
void SvxFontPrevWindow::SetBrackets(sal_Unicode cStart, sal_Unicode cEnd)
{
pImpl->cStartBracket = cStart;
@@ -849,3 +842,5 @@ void SvxFontPrevWindow::AutoCorrectFontColor( void )
if( COL_AUTO == pImpl->aCTLFont.GetColor().GetColor() )
pImpl->aCTLFont.SetColor( aFontColor );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/fontlb.cxx b/svx/source/dialog/fontlb.cxx
index a7f37eef6b..f8e3192572 100644
--- a/svx/source/dialog/fontlb.cxx
+++ b/svx/source/dialog/fontlb.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -187,3 +188,4 @@ IMPL_GET_WINDOW (SvxFontListBox);*/
// ============================================================================
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/fontwork.cxx b/svx/source/dialog/fontwork.cxx
index b0419dbd04..e4b4b65b15 100644
--- a/svx/source/dialog/fontwork.cxx
+++ b/svx/source/dialog/fontwork.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -248,7 +249,6 @@ SvxFontWorkDialog::SvxFontWorkDialog( SfxBindings *pBindinx,
nSaveShadowSize (100),
maImageList (ResId(IL_FONTWORK,*rResId.GetResMgr())),
- maImageListH (ResId(ILH_FONTWORK,*rResId.GetResMgr())),
pColorTable (NULL)
{
@@ -710,7 +710,7 @@ void SvxFontWorkDialog::SetShadowXVal_Impl(const XFormTextShadowXValItem* pItem)
{
// #i19251#
// INT32 nValue = pItem->GetValue();
-
+
// #i19251#
// The two involved fields/items are used double and contain/give different
// values regarding to the access method. Thus, here we need to separate the access
@@ -1007,7 +1007,7 @@ void SvxFontWorkDialog::CreateStdFormObj(SdrView& rView, SdrPageView& rPV,
//-/ rOldObj.TakeAttributes(aAttr, TRUE, FALSE);
aAttr.Put(rOldObj.GetMergedItemSet());
-
+
const XFormTextStdFormItem& rOldForm = (const XFormTextStdFormItem&)
aAttr.Get(XATTR_FORMTXTSTDFORM);
@@ -1220,30 +1220,16 @@ void SvxFontWorkDialog::DataChanged( const DataChangedEvent& rDCEvt )
SfxDockingWindow::DataChanged( rDCEvt );
}
-/* -----------------------------08.05.2002 14:28------------------------------
- ---------------------------------------------------------------------------*/
void SvxFontWorkDialog::ApplyImageList()
{
- bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
-
ResMgr* _pMgr = &DIALOG_MGR();
- USHORT nBitmapResId = bHighContrast ? RID_SVXBMP_FONTWORK_FORM1_H : RID_SVXBMP_FONTWORK_FORM1;
+ USHORT nBitmapResId = RID_SVXBMP_FONTWORK_FORM1;
USHORT nTextResId = RID_SVXSTR_FONTWORK_FORM1;
bool bInit = aFormSet.GetItemCount() == 0;
- if( bInit )
- {
-/*
- Size aSize( aTbxStyle.CalcWindowSizePixel() );
- Bitmap aBmp(ResId(RID_SVXBMP_FONTWORK_FORM1,_pMgr));
- aSize.Height() = aFormSet.CalcWindowSizePixel(aBmp.GetSizePixel()).Height() + 2;
- aFormSet.SetSizePixel(aSize);
-*/
- }
-
USHORT i;
for( i = 1; i < 13; i++, nTextResId++, nBitmapResId++ )
{
@@ -1258,7 +1244,7 @@ void SvxFontWorkDialog::ApplyImageList()
}
}
- ImageList& rImgLst = bHighContrast ? maImageListH : maImageList;
+ ImageList& rImgLst = maImageList;
aTbxStyle.SetImageList( rImgLst );
aTbxAdjust.SetImageList( rImgLst );
@@ -1281,3 +1267,5 @@ void SvxFontWorkDialog::ApplyImageList()
aFbTextStart.SetImage( rImgLst.GetImage( TBI_TEXTSTART ) );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/fontwork.hrc b/svx/source/dialog/fontwork.hrc
index a664dd3ce6..bce6cfa209 100644
--- a/svx/source/dialog/fontwork.hrc
+++ b/svx/source/dialog/fontwork.hrc
@@ -40,7 +40,6 @@
#define CLB_SHADOW_COLOR 1
#define IL_FONTWORK 1200
-#define ILH_FONTWORK 1201
// the following ids are also used to identify the
// bitmaps for the image list
diff --git a/svx/source/dialog/fontwork.src b/svx/source/dialog/fontwork.src
index 01cf483a67..06f2a2b519 100644
--- a/svx/source/dialog/fontwork.src
+++ b/svx/source/dialog/fontwork.src
@@ -350,12 +350,6 @@ DockingWindow RID_SVXDLG_FONTWORK
MaskColor = IMAGE_STDBTN_COLOR ;
FONTWORK_IDLIST
};
- ImageList ILH_FONTWORK
- {
- Prefix = "fwh";
- MaskColor = IMAGE_STDBTN_COLOR ;
- FONTWORK_IDLIST
- };
};
// Bitmaps ---------------------------------------------------------------
Bitmap RID_SVXBMP_FONTWORK_FORM1
@@ -407,55 +401,6 @@ Bitmap RID_SVXBMP_FONTWORK_FORM12
File = "fwbuttn4.bmp" ;
};
-Bitmap RID_SVXBMP_FONTWORK_FORM1_H
-{
- File = "fwthcirc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM2_H
-{
- File = "fwbhcirc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM3_H
-{
- File = "fwlhcirc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM4_H
-{
- File = "fwrhcirc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM5_H
-{
- File = "fwtoparc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM6_H
-{
- File = "fwbotarc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM7_H
-{
- File = "fwlftarc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM8_H
-{
- File = "fwrgtarc_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM9_H
-{
- File = "fwbuttn1_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM10_H
-{
- File = "fwbuttn2_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM11_H
-{
- File = "fwbuttn3_h.bmp" ;
-};
-Bitmap RID_SVXBMP_FONTWORK_FORM12_H
-{
- File = "fwbuttn4_h.bmp" ;
-};
-
// Strings ---------------------------------------------------------------
String RID_SVXSTR_FONTWORK_FORM1
{
diff --git a/svx/source/dialog/framelink.cxx b/svx/source/dialog/framelink.cxx
index 06fc47828b..94c2d021b1 100644
--- a/svx/source/dialog/framelink.cxx
+++ b/svx/source/dialog/framelink.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,6 +49,9 @@
#if SVX_FRAME_USE_LINEINFO
#include <vcl/lineinfo.hxx>
+#else
+#include <basegfx/polygon/b2dpolygon.hxx>
+#include <basegfx/polygon/b2dpolygontools.hxx>
#endif
namespace svx {
@@ -389,7 +393,7 @@ void lclLinkLeftEnd_Single(
// don't overdraw vertical borders with equal width
lclGetBehindEnd( rLFromT ) :
// take leftmost start of both secondary lines (#46488#)
- rResult.mnOffs1 = std::min( lclGetSecnBeg( rLFromT ), lclGetSecnBeg( rLFromB ) );
+ std::min( lclGetSecnBeg( rLFromT ), lclGetSecnBeg( rLFromB ) );
// single border with equal width coming from left
else if( !rLFromL.Secn() && (rLFromL.Prim() == rBorder.Prim()) )
@@ -608,44 +612,6 @@ void lclLinkVerFrameBorder(
// ============================================================================
-#if 0
-// Not used anymore, but not deleted for possible future usage.
-
-/** Returns the relative Y offset of the intercept point of 2 diagonal borders.
-
- @param nTLBROffs
- Width offset (sub units) across the top-left to bottom-right frame border.
- @param fTLBRAngle
- Inner angle between horizontal and top-left to bottom-right frame border.
- @param nBLTROffs
- Width offset (sub units) across the bottom-left to top-right frame border.
- @param fBLTRAngle
- Inner angle between horizontal and bottom-left to top-right frame border.
- @return
- Offset (sub units) relative to the Y position of the centered intercept
- point of both diagonal frame borders.
- */
-long lclGetDiagDiagOffset( long nTLBROffs, double fTLBRAngle, long nBLTROffs, double fBLTRAngle )
-{
- double fASin = sin( fTLBRAngle );
- double fACos = cos( fTLBRAngle );
- double fAX = -nTLBROffs * fASin;
- double fAY = nTLBROffs * fACos;
- double fRAX = fACos;
- double fRAY = fASin;
-
- double fBSin = sin( fBLTRAngle );
- double fBCos = cos( fBLTRAngle );
- double fBX = nBLTROffs * fBSin;
- double fBY = nBLTROffs * fBCos;
- double fRBX = fBCos;
- double fRBY = -fBSin;
-
- double fKA = (fRBX * (fBY - fAY) - fRBY * (fBX - fAX)) / (fRBX * fRAY - fRAX * fRBY);
- return lclD2L( fAY + fKA * fRAY );
-}
-#endif
-
// ----------------------------------------------------------------------------
// Linking of diagonal frame borders.
@@ -755,7 +721,7 @@ inline Polygon lclCreatePolygon( const PointVec& rPoints )
Polygon lclCreatePolygon( const Point& rP1, const Point& rP2, const Point& rP3, const Point& rP4 )
{
PointVec aPoints;
- aPoints.reserve( 4 );
+ aPoints.reserve( 2 );
aPoints.push_back( rP1 );
aPoints.push_back( rP2 );
aPoints.push_back( rP3 );
@@ -776,12 +742,6 @@ Polygon lclCreatePolygon( const Point& rP1, const Point& rP2, const Point& rP3,
return lclCreatePolygon( aPoints );
}
-/** Returns a polygon constructed from the two passed line positions. */
-inline Polygon lclCreatePolygon( const LinePoints& rPoints1, const LinePoints& rPoints2 )
-{
- return lclCreatePolygon( rPoints1.maBeg, rPoints1.maEnd, rPoints2.maEnd, rPoints2.maBeg );
-}
-
/** Sets the color of the passed frame style to the output device.
Sets the line color and fill color in the output device.
@@ -803,73 +763,6 @@ void lclSetColorToOutDev( OutputDevice& rDev, const Style& rStyle, const Color*
}
// ----------------------------------------------------------------------------
-// Generic drawing functions.
-
-/** Draws a thin (1 pixel wide) line, optionally dotted, into the passed output device. */
-void lclDrawThinLine( OutputDevice& rDev, const Point& rBeg, const Point& rEnd, bool bDotted )
-{
-#if SVX_FRAME_USE_LINEINFO
- if( bDotted && (rBeg != rEnd) )
- {
-// using LineInfo for dotted lines looks ugly and does not work well for diagonal lines
- LineInfo aLineInfo( LINE_DASH, 1 );
- aLineInfo.SetDotCount( 1 );
- aLineInfo.SetDotLen( 1 );
- aLineInfo.SetDistance( 3 );
- rDev.DrawLine( rBeg, rEnd, aLineInfo );
- }
-#else
- Point aBeg( rDev.LogicToPixel( rBeg ) );
- Point aEnd( rDev.LogicToPixel( rEnd ) );
- if( bDotted && (aBeg != aEnd) )
- {
- bool bHor = Abs( aEnd.X() - aBeg.X() ) > Abs( aEnd.Y() - aBeg.Y() );
- const Point& rBegPos( bHor ? ((aBeg.X() < aEnd.X()) ? aBeg : aEnd) : ((aBeg.Y() < aEnd.Y()) ? aBeg : aEnd ) );
- const Point& rEndPos( (rBegPos == aBeg) ? aEnd : aBeg );
-
- long nAlongBeg = bHor ? rBegPos.X() : rBegPos.Y();
- long nAcrssBeg = bHor ? rBegPos.Y() : rBegPos.X();
- long nAlongSize = (bHor ? rEndPos.X() : rEndPos.Y()) - nAlongBeg;
- long nAcrssSize = (bHor ? rEndPos.Y() : rEndPos.X()) - nAcrssBeg;
- double fGradient = static_cast< double >( nAcrssSize ) / nAlongSize;
-
- PointVec aPoints;
- aPoints.reserve( (nAlongSize + 1) / 2 );
- for( long nAlongIdx = 0; nAlongIdx <= nAlongSize; nAlongIdx += 2 )
- {
- long nAl = nAlongBeg + nAlongIdx;
- long nAc = nAcrssBeg + lclD2L( fGradient * nAlongIdx );
- aPoints.push_back( Point( bHor ? nAl : nAc, bHor ? nAc : nAl ) );
- }
-
- rDev.Push( PUSH_MAPMODE );
- rDev.SetMapMode( MAP_PIXEL );
- rDev.DrawPixel( lclCreatePolygon( aPoints ) );
- rDev.Pop(); // map mode
- }
-#endif
- else
- rDev.DrawLine( rBeg, rEnd );
-}
-
-/** Draws a thin (1 pixel wide) line, optionally dotted, into the passed output device. */
-inline void lclDrawThinLine( OutputDevice& rDev, const LinePoints& rPoints, bool bDotted )
-{
- lclDrawThinLine( rDev, rPoints.maBeg, rPoints.maEnd, bDotted );
-}
-
-/** Draws a polygon with four points into the passed output device. */
-inline void lclDrawPolygon( OutputDevice& rDev, const Point& rP1, const Point& rP2, const Point& rP3, const Point& rP4 )
-{
- rDev.DrawPolygon( lclCreatePolygon( rP1, rP2, rP3, rP4 ) );
-}
-
-/** Draws a polygon specified by two borders into the passed output device. */
-inline void lclDrawPolygon( OutputDevice& rDev, const LinePoints& rPoints1, const LinePoints& rPoints2 )
-{
- rDev.DrawPolygon( lclCreatePolygon( rPoints1, rPoints2 ) );
-}
-
// ============================================================================
// Drawing of horizontal frame borders.
@@ -882,16 +775,18 @@ void lclDrawHorLine(
OutputDevice& rDev,
const Point& rLPos, const LineEndResult& rLRes,
const Point& rRPos, const LineEndResult& rRRes,
- long nTOffs, long nBOffs, bool bDotted )
+ long nTOffs, long nBOffs, SvxBorderStyle nDashing )
{
LinePoints aTPoints( rLPos + lclToMapUnit( rLRes.mnOffs1, nTOffs ), rRPos + lclToMapUnit( rRRes.mnOffs1, nTOffs ) );
- if( nTOffs == nBOffs )
- lclDrawThinLine( rDev, aTPoints, bDotted );
- else
- {
- LinePoints aBPoints( rLPos + lclToMapUnit( rLRes.mnOffs2, nBOffs ), rRPos + lclToMapUnit( rRRes.mnOffs2, nBOffs ) );
- lclDrawPolygon( rDev, aTPoints, aBPoints );
- }
+ LinePoints aBPoints( rLPos + lclToMapUnit( rLRes.mnOffs2, nBOffs ), rRPos + lclToMapUnit( rRRes.mnOffs2, nBOffs ) );
+
+ sal_uInt32 nWidth = lclToMapUnit( abs( nTOffs ) ) + lclToMapUnit( abs( nBOffs ) );
+ if ( ( nTOffs >= 0 && nBOffs >= 0 ) || ( nTOffs <= 0 && nBOffs <= 0 ) )
+ nWidth = abs( lclToMapUnit( nTOffs ) - lclToMapUnit( nBOffs ) ) + 1;
+ Point rLMid = ( aTPoints.maBeg + aBPoints.maBeg ) / 2;
+ Point rRMid = ( aTPoints.maEnd + aBPoints.maEnd ) / 2;
+
+ ::svtools::DrawLine( rDev, rLMid, rRMid, nWidth, nDashing );
}
/** Draws a horizontal frame border into the passed output device.
@@ -917,10 +812,10 @@ void lclDrawHorFrameBorder(
{
lclSetColorToOutDev( rDev, rBorder, pForceColor );
lclDrawHorLine( rDev, rLPos, rResult.maBeg.maPrim, rRPos, rResult.maEnd.maPrim,
- lclGetBeg( rBorder ), lclGetPrimEnd( rBorder ), rBorder.Dotted() );
+ lclGetBeg( rBorder ), lclGetPrimEnd( rBorder ), rBorder.Dashing() );
if( rBorder.Secn() )
lclDrawHorLine( rDev, rLPos, rResult.maBeg.maSecn, rRPos, rResult.maEnd.maSecn,
- lclGetSecnBeg( rBorder ), lclGetEnd( rBorder ), rBorder.Dotted() );
+ lclGetSecnBeg( rBorder ), lclGetEnd( rBorder ), rBorder.Dashing() );
rDev.Pop(); // colors
}
}
@@ -937,16 +832,18 @@ void lclDrawVerLine(
OutputDevice& rDev,
const Point& rTPos, const LineEndResult& rTRes,
const Point& rBPos, const LineEndResult& rBRes,
- long nLOffs, long nROffs, bool bDotted )
+ long nLOffs, long nROffs, SvxBorderStyle nDashing )
{
LinePoints aLPoints( rTPos + lclToMapUnit( nLOffs, rTRes.mnOffs1 ), rBPos + lclToMapUnit( nLOffs, rBRes.mnOffs1 ) );
- if( nLOffs == nROffs )
- lclDrawThinLine( rDev, aLPoints, bDotted );
- else
- {
- LinePoints aRPoints( rTPos + lclToMapUnit( nROffs, rTRes.mnOffs2 ), rBPos + lclToMapUnit( nROffs, rBRes.mnOffs2 ) );
- lclDrawPolygon( rDev, aLPoints, aRPoints );
- }
+ LinePoints aRPoints( rTPos + lclToMapUnit( nROffs, rTRes.mnOffs2 ), rBPos + lclToMapUnit( nROffs, rBRes.mnOffs2 ) );
+
+ sal_uInt32 nWidth = lclToMapUnit( abs( nLOffs ) ) + lclToMapUnit( abs( nROffs ) );
+ if ( ( nLOffs >= 0 && nROffs >= 0 ) || ( nLOffs <= 0 && nROffs <= 0 ) )
+ nWidth = abs( lclToMapUnit( nLOffs ) - lclToMapUnit( nROffs ) ) + 1;
+ Point rTMid = ( aLPoints.maBeg + aRPoints.maBeg ) / 2;
+ Point rBMid = ( aLPoints.maEnd + aRPoints.maEnd ) / 2;
+
+ ::svtools::DrawLine( rDev, rTMid, rBMid, nWidth, nDashing );
}
/** Draws a vertical frame border into the passed output device.
@@ -972,10 +869,10 @@ void lclDrawVerFrameBorder(
{
lclSetColorToOutDev( rDev, rBorder, pForceColor );
lclDrawVerLine( rDev, rTPos, rResult.maBeg.maPrim, rBPos, rResult.maEnd.maPrim,
- lclGetBeg( rBorder ), lclGetPrimEnd( rBorder ), rBorder.Dotted() );
+ lclGetBeg( rBorder ), lclGetPrimEnd( rBorder ), rBorder.Dashing() );
if( rBorder.Secn() )
lclDrawVerLine( rDev, rTPos, rResult.maBeg.maSecn, rBPos, rResult.maEnd.maSecn,
- lclGetSecnBeg( rBorder ), lclGetEnd( rBorder ), rBorder.Dotted() );
+ lclGetSecnBeg( rBorder ), lclGetEnd( rBorder ), rBorder.Dashing() );
rDev.Pop(); // colors
}
}
@@ -1108,14 +1005,19 @@ void lclPushCrossingClipRegion( OutputDevice& rDev, const Rectangle& rRect, bool
*/
void lclDrawDiagLine(
OutputDevice& rDev, const Rectangle& rRect, bool bTLBR,
- const DiagLineResult& rResult, long nDiagOffs1, long nDiagOffs2, bool bDotted )
+ const DiagLineResult& rResult, long nDiagOffs1, long nDiagOffs2, SvxBorderStyle nDashing )
{
lclPushDiagClipRect( rDev, rRect, rResult );
LinePoints aLPoints( lclGetDiagLineEnds( rRect, bTLBR, nDiagOffs1 ) );
- if( nDiagOffs1 == nDiagOffs2 )
- lclDrawThinLine( rDev, aLPoints, bDotted );
- else
- lclDrawPolygon( rDev, aLPoints, lclGetDiagLineEnds( rRect, bTLBR, nDiagOffs2 ) );
+ LinePoints aL2Points( lclGetDiagLineEnds( rRect, bTLBR, nDiagOffs2 ) );
+ Point aSMid( ( aLPoints.maBeg + aL2Points.maBeg ) / 2 );
+ Point aEMid( ( aLPoints.maEnd + aL2Points.maEnd ) / 2 );
+
+ sal_uInt32 nWidth = lclToMapUnit( abs( nDiagOffs1 ) ) + lclToMapUnit( abs( nDiagOffs2 ) );
+ if ( ( nDiagOffs1 <= 0 && nDiagOffs2 <= 0 ) || ( nDiagOffs1 >=0 && nDiagOffs2 >=0 ) )
+ nWidth = lclToMapUnit( abs( nDiagOffs1 - nDiagOffs2 ) );
+
+ svtools::DrawLine( rDev, aSMid, aEMid, nWidth, nDashing );
rDev.Pop(); // clipping region
}
@@ -1147,9 +1049,9 @@ void lclDrawDiagFrameBorder(
lclPushCrossingClipRegion( rDev, rRect, bTLBR, rCrossStyle );
lclSetColorToOutDev( rDev, rBorder, pForceColor );
- lclDrawDiagLine( rDev, rRect, bTLBR, rResult.maPrim, lclGetBeg( rBorder ), lclGetPrimEnd( rBorder ), rBorder.Dotted() );
+ lclDrawDiagLine( rDev, rRect, bTLBR, rResult.maPrim, lclGetBeg( rBorder ), lclGetPrimEnd( rBorder ), rBorder.Dashing() );
if( rBorder.Secn() )
- lclDrawDiagLine( rDev, rRect, bTLBR, rResult.maSecn, lclGetSecnBeg( rBorder ), lclGetEnd( rBorder ), rBorder.Dotted() );
+ lclDrawDiagLine( rDev, rRect, bTLBR, rResult.maSecn, lclGetSecnBeg( rBorder ), lclGetEnd( rBorder ), rBorder.Dashing() );
rDev.Pop(); // colors
if( bClip )
@@ -1226,7 +1128,7 @@ void Style::Set( const Color& rColor, sal_uInt16 nP, sal_uInt16 nD, sal_uInt16 n
Set( nP, nD, nS );
}
-void Style::Set( const SvxBorderLine& rBorder, double fScale, sal_uInt16 nMaxWidth, bool bUseDots )
+void Style::Set( const SvxBorderLine& rBorder, double fScale, sal_uInt16 nMaxWidth )
{
maColor = rBorder.GetColor();
@@ -1237,12 +1139,12 @@ void Style::Set( const SvxBorderLine& rBorder, double fScale, sal_uInt16 nMaxWid
if( !nSecn ) // no or single frame border
{
Set( SCALEVALUE( nPrim ), 0, 0 );
- mbDotted = bUseDots && (0 < nPrim) && (nPrim < 10);
+ mnDashing = rBorder.GetStyle();
}
else
{
Set( SCALEVALUE( nPrim ), SCALEVALUE( nDist ), SCALEVALUE( nSecn ) );
- mbDotted = false;
+ mnDashing = SOLID;
// Enlarge the style if distance is too small due to rounding losses.
sal_uInt16 nPixWidth = SCALEVALUE( nPrim + nDist + nSecn );
if( nPixWidth > GetWidth() )
@@ -1275,14 +1177,14 @@ void Style::Set( const SvxBorderLine& rBorder, double fScale, sal_uInt16 nMaxWid
}
}
-void Style::Set( const SvxBorderLine* pBorder, double fScale, sal_uInt16 nMaxWidth, bool bUseDots )
+void Style::Set( const SvxBorderLine* pBorder, double fScale, sal_uInt16 nMaxWidth )
{
if( pBorder )
- Set( *pBorder, fScale, nMaxWidth, bUseDots );
+ Set( *pBorder, fScale, nMaxWidth );
else
{
Clear();
- mbDotted = false;
+ mnDashing = SOLID;
}
}
@@ -1314,7 +1216,8 @@ Style Style::Mirror() const
bool operator==( const Style& rL, const Style& rR )
{
return (rL.Prim() == rR.Prim()) && (rL.Dist() == rR.Dist()) && (rL.Secn() == rR.Secn()) &&
- (rL.GetColor() == rR.GetColor()) && (rL.GetRefMode() == rR.GetRefMode()) && (rL.Dotted() == rR.Dotted());
+ (rL.GetColor() == rR.GetColor()) && (rL.GetRefMode() == rR.GetRefMode()) &&
+ (rL.Dashing() == rR.Dashing());
}
bool operator<( const Style& rL, const Style& rR )
@@ -1331,7 +1234,7 @@ bool operator<( const Style& rL, const Style& rR )
if( (rL.Secn() && rR.Secn()) && (rL.Dist() != rR.Dist()) ) return rL.Dist() > rR.Dist();
// both lines single and 1 unit thick, only one is dotted -> rL<rR, if rL is dotted
- if( (nLW == 1) && (rL.Dotted() != rR.Dotted()) ) return rL.Dotted();
+ if( (nLW == 1) && (rL.Dashing() != rR.Dashing()) ) return rL.Dashing();
// seem to be equal
return false;
@@ -1498,10 +1401,10 @@ void DrawVerFrameBorderSlanted( OutputDevice& rDev,
lclSetColorToOutDev( rDev, aScaled, pForceColor );
lclDrawVerLine( rDev, rTPos, aRes, rBPos, aRes,
- lclGetBeg( aScaled ), lclGetPrimEnd( aScaled ), aScaled.Dotted() );
+ lclGetBeg( aScaled ), lclGetPrimEnd( aScaled ), aScaled.Dashing() );
if( aScaled.Secn() )
lclDrawVerLine( rDev, rTPos, aRes, rBPos, aRes,
- lclGetSecnBeg( aScaled ), lclGetEnd( aScaled ), aScaled.Dotted() );
+ lclGetSecnBeg( aScaled ), lclGetEnd( aScaled ), aScaled.Dashing() );
rDev.Pop(); // colors
}
}
@@ -1529,3 +1432,4 @@ void DrawDiagFrameBorders(
} // namespace frame
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/framelinkarray.cxx b/svx/source/dialog/framelinkarray.cxx
index 273f2e8ce8..e778abca89 100644
--- a/svx/source/dialog/framelinkarray.cxx
+++ b/svx/source/dialog/framelinkarray.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -1245,3 +1246,4 @@ void Array::DrawArray( OutputDevice& rDev, const Color* pForceColor ) const
} // namespace frame
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/frmdirlbox.cxx b/svx/source/dialog/frmdirlbox.cxx
index 89b8f73480..03b1eec8a2 100644
--- a/svx/source/dialog/frmdirlbox.cxx
+++ b/svx/source/dialog/frmdirlbox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -125,3 +126,4 @@ void FrameDirListBoxWrapper::SetControlValue( SvxFrameDirection eValue )
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/frmsel.cxx b/svx/source/dialog/frmsel.cxx
index b562e123b4..867ef9a593 100644
--- a/svx/source/dialog/frmsel.cxx
+++ b/svx/source/dialog/frmsel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,12 +36,8 @@
#include "AccessibleFrameSelector.hxx"
#include <svx/dialmgr.hxx>
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
-#ifndef SVX_FRMSEL_HRC
#include "frmsel.hrc"
-#endif
#include <tools/rcid.h>
@@ -157,7 +154,7 @@ void FrameBorder::SetCoreStyle( const SvxBorderLine* pStyle )
maCoreStyle = SvxBorderLine();
// from twips to points
- maUIStyle.Set( maCoreStyle, 0.05, FRAMESEL_GEOM_WIDTH, true );
+ maUIStyle.Set( maCoreStyle, 0.05, FRAMESEL_GEOM_WIDTH );
meState = maUIStyle.Prim() ? FRAMESTATE_SHOW : FRAMESTATE_HIDE;
}
@@ -637,11 +634,31 @@ void FrameSelectorImpl::DrawAllFrameBorders()
// Copy all frame border styles to the helper array
maArray.SetColumnStyleLeft( 0, maLeft.GetUIStyle() );
if( mbVer ) maArray.SetColumnStyleLeft( 1, maVer.GetUIStyle() );
- maArray.SetColumnStyleRight( mbVer ? 1 : 0, maRight.GetUIStyle() );
+
+ // Invert the style for the right line
+ const frame::Style rRightStyle = maRight.GetUIStyle( );
+ frame::Style rInvertedRight( rRightStyle.GetColor(),
+ rRightStyle.Secn(), rRightStyle.Dist(), rRightStyle.Prim( ),
+ rRightStyle.Dashing( ) );
+ maArray.SetColumnStyleRight( mbVer ? 1 : 0, rInvertedRight );
maArray.SetRowStyleTop( 0, maTop.GetUIStyle() );
- if( mbHor ) maArray.SetRowStyleTop( 1, maHor.GetUIStyle() );
- maArray.SetRowStyleBottom( mbHor ? 1 : 0, maBottom.GetUIStyle() );
+ if( mbHor )
+ {
+ // Invert the style for the hor line to match the real borders
+ const frame::Style rHorStyle = maHor.GetUIStyle();
+ frame::Style rInvertedHor( rHorStyle.GetColor(),
+ rHorStyle.Secn(), rHorStyle.Dist(), rHorStyle.Prim( ),
+ rHorStyle.Dashing() );
+ maArray.SetRowStyleTop( 1, rInvertedHor );
+ }
+
+ // Invert the style for the bottom line
+ const frame::Style rBottomStyle = maBottom.GetUIStyle( );
+ frame::Style rInvertedBottom( rBottomStyle.GetColor(),
+ rBottomStyle.Secn(), rBottomStyle.Dist(), rBottomStyle.Prim( ),
+ rBottomStyle.Dashing() );
+ maArray.SetRowStyleBottom( mbHor ? 1 : 0, rInvertedBottom );
for( size_t nCol = 0; nCol < maArray.GetColCount(); ++nCol )
for( size_t nRow = 0; nRow < maArray.GetRowCount(); ++nRow )
@@ -862,7 +879,8 @@ void FrameSelector::HideAllBorders()
mxImpl->SetBorderState( **aIt, FRAMESTATE_HIDE );
}
-bool FrameSelector::GetVisibleWidth( USHORT& rnPrim, USHORT& rnDist, USHORT& rnSecn ) const
+bool FrameSelector::GetVisibleWidth( USHORT& rnPrim, USHORT& rnDist, USHORT& rnSecn,
+ SvxBorderStyle& rnStyle ) const
{
VisFrameBorderCIter aIt( mxImpl->maEnabBorders );
if( !aIt.Is() )
@@ -874,13 +892,15 @@ bool FrameSelector::GetVisibleWidth( USHORT& rnPrim, USHORT& rnDist, USHORT& rnS
bFound =
(rStyle.GetOutWidth() == (*aIt)->GetCoreStyle().GetOutWidth()) &&
(rStyle.GetDistance() == (*aIt)->GetCoreStyle().GetDistance()) &&
- (rStyle.GetInWidth() == (*aIt)->GetCoreStyle().GetInWidth());
+ (rStyle.GetInWidth() == (*aIt)->GetCoreStyle().GetInWidth()) &&
+ (rStyle.GetStyle() == (*aIt)->GetCoreStyle().GetStyle());
if( bFound )
{
rnPrim = rStyle.GetOutWidth();
rnDist = rStyle.GetDistance();
rnSecn = rStyle.GetInWidth();
+ rnStyle = rStyle.GetStyle();
}
return bFound;
}
@@ -941,11 +961,13 @@ void FrameSelector::SelectAllVisibleBorders( bool bSelect )
mxImpl->SelectBorder( **aIt, bSelect );
}
-void FrameSelector::SetStyleToSelection( USHORT nPrim, USHORT nDist, USHORT nSecn )
+void FrameSelector::SetStyleToSelection( USHORT nPrim, USHORT nDist, USHORT nSecn,
+ SvxBorderStyle nStyle )
{
mxImpl->maCurrStyle.SetOutWidth( nPrim );
mxImpl->maCurrStyle.SetDistance( nDist );
mxImpl->maCurrStyle.SetInWidth( nSecn );
+ mxImpl->maCurrStyle.SetStyle( nStyle );
for( SelFrameBorderIter aIt( mxImpl->maEnabBorders ); aIt.Is(); ++aIt )
mxImpl->SetBorderState( **aIt, FRAMESTATE_SHOW );
}
@@ -1203,3 +1225,4 @@ FrameBorderIterBase< Cont, Iter, Pred >& FrameBorderIterBase< Cont, Iter, Pred >
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/graphctl.cxx b/svx/source/dialog/graphctl.cxx
index 75496b2492..e8d3fd5acf 100644
--- a/svx/source/dialog/graphctl.cxx
+++ b/svx/source/dialog/graphctl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,9 +34,7 @@
#include <unotools/syslocale.hxx>
#include <rtl/math.hxx>
#include <unotools/localedatawrapper.hxx>
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
#include <vcl/svapp.hxx>
#include <osl/mutex.hxx>
@@ -182,7 +181,7 @@ void GraphCtrl::SetWinStyle( WinBits nWinBits )
void GraphCtrl::InitSdrModel()
{
- ::vos::OGuard aGuard (Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
SdrPage* pPage;
@@ -616,7 +615,7 @@ void GraphCtrl::KeyInput( const KeyEvent& rKEvt )
if(pView->IsDragObj())
{
- FASTBOOL bWasNoSnap = rDragStat.IsNoSnap();
+ bool bWasNoSnap = rDragStat.IsNoSnap();
BOOL bWasSnapEnabled = pView->IsSnapEnabled();
// switch snapping off
@@ -958,3 +957,5 @@ IMPL_LINK( GraphCtrl, UpdateHdl, Timer*, pTimer )
return mpAccContext;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/grfflt.cxx b/svx/source/dialog/grfflt.cxx
index bf8bd104a2..d69290ad1d 100644
--- a/svx/source/dialog/grfflt.cxx
+++ b/svx/source/dialog/grfflt.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,16 +32,13 @@
#include <vcl/msgbox.hxx>
#include <sfx2/viewfrm.hxx>
#include <sfx2/viewsh.hxx>
-#ifndef _SFXOBJSH_HXX
#include <sfx2/objsh.hxx>
-#endif
#include <sfx2/request.hxx>
#include <svx/dialmgr.hxx>
#include <svx/grfflt.hxx>
-//#include "grfflt.hrc"
#include <svx/dialogs.hrc>
-#include <svx/svxdlg.hxx> //CHINA001
+#include <svx/svxdlg.hxx>
// --------------------
// - SvxGraphicFilter -
@@ -187,7 +185,6 @@ ULONG SvxGraphicFilter::ExecuteGrfFilterSlot( SfxRequest& rReq, GraphicObject& r
case( SID_GRFFILTER_MOSAIC ):
{
- //CHINA001 GraphicFilterMosaic aDlg( pWindow, rGraphic, 4, 4, FALSE );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
@@ -202,30 +199,28 @@ ULONG SvxGraphicFilter::ExecuteGrfFilterSlot( SfxRequest& rReq, GraphicObject& r
case( SID_GRFFILTER_EMBOSS ):
{
- //CHINA001 GraphicFilterEmboss aDlg( pWindow, rGraphic, RP_MM );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
AbstractGraphicFilterDialog* aDlg = pFact->CreateGraphicFilterEmboss( pWindow, rGraphic, RP_MM, RID_SVX_GRFFILTER_DLG_EMBOSS );
- DBG_ASSERT(aDlg, "Dialogdiet fail!");//CHINA001
- if( aDlg->Execute() == RET_OK ) //CHINA001 if( aDlg.Execute() == RET_OK )
- aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 ); //CHINA001 aGraphic = aDlg.GetFilteredGraphic( rGraphic, 1.0, 1.0 );
- delete aDlg; //add by CHINA001
+ DBG_ASSERT(aDlg, "Dialogdiet fail!");
+ if( aDlg->Execute() == RET_OK )
+ aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 );
+ delete aDlg;
}
}
break;
case( SID_GRFFILTER_POSTER ):
{
- //CHINA001 GraphicFilterPoster aDlg( pWindow, rGraphic, 16 );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
AbstractGraphicFilterDialog* aDlg = pFact->CreateGraphicFilterPosterSepia( pWindow, rGraphic, 16, RID_SVX_GRFFILTER_DLG_POSTER );
- DBG_ASSERT(aDlg, "Dialogdiet fail!");//CHINA001
- if( aDlg->Execute() == RET_OK ) //CHINA001 if( aDlg.Execute() == RET_OK )
- aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 ); //CHINA001 aGraphic = aDlg.GetFilteredGraphic( rGraphic, 1.0, 1.0 );
- delete aDlg; //add by CHINA001
+ DBG_ASSERT(aDlg, "Dialogdiet fail!");
+ if( aDlg->Execute() == RET_OK )
+ aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 );
+ delete aDlg;
}
}
break;
@@ -257,30 +252,28 @@ ULONG SvxGraphicFilter::ExecuteGrfFilterSlot( SfxRequest& rReq, GraphicObject& r
case( SID_GRFFILTER_SEPIA ):
{
- //CHINA001 GraphicFilterSepia aDlg( pWindow, rGraphic, 10 );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
AbstractGraphicFilterDialog* aDlg = pFact->CreateGraphicFilterPosterSepia( pWindow, rGraphic, 10, RID_SVX_GRFFILTER_DLG_SEPIA );
- DBG_ASSERT(aDlg, "Dialogdiet fail!");//CHINA001
- if( aDlg->Execute() == RET_OK ) //CHINA001 if( aDlg.Execute() == RET_OK )
- aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 ); //CHINA001 aGraphic = aDlg.GetFilteredGraphic( rGraphic, 1.0, 1.0 );
- delete aDlg; //add by CHINA001
+ DBG_ASSERT(aDlg, "Dialogdiet fail!");
+ if( aDlg->Execute() == RET_OK )
+ aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 );
+ delete aDlg;
}
}
break;
case( SID_GRFFILTER_SOLARIZE ):
{
- //CHINA001 GraphicFilterSolarize aDlg( pWindow, rGraphic, 128, FALSE );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
AbstractGraphicFilterDialog* aDlg = pFact->CreateGraphicFilterSolarize( pWindow, rGraphic, 128, FALSE, RID_SVX_GRFFILTER_DLG_SOLARIZE );
- DBG_ASSERT(aDlg, "Dialogdiet fail!");//CHINA001
- if( aDlg->Execute() == RET_OK ) //CHINA001 if( aDlg.Execute() == RET_OK )
- aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 ); //CHINA001 aGraphic = aDlg.GetFilteredGraphic( rGraphic, 1.0, 1.0 );
- delete aDlg; //add by CHINA001
+ DBG_ASSERT(aDlg, "Dialogdiet fail!");
+ if( aDlg->Execute() == RET_OK )
+ aGraphic = aDlg->GetFilteredGraphic( rGraphic, 1.0, 1.0 );
+ delete aDlg;
}
}
break;
@@ -350,444 +343,5 @@ void SvxGraphicFilter::DisableGraphicFilterSlots( SfxItemSet& rSet )
if( SFX_ITEM_AVAILABLE <= rSet.GetItemState( SID_GRFFILTER_SOLARIZE ) )
rSet.DisableItem( SID_GRFFILTER_SOLARIZE );
};
-/* CHINA001 move to cuigrfflt.cxx
-// --------------------------------------
-// - GraphicFilterDialog::PreviewWindow -
-// --------------------------------------
-
-GraphicFilterDialog::PreviewWindow::PreviewWindow( Window* pParent, const ResId& rResId ) :
- Control( pParent, rResId )
-{
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterDialog::PreviewWindow::~PreviewWindow()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-void GraphicFilterDialog::PreviewWindow::Paint( const Rectangle& rRect )
-{
- Control::Paint( rRect );
-
- const Size aGrfSize( LogicToPixel( maGraphic.GetPrefSize(), maGraphic.GetPrefMapMode() ) );
- const Size aOutSize( GetOutputSizePixel() );
- const Point aGrfPos( ( aOutSize.Width() - aGrfSize.Width() ) >> 1,
- ( aOutSize.Height() - aGrfSize.Height() ) >> 1 );
-
- if( maGraphic.IsAnimated() )
- maGraphic.StartAnimation( this , aGrfPos, aGrfSize );
- else
- maGraphic.Draw( this, aGrfPos, aGrfSize );
-}
-
-// -----------------------------------------------------------------------------
-
-void GraphicFilterDialog::PreviewWindow::SetGraphic( const Graphic& rGraphic )
-{
- maGraphic = rGraphic;
-
- if( maGraphic.IsAnimated() || maGraphic.IsTransparent() )
- Invalidate();
- else
- Paint( Rectangle( Point(), GetOutputSizePixel() ) );
-}
-
-// -----------------------
-// - GraphicFilterDialog -
-// -----------------------
-
-GraphicFilterDialog::GraphicFilterDialog( Window* pParent, const ResId& rResId, const Graphic& rGraphic ) :
- ModalDialog ( pParent, rResId ),
- mfScaleX ( 0.0 ),
- mfScaleY ( 0.0 ),
- maSizePixel ( LogicToPixel( rGraphic.GetPrefSize(), rGraphic.GetPrefMapMode() ) ),
- maModifyHdl ( LINK( this, GraphicFilterDialog, ImplModifyHdl ) ),
- maPreview ( this, SVX_RES( CTL_PREVIEW ) ),
- maFlParameter ( this, SVX_RES( FL_PARAMETER ) ),
- maBtnOK ( this, SVX_RES( BTN_OK ) ),
- maBtnCancel ( this, SVX_RES( BTN_CANCEL ) ),
- maBtnHelp ( this, SVX_RES( BTN_HELP ) )
-{
- const Size aPreviewSize( maPreview.GetOutputSizePixel() );
- Size aGrfSize( maSizePixel );
-
- if( rGraphic.GetType() == GRAPHIC_BITMAP &&
- aPreviewSize.Width() && aPreviewSize.Height() &&
- aGrfSize.Width() && aGrfSize.Height() )
- {
- const double fGrfWH = (double) aGrfSize.Width() / aGrfSize.Height();
- const double fPreWH = (double) aPreviewSize.Width() / aPreviewSize.Height();
-
- if( fGrfWH < fPreWH )
- {
- aGrfSize.Width() = (long) ( aPreviewSize.Height() * fGrfWH );
- aGrfSize.Height()= aPreviewSize.Height();
- }
- else
- {
- aGrfSize.Width() = aPreviewSize.Width();
- aGrfSize.Height()= (long) ( aPreviewSize.Width() / fGrfWH);
- }
-
- mfScaleX = (double) aGrfSize.Width() / maSizePixel.Width();
- mfScaleY = (double) aGrfSize.Height() / maSizePixel.Height();
-
- if( !rGraphic.IsAnimated() )
- {
- BitmapEx aBmpEx( rGraphic.GetBitmapEx() );
-
- if( aBmpEx.Scale( aGrfSize, BMP_SCALE_INTERPOLATE ) )
- maGraphic = aBmpEx;
- }
- }
-
- maTimer.SetTimeoutHdl( LINK( this, GraphicFilterDialog, ImplPreviewTimeoutHdl ) );
- maTimer.SetTimeout( 100 );
- ImplModifyHdl( NULL );
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterDialog::~GraphicFilterDialog()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-IMPL_LINK( GraphicFilterDialog, ImplPreviewTimeoutHdl, Timer*, pTimer )
-{
- maTimer.Stop();
- maPreview.SetGraphic( GetFilteredGraphic( maGraphic, mfScaleX, mfScaleY ) );
-
- return 0;
-}
-
-// -----------------------------------------------------------------------------
-
-IMPL_LINK( GraphicFilterDialog, ImplModifyHdl, void*, p )
-{
- if( maGraphic.GetType() == GRAPHIC_BITMAP )
- {
- maTimer.Stop();
- maTimer.Start();
- }
-
- return 0;
-}
-
-// ----------------
-// - FilterMosaic -
-// ----------------
-
-GraphicFilterMosaic::GraphicFilterMosaic( Window* pParent, const Graphic& rGraphic,
- USHORT nTileWidth, USHORT nTileHeight, BOOL bEnhanceEdges ) :
- GraphicFilterDialog( pParent, SVX_RES( RID_SVX_GRFFILTER_DLG_MOSAIC ), rGraphic ),
- maFtWidth ( this, SVX_RES( DLG_FILTERMOSAIC_FT_WIDTH ) ),
- maMtrWidth ( this, SVX_RES( DLG_FILTERMOSAIC_MTR_WIDTH ) ),
- maFtHeight ( this, SVX_RES( DLG_FILTERMOSAIC_FT_HEIGHT ) ),
- maMtrHeight ( this, SVX_RES( DLG_FILTERMOSAIC_MTR_HEIGHT ) ),
- maCbxEdges ( this, SVX_RES( DLG_FILTERMOSAIC_CBX_EDGES ) )
-{
- FreeResource();
-
- maMtrWidth.SetValue( nTileWidth );
- maMtrWidth.SetLast( GetGraphicSizePixel().Width() );
- maMtrWidth.SetModifyHdl( GetModifyHdl() );
-
- maMtrHeight.SetValue( nTileHeight );
- maMtrHeight.SetLast( GetGraphicSizePixel().Height() );
- maMtrHeight.SetModifyHdl( GetModifyHdl() );
-
- maCbxEdges.Check( bEnhanceEdges );
- maCbxEdges.SetToggleHdl( GetModifyHdl() );
-
- maMtrWidth.GrabFocus();
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterMosaic::~GraphicFilterMosaic()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-Graphic GraphicFilterMosaic::GetFilteredGraphic( const Graphic& rGraphic,
- double fScaleX, double fScaleY )
-{
- Graphic aRet;
- const Size aSize( Max( FRound( GetTileWidth() * fScaleX ), 1L ),
- Max( FRound( GetTileHeight() * fScaleY ), 1L ) );
- BmpFilterParam aParam( aSize );
-
- if( rGraphic.IsAnimated() )
- {
- Animation aAnim( rGraphic.GetAnimation() );
-
- if( aAnim.Filter( BMP_FILTER_MOSAIC, &aParam ) )
- {
- if( IsEnhanceEdges() )
- aAnim.Filter( BMP_FILTER_SHARPEN );
-
- aRet = aAnim;
- }
- }
- else
- {
- BitmapEx aBmpEx( rGraphic.GetBitmapEx() );
-
- if( aBmpEx.Filter( BMP_FILTER_MOSAIC, &aParam ) )
- {
- if( IsEnhanceEdges() )
- aBmpEx.Filter( BMP_FILTER_SHARPEN );
-
- aRet = aBmpEx;
- }
- }
-
- return aRet;
-}
-
-// ------------------
-// - GraphicFilterSolarize -
-// ------------------
-
-GraphicFilterSolarize::GraphicFilterSolarize( Window* pParent, const Graphic& rGraphic,
- BYTE cGreyThreshold, BOOL bInvert ) :
- GraphicFilterDialog ( pParent, SVX_RES( RID_SVX_GRFFILTER_DLG_SOLARIZE ), rGraphic ),
- maFtThreshold ( this, SVX_RES( DLG_FILTERSOLARIZE_FT_THRESHOLD ) ),
- maMtrThreshold ( this, SVX_RES( DLG_FILTERSOLARIZE_MTR_THRESHOLD ) ),
- maCbxInvert ( this, SVX_RES( DLG_FILTERSOLARIZE_CBX_INVERT ) )
-{
- FreeResource();
-
- maMtrThreshold.SetValue( FRound( cGreyThreshold / 2.55 ) );
- maMtrThreshold.SetModifyHdl( GetModifyHdl() );
- maCbxInvert.Check( bInvert );
- maCbxInvert.SetToggleHdl( GetModifyHdl() );
-
- maMtrThreshold.GrabFocus();
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterSolarize::~GraphicFilterSolarize()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-Graphic GraphicFilterSolarize::GetFilteredGraphic( const Graphic& rGraphic,
- double fScaleX, double fScaleY )
-{
- Graphic aRet;
- BmpFilterParam aParam( GetGreyThreshold() );
-
- if( rGraphic.IsAnimated() )
- {
- Animation aAnim( rGraphic.GetAnimation() );
-
- if( aAnim.Filter( BMP_FILTER_SOLARIZE, &aParam ) )
- {
- if( IsInvert() )
- aAnim.Invert();
-
- aRet = aAnim;
- }
- }
- else
- {
- BitmapEx aBmpEx( rGraphic.GetBitmapEx() );
-
- if( aBmpEx.Filter( BMP_FILTER_SOLARIZE, &aParam ) )
- {
- if( IsInvert() )
- aBmpEx.Invert();
-
- aRet = aBmpEx;
- }
- }
-
- return aRet;
-}
-
-// ----------------------
-// - GraphicFilterSepia -
-// ----------------------
-
-GraphicFilterSepia::GraphicFilterSepia( Window* pParent, const Graphic& rGraphic,
- USHORT nSepiaPercent ) :
- GraphicFilterDialog ( pParent, SVX_RES( RID_SVX_GRFFILTER_DLG_SEPIA ), rGraphic ),
- maFtSepia ( this, SVX_RES( DLG_FILTERSEPIA_FT_SEPIA ) ),
- maMtrSepia ( this, SVX_RES( DLG_FILTERSEPIA_MTR_SEPIA ) )
-{
- FreeResource();
-
- maMtrSepia.SetValue( nSepiaPercent );
- maMtrSepia.SetModifyHdl( GetModifyHdl() );
-
- maMtrSepia.GrabFocus();
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterSepia::~GraphicFilterSepia()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-Graphic GraphicFilterSepia::GetFilteredGraphic( const Graphic& rGraphic,
- double fScaleX, double fScaleY )
-{
- Graphic aRet;
- BmpFilterParam aParam( GetSepiaPercent() );
-
- if( rGraphic.IsAnimated() )
- {
- Animation aAnim( rGraphic.GetAnimation() );
-
- if( aAnim.Filter( BMP_FILTER_SEPIA, &aParam ) )
- aRet = aAnim;
- }
- else
- {
- BitmapEx aBmpEx( rGraphic.GetBitmapEx() );
-
- if( aBmpEx.Filter( BMP_FILTER_SEPIA, &aParam ) )
- aRet = aBmpEx;
- }
-
- return aRet;
-}
-
-// -----------------------
-// - GraphicFilterPoster -
-// -----------------------
-
-GraphicFilterPoster::GraphicFilterPoster( Window* pParent, const Graphic& rGraphic,
- USHORT nPosterCount ) :
- GraphicFilterDialog ( pParent, SVX_RES( RID_SVX_GRFFILTER_DLG_POSTER ), rGraphic ),
- maFtPoster ( this, SVX_RES( DLG_FILTERPOSTER_FT_POSTER ) ),
- maNumPoster ( this, SVX_RES( DLG_FILTERPOSTER_NUM_POSTER ) )
-{
- FreeResource();
-
- maNumPoster.SetFirst( 2 );
- maNumPoster.SetLast( rGraphic.GetBitmapEx().GetBitCount() );
- maNumPoster.SetValue( nPosterCount );
- maNumPoster.SetModifyHdl( GetModifyHdl() );
- maNumPoster.GrabFocus();
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterPoster::~GraphicFilterPoster()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-Graphic GraphicFilterPoster::GetFilteredGraphic( const Graphic& rGraphic,
- double fScaleX, double fScaleY )
-{
- Graphic aRet;
- const USHORT nPosterCount = GetPosterColorCount();
-
- if( rGraphic.IsAnimated() )
- {
- Animation aAnim( rGraphic.GetAnimation() );
-
- if( aAnim.ReduceColors( nPosterCount, BMP_REDUCE_POPULAR ) )
- aRet = aAnim;
- }
- else
- {
- BitmapEx aBmpEx( rGraphic.GetBitmapEx() );
-
- if( aBmpEx.ReduceColors( nPosterCount, BMP_REDUCE_POPULAR ) )
- aRet = aBmpEx;
- }
-
- return aRet;
-}
-
-// -----------------------
-// - GraphicFilterEmboss -
-// -----------------------
-
-void GraphicFilterEmboss::EmbossControl::MouseButtonDown( const MouseEvent& rEvt )
-{
- const RECT_POINT eOldRP = GetActualRP();
-
- SvxRectCtl::MouseButtonDown( rEvt );
-
- if( GetActualRP() != eOldRP )
- maModifyHdl.Call( this );
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterEmboss::GraphicFilterEmboss( Window* pParent, const Graphic& rGraphic,
- RECT_POINT eLightSource ) :
- GraphicFilterDialog ( pParent, SVX_RES( RID_SVX_GRFFILTER_DLG_EMBOSS ), rGraphic ),
- maFtLight ( this, SVX_RES( DLG_FILTEREMBOSS_FT_LIGHT ) ),
- maCtlLight ( this, SVX_RES( DLG_FILTEREMBOSS_CTL_LIGHT ), eLightSource )
-{
- FreeResource();
-
- maCtlLight.SetModifyHdl( GetModifyHdl() );
- maCtlLight.GrabFocus();
-}
-
-// -----------------------------------------------------------------------------
-
-GraphicFilterEmboss::~GraphicFilterEmboss()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-Graphic GraphicFilterEmboss::GetFilteredGraphic( const Graphic& rGraphic,
- double fScaleX, double fScaleY )
-{
- Graphic aRet;
- USHORT nAzim, nElev;
-
- switch( maCtlLight.GetActualRP() )
- {
- case( RP_LT ): nAzim = 4500, nElev = 4500; break;
- case( RP_MT ): nAzim = 9000, nElev = 4500; break;
- case( RP_RT ): nAzim = 13500, nElev = 4500; break;
- case( RP_LM ): nAzim = 0, nElev = 4500; break;
- case( RP_MM ): nAzim = 0, nElev = 9000; break;
- case( RP_RM ): nAzim = 18000, nElev = 4500; break;
- case( RP_LB ): nAzim = 31500, nElev = 4500; break;
- case( RP_MB ): nAzim = 27000, nElev = 4500; break;
- case( RP_RB ): nAzim = 22500, nElev = 4500; break;
- }
-
- BmpFilterParam aParam( nAzim, nElev );
-
- if( rGraphic.IsAnimated() )
- {
- Animation aAnim( rGraphic.GetAnimation() );
-
- if( aAnim.Filter( BMP_FILTER_EMBOSS_GREY, &aParam ) )
- aRet = aAnim;
- }
- else
- {
- BitmapEx aBmpEx( rGraphic.GetBitmapEx() );
-
- if( aBmpEx.Filter( BMP_FILTER_EMBOSS_GREY, &aParam ) )
- aRet = aBmpEx;
- }
-
- return aRet;
-}
-*/
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/hdft.cxx b/svx/source/dialog/hdft.cxx
index aa64c47efa..d782152429 100644
--- a/svx/source/dialog/hdft.cxx
+++ b/svx/source/dialog/hdft.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,11 +60,11 @@
#include <editeng/sizeitem.hxx>
#include <editeng/boxitem.hxx>
-#include <svx/svxdlg.hxx> //CHINA001
-#include <svx/dialogs.hrc> //CHINA001
+#include <svx/svxdlg.hxx>
+#include <svx/dialogs.hrc>
// static ----------------------------------------------------------------
-// --> OD 2004-06-18 #i19922#
+// Word 97 incompatibility (#i19922#)
//static const long MINBODY = 284; // 0,5cm in twips aufgerundet
static const long MINBODY = 56; // 1mm in twips rounded
@@ -89,10 +90,6 @@ static USHORT pRanges[] =
0
};
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
// gibt den Bereich der Which-Werte zurueck
@@ -388,13 +385,13 @@ void SvxHFPage::Reset( const SfxItemSet& rSet )
aCntSharedBox.SaveValue();
RangeHdl( 0 );
- USHORT nHtmlMode = 0;
const SfxPoolItem* pItem = 0;
SfxObjectShell* pShell;
if(SFX_ITEM_SET == rSet.GetItemState(SID_HTML_MODE, FALSE, &pItem) ||
( 0 != (pShell = SfxObjectShell::Current()) &&
0 != (pItem = pShell->GetItem(SID_HTML_MODE))))
{
+ USHORT nHtmlMode = 0;
nHtmlMode = ((SfxUInt16Item*)pItem)->GetValue();
if(nHtmlMode && HTMLMODE_ON)
{
@@ -544,8 +541,6 @@ IMPL_LINK( SvxHFPage, BackgroundHdl, Button *, EMPTYARG )
pBBSet->Put( *pItem );
}
- //CHINA001 SvxBorderBackgroundDlg* pDlg =
-//CHINA001 new SvxBorderBackgroundDlg( this, *pBBSet, bEnableBackgroundSelector );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
@@ -712,10 +707,6 @@ void SvxHFPage::ResetBackground_Impl( const SfxItemSet& rSet )
}
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
void SvxHFPage::ActivatePage( const SfxItemSet& rSet )
{
const SfxPoolItem* pItem = GetItem( rSet, SID_ATTR_LRSPACE );
@@ -867,10 +858,6 @@ void SvxHFPage::ActivatePage( const SfxItemSet& rSet )
RangeHdl( 0 );
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
int SvxHFPage::DeactivatePage( SfxItemSet* _pSet )
{
if ( _pSet )
@@ -954,9 +941,7 @@ IMPL_LINK( SvxHFPage, RangeHdl, Edit *, EMPTYARG )
aRMEdit.SetMax( aLMEdit.Normalize( nMax ), FUNIT_TWIP );
return 0;
}
-/* -----------------------------26.08.2002 12:49------------------------------
- ---------------------------------------------------------------------------*/
void lcl_Move(Window& rWin, sal_Int32 nDiff)
{
Point aPos(rWin.GetPosPixel());
@@ -981,3 +966,4 @@ void SvxHFPage::EnableDynamicSpacing()
lcl_Move(*aMoveWindows[nIdx++], nOffset);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/hyperdlg.cxx b/svx/source/dialog/hyperdlg.cxx
index fed065cba4..a755c3f224 100644
--- a/svx/source/dialog/hyperdlg.cxx
+++ b/svx/source/dialog/hyperdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -65,11 +66,10 @@ SvxHlinkDlgWrapper::SvxHlinkDlgWrapper( Window* _pParent, USHORT nId,
mpDlg( NULL )
{
- //CHINA001 pWindow = new SvxHpLinkDlg( _pParent, pBindings );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
- DBG_ASSERT(pFact, "Dialogdiet fail!");//CHINA001
+ DBG_ASSERT(pFact, "Dialogdiet fail!");
mpDlg = pFact->CreateSvxHpLinkDlg( _pParent, pBindings, SID_HYPERLINK_DIALOG );
- DBG_ASSERT(mpDlg, "Dialogdiet fail!");//CHINA001
+ DBG_ASSERT(mpDlg, "Dialogdiet fail!");
pWindow = mpDlg->GetWindow();
((MyStruct*)pImp)->bVisible = FALSE;
@@ -105,3 +105,4 @@ sal_Bool SvxHlinkDlgWrapper::QueryClose()
return mpDlg ? mpDlg->QueryClose() : sal_True;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/hyprdlg.hxx b/svx/source/dialog/hyprdlg.hxx
index 465e18337d..d0db4fcd87 100644
--- a/svx/source/dialog/hyprdlg.hxx
+++ b/svx/source/dialog/hyprdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,10 +39,6 @@
class SvxHyperlinkDlg;
class SfxViewFrame;
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
class HyperCombo : public ComboBox
{
SvxHyperlinkDlg *pDlg;
@@ -141,3 +138,4 @@ public:
#endif // _SVX_DLG_HYPERDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/hyprlink.cxx b/svx/source/dialog/hyprlink.cxx
index e69800cfa1..22f6717739 100644
--- a/svx/source/dialog/hyprlink.cxx
+++ b/svx/source/dialog/hyprlink.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,20 +68,15 @@ public:
virtual void Commit();
};
-/*-- 11.11.2003 14:20:59---------------------------------------------------
-
- -----------------------------------------------------------------------*/
SearchDefaultConfigItem_Impl::SearchDefaultConfigItem_Impl() :
ConfigItem(OUString::createFromAscii("Inet/DefaultSearchEngine"))
{
uno::Sequence<OUString> aNames(1);
- aNames.getArray()[0] = OUString::createFromAscii("Name");
+ aNames.getArray()[0] = OUString(RTL_CONSTASCII_USTRINGPARAM("Name"));
uno::Sequence< uno::Any > aValues = GetProperties(aNames);
aValues.getConstArray()[0] >>= sDefaultEngine;
}
-/*-- 11.11.2003 14:21:00---------------------------------------------------
- -----------------------------------------------------------------------*/
SearchDefaultConfigItem_Impl::~SearchDefaultConfigItem_Impl()
{
}
@@ -202,10 +198,6 @@ SvxHyperlinkDlg::SvxHyperlinkDlg( SfxBindings *_pBindings, Window* pParent) :
HideItem( BTN_INET_SEARCH );
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
SvxHyperlinkDlg::~SvxHyperlinkDlg()
{
SfxImageManager::GetImageManager( 0 )->ReleaseToolBox(this);
@@ -246,10 +238,6 @@ void SvxHyperlinkDlg::Resize()
}
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
void SvxHyperlinkDlg::Resizing(Size& rSize)
{
if (rSize.Height() > nMaxHeight)
@@ -338,10 +326,6 @@ void SvxHyperlinkDlg::StateChanged( USHORT nSID, SfxItemState eState,
}
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
IMPL_LINK( SvxHyperlinkDlg, TBClickHdl, ToolBox *, pBox )
{
switch (pBox->GetCurItemId())
@@ -363,10 +347,6 @@ IMPL_LINK( SvxHyperlinkDlg, TBClickHdl, ToolBox *, pBox )
return TRUE;
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
IMPL_LINK( SvxHyperlinkDlg, TBSelectHdl, ToolBox *, pBox )
{
switch (pBox->GetCurItemId())
@@ -459,10 +439,6 @@ IMPL_LINK( SvxHyperlinkDlg, DropdownClick, ToolBox *, pBox )
return TRUE;
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
void SvxHyperlinkDlg::TargetMenu(const String& rSelEntry, BOOL bExecute)
{
if (pTargetMenu && !bExecute)
@@ -484,9 +460,9 @@ void SvxHyperlinkDlg::TargetMenu(const String& rSelEntry, BOOL bExecute)
TargetList aList;
pVwFrm->GetTopFrame().GetTargetList(aList);
- USHORT nCount = (USHORT)aList.Count();
- if( nCount )
+ if ( !aList.empty() )
{
+ size_t nCount = aList.size();
BOOL bChecked = FALSE;
if (pTargetMenu != NULL)
@@ -495,10 +471,10 @@ void SvxHyperlinkDlg::TargetMenu(const String& rSelEntry, BOOL bExecute)
pTargetMenu = new PopupMenu;
pTargetMenu->SetMenuFlags( pTargetMenu->GetMenuFlags() |
MENU_FLAG_NOAUTOMNEMONICS );
- USHORT i;
- for ( i = 0; i < nCount; i++ )
+
+ for ( size_t i = 0; i < nCount; i++ )
{
- String sEntry(*aList.GetObject(i));
+ String sEntry( *aList[ i ] );
pTargetMenu->InsertItem(i + 1, sEntry, MIB_RADIOCHECK|MIB_AUTOCHECK);
if (sEntry == rSelEntry)
@@ -507,8 +483,8 @@ void SvxHyperlinkDlg::TargetMenu(const String& rSelEntry, BOOL bExecute)
bChecked = TRUE;
}
}
- for ( i = nCount; i; i-- )
- delete aList.GetObject( i - 1 );
+ for ( size_t i = nCount; i; )
+ delete aList[ --i ];
if (!bChecked)
pTargetMenu->CheckItem(1);
@@ -524,10 +500,6 @@ void SvxHyperlinkDlg::TargetMenu(const String& rSelEntry, BOOL bExecute)
}
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
IMPL_LINK( SvxHyperlinkDlg, LinkPopupSelectHdl, Menu *, pMenu )
{
switch (pMenu->GetCurItemId())
@@ -543,10 +515,6 @@ IMPL_LINK( SvxHyperlinkDlg, LinkPopupSelectHdl, Menu *, pMenu )
return TRUE;
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
IMPL_LINK( SvxHyperlinkDlg, SearchPopupSelectHdl, Menu *, pMenu )
{
const SvxSearchEngineData& rData = aSearchConfig.GetData(pMenu->GetCurItemId() - 1);
@@ -623,10 +591,6 @@ IMPL_LINK( SvxHyperlinkDlg, SearchPopupSelectHdl, Menu *, pMenu )
return TRUE;
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
IMPL_LINK( SvxHyperlinkDlg, BookmarkFoundHdl, String *, pUrl )
{
if (pUrl && pUrl->Len())
@@ -791,10 +755,6 @@ IMPL_LINK( SvxHyperlinkDlg, ComboSelectHdl, ComboBox *, pCombo )
return TRUE;
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
IMPL_LINK( SvxHyperlinkDlg, ComboModifyHdl, ComboBox *, pCombo )
{
BOOL bEnable = TRUE;
@@ -851,6 +811,7 @@ void SvxHyperlinkDlg::SetImages()
HyperCombo::HyperCombo( SvxHyperlinkDlg* pDialog, const ResId& rResId ) :
ComboBox( (Window *)pDialog, rResId )
{
+ nRatio = 0;
pDlg = pDialog;
nMaxWidth = GetSizePixel().Width();
@@ -909,10 +870,6 @@ long HyperCombo::PreNotify( NotifyEvent& rNEvt )
return nHandled;
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
long HyperCombo::CalcResizeWidth( long nW )
{
long nNewWidth = Max(nMaxWidth - nW * GetRatio() / 100L, nMinWidth);
@@ -926,10 +883,6 @@ long HyperCombo::CalcResizeWidth( long nW )
return 0; // Kein Resize notwendig
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
void HyperCombo::DoResize( long nNewWidth )
{
SetSizePixel(Size(nNewWidth, GetSizePixel().Height()));
@@ -987,13 +940,10 @@ SvxHyperlinkDlgWrapper::SvxHyperlinkDlgWrapper( Window* _pParent, USHORT nId,
eChildAlignment = SFX_ALIGN_TOP;
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
SfxChildWinInfo SvxHyperlinkDlgWrapper::GetInfo() const
{
SfxChildWinInfo aInfo = SfxChildWindow::GetInfo();
return aInfo;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/imapdlg.cxx b/svx/source/dialog/imapdlg.cxx
index ae4c7f4da1..ec2e302973 100644
--- a/svx/source/dialog/imapdlg.cxx
+++ b/svx/source/dialog/imapdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,13 +40,9 @@
#include <stdlib.h>
#include <tools/shl.hxx>
-#ifndef _EINF_HXX
#include <tools/errinf.hxx>
-#endif
#include <tools/urlobj.hxx>
-#ifndef _UNOTOOLS_UCBSTREAMHELPER_HXX
#include <unotools/ucbstreamhelper.hxx>
-#endif
#include <vcl/msgbox.hxx>
#include <vcl/group.hxx>
#include <vcl/lstbox.hxx>
@@ -63,9 +60,7 @@
#include <sfx2/objsh.hxx>
#include <sfx2/docfile.hxx>
#include <unotools/localedatawrapper.hxx>
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
#define _IMAPDLG_PRIVATE
#include "svx/imapdlg.hxx"
@@ -203,7 +198,6 @@ SvxIMapDlg::SvxIMapDlg( SfxBindings *_pBindings, SfxChildWindow *pCW,
maCbbTarget ( this, SVX_RES( RID_SVXCTL_CBB_TARGET ) ),
aStbStatus ( this, WB_BORDER | WB_3DLOOK | WB_LEFT ),
maImageList ( SVX_RES( IL_IMAPDLG ) ),
- maImageListH ( SVX_RES( ILH_IMAPDLG ) ),
pCheckObj ( NULL ),
aIMapItem ( SID_IMAP_EXEC, *this, *_pBindings )
{
@@ -409,8 +403,8 @@ void SvxIMapDlg::SetTargetList( const TargetList& rTargetList )
maCbbTarget.Clear();
- for( String* pStr = aNewList.First(); pStr; pStr = aNewList.Next() )
- maCbbTarget.InsertEntry( *pStr );
+ for ( size_t i = 0, n = aNewList.size(); i < n; ++i )
+ maCbbTarget.InsertEntry( *aNewList[ i ] );
}
@@ -447,9 +441,9 @@ void SvxIMapDlg::Update( const Graphic& rGraphic, const ImageMap* pImageMap,
// UpdateTargetList loeschen, da diese Methode
// vor dem Zuschlagen des Update-Timers noch
// mehrmals gerufen werden kann( #46540 )
- for( String* pStr = pOwnData->aUpdateTargetList.First(); pStr; pStr = pOwnData->aUpdateTargetList.Next() )
- delete pStr;
- pOwnData->aUpdateTargetList.Clear();
+ for ( size_t i = 0, n = pOwnData->aUpdateTargetList.size(); i < n; ++i )
+ delete pOwnData->aUpdateTargetList[ i ];
+ pOwnData->aUpdateTargetList.clear();
// TargetListe muss kopiert werden, da sie im
// Besitz des Aufrufers ist und von ihm nach diesem
@@ -459,8 +453,8 @@ void SvxIMapDlg::Update( const Graphic& rGraphic, const ImageMap* pImageMap,
{
TargetList aTargetList( *pTargetList );
- for( String* pStr = aTargetList.First(); pStr; pStr = aTargetList.Next() )
- pOwnData->aUpdateTargetList.Insert( new String( *pStr ) );
+ for ( size_t i = 0, n = aTargetList.size(); i < n; ++i )
+ pOwnData->aUpdateTargetList.push_back( new String( *aTargetList[ i ] ) );
}
pOwnData->aTimer.Start();
@@ -954,10 +948,9 @@ IMPL_LINK( SvxIMapDlg, UpdateHdl, Timer*, EMPTYARG )
}
// die in der Update-Methode kopierte Liste wieder loeschen
- for( String* pStr = pOwnData->aUpdateTargetList.First(); pStr; pStr = pOwnData->aUpdateTargetList.Next() )
- delete pStr;
-
- pOwnData->aUpdateTargetList.Clear();
+ for ( size_t i = 0, n = pOwnData->aUpdateTargetList.size(); i < n; ++i )
+ delete pOwnData->aUpdateTargetList[ i ];
+ pOwnData->aUpdateTargetList.clear();
GetBindings().Invalidate( SID_IMAP_EXEC );
@@ -1039,9 +1032,7 @@ IMPL_LINK( SvxIMapDlg, MiscHdl, void*, EMPTYARG )
void SvxIMapDlg::ApplyImageList()
{
- bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
-
- ImageList& rImgLst = bHighContrast ? maImageListH : maImageList;
+ ImageList& rImgLst = maImageList;
aTbxIMapDlg1.SetImageList( rImgLst );
}
@@ -1053,3 +1044,5 @@ void SvxIMapDlg::DataChanged( const DataChangedEvent& rDCEvt )
if ( (rDCEvt.GetType() == DATACHANGED_SETTINGS) && (rDCEvt.GetFlags() & SETTINGS_STYLE) )
ApplyImageList();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/imapdlg.hrc b/svx/source/dialog/imapdlg.hrc
index 5247836d25..850c960ebb 100644
--- a/svx/source/dialog/imapdlg.hrc
+++ b/svx/source/dialog/imapdlg.hrc
@@ -71,7 +71,6 @@
#define STB_STATUS 1
#define IL_IMAPDLG 1024
-#define ILH_IMAPDLG 1025
/******************************************************************************/
diff --git a/svx/source/dialog/imapdlg.src b/svx/source/dialog/imapdlg.src
index 202dc6d984..f6d990f930 100644
--- a/svx/source/dialog/imapdlg.src
+++ b/svx/source/dialog/imapdlg.src
@@ -269,13 +269,8 @@ ModelessDialog RID_SVXDLG_IMAP
MaskColor = Color { Red = 0xFFFF; Green = 0x0000; Blue = 0xFFFF; } ;
IMAPDLG_IDLIST
};
- ImageList ILH_IMAPDLG
- {
- Prefix = "idh";
- MaskColor = Color { Red = 0xFFFF; Green = 0x0000; Blue = 0xFFFF; } ;
- IMAPDLG_IDLIST
- };
};
+
Control RID_SVXCTL_IMAP
{
Border = TRUE ;
diff --git a/svx/source/dialog/imapimp.hxx b/svx/source/dialog/imapimp.hxx
index 0296bc426a..51ebf403f9 100644
--- a/svx/source/dialog/imapimp.hxx
+++ b/svx/source/dialog/imapimp.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,8 +50,10 @@ public:
void* pUpdateEditingObject;
BOOL bExecState;
- IMapOwnData( SvxIMapDlg* pIMapDlg ) : pIMap ( pIMapDlg ) {}
+ IMapOwnData( SvxIMapDlg* pIMapDlg ) : pIMap ( pIMapDlg ), pUpdateEditingObject( NULL ) {}
};
#endif // _IMAPIMP_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/imapwnd.cxx b/svx/source/dialog/imapwnd.cxx
index 31b1757350..25cc6d5650 100644
--- a/svx/source/dialog/imapwnd.cxx
+++ b/svx/source/dialog/imapwnd.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95,8 +96,8 @@ IMapWindow::IMapWindow( Window* pParent, const ResId& rResId, const Reference< X
IMapWindow::~IMapWindow()
{
// Liste loeschen
- for( String* pStr = aTargetList.First(); pStr; pStr = aTargetList.Next() )
- delete pStr;
+ for ( size_t i = 0, n = aTargetList.size(); i < n; ++i )
+ delete aTargetList[ i ];
SfxItemPool::Free(pIMapPool);
delete[] pItemInfo;
@@ -218,17 +219,14 @@ const ImageMap& IMapWindow::GetImageMap()
void IMapWindow::SetTargetList( TargetList& rTargetList )
{
- String* pStr;
-
// alte Liste loeschen
- for( pStr = aTargetList.First(); pStr; pStr = aTargetList.Next() )
- delete pStr;
-
- aTargetList.Clear();
+ for( size_t i = 0, n = aTargetList.size(); i < n; ++i )
+ delete aTargetList[ i ];
+ aTargetList.clear();
// mit uebergebener Liste fuellen
- for( pStr = rTargetList.First(); pStr; pStr = rTargetList.Next() )
- aTargetList.Insert( new String( *pStr ) );
+ for( size_t i = 0, n = rTargetList.size(); i < n; ++i )
+ aTargetList.push_back( new String( *rTargetList[ i ] ) );
pModel->SetChanged( sal_False );
}
@@ -822,7 +820,7 @@ void IMapWindow::DoMacroAssign()
aNamesItem.AddEvent( String::CreateFromAscii( "MouseOver" ), String(), SFX_EVENT_MOUSEOVER_OBJECT );
aNamesItem.AddEvent( String::CreateFromAscii( "MouseOut" ), String(), SFX_EVENT_MOUSEOUT_OBJECT );
aSet.Put( aNamesItem );
-
+
SvxMacroItem aMacroItem(SID_ATTR_MACROITEM);
IMapObject* pIMapObj = GetIMapObj( pSdrObj );
aMacroItem.SetMacroTable( pIMapObj->GetMacroTable() );
@@ -882,7 +880,7 @@ void IMapWindow::DoPropertyDialog()
pModel->SetChanged( sal_True );
UpdateInfo( TRUE );
}
- delete aDlg; //add by CHINA001
+ delete aDlg;
}
}
}
@@ -1004,40 +1002,6 @@ void IMapWindow::CreateDefaultObject()
void IMapWindow::KeyInput( const KeyEvent& rKEvt )
{
- KeyCode aCode = rKEvt.GetKeyCode();
-
-/*
- switch(aCode.GetCode())
- {
- case KEY_ESCAPE:
- {
- if ( pView->IsAction() )
- {
- pView->BrkAction();
- return;
- }
- else if ( pView->AreObjectsMarked() )
- {
- const SdrHdlList& rHdlList = pView->GetHdlList();
- SdrHdl* pHdl = rHdlList.GetFocusHdl();
-
- if(pHdl)
- {
- ((SdrHdlList&)rHdlList).ResetFocusHdl();
- }
- else
- {
- pView->UnmarkAllObj();
- ((Dialog*)GetParent())->GrabFocusToFirstControl();
- }
-
- return;
- }
- }
- break;
-
- }
-*/
GraphCtrl::KeyInput( rKEvt );
}
@@ -1067,3 +1031,5 @@ void IMapWindow::StartPolyEdit()
((SdrHdlList&)rHdlList).TravelFocusHdl(true);
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/imapwnd.hxx b/svx/source/dialog/imapwnd.hxx
index 0ab118b3c7..971e93af72 100644
--- a/svx/source/dialog/imapwnd.hxx
+++ b/svx/source/dialog/imapwnd.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -224,3 +225,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/langbox.cxx b/svx/source/dialog/langbox.cxx
index 0ff0f72451..c4cb6fd617 100644
--- a/svx/source/dialog/langbox.cxx
+++ b/svx/source/dialog/langbox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -155,7 +156,6 @@ void SvxLanguageBox::Init()
m_pLangTable = new SvtLanguageTable;
m_aNotCheckedImage = Image( SVX_RES( RID_SVXIMG_NOTCHECKED ) );
m_aCheckedImage = Image( SVX_RES( RID_SVXIMG_CHECKED ) );
- m_aCheckedImageHC = Image( SVX_RES( RID_SVXIMG_CHECKED_H ) );
m_aAllString = String( SVX_RESSTR( RID_SVXSTR_LANGUAGE_ALL ) );
m_nLangList = LANG_LIST_EMPTY;
m_bHasLangNone = FALSE;
@@ -201,8 +201,6 @@ USHORT SvxLanguageBox::ImplInsertImgEntry( const String& rEntry, USHORT nPos, bo
USHORT nRet = 0;
if( !bChecked )
nRet = InsertEntry( rEntry, m_aNotCheckedImage, nPos );
- else if( GetSettings().GetStyleSettings().GetHighContrastMode() )
- nRet = InsertEntry( rEntry, m_aCheckedImageHC, nPos );
else
nRet = InsertEntry( rEntry, m_aCheckedImage, nPos );
return nRet;
@@ -298,7 +296,7 @@ void SvxLanguageBox::SetLanguageList( INT16 nLangList,
nLangType != LANGUAGE_SYSTEM &&
nLangType != LANGUAGE_NONE &&
(nLangType < LANGUAGE_USER1 || nLangType > LANGUAGE_USER9) &&
- (MsLangId::getSubLanguage( nLangType) != 0 ||
+ (MsLangId::getSubLanguage( nLangType) != 0 ||
(nLangList & LANG_LIST_ALSO_PRIMARY_ONLY)) &&
((nLangList & LANG_LIST_ALL) != 0 ||
((nLangList & LANG_LIST_WESTERN) != 0 &&
@@ -344,8 +342,8 @@ USHORT SvxLanguageBox::InsertLanguage( const LanguageType nLangType, USHORT nPos
USHORT SvxLanguageBox::ImplInsertLanguage( const LanguageType nLangType, USHORT nPos, sal_Int16 nType )
{
LanguageType nLang = MsLangId::getReplacementForObsoleteLanguage( nLangType);
- // For obsolete and to be replaced languages check whether an entry of the
- // replacement already exists and if so don't add an entry with identical
+ // For obsolete and to be replaced languages check whether an entry of the
+ // replacement already exists and if so don't add an entry with identical
// string as would be returned by SvtLanguageTable::GetString().
if (nLang != nLangType)
{
@@ -404,8 +402,8 @@ USHORT SvxLanguageBox::InsertLanguage( const LanguageType nLangType,
BOOL bCheckEntry, USHORT nPos )
{
LanguageType nLang = MsLangId::getReplacementForObsoleteLanguage( nLangType);
- // For obsolete and to be replaced languages check whether an entry of the
- // replacement already exists and if so don't add an entry with identical
+ // For obsolete and to be replaced languages check whether an entry of the
+ // replacement already exists and if so don't add an entry with identical
// string as would be returned by SvtLanguageTable::GetString().
if (nLang != nLangType)
{
@@ -450,7 +448,7 @@ LanguageType SvxLanguageBox::GetSelectLanguage() const
void SvxLanguageBox::SelectLanguage( const LanguageType eLangType, BOOL bSelect )
{
- // If the core uses a LangID of an imported MS document and wants to select
+ // If the core uses a LangID of an imported MS document and wants to select
// a language that is replaced, we need to select the replacement instead.
LanguageType nLang = MsLangId::getReplacementForObsoleteLanguage( eLangType);
@@ -524,3 +522,4 @@ IMPL_GET_WINDOW (SvxLanguageBox);*/
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/langbox.src b/svx/source/dialog/langbox.src
index 8bd1987d2d..70eb0347e7 100644
--- a/svx/source/dialog/langbox.src
+++ b/svx/source/dialog/langbox.src
@@ -34,16 +34,12 @@ Image RID_SVXIMG_NOTCHECKED
ImageBitmap = Bitmap { File = "notcheck.bmp" ; } ;
MaskColor = Color { Red = 0xFFFF ; Green = 0x0000 ; Blue = 0xFFFF ; };
};
+
Image RID_SVXIMG_CHECKED
{
ImageBitmap = Bitmap { File = "lngcheck.bmp" ; } ;
MaskColor = Color { Red = 0xFFFF ; Green = 0x0000 ; Blue = 0xFFFF ; };
};
-Image RID_SVXIMG_CHECKED_H
-{
- ImageBitmap = Bitmap { File = "lngcheck_h.bmp" ; } ;
- MaskColor = Color { Red = 0xFFFF ; Green = 0x0000 ; Blue = 0xFFFF ; };
-};
// ********************************************************************** EOF
diff --git a/svx/source/dialog/linkwarn.cxx b/svx/source/dialog/linkwarn.cxx
new file mode 100644
index 0000000000..d69ddda72b
--- /dev/null
+++ b/svx/source/dialog/linkwarn.cxx
@@ -0,0 +1,150 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2010 Novell, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+// MARKER(update_precomp.py): autogen include statement, do not remove
+#include "precompiled_svx.hxx"
+
+#include "linkwarn.hrc"
+#include "svx/linkwarn.hxx"
+#include "svx/dialogs.hrc"
+#include "svx/dialmgr.hxx"
+#include <vcl/msgbox.hxx>
+#include <sfx2/basedlgs.hxx>
+#include <svtools/miscopt.hxx>
+
+SvxLinkWarningDialog::SvxLinkWarningDialog( Window* pParent, const String& _rFileName ) :
+ SfxModalDialog( pParent, SVX_RES( RID_SVXDLG_LINK_WARNING ) ),
+ m_aQueryImage ( this, SVX_RES( FI_QUERY ) ),
+ m_aInfoText ( this, SVX_RES( FT_INFOTEXT ) ),
+ m_aLinkGraphicBtn ( this, SVX_RES( PB_OK ) ),
+ m_aEmbedGraphicBtn ( this, SVX_RES( PB_NO ) ),
+ m_aOptionLine ( this, SVX_RES( FL_OPTION ) ),
+ m_aWarningOnBox ( this, SVX_RES( CB_WARNING_OFF ) )
+{
+ FreeResource();
+
+ // set questionmark image
+ m_aQueryImage.SetImage( QueryBox::GetStandardImage() );
+
+ // replace filename
+ String sInfoText = m_aInfoText.GetText();
+ sInfoText.SearchAndReplaceAll(
+ UniString::CreateFromAscii(
+ RTL_CONSTASCII_STRINGPARAM( "%FILENAME" ) ), _rFileName );
+ m_aInfoText.SetText( sInfoText );
+
+ // load state of "warning on" checkbox from misc options
+ SvtMiscOptions aMiscOpt;
+ m_aWarningOnBox.Check( aMiscOpt.ShowLinkWarningDialog() == sal_True );
+ if( aMiscOpt.IsShowLinkWarningDialogReadOnly() )
+ m_aWarningOnBox.Disable();
+
+ // set focus to Cancel button
+ m_aEmbedGraphicBtn.GrabFocus();
+
+ // calculate and set the size of the dialog and its controls
+ InitSize();
+}
+
+// -----------------------------------------------------------------------
+
+SvxLinkWarningDialog::~SvxLinkWarningDialog()
+{
+ // save value of "warning off" checkbox, if necessary
+ SvtMiscOptions aMiscOpt;
+ sal_Bool bChecked = m_aWarningOnBox.IsChecked();
+ if ( aMiscOpt.ShowLinkWarningDialog() != bChecked )
+ aMiscOpt.SetShowLinkWarningDialog( bChecked );
+}
+
+// -----------------------------------------------------------------------
+
+void SvxLinkWarningDialog::InitSize()
+{
+ // text of checkbox to wide -> add new line
+ long nTxtW = m_aWarningOnBox.GetCtrlTextWidth( m_aWarningOnBox.GetText() ) + IMPL_EXTRA_BUTTON_WIDTH;
+ long nCtrlW = m_aWarningOnBox.GetSizePixel().Width();
+ if ( nTxtW >= nCtrlW )
+ {
+ long nTextHeight = m_aWarningOnBox.GetTextHeight();
+ Size aNewSize = m_aWarningOnBox.GetSizePixel();
+ aNewSize.Height() += nTextHeight;
+ m_aWarningOnBox.SetSizePixel( aNewSize );
+ aNewSize = GetSizePixel();
+ aNewSize.Height() += nTextHeight;
+ SetSizePixel( aNewSize );
+ }
+
+ // align the size of the information text control (FixedText) to its content
+ Size aMinSize = m_aInfoText.CalcMinimumSize( m_aInfoText.GetSizePixel().Width() );
+ long nTxtH = aMinSize.Height();
+ long nCtrlH = m_aInfoText.GetSizePixel().Height();
+ long nDelta = ( nCtrlH - nTxtH );
+ Size aNewSize = m_aInfoText.GetSizePixel();
+ aNewSize.Height() -= nDelta;
+ m_aInfoText.SetSizePixel( aNewSize );
+
+ // new position for the succeeding windows
+ Window* pWins[] =
+ {
+ &m_aLinkGraphicBtn, &m_aEmbedGraphicBtn, &m_aOptionLine, &m_aWarningOnBox
+ };
+ Window** pCurrent = pWins;
+ for ( sal_uInt32 i = 0; i < sizeof(pWins) / sizeof(*pWins); ++i, ++pCurrent )
+ {
+ Point aNewPos = (*pCurrent)->GetPosPixel();
+ aNewPos.Y() -= nDelta;
+ (*pCurrent)->SetPosPixel( aNewPos );
+ }
+
+ // new size of the dialog
+ aNewSize = GetSizePixel();
+ aNewSize.Height() -= nDelta;
+ SetSizePixel( aNewSize );
+
+ // recalculate the size and position of the buttons
+ nTxtW = m_aLinkGraphicBtn.GetCtrlTextWidth( m_aLinkGraphicBtn.GetText() );
+ long nTemp = m_aEmbedGraphicBtn.GetCtrlTextWidth( m_aEmbedGraphicBtn.GetText() );
+ if ( nTemp > nTxtW )
+ nTxtW = nTemp;
+ nTxtW += IMPL_EXTRA_BUTTON_WIDTH;
+ Size a3Size = LogicToPixel( Size( 3, 3 ), MAP_APPFONT );
+ Point aPos = m_aLinkGraphicBtn.GetPosPixel();
+ aPos.X() = ( aNewSize.Width() - (2*nTxtW) - a3Size.Width() ) / 2;
+ long nDefX = m_aWarningOnBox.GetPosPixel().X();
+ if ( nDefX < aPos.X() )
+ aPos.X() = nDefX;
+ aNewSize = m_aLinkGraphicBtn.GetSizePixel();
+ aNewSize.Width() = nTxtW;
+ m_aLinkGraphicBtn.SetPosSizePixel( aPos, aNewSize );
+ aPos.X() += nTxtW + a3Size.Width();
+ m_aEmbedGraphicBtn.SetPosSizePixel( aPos, aNewSize );
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/linkwarn.hrc b/svx/source/dialog/linkwarn.hrc
new file mode 100644
index 0000000000..d01dc88d8e
--- /dev/null
+++ b/svx/source/dialog/linkwarn.hrc
@@ -0,0 +1,60 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2010 Novell, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef _SVX_LINKWARN_HRC
+#define _SVX_LINKWARN_HRC
+
+#include <svtools/controldims.hrc>
+
+// dialog ids
+#define FI_QUERY 10
+#define FT_INFOTEXT 11
+#define PB_OK 12
+#define PB_NO 13
+#define FL_OPTION 15
+#define CB_WARNING_OFF 16
+
+// --------- general metrics ---------
+
+#define SYMBOL_EDGE 20
+#define DIALOG_WIDTH 220
+#define INFO_TEXT_LINES 11
+
+#define AW_COL_1 (RSC_SP_DLG_INNERBORDER_LEFT)
+#define AW_COL_2 (AW_COL_1+SYMBOL_EDGE+RSC_SP_CTRL_DESC_X)
+#define AW_COL_3 (AW_COL_2+RSC_CD_PUSHBUTTON_WIDTH+RSC_SP_CTRL_DESC_X)
+#define AW_COL_4 (DIALOG_WIDTH-RSC_SP_DLG_INNERBORDER_RIGHT-RSC_CD_PUSHBUTTON_WIDTH)
+
+#define AW_ROW_1 (RSC_SP_DLG_INNERBORDER_TOP)
+#define AW_ROW_2 (AW_ROW_1+INFO_TEXT_LINES*RSC_CD_FIXEDTEXT_HEIGHT+RSC_SP_CTRL_Y)
+#define AW_ROW_3 (AW_ROW_2+RSC_CD_PUSHBUTTON_HEIGHT+RSC_SP_CTRL_DESC_Y)
+#define AW_ROW_4 (AW_ROW_3+RSC_CD_FIXEDLINE_HEIGHT+RSC_SP_CTRL_DESC_Y)
+
+#define DIALOG_HEIGHT (AW_ROW_4+RSC_CD_CHECKBOX_HEIGHT+RSC_SP_DLG_INNERBORDER_BOTTOM)
+
+#endif
diff --git a/svx/source/dialog/linkwarn.src b/svx/source/dialog/linkwarn.src
new file mode 100644
index 0000000000..100b53cb6e
--- /dev/null
+++ b/svx/source/dialog/linkwarn.src
@@ -0,0 +1,85 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ * Copyright 2010 Novell, Inc.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include "linkwarn.hrc"
+#include "svx/dialogs.hrc"
+#include "helpid.hrc"
+
+ModalDialog RID_SVXDLG_LINK_WARNING
+{
+ Size = MAP_APPFONT( DIALOG_WIDTH, DIALOG_HEIGHT );
+ OutputSize = TRUE;
+ Closeable = FALSE;
+ Moveable = TRUE;
+ SVLook = TRUE;
+
+ Text = "%PRODUCTNAME %PRODUCTVERSION %PRODUCTEXTENSION";
+
+ FixedImage FI_QUERY
+ {
+ Pos = MAP_APPFONT( AW_COL_1, AW_ROW_1 );
+ Size = MAP_APPFONT( SYMBOL_EDGE, SYMBOL_EDGE );
+ };
+ FixedText FT_INFOTEXT
+ {
+ Pos = MAP_APPFONT( AW_COL_2, AW_ROW_1 );
+ Size = MAP_APPFONT( DIALOG_WIDTH-AW_COL_2-RSC_SP_DLG_INNERBORDER_RIGHT, INFO_TEXT_LINES*RSC_CD_FIXEDTEXT_HEIGHT );
+ NoLabel = TRUE;
+ Wordbreak = TRUE;
+ Text [ en-US ] = "The file %FILENAME will not be stored along with your document, but only referenced as a link. This is dangerous if you move and/or rename the files. Do you want to embed the graphic instead?";
+ Text [ de-DE ] = "Die Datei %FILENAME wird nicht zusammen mit dem Dokument gespeichert, sondern nur als Verweis referenziert. Dies kann zu Problemen führen, wenn die Dateien verschoben und/oder umbenannt werden. Möchten Sie stattdessen die Grafik als eingebettetes Objekt einfügen?";
+ };
+ OKButton PB_OK
+ {
+ Pos = MAP_APPFONT( AW_COL_2, AW_ROW_2 );
+ Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT );
+ DefButton = TRUE ;
+ Text [ en-US ] = "~Keep Link";
+ Text [ de-DE ] = "~Als Verweis einfügen";
+ };
+ CancelButton PB_NO
+ {
+ Pos = MAP_APPFONT( AW_COL_3, AW_ROW_2 );
+ Size = MAP_APPFONT( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT );
+ Text [ en-US ] = "~Embed Graphic";
+ Text [ de-DE ] = "~Eingebettet einfügen";
+ };
+ FixedLine FL_OPTION
+ {
+ Pos = MAP_APPFONT( 0, AW_ROW_3 );
+ Size = MAP_APPFONT( DIALOG_WIDTH, RSC_CD_FIXEDLINE_HEIGHT );
+ };
+ CheckBox CB_WARNING_OFF
+ {
+ Pos = MAP_APPFONT( AW_COL_2, AW_ROW_4 );
+ Size = MAP_APPFONT( DIALOG_WIDTH-AW_COL_2-RSC_SP_DLG_INNERBORDER_RIGHT, RSC_CD_CHECKBOX_HEIGHT );
+ WordBreak = TRUE ;
+ Text [ en-US ] = "~Ask when linking a graphic";
+ Text [ de-DE ] = "~Nachfragen falls Grafik als Verweis eingefügt wird";
+ };
+};
diff --git a/svx/source/dialog/makefile.mk b/svx/source/dialog/makefile.mk
index 2c91e2acaf..a42bdee343 100644
--- a/svx/source/dialog/makefile.mk
+++ b/svx/source/dialog/makefile.mk
@@ -108,6 +108,7 @@ LIB2OBJFILES= \
$(SLO)$/hyprlink.obj \
$(SLO)$/imapdlg.obj \
$(SLO)$/imapwnd.obj \
+ $(SLO)$/linkwarn.obj \
$(SLO)$/measctrl.obj \
$(SLO)$/orienthelper.obj \
$(SLO)$/pagectrl.obj \
diff --git a/svx/source/dialog/measctrl.cxx b/svx/source/dialog/measctrl.cxx
index ba7c0deb74..6a706d9b98 100644
--- a/svx/source/dialog/measctrl.cxx
+++ b/svx/source/dialog/measctrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -197,3 +198,4 @@ void SvxXMeasurePreview::DataChanged( const DataChangedEvent& rDCEvt )
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/optgrid.cxx b/svx/source/dialog/optgrid.cxx
index 0f35520db2..8fbfdc2576 100644
--- a/svx/source/dialog/optgrid.cxx
+++ b/svx/source/dialog/optgrid.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,9 +44,7 @@
#include "optgrid.hrc"
#include "svx/dlgutil.hxx"
-/* -----------------18.08.98 17:41-------------------
- * local functions
- * --------------------------------------------------*/
+// local functions
void lcl_GetMinMax(MetricField& rField, long& nFirst, long& nLast, long& nMin, long& nMax)
{
nFirst = static_cast<long>(rField.Denormalize( rField.GetFirst( FUNIT_TWIP ) ));
@@ -109,19 +108,11 @@ SvxGridItem::SvxGridItem( const SvxGridItem& rItem )
};
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
SfxPoolItem* SvxGridItem::Clone( SfxItemPool* ) const
{
return new SvxGridItem( *this );
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
int SvxGridItem::operator==( const SfxPoolItem& rAttr ) const
{
DBG_ASSERT( SfxPoolItem::operator==(rAttr), "unterschiedliche Typen" );
@@ -140,10 +131,6 @@ int SvxGridItem::operator==( const SfxPoolItem& rAttr ) const
nFldSnapY == rItem.nFldSnapY );
}
-/*--------------------------------------------------------------------
- Beschreibung:
- --------------------------------------------------------------------*/
-
SfxItemPresentation SvxGridItem::GetPresentation
(
SfxItemPresentation ePres,
@@ -166,11 +153,7 @@ SfxItemPresentation SvxGridItem::GetPresentation
}
}
-
-/*----------------- OS 23.02.95 -----------------------
- TabPage Rastereinstellungen
--------------------------------------------------------*/
-
+// TabPage Rastereinstellungen
SvxGridTabPage::SvxGridTabPage( Window* pParent, const SfxItemSet& rCoreSet) :
SfxTabPage( pParent, SVX_RES( RID_SVXPAGE_GRID ), rCoreSet ),
@@ -413,3 +396,4 @@ IMPL_LINK( SvxGridTabPage, ChangeGridsnapHdl_Impl, void *, EMPTYARG )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/orienthelper.cxx b/svx/source/dialog/orienthelper.cxx
index 1d5b9d6ad6..9594139503 100644
--- a/svx/source/dialog/orienthelper.cxx
+++ b/svx/source/dialog/orienthelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -32,7 +33,6 @@
#include <vector>
#include <utility>
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
#endif
#include "svx/dialcontrol.hxx"
@@ -204,3 +204,4 @@ void OrientStackedWrapper::SetControlValue( bool bValue )
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/pagectrl.cxx b/svx/source/dialog/pagectrl.cxx
index 94dcc23712..19a91a1199 100644
--- a/svx/source/dialog/pagectrl.cxx
+++ b/svx/source/dialog/pagectrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -45,7 +46,7 @@ struct PageWindow_Impl
{
SvxBoxItem* pBorder;
Bitmap aBitmap;
- FASTBOOL bBitmap;
+ bool bBitmap;
sal_Bool bResetBackground;
sal_Bool bFrameDirection;
sal_Int32 nFrameDirection;
@@ -122,7 +123,7 @@ SvxPageWindow::~SvxPageWindow()
// -----------------------------------------------------------------------
-void __EXPORT SvxPageWindow::Paint( const Rectangle& )
+void SvxPageWindow::Paint( const Rectangle& )
{
Fraction aXScale( aWinSize.Width(), std::max( (long) (aSize.Width() * 2 + aSize.Width() / 8), 1L ) );
Fraction aYScale( aWinSize.Height(), std::max( aSize.Height(), 1L ) );
@@ -400,16 +401,12 @@ void SvxPageWindow::SetFtBorder( const SvxBoxItem& rNew )
delete pFtBorder;
pFtBorder = new SvxBoxItem( rNew );
}
-/* -----------------------------13.06.2002 16:16------------------------------
- ---------------------------------------------------------------------------*/
void SvxPageWindow::EnableFrameDirection(sal_Bool bEnable)
{
pImpl->EnableFrameDirection(bEnable);
}
-/* -----------------------------13.06.2002 16:16------------------------------
- ---------------------------------------------------------------------------*/
void SvxPageWindow::SetFrameDirection(sal_Int32 nFrameDirection)
{
pImpl->SetFrameDirection(nFrameDirection);
@@ -419,3 +416,5 @@ void SvxPageWindow::ResetBackground()
{
pImpl->bResetBackground = sal_True;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/paraprev.cxx b/svx/source/dialog/paraprev.cxx
index 2b2baa07e3..9d24138834 100644
--- a/svx/source/dialog/paraprev.cxx
+++ b/svx/source/dialog/paraprev.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -236,3 +237,4 @@ void SvxParaPrevWindow::OutputSizeChanged()
Invalidate();
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/passwd.cxx b/svx/source/dialog/passwd.cxx
index 386681b6fe..b4d9f2dcef 100644
--- a/svx/source/dialog/passwd.cxx
+++ b/svx/source/dialog/passwd.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
// include ---------------------------------------------------------------
#include <tools/shl.hxx>
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#define _SVX_PASSWD_CXX
@@ -134,3 +133,4 @@ SvxPasswordDialog::~SvxPasswordDialog()
// -----------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/pfiledlg.cxx b/svx/source/dialog/pfiledlg.cxx
index ae11f94ba5..ae860ac5c5 100644
--- a/svx/source/dialog/pfiledlg.cxx
+++ b/svx/source/dialog/pfiledlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44,8 +45,8 @@
using namespace ::rtl;
using namespace ::com::sun::star;
-sal_Char __READONLY_DATA sAudio[] = "audio";
-sal_Char __READONLY_DATA sVideo[] = "video";
+sal_Char const sAudio[] = "audio";
+sal_Char const sVideo[] = "video";
/*************************************************************************
|*
@@ -87,7 +88,7 @@ SvxPluginFileDlg::SvxPluginFileDlg (Window *, sal_uInt16 nKind ) :
if( xMgr.is() )
{
uno::Reference< plugin::XPluginManager > rPluginManager( xMgr->createInstance(
- OUString::createFromAscii( "com.sun.star.plugin.PluginManager" ) ), uno::UNO_QUERY );
+ OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.plugin.PluginManager")) ), uno::UNO_QUERY );
if ( rPluginManager.is() )
{
const uno::Sequence<plugin::PluginDescription > aSeq( rPluginManager->getPluginDescriptions() );
@@ -232,7 +233,7 @@ bool SvxPluginFileDlg::IsAvailable (sal_uInt16 nKind)
if( xMgr.is() )
{
- uno::Reference< plugin::XPluginManager > rPluginManager = uno::Reference< plugin::XPluginManager > ( xMgr->createInstance( OUString::createFromAscii( "com.sun.star.plugin.PluginManager" ) ), uno::UNO_QUERY );
+ uno::Reference< plugin::XPluginManager > rPluginManager = uno::Reference< plugin::XPluginManager > ( xMgr->createInstance( OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.plugin.PluginManager")) ), uno::UNO_QUERY );
if( rPluginManager.is() )
{
const uno::Sequence<plugin::PluginDescription > aSeq( rPluginManager->getPluginDescriptions() );
@@ -278,3 +279,5 @@ void SvxPluginFileDlg::SetContext( sfx2::FileDialogHelper::Context _eNewContext
{
maFileDlg.SetContext( _eNewContext );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/prtqry.cxx b/svx/source/dialog/prtqry.cxx
index ccf932be6a..5fdc3e8136 100644
--- a/svx/source/dialog/prtqry.cxx
+++ b/svx/source/dialog/prtqry.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_svx.hxx"
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
#endif
#include <svx/prtqry.hxx>
#include <svx/dialmgr.hxx>
#include <tools/shl.hxx>
-/* -----------------------------01.02.00 13:57--------------------------------
-
- ---------------------------------------------------------------------------*/
SvxPrtQryBox::SvxPrtQryBox(Window* pParent) :
MessBox(pParent, 0,
String(SVX_RES(RID_SVXSTR_QRY_PRINT_TITLE)),
@@ -52,11 +49,10 @@ SvxPrtQryBox::SvxPrtQryBox(Window* pParent) :
AddButton(BUTTON_CANCEL, RET_CANCEL, BUTTONDIALOG_CANCELBUTTON);
SetButtonHelpText( RET_OK, String() );
}
-/* -----------------------------01.02.00 13:57--------------------------------
- ---------------------------------------------------------------------------*/
SvxPrtQryBox::~SvxPrtQryBox()
{
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/relfld.cxx b/svx/source/dialog/relfld.cxx
index 7f627762fc..6a6e4259ff 100644
--- a/svx/source/dialog/relfld.cxx
+++ b/svx/source/dialog/relfld.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -144,3 +145,4 @@ void SvxRelativeField::SetRelative( BOOL bNewRelative )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/rlrcitem.cxx b/svx/source/dialog/rlrcitem.cxx
index ad37ef2704..37d7877b21 100644
--- a/svx/source/dialog/rlrcitem.cxx
+++ b/svx/source/dialog/rlrcitem.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -164,3 +165,4 @@ void SvxRulerItem::StateChanged( USHORT nSID, SfxItemState eState,
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/rlrcitem.hxx b/svx/source/dialog/rlrcitem.hxx
index 64eafd2af3..7c643c4f73 100644
--- a/svx/source/dialog/rlrcitem.hxx
+++ b/svx/source/dialog/rlrcitem.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/rubydialog.cxx b/svx/source/dialog/rubydialog.cxx
index bad0e1c2d1..8e7c2fb9c1 100644
--- a/svx/source/dialog/rubydialog.cxx
+++ b/svx/source/dialog/rubydialog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,9 +48,7 @@
#include <com/sun/star/text/RubyAdjust.hpp>
#include <com/sun/star/view/XSelectionChangeListener.hpp>
#include <com/sun/star/view/XSelectionSupplier.hpp>
-#ifndef _CPPUHELPER_IMPLBASE3_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
#include <svtools/colorcfg.hxx>
using namespace com::sun::star::uno;
@@ -75,9 +74,7 @@ static const sal_Char cRubyIsAbove[] = "RubyIsAbove";
static const sal_Char cDisplayName[] = "DisplayName";
static const sal_Char cRubyCharStyleName[] = "RubyCharStyleName";
static const sal_Char cRubies[] = "Rubies";
-/* -----------------------------09.01.01 17:24--------------------------------
- ---------------------------------------------------------------------------*/
SvxRubyChildWindow::SvxRubyChildWindow( Window* _pParent, USHORT nId,
SfxBindings* pBindings, SfxChildWinInfo* pInfo) :
SfxChildWindow(_pParent, nId)
@@ -92,16 +89,12 @@ SvxRubyChildWindow::SvxRubyChildWindow( Window* _pParent, USHORT nId,
pDlg->Initialize( pInfo );
}
-/* -----------------------------10.01.01 13:53--------------------------------
- ---------------------------------------------------------------------------*/
SfxChildWinInfo SvxRubyChildWindow::GetInfo() const
{
return SfxChildWindow::GetInfo();
}
-/* -----------------------------09.01.01 17:17--------------------------------
- ---------------------------------------------------------------------------*/
class SvxRubyData_Impl : public cppu::WeakImplHelper1
< ::com::sun::star::view::XSelectionChangeListener >
{
@@ -278,18 +271,14 @@ SvxRubyDialog::SvxRubyDialog( SfxBindings *pBind, SfxChildWindow *pCW,
UpdateColors();
}
-/* -----------------------------09.01.01 17:17--------------------------------
- ---------------------------------------------------------------------------*/
SvxRubyDialog::~SvxRubyDialog()
{
ClearCharStyleList();
EventObject aEvent;
xImpl->disposing(aEvent);
}
-/* -----------------------------01.02.01 10:29--------------------------------
- ---------------------------------------------------------------------------*/
void SvxRubyDialog::ClearCharStyleList()
{
for(USHORT i = 0; i < aCharStyleLB.GetEntryCount(); i++)
@@ -299,9 +288,7 @@ void SvxRubyDialog::ClearCharStyleList()
}
aCharStyleLB.Clear();
}
-/* -----------------------------09.01.01 17:17--------------------------------
- ---------------------------------------------------------------------------*/
BOOL SvxRubyDialog::Close()
{
pBindings->GetDispatcher()->Execute( SID_RUBY_DIALOG,
@@ -309,9 +296,7 @@ BOOL SvxRubyDialog::Close()
SFX_CALLMODE_RECORD);
return TRUE;
}
-/* -----------------------------29.01.01 15:26--------------------------------
- ---------------------------------------------------------------------------*/
void SvxRubyDialog::Activate()
{
SfxModelessDialog::Activate();
@@ -393,16 +378,12 @@ void SvxRubyDialog::Activate()
aPreviewWin.Invalidate();
}
}
-/* -----------------------------29.01.01 15:26--------------------------------
- ---------------------------------------------------------------------------*/
void SvxRubyDialog::Deactivate()
{
SfxModelessDialog::Deactivate();
}
-/* -----------------------------30.01.01 15:35--------------------------------
- ---------------------------------------------------------------------------*/
void SvxRubyDialog::SetText(sal_Int32 nPos, Edit& rLeft, Edit& rRight)
{
OUString sLeft, sRight;
@@ -536,17 +517,13 @@ void SvxRubyDialog::Update()
ScrollHdl_Impl(&aScrollSB);
}
-/* -----------------------------16.02.01 14:01--------------------------------
- ---------------------------------------------------------------------------*/
void SvxRubyDialog::GetCurrentText(String& rBase, String& rRuby)
{
rBase = aEditArr[nCurrentEdit * 2]->GetText();
rRuby = aEditArr[nCurrentEdit * 2 + 1]->GetText();
}
-/* -----------------------------31.01.01 14:09--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, ScrollHdl_Impl, ScrollBar*, pScroll)
{
long nPos = pScroll->GetThumbPos();
@@ -562,9 +539,7 @@ IMPL_LINK(SvxRubyDialog, ScrollHdl_Impl, ScrollBar*, pScroll)
aPreviewWin.Invalidate();
return 0;
}
-/* -----------------------------30.01.01 14:48--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, ApplyHdl_Impl, PushButton*, EMPTYARG)
{
const Sequence<PropertyValues>& aRubyValues = pImpl->GetRubyValues();
@@ -593,17 +568,13 @@ IMPL_LINK(SvxRubyDialog, ApplyHdl_Impl, PushButton*, EMPTYARG)
}
return 0;
}
-/* -----------------------------29.01.01 09:38--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, CloseHdl_Impl, PushButton*, EMPTYARG)
{
Close();
return 0;
}
-/* -----------------------------29.01.01 15:10--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, StylistHdl_Impl, PushButton*, EMPTYARG)
{
SfxPoolItem* pState = 0;
@@ -616,18 +587,14 @@ IMPL_LINK(SvxRubyDialog, StylistHdl_Impl, PushButton*, EMPTYARG)
}
return 0;
}
-/* -----------------------------30.01.01 15:32--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, AutomaticHdl_Impl, CheckBox*, pBox)
{
pImpl->UpdateRubyValues(pBox->IsChecked());
Update();
return 0;
}
-/* -----------------------------31.01.01 16:37--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, AdjustHdl_Impl, ListBox*, pBox)
{
AssertOneEntry();
@@ -647,9 +614,7 @@ IMPL_LINK(SvxRubyDialog, AdjustHdl_Impl, ListBox*, pBox)
aPreviewWin.Invalidate();
return 0;
}
-/* -----------------------------01.06.01 10:24--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, PositionHdl_Impl, ListBox*, pBox)
{
AssertOneEntry();
@@ -670,9 +635,7 @@ IMPL_LINK(SvxRubyDialog, PositionHdl_Impl, ListBox*, pBox)
aPreviewWin.Invalidate();
return 0;
}
-/* -----------------------------01.02.01 10:06--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, CharStyleHdl_Impl, ListBox*, EMPTYARG )
{
AssertOneEntry();
@@ -695,9 +658,7 @@ IMPL_LINK(SvxRubyDialog, CharStyleHdl_Impl, ListBox*, EMPTYARG )
}
return 0;
}
-/* -----------------------------16.02.01 08:35--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, EditModifyHdl_Impl, Edit*, pEdit)
{
for(USHORT i = 0; i < 8; i++)
@@ -711,9 +672,7 @@ IMPL_LINK(SvxRubyDialog, EditModifyHdl_Impl, Edit*, pEdit)
aPreviewWin.Invalidate();
return 0;
}
-/* -----------------------------17.07.01 09:11--------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, EditScrollHdl_Impl, sal_Int32*, pParam)
{
long nRet = 0;
@@ -741,9 +700,7 @@ IMPL_LINK(SvxRubyDialog, EditScrollHdl_Impl, sal_Int32*, pParam)
}
return nRet;
}
-/* -----------------------------20.07.2001 15:18------------------------------
- ---------------------------------------------------------------------------*/
IMPL_LINK(SvxRubyDialog, EditJumpHdl_Impl, sal_Int32*, pParam)
{
USHORT nIndex = USHRT_MAX;
@@ -771,9 +728,7 @@ IMPL_LINK(SvxRubyDialog, EditJumpHdl_Impl, sal_Int32*, pParam)
}
return 0;
};
-/* -----------------------------19.06.01 11:33--------------------------------
- ---------------------------------------------------------------------------*/
void SvxRubyDialog::AssertOneEntry()
{
pImpl->AssertOneEntry();
@@ -811,9 +766,6 @@ void SvxRubyDialog::DataChanged( const DataChangedEvent& rDCEvt )
UpdateColors();
}
-/* -----------------------------29.01.01 15:44--------------------------------
-
- ---------------------------------------------------------------------------*/
void lcl_MoveBox(long nOffset, Edit& rLeft, Edit& rRight)
{
Size aLeftSz(rLeft.GetSizePixel());
@@ -826,9 +778,7 @@ void lcl_MoveBox(long nOffset, Edit& rLeft, Edit& rRight)
rRight.SetPosSizePixel(aRightPos, aRightSz);
}
-/* -----------------------------16.02.01 08:09--------------------------------
- ---------------------------------------------------------------------------*/
RubyPreview::RubyPreview(SvxRubyDialog& rParent, const ResId& rResId) :
Window(&rParent, rResId),
rParentDlg(rParent)
@@ -842,9 +792,7 @@ RubyPreview::RubyPreview(SvxRubyDialog& rParent, const ResId& rResId) :
SetBorderStyle( WINDOW_BORDER_MONO );
}
-/* -----------------------------29.01.01 14:05--------------------------------
- ---------------------------------------------------------------------------*/
void RubyPreview::Paint( const Rectangle& /* rRect */ )
{
Font aRubyFont = GetFont();
@@ -951,17 +899,13 @@ void RubyPreview::Paint( const Rectangle& /* rRect */ )
}
SetFont(aSaveFont);
}
-/* -----------------------------16.02.01 15:12--------------------------------
- ---------------------------------------------------------------------------*/
void RubyEdit::GetFocus()
{
GetModifyHdl().Call(this);
Edit::GetFocus();
}
-/* -----------------------------17.07.01 09:00--------------------------------
- ---------------------------------------------------------------------------*/
long RubyEdit::PreNotify( NotifyEvent& rNEvt )
{
long nHandled = 0;
@@ -988,3 +932,4 @@ long RubyEdit::PreNotify( NotifyEvent& rNEvt )
return nHandled;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/ruler.hrc b/svx/source/dialog/ruler.hrc
index 8031270272..101130bbb7 100644
--- a/svx/source/dialog/ruler.hrc
+++ b/svx/source/dialog/ruler.hrc
@@ -34,4 +34,5 @@
#define ID_MILE 10
#define ID_POINT 6
#define ID_PICA 7
-
+#define ID_CHAR 11
+#define ID_LINE 12
diff --git a/svx/source/dialog/ruler.src b/svx/source/dialog/ruler.src
index 5937ab99fb..b30ca44b5e 100644
--- a/svx/source/dialog/ruler.src
+++ b/svx/source/dialog/ruler.src
@@ -87,6 +87,18 @@ Menu RID_SVXMN_RULER
Checkable = TRUE ;
Text [ en-US ] = "Pica" ;
};
+ MenuItem
+ {
+ Identifier = ID_CHAR ;
+ Checkable = TRUE ;
+ Text[ en-US ] = "Char" ;
+ };
+ MenuItem
+ {
+ Identifier = ID_LINE ;
+ Checkable = TRUE ;
+ Text[ en-US ] = "Line" ;
+ };
};
};
String RID_SVXSTR_RULER_TAB_LEFT
diff --git a/svx/source/dialog/rulritem.cxx b/svx/source/dialog/rulritem.cxx
index 9c01948296..4bf1eca9ae 100644
--- a/svx/source/dialog/rulritem.cxx
+++ b/svx/source/dialog/rulritem.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,7 +64,7 @@ String SvxLongLRSpaceItem::GetValueText() const
#define TWIP_TO_MM100(TWIP) ((TWIP) >= 0 ? (((TWIP)*127L+36L)/72L) : (((TWIP)*127L-36L)/72L))
#define MM100_TO_TWIP(MM100) ((MM100) >= 0 ? (((MM100)*72L+63L)/127L) : (((MM100)*72L-63L)/127L))
-sal_Bool SvxLongLRSpaceItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
+bool SvxLongLRSpaceItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
{
sal_Bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
nMemberId &= ~CONVERT_TWIPS;
@@ -82,18 +83,18 @@ sal_Bool SvxLongLRSpaceItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE
case MID_LEFT: nVal = lLeft; break;
case MID_RIGHT: nVal = lRight; break;
- default: DBG_ERROR("Wrong MemberId!"); return sal_False;
+ default: DBG_ERROR("Wrong MemberId!"); return false;
}
if ( bConvert )
nVal = TWIP_TO_MM100( nVal );
rVal <<= nVal;
- return TRUE;
+ return true;
}
// -----------------------------------------------------------------------
-sal_Bool SvxLongLRSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, BYTE nMemberId )
+bool SvxLongLRSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, BYTE nMemberId )
{
sal_Bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
nMemberId &= ~CONVERT_TWIPS;
@@ -106,7 +107,7 @@ sal_Bool SvxLongLRSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, B
{
lLeft = bConvert ? MM100_TO_TWIP( aLeftRightMargin.Left ) : aLeftRightMargin.Left;
lRight = bConvert ? MM100_TO_TWIP( aLeftRightMargin.Right ) : aLeftRightMargin.Right;
- return sal_True;
+ return true;
}
}
else if ( rVal >>= nVal )
@@ -118,13 +119,13 @@ sal_Bool SvxLongLRSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, B
{
case MID_LEFT: lLeft = nVal; break;
case MID_RIGHT: lRight = nVal; break;
- default: DBG_ERROR("Wrong MemberId!"); return sal_False;
+ default: DBG_ERROR("Wrong MemberId!"); return false;
}
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
}
//------------------------------------------------------------------------
@@ -189,7 +190,7 @@ String SvxLongULSpaceItem::GetValueText() const
return String();
}
-sal_Bool SvxLongULSpaceItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
+bool SvxLongULSpaceItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
{
sal_Bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
nMemberId &= ~CONVERT_TWIPS;
@@ -203,23 +204,23 @@ sal_Bool SvxLongULSpaceItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE
aUpperLowerMargin.Upper = bConvert ? TWIP_TO_MM100( lLeft ) : lLeft;
aUpperLowerMargin.Lower = bConvert ? TWIP_TO_MM100( lRight ) : lRight;
rVal <<= aUpperLowerMargin;
- return TRUE;
+ return true;
}
case MID_UPPER: nVal = lLeft; break;
case MID_LOWER: nVal = lRight; break;
- default: DBG_ERROR("Wrong MemberId!"); return sal_False;
+ default: DBG_ERROR("Wrong MemberId!"); return false;
}
if ( bConvert )
nVal = TWIP_TO_MM100( nVal );
rVal <<= nVal;
- return TRUE;
+ return true;
}
// -----------------------------------------------------------------------
-sal_Bool SvxLongULSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, BYTE nMemberId )
+bool SvxLongULSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, BYTE nMemberId )
{
sal_Bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
nMemberId &= ~CONVERT_TWIPS;
@@ -232,7 +233,7 @@ sal_Bool SvxLongULSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, B
{
lLeft = bConvert ? MM100_TO_TWIP( aUpperLowerMargin.Upper ) : aUpperLowerMargin.Upper;
lRight = bConvert ? MM100_TO_TWIP( aUpperLowerMargin.Lower ) : aUpperLowerMargin.Lower;
- return sal_True;
+ return true;
}
}
else if ( rVal >>= nVal )
@@ -244,13 +245,13 @@ sal_Bool SvxLongULSpaceItem::PutValue( const ::com::sun::star::uno::Any& rVal, B
{
case MID_UPPER: lLeft = nVal; break;
case MID_LOWER: lRight = nVal; break;
- default: DBG_ERROR("Wrong MemberId!"); return sal_False;
+ default: DBG_ERROR("Wrong MemberId!"); return false;
}
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
}
//------------------------------------------------------------------------
@@ -307,7 +308,7 @@ int SvxPagePosSizeItem::operator==( const SfxPoolItem& rCmp) const
lHeight == ((const SvxPagePosSizeItem &)rCmp).lHeight;
}
-sal_Bool SvxPagePosSizeItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
+bool SvxPagePosSizeItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
{
nMemberId &= ~CONVERT_TWIPS;
@@ -322,22 +323,22 @@ sal_Bool SvxPagePosSizeItem::QueryValue( ::com::sun::star::uno::Any& rVal, BYTE
aPagePosSize.Width = lWidth;
aPagePosSize.Height = lHeight;
rVal <<= aPagePosSize;
- return TRUE;
+ return true;
}
-
+
case MID_X: nVal = aPos.X(); break;
case MID_Y: nVal = aPos.Y(); break;
case MID_WIDTH: nVal = lWidth; break;
case MID_HEIGHT: nVal = lHeight; break;
- default: DBG_ERROR("Wrong MemberId!"); return sal_False;
+ default: DBG_ERROR("Wrong MemberId!"); return false;
}
rVal <<= nVal;
- return TRUE;
+ return true;
}
-sal_Bool SvxPagePosSizeItem::PutValue( const ::com::sun::star::uno::Any& rVal, BYTE nMemberId )
+bool SvxPagePosSizeItem::PutValue( const ::com::sun::star::uno::Any& rVal, BYTE nMemberId )
{
nMemberId &= ~CONVERT_TWIPS;
@@ -364,14 +365,14 @@ sal_Bool SvxPagePosSizeItem::PutValue( const ::com::sun::star::uno::Any& rVal, B
case MID_Y: aPos.Y() = nVal; break;
case MID_WIDTH: lWidth = nVal; break;
case MID_HEIGHT: lHeight = nVal; break;
-
+
default: DBG_ERROR("Wrong MemberId!"); return sal_False;
}
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
}
//------------------------------------------------------------------------
@@ -595,14 +596,14 @@ long SvxColumnItem::GetVisibleRight() const
return (*this)[nIdx].nEnd;
}
-sal_Bool SvxColumnItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
+bool SvxColumnItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
{
nMemberId &= ~CONVERT_TWIPS;
switch ( nMemberId )
{
case MID_COLUMNARRAY:
{
- return sal_False;
+ return false;
}
case MID_RIGHT: rVal <<= nRight; break;
case MID_LEFT: rVal <<= nLeft; break;
@@ -612,10 +613,10 @@ sal_Bool SvxColumnItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMember
default: DBG_ERROR("Wrong MemberId!"); return sal_False;
}
- return sal_True;
+ return true;
}
-sal_Bool SvxColumnItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMemberId )
+bool SvxColumnItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMemberId )
{
nMemberId &= ~CONVERT_TWIPS;
sal_Int32 nVal = 0;
@@ -623,7 +624,7 @@ sal_Bool SvxColumnItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMe
{
case MID_COLUMNARRAY:
{
- return sal_False;
+ return false;
}
case MID_RIGHT: rVal >>= nRight; break;
case MID_LEFT: rVal >>= nLeft; break;
@@ -633,7 +634,7 @@ sal_Bool SvxColumnItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMe
default: DBG_ERROR("Wrong MemberId!"); return sal_False;
}
- return sal_True;
+ return true;
}
//------------------------------------------------------------------------
@@ -706,7 +707,7 @@ SvxObjectItem::SvxObjectItem( const SvxObjectItem& rCopy ) :
{
}
-sal_Bool SvxObjectItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
+bool SvxObjectItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMemberId ) const
{
nMemberId &= ~CONVERT_TWIPS;
switch ( nMemberId )
@@ -721,13 +722,13 @@ sal_Bool SvxObjectItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMember
return sal_False;
}
- return TRUE;
+ return true;
}
-sal_Bool SvxObjectItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMemberId )
+bool SvxObjectItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMemberId )
{
nMemberId &= ~CONVERT_TWIPS;
- BOOL bRet=FALSE;
+ BOOL bRet = false;
switch ( nMemberId )
{
case MID_START_X : bRet = (rVal >>= nStartX); break;
@@ -741,3 +742,4 @@ sal_Bool SvxObjectItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMe
return bRet;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/sendreportgen.cxx b/svx/source/dialog/sendreportgen.cxx
index 2690d4b392..75c8d9eb9e 100644
--- a/svx/source/dialog/sendreportgen.cxx
+++ b/svx/source/dialog/sendreportgen.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,3 +52,5 @@ namespace svx{
} // namespace DocRecovery
} // namespace svx
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/sendreportunx.cxx b/svx/source/dialog/sendreportunx.cxx
index 657399ca3c..2362cc3bea 100644
--- a/svx/source/dialog/sendreportunx.cxx
+++ b/svx/source/dialog/sendreportunx.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -270,3 +271,5 @@ namespace svx{
} // namespace DocRecovery
} // namespace svx
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/sendreportw32.cxx b/svx/source/dialog/sendreportw32.cxx
index 61c4daa0f7..b50dc0c0ca 100644
--- a/svx/source/dialog/sendreportw32.cxx
+++ b/svx/source/dialog/sendreportw32.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,6 +39,7 @@
#include <tchar.h>
#include <stdio.h>
#include <systools/win32/uwinapi.h>
+#include <sal/macros.h>
// need to undef min and max macros from MS headers here to make
// the std::min and std::max from stl visible again
@@ -198,7 +200,7 @@ namespace svx{
TCHAR szTempPath[MAX_PATH];
TCHAR szFileName[MAX_PATH];
- GetTempPath( elementsof(szTempPath), szTempPath );
+ GetTempPath( SAL_N_ELEMENTS(szTempPath), szTempPath );
GetTempFileName( szTempPath, TEXT("DSC"), 0, szFileName );
FILE *fp = _tfopen( szFileName, _T("wb") );
@@ -225,7 +227,7 @@ namespace svx{
ZeroMemory( &StartupInfo, sizeof(StartupInfo) );
StartupInfo.cb = sizeof(StartupInfo.cb);
- sntprintf( szBuffer, elementsof(szBuffer),
+ sntprintf( szBuffer, SAL_N_ELEMENTS(szBuffer),
_T("%s -noui -load -send"),
szPath );
@@ -258,3 +260,5 @@ namespace svx{
} // namespace DocRecovery
} // namespace svx
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/simptabl.cxx b/svx/source/dialog/simptabl.cxx
index c32d151d90..a3c1814d7b 100644
--- a/svx/source/dialog/simptabl.cxx
+++ b/svx/source/dialog/simptabl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,9 +34,7 @@
#include <svx/simptabl.hxx>
#include <vcl/svapp.hxx>
-#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
-#endif
#include <unotools/intlwrapper.hxx>
// SvxSimpTblContainer ------------------------------------------------------
@@ -226,7 +225,6 @@ void SvxSimpleTable::Paint( const Rectangle& rRect )
SvHeaderTabListBox::Paint(rRect );
USHORT nPrivTabCount = TabCount();
- USHORT nPos = 0;
USHORT nNewSize = ( nPrivTabCount > 0 ) ? (USHORT)GetTab(0) : 0;
long nOffset=-GetXOffset();
@@ -240,6 +238,7 @@ void SvxSimpleTable::Paint( const Rectangle& rRect )
if(nPrivTabCount>aHeaderBar.GetItemCount())
nPrivTabCount=aHeaderBar.GetItemCount();
+ USHORT nPos = 0;
for(USHORT i=1;i<nPrivTabCount;i++)
{
nNewSize = static_cast< USHORT >( GetTab(i) ) - nPos;
@@ -442,15 +441,14 @@ void SvxSimpleTable::HBarEndDrag()
{
HideTracking();
USHORT nPrivTabCount=TabCount();
- USHORT nPos=0;
- USHORT nNewSize=0;
if(nPrivTabCount)
{
if(nPrivTabCount>aHeaderBar.GetItemCount())
nPrivTabCount=aHeaderBar.GetItemCount();
- //for(USHORT i=1;i<=nPrivTabCount;i++)
+ USHORT nPos=0;
+ USHORT nNewSize=0;
for(USHORT i=1;i<nPrivTabCount;i++)
{
nNewSize = static_cast< USHORT >( aHeaderBar.GetItemSize(i) ) + nPos;
@@ -577,3 +575,4 @@ IMPL_LINK( SvxSimpleTable, CompareHdl, SvSortData*, pData)
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/srchctrl.cxx b/svx/source/dialog/srchctrl.cxx
index 080e9b8621..f6c9c4c118 100644
--- a/svx/source/dialog/srchctrl.cxx
+++ b/svx/source/dialog/srchctrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -88,3 +89,4 @@ void SvxSearchController::StateChanged( USHORT nSID, SfxItemState eState,
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/srchctrl.hxx b/svx/source/dialog/srchctrl.hxx
index e3ffd2c556..3547c3ea8b 100644
--- a/svx/source/dialog/srchctrl.hxx
+++ b/svx/source/dialog/srchctrl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,3 +50,4 @@ public:
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/srchdlg.cxx b/svx/source/dialog/srchdlg.cxx
index 3e4d0d49f3..86987695f4 100644
--- a/svx/source/dialog/srchdlg.cxx
+++ b/svx/source/dialog/srchdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,7 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_svx.hxx"
-// include ---------------------------------------------------------------
+#include <sal/macros.h>
#include <vcl/wrkwin.hxx>
#include <vcl/morebtn.hxx>
#include <vcl/msgbox.hxx>
@@ -144,12 +145,12 @@ struct SearchDlg_Impl
bDeltaCalculated( FALSE ),
pRanges ( NULL )
{
- aCommand1URL.Complete = aCommand1URL.Main = rtl::OUString::createFromAscii("vnd.sun.search:SearchViaComponent1");
- aCommand1URL.Protocol = rtl::OUString::createFromAscii("vnd.sun.search:");
- aCommand1URL.Path = rtl::OUString::createFromAscii("SearchViaComponent1");
- aCommand2URL.Complete = aCommand2URL.Main = rtl::OUString::createFromAscii("vnd.sun.search:SearchViaComponent2");
- aCommand2URL.Protocol = rtl::OUString::createFromAscii("vnd.sun.search:");
- aCommand2URL.Path = rtl::OUString::createFromAscii("SearchViaComponent2");
+ aCommand1URL.Complete = aCommand1URL.Main = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.search:SearchViaComponent1"));
+ aCommand1URL.Protocol = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.search:"));
+ aCommand1URL.Path = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SearchViaComponent1"));
+ aCommand2URL.Complete = aCommand2URL.Main = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.search:SearchViaComponent2"));
+ aCommand2URL.Protocol = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("vnd.sun.search:"));
+ aCommand2URL.Path = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SearchViaComponent2"));
}
~SearchDlg_Impl() { delete[] pRanges; }
};
@@ -498,7 +499,7 @@ void SvxSearchDialog::Construct_Impl()
// vnd.sun.star::SearchViaComponent1 and 2 are supported
const uno::Reference< frame::XFrame >xFrame = rBindings.GetActiveFrame();
const uno::Reference< frame::XDispatchProvider > xDispatchProv(xFrame, uno::UNO_QUERY);
- rtl::OUString sTarget = rtl::OUString::createFromAscii("_self");
+ rtl::OUString sTarget(RTL_CONSTASCII_USTRINGPARAM("_self"));
bool bSearchComponent1 = false;
bool bSearchComponent2 = false;
@@ -659,6 +660,11 @@ INT32 SvxSearchDialog::GetTransliterationFlags() const
return nTransliterationFlags;
}
+void SvxSearchDialog::SetSaveToModule(bool b)
+{
+ pImpl->bSaveToModule = b;
+}
+
// -----------------------------------------------------------------------
void SvxSearchDialog::ApplyTransliterationFlags_Impl( INT32 nSettings )
@@ -777,10 +783,10 @@ void SvxSearchDialog::CalculateDelta_Impl()
try
{
::rtl::OUString aModuleIdentifier = xModuleManager->identify( xFrame );
- bCalcApp = aModuleIdentifier.equalsAscii( "com.sun.star.sheet.SpreadsheetDocument" );
- bDrawApp = aModuleIdentifier.equalsAscii( "com.sun.star.drawing.DrawingDocument" );
- bImpressApp = aModuleIdentifier.equalsAscii( "com.sun.star.presentation.PresentationDocument" );
- bWriterApp = aModuleIdentifier.equalsAscii( "com.sun.star.text.TextDocument" );
+ bCalcApp = aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sheet.SpreadsheetDocument" ) );
+ bDrawApp = aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.DrawingDocument" ) );
+ bImpressApp = aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.presentation.PresentationDocument" ) );
+ bWriterApp = aModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.text.TextDocument" ) );
}
catch ( uno::Exception& )
{
@@ -889,7 +895,7 @@ void SvxSearchDialog::CalculateDelta_Impl()
if ( nOffset > 0 )
{
long nH = LogicToPixel( Size( 0, nOffset ), MAP_APPFONT ).Height();
- for ( i = 0; i < sizeof( pWins ) / sizeof( pWins[ 0 ] ); ++i, ++pCurrent )
+ for ( i = 0; i < SAL_N_ELEMENTS( pWins ); ++i, ++pCurrent )
{
if ( ( bCalcApp && i < nCalcCtrlCount )
|| ( i == nCalcCtrlCount && aCJKOptions.IsCJKFontEnabled() )
@@ -926,9 +932,36 @@ void SvxSearchDialog::CalculateDelta_Impl()
// -----------------------------------------------------------------------
+namespace {
+
+class ToggleSaveToModule
+{
+public:
+ ToggleSaveToModule(SvxSearchDialog& rDialog, bool bValue) :
+ mrDialog(rDialog), mbValue(bValue)
+ {
+ mrDialog.SetSaveToModule(mbValue);
+ }
+
+ ~ToggleSaveToModule()
+ {
+ mrDialog.SetSaveToModule(!mbValue);
+ }
+private:
+ SvxSearchDialog& mrDialog;
+ bool mbValue;
+};
+
+}
+
void SvxSearchDialog::Init_Impl( int bSearchPattern )
{
DBG_ASSERT( pSearchItem, "SearchItem == 0" );
+
+ // We don't want to save any intermediate state to the module while the
+ // dialog is being initialized.
+ ToggleSaveToModule aNoModuleSave(*this, false);
+
bWriter = ( pSearchItem->GetAppFlag() == SVX_SEARCHAPP_WRITER );
pImpl->bMultiLineEdit = FALSE;
@@ -979,7 +1012,7 @@ void SvxSearchDialog::Init_Impl( int bSearchPattern )
CalculateDelta_Impl();
- FASTBOOL bDraw = FALSE;
+ bool bDraw = FALSE;
if ( pSearchItem->GetAppFlag() == SVX_SEARCHAPP_CALC )
{
Link aLink = LINK( this, SvxSearchDialog, FlagHdl_Impl );
@@ -1078,12 +1111,10 @@ void SvxSearchDialog::Init_Impl( int bSearchPattern )
aSimilarityBox.Check( pSearchItem->IsLevenshtein() );
bSet = TRUE;
- pImpl->bSaveToModule = FALSE;
FlagHdl_Impl( &aSimilarityBox );
FlagHdl_Impl( &aJapOptionsCB );
- pImpl->bSaveToModule = TRUE;
- FASTBOOL bDisableSearch = FALSE;
+ bool bDisableSearch = FALSE;
SfxViewShell* pViewShell = SfxViewShell::Current();
if ( pViewShell )
@@ -1142,14 +1173,14 @@ void SvxSearchDialog::Init_Impl( int bSearchPattern )
}
else
{
- FASTBOOL bSetSearch = ( ( nModifyFlag & MODIFY_SEARCH ) == 0 );
- FASTBOOL bSetReplace = ( ( nModifyFlag & MODIFY_REPLACE ) == 0 );
+ bool bSetSearch = ( ( nModifyFlag & MODIFY_SEARCH ) == 0 );
+ bool bSetReplace = ( ( nModifyFlag & MODIFY_REPLACE ) == 0 );
if ( pSearchItem->GetSearchString().Len() && bSetSearch )
aSearchLB.SetText( pSearchItem->GetSearchString() );
else if ( aSearchStrings.Count() )
{
- FASTBOOL bAttributes =
+ bool bAttributes =
( ( pSearchList && pSearchList->Count() ) ||
( pReplaceList && pReplaceList->Count() ) );
@@ -1434,7 +1465,7 @@ IMPL_LINK( SvxSearchDialog, FlagHdl_Impl, Control *, pCtrl )
IMPL_LINK( SvxSearchDialog, CommandHdl_Impl, Button *, pBtn )
{
- FASTBOOL bInclusive = ( aLayoutBtn.GetText() == aLayoutStr );
+ bool bInclusive = ( aLayoutBtn.GetText() == aLayoutStr );
if ( ( pBtn == &aSearchBtn ) ||
( pBtn == &aSearchAllBtn ) ||
@@ -1531,12 +1562,6 @@ IMPL_LINK( SvxSearchDialog, CommandHdl_Impl, Button *, pBtn )
}
else if ( pBtn == &aSimilarityBtn )
{
-//CHINA001 SvxSearchSimilarityDialog* pDlg =
-//CHINA001 new SvxSearchSimilarityDialog( this,
-//CHINA001 pSearchItem->IsLEVRelaxed(),
-//CHINA001 pSearchItem->GetLEVOther(),
-//CHINA001 pSearchItem->GetLEVShorter(),
-//CHINA001 pSearchItem->GetLEVLonger() );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
@@ -1545,7 +1570,7 @@ IMPL_LINK( SvxSearchDialog, CommandHdl_Impl, Button *, pBtn )
pSearchItem->GetLEVOther(),
pSearchItem->GetLEVShorter(),
pSearchItem->GetLEVLonger() );
- DBG_ASSERT(pDlg, "Dialogdiet fail!");//CHINA001
+ DBG_ASSERT(pDlg, "Dialogdiet fail!");
if ( pDlg && pDlg->Execute() == RET_OK )
{
pSearchItem->SetLEVRelaxed( pDlg->IsRelaxed() );
@@ -1570,20 +1595,20 @@ IMPL_LINK( SvxSearchDialog, CommandHdl_Impl, Button *, pBtn )
int nRet = aDlg->Execute(); //CHINA001 int nRet = aDlg.Execute();
if (RET_OK == nRet) //! true only if FillItemSet of SvxJSearchOptionsPage returns true
{
- INT32 nFlags = aDlg->GetTransliterationFlags(); //CHINA001 INT32 nFlags = aDlg.GetTransliterationFlags();
+ INT32 nFlags = aDlg->GetTransliterationFlags();
pSearchItem->SetTransliterationFlags( nFlags );
ApplyTransliterationFlags_Impl( nFlags );
}
- delete aDlg; //add for CHINA001
+ delete aDlg;
}
}
else if(pBtn == &aSearchComponent1PB || pBtn == &aSearchComponent2PB )
{
uno::Sequence < beans::PropertyValue > aArgs(2);
beans::PropertyValue* pArgs = aArgs.getArray();
- pArgs[0].Name = ::rtl::OUString::createFromAscii("SearchString");
+ pArgs[0].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SearchString"));
pArgs[0].Value <<= ::rtl::OUString(aSearchLB.GetText());
- pArgs[1].Name = ::rtl::OUString::createFromAscii("ParentWindow");
+ pArgs[1].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ParentWindow"));
pArgs[1].Value <<= VCLUnoHelper::GetInterface( LAYOUT_THIS_WINDOW (this) );
if(pBtn == &aSearchComponent1PB)
{
@@ -1609,16 +1634,23 @@ IMPL_LINK( SvxSearchDialog, ModifyHdl_Impl, ComboBox *, pEd )
else
bSet = FALSE;
+ // Calc allows searching for empty cells.
+ bool bAllowEmptySearch = (pSearchItem->GetAppFlag() == SVX_SEARCHAPP_CALC);
+
if ( pEd == &aSearchLB || pEd == &aReplaceLB )
{
- xub_StrLen nLBTxtLen = aSearchLB.GetText().Len(), nTxtLen;
+ xub_StrLen nSrchTxtLen = aSearchLB.GetText().Len();
+ xub_StrLen nReplTxtLen = 0;
+ if (bAllowEmptySearch)
+ nReplTxtLen = aReplaceLB.GetText().Len();
+ xub_StrLen nAttrTxtLen = 0;
if ( !pImpl->bMultiLineEdit )
- nTxtLen = aSearchAttrText.GetText().Len();
+ nAttrTxtLen = aSearchAttrText.GetText().Len();
else
- nTxtLen = pImpl->aSearchFormats.GetText().Len();
+ nAttrTxtLen = pImpl->aSearchFormats.GetText().Len();
- if ( nLBTxtLen || nTxtLen )
+ if (nSrchTxtLen || nReplTxtLen || nAttrTxtLen)
{
EnableControl_Impl( &aSearchBtn );
EnableControl_Impl( &aReplaceBtn );
@@ -1842,19 +1874,19 @@ void SvxSearchDialog::EnableControls_Impl( const USHORT nFlags )
}
else if ( !IsVisible() )
Show();
- FASTBOOL bNoSearch = TRUE;
+ bool bNoSearch = true;
sal_Bool bEnableSearch = ( SEARCH_OPTIONS_SEARCH & nOptions ) != 0;
aSearchBtn.Enable(bEnableSearch);
if( bEnableSearch )
- bNoSearch = FALSE;
+ bNoSearch = false;
if ( ( SEARCH_OPTIONS_SEARCH_ALL & nOptions ) != 0 )
{
aSearchAllBtn.Enable();
- bNoSearch = FALSE;
+ bNoSearch = false;
}
else
aSearchAllBtn.Disable();
@@ -1864,7 +1896,7 @@ void SvxSearchDialog::EnableControls_Impl( const USHORT nFlags )
aReplaceText.Enable();
aReplaceLB.Enable();
aReplaceTmplLB.Enable();
- bNoSearch = FALSE;
+ bNoSearch = false;
}
else
{
@@ -1876,7 +1908,7 @@ void SvxSearchDialog::EnableControls_Impl( const USHORT nFlags )
if ( ( SEARCH_OPTIONS_REPLACE_ALL & nOptions ) != 0 )
{
aReplaceAllBtn.Enable();
- bNoSearch = FALSE;
+ bNoSearch = false;
}
else
aReplaceAllBtn.Disable();
@@ -2170,12 +2202,12 @@ IMPL_LINK( SvxSearchDialog, FormatHdl_Impl, Button *, EMPTYARG )
aSet.DisableItem(rPool.GetWhich(SID_ATTR_PARA_PAGEBREAK));
aSet.DisableItem(rPool.GetWhich(SID_ATTR_PARA_KEEP));
- //CHINA001 SvxSearchFormatDialog* pDlg = new SvxSearchFormatDialog( this, aSet );
+
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
SfxAbstractTabDialog* pDlg = pFact->CreateTabItemDialog( LAYOUT_THIS_WINDOW (this), aSet, RID_SVXDLG_SEARCHFORMAT );
- DBG_ASSERT(pDlg, "Dialogdiet fail!");//CHINA001
+ DBG_ASSERT(pDlg, "Dialogdiet fail!");
aTxt.Insert( pDlg->GetText(), 0 );
pDlg->SetText( aTxt );
@@ -2247,7 +2279,6 @@ IMPL_LINK( SvxSearchDialog, AttributeHdl_Impl, Button *, EMPTYARG )
if ( !pSearchList || !pImpl->pRanges )
return 0;
- //CHINA001 SvxSearchAttributeDialog* pDlg = new SvxSearchAttributeDialog( this, *pSearchList, pImpl->pRanges );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
@@ -2352,6 +2383,8 @@ String& SvxSearchDialog::BuildAttrText_Impl( String& rStr,
ResStringArray aAttrNames( SVX_RES( RID_ATTR_NAMES ) );
+ ResStringArray aAttrNames( SVX_RES( RID_ATTR_NAMES ) );
+
for ( USHORT i = 0; i < pList->Count(); ++i )
{
const SearchAttrItem& rItem = pList->GetObject(i);
@@ -2547,3 +2580,4 @@ SfxChildWinInfo SvxSearchDialogWrapper::GetInfo() const
return aInfo;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/stddlg.cxx b/svx/source/dialog/stddlg.cxx
index 950c4f3a0a..16d0853b98 100644
--- a/svx/source/dialog/stddlg.cxx
+++ b/svx/source/dialog/stddlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,9 +31,7 @@
// include ---------------------------------------------------------------
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
#include <svx/stddlg.hxx>
@@ -59,9 +58,10 @@ SvxStandardDialog::SvxStandardDialog( Window *pParent, const ResId &rResId ) :
// -----------------------------------------------------------------------
-__EXPORT SvxStandardDialog::~SvxStandardDialog()
+SvxStandardDialog::~SvxStandardDialog()
{
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/strarray.cxx b/svx/source/dialog/strarray.cxx
index 4bd93baef0..4ac0736121 100644
--- a/svx/source/dialog/strarray.cxx
+++ b/svx/source/dialog/strarray.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97,3 +98,4 @@ long SvxStringArray::GetValueByStr( const String& rStr ) const
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/svxbmpnumvalueset.cxx b/svx/source/dialog/svxbmpnumvalueset.cxx
index 51d7af6a11..86babe3667 100644
--- a/svx/source/dialog/svxbmpnumvalueset.cxx
+++ b/svx/source/dialog/svxbmpnumvalueset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_svx.hxx"
#include <svx/dialmgr.hxx>
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
#include <tools/shl.hxx>
#include <i18npool/mslangid.hxx>
#include <svtools/valueset.hxx>
@@ -103,9 +102,6 @@ static const sal_Char cSuffix[] = "Suffix";
static const sal_Char cBulletChar[] = "BulletChar";
static const sal_Char cBulletFontName[] = "BulletFontName";
-/* -----------------28.10.98 08:32-------------------
- *
- * --------------------------------------------------*/
// Die Auswahl an Bullets aus den StarSymbol
static const sal_Unicode aBulletTypes[] =
{
@@ -158,7 +154,7 @@ static void lcl_PaintLevel(OutputDevice* pVDev, sal_Int16 nNumberingType,
}
void SvxNumValueSet::UserDraw( const UserDrawEvent& rUDEvt )
{
- static USHORT __READONLY_DATA aLinesArr[] =
+ static USHORT const aLinesArr[] =
{
15, 10,
20, 30,
@@ -449,17 +445,11 @@ SvxNumValueSet::SvxNumValueSet( Window* pParent, const ResId& rResId, USHORT nTy
}
}
-/*-----------------08.02.97 12.38-------------------
-
---------------------------------------------------*/
-
- SvxNumValueSet::~SvxNumValueSet()
+SvxNumValueSet::~SvxNumValueSet()
{
delete pVDev;
}
-/* -----------------------------30.01.01 16:24--------------------------------
- ---------------------------------------------------------------------------*/
void SvxNumValueSet::SetNumberingSettings(
const Sequence<Sequence<PropertyValue> >& aNum,
Reference<XNumberingFormatter>& xFormat,
@@ -477,9 +467,7 @@ void SvxNumValueSet::SetNumberingSettings(
SetItemText( i + 1, SVX_RESSTR( RID_SVXSTR_SINGLENUM_DESCRIPTIONS + i ));
}
}
-/* -----------------------------31.01.01 09:50--------------------------------
- ---------------------------------------------------------------------------*/
void SvxNumValueSet::SetOutlineNumberingSettings(
Sequence<Reference<XIndexAccess> >& rOutline,
Reference<XNumberingFormatter>& xFormat,
@@ -512,20 +500,13 @@ SvxBmpNumValueSet::SvxBmpNumValueSet( Window* pParent, const ResId& rResId/*, co
aFormatTimer.SetTimeoutHdl(LINK(this, SvxBmpNumValueSet, FormatHdl_Impl));
}
-/*-----------------13.02.97 09.41-------------------
-
---------------------------------------------------*/
-
- SvxBmpNumValueSet::~SvxBmpNumValueSet()
+SvxBmpNumValueSet::~SvxBmpNumValueSet()
{
GalleryExplorer::EndLocking(GALLERY_THEME_BULLETS);
aFormatTimer.Stop();
}
-/*-----------------13.02.97 09.41-------------------
-
---------------------------------------------------*/
-void SvxBmpNumValueSet::UserDraw( const UserDrawEvent& rUDEvt )
+void SvxBmpNumValueSet::UserDraw( const UserDrawEvent& rUDEvt )
{
SvxNumValueSet::UserDraw(rUDEvt);
@@ -555,10 +536,6 @@ void SvxBmpNumValueSet::UserDraw( const UserDrawEvent& rUDEvt )
}
}
-/*-----------------14.02.97 07.34-------------------
-
---------------------------------------------------*/
-
IMPL_LINK(SvxBmpNumValueSet, FormatHdl_Impl, Timer*, EMPTYARG)
{
// nur, wenn eine Grafik nicht da war, muss formatiert werden
@@ -570,3 +547,5 @@ IMPL_LINK(SvxBmpNumValueSet, FormatHdl_Impl, Timer*, EMPTYARG)
Invalidate();
return 0;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/svxdlg.cxx b/svx/source/dialog/svxdlg.cxx
index ad238f9591..6d87cdbb96 100644
--- a/svx/source/dialog/svxdlg.cxx
+++ b/svx/source/dialog/svxdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
diff --git a/svx/source/dialog/svxgrahicitem.cxx b/svx/source/dialog/svxgrahicitem.cxx
index d871d70d59..4fa6f6c689 100644
--- a/svx/source/dialog/svxgrahicitem.cxx
+++ b/svx/source/dialog/svxgrahicitem.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -48,3 +49,5 @@ SfxPoolItem* SvxGraphicItem::Clone( SfxItemPool * ) const
{
return new SvxGraphicItem( *this );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/svxruler.cxx b/svx/source/dialog/svxruler.cxx
index 23ef03dab5..ab79250520 100644
--- a/svx/source/dialog/svxruler.cxx
+++ b/svx/source/dialog/svxruler.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,7 +55,6 @@
#include "editeng/protitem.hxx"
#ifndef _APP_HXX
#include <vcl/svapp.hxx>
-#endif
#ifndef RULER_TAB_RTL
#define RULER_TAB_RTL ((USHORT)0x0010)
#endif
@@ -456,7 +456,7 @@ SvxRuler::SvxRuler
}
-__EXPORT SvxRuler::~SvxRuler()
+SvxRuler::~SvxRuler()
/*
[Beschreibung]
@@ -776,9 +776,7 @@ void SvxRuler::Update( const SvxProtectItem* pItem )
{
if( pItem ) pRuler_Imp->aProtectItem = *pItem;
}
-/* -----------------------------22.08.2002 13:10------------------------------
- ---------------------------------------------------------------------------*/
void SvxRuler::UpdateTextRTL(const SfxBoolItem* pItem)
{
if(bActive && bHorz)
@@ -2211,16 +2209,14 @@ ADD_DEBUG_TEXT("lLastLMargin: ", String::CreateFromInt32(pRuler_Imp->lLastLMargi
//This includes the left border when the table is not limited
//to a lower frame border.
int nLimit;
- long lLeft;
if(GetDragType()==RULER_TYPE_BORDER)
{
nLimit=nIdx+1;
- lLeft=(pBorders[nIdx].nPos+=lDiff);
+ pBorders[nIdx].nPos+=lDiff;
}
else
{
nLimit=0;
- lLeft=pRuler_Imp->lLastLMargin+lDiff;
}
//in vertical tables the left borders have to be moved
if(bHorz)
@@ -2818,7 +2814,7 @@ void SvxRuler::EvalModifier()
}
-void __EXPORT SvxRuler::Click()
+void SvxRuler::Click()
/*
[Beschreibung]
@@ -3446,7 +3442,7 @@ void SvxRuler::CalcMinMax()
}
-long __EXPORT SvxRuler::StartDrag()
+long SvxRuler::StartDrag()
/*
[Beschreibung]
@@ -3532,7 +3528,7 @@ long __EXPORT SvxRuler::StartDrag()
}
-void __EXPORT SvxRuler::Drag()
+void SvxRuler::Drag()
/*
[Beschreibung]
@@ -3572,7 +3568,7 @@ void __EXPORT SvxRuler::Drag()
}
-void __EXPORT SvxRuler::EndDrag()
+void SvxRuler::EndDrag()
/*
[Beschreibung]
@@ -3645,7 +3641,7 @@ void __EXPORT SvxRuler::EndDrag()
}
-void __EXPORT SvxRuler::ExtraDown()
+void SvxRuler::ExtraDown()
/*
[Beschreibung]
@@ -3666,7 +3662,7 @@ void __EXPORT SvxRuler::ExtraDown()
}
-void __EXPORT SvxRuler::Notify(SfxBroadcaster&, const SfxHint& rHint)
+void SvxRuler::Notify(SfxBroadcaster&, const SfxHint& rHint)
/*
[Beschreibung]
@@ -3788,8 +3784,17 @@ void SvxRuler::Command( const CommandEvent& rCEvt )
(nId == FUNIT_M ||
nId == FUNIT_KM ||
nId == FUNIT_FOOT ||
- nId == FUNIT_MILE ))
- aMenu.RemoveItem(i - 1);
+ nId == FUNIT_MILE ||
+ nId == FUNIT_CHAR ||
+ nId == FUNIT_LINE ))
+ {
+ if (( nId == FUNIT_CHAR ) && bHorz )
+ ;
+ else if (( nId == FUNIT_LINE ) && !bHorz )
+ ;
+ else
+ aMenu.RemoveItem(i - 1);
+ }
}
aMenu.Execute( this, rCEvt.GetMousePosPixel() );
}
@@ -3966,11 +3971,11 @@ long SvxRuler::CalcPropMaxRight(USHORT nCol) const
}
}
}
-/*-- 29.11.2007 08:24:23---------------------------------------------------
- //#i24363# tab stops relative to indent
- -----------------------------------------------------------------------*/
+
+// Tab stops relative to indent (#i24363#)
void SvxRuler::SetTabsRelativeToIndent( BOOL bRel )
{
pRuler_Imp->bIsTabsRelativeToIndent = bRel;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/swframeexample.cxx b/svx/source/dialog/swframeexample.cxx
index 98ebe2a51c..9e65330507 100644
--- a/svx/source/dialog/swframeexample.cxx
+++ b/svx/source/dialog/swframeexample.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -735,3 +736,4 @@ void SvxSwFrameExample::DrawRect_Impl(const Rectangle &rRect, const Color &rFill
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/swframeposstrings.cxx b/svx/source/dialog/swframeposstrings.cxx
index 936e38ed10..210b22dd35 100644
--- a/svx/source/dialog/swframeposstrings.cxx
+++ b/svx/source/dialog/swframeposstrings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,23 +51,17 @@ SvxSwFramePosString_Impl::SvxSwFramePosString_Impl() :
}
FreeResource();
}
-/*-- 04.03.2004 13:14:48---------------------------------------------------
- -----------------------------------------------------------------------*/
SvxSwFramePosString::SvxSwFramePosString() :
pImpl(new SvxSwFramePosString_Impl)
{
}
-/*-- 04.03.2004 13:14:48---------------------------------------------------
- -----------------------------------------------------------------------*/
SvxSwFramePosString::~SvxSwFramePosString()
{
delete pImpl;
}
-/*-- 04.03.2004 13:14:48---------------------------------------------------
- -----------------------------------------------------------------------*/
const String& SvxSwFramePosString::GetString(StringId eId)
{
DBG_ASSERT(eId >= 0 && eId < STR_MAX, "invalid StringId");
@@ -74,3 +69,5 @@ const String& SvxSwFramePosString::GetString(StringId eId)
eId = LEFT;
return pImpl->aStrings[eId];
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/txencbox.cxx b/svx/source/dialog/txencbox.cxx
index 2c632164bc..7c3205fb98 100644
--- a/svx/source/dialog/txencbox.cxx
+++ b/svx/source/dialog/txencbox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -252,3 +253,4 @@ BOOL SvxTextEncodingBox::IsTextEncodingSelected( const rtl_TextEncoding nEnc ) c
return FALSE;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/txenctab.cxx b/svx/source/dialog/txenctab.cxx
index 5cfdc73d50..d211cf0ba1 100644
--- a/svx/source/dialog/txenctab.cxx
+++ b/svx/source/dialog/txenctab.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,3 +75,4 @@ rtl_TextEncoding SvxTextEncodingTable::GetTextEncoding( const String& rStr ) con
return RTL_TEXTENCODING_DONTKNOW;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/wrapfield.cxx b/svx/source/dialog/wrapfield.cxx
index 8d797fa5ad..a965fdf341 100644
--- a/svx/source/dialog/wrapfield.cxx
+++ b/svx/source/dialog/wrapfield.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,3 +60,4 @@ void WrapField::Down()
} // namespace svx
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */