From 7fcbcc4b70c1e905e6cdd08ab79ea8ebd0720a5b Mon Sep 17 00:00:00 2001 From: "Frank Schoenheit [fs]" Date: Mon, 11 Oct 2010 13:59:41 +0200 Subject: dba34b: during #i112779#: don't hold an extra BitmapEx in ImageControl, use base classes Image instead --- svtools/source/uno/unoiface.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'svtools') diff --git a/svtools/source/uno/unoiface.cxx b/svtools/source/uno/unoiface.cxx index 2d22d9cedb33..18ab6f804d0c 100644 --- a/svtools/source/uno/unoiface.cxx +++ b/svtools/source/uno/unoiface.cxx @@ -1652,7 +1652,7 @@ void SVTXRoadmap::ImplSetNewImage() { OSL_PRECOND( GetWindow(), "SVTXRoadmap::ImplSetNewImage: window is required to be not-NULL!" ); ::svt::ORoadmap* pButton = static_cast< ::svt::ORoadmap* >( GetWindow() ); - pButton->SetRoadmapBitmap( GetBitmap() ); + pButton->SetRoadmapBitmap( GetImage().GetBitmapEx() ); } void SVTXRoadmap::ImplGetPropertyIds( std::list< sal_uInt16 > &rIds ) -- cgit From f9660fa98025fe598148abec121bb52191da608f Mon Sep 17 00:00:00 2001 From: "Frank Schoenheit [fs]" Date: Thu, 14 Oct 2010 16:40:32 +0200 Subject: undoapi: first sketch of the listener API - not sure this will survive 'til the final version --- svtools/source/edit/textundo.cxx | 8 ++++---- svtools/source/edit/textundo.hxx | 4 ++-- svtools/source/edit/textview.cxx | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) (limited to 'svtools') diff --git a/svtools/source/edit/textundo.cxx b/svtools/source/edit/textundo.cxx index 4c243de16c31..1ea2ee41efd0 100644 --- a/svtools/source/edit/textundo.cxx +++ b/svtools/source/edit/textundo.cxx @@ -54,7 +54,7 @@ TextUndoManager::~TextUndoManager() { } -BOOL __EXPORT TextUndoManager::Undo( USHORT nCount ) +BOOL __EXPORT TextUndoManager::Undo() { if ( GetUndoActionCount() == 0 ) return FALSE; @@ -62,7 +62,7 @@ BOOL __EXPORT TextUndoManager::Undo( USHORT nCount ) UndoRedoStart(); mpTextEngine->SetIsInUndo( TRUE ); - BOOL bDone = SfxUndoManager::Undo( nCount ); + BOOL bDone = SfxUndoManager::Undo(); mpTextEngine->SetIsInUndo( FALSE ); UndoRedoEnd(); @@ -70,7 +70,7 @@ BOOL __EXPORT TextUndoManager::Undo( USHORT nCount ) return bDone; } -BOOL __EXPORT TextUndoManager::Redo( USHORT nCount ) +BOOL __EXPORT TextUndoManager::Redo() { if ( GetRedoActionCount() == 0 ) return FALSE; @@ -79,7 +79,7 @@ BOOL __EXPORT TextUndoManager::Redo( USHORT nCount ) UndoRedoStart(); mpTextEngine->SetIsInUndo( TRUE ); - BOOL bDone = SfxUndoManager::Redo( nCount ); + BOOL bDone = SfxUndoManager::Redo(); mpTextEngine->SetIsInUndo( FALSE ); UndoRedoEnd(); diff --git a/svtools/source/edit/textundo.hxx b/svtools/source/edit/textundo.hxx index cc26c0b51ef6..27fe8933ad17 100644 --- a/svtools/source/edit/textundo.hxx +++ b/svtools/source/edit/textundo.hxx @@ -47,9 +47,9 @@ public: ~TextUndoManager(); using SfxUndoManager::Undo; - virtual BOOL Undo( USHORT nCount=1 ); + virtual BOOL Undo(); using SfxUndoManager::Redo; - virtual BOOL Redo( USHORT nCount=1 ); + virtual BOOL Redo(); }; diff --git a/svtools/source/edit/textview.cxx b/svtools/source/edit/textview.cxx index 48cd23bdcc6f..a2f37c0bd34d 100644 --- a/svtools/source/edit/textview.cxx +++ b/svtools/source/edit/textview.cxx @@ -1122,13 +1122,13 @@ void TextView::Scroll( long ndX, long ndY ) void TextView::Undo() { mpImpl->mpTextEngine->SetActiveView( this ); - mpImpl->mpTextEngine->GetUndoManager().Undo( 1 ); + mpImpl->mpTextEngine->GetUndoManager().Undo(); } void TextView::Redo() { mpImpl->mpTextEngine->SetActiveView( this ); - mpImpl->mpTextEngine->GetUndoManager().Redo( 0 ); + mpImpl->mpTextEngine->GetUndoManager().Redo(); } void TextView::Cut() -- cgit From 32562151fdf2e9bbeec57fda3a1d96d5e3880b1c Mon Sep 17 00:00:00 2001 From: "Frank Schoenheit [fs]" Date: Wed, 20 Oct 2010 14:54:59 +0200 Subject: undoapi: made SfxUndoManager an implementation of the new, abstract ::svl::IUndoManager interface. Change the SfxShell's UndoManager attribute to be an IUndoManager. Did all the resulting changes up the source tree. This way, we'll hopefully be able to provide an IUndoManager implementation in Writer, which is not based on the SfxUndoManager, but on Writer's own Undo implementation. --- svtools/inc/svtools/texteng.hxx | 9 +++++++-- svtools/source/edit/texteng.cxx | 2 +- 2 files changed, 8 insertions(+), 3 deletions(-) (limited to 'svtools') diff --git a/svtools/inc/svtools/texteng.hxx b/svtools/inc/svtools/texteng.hxx index ef27edee2efe..a30f29ff750b 100644 --- a/svtools/inc/svtools/texteng.hxx +++ b/svtools/inc/svtools/texteng.hxx @@ -39,7 +39,6 @@ class TextAttrib; class TextCharAttrib; class TextUndo; class TextUndoManager; -class SfxUndoManager; class EditSelFunctionSet; class EditSelEngine; class IdleFormatter; @@ -49,6 +48,11 @@ class SfxUndoAction; class KeyEvent; class Timer; +namespace svl +{ + class IUndoManager; +} + class TextLine; class TETextPortion; #include @@ -280,7 +284,8 @@ public: BOOL IsRightToLeft() const { return mbRightToLeft; } BOOL HasUndoManager() const { return mpUndoManager ? TRUE : FALSE; } - SfxUndoManager& GetUndoManager(); + ::svl::IUndoManager& + GetUndoManager(); void UndoActionStart( USHORT nId ); void UndoActionEnd( USHORT nId ); void InsertUndo( TextUndo* pUndo, BOOL bTryMerge = FALSE ); diff --git a/svtools/source/edit/texteng.cxx b/svtools/source/edit/texteng.cxx index e0e136089d78..1aed79c3cafb 100644 --- a/svtools/source/edit/texteng.cxx +++ b/svtools/source/edit/texteng.cxx @@ -1430,7 +1430,7 @@ void TextEngine::EnableUndo( BOOL bEnable ) mbUndoEnabled = bEnable; } -SfxUndoManager& TextEngine::GetUndoManager() +::svl::IUndoManager& TextEngine::GetUndoManager() { if ( !mpUndoManager ) mpUndoManager = new TextUndoManager( this ); -- cgit From 7abe5ea730c08466dce9a80a45cda41c88a4faad Mon Sep 17 00:00:00 2001 From: "Ocke.Janssen" Date: Thu, 28 Oct 2010 09:06:55 +0200 Subject: dba34b: #i115284# clear hdlentry when it going to be removed --- svtools/source/contnr/svtreebx.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'svtools') diff --git a/svtools/source/contnr/svtreebx.cxx b/svtools/source/contnr/svtreebx.cxx index f4780fbf08ad..3ff4d2b11990 100644 --- a/svtools/source/contnr/svtreebx.cxx +++ b/svtools/source/contnr/svtreebx.cxx @@ -1146,9 +1146,11 @@ void SvTreeListBox::ModelIsRemoving( SvListEntry* pEntry ) NotifyRemoving( (SvLBoxEntry*)pEntry ); } -void SvTreeListBox::ModelHasRemoved( SvListEntry* /* pEntry */ ) +void SvTreeListBox::ModelHasRemoved( SvListEntry* pEntry ) { DBG_CHKTHIS(SvTreeListBox,0); + if ( pEntry == pHdlEntry) + pHdlEntry = NULL; pImp->EntryRemoved(); } -- cgit From cef41c30dd562e129b864b87c85f59bf038423a2 Mon Sep 17 00:00:00 2001 From: Xiaofei Zhang Date: Fri, 5 Nov 2010 10:31:15 +0800 Subject: removetooltypes01: #i112600# remove tooltypes from toolkit, svtools and framework --- svtools/bmpmaker/bmp.cxx | 24 +- svtools/bmpmaker/bmpcore.cxx | 12 +- svtools/bmpmaker/bmpcore.hxx | 8 +- svtools/bmpmaker/bmpsum.cxx | 20 +- svtools/bmpmaker/g2g.cxx | 26 +- svtools/inc/DocumentInfoPreview.hxx | 2 +- svtools/inc/acceleratorexecute.hxx | 2 +- svtools/inc/apearcfg.hxx | 48 +- svtools/inc/asynclink.hxx | 16 +- svtools/inc/calendar.hxx | 96 +-- svtools/inc/cliplistener.hxx | 2 +- svtools/inc/ctrlbox.hxx | 140 ++-- svtools/inc/ctrltool.hxx | 44 +- svtools/inc/expander.hxx | 10 +- svtools/inc/filectrl.hxx | 22 +- svtools/inc/filedlg.hxx | 8 +- svtools/inc/fileview.hxx | 4 +- svtools/inc/fltdefs.hxx | 66 +- svtools/inc/htmltokn.h | 2 +- svtools/inc/inetimg.hxx | 4 +- svtools/inc/ivctrl.hxx | 114 +-- svtools/inc/localresaccess.hxx | 2 +- svtools/inc/prgsbar.hxx | 14 +- svtools/inc/rtfout.hxx | 8 +- svtools/inc/ruler.hxx | 202 ++--- svtools/inc/scrwin.hxx | 14 +- svtools/inc/stdmenu.hxx | 2 +- svtools/inc/svtools/accessibletable.hxx | 8 +- svtools/inc/svtools/accessibletableprovider.hxx | 24 +- svtools/inc/svtools/brwbox.hxx | 274 +++---- svtools/inc/svtools/colctrl.hxx | 70 +- svtools/inc/svtools/editbrowsebox.hxx | 20 +- svtools/inc/svtools/editimplementation.hxx | 4 +- svtools/inc/svtools/editsyntaxhighlighter.hxx | 2 +- svtools/inc/svtools/ehdl.hxx | 32 +- svtools/inc/svtools/embedhlp.hxx | 18 +- svtools/inc/svtools/filter.hxx | 268 +++---- svtools/inc/svtools/fltcall.hxx | 8 +- svtools/inc/svtools/fmtfield.hxx | 106 +-- svtools/inc/svtools/generictoolboxcontroller.hxx | 2 +- svtools/inc/svtools/genericunodialog.hxx | 2 +- svtools/inc/svtools/grfmgr.hxx | 192 ++--- svtools/inc/svtools/headbar.hxx | 140 ++-- svtools/inc/svtools/htmlcfg.hxx | 36 +- svtools/inc/svtools/htmlout.hxx | 14 +- svtools/inc/svtools/imap.hxx | 34 +- svtools/inc/svtools/imapcirc.hxx | 20 +- svtools/inc/svtools/imapobj.hxx | 44 +- svtools/inc/svtools/imappoly.hxx | 20 +- svtools/inc/svtools/imaprect.hxx | 14 +- svtools/inc/svtools/inettbc.hxx | 28 +- svtools/inc/svtools/javainteractionhandler.hxx | 2 +- svtools/inc/svtools/logindlg.hxx | 8 +- svtools/inc/svtools/parhtml.hxx | 98 +-- svtools/inc/svtools/parrtf.hxx | 8 +- svtools/inc/svtools/printdlg.hxx | 90 +-- svtools/inc/svtools/prnsetup.hxx | 2 +- svtools/inc/svtools/roadmapwizard.hxx | 4 +- svtools/inc/svtools/stringtransfer.hxx | 2 +- svtools/inc/svtools/svicnvw.hxx | 76 +- svtools/inc/svtools/svlbitm.hxx | 70 +- svtools/inc/svtools/svlbox.hxx | 162 ++-- svtools/inc/svtools/svmedit.hxx | 34 +- svtools/inc/svtools/svmedit2.hxx | 12 +- svtools/inc/svtools/svparser.hxx | 72 +- svtools/inc/svtools/svtabbx.hxx | 100 +-- svtools/inc/svtools/svtdata.hxx | 8 +- svtools/inc/svtools/svtreebx.hxx | 130 ++-- svtools/inc/svtools/svxbox.hxx | 70 +- svtools/inc/svtools/syntaxhighlight.hxx | 28 +- svtools/inc/svtools/table/abstracttablecontrol.hxx | 2 +- svtools/inc/svtools/table/tablecontrol.hxx | 12 +- svtools/inc/svtools/table/tableinputhandler.hxx | 4 +- svtools/inc/svtools/table/tablemodel.hxx | 10 +- svtools/inc/svtools/table/tablerenderer.hxx | 34 +- svtools/inc/svtools/textdata.hxx | 76 +- svtools/inc/svtools/texteng.hxx | 214 ++--- svtools/inc/svtools/textview.hxx | 70 +- svtools/inc/svtools/toolpanel/paneltabbar.hxx | 2 +- svtools/inc/svtools/toolpanel/toolpaneldeck.hxx | 2 +- svtools/inc/svtools/transfer.hxx | 8 +- svtools/inc/svtools/treelist.hxx | 236 +++--- svtools/inc/svtools/ttprops.hxx | 38 +- svtools/inc/svtools/unitconv.hxx | 6 +- svtools/inc/svtools/valueset.hxx | 180 ++--- svtools/inc/svtools/wizardmachine.hxx | 18 +- svtools/inc/svtools/wizdlg.hxx | 30 +- svtools/inc/svtools/wmf.hxx | 12 +- svtools/inc/svtools/xtextedt.hxx | 14 +- svtools/inc/sychconv.hxx | 2 +- svtools/inc/tabbar.hxx | 186 ++--- svtools/inc/taskbar.hxx | 148 ++-- svtools/inc/templatefoldercache.hxx | 12 +- svtools/inc/testtool.hxx | 6 +- svtools/inc/txtattr.hxx | 54 +- svtools/inc/wallitem.hxx | 2 +- svtools/source/brwbox/brwbox1.cxx | 376 ++++----- svtools/source/brwbox/brwbox2.cxx | 350 ++++----- svtools/source/brwbox/brwbox3.cxx | 12 +- svtools/source/brwbox/brwhead.cxx | 4 +- svtools/source/brwbox/datwin.cxx | 98 +-- svtools/source/brwbox/datwin.hxx | 92 +-- svtools/source/brwbox/ebbcontrols.cxx | 30 +- svtools/source/brwbox/editbrowsebox.cxx | 2 +- svtools/source/brwbox/editbrowsebox2.cxx | 8 +- svtools/source/config/accessibilityoptions.cxx | 4 +- svtools/source/config/apearcfg.cxx | 24 +- svtools/source/config/colorcfg.cxx | 10 +- svtools/source/config/htmlcfg.cxx | 48 +- svtools/source/config/menuoptions.cxx | 12 +- svtools/source/config/miscopt.cxx | 10 +- svtools/source/config/printoptions.cxx | 6 +- svtools/source/contnr/ctrdll.cxx | 2 +- svtools/source/contnr/fileview.cxx | 88 +-- svtools/source/contnr/imivctl.hxx | 276 +++---- svtools/source/contnr/imivctl1.cxx | 862 ++++++++++----------- svtools/source/contnr/imivctl2.cxx | 182 ++--- svtools/source/contnr/ivctrl.cxx | 92 +-- svtools/source/contnr/svicnvw.cxx | 88 +-- svtools/source/contnr/svimpbox.cxx | 622 +++++++-------- svtools/source/contnr/svimpicn.cxx | 632 +++++++-------- svtools/source/contnr/svlbitm.cxx | 78 +- svtools/source/contnr/svlbox.cxx | 278 +++---- svtools/source/contnr/svtabbx.cxx | 164 ++-- svtools/source/contnr/svtreebx.cxx | 280 +++---- svtools/source/contnr/templwin.cxx | 72 +- svtools/source/contnr/templwin.hxx | 12 +- svtools/source/contnr/treelist.cxx | 304 ++++---- svtools/source/control/asynclink.cxx | 12 +- svtools/source/control/calendar.cxx | 494 ++++++------ svtools/source/control/ctrlbox.cxx | 218 +++--- svtools/source/control/ctrldll.cxx | 2 +- svtools/source/control/ctrltool.cxx | 60 +- svtools/source/control/filectrl.cxx | 12 +- svtools/source/control/fmtfield.cxx | 170 ++-- svtools/source/control/headbar.cxx | 300 +++---- svtools/source/control/inettbc.cxx | 130 ++-- svtools/source/control/prgsbar.cxx | 32 +- svtools/source/control/roadmap.cxx | 12 +- svtools/source/control/ruler.cxx | 358 ++++----- svtools/source/control/scriptedtext.cxx | 2 +- svtools/source/control/scrwin.cxx | 42 +- svtools/source/control/stdctrl.cxx | 2 +- svtools/source/control/stdmenu.cxx | 100 +-- svtools/source/control/svxbox.cxx | 132 ++-- svtools/source/control/tabbar.cxx | 432 +++++------ svtools/source/control/taskbar.cxx | 24 +- svtools/source/control/taskbox.cxx | 36 +- svtools/source/control/taskmisc.cxx | 20 +- svtools/source/control/taskstat.cxx | 136 ++-- svtools/source/control/toolbarmenu.cxx | 42 +- svtools/source/control/toolbarmenuacc.cxx | 6 +- svtools/source/control/toolbarmenuimp.hxx | 2 +- svtools/source/control/valueacc.cxx | 36 +- svtools/source/control/valueimp.hxx | 12 +- svtools/source/control/valueset.cxx | 450 +++++------ svtools/source/dialogs/addresstemplate.cxx | 4 +- svtools/source/dialogs/colctrl.cxx | 100 +-- svtools/source/dialogs/colrdlg.cxx | 30 +- svtools/source/dialogs/filedlg.cxx | 12 +- svtools/source/dialogs/filedlg2.cxx | 140 ++-- svtools/source/dialogs/filedlg2.hxx | 30 +- svtools/source/dialogs/insdlg.cxx | 8 +- svtools/source/dialogs/logindlg.cxx | 16 +- svtools/source/dialogs/mcvmath.cxx | 32 +- svtools/source/dialogs/mcvmath.hxx | 16 +- svtools/source/dialogs/printdlg.cxx | 88 +-- svtools/source/dialogs/prnsetup.cxx | 14 +- svtools/source/dialogs/propctrl.cxx | 34 +- svtools/source/dialogs/propctrl.hxx | 4 +- svtools/source/dialogs/property.cxx | 206 ++--- svtools/source/dialogs/wizdlg.cxx | 52 +- svtools/source/edit/editsyntaxhighlighter.cxx | 24 +- svtools/source/edit/svmedit.cxx | 278 +++---- svtools/source/edit/svmedit2.cxx | 14 +- svtools/source/edit/sychconv.cxx | 18 +- svtools/source/edit/syntaxhighlight.cxx | 206 ++--- svtools/source/edit/textdat2.hxx | 138 ++-- svtools/source/edit/textdata.cxx | 66 +- svtools/source/edit/textdoc.cxx | 206 ++--- svtools/source/edit/textdoc.hxx | 60 +- svtools/source/edit/texteng.cxx | 672 ++++++++-------- svtools/source/edit/textund2.hxx | 32 +- svtools/source/edit/textundo.cxx | 58 +- svtools/source/edit/textundo.hxx | 10 +- svtools/source/edit/textview.cxx | 410 +++++----- svtools/source/edit/xtextedt.cxx | 78 +- svtools/source/filter.vcl/filter/dlgexpor.cxx | 12 +- svtools/source/filter.vcl/filter/filter.cxx | 330 ++++---- svtools/source/filter.vcl/filter/filter2.cxx | 364 ++++----- svtools/source/filter.vcl/filter/fldll.cxx | 2 +- svtools/source/filter.vcl/filter/gradwrap.cxx | 42 +- svtools/source/filter.vcl/filter/sgfbram.cxx | 132 ++-- svtools/source/filter.vcl/filter/sgvmain.cxx | 202 ++--- svtools/source/filter.vcl/filter/sgvspln.cxx | 82 +- svtools/source/filter.vcl/filter/sgvtext.cxx | 364 ++++----- svtools/source/filter.vcl/igif/decode.cxx | 50 +- svtools/source/filter.vcl/igif/decode.hxx | 32 +- svtools/source/filter.vcl/igif/gifread.cxx | 170 ++-- svtools/source/filter.vcl/ixbm/xbmread.cxx | 52 +- svtools/source/filter.vcl/ixpm/rgbtable.hxx | 6 +- svtools/source/filter.vcl/ixpm/xpmread.cxx | 164 ++-- svtools/source/filter.vcl/jpeg/jpeg.cxx | 56 +- svtools/source/filter.vcl/jpeg/jpeg.h | 2 +- svtools/source/filter.vcl/jpeg/jpegc.c | 14 +- svtools/source/filter.vcl/wmf/emfwr.cxx | 168 ++-- svtools/source/filter.vcl/wmf/emfwr.hxx | 30 +- svtools/source/filter.vcl/wmf/enhwmf.cxx | 184 ++--- svtools/source/filter.vcl/wmf/winmtf.cxx | 84 +- svtools/source/filter.vcl/wmf/winmtf.hxx | 94 +-- svtools/source/filter.vcl/wmf/winwmf.cxx | 102 +-- svtools/source/filter.vcl/wmf/wmf.cxx | 32 +- svtools/source/filter.vcl/wmf/wmfwr.cxx | 134 ++-- svtools/source/filter.vcl/wmf/wmfwr.hxx | 56 +- svtools/source/graphic/descriptor.cxx | 2 +- svtools/source/graphic/descriptor.hxx | 2 +- svtools/source/graphic/grfattr.cxx | 8 +- svtools/source/graphic/grfcache.cxx | 138 ++-- svtools/source/graphic/grfcache.hxx | 42 +- svtools/source/graphic/grfmgr.cxx | 136 ++-- svtools/source/graphic/grfmgr2.cxx | 142 ++-- svtools/source/graphic/provider.cxx | 2 +- svtools/source/hatchwindow/ipwin.cxx | 24 +- svtools/source/hatchwindow/ipwin.hxx | 8 +- svtools/source/inc/gifread.hxx | 66 +- svtools/source/inc/jpeg.hxx | 10 +- svtools/source/inc/msgrd.hxx | 6 +- svtools/source/inc/msgwr.hxx | 6 +- svtools/source/inc/property.hxx | 108 +-- svtools/source/inc/sgfbram.hxx | 100 +-- svtools/source/inc/sgffilt.hxx | 8 +- svtools/source/inc/sgvmain.hxx | 226 +++--- svtools/source/inc/sgvspln.hxx | 10 +- svtools/source/inc/svimpbox.hxx | 122 +-- svtools/source/inc/svimpicn.hxx | 64 +- svtools/source/inc/xbmread.hxx | 6 +- svtools/source/inc/xpmread.hxx | 60 +- svtools/source/java/javainteractionhandler.cxx | 2 +- svtools/source/misc/acceleratorexecute.cxx | 2 +- svtools/source/misc/cliplistener.cxx | 2 +- svtools/source/misc/ehdl.cxx | 86 +- svtools/source/misc/embedhlp.cxx | 42 +- svtools/source/misc/embedtransfer.cxx | 8 +- svtools/source/misc/helpagentwindow.cxx | 2 +- svtools/source/misc/imagemgr.cxx | 348 ++++----- svtools/source/misc/imap.cxx | 152 ++-- svtools/source/misc/imap2.cxx | 40 +- svtools/source/misc/imap3.cxx | 10 +- svtools/source/misc/itemdel.cxx | 2 +- svtools/source/misc/langtab.cxx | 4 +- svtools/source/misc/svtdata.cxx | 2 +- svtools/source/misc/templatefoldercache.cxx | 2 +- svtools/source/misc/transfer.cxx | 8 +- svtools/source/misc/transfer2.cxx | 12 +- svtools/source/misc/unitconv.cxx | 10 +- svtools/source/plugapp/commtest.cxx | 14 +- svtools/source/plugapp/ttprops.cxx | 14 +- .../source/productregistration/registrationdlg.cxx | 2 +- svtools/source/svhtml/htmlkywd.cxx | 22 +- svtools/source/svhtml/htmlout.cxx | 32 +- svtools/source/svhtml/htmlsupp.cxx | 10 +- svtools/source/svhtml/parhtml.cxx | 306 ++++---- svtools/source/svrtf/parrtf.cxx | 12 +- svtools/source/svrtf/rtfkeywd.cxx | 4 +- svtools/source/svrtf/rtfout.cxx | 10 +- svtools/source/svrtf/svparser.cxx | 66 +- svtools/source/table/defaultinputhandler.cxx | 6 +- svtools/source/table/gridtablerenderer.cxx | 12 +- svtools/source/table/tablecontrol.cxx | 8 +- svtools/source/table/tablecontrol_impl.cxx | 36 +- svtools/source/table/tablecontrol_impl.hxx | 10 +- svtools/source/toolpanel/drawerlayouter.cxx | 4 +- svtools/source/toolpanel/paneltabbar.cxx | 14 +- svtools/source/toolpanel/tablayouter.cxx | 2 +- svtools/source/toolpanel/toolpaneldeck.cxx | 4 +- svtools/source/toolpanel/toolpaneldrawer.cxx | 18 +- svtools/source/toolpanel/toolpaneldrawer.hxx | 4 +- svtools/source/uno/generictoolboxcontroller.cxx | 4 +- svtools/source/uno/toolboxcontroller.cxx | 2 +- svtools/source/uno/treecontrolpeer.cxx | 50 +- svtools/source/uno/treecontrolpeer.hxx | 2 +- svtools/source/uno/unoiface.cxx | 6 +- svtools/source/uno/unoimap.cxx | 18 +- svtools/source/uno/wizard/wizardpagecontroller.cxx | 2 +- svtools/source/urlobj/inetimg.cxx | 16 +- svtools/workben/browser.cxx | 4 +- svtools/workben/stest.cxx | 4 +- svtools/workben/svdem.cxx | 24 +- svtools/workben/toolpanel/toolpaneltest.cxx | 6 +- svtools/workben/urange.cxx | 8 +- 290 files changed, 10920 insertions(+), 10920 deletions(-) mode change 100644 => 100755 svtools/source/control/asynclink.cxx mode change 100644 => 100755 svtools/source/control/ctrldll.cxx mode change 100644 => 100755 svtools/source/control/filectrl.cxx mode change 100644 => 100755 svtools/source/control/fmtfield.cxx mode change 100644 => 100755 svtools/source/control/headbar.cxx mode change 100644 => 100755 svtools/source/control/inettbc.cxx mode change 100644 => 100755 svtools/source/control/prgsbar.cxx mode change 100644 => 100755 svtools/source/control/roadmap.cxx mode change 100644 => 100755 svtools/source/control/ruler.cxx mode change 100644 => 100755 svtools/source/control/scriptedtext.cxx mode change 100644 => 100755 svtools/source/control/scrwin.cxx mode change 100644 => 100755 svtools/source/control/stdctrl.cxx mode change 100644 => 100755 svtools/source/control/stdmenu.cxx mode change 100644 => 100755 svtools/source/control/svxbox.cxx mode change 100644 => 100755 svtools/source/control/tabbar.cxx mode change 100644 => 100755 svtools/source/control/taskbar.cxx mode change 100644 => 100755 svtools/source/control/taskbox.cxx mode change 100644 => 100755 svtools/source/control/taskmisc.cxx mode change 100644 => 100755 svtools/source/control/taskstat.cxx (limited to 'svtools') diff --git a/svtools/bmpmaker/bmp.cxx b/svtools/bmpmaker/bmp.cxx index 5b473b0289c2..204fd404d329 100644 --- a/svtools/bmpmaker/bmp.cxx +++ b/svtools/bmpmaker/bmp.cxx @@ -54,19 +54,19 @@ class BmpApp : public BmpCreator private: String aOutputFileName; - BYTE cExitCode; + sal_uInt8 cExitCode; - BOOL GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rSwitchParam ); - BOOL GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rSwitchParams ); + sal_Bool GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rSwitchParam ); + sal_Bool GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rSwitchParams ); - void SetExitCode( BYTE cExit ) + void SetExitCode( sal_uInt8 cExit ) { if( ( EXIT_NOERROR == cExitCode ) || ( cExit != EXIT_NOERROR ) ) cExitCode = cExit; } void ShowUsage(); - virtual void Message( const String& rText, BYTE cExitCode ); + virtual void Message( const String& rText, sal_uInt8 cExitCode ); public: @@ -90,9 +90,9 @@ BmpApp::~BmpApp() // ----------------------------------------------------------------------- -BOOL BmpApp::GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ) +sal_Bool BmpApp::GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ) { - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; for( int i = 0, nCount = rArgs.size(); ( i < nCount ) && !bRet; i++ ) { @@ -104,7 +104,7 @@ BOOL BmpApp::GetCommandOption( const ::std::vector< String >& rArgs, const Strin if( aTestStr.CompareIgnoreCaseToAscii( rArgs[ i ] ) == COMPARE_EQUAL ) { - bRet = TRUE; + bRet = sal_True; if( i < ( nCount - 1 ) ) rParam = rArgs[ i + 1 ]; @@ -122,9 +122,9 @@ BOOL BmpApp::GetCommandOption( const ::std::vector< String >& rArgs, const Strin // ----------------------------------------------------------------------- -BOOL BmpApp::GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rParams ) +sal_Bool BmpApp::GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rParams ) { - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; for( int i = 0, nCount = rArgs.size(); ( i < nCount ); i++ ) { @@ -154,7 +154,7 @@ BOOL BmpApp::GetCommandOptions( const ::std::vector< String >& rArgs, const Stri // ----------------------------------------------------------------------- -void BmpApp::Message( const String& rText, BYTE cExit ) +void BmpApp::Message( const String& rText, sal_uInt8 cExit ) { if( EXIT_NOERROR != cExit ) SetExitCode( cExit ); @@ -188,7 +188,7 @@ int BmpApp::Start( const ::std::vector< String >& rArgs ) if( rArgs.size() >= 6 ) { LangInfo aLangInfo; - USHORT nCurCmd = 0; + sal_uInt16 nCurCmd = 0; const String aSrsName( rArgs[ nCurCmd++ ] ); ::std::vector< String > aInDirVector; ByteString aLangDir; diff --git a/svtools/bmpmaker/bmpcore.cxx b/svtools/bmpmaker/bmpcore.cxx index 9e134c06a670..ed3ae80b2788 100644 --- a/svtools/bmpmaker/bmpcore.cxx +++ b/svtools/bmpmaker/bmpcore.cxx @@ -72,7 +72,7 @@ BmpCreator::~BmpCreator() // ----------------------------------------------------------------------------- -void BmpCreator::Message( const String&, BYTE ) +void BmpCreator::Message( const String&, sal_uInt8 ) { } @@ -329,7 +329,7 @@ void BmpCreator::Create( const String& rSRSName, { DirEntry aFileName( ImplGetSystemFileName( rSRSName ) ), aOutDir( ImplGetSystemFileName( rOutName ) ); ::std::vector< DirEntry > aInDirs; - BOOL bDone = FALSE; + sal_Bool bDone = sal_False; aFileName.ToAbs(); aOutDir.ToAbs(); @@ -361,7 +361,7 @@ void BmpCreator::Create( const String& rSRSName, { String aText; ByteString aByteText; - BOOL bLangDep = FALSE; + sal_Bool bLangDep = sal_False; do { @@ -389,7 +389,7 @@ void BmpCreator::Create( const String& rSRSName, aByteText.Search( '[' ) != STRING_NOTFOUND && aByteText.Search( ']' ) != STRING_NOTFOUND ) { - bLangDep = TRUE; + bLangDep = sal_True; } if (!pSRS->ReadLine(aByteText)) @@ -401,13 +401,13 @@ void BmpCreator::Create( const String& rSRSName, // if image list is not language dependent, don't do anything for languages except german if( aText.Len() ) { - bDone = TRUE; + bDone = sal_True; ImplCreate( aInDirs, aOutDir, aName, rLang ); } /* else if( ( rLang.mnLangNum != 49 ) && !bLangDep ) { Message( String( RTL_CONSTASCII_USTRINGPARAM( "INFO: ImageList is not language dependent! Nothing to do for this language." ) ) ); - bDone = TRUE; + bDone = sal_True; }*/ } while ( aText.Len() ); diff --git a/svtools/bmpmaker/bmpcore.hxx b/svtools/bmpmaker/bmpcore.hxx index ece4fa09cf78..6b28af103717 100644 --- a/svtools/bmpmaker/bmpcore.hxx +++ b/svtools/bmpmaker/bmpcore.hxx @@ -55,7 +55,7 @@ struct LangInfo { char maLangDir[ 257 ]; - USHORT mnLangNum; + sal_uInt16 mnLangNum; }; // -------------- @@ -71,8 +71,8 @@ private: Size aTotSize; Point aPos; SvFileStream* pSRS; - ULONG nTotCount; - USHORT nPos; + sal_uIntPtr nTotCount; + sal_uInt16 nPos; void ImplCreate( const ::std::vector< DirEntry >& rInDirs, const DirEntry& rOut, @@ -81,7 +81,7 @@ private: protected: - virtual void Message( const String& rText, BYTE cExitCode = EXIT_NOERROR ); + virtual void Message( const String& rText, sal_uInt8 cExitCode = EXIT_NOERROR ); public: diff --git a/svtools/bmpmaker/bmpsum.cxx b/svtools/bmpmaker/bmpsum.cxx index 7c264e694a12..0ac43ce57148 100644 --- a/svtools/bmpmaker/bmpsum.cxx +++ b/svtools/bmpmaker/bmpsum.cxx @@ -58,16 +58,16 @@ private: sal_uInt32 cExitCode; - BOOL GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rSwitchParam ); - BOOL GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rSwitchParams ); + sal_Bool GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rSwitchParam ); + sal_Bool GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rSwitchParams ); - void SetExitCode( BYTE cExit ) + void SetExitCode( sal_uInt8 cExit ) { if( ( EXIT_NOERROR == cExitCode ) || ( cExit != EXIT_NOERROR ) ) cExitCode = cExit; } void ShowUsage(); - void Message( const String& rText, BYTE cExitCode ); + void Message( const String& rText, sal_uInt8 cExitCode ); sal_uInt64 GetCRC( const BitmapEx& rBmpEx ); @@ -96,9 +96,9 @@ BmpSum::~BmpSum() // ----------------------------------------------------------------------- -BOOL BmpSum::GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ) +sal_Bool BmpSum::GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ) { - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; for( int i = 0, nCount = rArgs.size(); ( i < nCount ) && !bRet; i++ ) { @@ -110,7 +110,7 @@ BOOL BmpSum::GetCommandOption( const ::std::vector< String >& rArgs, const Strin if( aTestStr.CompareIgnoreCaseToAscii( rArgs[ i ] ) == COMPARE_EQUAL ) { - bRet = TRUE; + bRet = sal_True; if( i < ( nCount - 1 ) ) rParam = rArgs[ i + 1 ]; @@ -128,9 +128,9 @@ BOOL BmpSum::GetCommandOption( const ::std::vector< String >& rArgs, const Strin // ----------------------------------------------------------------------- -BOOL BmpSum::GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rParams ) +sal_Bool BmpSum::GetCommandOptions( const ::std::vector< String >& rArgs, const String& rSwitch, ::std::vector< String >& rParams ) { - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; for( int i = 0, nCount = rArgs.size(); ( i < nCount ); i++ ) { @@ -160,7 +160,7 @@ BOOL BmpSum::GetCommandOptions( const ::std::vector< String >& rArgs, const Stri // ----------------------------------------------------------------------- -void BmpSum::Message( const String& rText, BYTE nExitCode ) +void BmpSum::Message( const String& rText, sal_uInt8 nExitCode ) { if( EXIT_NOERROR != nExitCode ) SetExitCode( nExitCode ); diff --git a/svtools/bmpmaker/g2g.cxx b/svtools/bmpmaker/g2g.cxx index 6f4ee0f86279..0a308cccda40 100644 --- a/svtools/bmpmaker/g2g.cxx +++ b/svtools/bmpmaker/g2g.cxx @@ -56,13 +56,13 @@ class G2GApp { private: - BYTE cExitCode; + sal_uInt8 cExitCode; void ShowUsage(); - BOOL GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ); - void SetExitCode( BYTE cExit ) { if( ( EXIT_NOERROR == cExitCode ) || ( cExit != EXIT_NOERROR ) ) cExitCode = cExit; } + sal_Bool GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ); + void SetExitCode( sal_uInt8 cExit ) { if( ( EXIT_NOERROR == cExitCode ) || ( cExit != EXIT_NOERROR ) ) cExitCode = cExit; } - virtual void Message( const String& rText, BYTE cExitCode = EXIT_NOERROR ); + virtual void Message( const String& rText, sal_uInt8 cExitCode = EXIT_NOERROR ); public: @@ -86,9 +86,9 @@ G2GApp::~G2GApp() // ----------------------------------------------------------------------- -BOOL G2GApp::GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ) +sal_Bool G2GApp::GetCommandOption( const ::std::vector< String >& rArgs, const String& rSwitch, String& rParam ) { - BOOL bRet = FALSE; + sal_Bool bRet = sal_False; for( int i = 0, nCount = rArgs.size(); ( i < nCount ) && !bRet; i++ ) { @@ -100,7 +100,7 @@ BOOL G2GApp::GetCommandOption( const ::std::vector< String >& rArgs, const Strin if( aTestStr.CompareIgnoreCaseToAscii( rArgs[ i ] ) == COMPARE_EQUAL ) { - bRet = TRUE; + bRet = sal_True; if( i < ( nCount - 1 ) ) rParam = rArgs[ i + 1 ]; @@ -118,7 +118,7 @@ BOOL G2GApp::GetCommandOption( const ::std::vector< String >& rArgs, const Strin // ----------------------------------------------------------------------- -void G2GApp::Message( const String& rText, BYTE nExitCode ) +void G2GApp::Message( const String& rText, sal_uInt8 nExitCode ) { if( EXIT_NOERROR != nExitCode ) SetExitCode( nExitCode ); @@ -148,7 +148,7 @@ void G2GApp::ShowUsage() int G2GApp::Start( const ::std::vector< String >& rArgs ) { int nCmdCount = rArgs.size(); - USHORT nCurCmd = 0; + sal_uInt16 nCurCmd = 0; cExitCode = EXIT_NOERROR; @@ -167,7 +167,7 @@ int G2GApp::Start( const ::std::vector< String >& rArgs ) if( aInFile.Len() && aOutFile.Len() && aFilterStr.Len() ) { - const USHORT nExportFilter = aFilter.GetExportFormatNumberForShortName( aFilterStr ); + const sal_uInt16 nExportFilter = aFilter.GetExportFormatNumberForShortName( aFilterStr ); if( GRFILTER_FORMAT_NOTFOUND == nExportFilter ) Message( String( RTL_CONSTASCII_USTRINGPARAM( "invalid graphic filter" ) ), EXIT_INVALID_GRAPHICFILTER ); @@ -198,9 +198,9 @@ int G2GApp::Start( const ::std::vector< String >& rArgs ) if( bHex ) { - const BYTE cTransR = ( LOWERHEXTONUM( aHexStr.GetChar( 0 ) ) << 4 ) | LOWERHEXTONUM( aHexStr.GetChar( 1 ) ); - const BYTE cTransG = ( LOWERHEXTONUM( aHexStr.GetChar( 2 ) ) << 4 ) | LOWERHEXTONUM( aHexStr.GetChar( 3 ) ); - const BYTE cTransB = ( LOWERHEXTONUM( aHexStr.GetChar( 4 ) ) << 4 ) | LOWERHEXTONUM( aHexStr.GetChar( 5 ) ); + const sal_uInt8 cTransR = ( LOWERHEXTONUM( aHexStr.GetChar( 0 ) ) << 4 ) | LOWERHEXTONUM( aHexStr.GetChar( 1 ) ); + const sal_uInt8 cTransG = ( LOWERHEXTONUM( aHexStr.GetChar( 2 ) ) << 4 ) | LOWERHEXTONUM( aHexStr.GetChar( 3 ) ); + const sal_uInt8 cTransB = ( LOWERHEXTONUM( aHexStr.GetChar( 4 ) ) << 4 ) | LOWERHEXTONUM( aHexStr.GetChar( 5 ) ); BitmapEx aBmpEx( aGraphic.GetBitmapEx() ); Bitmap aOldBmp( aBmpEx.GetBitmap() ); diff --git a/svtools/inc/DocumentInfoPreview.hxx b/svtools/inc/DocumentInfoPreview.hxx index ae57b1a68b32..92c9c72b36bc 100644 --- a/svtools/inc/DocumentInfoPreview.hxx +++ b/svtools/inc/DocumentInfoPreview.hxx @@ -53,7 +53,7 @@ namespace svtools ::com::sun::star::document::XDocumentProperties>& i_xDocProps ,const String& i_rURL); void InsertEntry( const String& rTitle, const String& rValue ); - void SetAutoScroll(BOOL _bAutoScroll); + void SetAutoScroll(sal_Bool _bAutoScroll); }; } diff --git a/svtools/inc/acceleratorexecute.hxx b/svtools/inc/acceleratorexecute.hxx index 3ee79e1fca0c..b5e9f99d2c4b 100644 --- a/svtools/inc/acceleratorexecute.hxx +++ b/svtools/inc/acceleratorexecute.hxx @@ -222,7 +222,7 @@ class SVT_DLLPUBLIC AcceleratorExecute : private TMutexInit specify the accelerator for execute. @return [sal_Bool] - TRUE if this key is configured and match to a command. + sal_True if this key is configured and match to a command. Attention: This state does not mean the success state of the corresponding execute. Because its done asynchronous! */ diff --git a/svtools/inc/apearcfg.hxx b/svtools/inc/apearcfg.hxx index 8e6018424c4c..bda7e09828b3 100644 --- a/svtools/inc/apearcfg.hxx +++ b/svtools/inc/apearcfg.hxx @@ -68,11 +68,11 @@ class SVT_DLLPUBLIC SvtTabAppearanceCfg : public utl::ConfigItem short nAAMinPixelHeight ; #endif - BOOL bMenuMouseFollow ; - BOOL bSingleLineTabCtrl ; - BOOL bColoredTabCtrl ; + sal_Bool bMenuMouseFollow ; + sal_Bool bSingleLineTabCtrl ; + sal_Bool bColoredTabCtrl ; #if defined( UNX ) || defined ( FS_PRIV_DEBUG ) - BOOL bFontAntialiasing ; + sal_Bool bFontAntialiasing ; #endif static sal_Bool bInitialized ; @@ -86,39 +86,39 @@ public: virtual void Commit(); virtual void Notify( const com::sun::star::uno::Sequence< rtl::OUString >& _rPropertyNames); - USHORT GetLookNFeel () const { return nLookNFeel; } - void SetLookNFeel ( USHORT nSet ); + sal_uInt16 GetLookNFeel () const { return nLookNFeel; } + void SetLookNFeel ( sal_uInt16 nSet ); - USHORT GetDragMode () const { return nDragMode; } - void SetDragMode ( USHORT nSet ); + sal_uInt16 GetDragMode () const { return nDragMode; } + void SetDragMode ( sal_uInt16 nSet ); - USHORT GetScaleFactor () const { return nScaleFactor; } - void SetScaleFactor ( USHORT nSet ); + sal_uInt16 GetScaleFactor () const { return nScaleFactor; } + void SetScaleFactor ( sal_uInt16 nSet ); - USHORT GetSnapMode () const { return nSnapMode; } - void SetSnapMode ( USHORT nSet ); + sal_uInt16 GetSnapMode () const { return nSnapMode; } + void SetSnapMode ( sal_uInt16 nSet ); - USHORT GetMiddleMouseButton () const { return nMiddleMouse; } - void SetMiddleMouseButton ( USHORT nSet ); + sal_uInt16 GetMiddleMouseButton () const { return nMiddleMouse; } + void SetMiddleMouseButton ( sal_uInt16 nSet ); void SetApplicationDefaults ( Application* pApp ); - void SetMenuMouseFollow(BOOL bSet) {bMenuMouseFollow = bSet; SetModified();} - BOOL IsMenuMouseFollow() const{return bMenuMouseFollow;} + void SetMenuMouseFollow(sal_Bool bSet) {bMenuMouseFollow = bSet; SetModified();} + sal_Bool IsMenuMouseFollow() const{return bMenuMouseFollow;} - void SetSingleLineTabCtrl(BOOL bSet) {bSingleLineTabCtrl = bSet; SetModified();} - BOOL IsSingleLineTabCtrl()const {return bSingleLineTabCtrl;} + void SetSingleLineTabCtrl(sal_Bool bSet) {bSingleLineTabCtrl = bSet; SetModified();} + sal_Bool IsSingleLineTabCtrl()const {return bSingleLineTabCtrl;} #if defined( UNX ) || defined ( FS_PRIV_DEBUG ) - void SetFontAntiAliasing( BOOL bSet ) { bFontAntialiasing = bSet; SetModified(); } - BOOL IsFontAntiAliasing() const { return bFontAntialiasing; } + void SetFontAntiAliasing( sal_Bool bSet ) { bFontAntialiasing = bSet; SetModified(); } + sal_Bool IsFontAntiAliasing() const { return bFontAntialiasing; } - USHORT GetFontAntialiasingMinPixelHeight( ) const { return nAAMinPixelHeight; } - void SetFontAntialiasingMinPixelHeight( USHORT _nMinHeight ) { nAAMinPixelHeight = _nMinHeight; SetModified(); } + sal_uInt16 GetFontAntialiasingMinPixelHeight( ) const { return nAAMinPixelHeight; } + void SetFontAntialiasingMinPixelHeight( sal_uInt16 _nMinHeight ) { nAAMinPixelHeight = _nMinHeight; SetModified(); } #endif - void SetColoredTabCtrl(BOOL bSet) {bColoredTabCtrl = bSet; SetModified();}; - BOOL IsColoredTabCtrl()const {return bColoredTabCtrl;} + void SetColoredTabCtrl(sal_Bool bSet) {bColoredTabCtrl = bSet; SetModified();}; + sal_Bool IsColoredTabCtrl()const {return bColoredTabCtrl;} static sal_Bool IsInitialized() { return bInitialized; } static void SetInitialized() { bInitialized = sal_True; } diff --git a/svtools/inc/asynclink.hxx b/svtools/inc/asynclink.hxx index 41c6f3e92388..efc8afac1064 100644 --- a/svtools/inc/asynclink.hxx +++ b/svtools/inc/asynclink.hxx @@ -44,10 +44,10 @@ namespace svtools { class SVT_DLLPUBLIC AsynchronLink { Link _aLink; - ULONG _nEventId; + sal_uIntPtr _nEventId; Timer* _pTimer; - BOOL _bInCall; - BOOL* _pDeleted; + sal_Bool _bInCall; + sal_Bool* _pDeleted; void* _pArg; vos::OMutex* _pMutex; @@ -56,19 +56,19 @@ class SVT_DLLPUBLIC AsynchronLink public: AsynchronLink( const Link& rLink ) : - _aLink( rLink ), _nEventId( 0 ), _pTimer( 0 ), _bInCall( FALSE ), + _aLink( rLink ), _nEventId( 0 ), _pTimer( 0 ), _bInCall( sal_False ), _pDeleted( 0 ), _pMutex( 0 ){} - AsynchronLink() : _nEventId( 0 ), _pTimer( 0 ), _bInCall( FALSE ), + AsynchronLink() : _nEventId( 0 ), _pTimer( 0 ), _bInCall( sal_False ), _pDeleted( 0 ), _pMutex( 0 ){} ~AsynchronLink(); void CreateMutex(); void operator=( const Link& rLink ) { _aLink = rLink; } - void Call( void* pObj, BOOL bAllowDoubles = FALSE, - BOOL bUseTimer = FALSE ); + void Call( void* pObj, sal_Bool bAllowDoubles = sal_False, + sal_Bool bUseTimer = sal_False ); void ForcePendingCall( ); void ClearPendingCall( ); - BOOL IsSet() const { return _aLink.IsSet(); } + sal_Bool IsSet() const { return _aLink.IsSet(); } Link GetLink() const { return _aLink; } }; diff --git a/svtools/inc/calendar.hxx b/svtools/inc/calendar.hxx index f85887873bb0..1fe0013e055e 100644 --- a/svtools/inc/calendar.hxx +++ b/svtools/inc/calendar.hxx @@ -138,16 +138,16 @@ wenn man beispielsweise den Bereich eingrenzen oder erweitern will. Der Bereich wird mit SelectDate()/SelectDateRange() umgesetzt und mit GetSelectDateCount()/GetSelectDate() abgefragt. Wenn man wissen moechte, in welche Richtung selektiert wird, kann dies ueber IsSelectLeft() -abgefragt werden. TRUE bedeutet eine Selektion nach links oder oben, -FALSE eine Selektion nach rechts oder unten. +abgefragt werden. sal_True bedeutet eine Selektion nach links oder oben, +sal_False eine Selektion nach rechts oder unten. -------------------------------------------------------------------------- Wenn sich der Date-Range-Bereich anpasst und man dort die Selektion uebernehmen will, sollte dies nur gemacht werden, wenn -IsScrollDateRangeChanged() TRUE zurueckliefert. Denn diese Methode liefert -TRUE zurueck, wenn der Bereich durch Betaetigung von den Scroll-Buttons -ausgeloest wurde. Bei FALSE wurde dies durch Resize(), Methoden-Aufrufen +IsScrollDateRangeChanged() sal_True zurueckliefert. Denn diese Methode liefert +sal_True zurueck, wenn der Bereich durch Betaetigung von den Scroll-Buttons +ausgeloest wurde. Bei sal_False wurde dies durch Resize(), Methoden-Aufrufen oder durch Beendigung einer Selektion ausgeloest. *************************************************************************/ @@ -169,7 +169,7 @@ oder durch Beendigung einer Selektion ausgeloest. #define WB_MULTISELECT ((WinBits)0x00400000) #endif -#define DIB_BOLD ((USHORT)0x0001) +#define DIB_BOLD ((sal_uInt16)0x0001) // ------------ // - Calendar - @@ -203,7 +203,7 @@ private: Color* mpStandardColor; Color* mpSaturdayColor; Color* mpSundayColor; - ULONG mnDayCount; + sal_uIntPtr mnDayCount; long mnDaysOffX; long mnWeekDayOffY; long mnDaysOffY; @@ -218,10 +218,10 @@ private: long mnDummy3; long mnDummy4; WinBits mnWinStyle; - USHORT mnFirstYear; - USHORT mnLastYear; - USHORT mnRequestYear; - BOOL mbCalc:1, + sal_uInt16 mnFirstYear; + sal_uInt16 mnLastYear; + sal_uInt16 mnRequestYear; + sal_Bool mbCalc:1, mbFormat:1, mbDrag:1, mbSelection:1, @@ -245,7 +245,7 @@ private: Link maDoubleClickHdl; Link maSelectHdl; Timer maDragScrollTimer; - USHORT mnDragScrollHitTest; + sal_uInt16 mnDragScrollHitTest; #ifdef _SV_CALENDAR_CXX using Control::ImplInitSettings; @@ -255,30 +255,30 @@ private: SVT_DLLPRIVATE void ImplGetWeekFont( Font& rFont ) const; SVT_DLLPRIVATE void ImplFormat(); using Window::ImplHitTest; - SVT_DLLPRIVATE USHORT ImplHitTest( const Point& rPos, Date& rDate ) const; - SVT_DLLPRIVATE void ImplDrawSpin( BOOL bDrawPrev = TRUE, BOOL bDrawNext = TRUE ); + SVT_DLLPRIVATE sal_uInt16 ImplHitTest( const Point& rPos, Date& rDate ) const; + SVT_DLLPRIVATE void ImplDrawSpin( sal_Bool bDrawPrev = sal_True, sal_Bool bDrawNext = sal_True ); SVT_DLLPRIVATE void ImplDrawDate( long nX, long nY, - USHORT nDay, USHORT nMonth, USHORT nYear, + sal_uInt16 nDay, sal_uInt16 nMonth, sal_uInt16 nYear, DayOfWeek eDayOfWeek, - BOOL bBack = TRUE, BOOL bOther = FALSE, - ULONG nToday = 0 ); - SVT_DLLPRIVATE void ImplDraw( BOOL bPaint = FALSE ); + sal_Bool bBack = sal_True, sal_Bool bOther = sal_False, + sal_uIntPtr nToday = 0 ); + SVT_DLLPRIVATE void ImplDraw( sal_Bool bPaint = sal_False ); SVT_DLLPRIVATE void ImplUpdateDate( const Date& rDate ); SVT_DLLPRIVATE void ImplUpdateSelection( Table* pOld ); - SVT_DLLPRIVATE void ImplMouseSelect( const Date& rDate, USHORT nHitTest, - BOOL bMove, BOOL bExpand, BOOL bExtended ); - SVT_DLLPRIVATE void ImplUpdate( BOOL bCalcNew = FALSE ); + SVT_DLLPRIVATE void ImplMouseSelect( const Date& rDate, sal_uInt16 nHitTest, + sal_Bool bMove, sal_Bool bExpand, sal_Bool bExtended ); + SVT_DLLPRIVATE void ImplUpdate( sal_Bool bCalcNew = sal_False ); using Window::ImplScroll; - SVT_DLLPRIVATE void ImplScroll( BOOL bPrev ); + SVT_DLLPRIVATE void ImplScroll( sal_Bool bPrev ); SVT_DLLPRIVATE void ImplInvertDropPos(); SVT_DLLPRIVATE void ImplShowMenu( const Point& rPos, const Date& rDate ); - SVT_DLLPRIVATE void ImplTracking( const Point& rPos, BOOL bRepeat ); - SVT_DLLPRIVATE void ImplEndTracking( BOOL bCancel ); + SVT_DLLPRIVATE void ImplTracking( const Point& rPos, sal_Bool bRepeat ); + SVT_DLLPRIVATE void ImplEndTracking( sal_Bool bCancel ); SVT_DLLPRIVATE DayOfWeek ImplGetWeekStart() const; #endif protected: - BOOL ShowDropPos( const Point& rPos, Date& rDate ); + sal_Bool ShowDropPos( const Point& rPos, Date& rDate ); void HideDropPos(); DECL_STATIC_LINK( Calendar, ScrollHdl, Timer *); @@ -316,29 +316,29 @@ public: /// Set how many days of a week must reside in the first week of a year. void SetMinimumNumberOfDaysInWeek( sal_Int16 nDays ); - void SelectDate( const Date& rDate, BOOL bSelect = TRUE ); + void SelectDate( const Date& rDate, sal_Bool bSelect = sal_True ); void SelectDateRange( const Date& rStartDate, const Date& rEndDate, - BOOL bSelect = TRUE ); + sal_Bool bSelect = sal_True ); void SetNoSelection(); - BOOL IsDateSelected( const Date& rDate ) const; - ULONG GetSelectDateCount() const; - Date GetSelectDate( ULONG nIndex = 0 ) const; - void EnableCallEverySelect( BOOL bEvery = TRUE ) { mbAllSel = bEvery; } - BOOL IsCallEverySelectEnabled() const { return mbAllSel; } + sal_Bool IsDateSelected( const Date& rDate ) const; + sal_uIntPtr GetSelectDateCount() const; + Date GetSelectDate( sal_uIntPtr nIndex = 0 ) const; + void EnableCallEverySelect( sal_Bool bEvery = sal_True ) { mbAllSel = bEvery; } + sal_Bool IsCallEverySelectEnabled() const { return mbAllSel; } - USHORT GetRequestYear() const { return mnRequestYear; } + sal_uInt16 GetRequestYear() const { return mnRequestYear; } void SetCurDate( const Date& rNewDate ); Date GetCurDate() const { return maCurDate; } void SetFirstDate( const Date& rNewFirstDate ); Date GetFirstDate() const { return maFirstDate; } Date GetLastDate() const { return GetFirstDate() + mnDayCount; } - ULONG GetDayCount() const { return mnDayCount; } + sal_uIntPtr GetDayCount() const { return mnDayCount; } Date GetFirstMonth() const; Date GetLastMonth() const; - USHORT GetMonthCount() const; - BOOL GetDate( const Point& rPos, Date& rDate ) const; + sal_uInt16 GetMonthCount() const; + sal_Bool GetDate( const Point& rPos, Date& rDate ) const; Rectangle GetDateRect( const Date& rDate ) const; - BOOL GetDropDate( Date& rDate ) const; + sal_Bool GetDropDate( Date& rDate ) const; long GetCurMonthPerLine() const { return mnMonthPerLine; } long GetCurLines() const { return mnLines; } @@ -353,7 +353,7 @@ public: void AddDateInfo( const Date& rDate, const XubString& rText, const Color* pTextColor = NULL, const Color* pFrameColor = NULL, - USHORT nFlags = 0 ); + sal_uInt16 nFlags = 0 ); void RemoveDateInfo( const Date& rDate ); void ClearDateInfo(); XubString GetDateInfoText( const Date& rDate ); @@ -361,9 +361,9 @@ public: void StartSelection(); void EndSelection(); - BOOL IsTravelSelect() const { return mbTravelSelect; } - BOOL IsScrollDateRangeChanged() const { return mbScrollDateRange; } - BOOL IsSelectLeft() const { return mbSelLeft; } + sal_Bool IsTravelSelect() const { return mbTravelSelect; } + sal_Bool IsScrollDateRangeChanged() const { return mbScrollDateRange; } + sal_Bool IsSelectLeft() const { return mbSelLeft; } Size CalcWindowSizePixel( long nCalcMonthPerLine = 1, long nCalcLines = 1 ) const; @@ -459,8 +459,8 @@ private: PushButton* mpTodayBtn; PushButton* mpNoneBtn; Date maDefaultDate; - BOOL mbToday; - BOOL mbNone; + sal_Bool mbToday; + sal_Bool mbNone; Link maSelectHdl; #ifdef _SV_CALENDAR_CXX @@ -476,17 +476,17 @@ public: virtual void Select(); - virtual BOOL ShowDropDown( BOOL bShow ); + virtual sal_Bool ShowDropDown( sal_Bool bShow ); virtual Calendar* CreateCalendar( Window* pParent ); Calendar* GetCalendar(); void SetDefaultDate( const Date& rDate ) { maDefaultDate = rDate; } Date GetDefaultDate() const { return maDefaultDate; } - void EnableToday( BOOL bToday = TRUE ) { mbToday = bToday; } - BOOL IsTodayEnabled() const { return mbToday; } - void EnableNone( BOOL bNone = TRUE ) { mbNone = bNone; } - BOOL IsNoneEnabled() const { return mbNone; } + void EnableToday( sal_Bool bToday = sal_True ) { mbToday = bToday; } + sal_Bool IsTodayEnabled() const { return mbToday; } + void EnableNone( sal_Bool bNone = sal_True ) { mbNone = bNone; } + sal_Bool IsNoneEnabled() const { return mbNone; } void SetCalendarStyle( WinBits nStyle ) { mnCalendarStyle = nStyle; } WinBits GetCalendarStyle() const { return mnCalendarStyle; } diff --git a/svtools/inc/cliplistener.hxx b/svtools/inc/cliplistener.hxx index ab20d6d7aa20..5051633bd6b6 100644 --- a/svtools/inc/cliplistener.hxx +++ b/svtools/inc/cliplistener.hxx @@ -46,7 +46,7 @@ public: TransferableClipboardListener( const Link& rCallback ); ~TransferableClipboardListener(); - void AddRemoveListener( Window* pWin, BOOL bAdd ); + void AddRemoveListener( Window* pWin, sal_Bool bAdd ); void ClearCallbackLink(); // XEventListener diff --git a/svtools/inc/ctrlbox.hxx b/svtools/inc/ctrlbox.hxx index 9e6e942daf1e..46e3a64d49f6 100644 --- a/svtools/inc/ctrlbox.hxx +++ b/svtools/inc/ctrlbox.hxx @@ -181,60 +181,60 @@ public: virtual void UserDraw( const UserDrawEvent& rUDEvt ); using ListBox::InsertEntry; - virtual USHORT InsertEntry( const XubString& rStr, - USHORT nPos = LISTBOX_APPEND ); - virtual USHORT InsertEntry( const Color& rColor, const XubString& rStr, - USHORT nPos = LISTBOX_APPEND ); + virtual sal_uInt16 InsertEntry( const XubString& rStr, + sal_uInt16 nPos = LISTBOX_APPEND ); + virtual sal_uInt16 InsertEntry( const Color& rColor, const XubString& rStr, + sal_uInt16 nPos = LISTBOX_APPEND ); void InsertAutomaticEntry(); using ListBox::RemoveEntry; - virtual void RemoveEntry( USHORT nPos ); + virtual void RemoveEntry( sal_uInt16 nPos ); virtual void Clear(); void CopyEntries( const ColorListBox& rBox ); using ListBox::GetEntryPos; - virtual USHORT GetEntryPos( const Color& rColor ) const; - virtual Color GetEntryColor( USHORT nPos ) const; + virtual sal_uInt16 GetEntryPos( const Color& rColor ) const; + virtual Color GetEntryColor( sal_uInt16 nPos ) const; Size GetImageSize() const { return aImageSize; } - void SelectEntry( const XubString& rStr, BOOL bSelect = TRUE ) + void SelectEntry( const XubString& rStr, sal_Bool bSelect = sal_True ) { ListBox::SelectEntry( rStr, bSelect ); } - void SelectEntry( const Color& rColor, BOOL bSelect = TRUE ); - XubString GetSelectEntry( USHORT nSelIndex = 0 ) const + void SelectEntry( const Color& rColor, sal_Bool bSelect = sal_True ); + XubString GetSelectEntry( sal_uInt16 nSelIndex = 0 ) const { return ListBox::GetSelectEntry( nSelIndex ); } - Color GetSelectEntryColor( USHORT nSelIndex = 0 ) const; - BOOL IsEntrySelected( const XubString& rStr ) const + Color GetSelectEntryColor( sal_uInt16 nSelIndex = 0 ) const; + sal_Bool IsEntrySelected( const XubString& rStr ) const { return ListBox::IsEntrySelected( rStr ); } - BOOL IsEntrySelected( const Color& rColor ) const; + sal_Bool IsEntrySelected( const Color& rColor ) const; private: // declared as private because some compilers would generate the default functions ColorListBox( const ColorListBox& ); ColorListBox& operator =( const ColorListBox& ); - void SetEntryData( USHORT nPos, void* pNewData ); - void* GetEntryData( USHORT nPos ) const; + void SetEntryData( sal_uInt16 nPos, void* pNewData ); + void* GetEntryData( sal_uInt16 nPos ) const; }; -inline void ColorListBox::SelectEntry( const Color& rColor, BOOL bSelect ) +inline void ColorListBox::SelectEntry( const Color& rColor, sal_Bool bSelect ) { - USHORT nPos = GetEntryPos( rColor ); + sal_uInt16 nPos = GetEntryPos( rColor ); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) ListBox::SelectEntryPos( nPos, bSelect ); } -inline BOOL ColorListBox::IsEntrySelected( const Color& rColor ) const +inline sal_Bool ColorListBox::IsEntrySelected( const Color& rColor ) const { - USHORT nPos = GetEntryPos( rColor ); + sal_uInt16 nPos = GetEntryPos( rColor ); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) return IsEntryPosSelected( nPos ); else - return FALSE; + return sal_False; } -inline Color ColorListBox::GetSelectEntryColor( USHORT nSelIndex ) const +inline Color ColorListBox::GetSelectEntryColor( sal_uInt16 nSelIndex ) const { - USHORT nPos = GetSelectEntryPos( nSelIndex ); + sal_uInt16 nPos = GetSelectEntryPos( nSelIndex ); Color aColor; if ( nPos != LISTBOX_ENTRY_NOTFOUND ) aColor = GetEntryColor( nPos ); @@ -259,7 +259,7 @@ class SVT_DLLPUBLIC LineListBox : public ListBox using Window::ImplInit; SVT_DLLPRIVATE void ImplInit(); void UpdateLineColors( void ); - BOOL UpdatePaintLineColor( void ); // returns TRUE if maPaintCol has changed + sal_Bool UpdatePaintLineColor( void ); // returns sal_True if maPaintCol has changed inline const Color& GetPaintColor( void ) const; virtual void DataChanged( const DataChangedEvent& rDCEvt ); @@ -269,25 +269,25 @@ public: virtual ~LineListBox(); using ListBox::InsertEntry; - virtual USHORT InsertEntry( const XubString& rStr, USHORT nPos = LISTBOX_APPEND ); - virtual USHORT InsertEntry( long nLine1, long nLine2 = 0, long nDistance = 0, USHORT nPos = LISTBOX_APPEND ); + virtual sal_uInt16 InsertEntry( const XubString& rStr, sal_uInt16 nPos = LISTBOX_APPEND ); + virtual sal_uInt16 InsertEntry( long nLine1, long nLine2 = 0, long nDistance = 0, sal_uInt16 nPos = LISTBOX_APPEND ); using ListBox::RemoveEntry; - virtual void RemoveEntry( USHORT nPos ); + virtual void RemoveEntry( sal_uInt16 nPos ); virtual void Clear(); using ListBox::GetEntryPos; - USHORT GetEntryPos( long nLine1, long nLine2 = 0, long nDistance = 0 ) const; - long GetEntryLine1( USHORT nPos ) const; - long GetEntryLine2( USHORT nPos ) const; - long GetEntryDistance( USHORT nPos ) const; - - inline void SelectEntry( const XubString& rStr, BOOL bSelect = TRUE ) { ListBox::SelectEntry( rStr, bSelect ); } - void SelectEntry( long nLine1, long nLine2 = 0, long nDistance = 0, BOOL bSelect = TRUE ); - long GetSelectEntryLine1( USHORT nSelIndex = 0 ) const; - long GetSelectEntryLine2( USHORT nSelIndex = 0 ) const; - long GetSelectEntryDistance( USHORT nSelIndex = 0 ) const; - inline BOOL IsEntrySelected( const XubString& rStr ) const { return ListBox::IsEntrySelected( rStr ); } - BOOL IsEntrySelected( long nLine1, long nLine2 = 0, long nDistance = 0 ) const; + sal_uInt16 GetEntryPos( long nLine1, long nLine2 = 0, long nDistance = 0 ) const; + long GetEntryLine1( sal_uInt16 nPos ) const; + long GetEntryLine2( sal_uInt16 nPos ) const; + long GetEntryDistance( sal_uInt16 nPos ) const; + + inline void SelectEntry( const XubString& rStr, sal_Bool bSelect = sal_True ) { ListBox::SelectEntry( rStr, bSelect ); } + void SelectEntry( long nLine1, long nLine2 = 0, long nDistance = 0, sal_Bool bSelect = sal_True ); + long GetSelectEntryLine1( sal_uInt16 nSelIndex = 0 ) const; + long GetSelectEntryLine2( sal_uInt16 nSelIndex = 0 ) const; + long GetSelectEntryDistance( sal_uInt16 nSelIndex = 0 ) const; + inline sal_Bool IsEntrySelected( const XubString& rStr ) const { return ListBox::IsEntrySelected( rStr ); } + sal_Bool IsEntrySelected( long nLine1, long nLine2 = 0, long nDistance = 0 ) const; inline void SetUnit( FieldUnit eNewUnit ) { eUnit = eNewUnit; } inline FieldUnit GetUnit() const { return eUnit; } @@ -301,51 +301,51 @@ private: // declared as private because some compilers would generate the default methods LineListBox( const LineListBox& ); LineListBox& operator =( const LineListBox& ); - void SetEntryData( USHORT nPos, void* pNewData ); - void* GetEntryData( USHORT nPos ) const; + void SetEntryData( sal_uInt16 nPos, void* pNewData ); + void* GetEntryData( sal_uInt16 nPos ) const; }; -inline void LineListBox::SelectEntry( long nLine1, long nLine2, long nDistance, BOOL bSelect ) +inline void LineListBox::SelectEntry( long nLine1, long nLine2, long nDistance, sal_Bool bSelect ) { - USHORT nPos = GetEntryPos( nLine1, nLine2, nDistance ); + sal_uInt16 nPos = GetEntryPos( nLine1, nLine2, nDistance ); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) ListBox::SelectEntryPos( nPos, bSelect ); } -inline long LineListBox::GetSelectEntryLine1( USHORT nSelIndex ) const +inline long LineListBox::GetSelectEntryLine1( sal_uInt16 nSelIndex ) const { - USHORT nPos = GetSelectEntryPos( nSelIndex ); + sal_uInt16 nPos = GetSelectEntryPos( nSelIndex ); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) return GetEntryLine1( nPos ); else return 0; } -inline long LineListBox::GetSelectEntryLine2( USHORT nSelIndex ) const +inline long LineListBox::GetSelectEntryLine2( sal_uInt16 nSelIndex ) const { - USHORT nPos = GetSelectEntryPos( nSelIndex ); + sal_uInt16 nPos = GetSelectEntryPos( nSelIndex ); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) return GetEntryLine2( nPos ); else return 0; } -inline long LineListBox::GetSelectEntryDistance( USHORT nSelIndex ) const +inline long LineListBox::GetSelectEntryDistance( sal_uInt16 nSelIndex ) const { - USHORT nPos = GetSelectEntryPos( nSelIndex ); + sal_uInt16 nPos = GetSelectEntryPos( nSelIndex ); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) return GetEntryDistance( nPos ); else return 0; } -inline BOOL LineListBox::IsEntrySelected( long nLine1, long nLine2, long nDistance ) const +inline sal_Bool LineListBox::IsEntrySelected( long nLine1, long nLine2, long nDistance ) const { - USHORT nPos = GetEntryPos( nLine1, nLine2, nDistance ); + sal_uInt16 nPos = GetEntryPos( nLine1, nLine2, nDistance ); if ( nPos != LISTBOX_ENTRY_NOTFOUND ) return IsEntryPosSelected( nPos ); else - return FALSE; + return sal_False; } inline void LineListBox::SetColor( const Color& rColor ) @@ -372,8 +372,8 @@ private: Image maImagePrinterFont; Image maImageBitmapFont; Image maImageScalableFont; - BOOL mbWYSIWYG; - BOOL mbSymbols; + sal_Bool mbWYSIWYG; + sal_Bool mbSymbols; #ifdef _CTRLBOX_CXX SVT_DLLPRIVATE void ImplCalcUserItemSize(); @@ -393,11 +393,11 @@ public: void Fill( const FontList* pList ); - void EnableWYSIWYG( BOOL bEnable = TRUE ); - BOOL IsWYSIWYGEnabled() const { return mbWYSIWYG; } + void EnableWYSIWYG( sal_Bool bEnable = sal_True ); + sal_Bool IsWYSIWYGEnabled() const { return mbWYSIWYG; } - void EnableSymbols( BOOL bEnable = TRUE ); - BOOL IsSymbolsEnabled() const { return mbSymbols; } + void EnableSymbols( sal_Bool bEnable = sal_True ); + sal_Bool IsSymbolsEnabled() const { return mbSymbols; } private: // declared as private because some compilers would generate the default functions @@ -447,13 +447,13 @@ class SVT_DLLPUBLIC FontSizeBox : public MetricBox { FontInfo aFontInfo; const FontList* pFontList; - USHORT nRelMin; - USHORT nRelMax; - USHORT nRelStep; + sal_uInt16 nRelMin; + sal_uInt16 nRelMax; + sal_uInt16 nRelStep; short nPtRelMin; short nPtRelMax; short nPtRelStep; - BOOL bRelativeMode:1, + sal_Bool bRelativeMode:1, bRelative:1, bPtRelative:1, bStdSize:1; @@ -476,22 +476,22 @@ public: void Fill( const FontInfo* pInfo, const FontList* pList ); - void EnableRelativeMode( USHORT nMin = 50, USHORT nMax = 150, - USHORT nStep = 5 ); + void EnableRelativeMode( sal_uInt16 nMin = 50, sal_uInt16 nMax = 150, + sal_uInt16 nStep = 5 ); void EnablePtRelativeMode( short nMin = -200, short nMax = 200, short nStep = 10 ); - BOOL IsRelativeMode() const { return bRelativeMode; } - void SetRelative( BOOL bRelative = FALSE ); - BOOL IsRelative() const { return bRelative; } - void SetPtRelative( BOOL bPtRel = TRUE ) - { bPtRelative = bPtRel; SetRelative( TRUE ); } - BOOL IsPtRelative() const { return bPtRelative; } + sal_Bool IsRelativeMode() const { return bRelativeMode; } + void SetRelative( sal_Bool bRelative = sal_False ); + sal_Bool IsRelative() const { return bRelative; } + void SetPtRelative( sal_Bool bPtRel = sal_True ) + { bPtRelative = bPtRel; SetRelative( sal_True ); } + sal_Bool IsPtRelative() const { return bPtRelative; } virtual void SetValue( sal_Int64 nNewValue, FieldUnit eInUnit ); virtual void SetValue( sal_Int64 nNewValue ); virtual sal_Int64 GetValue( FieldUnit eOutUnit ) const; virtual sal_Int64 GetValue() const; - sal_Int64 GetValue( USHORT nPos, FieldUnit eOutUnit ) const; + sal_Int64 GetValue( sal_uInt16 nPos, FieldUnit eOutUnit ) const; void SetUserValue( sal_Int64 nNewValue, FieldUnit eInUnit ); void SetUserValue( sal_Int64 nNewValue ) { SetUserValue( nNewValue, FUNIT_NONE ); } diff --git a/svtools/inc/ctrltool.hxx b/svtools/inc/ctrltool.hxx index a0eb5db2b955..91587bef7f28 100644 --- a/svtools/inc/ctrltool.hxx +++ b/svtools/inc/ctrltool.hxx @@ -63,7 +63,7 @@ class FontNameMenu, class FontStyleMenu, class FontSizeMenu -------------------------------------------------------------------------- FontList::FontList( OutputDevice* pDevice, OutputDevice* pDevice2 = NULL, - BOOL bAll = TRUE ); + sal_Bool bAll = sal_True ); Konstruktor der Klasse FontList. Vom uebergebenen OutputDevice werden die entsprechenden Fonts abgefragt. Das OutputDevice muss solange existieren, @@ -80,8 +80,8 @@ Device-Schriften (eine fuer Drucker und eine fuer den Bildschirm) vorhanden sind, wird die vom uebergebenen Device "pDevice" bevorzugt. Mit dem dritten Parameter kann man angeben, ob nur skalierbare Schriften -abgefragt werden sollen oder alle. Wenn TRUE uebergeben wird, werden auch -Bitmap-Schriften mit abgefragt. Bei FALSE werden Vector-Schriften und +abgefragt werden sollen oder alle. Wenn sal_True uebergeben wird, werden auch +Bitmap-Schriften mit abgefragt. Bei sal_False werden Vector-Schriften und scalierbare Schriften abgefragt. -------------------------------------------------------------------------- @@ -147,11 +147,11 @@ von der FontList, sollte deshalb das Array nicht mehr referenziert werden. // - FontList - // ------------ -#define FONTLIST_FONTINFO_NOTFOUND ((USHORT)0xFFFF) +#define FONTLIST_FONTINFO_NOTFOUND ((sal_uInt16)0xFFFF) -#define FONTLIST_FONTNAMETYPE_PRINTER ((USHORT)0x0001) -#define FONTLIST_FONTNAMETYPE_SCREEN ((USHORT)0x0002) -#define FONTLIST_FONTNAMETYPE_SCALABLE ((USHORT)0x0004) +#define FONTLIST_FONTNAMETYPE_PRINTER ((sal_uInt16)0x0001) +#define FONTLIST_FONTNAMETYPE_SCREEN ((sal_uInt16)0x0002) +#define FONTLIST_FONTNAMETYPE_SCALABLE ((sal_uInt16)0x0004) class SVT_DLLPUBLIC FontList : private List { @@ -175,16 +175,16 @@ private: OutputDevice* mpDev2; #ifdef CTRLTOOL_CXX - SVT_DLLPRIVATE ImplFontListNameInfo* ImplFind( const XubString& rSearchName, ULONG* pIndex ) const; + SVT_DLLPRIVATE ImplFontListNameInfo* ImplFind( const XubString& rSearchName, sal_uIntPtr* pIndex ) const; SVT_DLLPRIVATE ImplFontListNameInfo* ImplFindByName( const XubString& rStr ) const; - SVT_DLLPRIVATE void ImplInsertFonts( OutputDevice* pDev, BOOL bAll, - BOOL bInsertData ); + SVT_DLLPRIVATE void ImplInsertFonts( OutputDevice* pDev, sal_Bool bAll, + sal_Bool bInsertData ); #endif public: FontList( OutputDevice* pDevice, OutputDevice* pDevice2 = NULL, - BOOL bAll = TRUE ); + sal_Bool bAll = sal_True ); ~FontList(); FontList* Clone() const; @@ -192,7 +192,7 @@ public: OutputDevice* GetDevice() const { return mpDev; } OutputDevice* GetDevice2() const { return mpDev2; } XubString GetFontMapText( const FontInfo& rInfo ) const; - USHORT GetFontNameType( const XubString& rFontName ) const; + sal_uInt16 GetFontNameType( const XubString& rFontName ) const; const XubString& GetNormalStr() const { return maNormal; } const XubString& GetItalicStr() const { return maNormalItalic; } @@ -207,11 +207,11 @@ public: FontWeight eWeight, FontItalic eItalic ) const; - BOOL IsAvailable( const XubString& rName ) const; - USHORT GetFontNameCount() const - { return (USHORT)List::Count(); } - const FontInfo& GetFontName( USHORT nFont ) const; - USHORT GetFontNameType( USHORT nFont ) const; + sal_Bool IsAvailable( const XubString& rName ) const; + sal_uInt16 GetFontNameCount() const + { return (sal_uInt16)List::Count(); } + const FontInfo& GetFontName( sal_uInt16 nFont ) const; + sal_uInt16 GetFontNameType( sal_uInt16 nFont ) const; sal_Handle GetFirstFontInfo( const XubString& rName ) const; sal_Handle GetNextFontInfo( sal_Handle hFontInfo ) const; const FontInfo& GetFontInfo( sal_Handle hFontInfo ) const; @@ -233,19 +233,19 @@ class SVT_DLLPUBLIC FontSizeNames { private: struct ImplFSNameItem* mpArray; - ULONG mnElem; + sal_uIntPtr mnElem; public: FontSizeNames( LanguageType eLanguage /* = LANGUAGE_DONTKNOW */ ); - ULONG Count() const { return mnElem; } - BOOL IsEmpty() const { return !mnElem; } + sal_uIntPtr Count() const { return mnElem; } + sal_Bool IsEmpty() const { return !mnElem; } long Name2Size( const String& ) const; String Size2Name( long ) const; - String GetIndexName( ULONG nIndex ) const; - long GetIndexSize( ULONG nIndex ) const; + String GetIndexName( sal_uIntPtr nIndex ) const; + long GetIndexSize( sal_uIntPtr nIndex ) const; }; #endif // _CTRLTOOL_HXX diff --git a/svtools/inc/expander.hxx b/svtools/inc/expander.hxx index c0f3cfc7632a..ec53a515c989 100644 --- a/svtools/inc/expander.hxx +++ b/svtools/inc/expander.hxx @@ -52,9 +52,9 @@ private: Image aActiveImage; Rectangle maFocusRect; ImageList maExpanderImages; - BOOL mbIsExpanded; - BOOL mbHasFocusRect; - BOOL mbIsInMouseDown; + sal_Bool mbIsExpanded; + sal_Bool mbHasFocusRect; + sal_Bool mbIsInMouseDown; Link maToggleHdl; SvExpanderStateType eType; @@ -75,9 +75,9 @@ public: SvExpander( Window* pParent, WinBits nStyle = 0 ); SvExpander( Window* pParent, const ResId& rResId ); - BOOL IsExpanded() {return mbIsExpanded;} + sal_Bool IsExpanded() {return mbIsExpanded;} - void SetToExpanded(BOOL bFlag=TRUE); + void SetToExpanded(sal_Bool bFlag=sal_True); void SetExpanderImage( SvExpanderStateType eType); Image GetExpanderImage(SvExpanderStateType eType); diff --git a/svtools/inc/filectrl.hxx b/svtools/inc/filectrl.hxx index dd314bb23ca1..c88689ea0338 100644 --- a/svtools/inc/filectrl.hxx +++ b/svtools/inc/filectrl.hxx @@ -39,14 +39,14 @@ #define STR_FILECTRL_BUTTONTEXT 333 // ID-Range?! // Flags for FileControl -typedef USHORT FileControlMode; -#define FILECTRL_RESIZEBUTTONBYPATHLEN ((USHORT)0x0001)//if this is set, the button will become small as soon as the Text in the Edit Field is to long to be shown completely +typedef sal_uInt16 FileControlMode; +#define FILECTRL_RESIZEBUTTONBYPATHLEN ((sal_uInt16)0x0001)//if this is set, the button will become small as soon as the Text in the Edit Field is to long to be shown completely // Flags for internal use of FileControl -typedef USHORT FileControlMode_Internal; -#define FILECTRL_INRESIZE ((USHORT)0x0001) -#define FILECTRL_ORIGINALBUTTONTEXT ((USHORT)0x0002) +typedef sal_uInt16 FileControlMode_Internal; +#define FILECTRL_INRESIZE ((sal_uInt16)0x0001) +#define FILECTRL_ORIGINALBUTTONTEXT ((sal_uInt16)0x0002) class SVT_DLLPUBLIC FileControl : public Window @@ -56,7 +56,7 @@ private: PushButton maButton; String maButtonText; - BOOL mbOpenDlg; + sal_Bool mbOpenDlg; Link maDialogCreatedHdl; @@ -80,10 +80,10 @@ public: Edit& GetEdit() { return maEdit; } PushButton& GetButton() { return maButton; } - void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, ULONG nFlags ); + void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, sal_uIntPtr nFlags ); - void SetOpenDialog( BOOL bOpen ) { mbOpenDlg = bOpen; } - BOOL IsOpenDialog() const { return mbOpenDlg; } + void SetOpenDialog( sal_Bool bOpen ) { mbOpenDlg = bOpen; } + sal_Bool IsOpenDialog() const { return mbOpenDlg; } void SetText( const XubString& rStr ); XubString GetText() const; @@ -92,8 +92,8 @@ public: void SetSelection( const Selection& rSelection ) { maEdit.SetSelection( rSelection ); } Selection GetSelection() const { return maEdit.GetSelection(); } - void SetReadOnly( BOOL bReadOnly = TRUE ) { maEdit.SetReadOnly( bReadOnly ); } - BOOL IsReadOnly() const { return maEdit.IsReadOnly(); } + void SetReadOnly( sal_Bool bReadOnly = sal_True ) { maEdit.SetReadOnly( bReadOnly ); } + sal_Bool IsReadOnly() const { return maEdit.IsReadOnly(); } //------ //manipulate the Button-Text: diff --git a/svtools/inc/filedlg.hxx b/svtools/inc/filedlg.hxx index c04e48fc7658..59fd393ea73c 100644 --- a/svtools/inc/filedlg.hxx +++ b/svtools/inc/filedlg.hxx @@ -53,7 +53,7 @@ protected: UniString aDfltExt; // Default - Extension public: - PathDialog( Window* pParent, WinBits nWinStyle = 0, BOOL bCreateDir = TRUE ); + PathDialog( Window* pParent, WinBits nWinStyle = 0, sal_Bool bCreateDir = sal_True ); ~PathDialog(); virtual long OK(); @@ -92,9 +92,9 @@ public: void RemoveAllFilter(); void SetCurFilter( const UniString& rFilter ); UniString GetCurFilter() const; - USHORT GetFilterCount() const; - UniString GetFilterName( USHORT nPos ) const; - UniString GetFilterType( USHORT nPos ) const; + sal_uInt16 GetFilterCount() const; + UniString GetFilterName( sal_uInt16 nPos ) const; + UniString GetFilterType( sal_uInt16 nPos ) const; void SetFileSelectHdl( const Link& rLink ) { aFileHdlLink = rLink; } const Link& GetFileSelectHdl() const { return aFileHdlLink; } diff --git a/svtools/inc/fileview.hxx b/svtools/inc/fileview.hxx index 74476541dcd8..969efc228ae9 100644 --- a/svtools/inc/fileview.hxx +++ b/svtools/inc/fileview.hxx @@ -189,7 +189,7 @@ public: void SetDoubleClickHdl( const Link& rHdl ); void SetOpenDoneHdl( const Link& rHdl ); - ULONG GetSelectionCount() const; + sal_uIntPtr GetSelectionCount() const; SvLBoxEntry* FirstSelected() const; SvLBoxEntry* NextSelected( SvLBoxEntry* pEntry ) const; void EnableAutoResize(); @@ -199,7 +199,7 @@ public: void EnableDelete( sal_Bool bEnable ); void EnableNameReplacing( sal_Bool bEnable = sal_True ); // translate folder names or display doc-title instead of file name - // EnableContextMenu( TRUE )/EnableDelete(TRUE) disable name replacing! + // EnableContextMenu( sal_True )/EnableDelete(sal_True) disable name replacing! // save and load column size and sort order String GetConfigString() const; diff --git a/svtools/inc/fltdefs.hxx b/svtools/inc/fltdefs.hxx index 8ef3f2ab3740..fcfc76026eb9 100644 --- a/svtools/inc/fltdefs.hxx +++ b/svtools/inc/fltdefs.hxx @@ -40,12 +40,12 @@ typedef struct RGBQUAD { - BYTE rgbBlue; - BYTE rgbGreen; - BYTE rgbRed; - BYTE rgbReserved; + sal_uInt8 rgbBlue; + sal_uInt8 rgbGreen; + sal_uInt8 rgbRed; + sal_uInt8 rgbReserved; - RGBQUAD( const BYTE cRed = 0, const BYTE cGreen = 0, const BYTE cBlue = 0 ) : + RGBQUAD( const sal_uInt8 cRed = 0, const sal_uInt8 cGreen = 0, const sal_uInt8 cBlue = 0 ) : rgbBlue ( cBlue ), rgbGreen ( cGreen ), rgbRed ( cRed ), @@ -54,7 +54,7 @@ typedef struct RGBQUAD #ifdef WIN -typedef BYTE huge* PDIBBYTE; +typedef sal_uInt8 huge* PDIBBYTE; #define MEMCPY hmemcpy #define GLOBALALLOC(nSize) ((PDIBBYTE)GlobalLock(GlobalAlloc(GHND,(nSize)))) #define GLOBALHANDLE(pPointer) ((HGLOBAL)GlobalHandle((*((size_t*)&(pPointer)+1)))) @@ -62,13 +62,13 @@ typedef BYTE huge* PDIBBYTE; #define MEMSET( pDst, cByte, nCount ) \ { \ PDIBBYTE pTmp = (PDIBBYTE) pDst; \ - for ( ULONG i = 0; i < nCount; i++ )\ + for ( sal_uIntPtr i = 0; i < nCount; i++ )\ *pTmp++ = cByte; \ } #else -typedef BYTE* PDIBBYTE; +typedef sal_uInt8* PDIBBYTE; #define MEMCPY memcpy #define MEMSET memset #define GLOBALALLOC(nSize) ((PDIBBYTE)GlobalAlloc(GMEM_FIXED,(nSize))) @@ -78,18 +78,18 @@ typedef BYTE* PDIBBYTE; #endif #else -typedef BYTE* PDIBBYTE; +typedef sal_uInt8* PDIBBYTE; #define MEMCPY memcpy #define MEMSET memset -#define GLOBALALLOC(nSize) ((PDIBBYTE)new BYTE[(nSize)]) +#define GLOBALALLOC(nSize) ((PDIBBYTE)new sal_uInt8[(nSize)]) #define GLOBALFREE(pPointer) (delete[] (pPointer)) #endif #if defined ( OS2 ) || defined ( UNX ) -void ReadBitmap( SvStream& rIStream, Bitmap& rBmp, USHORT nDefaultHeight = 0, ULONG nOffBits = 0 ); -void ReplaceInfoHeader( SvStream& rStm, BYTE* pBuffer ); +void ReadBitmap( SvStream& rIStream, Bitmap& rBmp, sal_uInt16 nDefaultHeight = 0, sal_uIntPtr nOffBits = 0 ); +void ReplaceInfoHeader( SvStream& rStm, sal_uInt8* pBuffer ); #ifdef OS2 #define RGBQUAD RGBQUADOS2 @@ -103,12 +103,12 @@ void ReplaceInfoHeader( SvStream& rStm, BYTE* pBuffer ); typedef struct RGBQUAD { - BYTE rgbBlue; - BYTE rgbGreen; - BYTE rgbRed; - BYTE rgbReserved; + sal_uInt8 rgbBlue; + sal_uInt8 rgbGreen; + sal_uInt8 rgbRed; + sal_uInt8 rgbReserved; - RGBQUAD( const BYTE cRed = 0, const BYTE cGreen = 0, const BYTE cBlue = 0 ) : + RGBQUAD( const sal_uInt8 cRed = 0, const sal_uInt8 cGreen = 0, const sal_uInt8 cBlue = 0 ) : rgbBlue ( cBlue ), rgbGreen ( cGreen ), rgbRed ( cRed ), @@ -117,27 +117,27 @@ typedef struct RGBQUAD typedef struct BITMAPFILEHEADER { - UINT16 bfType; - UINT32 bfSize; - UINT16 bfReserved1; - UINT16 bfReserved2; - UINT32 bfOffBits; + sal_uInt16 bfType; + sal_uInt32 bfSize; + sal_uInt16 bfReserved1; + sal_uInt16 bfReserved2; + sal_uInt32 bfOffBits; } BITMAPFILEHEADER; typedef BITMAPFILEHEADER* PBITMAPFILEHEADER; typedef struct BITMAPINFOHEADER { - UINT32 biSize; - UINT32 biWidth; - UINT32 biHeight; - UINT16 biPlanes; - UINT16 biBitCount; - UINT32 biCompression; - UINT32 biSizeImage; - UINT32 biXPelsPerMeter; - UINT32 biYPelsPerMeter; - UINT32 biClrUsed; - UINT32 biClrImportant; + sal_uInt32 biSize; + sal_uInt32 biWidth; + sal_uInt32 biHeight; + sal_uInt16 biPlanes; + sal_uInt16 biBitCount; + sal_uInt32 biCompression; + sal_uInt32 biSizeImage; + sal_uInt32 biXPelsPerMeter; + sal_uInt32 biYPelsPerMeter; + sal_uInt32 biClrUsed; + sal_uInt32 biClrImportant; } BITMAPINFOHEADER; typedef BITMAPINFOHEADER* PBITMAPINFOHEADER; diff --git a/svtools/inc/htmltokn.h b/svtools/inc/htmltokn.h index 7c43c1463e25..5b577093ce8a 100644 --- a/svtools/inc/htmltokn.h +++ b/svtools/inc/htmltokn.h @@ -46,7 +46,7 @@ SVT_DLLPUBLIC int GetHTMLToken( const String& rName ); int GetHTMLOption( const String& rName ); // suche die 24-bit-Farbe zu einem Farbnamen (nicht gefunden = ULONG_MAX) -SVT_DLLPUBLIC ULONG GetHTMLColor( const String& rName ); +SVT_DLLPUBLIC sal_uIntPtr GetHTMLColor( const String& rName ); // beginnen immer ab 256, groesser als ein char const int HTML_TOKEN_START = 0x100; diff --git a/svtools/inc/inetimg.hxx b/svtools/inc/inetimg.hxx index 924bbad831d6..093263e82da3 100644 --- a/svtools/inc/inetimg.hxx +++ b/svtools/inc/inetimg.hxx @@ -77,8 +77,8 @@ public: const Size& GetSizePixel() const { return aSizePixel; } // Im-/Export - sal_Bool Write( SvStream& rOStm, ULONG nFormat ) const; - sal_Bool Read( SvStream& rIStm, ULONG nFormat ); + sal_Bool Write( SvStream& rOStm, sal_uIntPtr nFormat ) const; + sal_Bool Read( SvStream& rIStm, sal_uIntPtr nFormat ); }; #endif // #ifndef _INETIMG_HXX diff --git a/svtools/inc/ivctrl.hxx b/svtools/inc/ivctrl.hxx index 5bea4675b62e..bbc93a7530ff 100644 --- a/svtools/inc/ivctrl.hxx +++ b/svtools/inc/ivctrl.hxx @@ -85,7 +85,7 @@ class SvxIconChoiceCtrlEntry Rectangle aRect; // Bounding-Rect des Entries Rectangle aGridRect; // nur gesetzt im Grid-Modus - ULONG nPos; + sal_uIntPtr nPos; // die Eintragsposition in der Eintragsliste entspricht der beim Insert vorgegebenen // [Sortier-]Reihenfolge (->Reihenfolge der Anker in der Ankerliste!). Im AutoArrange-Modus @@ -95,12 +95,12 @@ class SvxIconChoiceCtrlEntry SvxIconChoiceCtrlEntry* pflink; // forward (rechter Nachbar) SvxIconChoiceCtrlTextMode eTextMode; - USHORT nX,nY; // fuer Tastatursteuerung - USHORT nFlags; + sal_uInt16 nX,nY; // fuer Tastatursteuerung + sal_uInt16 nFlags; - void ClearFlags( USHORT nMask ) { nFlags &= (~nMask); } - void SetFlags( USHORT nMask ) { nFlags |= nMask; } - void AssignFlags( USHORT _nFlags ) { nFlags = _nFlags; } + void ClearFlags( sal_uInt16 nMask ) { nFlags &= (~nMask); } + void SetFlags( sal_uInt16 nMask ) { nFlags |= nMask; } + void AssignFlags( sal_uInt16 _nFlags ) { nFlags = _nFlags; } // setzt den linken Nachbarn (A <-> B ==> A <-> this <-> B) void SetBacklink( SvxIconChoiceCtrlEntry* pA ) @@ -120,9 +120,9 @@ class SvxIconChoiceCtrlEntry } public: - SvxIconChoiceCtrlEntry( USHORT nFlags = 0 ); - SvxIconChoiceCtrlEntry( const String& rText, const Image& rImage, USHORT nFlags = 0 ); - SvxIconChoiceCtrlEntry( const String& rText, const Image& rImage, const Image& rImageHC, USHORT nFlags = 0 ); + SvxIconChoiceCtrlEntry( sal_uInt16 nFlags = 0 ); + SvxIconChoiceCtrlEntry( const String& rText, const Image& rImage, sal_uInt16 nFlags = 0 ); + SvxIconChoiceCtrlEntry( const String& rText, const Image& rImage, const Image& rImageHC, sal_uInt16 nFlags = 0 ); ~SvxIconChoiceCtrlEntry () {} void SetImage ( const Image& rImage ) { aImage = rImage; } @@ -139,21 +139,21 @@ public: const Rectangle & GetBoundRect() const { return aRect; } - void SetFocus ( BOOL bSet ) + void SetFocus ( sal_Bool bSet ) { nFlags = ( bSet ? nFlags | ICNVIEW_FLAG_FOCUSED : nFlags & ~ICNVIEW_FLAG_FOCUSED ); } SvxIconChoiceCtrlTextMode GetTextMode() const { return eTextMode; } - USHORT GetFlags() const { return nFlags; } - BOOL IsSelected() const { return (BOOL)((nFlags & ICNVIEW_FLAG_SELECTED) !=0); } - BOOL IsFocused() const { return (BOOL)((nFlags & ICNVIEW_FLAG_FOCUSED) !=0); } - BOOL IsInUse() const { return (BOOL)((nFlags & ICNVIEW_FLAG_IN_USE) !=0); } - BOOL IsCursored() const { return (BOOL)((nFlags & ICNVIEW_FLAG_CURSORED) !=0); } - BOOL IsDropTarget() const { return (BOOL)((nFlags & ICNVIEW_FLAG_DROP_TARGET) !=0); } - BOOL IsBlockingEmphasis() const { return (BOOL)((nFlags & ICNVIEW_FLAG_BLOCK_EMPHASIS) !=0); } - BOOL WasMoved() const { return (BOOL)((nFlags & ICNVIEW_FLAG_POS_MOVED) !=0); } - void SetMoved( BOOL bMoved ); - BOOL IsPosLocked() const { return (BOOL)((nFlags & ICNVIEW_FLAG_POS_LOCKED) !=0); } - void LockPos( BOOL bLock ); + sal_uInt16 GetFlags() const { return nFlags; } + sal_Bool IsSelected() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_SELECTED) !=0); } + sal_Bool IsFocused() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_FOCUSED) !=0); } + sal_Bool IsInUse() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_IN_USE) !=0); } + sal_Bool IsCursored() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_CURSORED) !=0); } + sal_Bool IsDropTarget() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_DROP_TARGET) !=0); } + sal_Bool IsBlockingEmphasis() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_BLOCK_EMPHASIS) !=0); } + sal_Bool WasMoved() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_POS_MOVED) !=0); } + void SetMoved( sal_Bool bMoved ); + sal_Bool IsPosLocked() const { return (sal_Bool)((nFlags & ICNVIEW_FLAG_POS_LOCKED) !=0); } + void LockPos( sal_Bool bLock ); // Nur bei AutoArrange gesetzt. Den Kopf der Liste gibts per SvxIconChoiceCtrl::GetPredecessorHead SvxIconChoiceCtrlEntry* GetSuccessor() const { return pflink; } SvxIconChoiceCtrlEntry* GetPredecessor() const { return pblink; } @@ -174,10 +174,10 @@ class SvxIconChoiceCtrlColumnInfo Image aColImage; long nWidth; SvxIconChoiceCtrlColumnAlign eAlignment; - USHORT nSubItem; + sal_uInt16 nSubItem; public: - SvxIconChoiceCtrlColumnInfo( USHORT nSub, long nWd, + SvxIconChoiceCtrlColumnInfo( sal_uInt16 nSub, long nWd, SvxIconChoiceCtrlColumnAlign eAlign ) : nWidth( nWd ), eAlignment( eAlign ), nSubItem( nSub ) {} SvxIconChoiceCtrlColumnInfo( const SvxIconChoiceCtrlColumnInfo& ); @@ -186,13 +186,13 @@ public: void SetImage( const Image& rImg ) { aColImage = rImg; } void SetWidth( long nWd ) { nWidth = nWd; } void SetAlignment( SvxIconChoiceCtrlColumnAlign eAlign ) { eAlignment = eAlign; } - void SetSubItem( USHORT nSub) { nSubItem = nSub; } + void SetSubItem( sal_uInt16 nSub) { nSubItem = nSub; } const String& GetText() const { return aColText; } const Image& GetImage() const { return aColImage; } long GetWidth() const { return nWidth; } SvxIconChoiceCtrlColumnAlign GetAlignment() const { return eAlignment; } - USHORT GetSubItem() const { return nSubItem; } + sal_uInt16 GetSubItem() const { return nSubItem; } }; //################################################################################################################################### @@ -241,15 +241,15 @@ class SVT_DLLPUBLIC SvtIconChoiceCtrl : public Control Link _aVisRectChangedHdl; KeyEvent* _pCurKeyEvent; SvxIconChoiceCtrl_Impl* _pImp; - BOOL _bAutoFontColor; + sal_Bool _bAutoFontColor; protected: virtual void KeyInput( const KeyEvent& rKEvt ); - virtual BOOL EditedEntry( SvxIconChoiceCtrlEntry*, const XubString& rNewText, BOOL bCancelled ); + virtual sal_Bool EditedEntry( SvxIconChoiceCtrlEntry*, const XubString& rNewText, sal_Bool bCancelled ); virtual void DocumentRectChanged(); virtual void VisibleRectChanged(); - virtual BOOL EditingEntry( SvxIconChoiceCtrlEntry* pEntry ); + virtual sal_Bool EditingEntry( SvxIconChoiceCtrlEntry* pEntry ); virtual void Command( const CommandEvent& rCEvt ); virtual void Paint( const Rectangle& rRect ); virtual void MouseButtonDown( const MouseEvent& rMEvt ); @@ -269,11 +269,11 @@ protected: virtual String GetEntryText( SvxIconChoiceCtrlEntry* pEntry, - BOOL bInplaceEdit ); + sal_Bool bInplaceEdit ); virtual void FillLayoutData() const; - void CallImplEventListeners(ULONG nEvent, void* pData); + void CallImplEventListeners(sal_uIntPtr nEvent, void* pData); public: @@ -284,9 +284,9 @@ public: void SetStyle( WinBits nWinStyle ); WinBits GetStyle() const; - BOOL SetChoiceWithCursor ( BOOL bDo = TRUE ); + sal_Bool SetChoiceWithCursor ( sal_Bool bDo = sal_True ); - void SetUpdateMode( BOOL bUpdateMode ); + void SetUpdateMode( sal_Bool bUpdateMode ); void SetFont( const Font& rFont ); void SetPointFont( const Font& rFont ); @@ -299,17 +299,17 @@ public: void ArrangeIcons(); - SvxIconChoiceCtrlEntry* InsertEntry( ULONG nPos = LIST_APPEND, + SvxIconChoiceCtrlEntry* InsertEntry( sal_uIntPtr nPos = LIST_APPEND, const Point* pPos = 0, - USHORT nFlags = 0 ); + sal_uInt16 nFlags = 0 ); SvxIconChoiceCtrlEntry* InsertEntry( const String& rText, const Image& rImage, - ULONG nPos = LIST_APPEND, + sal_uIntPtr nPos = LIST_APPEND, const Point* pPos = 0, - USHORT nFlags = 0 ); + sal_uInt16 nFlags = 0 ); SvxIconChoiceCtrlEntry* InsertEntry( const String& rText, const Image& rImage, const Image& rImageHC, - ULONG nPos = LIST_APPEND, + sal_uIntPtr nPos = LIST_APPEND, const Point* pPos = 0, - USHORT nFlags = 0 ); + sal_uInt16 nFlags = 0 ); /** creates automatic mnemonics for all icon texts in the control */ @@ -326,14 +326,14 @@ public: void RemoveEntry( SvxIconChoiceCtrlEntry* pEntry ); - BOOL DoKeyInput( const KeyEvent& rKEvt ); + sal_Bool DoKeyInput( const KeyEvent& rKEvt ); - BOOL IsEntryEditing() const; + sal_Bool IsEntryEditing() const; void Clear(); - ULONG GetEntryCount() const; - SvxIconChoiceCtrlEntry* GetEntry( ULONG nPos ) const; - ULONG GetEntryListPos( SvxIconChoiceCtrlEntry* pEntry ) const; + sal_uIntPtr GetEntryCount() const; + SvxIconChoiceCtrlEntry* GetEntry( sal_uIntPtr nPos ) const; + sal_uIntPtr GetEntryListPos( SvxIconChoiceCtrlEntry* pEntry ) const; using Window::SetCursor; void SetCursor( SvxIconChoiceCtrlEntry* pEntry ); SvxIconChoiceCtrlEntry* GetCursor() const; @@ -341,16 +341,16 @@ public: // Neu-Berechnung gecachter View-Daten und Invalidierung im Fenster void InvalidateEntry( SvxIconChoiceCtrlEntry* pEntry ); - // bHit==FALSE: Eintrag gilt als getroffen, wenn Position im BoundRect liegt - // ==TRUE : Bitmap oder Text muss getroffen sein - SvxIconChoiceCtrlEntry* GetEntry( const Point& rPosPixel, BOOL bHit = FALSE ) const; + // bHit==sal_False: Eintrag gilt als getroffen, wenn Position im BoundRect liegt + // ==sal_True : Bitmap oder Text muss getroffen sein + SvxIconChoiceCtrlEntry* GetEntry( const Point& rPosPixel, sal_Bool bHit = sal_False ) const; // Gibt den naechsten ueber pCurEntry liegenden Eintrag (ZOrder) - SvxIconChoiceCtrlEntry* GetNextEntry( const Point& rPosPixel, SvxIconChoiceCtrlEntry* pCurEntry, BOOL ) const; + SvxIconChoiceCtrlEntry* GetNextEntry( const Point& rPosPixel, SvxIconChoiceCtrlEntry* pCurEntry, sal_Bool ) const; // Gibt den naechsten unter pCurEntry liegenden Eintrag (ZOrder) - SvxIconChoiceCtrlEntry* GetPrevEntry( const Point& rPosPixel, SvxIconChoiceCtrlEntry* pCurEntry, BOOL ) const; + SvxIconChoiceCtrlEntry* GetPrevEntry( const Point& rPosPixel, SvxIconChoiceCtrlEntry* pCurEntry, sal_Bool ) const; - // in dem ULONG wird die Position in der Liste des gefunden Eintrags zurueckgegeben - SvxIconChoiceCtrlEntry* GetSelectedEntry( ULONG& rPos ) const; + // in dem sal_uIntPtr wird die Position in der Liste des gefunden Eintrags zurueckgegeben + SvxIconChoiceCtrlEntry* GetSelectedEntry( sal_uIntPtr& rPos ) const; void SetEntryTextMode( SvxIconChoiceCtrlTextMode eMode, SvxIconChoiceCtrlEntry* pEntry = 0 ); SvxIconChoiceCtrlTextMode GetEntryTextMode( const SvxIconChoiceCtrlEntry* pEntry = 0 ) const; @@ -360,19 +360,19 @@ public: void Flush(); - virtual BOOL HasBackground() const; - virtual BOOL HasFont() const; - virtual BOOL HasFontTextColor() const; - virtual BOOL HasFontFillColor() const; + virtual sal_Bool HasBackground() const; + virtual sal_Bool HasFont() const; + virtual sal_Bool HasFontTextColor() const; + virtual sal_Bool HasFontFillColor() const; - void SetFontColorToBackground ( BOOL bDo = TRUE ) { _bAutoFontColor = bDo; } - BOOL AutoFontColor () { return _bAutoFontColor; } + void SetFontColorToBackground ( sal_Bool bDo = sal_True ) { _bAutoFontColor = bDo; } + sal_Bool AutoFontColor () { return _bAutoFontColor; } Point GetLogicPos( const Point& rPosPixel ) const; Point GetPixelPos( const Point& rPosLogic ) const; void SetSelectionMode( SelectionMode eMode ); - BOOL HandleShortCutKey( const KeyEvent& rKeyEvent ); + sal_Bool HandleShortCutKey( const KeyEvent& rKeyEvent ); Rectangle GetBoundingBox( SvxIconChoiceCtrlEntry* pEntry ) const; Rectangle GetEntryCharacterBounds( const sal_Int32 _nEntryPos, const sal_Int32 _nCharacterIndex ) const; diff --git a/svtools/inc/localresaccess.hxx b/svtools/inc/localresaccess.hxx index c72f68f64f03..b00a306d0535 100644 --- a/svtools/inc/localresaccess.hxx +++ b/svtools/inc/localresaccess.hxx @@ -68,7 +68,7 @@ namespace svt FreeResource(); } - inline BOOL IsAvailableRes( const ResId& _rId ) const + inline sal_Bool IsAvailableRes( const ResId& _rId ) const { return Resource::IsAvailableRes( _rId ); } diff --git a/svtools/inc/prgsbar.hxx b/svtools/inc/prgsbar.hxx index c02d400c6931..25411b696c84 100644 --- a/svtools/inc/prgsbar.hxx +++ b/svtools/inc/prgsbar.hxx @@ -72,15 +72,15 @@ private: Point maPos; long mnPrgsWidth; long mnPrgsHeight; - USHORT mnPercent; - USHORT mnPercentCount; - BOOL mbCalcNew; + sal_uInt16 mnPercent; + sal_uInt16 mnPercentCount; + sal_Bool mbCalcNew; #ifdef _SV_PRGSBAR_CXX using Window::ImplInit; SVT_DLLPRIVATE void ImplInit(); - SVT_DLLPRIVATE void ImplInitSettings( BOOL bFont, BOOL bForeground, BOOL bBackground ); - SVT_DLLPRIVATE void ImplDrawProgress( USHORT nOldPerc, USHORT nNewPerc ); + SVT_DLLPRIVATE void ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal_Bool bBackground ); + SVT_DLLPRIVATE void ImplDrawProgress( sal_uInt16 nOldPerc, sal_uInt16 nNewPerc ); #endif public: @@ -93,8 +93,8 @@ public: virtual void StateChanged( StateChangedType nStateChange ); virtual void DataChanged( const DataChangedEvent& rDCEvt ); - void SetValue( USHORT nNewPercent ); - USHORT GetValue() const { return mnPercent; } + void SetValue( sal_uInt16 nNewPercent ); + sal_uInt16 GetValue() const { return mnPercent; } }; #endif // _PRGSBAR_HXX diff --git a/svtools/inc/rtfout.hxx b/svtools/inc/rtfout.hxx index 12a125635132..36096e1257f1 100644 --- a/svtools/inc/rtfout.hxx +++ b/svtools/inc/rtfout.hxx @@ -50,15 +50,15 @@ public: static SvStream& Out_Char( SvStream&, sal_Unicode cChar, int *pUCMode, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252, - BOOL bWriteHelpFile = FALSE ); + sal_Bool bWriteHelpFile = sal_False ); static SvStream& Out_String( SvStream&, const String&, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252, - BOOL bWriteHelpFile = FALSE ); + sal_Bool bWriteHelpFile = sal_False ); static SvStream& Out_Fontname( SvStream&, const String&, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252, - BOOL bWriteHelpFile = FALSE ); + sal_Bool bWriteHelpFile = sal_False ); - static SvStream& Out_Hex( SvStream&, ULONG nHex, BYTE nLen ); + static SvStream& Out_Hex( SvStream&, sal_uIntPtr nHex, sal_uInt8 nLen ); }; diff --git a/svtools/inc/ruler.hxx b/svtools/inc/ruler.hxx index c2649b298ba6..028d67c20877 100644 --- a/svtools/inc/ruler.hxx +++ b/svtools/inc/ruler.hxx @@ -138,7 +138,7 @@ SetMargin2() mit Parametern aufgerufen werden, kann bei diesen folgendes angegeben werden: long nPos - Offset zum NullPunkt in Pixel - USHORT nStyle - Bit-Style: + sal_uInt16 nStyle - Bit-Style: RULER_MARGIN_SIZEABLE Rand kann in der Groesse veraendert werden. @@ -154,7 +154,7 @@ initialisiert werden muessen: long nPos - Offset zum NullPunkt in Pixel long nWidth - Breite des Spaltenabstands in Pixel (kann zum Beispiel fuer Tabellenspalten auch 0 sein) - USHORT nStyle - Bit-Style: + sal_uInt16 nStyle - Bit-Style: RULER_BORDER_SIZEABLE Spaltenabstand kann in der Groesse veraendert werden. Dieses Flag sollte nur gesetzt werden, @@ -190,7 +190,7 @@ Parameter muss ein Array vom Typ RulerIndent uebergeben werden, wobei folgende Werte initialisiert werden muessen: long nPos - Offset zum NullPunkt in Pixel - USHORT nStyle - Bit-Style: + sal_uInt16 nStyle - Bit-Style: RULER_INDENT_TOP (Erstzeileneinzug) RULER_INDENT_BOTTOM (Linker/Rechter Einzug) RULER_INDENT_BORDER (Verical line that shows the border distance) @@ -206,7 +206,7 @@ Parameter muss ein Array vom Typ RulerTab uebergeben werden, wobei folgende Werte initialisiert werden muessen: long nPos - Offset zum NullPunkt in Pixel - USHORT nStyle - Bit-Style: + sal_uInt16 nStyle - Bit-Style: RULER_TAB_DEFAULT (kann nicht selektiert werden) RULER_TAB_LEFT RULER_TAB_CENTER @@ -223,7 +223,7 @@ muss ein Array vom Typ RulerLine uebergeben werden, wobei folgende Werte initialisiert werden muessen: long nPos - Offset zum NullPunkt in Pixel - USHORT nStyle - Bit-Style (muss zur Zeit immer 0 sein) + sal_uInt16 nStyle - Bit-Style (muss zur Zeit immer 0 sein) Mit SetArrows() koennen Bemassungspfeile im Lineal angezeigt werden. Wenn Bemassungspfeile gesetzt werden, werden im Lineal auch keine Unterteilungen @@ -234,7 +234,7 @@ uebergeben werden, wobei folgende Werte initialisiert werden muessen: long nPos - Offset zum NullPunkt in Pixel long nWidth - Breite des Pfeils long nLogWidth - Breite des Pfeils in logischer Einheit - USHORT nStyle - Bit-Style (muss zur Zeit immer 0 sein) + sal_uInt16 nStyle - Bit-Style (muss zur Zeit immer 0 sein) Mit SetSourceUnit() wird die Einheit eingestellt, in welcher die logischen Werte vorliegen, die bei SetArrows() uebergeben werden. Dabei werden nur die @@ -246,7 +246,7 @@ Wenn auch vom Benutzer die Raender, Tabs, Border, ... ueber das Lineal geaendert werden koennen, muss etwas mehr Aufwand getrieben werden. Dazu muessen die Methoden StartDrag(), Drag() und EndDrag() ueberlagert werden. Bei der Methode StartDrag() besteht die Moeglichkeit durch das zurueckgeben -von FALSE das Draggen zu verhindern. Im Drag-Handler muss die Drag-Position +von sal_False das Draggen zu verhindern. Im Drag-Handler muss die Drag-Position abgefragt werden und die Werte muessen an die neue Position verschoben werden. Dazu ruft man einfach die einzelnen Set-Methoden auf. Solange man sich im Drag-Handler befindet, werden sich die Werte nur gemerkt und erst @@ -254,10 +254,10 @@ danach das Lineal neu ausgegeben. Alle Handler koennen auch als Links ueber entsprechende Set..Hdl()-Methoden gesetzt werden. - StartDrag() - Wird gerufen, wenn das Draggen gestartet wird. Wenn FALSE - zurueckgegeben wird, wird das Draggen nicht ausgefuehrt. Bei TRUE + Wird gerufen, wenn das Draggen gestartet wird. Wenn sal_False + zurueckgegeben wird, wird das Draggen nicht ausgefuehrt. Bei sal_True wird das Draggen zugelassen. Wenn der Handler nicht ueberlagert - wird, wird FALSE zurueckgegeben. + wird, wird sal_False zurueckgegeben. - EndDrag() Wird gerufen, wenn das Draggen beendet wird. @@ -325,7 +325,7 @@ es folgende Abfrage-Methoden. gezogen, werden automatisch die alten Werte dargestellt, ohne das der Drag-Handler gerufen wird. Falls der Benutzer jedoch den Wert auf die alte Position - zurueckgeschoben hat, liefert die Methode trotzdem FALSE. Falls + zurueckgeschoben hat, liefert die Methode trotzdem sal_False. Falls dies vermieden werden soll, muss sich die Applikation im StartDrag- Handler den alten Wert merken und im EndDrag-Handler den Wert vergleichen. @@ -372,7 +372,7 @@ es folgende Abfrage-Methoden. gegebenenfalls ueber das Abfangen des MouseButtonDown-Handlers auch ueber die rechte Maustaste etwas auf ein Item anzuwenden. Als Paramter ueber gibt man die Fensterposition und gegebenenfalls - einen Pointer auf einen USHORT, um die Array-Position eines + einen Pointer auf einen sal_uInt16, um die Array-Position eines Tabs, Indent oder Borders mitzubekommen. Als Type werden folgende Werte zurueckgegeben: RULER_TYPE_DONTKNOW (kein Element im Linealbereich) @@ -388,7 +388,7 @@ mit CancelDrag() abgebrochen werden. Folgende Methoden gibt es fuer die Drag-Steuerung: - IsDrag() - Liefert TRUE zurueck, wenn sich das Lineal im Drag-Vorgang befindet. + Liefert sal_True zurueck, wenn sich das Lineal im Drag-Vorgang befindet. - CancelDrag() Bricht den Drag-Vorgang ab, falls einer durchgefuehrt wird. Dabei @@ -443,7 +443,7 @@ womit man bestimmte Aktionen abfangen kann. RULER_EXTRA_DONTKNOW (Nichts) RULER_EXTRA_NULLOFFSET (Koordinaaten-Kreuz) RULER_EXTRA_TAB (Tab) - - USHORT nStyle Bitfeld als Style: + - sal_uInt16 nStyle Bitfeld als Style: RULER_STYLE_HIGHLIGHT (selektiert) RULER_TAB_... (ein Tab-Style) @@ -553,9 +553,9 @@ enum RulerType { RULER_TYPE_DONTKNOW, RULER_TYPE_OUTSIDE, enum RulerExtra { RULER_EXTRA_DONTKNOW, RULER_EXTRA_NULLOFFSET, RULER_EXTRA_TAB }; -#define RULER_STYLE_HIGHLIGHT ((USHORT)0x8000) -#define RULER_STYLE_DONTKNOW ((USHORT)0x4000) -#define RULER_STYLE_INVISIBLE ((USHORT)0x2000) +#define RULER_STYLE_HIGHLIGHT ((sal_uInt16)0x8000) +#define RULER_STYLE_DONTKNOW ((sal_uInt16)0x4000) +#define RULER_STYLE_INVISIBLE ((sal_uInt16)0x2000) #define RULER_DRAGSIZE_MOVE 0 #define RULER_DRAGSIZE_1 1 @@ -574,24 +574,24 @@ enum RulerExtra { RULER_EXTRA_DONTKNOW, // - RulerMargin - // --------------- -#define RULER_MARGIN_SIZEABLE ((USHORT)0x0001) +#define RULER_MARGIN_SIZEABLE ((sal_uInt16)0x0001) // --------------- // - RulerBorder - // --------------- -#define RULER_BORDER_SIZEABLE ((USHORT)0x0001) -#define RULER_BORDER_MOVEABLE ((USHORT)0x0002) -#define RULER_BORDER_VARIABLE ((USHORT)0x0004) -#define RULER_BORDER_TABLE ((USHORT)0x0008) -#define RULER_BORDER_SNAP ((USHORT)0x0010) -#define RULER_BORDER_MARGIN ((USHORT)0x0020) +#define RULER_BORDER_SIZEABLE ((sal_uInt16)0x0001) +#define RULER_BORDER_MOVEABLE ((sal_uInt16)0x0002) +#define RULER_BORDER_VARIABLE ((sal_uInt16)0x0004) +#define RULER_BORDER_TABLE ((sal_uInt16)0x0008) +#define RULER_BORDER_SNAP ((sal_uInt16)0x0010) +#define RULER_BORDER_MARGIN ((sal_uInt16)0x0020) struct RulerBorder { long nPos; long nWidth; - USHORT nStyle; + sal_uInt16 nStyle; //minimum/maximum position, supported for table borders/rows long nMinPos; long nMaxPos; @@ -601,33 +601,33 @@ struct RulerBorder // - RulerIndent - // --------------- -#define RULER_INDENT_TOP ((USHORT)0x0000) -#define RULER_INDENT_BOTTOM ((USHORT)0x0001) -#define RULER_INDENT_BORDER ((USHORT)0x0002) -#define RULER_INDENT_STYLE ((USHORT)0x000F) +#define RULER_INDENT_TOP ((sal_uInt16)0x0000) +#define RULER_INDENT_BOTTOM ((sal_uInt16)0x0001) +#define RULER_INDENT_BORDER ((sal_uInt16)0x0002) +#define RULER_INDENT_STYLE ((sal_uInt16)0x000F) struct RulerIndent { long nPos; - USHORT nStyle; + sal_uInt16 nStyle; }; // ------------ // - RulerTab - // ------------ -#define RULER_TAB_LEFT ((USHORT)0x0000) -#define RULER_TAB_RIGHT ((USHORT)0x0001) -#define RULER_TAB_DECIMAL ((USHORT)0x0002) -#define RULER_TAB_CENTER ((USHORT)0x0003) -#define RULER_TAB_DEFAULT ((USHORT)0x0004) -#define RULER_TAB_STYLE ((USHORT)0x000F) -#define RULER_TAB_RTL ((USHORT)0x0010) +#define RULER_TAB_LEFT ((sal_uInt16)0x0000) +#define RULER_TAB_RIGHT ((sal_uInt16)0x0001) +#define RULER_TAB_DECIMAL ((sal_uInt16)0x0002) +#define RULER_TAB_CENTER ((sal_uInt16)0x0003) +#define RULER_TAB_DEFAULT ((sal_uInt16)0x0004) +#define RULER_TAB_STYLE ((sal_uInt16)0x000F) +#define RULER_TAB_RTL ((sal_uInt16)0x0010) struct RulerTab { long nPos; - USHORT nStyle; + sal_uInt16 nStyle; }; #define RULER_TAB_WIDTH 7 @@ -640,7 +640,7 @@ struct RulerTab struct RulerLine { long nPos; - USHORT nStyle; + sal_uInt16 nStyle; }; // -------------- @@ -652,7 +652,7 @@ struct RulerArrow long nPos; long nWidth; long nLogWidth; - USHORT nStyle; + sal_uInt16 nStyle; }; class ImplRulerData; @@ -676,33 +676,33 @@ private: long mnBorderWidth; long mnStartDragPos; long mnDragPos; - ULONG mnUpdateEvtId; + sal_uIntPtr mnUpdateEvtId; ImplRulerData* mpSaveData; ImplRulerData* mpData; ImplRulerData* mpDragData; Rectangle maExtraRect; WinBits mnWinStyle; - USHORT mnUnitIndex; - USHORT mnDragAryPos; - USHORT mnDragSize; - USHORT mnDragScroll; - USHORT mnDragModifier; - USHORT mnExtraStyle; - USHORT mnExtraClicks; - USHORT mnExtraModifier; + sal_uInt16 mnUnitIndex; + sal_uInt16 mnDragAryPos; + sal_uInt16 mnDragSize; + sal_uInt16 mnDragScroll; + sal_uInt16 mnDragModifier; + sal_uInt16 mnExtraStyle; + sal_uInt16 mnExtraClicks; + sal_uInt16 mnExtraModifier; RulerExtra meExtraType; RulerType meDragType; MapUnit meSourceUnit; FieldUnit meUnit; Fraction maZoom; - BOOL mbCalc; - BOOL mbFormat; - BOOL mbDrag; - BOOL mbDragDelete; - BOOL mbDragCanceled; - BOOL mbAutoWinWidth; - BOOL mbActive; - BYTE mnUpdateFlags; + sal_Bool mbCalc; + sal_Bool mbFormat; + sal_Bool mbDrag; + sal_Bool mbDragDelete; + sal_Bool mbDragCanceled; + sal_Bool mbAutoWinWidth; + sal_Bool mbActive; + sal_uInt8 mnUpdateFlags; Link maStartDragHdl; Link maDragHdl; Link maEndDragHdl; @@ -718,27 +718,27 @@ private: SVT_DLLPRIVATE void ImplDrawTicks( long nMin, long nMax, long nStart, long nCenter ); SVT_DLLPRIVATE void ImplDrawArrows( long nCenter ); SVT_DLLPRIVATE void ImplDrawBorders( long nMin, long nMax, long nVirTop, long nVirBottom ); - SVT_DLLPRIVATE void ImplDrawIndent( const Polygon& rPoly, USHORT nStyle ); + SVT_DLLPRIVATE void ImplDrawIndent( const Polygon& rPoly, sal_uInt16 nStyle ); SVT_DLLPRIVATE void ImplDrawIndents( long nMin, long nMax, long nVirTop, long nVirBottom ); - SVT_DLLPRIVATE void ImplDrawTab( OutputDevice* pDevice, const Point& rPos, USHORT nStyle ); + SVT_DLLPRIVATE void ImplDrawTab( OutputDevice* pDevice, const Point& rPos, sal_uInt16 nStyle ); SVT_DLLPRIVATE void ImplDrawTabs( long nMin, long nMax, long nVirTop, long nVirBottom ); using Window::ImplInit; SVT_DLLPRIVATE void ImplInit( WinBits nWinBits ); - SVT_DLLPRIVATE void ImplInitSettings( BOOL bFont, BOOL bForeground, BOOL bBackground ); + SVT_DLLPRIVATE void ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal_Bool bBackground ); SVT_DLLPRIVATE void ImplCalc(); SVT_DLLPRIVATE void ImplFormat(); - SVT_DLLPRIVATE void ImplInitExtraField( BOOL bUpdate ); - SVT_DLLPRIVATE void ImplInvertLines( BOOL bErase = FALSE ); + SVT_DLLPRIVATE void ImplInitExtraField( sal_Bool bUpdate ); + SVT_DLLPRIVATE void ImplInvertLines( sal_Bool bErase = sal_False ); SVT_DLLPRIVATE void ImplDraw(); - SVT_DLLPRIVATE void ImplDrawExtra( BOOL bPaint = FALSE ); - SVT_DLLPRIVATE void ImplUpdate( BOOL bMustCalc = FALSE ); + SVT_DLLPRIVATE void ImplDrawExtra( sal_Bool bPaint = sal_False ); + SVT_DLLPRIVATE void ImplUpdate( sal_Bool bMustCalc = sal_False ); using Window::ImplHitTest; - SVT_DLLPRIVATE BOOL ImplHitTest( const Point& rPos, + SVT_DLLPRIVATE sal_Bool ImplHitTest( const Point& rPos, ImplRulerHitTest* pHitTest, - BOOL bRequiredStyle = FALSE, - USHORT nRequiredStyle = 0 ) const; - SVT_DLLPRIVATE BOOL ImplDocHitTest( const Point& rPos, RulerType eDragType, ImplRulerHitTest* pHitTest ) const; - SVT_DLLPRIVATE BOOL ImplStartDrag( ImplRulerHitTest* pHitTest, USHORT nModifier ); + sal_Bool bRequiredStyle = sal_False, + sal_uInt16 nRequiredStyle = 0 ) const; + SVT_DLLPRIVATE sal_Bool ImplDocHitTest( const Point& rPos, RulerType eDragType, ImplRulerHitTest* pHitTest ) const; + SVT_DLLPRIVATE sal_Bool ImplStartDrag( ImplRulerHitTest* pHitTest, sal_uInt16 nModifier ); SVT_DLLPRIVATE void ImplDrag( const Point& rPos ); SVT_DLLPRIVATE void ImplEndDrag(); DECL_DLLPRIVATE_LINK( ImplUpdateHdl, void* ); @@ -769,7 +769,7 @@ public: void Activate(); void Deactivate(); - BOOL IsActive() const { return mbActive; } + sal_Bool IsActive() const { return mbActive; } void SetWinPos( long nOff = 0, long nWidth = 0 ); long GetWinOffset() const { return mnWinOff; } @@ -789,67 +789,67 @@ public: void SetSourceUnit( MapUnit eNewUnit ) { meSourceUnit = eNewUnit; } MapUnit GetSourceUnit() const { return meSourceUnit; } - void SetExtraType( RulerExtra eNewExtraType, USHORT nStyle = 0 ); + void SetExtraType( RulerExtra eNewExtraType, sal_uInt16 nStyle = 0 ); RulerExtra GetExtraType() const { return meExtraType; } - USHORT GetExtraStyle() const { return mnExtraStyle; } - USHORT GetExtraClicks() const { return mnExtraClicks; } - USHORT GetExtraModifier() const { return mnExtraModifier; } + sal_uInt16 GetExtraStyle() const { return mnExtraStyle; } + sal_uInt16 GetExtraClicks() const { return mnExtraClicks; } + sal_uInt16 GetExtraModifier() const { return mnExtraModifier; } - BOOL StartDocDrag( const MouseEvent& rMEvt, + sal_Bool StartDocDrag( const MouseEvent& rMEvt, RulerType eDragType = RULER_TYPE_DONTKNOW ); RulerType GetDocType( const Point& rPos, RulerType eDragType = RULER_TYPE_DONTKNOW, - USHORT* pAryPos = NULL ) const; + sal_uInt16* pAryPos = NULL ) const; RulerType GetDragType() const { return meDragType; } long GetDragPos() const { return mnDragPos; } - USHORT GetDragAryPos() const { return mnDragAryPos; } - USHORT GetDragSize() const { return mnDragSize; } - BOOL IsDragDelete() const { return mbDragDelete; } - BOOL IsDragCanceled() const { return mbDragCanceled; } - USHORT GetDragScroll() const { return mnDragScroll; } - USHORT GetDragModifier() const { return mnDragModifier; } - BOOL IsDrag() const { return mbDrag; } + sal_uInt16 GetDragAryPos() const { return mnDragAryPos; } + sal_uInt16 GetDragSize() const { return mnDragSize; } + sal_Bool IsDragDelete() const { return mbDragDelete; } + sal_Bool IsDragCanceled() const { return mbDragCanceled; } + sal_uInt16 GetDragScroll() const { return mnDragScroll; } + sal_uInt16 GetDragModifier() const { return mnDragModifier; } + sal_Bool IsDrag() const { return mbDrag; } void CancelDrag(); long GetClickPos() const { return mnDragPos; } RulerType GetClickType() const { return meDragType; } - USHORT GetClickAryPos() const { return mnDragAryPos; } + sal_uInt16 GetClickAryPos() const { return mnDragAryPos; } using Window::GetType; RulerType GetType( const Point& rPos, - USHORT* pAryPos = NULL ) const; + sal_uInt16* pAryPos = NULL ) const; void SetNullOffset( long nPos ); long GetNullOffset() const; void SetMargin1() { SetMargin1( 0, RULER_STYLE_INVISIBLE ); } - void SetMargin1( long nPos, USHORT nMarginStyle = RULER_MARGIN_SIZEABLE ); + void SetMargin1( long nPos, sal_uInt16 nMarginStyle = RULER_MARGIN_SIZEABLE ); long GetMargin1() const; - USHORT GetMargin1Style() const; + sal_uInt16 GetMargin1Style() const; void SetMargin2() { SetMargin2( 0, RULER_STYLE_INVISIBLE ); } - void SetMargin2( long nPos, USHORT nMarginStyle = RULER_MARGIN_SIZEABLE ); + void SetMargin2( long nPos, sal_uInt16 nMarginStyle = RULER_MARGIN_SIZEABLE ); long GetMargin2() const; - USHORT GetMargin2Style() const; + sal_uInt16 GetMargin2Style() const; - void SetLines( USHORT n = 0, const RulerLine* pLineAry = NULL ); - USHORT GetLineCount() const; + void SetLines( sal_uInt16 n = 0, const RulerLine* pLineAry = NULL ); + sal_uInt16 GetLineCount() const; const RulerLine* GetLines() const; - void SetArrows( USHORT n = 0, const RulerArrow* pArrowAry = NULL ); - USHORT GetArrowCount() const; + void SetArrows( sal_uInt16 n = 0, const RulerArrow* pArrowAry = NULL ); + sal_uInt16 GetArrowCount() const; const RulerArrow* GetArrows() const; - void SetBorders( USHORT n = 0, const RulerBorder* pBrdAry = NULL ); - USHORT GetBorderCount() const; + void SetBorders( sal_uInt16 n = 0, const RulerBorder* pBrdAry = NULL ); + sal_uInt16 GetBorderCount() const; const RulerBorder* GetBorders() const; - void SetIndents( USHORT n = 0, const RulerIndent* pIndentAry = NULL ); - USHORT GetIndentCount() const; + void SetIndents( sal_uInt16 n = 0, const RulerIndent* pIndentAry = NULL ); + sal_uInt16 GetIndentCount() const; const RulerIndent* GetIndents() const; - void SetTabs( USHORT n = 0, const RulerTab* pTabAry = NULL ); - USHORT GetTabCount() const; + void SetTabs( sal_uInt16 n = 0, const RulerTab* pTabAry = NULL ); + sal_uInt16 GetTabCount() const; const RulerTab* GetTabs() const; static void DrawTab( OutputDevice* pDevice, - const Point& rPos, USHORT nStyle ); + const Point& rPos, sal_uInt16 nStyle ); void SetStyle( WinBits nStyle ); WinBits GetStyle() const { return mnWinStyle; } @@ -868,7 +868,7 @@ public: const Link& GetExtraDownHdl() const { return maExtraDownHdl; } //set text direction right-to-left - void SetTextRTL(BOOL bRTL); + void SetTextRTL(sal_Bool bRTL); }; #endif // _RULER_HXX diff --git a/svtools/inc/scrwin.hxx b/svtools/inc/scrwin.hxx index 1542ed667133..c3e3729b2734 100644 --- a/svtools/inc/scrwin.hxx +++ b/svtools/inc/scrwin.hxx @@ -40,7 +40,7 @@ class DataChangedEvent; // - ScrollableWindow-Type - // ------------------------- -typedef USHORT ScrollableWindowFlags; +typedef sal_uInt16 ScrollableWindowFlags; #define SCRWIN_THUMBDRAGGING 1 #define SCRWIN_VCENTER 2 @@ -62,7 +62,7 @@ private: ScrollBar aVScroll; // the scrollbars ScrollBar aHScroll; ScrollBarBox aCornerWin; // window in the bottom right corner - BOOL bScrolling:1, // user controlled scrolling + sal_Bool bScrolling:1, // user controlled scrolling bHandleDragging:1, // scroll window while dragging bHCenter:1, bVCenter:1; @@ -94,15 +94,15 @@ public: Size GetTotalSize() { return PixelToLogic( aTotPixSz ); } void SetVisibleSize( const Size& rNewSize ); - BOOL MakeVisible( const Rectangle& rTarget, BOOL bSloppy = FALSE ); + sal_Bool MakeVisible( const Rectangle& rTarget, sal_Bool bSloppy = sal_False ); Rectangle GetVisibleArea() const; - void SetLineSize( ULONG nHorz, ULONG nVert ); + void SetLineSize( sal_uIntPtr nHorz, sal_uIntPtr nVert ); using Window::Scroll; - virtual void Scroll( long nDeltaX, long nDeltaY, USHORT nFlags = 0 ); + virtual void Scroll( long nDeltaX, long nDeltaY, sal_uInt16 nFlags = 0 ); void ScrollLines( long nLinesX, long nLinesY ); - void ScrollPages( long nPagesX, ULONG nOverlapX, - long nPagesY, ULONG nOverlapY ); + void ScrollPages( long nPagesX, sal_uIntPtr nOverlapX, + long nPagesY, sal_uIntPtr nOverlapY ); private: SVT_DLLPRIVATE Size GetOutputSizePixel() const; diff --git a/svtools/inc/stdmenu.hxx b/svtools/inc/stdmenu.hxx index 1b7e9816a103..34626dbd7721 100644 --- a/svtools/inc/stdmenu.hxx +++ b/svtools/inc/stdmenu.hxx @@ -189,7 +189,7 @@ private: Link maSelectHdl; Link maHighlightHdl; - SVT_DLLPRIVATE BOOL ImplIsAlreadyInserted( const XubString& rStyleName, USHORT nCount ); + SVT_DLLPRIVATE sal_Bool ImplIsAlreadyInserted( const XubString& rStyleName, sal_uInt16 nCount ); public: FontStyleMenu(); diff --git a/svtools/inc/svtools/accessibletable.hxx b/svtools/inc/svtools/accessibletable.hxx index 198a24b8eb62..8d363f180777 100755 --- a/svtools/inc/svtools/accessibletable.hxx +++ b/svtools/inc/svtools/accessibletable.hxx @@ -101,7 +101,7 @@ public: // Window virtual Rectangle GetWindowExtentsRelative( Window *pRelativeWindow ) const = 0; virtual void GrabFocus()= 0; - virtual XACC GetAccessible( BOOL bCreate = TRUE )= 0; + virtual XACC GetAccessible( sal_Bool bCreate = sal_True )= 0; virtual Window* GetAccessibleParentWindow() const= 0; virtual Window* GetWindowInstance()= 0; virtual sal_Int32 GetAccessibleControlCount() const = 0; @@ -112,8 +112,8 @@ public: virtual sal_Int32 GetSelectedRowCount() const= 0; virtual bool IsRowSelected( long _nRow ) const= 0; virtual sal_Bool ConvertPointToCellAddress( sal_Int32& _rnRow, sal_Int32& _rnColPos, const Point& _rPoint )= 0; - virtual Rectangle calcHeaderRect( sal_Bool _bIsColumnBar, BOOL _bOnScreen = TRUE ) = 0; - virtual Rectangle calcTableRect( BOOL _bOnScreen = TRUE ) = 0; + virtual Rectangle calcHeaderRect( sal_Bool _bIsColumnBar, sal_Bool _bOnScreen = sal_True ) = 0; + virtual Rectangle calcTableRect( sal_Bool _bOnScreen = sal_True ) = 0; virtual Rectangle GetFieldCharacterBounds(sal_Int32 _nRow,sal_Int32 _nColumnPos,sal_Int32 nIndex)= 0; virtual sal_Int32 GetFieldIndexAtPoint(sal_Int32 _nRow,sal_Int32 _nColumnPos,const Point& _rPoint)= 0; virtual void FillAccessibleStateSetForCell( ::utl::AccessibleStateSetHelper& _rStateSet, sal_Int32 _nRow, sal_uInt16 _nColumnPos ) const= 0; @@ -149,7 +149,7 @@ public: virtual void dispose() = 0; /** checks whether the accessible implementation, and its context, are still alive - @return , if the object is not disposed or disposing. + @return , if the object is not disposed or disposing. */ virtual sal_Bool isAlive() const = 0; diff --git a/svtools/inc/svtools/accessibletableprovider.hxx b/svtools/inc/svtools/accessibletableprovider.hxx index d14aecce9f58..484a6efb69c9 100644 --- a/svtools/inc/svtools/accessibletableprovider.hxx +++ b/svtools/inc/svtools/accessibletableprovider.hxx @@ -83,31 +83,31 @@ public: @param _nColumn The column which description is in demand. */ virtual ::rtl::OUString GetColumnDescription( sal_uInt16 _nColumnPos ) const = 0; - /** @return , if the object has a row header. */ + /** @return , if the object has a row header. */ virtual sal_Bool HasRowHeader() const = 0; //GetColumnId - /** @return , if the object can focus a cell. */ + /** @return , if the object can focus a cell. */ virtual sal_Bool IsCellFocusable() const = 0; virtual sal_Bool GoToCell( sal_Int32 _nRow, sal_uInt16 _nColumnPos ) = 0; virtual void SetNoSelection() = 0; virtual void SelectAll() = 0; - virtual void SelectRow( long _nRow, BOOL _bSelect = TRUE, BOOL bExpand = TRUE ) = 0; + virtual void SelectRow( long _nRow, sal_Bool _bSelect = sal_True, sal_Bool bExpand = sal_True ) = 0; virtual void SelectColumn( sal_uInt16 _nColumnPos, sal_Bool _bSelect = sal_True ) = 0; virtual sal_Int32 GetSelectedRowCount() const = 0; virtual sal_Int32 GetSelectedColumnCount() const = 0; - /** @return , if the row is selected. */ + /** @return , if the row is selected. */ virtual bool IsRowSelected( long _nRow ) const = 0; virtual sal_Bool IsColumnSelected( long _nColumnPos ) const = 0; virtual void GetAllSelectedRows( ::com::sun::star::uno::Sequence< sal_Int32 >& _rRows ) const = 0; virtual void GetAllSelectedColumns( ::com::sun::star::uno::Sequence< sal_Int32 >& _rColumns ) const = 0; - /** @return , if the cell is visible. */ + /** @return , if the cell is visible. */ virtual sal_Bool IsCellVisible( sal_Int32 _nRow, sal_uInt16 _nColumnPos ) const = 0; - virtual String GetAccessibleCellText( long _nRow, USHORT _nColumnPos ) const = 0; + virtual String GetAccessibleCellText( long _nRow, sal_uInt16 _nColumnPos ) const = 0; - virtual Rectangle calcHeaderRect( sal_Bool _bIsColumnBar, BOOL _bOnScreen = TRUE ) = 0; - virtual Rectangle calcTableRect( BOOL _bOnScreen = TRUE ) = 0; - virtual Rectangle GetFieldRectPixelAbs( sal_Int32 _nRow, sal_uInt16 _nColumnPos, BOOL _bIsHeader, BOOL _bOnScreen = TRUE ) = 0; + virtual Rectangle calcHeaderRect( sal_Bool _bIsColumnBar, sal_Bool _bOnScreen = sal_True ) = 0; + virtual Rectangle calcTableRect( sal_Bool _bOnScreen = sal_True ) = 0; + virtual Rectangle GetFieldRectPixelAbs( sal_Int32 _nRow, sal_uInt16 _nColumnPos, sal_Bool _bIsHeader, sal_Bool _bOnScreen = sal_True ) = 0; virtual XACC CreateAccessibleCell( sal_Int32 _nRow, sal_uInt16 _nColumnPos ) = 0; virtual XACC CreateAccessibleRowHeader( sal_Int32 _nRow ) = 0; @@ -129,12 +129,12 @@ public: virtual void GrabTableFocus() = 0; // OutputDevice - virtual BOOL GetGlyphBoundRects( const Point& rOrigin, const String& rStr, int nIndex, int nLen, int nBase, MetricVector& rVector ) = 0; + virtual sal_Bool GetGlyphBoundRects( const Point& rOrigin, const String& rStr, int nIndex, int nLen, int nBase, MetricVector& rVector ) = 0; // Window virtual Rectangle GetWindowExtentsRelative( Window *pRelativeWindow ) const = 0; virtual void GrabFocus() = 0; - virtual XACC GetAccessible( BOOL bCreate = TRUE ) = 0; + virtual XACC GetAccessible( sal_Bool bCreate = sal_True ) = 0; virtual Window* GetAccessibleParentWindow() const = 0; virtual Window* GetWindowInstance() = 0; @@ -189,7 +189,7 @@ public: virtual void dispose() = 0; /** checks whether the accessible implementation, and its context, are still alive - @return , if the object is not disposed or disposing. + @return , if the object is not disposed or disposing. */ virtual sal_Bool isAlive() const = 0; diff --git a/svtools/inc/svtools/brwbox.hxx b/svtools/inc/svtools/brwbox.hxx index 42fb4b4d36ac..699890d02e5b 100644 --- a/svtools/inc/svtools/brwbox.hxx +++ b/svtools/inc/svtools/brwbox.hxx @@ -67,7 +67,7 @@ namespace utl { #define BROWSER_INVALIDID USHRT_MAX #define BROWSER_ENDOFSELECTION (long)(SFX_ENDOFSELECTION) -typedef ULONG BrowserMode; +typedef sal_uIntPtr BrowserMode; #define BROWSER_COLUMNSELECTION 0x0001 #define BROWSER_MULTISELECTION 0x0002 @@ -153,20 +153,20 @@ class BrowseEvent Window* pWin; long nRow; Rectangle aRect; - USHORT nCol; - USHORT nColId; + sal_uInt16 nCol; + sal_uInt16 nColId; public: BrowseEvent(); BrowseEvent( Window* pWindow, long nAbsRow, - USHORT nColumn, USHORT nColumnId, + sal_uInt16 nColumn, sal_uInt16 nColumnId, const Rectangle& rRect ); Window* GetWindow() const { return pWin; } long GetRow() const { return nRow; } - USHORT GetColumn() const { return nCol; } - USHORT GetColumnId() const { return nColId; } + sal_uInt16 GetColumn() const { return nCol; } + sal_uInt16 GetColumnId() const { return nColId; } const Rectangle& GetRect() const { return aRect; } }; @@ -180,7 +180,7 @@ public: BrowserMouseEvent(); BrowserMouseEvent( BrowserDataWin* pWin, const MouseEvent& rEvt ); BrowserMouseEvent( Window* pWin, const MouseEvent& rEvt, - long nAbsRow, USHORT nColumn, USHORT nColumnId, + long nAbsRow, sal_uInt16 nColumn, sal_uInt16 nColumnId, const Rectangle& rRect ); }; @@ -253,45 +253,45 @@ class SVT_DLLPUBLIC BrowseBox ScrollBar aHScroll; // horizontal scrollbar long nDataRowHeight; // height of a single data-row - USHORT nTitleLines; // number of lines in title row - ULONG nControlAreaWidth; // width of fixed area beneeth hscroll - BOOL bThumbDragging; // handle thumb dragging - BOOL bColumnCursor; // single columns and fields selectable - BOOL bMultiSelection;// allow multiple selected rows - BOOL bKeepHighlight; // don't hide selection on LoseFocus - - BOOL bHLines; // draw lines between rows - BOOL bVLines; // draw lines between columns - BOOL bHDots; // draw lines between rows dotted - BOOL bVDots; // draw lines between columns dotted + sal_uInt16 nTitleLines; // number of lines in title row + sal_uIntPtr nControlAreaWidth; // width of fixed area beneeth hscroll + sal_Bool bThumbDragging; // handle thumb dragging + sal_Bool bColumnCursor; // single columns and fields selectable + sal_Bool bMultiSelection;// allow multiple selected rows + sal_Bool bKeepHighlight; // don't hide selection on LoseFocus + + sal_Bool bHLines; // draw lines between rows + sal_Bool bVLines; // draw lines between columns + sal_Bool bHDots; // draw lines between rows dotted + sal_Bool bVDots; // draw lines between columns dotted Color aGridLineColor; // color for lines, default dark grey - BOOL bBootstrapped; // child windows resized etc. + sal_Bool bBootstrapped; // child windows resized etc. long nTopRow; // no. of first visible row (0...) long nCurRow; // no. of row with cursor long nRowCount; // total number of rows in model - USHORT nFirstCol; // no. of first visible scrollable column - USHORT nCurColId; // column id of cursor + sal_uInt16 nFirstCol; // no. of first visible scrollable column + sal_uInt16 nCurColId; // column id of cursor - BOOL bSelecting; - BOOL bRowDividerDrag; - BOOL bHit; - BOOL mbInteractiveRowHeight; + sal_Bool bSelecting; + sal_Bool bRowDividerDrag; + sal_Bool bHit; + sal_Bool mbInteractiveRowHeight; Point a1stPoint; Point a2ndPoint; long nResizeX; // mouse position at start of resizing long nMinResizeX; // never drag more left long nDragX; // last dragged column (MouseMove) - USHORT nResizeCol; // resize this column in MouseMove - BOOL bResizing; // mouse captured for column resizing - - BOOL bSelect; // select or deselect - BOOL bSelectionIsVisible; // depending on focus - BOOL bScrolling; // hidden cursor while scrolling - BOOL bNotToggleSel; // set while in ToggleSelection() etc. - BOOL bHasFocus; // set/unset in Get/LoseFocus - BOOL bHideSelect; // hide selection (highlight) - BOOL bHideCursor; // hide cursor (frame) + sal_uInt16 nResizeCol; // resize this column in MouseMove + sal_Bool bResizing; // mouse captured for column resizing + + sal_Bool bSelect; // select or deselect + sal_Bool bSelectionIsVisible; // depending on focus + sal_Bool bScrolling; // hidden cursor while scrolling + sal_Bool bNotToggleSel; // set while in ToggleSelection() etc. + sal_Bool bHasFocus; // set/unset in Get/LoseFocus + sal_Bool bHideSelect; // hide selection (highlight) + sal_Bool bHideCursor; // hide cursor (frame) Range aSelRange; // for selection expansion BrowserColumns* pCols; // array of column-descriptions @@ -304,7 +304,7 @@ class SVT_DLLPUBLIC BrowseBox ::std::auto_ptr< ::svt::BrowseBoxImpl > m_pImpl; // impl structure of the BrowseBox object - BOOL m_bFocusOnlyCursor; // hide cursor if we don't have the focus + sal_Bool m_bFocusOnlyCursor; // hide cursor if we don't have the focus Color m_aCursorColor; // special color for cursor, COL_TRANSPARENT for usual (VCL-painted) "inverted" cursor BrowserMode m_nCurrentMode; // last argument of SetMode (redundant, as our other members represent the current settings, too) @@ -312,16 +312,16 @@ private: //#if 0 // _SOLAR__PRIVATE SVT_DLLPRIVATE void ConstructImpl(BrowserMode nMode); SVT_DLLPRIVATE void ExpandRowSelection( const BrowserMouseEvent& rEvt ); - SVT_DLLPRIVATE void ToggleSelection( BOOL bForce = FALSE ); + SVT_DLLPRIVATE void ToggleSelection( sal_Bool bForce = sal_False ); SVT_DLLPRIVATE void UpdateScrollbars(); SVT_DLLPRIVATE void AutoSizeLastColumn(); SVT_DLLPRIVATE long ImpGetDataRowHeight() const; - SVT_DLLPRIVATE Rectangle ImplFieldRectPixel( long nRow, USHORT nColId ) const; - SVT_DLLPRIVATE USHORT FrozenColCount() const; + SVT_DLLPRIVATE Rectangle ImplFieldRectPixel( long nRow, sal_uInt16 nColId ) const; + SVT_DLLPRIVATE sal_uInt16 FrozenColCount() const; - SVT_DLLPRIVATE void ColumnInserted( USHORT nPos ); + SVT_DLLPRIVATE void ColumnInserted( sal_uInt16 nPos ); DECL_DLLPRIVATE_LINK( ScrollHdl, ScrollBar * ); DECL_DLLPRIVATE_LINK( EndScrollHdl, ScrollBar * ); @@ -330,26 +330,26 @@ private: SVT_DLLPRIVATE long GetFrozenWidth() const; //#endif - BOOL GoToRow(long nRow, BOOL bRowColMove, BOOL bDoNotModifySelection = FALSE ); + sal_Bool GoToRow(long nRow, sal_Bool bRowColMove, sal_Bool bDoNotModifySelection = sal_False ); - BOOL GoToColumnId( USHORT nColId, BOOL bMakeVisible, BOOL bRowColMove = FALSE); - void SelectColumnPos( USHORT nCol, BOOL _bSelect, BOOL bMakeVisible); - void SelectColumnId( USHORT nColId, BOOL _bSelect, BOOL bMakeVisible) + sal_Bool GoToColumnId( sal_uInt16 nColId, sal_Bool bMakeVisible, sal_Bool bRowColMove = sal_False); + void SelectColumnPos( sal_uInt16 nCol, sal_Bool _bSelect, sal_Bool bMakeVisible); + void SelectColumnId( sal_uInt16 nColId, sal_Bool _bSelect, sal_Bool bMakeVisible) { SelectColumnPos( GetColumnPos(nColId), _bSelect, bMakeVisible); } - void ImplPaintData(OutputDevice& _rOut, const Rectangle& _rRect, BOOL _bForeignDevice, BOOL _bDrawSelections); + void ImplPaintData(OutputDevice& _rOut, const Rectangle& _rRect, sal_Bool _bForeignDevice, sal_Bool _bDrawSelections); - BOOL PaintCursorIfHiddenOnce() const { return !m_bFocusOnlyCursor && !HasFocus(); } + sal_Bool PaintCursorIfHiddenOnce() const { return !m_bFocusOnlyCursor && !HasFocus(); } - USHORT ToggleSelectedColumn(); - void SetToggledSelectedColumn(USHORT _nSelectedColumnId); + sal_uInt16 ToggleSelectedColumn(); + void SetToggledSelectedColumn(sal_uInt16 _nSelectedColumnId); protected: /// retrieves the XAccessible implementation associated with the BrowseBox instance ::svt::IAccessibleFactory& getAccessibleFactory(); protected: - USHORT ColCount() const; + sal_uInt16 ColCount() const; // software plug for database access // Der RowCount wird jetzt intern automatisch gezaehlt @@ -362,19 +362,19 @@ protected: // fuer Anzeige im VScrollBar z.B. auf "?" oder setzen void SetRealRowCount( const String &rRealRowCount ); - // Return Value muss immer TRUE sein - SeekRow *muss* klappen! + // Return Value muss immer sal_True sein - SeekRow *muss* klappen! // (sonst ASSERT) MI: wer hat das eingebaut? Das darf nicht so sein! /** seeks for the given row position @param nRow nRow starts at 0 */ - virtual BOOL SeekRow( long nRow ) = 0; + virtual sal_Bool SeekRow( long nRow ) = 0; virtual void DrawCursor(); virtual void PaintRow( OutputDevice &rDev, const Rectangle &rRect ); virtual void PaintData( Window& rWin, const Rectangle& rRect ); virtual void PaintField( OutputDevice& rDev, const Rectangle& rRect, - USHORT nColumnId ) const = 0; + sal_uInt16 nColumnId ) const = 0; // Benachrichtigung an die abgeleitete Klasse, dass sich der sichtbare // Bereich von Rows geaendert hat. Aus dieser Methode heraus darf // die abgeleitete Klasse Aenderungen des Model mit Hilfe der Methoden @@ -392,13 +392,13 @@ protected: // dadurch aendert sich nur die Numerierung der sichtbaren Rows // - Scrollen (und daraus resultierend eine andere erste sichtbare Row) // - Resize des Fensters - virtual void VisibleRowsChanged( long nNewTopRow, USHORT nNumRows); + virtual void VisibleRowsChanged( long nNewTopRow, sal_uInt16 nNumRows); // Anzahl sichtbarer Rows in dem Fenster (inkl. "angeschnittener" Rows) - USHORT GetVisibleRows() - { return (USHORT)((pDataWin->GetOutputSizePixel().Height() - 1 )/ GetDataRowHeight() + 1); } + sal_uInt16 GetVisibleRows() + { return (sal_uInt16)((pDataWin->GetOutputSizePixel().Height() - 1 )/ GetDataRowHeight() + 1); } long GetTopRow() { return nTopRow; } - USHORT GetFirstVisibleColNumber() const { return nFirstCol; } + sal_uInt16 GetFirstVisibleColNumber() const { return nFirstCol; } // Focus-Rect ein-/ausschalten void DoShowCursor( const char *pWhoLog ); @@ -452,7 +452,7 @@ public: virtual void GetFocus(); virtual void Resize(); virtual void Paint( const Rectangle& rRect ); - virtual void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, ULONG nFlags ); + virtual void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, sal_uIntPtr nFlags ); virtual void Command( const CommandEvent& rEvt ); virtual void StartDrag( sal_Int8 _nAction, const Point& _rPosPixel ); @@ -470,18 +470,18 @@ public: virtual void EndScroll(); virtual void Select(); virtual void DoubleClick( const BrowserMouseEvent& rEvt ); - virtual BOOL IsCursorMoveAllowed( long nNewRow, USHORT nNewColId ) const; + virtual sal_Bool IsCursorMoveAllowed( long nNewRow, sal_uInt16 nNewColId ) const; virtual void CursorMoved(); - virtual void ColumnMoved( USHORT nColId ); - virtual void ColumnResized( USHORT nColId ); - virtual long QueryColumnResize( USHORT nColId, long nWidth ); + virtual void ColumnMoved( sal_uInt16 nColId ); + virtual void ColumnResized( sal_uInt16 nColId ); + virtual long QueryColumnResize( sal_uInt16 nColId, long nWidth ); /// called when the row height has been changed interactively virtual void RowHeightChanged(); virtual long QueryMinimumRowHeight(); // Window-Control (pass to DataWindow) - void SetUpdateMode( BOOL bUpdate ); - BOOL GetUpdateMode() const; + void SetUpdateMode( sal_Bool bUpdate ); + sal_Bool GetUpdateMode() const; // map-mode and font control void SetFont( const Font& rNewFont ); @@ -495,73 +495,73 @@ public: const Color& GetGridLineColor() const {return aGridLineColor;} // inserting, changing, removing and freezing of columns - void InsertHandleColumn( ULONG nWidth ); - void InsertDataColumn( USHORT nItemId, const Image& rImage, + void InsertHandleColumn( sal_uIntPtr nWidth ); + void InsertDataColumn( sal_uInt16 nItemId, const Image& rImage, long nSize, HeaderBarItemBits nBits = HIB_STDSTYLE, - USHORT nPos = HEADERBAR_APPEND ); - void InsertDataColumn( USHORT nItemId, const XubString& rText, + sal_uInt16 nPos = HEADERBAR_APPEND ); + void InsertDataColumn( sal_uInt16 nItemId, const XubString& rText, long nSize, HeaderBarItemBits nBits = HIB_STDSTYLE, - USHORT nPos = HEADERBAR_APPEND ); - void InsertDataColumn( USHORT nItemId, + sal_uInt16 nPos = HEADERBAR_APPEND ); + void InsertDataColumn( sal_uInt16 nItemId, const Image& rImage, const XubString& rText, long nSize, HeaderBarItemBits nBits = HIB_STDSTYLE, - USHORT nPos = HEADERBAR_APPEND, + sal_uInt16 nPos = HEADERBAR_APPEND, // Hilfstext bei leerem rText const String* pHelpText = 0 ); - void SetColumnTitle( USHORT nColumnId, const String &rTitle ); - void SetColumnMode( USHORT nColumnId, BrowserColumnMode nFlags ); - void SetColumnWidth( USHORT nColumnId, ULONG nWidth ); - void SetColumnPos( USHORT nColumnId, USHORT nPos ); - void FreezeColumn( USHORT nColumnId, BOOL bFreeze = TRUE ); + void SetColumnTitle( sal_uInt16 nColumnId, const String &rTitle ); + void SetColumnMode( sal_uInt16 nColumnId, BrowserColumnMode nFlags ); + void SetColumnWidth( sal_uInt16 nColumnId, sal_uIntPtr nWidth ); + void SetColumnPos( sal_uInt16 nColumnId, sal_uInt16 nPos ); + void FreezeColumn( sal_uInt16 nColumnId, sal_Bool bFreeze = sal_True ); void UnfreezeColumns(); - void RemoveColumn( USHORT nColumnId ); + void RemoveColumn( sal_uInt16 nColumnId ); void RemoveColumns(); // control of title and data row height void SetDataRowHeight( long nPixel ); long GetDataRowHeight() const; - void SetTitleLines( USHORT nLines ); - USHORT GetTitleLines() const { return nTitleLines; } + void SetTitleLines( sal_uInt16 nLines ); + sal_uInt16 GetTitleLines() const { return nTitleLines; } virtual long GetTitleHeight() const; // access to dynamic values of cursor row - String GetColumnTitle( USHORT nColumnId ) const; - BrowserColumnMode GetColumnMode( USHORT nColumnId ) const; - Rectangle GetFieldRect( USHORT nColumnId ) const; - ULONG GetColumnWidth( USHORT nColumnId ) const; - USHORT GetColumnId( USHORT nPos ) const; - USHORT GetColumnPos( USHORT nColumnId ) const; - BOOL IsFrozen( USHORT nColumnId ) const; + String GetColumnTitle( sal_uInt16 nColumnId ) const; + BrowserColumnMode GetColumnMode( sal_uInt16 nColumnId ) const; + Rectangle GetFieldRect( sal_uInt16 nColumnId ) const; + sal_uIntPtr GetColumnWidth( sal_uInt16 nColumnId ) const; + sal_uInt16 GetColumnId( sal_uInt16 nPos ) const; + sal_uInt16 GetColumnPos( sal_uInt16 nColumnId ) const; + sal_Bool IsFrozen( sal_uInt16 nColumnId ) const; // movement of visible area void ResetScroll(); long ScrollColumns( long nColumns ); long ScrollRows( long nRows ); long ScrollPages( long nPagesY ); - BOOL MakeFieldVisible( long nRow, USHORT nColId, BOOL bComplete = FALSE ); + sal_Bool MakeFieldVisible( long nRow, sal_uInt16 nColId, sal_Bool bComplete = sal_False ); // access and movement of cursor long GetCurRow() const { return nCurRow; } - USHORT GetCurColumnId() const { return nCurColId; } - BOOL GoToRow( long nRow ); - BOOL GoToRowAndDoNotModifySelection( long nRow ); - BOOL GoToColumnId( USHORT nColId ); - BOOL GoToRowColumnId( long nRow, USHORT nColId ); + sal_uInt16 GetCurColumnId() const { return nCurColId; } + sal_Bool GoToRow( long nRow ); + sal_Bool GoToRowAndDoNotModifySelection( long nRow ); + sal_Bool GoToColumnId( sal_uInt16 nColId ); + sal_Bool GoToRowColumnId( long nRow, sal_uInt16 nColId ); // selections virtual void SetNoSelection(); virtual void SelectAll(); - virtual void SelectRow( long nRow, BOOL _bSelect = TRUE, BOOL bExpand = TRUE ); - void SelectColumnPos( USHORT nCol, BOOL _bSelect = TRUE ) - { SelectColumnPos( nCol, _bSelect, TRUE); } - void SelectColumnId( USHORT nColId, BOOL _bSelect = TRUE ) - { SelectColumnPos( GetColumnPos(nColId), _bSelect, TRUE); } + virtual void SelectRow( long nRow, sal_Bool _bSelect = sal_True, sal_Bool bExpand = sal_True ); + void SelectColumnPos( sal_uInt16 nCol, sal_Bool _bSelect = sal_True ) + { SelectColumnPos( nCol, _bSelect, sal_True); } + void SelectColumnId( sal_uInt16 nColId, sal_Bool _bSelect = sal_True ) + { SelectColumnPos( GetColumnPos(nColId), _bSelect, sal_True); } long GetSelectRowCount() const; - USHORT GetSelectColumnCount() const; + sal_uInt16 GetSelectColumnCount() const; virtual bool IsRowSelected( long nRow ) const; - bool IsColumnSelected( USHORT nColumnId ) const; + bool IsColumnSelected( sal_uInt16 nColumnId ) const; sal_Bool IsAllSelected() const; - long FirstSelectedRow( BOOL bInverse = FALSE ); + long FirstSelectedRow( sal_Bool bInverse = sal_False ); long LastSelectedRow(); long PrevSelectedRow(); long NextSelectedRow(); @@ -573,40 +573,40 @@ public: long FirstSelectedColumn( ) const; long NextSelectedColumn( ) const; - BOOL IsResizing() const { return bResizing; } + sal_Bool IsResizing() const { return bResizing; } // access to positions of fields, column and rows Window& GetEventWindow() const; Window& GetDataWindow() const { return *pDataWin; } Rectangle GetRowRectPixel( long nRow, - BOOL bRelToBrowser = TRUE ) const; - Rectangle GetFieldRectPixel( long nRow, USHORT nColId, - BOOL bRelToBrowser = TRUE) const; - BOOL IsFieldVisible( long nRow, USHORT nColId, - BOOL bComplete = FALSE ) const; + sal_Bool bRelToBrowser = sal_True ) const; + Rectangle GetFieldRectPixel( long nRow, sal_uInt16 nColId, + sal_Bool bRelToBrowser = sal_True) const; + sal_Bool IsFieldVisible( long nRow, sal_uInt16 nColId, + sal_Bool bComplete = sal_False ) const; long GetRowAtYPosPixel( long nY, - BOOL bRelToBrowser = TRUE ) const; - USHORT GetColumnAtXPosPixel( long nX, - BOOL bRelToBrowser = TRUE ) const; + sal_Bool bRelToBrowser = sal_True ) const; + sal_uInt16 GetColumnAtXPosPixel( long nX, + sal_Bool bRelToBrowser = sal_True ) const; // invalidations void Clear(); - void RowRemoved( long nRow, long nNumRows = 1, BOOL bDoPaint = TRUE ); - void RowModified( long nRow, USHORT nColId = USHRT_MAX ); - void RowInserted( long nRow, long nNumRows = 1, BOOL bDoPaint = TRUE, BOOL bKeepSelection = FALSE ); + void RowRemoved( long nRow, long nNumRows = 1, sal_Bool bDoPaint = sal_True ); + void RowModified( long nRow, sal_uInt16 nColId = USHRT_MAX ); + void RowInserted( long nRow, long nNumRows = 1, sal_Bool bDoPaint = sal_True, sal_Bool bKeepSelection = sal_False ); // miscellanous - void ReserveControlArea( USHORT nWidth = USHRT_MAX ); + void ReserveControlArea( sal_uInt16 nWidth = USHRT_MAX ); Rectangle GetControlArea() const; - BOOL ProcessKey( const KeyEvent& rEvt ); - void Dispatch( USHORT nId ); + sal_Bool ProcessKey( const KeyEvent& rEvt ); + void Dispatch( sal_uInt16 nId ); void SetMode( BrowserMode nMode = 0 ); BrowserMode GetMode( ) const { return m_nCurrentMode; } bool IsInCommandEvent() const; void SetCursorColor(const Color& _rCol); Color GetCursorColor() const { return m_aCursorColor; } - void ResetSelecting() { bSelecting = FALSE; } + void ResetSelecting() { bSelecting = sal_False; } /** specifies that the user is allowed to interactively change the height of a row, by simply dragging an arbitrary row separator. @@ -614,21 +614,21 @@ public: Note that this works only if there's a handle column, since only in this case, there *is* something for the user to click onto */ - void EnableInteractiveRowHeight( BOOL _bEnable = TRUE ) { mbInteractiveRowHeight = _bEnable; } - BOOL IsInteractiveRowHeightEnabled( ) const { return mbInteractiveRowHeight; } + void EnableInteractiveRowHeight( sal_Bool _bEnable = sal_True ) { mbInteractiveRowHeight = _bEnable; } + sal_Bool IsInteractiveRowHeightEnabled( ) const { return mbInteractiveRowHeight; } /// access to selected methods, to be granted to the BrowserColumn struct BrowserColumnAccess { friend class BrowserColumn; private: BrowserColumnAccess() { } }; /** public version of PaintField, with selected access rights for the BrowserColumn */ - void DoPaintField( OutputDevice& rDev, const Rectangle& rRect, USHORT nColumnId, BrowserColumnAccess ) const + void DoPaintField( OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColumnId, BrowserColumnAccess ) const { PaintField( rDev, rRect, nColumnId ); } /** suggests a default width for a column containing a given text The width is calculated so that the text fits completely, plus som margin. */ - ULONG GetDefaultColumnWidth( const String& _rText ) const; + sal_uIntPtr GetDefaultColumnWidth( const String& _rText ) const; /** GetCellText returns the text at the given position @param _nRow @@ -638,12 +638,12 @@ public: @return the text out of the cell */ - virtual String GetCellText(long _nRow, USHORT _nColId) const; + virtual String GetCellText(long _nRow, sal_uInt16 _nColId) const; /** @return the current column count */ - USHORT GetColumnCount() const { return ColCount(); } + sal_uInt16 GetColumnCount() const { return ColCount(); } /** commitBrowseBoxEvent commit the event at all listeners of the browsebox @param nEventId @@ -686,21 +686,21 @@ public: /** returns the Rectangle for either the column header bar ot the row header bar @param _bIsColumnBar - when column header bar is used + when column header bar is used @param _bOnScreen - when the rectangle should be calculated OnScreen + when the rectangle should be calculated OnScreen @return the Rectangle */ - virtual Rectangle calcHeaderRect(sal_Bool _bIsColumnBar,BOOL _bOnScreen = TRUE); + virtual Rectangle calcHeaderRect(sal_Bool _bIsColumnBar,sal_Bool _bOnScreen = sal_True); /** calculates the Rectangle of the table @param _bOnScreen - when the rectangle should be calculated OnScreen + when the rectangle should be calculated OnScreen @return the Rectangle */ - virtual Rectangle calcTableRect(BOOL _bOnScreen = TRUE); + virtual Rectangle calcTableRect(sal_Bool _bOnScreen = sal_True); /** @param _nRowId @@ -708,13 +708,13 @@ public: @param _nColId teh column id @param _bOnScreen - when the rectangle should be calculated OnScreen + when the rectangle should be calculated OnScreen @return the Rectangle */ - virtual Rectangle GetFieldRectPixelAbs(sal_Int32 _nRowId,sal_uInt16 _nColId, BOOL _bIsHeader, BOOL _bOnScreen = TRUE); + virtual Rectangle GetFieldRectPixelAbs(sal_Int32 _nRowId,sal_uInt16 _nColId, sal_Bool _bIsHeader, sal_Bool _bOnScreen = sal_True); - /// return if and only if the accessible object for this instance has been created and is alive + /// return if and only if the accessible object for this instance has been created and is alive sal_Bool isAccessibleAlive( ) const; // ACCESSIBILITY ========================================================== @@ -763,7 +763,7 @@ public: @param rnRow Out-paramater that takes the row index. @param rnColumnId Out-paramater that takes the column ID. @param rPoint The position in pixels relative to the data window. - @return , if the point could be converted to a valid address. */ + @return , if the point could be converted to a valid address. */ virtual sal_Bool ConvertPointToCellAddress( sal_Int32& rnRow, sal_uInt16& rnColumnId, const Point& rPoint ); @@ -771,21 +771,21 @@ public: index. @param rnRow Out-paramater that takes the row index. @param rPoint The position in pixels relative to the header bar. - @return , if the point could be converted to a valid index. */ + @return , if the point could be converted to a valid index. */ virtual sal_Bool ConvertPointToRowHeader( sal_Int32& rnRow, const Point& rPoint ); /** Converts a point relative to the column header bar origin to a column header index. @param rnColumnId Out-paramater that takes the column ID. @param rPoint The position in pixels relative to the header bar. - @return , if the point could be converted to a valid index. */ + @return , if the point could be converted to a valid index. */ virtual sal_Bool ConvertPointToColumnHeader( sal_uInt16& rnColumnPos, const Point& rPoint ); /** Converts a point relative to the BrowseBox origin to the index of an existing control. @param rnRow Out-paramater that takes the 0-based control index. @param rPoint The position in pixels relative to the BrowseBox. - @return , if the point could be converted to a valid index. */ + @return , if the point could be converted to a valid index. */ virtual sal_Bool ConvertPointToControlIndex( sal_Int32& rnIndex, const Point& rPoint ); // Object data and state -------------------------------------------------- @@ -836,7 +836,7 @@ public: virtual sal_uInt16 GetCurrColumn() const; virtual sal_Bool HasRowHeader() const; virtual sal_Bool IsCellFocusable() const; - virtual BOOL GoToCell( sal_Int32 _nRow, sal_uInt16 _nColumn ); + virtual sal_Bool GoToCell( sal_Int32 _nRow, sal_uInt16 _nColumn ); virtual void SelectColumn( sal_uInt16 _nColumn, sal_Bool _bSelect = sal_True ); virtual sal_Bool IsColumnSelected( long _nColumn ) const; virtual sal_Int32 GetSelectedRowCount() const; @@ -844,11 +844,11 @@ public: virtual void GetAllSelectedRows( ::com::sun::star::uno::Sequence< sal_Int32 >& _rRows ) const; virtual void GetAllSelectedColumns( ::com::sun::star::uno::Sequence< sal_Int32 >& _rColumns ) const; virtual sal_Bool IsCellVisible( sal_Int32 _nRow, sal_uInt16 _nColumn ) const; - virtual String GetAccessibleCellText(long _nRow, USHORT _nColPos) const; - virtual BOOL GetGlyphBoundRects( const Point& rOrigin, const String& rStr, int nIndex, int nLen, int nBase, MetricVector& rVector ); + virtual String GetAccessibleCellText(long _nRow, sal_uInt16 _nColPos) const; + virtual sal_Bool GetGlyphBoundRects( const Point& rOrigin, const String& rStr, int nIndex, int nLen, int nBase, MetricVector& rVector ); virtual Rectangle GetWindowExtentsRelative( Window *pRelativeWindow ) const; virtual void GrabFocus(); - virtual XACC GetAccessible( BOOL bCreate = TRUE ); + virtual XACC GetAccessible( sal_Bool bCreate = sal_True ); virtual Window* GetAccessibleParentWindow() const; virtual Window* GetWindowInstance(); diff --git a/svtools/inc/svtools/colctrl.hxx b/svtools/inc/svtools/colctrl.hxx index d76f8e881269..7841ce93952e 100644 --- a/svtools/inc/svtools/colctrl.hxx +++ b/svtools/inc/svtools/colctrl.hxx @@ -72,7 +72,7 @@ public: Color GetColor() const { return maColor; }; void SetColor( const Color& rCol ); - void SetColor( const ColorHSB& rCol, BOOL bSetColor = TRUE ); + void SetColor( const ColorHSB& rCol, sal_Bool bSetColor = sal_True ); short GetLuminance() const { return mnLuminance; }; void SetLuminance( short nLum ); @@ -111,27 +111,27 @@ enum CMCPosition { CMC_TOPLEFT, CMC_TOPRIGHT, CMC_BOTTOMLEFT, CMC_BOTTOMRIGHT, C class ColorMixingControl : public ValueSet { private: - USHORT mnRows; - USHORT mnColumns; + sal_uInt16 mnRows; + sal_uInt16 mnColumns; Color maColor[4]; void Initialize(); - Color CalcDifferenceColor( USHORT nCol1, USHORT nCol2, USHORT nSteps ); - void FillRow( USHORT nRow ); - void FillColumn( USHORT nColumn ); + Color CalcDifferenceColor( sal_uInt16 nCol1, sal_uInt16 nCol2, sal_uInt16 nSteps ); + void FillRow( sal_uInt16 nRow ); + void FillColumn( sal_uInt16 nColumn ); public: ColorMixingControl( Window* pParent, WinBits nStyle = 0, - USHORT nRows = 4, USHORT nColumns = 4 ); + sal_uInt16 nRows = 4, sal_uInt16 nColumns = 4 ); ColorMixingControl( Window* pParent, const ResId& rResId, - USHORT nRows = 4, USHORT nColumns = 4 ); + sal_uInt16 nRows = 4, sal_uInt16 nColumns = 4 ); ~ColorMixingControl(); - USHORT GetRows() const { return mnRows; }; - void SetRows( USHORT nRows ); - USHORT GetColumns() const { return mnColumns; }; - void SetColumns( USHORT nColumns ); + sal_uInt16 GetRows() const { return mnRows; }; + void SetRows( sal_uInt16 nRows ); + sal_uInt16 GetColumns() const { return mnColumns; }; + void SetColumns( sal_uInt16 nColumns ); using ValueSet::GetColor; Color GetColor( CMCPosition ePos ) const { return maColor[ ePos ]; }; @@ -149,23 +149,23 @@ public: class ColorHSB { private: - USHORT mnHue; // Farbwinkel, 360 Grad - USHORT mnSat; // Saturation, 100 % - USHORT mnBri; // Brightness, 100 % + sal_uInt16 mnHue; // Farbwinkel, 360 Grad + sal_uInt16 mnSat; // Saturation, 100 % + sal_uInt16 mnBri; // Brightness, 100 % public: ColorHSB() { mnHue=0; mnSat=0; mnBri=0; } - ColorHSB( USHORT nH, USHORT nS, USHORT nB ) + ColorHSB( sal_uInt16 nH, sal_uInt16 nS, sal_uInt16 nB ) { mnHue=nH; mnSat=nS; mnBri=nB; } ColorHSB( const Color& rColor ); - void SetHue( USHORT nH ) { mnHue=nH; } - void SetSat( USHORT nS ) { mnSat=nS; } - void SetBri( USHORT nB ) { mnBri=nB; } - USHORT GetHue() const { return mnHue; } - USHORT GetSat() const { return mnSat; } - USHORT GetBri() const { return mnBri; } + void SetHue( sal_uInt16 nH ) { mnHue=nH; } + void SetSat( sal_uInt16 nS ) { mnSat=nS; } + void SetBri( sal_uInt16 nB ) { mnBri=nB; } + sal_uInt16 GetHue() const { return mnHue; } + sal_uInt16 GetSat() const { return mnSat; } + sal_uInt16 GetBri() const { return mnBri; } Color GetRGB() const; }; @@ -176,26 +176,26 @@ public: class ColorCMYK { private: - USHORT mnCyan; - USHORT mnMagenta; - USHORT mnYellow; - USHORT mnKey; + sal_uInt16 mnCyan; + sal_uInt16 mnMagenta; + sal_uInt16 mnYellow; + sal_uInt16 mnKey; public: ColorCMYK() { mnCyan=0; mnMagenta=0; mnYellow=0; mnKey=100; } - ColorCMYK( USHORT nC, USHORT nM, USHORT nY, USHORT nK ) + ColorCMYK( sal_uInt16 nC, sal_uInt16 nM, sal_uInt16 nY, sal_uInt16 nK ) { mnCyan=nC; mnMagenta=nM; mnYellow=nY; mnKey=nK; } ColorCMYK( const Color& rColor ); - void SetCyan( USHORT nC ) { mnCyan=nC; } - void SetMagenta( USHORT nM ) { mnMagenta=nM; } - void SetYellow( USHORT nY ) { mnYellow=nY; } - void SetKey( USHORT nK ) { mnKey=nK; } - USHORT GetCyan() const { return mnCyan; } - USHORT GetMagenta() const { return mnMagenta; } - USHORT GetYellow() const { return mnYellow; } - USHORT GetKey() const { return mnKey; } + void SetCyan( sal_uInt16 nC ) { mnCyan=nC; } + void SetMagenta( sal_uInt16 nM ) { mnMagenta=nM; } + void SetYellow( sal_uInt16 nY ) { mnYellow=nY; } + void SetKey( sal_uInt16 nK ) { mnKey=nK; } + sal_uInt16 GetCyan() const { return mnCyan; } + sal_uInt16 GetMagenta() const { return mnMagenta; } + sal_uInt16 GetYellow() const { return mnYellow; } + sal_uInt16 GetKey() const { return mnKey; } Color GetRGB() const; }; diff --git a/svtools/inc/svtools/editbrowsebox.hxx b/svtools/inc/svtools/editbrowsebox.hxx index f97449e1880c..1b085adceac1 100644 --- a/svtools/inc/svtools/editbrowsebox.hxx +++ b/svtools/inc/svtools/editbrowsebox.hxx @@ -99,7 +99,7 @@ namespace svt protected: Control* pWindow; - sal_Bool bSuspended; // if the window is hidden and disabled + sal_Bool bSuspended; // if the window is hidden and disabled public: TYPEINFO(); @@ -142,8 +142,8 @@ namespace svt virtual String GetText( LineEnd aSeparator ) const = 0; virtual void SetText( const String& _rStr ) = 0; - virtual BOOL IsReadOnly() const = 0; - virtual void SetReadOnly( BOOL bReadOnly ) = 0; + virtual sal_Bool IsReadOnly() const = 0; + virtual void SetReadOnly( sal_Bool bReadOnly ) = 0; virtual xub_StrLen GetMaxTextLen() const = 0; virtual void SetMaxTextLen( xub_StrLen _nMaxLen ) = 0; @@ -178,8 +178,8 @@ namespace svt virtual String GetText( LineEnd aSeparator ) const; virtual void SetText( const String& _rStr ); - virtual BOOL IsReadOnly() const; - virtual void SetReadOnly( BOOL bReadOnly ); + virtual sal_Bool IsReadOnly() const; + virtual void SetReadOnly( sal_Bool bReadOnly ); virtual xub_StrLen GetMaxTextLen() const; virtual void SetMaxTextLen( xub_StrLen _nMaxLen ); @@ -220,7 +220,7 @@ namespace svt virtual void Modify(); private: - BOOL dispatchKeyEvent( const KeyEvent& _rEvent ); + sal_Bool dispatchKeyEvent( const KeyEvent& _rEvent ); }; //================================================================== @@ -246,7 +246,7 @@ namespace svt class SVT_DLLPUBLIC EditCellController : public CellController { IEditImplementation* m_pEditImplementation; - BOOL m_bOwnImplementation; // did we create m_pEditImplementation? + sal_Bool m_bOwnImplementation; // did we create m_pEditImplementation? public: TYPEINFO(); @@ -302,7 +302,7 @@ namespace svt virtual void GetFocus(); virtual long PreNotify(NotifyEvent& rEvt); virtual void Paint(const Rectangle& rClientRect); - virtual void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, ULONG nFlags ); + virtual void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, sal_uIntPtr nFlags ); virtual void StateChanged( StateChangedType nStateChange ); virtual void DataChanged( const DataChangedEvent& _rEvent ); virtual void Resize(); @@ -487,7 +487,7 @@ namespace svt CellControllerRef aController, aOldController; - ULONG nStartEvent, nEndEvent, nCellModifiedEvent; // event ids + sal_uIntPtr nStartEvent, nEndEvent, nCellModifiedEvent; // event ids Window* m_pFocusWhileRequest; // In ActivateCell, we grab the focus asynchronously, but if between requesting activation // and the asynchornous event the focus has changed, we won't grab it for ourself. @@ -664,7 +664,7 @@ namespace svt virtual sal_Int32 GetFieldIndexAtPoint(sal_Int32 _nRow,sal_Int32 _nColumnPos,const Point& _rPoint); ::com::sun::star::uno::Reference< - ::com::sun::star::accessibility::XAccessible > CreateAccessibleCheckBoxCell(long _nRow, USHORT _nColumnPos,const TriState& eState,sal_Bool _bEnabled=sal_True); + ::com::sun::star::accessibility::XAccessible > CreateAccessibleCheckBoxCell(long _nRow, sal_uInt16 _nColumnPos,const TriState& eState,sal_Bool _bEnabled=sal_True); protected: // creates the accessible which wraps the active cell void implCreateActiveAccessible( ); diff --git a/svtools/inc/svtools/editimplementation.hxx b/svtools/inc/svtools/editimplementation.hxx index 987d94c7bcee..fcdd140d78d6 100644 --- a/svtools/inc/svtools/editimplementation.hxx +++ b/svtools/inc/svtools/editimplementation.hxx @@ -74,14 +74,14 @@ void GenericEditImplementation< EDIT >::SetSelection( const Selection& _rSelecti //---------------------------------------------------------------------- template -void GenericEditImplementation< EDIT >::SetReadOnly( BOOL bReadOnly ) +void GenericEditImplementation< EDIT >::SetReadOnly( sal_Bool bReadOnly ) { m_rEdit.SetReadOnly( bReadOnly ); } //---------------------------------------------------------------------- template -BOOL GenericEditImplementation< EDIT >::IsReadOnly() const +sal_Bool GenericEditImplementation< EDIT >::IsReadOnly() const { return m_rEdit.IsReadOnly(); } diff --git a/svtools/inc/svtools/editsyntaxhighlighter.hxx b/svtools/inc/svtools/editsyntaxhighlighter.hxx index 01add0c4ce1d..aca298fd1d31 100644 --- a/svtools/inc/svtools/editsyntaxhighlighter.hxx +++ b/svtools/inc/svtools/editsyntaxhighlighter.hxx @@ -41,7 +41,7 @@ class SVT_DLLPUBLIC MultiLineEditSyntaxHighlight : public MultiLineEdit svtools::ColorConfig m_aColorConfig; private: - virtual void DoBracketHilight(USHORT aKey); + virtual void DoBracketHilight(sal_uInt16 aKey); protected: virtual long PreNotify( NotifyEvent& rNEvt ); diff --git a/svtools/inc/svtools/ehdl.hxx b/svtools/inc/svtools/ehdl.hxx index 967c41636ea3..88ea6cf9ef70 100644 --- a/svtools/inc/svtools/ehdl.hxx +++ b/svtools/inc/svtools/ehdl.hxx @@ -43,16 +43,16 @@ class SVT_DLLPUBLIC SfxErrorContext : private ErrorContext { public: SfxErrorContext( - USHORT nCtxIdP, Window *pWin=0, - USHORT nResIdP=USHRT_MAX, ResMgr *pMgrP=0); + sal_uInt16 nCtxIdP, Window *pWin=0, + sal_uInt16 nResIdP=USHRT_MAX, ResMgr *pMgrP=0); SfxErrorContext( - USHORT nCtxIdP, const String &aArg1, Window *pWin=0, - USHORT nResIdP=USHRT_MAX, ResMgr *pMgrP=0); - virtual BOOL GetString(ULONG nErrId, String &rStr); + sal_uInt16 nCtxIdP, const String &aArg1, Window *pWin=0, + sal_uInt16 nResIdP=USHRT_MAX, ResMgr *pMgrP=0); + virtual sal_Bool GetString(sal_uIntPtr nErrId, String &rStr); private: - USHORT nCtxId; - USHORT nResId; + sal_uInt16 nCtxId; + sal_uInt16 nResId; ResMgr *pMgr; String aArg1; }; @@ -60,26 +60,26 @@ private: class SVT_DLLPUBLIC SfxErrorHandler : private ErrorHandler { public: - SfxErrorHandler(USHORT nId, ULONG lStart, ULONG lEnd, ResMgr *pMgr=0); + SfxErrorHandler(sal_uInt16 nId, sal_uIntPtr lStart, sal_uIntPtr lEnd, ResMgr *pMgr=0); ~SfxErrorHandler(); protected: - virtual BOOL GetErrorString(ULONG lErrId, String &, USHORT&) const; - virtual BOOL GetMessageString(ULONG lErrId, String &, USHORT&) const; + virtual sal_Bool GetErrorString(sal_uIntPtr lErrId, String &, sal_uInt16&) const; + virtual sal_Bool GetMessageString(sal_uIntPtr lErrId, String &, sal_uInt16&) const; private: - ULONG lStart; - ULONG lEnd; - USHORT nId; + sal_uIntPtr lStart; + sal_uIntPtr lEnd; + sal_uInt16 nId; ResMgr *pMgr; ResMgr *pFreeMgr; //#if 0 // _SOLAR__PRIVATE - SVT_DLLPRIVATE BOOL GetClassString(ULONG lErrId, String &) const; + SVT_DLLPRIVATE sal_Bool GetClassString(sal_uIntPtr lErrId, String &) const; //#endif - virtual BOOL CreateString( - const ErrorInfo *, String &, USHORT &) const; + virtual sal_Bool CreateString( + const ErrorInfo *, String &, sal_uInt16 &) const; }; #endif diff --git a/svtools/inc/svtools/embedhlp.hxx b/svtools/inc/svtools/embedhlp.hxx index 098b565385ec..24a99ea4c4b5 100644 --- a/svtools/inc/svtools/embedhlp.hxx +++ b/svtools/inc/svtools/embedhlp.hxx @@ -59,8 +59,8 @@ namespace svt EmbeddedObjectRef_Impl* mpImp; NS_UNO::Reference < NS_EMBED::XEmbeddedObject > mxObj; - SVT_DLLPRIVATE SvStream* GetGraphicStream( BOOL bUpdate ) const; - /* SVT_DLLPRIVATE */ void GetReplacement( BOOL bUpdate ); + SVT_DLLPRIVATE SvStream* GetGraphicStream( sal_Bool bUpdate ) const; + /* SVT_DLLPRIVATE */ void GetReplacement( sal_Bool bUpdate ); SVT_DLLPRIVATE void Construct_Impl(); EmbeddedObjectRef& operator = ( const EmbeddedObjectRef& ); @@ -71,7 +71,7 @@ namespace svt static void DrawPaintReplacement( const Rectangle &rRect, const String &rText, OutputDevice *pOut ); static void DrawShading( const Rectangle &rRect, OutputDevice *pOut ); - static BOOL TryRunningState( const NS_UNO::Reference < NS_EMBED::XEmbeddedObject >& ); + static sal_Bool TryRunningState( const NS_UNO::Reference < NS_EMBED::XEmbeddedObject >& ); static void SetGraphicToContainer( const Graphic& rGraphic, comphelper::EmbeddedObjectContainer& aContainer, const ::rtl::OUString& aName, @@ -96,7 +96,7 @@ namespace svt ~EmbeddedObjectRef(); EmbeddedObjectRef( const EmbeddedObjectRef& ); - BOOL TryRunningState(); + sal_Bool TryRunningState(); // assigning to a container enables the object to exchange graphical representations with a storage void AssignToContainer( comphelper::EmbeddedObjectContainer* pContainer, const ::rtl::OUString& rPersistName ); @@ -119,15 +119,15 @@ namespace svt const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xInGrStream, const ::rtl::OUString& rMediaType ); - void UpdateReplacement() { GetReplacement( TRUE ); } + void UpdateReplacement() { GetReplacement( sal_True ); } void UpdateReplacementOnDemand(); MapUnit GetMapUnit() const; - void Lock( BOOL bLock = TRUE ); - BOOL IsLocked() const; + void Lock( sal_Bool bLock = sal_True ); + sal_Bool IsLocked() const; void Clear(); - BOOL is() const { return mxObj.is(); } + sal_Bool is() const { return mxObj.is(); } - BOOL IsChart() const; + sal_Bool IsChart() const; // #i104867# // Provides a graphic version number for the fetchable Graphic during this object's lifetime. Internally, diff --git a/svtools/inc/svtools/filter.hxx b/svtools/inc/svtools/filter.hxx index 49ec77adfea5..0461cc6a9272 100644 --- a/svtools/inc/svtools/filter.hxx +++ b/svtools/inc/svtools/filter.hxx @@ -44,7 +44,7 @@ struct ImplDirEntryHelper { - static BOOL Exists( const INetURLObject& rObj ); + static sal_Bool Exists( const INetURLObject& rObj ); static void Kill( const String& rStr ); }; @@ -64,8 +64,8 @@ class Graphic; #define GRFILTER_OUTHINT_GREY 1 -#define GRFILTER_FORMAT_NOTFOUND ((USHORT)0xFFFF) -#define GRFILTER_FORMAT_DONTKNOW ((USHORT)0xFFFF) +#define GRFILTER_FORMAT_NOTFOUND ((sal_uInt16)0xFFFF) +#define GRFILTER_FORMAT_DONTKNOW ((sal_uInt16)0xFFFF) #define GRFILTER_I_FLAGS_SET_LOGSIZE_FOR_JPEG 00000001 #define GRFILTER_I_FLAGS_DONT_SET_LOGSIZE_FOR_JPEG 00000002 @@ -107,32 +107,32 @@ class Graphic; // unterstuetzten Grafik-Fileformate // ------------------------------------ -#define GFF_NOT ( (USHORT)0x0000 ) -#define GFF_BMP ( (USHORT)0x0001 ) -#define GFF_GIF ( (USHORT)0x0002 ) -#define GFF_JPG ( (USHORT)0x0003 ) -#define GFF_PCD ( (USHORT)0x0004 ) -#define GFF_PCX ( (USHORT)0x0005 ) -#define GFF_PNG ( (USHORT)0x0006 ) -#define GFF_TIF ( (USHORT)0x0007 ) -#define GFF_XBM ( (USHORT)0x0008 ) -#define GFF_XPM ( (USHORT)0x0009 ) -#define GFF_PBM ( (USHORT)0x000a ) -#define GFF_PGM ( (USHORT)0x000b ) -#define GFF_PPM ( (USHORT)0x000c ) -#define GFF_RAS ( (USHORT)0x000d ) -#define GFF_TGA ( (USHORT)0x000e ) -#define GFF_PSD ( (USHORT)0x000f ) -#define GFF_EPS ( (USHORT)0x0010 ) -#define GFF_DXF ( (USHORT)0x00f1 ) -#define GFF_MET ( (USHORT)0x00f2 ) -#define GFF_PCT ( (USHORT)0x00f3 ) -#define GFF_SGF ( (USHORT)0x00f4 ) -#define GFF_SVM ( (USHORT)0x00f5 ) -#define GFF_WMF ( (USHORT)0x00f6 ) -#define GFF_SGV ( (USHORT)0x00f7 ) -#define GFF_EMF ( (USHORT)0x00f8 ) -#define GFF_XXX ( (USHORT)0xffff ) +#define GFF_NOT ( (sal_uInt16)0x0000 ) +#define GFF_BMP ( (sal_uInt16)0x0001 ) +#define GFF_GIF ( (sal_uInt16)0x0002 ) +#define GFF_JPG ( (sal_uInt16)0x0003 ) +#define GFF_PCD ( (sal_uInt16)0x0004 ) +#define GFF_PCX ( (sal_uInt16)0x0005 ) +#define GFF_PNG ( (sal_uInt16)0x0006 ) +#define GFF_TIF ( (sal_uInt16)0x0007 ) +#define GFF_XBM ( (sal_uInt16)0x0008 ) +#define GFF_XPM ( (sal_uInt16)0x0009 ) +#define GFF_PBM ( (sal_uInt16)0x000a ) +#define GFF_PGM ( (sal_uInt16)0x000b ) +#define GFF_PPM ( (sal_uInt16)0x000c ) +#define GFF_RAS ( (sal_uInt16)0x000d ) +#define GFF_TGA ( (sal_uInt16)0x000e ) +#define GFF_PSD ( (sal_uInt16)0x000f ) +#define GFF_EPS ( (sal_uInt16)0x0010 ) +#define GFF_DXF ( (sal_uInt16)0x00f1 ) +#define GFF_MET ( (sal_uInt16)0x00f2 ) +#define GFF_PCT ( (sal_uInt16)0x00f3 ) +#define GFF_SGF ( (sal_uInt16)0x00f4 ) +#define GFF_SVM ( (sal_uInt16)0x00f5 ) +#define GFF_WMF ( (sal_uInt16)0x00f6 ) +#define GFF_SGV ( (sal_uInt16)0x00f7 ) +#define GFF_EMF ( (sal_uInt16)0x00f8 ) +#define GFF_XXX ( (sal_uInt16)0xffff ) // --------------- // - RequestInfo - @@ -140,8 +140,8 @@ class Graphic; struct RequestInfo { - BYTE* pBuffer; - ULONG nRealBufferSize; + sal_uInt8* pBuffer; + sal_uIntPtr nRealBufferSize; }; // --------------------- @@ -157,16 +157,16 @@ class SVT_DLLPUBLIC GraphicDescriptor Size aLogSize; SvStream* pMemStm; SvStream* pBaseStm; - ULONG nStmPos; - USHORT nBitsPerPixel; - USHORT nPlanes; - USHORT nFormat; - BOOL bCompressed; - BOOL bDataReady; - BOOL bLinked; - BOOL bLinkChanged; - BOOL bWideSearch; - BOOL bBaseStm; + sal_uIntPtr nStmPos; + sal_uInt16 nBitsPerPixel; + sal_uInt16 nPlanes; + sal_uInt16 nFormat; + sal_Bool bCompressed; + sal_Bool bDataReady; + sal_Bool bLinked; + sal_Bool bLinkChanged; + sal_Bool bWideSearch; + sal_Bool bBaseStm; long nExtra1; long nExtra2; @@ -174,30 +174,30 @@ class SVT_DLLPUBLIC GraphicDescriptor //#if 0 // _SOLAR__PRIVATE - BOOL ImpDetectBMP( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectGIF( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectJPG( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPCD( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPCX( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPNG( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectTIF( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectXBM( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectXPM( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPBM( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPGM( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPPM( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectRAS( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectTGA( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPSD( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectEPS( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectDXF( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectMET( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectPCT( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectSGF( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectSVM( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectWMF( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectSGV( SvStream& rStm, BOOL bExtendedInfo ); - BOOL ImpDetectEMF( SvStream& rStm, BOOL bExtendedInfo ); + sal_Bool ImpDetectBMP( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectGIF( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectJPG( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPCD( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPCX( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPNG( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectTIF( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectXBM( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectXPM( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPBM( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPGM( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPPM( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectRAS( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectTGA( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPSD( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectEPS( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectDXF( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectMET( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectPCT( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectSGF( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectSVM( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectWMF( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectSGV( SvStream& rStm, sal_Bool bExtendedInfo ); + sal_Bool ImpDetectEMF( SvStream& rStm, sal_Bool bExtendedInfo ); //#endif @@ -206,8 +206,8 @@ class SVT_DLLPUBLIC GraphicDescriptor protected: - BOOL IsDataReady() const; - BOOL IsWideSearch() const; + sal_Bool IsDataReady() const; + sal_Bool IsWideSearch() const; SvStream& GetSearchStream() const; const String& GetPathExtension() const; @@ -237,14 +237,14 @@ public: virtual ~GraphicDescriptor(); // Startet die Detektion; - // bei bExtendedInfo == TRUE werden soweit wie moeglich + // bei bExtendedInfo == sal_True werden soweit wie moeglich // Daten aus dem jeweiligen FileHeader ermittelt // ( Groesse, Farbtiefe usw. ) - virtual BOOL Detect( BOOL bExtendedInfo = FALSE ); + virtual sal_Bool Detect( sal_Bool bExtendedInfo = sal_False ); // liefert das Fileformat nach erfolgreicher Detektion zurueck; // wenn kein Format erkannt wurde, ist das Formart GFF_NOT - USHORT GetFileFormat() const { return nFormat; } + sal_uInt16 GetFileFormat() const { return nFormat; } // liefert die Pixel-Bildgroesse oder 0-Size zurueck const Size& GetSizePixel() const { return (Size&) aPixSize; } @@ -253,19 +253,19 @@ public: const Size& GetSize_100TH_MM() const { return (Size&) aLogSize; } // liefert die Bits/Pixel oder 0 zurueck - USHORT GetBitsPerPixel() const { return nBitsPerPixel; } + sal_uInt16 GetBitsPerPixel() const { return nBitsPerPixel; } // liefert die Anzahl der Planes oder 0 zurueck - USHORT GetPlanes() const { return nPlanes; } + sal_uInt16 GetPlanes() const { return nPlanes; } // zeigt an, ob das Bild evtl. komprimiert (wie auch immer) ist - BOOL IsCompressed() const { return bCompressed; } + sal_Bool IsCompressed() const { return bCompressed; } // setzt den LinkHdl zum Setzen der Bytes; // der Handler muss einen Pointer auf die RequestInfo-Struktur // zurueckgeben; die Anzahl der minimal zur Verfuegung zu stellenden // Daten muss im Handler ueber ::GetRequestedByteCount() erfragt werden; - // die tatsaechlich zur Verfuegung gestellte BYTE-Anzahl + // die tatsaechlich zur Verfuegung gestellte sal_uInt8-Anzahl // wird in der RequestInfo-Struktur gesetzt void SetRequestHdl( const Link& rRequestHdl ); @@ -274,7 +274,7 @@ public: // muss im ReqHdl gerufen werden, um zu erfahren, wieviele // Bytes _mindestens_ bereitgestellt werden muessen - ULONG GetRequestedByteCount() const; + sal_uIntPtr GetRequestedByteCount() const; // gibt die Filternummer des Filters zurueck, // der im GraphicFilter zum Lesen dieses Formats @@ -288,8 +288,8 @@ public: struct FilterErrorEx { - ULONG nFilterError; - ULONG nStreamError; + sal_uIntPtr nFilterError; + sal_uIntPtr nStreamError; long nDummy1; long nDummy2; long nDummy3; @@ -309,7 +309,7 @@ class SVT_DLLPUBLIC GraphicFilter private: void ImplInit(); - ULONG ImplSetError( ULONG nError, const SvStream* pStm = NULL ); + sal_uIntPtr ImplSetError( sal_uIntPtr nError, const SvStream* pStm = NULL ); sal_uInt16 ImpTestOrFindFormat( const String& rPath, SvStream& rStream, sal_uInt16& rFormat ); DECL_LINK( FilterCallback, ConvertData* pData ); @@ -337,73 +337,73 @@ public: void SetFilterPath( const String& rFilterPath ) { aFilterPath = rFilterPath; }; - USHORT GetImportFormatCount(); - USHORT GetImportFormatNumber( const String& rFormatName ); - USHORT GetImportFormatNumberForMediaType( const String& rMediaType ); - USHORT GetImportFormatNumberForShortName( const String& rShortName ); + sal_uInt16 GetImportFormatCount(); + sal_uInt16 GetImportFormatNumber( const String& rFormatName ); + sal_uInt16 GetImportFormatNumberForMediaType( const String& rMediaType ); + sal_uInt16 GetImportFormatNumberForShortName( const String& rShortName ); sal_uInt16 GetImportFormatNumberForTypeName( const String& rType ); - String GetImportFormatName( USHORT nFormat ); - String GetImportFormatTypeName( USHORT nFormat ); - String GetImportFormatMediaType( USHORT nFormat ); - String GetImportFormatShortName( USHORT nFormat ); - String GetImportOSFileType( USHORT nFormat ); - String GetImportWildcard( USHORT nFormat, sal_Int32 nEntry = 0 ); - BOOL IsImportPixelFormat( USHORT nFormat ); - - USHORT GetExportFormatCount(); - USHORT GetExportFormatNumber( const String& rFormatName ); - USHORT GetExportFormatNumberForMediaType( const String& rShortName ); - USHORT GetExportFormatNumberForShortName( const String& rShortName ); + String GetImportFormatName( sal_uInt16 nFormat ); + String GetImportFormatTypeName( sal_uInt16 nFormat ); + String GetImportFormatMediaType( sal_uInt16 nFormat ); + String GetImportFormatShortName( sal_uInt16 nFormat ); + String GetImportOSFileType( sal_uInt16 nFormat ); + String GetImportWildcard( sal_uInt16 nFormat, sal_Int32 nEntry = 0 ); + sal_Bool IsImportPixelFormat( sal_uInt16 nFormat ); + + sal_uInt16 GetExportFormatCount(); + sal_uInt16 GetExportFormatNumber( const String& rFormatName ); + sal_uInt16 GetExportFormatNumberForMediaType( const String& rShortName ); + sal_uInt16 GetExportFormatNumberForShortName( const String& rShortName ); sal_uInt16 GetExportFormatNumberForTypeName( const String& rType ); - String GetExportFormatName( USHORT nFormat ); - String GetExportFormatTypeName( USHORT nFormat ); - String GetExportFormatMediaType( USHORT nFormat ); - String GetExportFormatShortName( USHORT nFormat ); - String GetExportOSFileType( USHORT nFormat ); - String GetExportWildcard( USHORT nFormat, sal_Int32 nEntry = 0 ); - BOOL IsExportPixelFormat( USHORT nFormat ); - - BOOL HasImportDialog( USHORT nFormat ); - BOOL DoImportDialog( Window* pWindow, USHORT nFormat ); - - BOOL HasExportDialog( USHORT nFormat ); - BOOL DoExportDialog( Window* pWindow, USHORT nFormat ); - BOOL DoExportDialog( Window* pWindow, USHORT nFormat, FieldUnit eFieldUnit ); - - USHORT ExportGraphic( const Graphic& rGraphic, const INetURLObject& rPath, - USHORT nFormat = GRFILTER_FORMAT_DONTKNOW, + String GetExportFormatName( sal_uInt16 nFormat ); + String GetExportFormatTypeName( sal_uInt16 nFormat ); + String GetExportFormatMediaType( sal_uInt16 nFormat ); + String GetExportFormatShortName( sal_uInt16 nFormat ); + String GetExportOSFileType( sal_uInt16 nFormat ); + String GetExportWildcard( sal_uInt16 nFormat, sal_Int32 nEntry = 0 ); + sal_Bool IsExportPixelFormat( sal_uInt16 nFormat ); + + sal_Bool HasImportDialog( sal_uInt16 nFormat ); + sal_Bool DoImportDialog( Window* pWindow, sal_uInt16 nFormat ); + + sal_Bool HasExportDialog( sal_uInt16 nFormat ); + sal_Bool DoExportDialog( Window* pWindow, sal_uInt16 nFormat ); + sal_Bool DoExportDialog( Window* pWindow, sal_uInt16 nFormat, FieldUnit eFieldUnit ); + + sal_uInt16 ExportGraphic( const Graphic& rGraphic, const INetURLObject& rPath, + sal_uInt16 nFormat = GRFILTER_FORMAT_DONTKNOW, const com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue >* pFilterData = NULL ); - USHORT ExportGraphic( const Graphic& rGraphic, const String& rPath, - SvStream& rOStm, USHORT nFormat = GRFILTER_FORMAT_DONTKNOW, + sal_uInt16 ExportGraphic( const Graphic& rGraphic, const String& rPath, + SvStream& rOStm, sal_uInt16 nFormat = GRFILTER_FORMAT_DONTKNOW, const com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue >* pFilterData = NULL ); long GetExportGraphicHint() const { return nExpGraphHint; } - USHORT CanImportGraphic( const INetURLObject& rPath, - USHORT nFormat = GRFILTER_FORMAT_DONTKNOW, - USHORT * pDeterminedFormat = NULL); + sal_uInt16 CanImportGraphic( const INetURLObject& rPath, + sal_uInt16 nFormat = GRFILTER_FORMAT_DONTKNOW, + sal_uInt16 * pDeterminedFormat = NULL); - USHORT ImportGraphic( Graphic& rGraphic, const INetURLObject& rPath, - USHORT nFormat = GRFILTER_FORMAT_DONTKNOW, - USHORT * pDeterminedFormat = NULL, sal_uInt32 nImportFlags = 0 ); + sal_uInt16 ImportGraphic( Graphic& rGraphic, const INetURLObject& rPath, + sal_uInt16 nFormat = GRFILTER_FORMAT_DONTKNOW, + sal_uInt16 * pDeterminedFormat = NULL, sal_uInt32 nImportFlags = 0 ); - USHORT CanImportGraphic( const String& rPath, SvStream& rStream, - USHORT nFormat = GRFILTER_FORMAT_DONTKNOW, - USHORT * pDeterminedFormat = NULL); + sal_uInt16 CanImportGraphic( const String& rPath, SvStream& rStream, + sal_uInt16 nFormat = GRFILTER_FORMAT_DONTKNOW, + sal_uInt16 * pDeterminedFormat = NULL); - USHORT ImportGraphic( Graphic& rGraphic, const String& rPath, + sal_uInt16 ImportGraphic( Graphic& rGraphic, const String& rPath, SvStream& rStream, - USHORT nFormat = GRFILTER_FORMAT_DONTKNOW, - USHORT * pDeterminedFormat = NULL, sal_uInt32 nImportFlags = 0 ); + sal_uInt16 nFormat = GRFILTER_FORMAT_DONTKNOW, + sal_uInt16 * pDeterminedFormat = NULL, sal_uInt32 nImportFlags = 0 ); - USHORT ImportGraphic( Graphic& rGraphic, const String& rPath, + sal_uInt16 ImportGraphic( Graphic& rGraphic, const String& rPath, SvStream& rStream, - USHORT nFormat, - USHORT * pDeterminedFormat, sal_uInt32 nImportFlags, + sal_uInt16 nFormat, + sal_uInt16 * pDeterminedFormat, sal_uInt32 nImportFlags, com::sun::star::uno::Sequence< com::sun::star::beans::PropertyValue >* pFilterData ); - BOOL Setup( USHORT nFormat ); + sal_Bool Setup( sal_uInt16 nFormat ); - void Abort() { bAbort = TRUE; } + void Abort() { bAbort = sal_True; } const FilterErrorEx& GetLastError() const; void ResetLastError(); @@ -413,15 +413,15 @@ public: static int LoadGraphic( const String& rPath, const String& rFilter, Graphic& rGraphic, GraphicFilter* pFilter = NULL, - USHORT* pDeterminedFormat = NULL ); + sal_uInt16* pDeterminedFormat = NULL ); }; // ------------------------------------ // - Windows Metafile Lesen/Schreiben - // ------------------------------------ -SVT_DLLPUBLIC BOOL ReadWindowMetafile( SvStream& rStream, GDIMetaFile& rMTF, FilterConfigItem* pConfigItem ); -SVT_DLLPUBLIC BOOL WriteWindowMetafile( SvStream& rStream, const GDIMetaFile& rMTF ); -SVT_DLLPUBLIC BOOL WriteWindowMetafileBits( SvStream& rStream, const GDIMetaFile& rMTF ); +SVT_DLLPUBLIC sal_Bool ReadWindowMetafile( SvStream& rStream, GDIMetaFile& rMTF, FilterConfigItem* pConfigItem ); +SVT_DLLPUBLIC sal_Bool WriteWindowMetafile( SvStream& rStream, const GDIMetaFile& rMTF ); +SVT_DLLPUBLIC sal_Bool WriteWindowMetafileBits( SvStream& rStream, const GDIMetaFile& rMTF ); #endif //_FILTER_HXX diff --git a/svtools/inc/svtools/fltcall.hxx b/svtools/inc/svtools/fltcall.hxx index d0bf054d724e..3da14a9a83f9 100644 --- a/svtools/inc/svtools/fltcall.hxx +++ b/svtools/inc/svtools/fltcall.hxx @@ -55,19 +55,19 @@ struct FltCallDialogParameter eFieldUnit ( eFiUni ) {}; }; -typedef BOOL (*PFilterCall)(SvStream & rStream, Graphic & rGraphic, +typedef sal_Bool (*PFilterCall)(SvStream & rStream, Graphic & rGraphic, FilterConfigItem* pConfigItem, sal_Bool bPrefDialog); // Von diesem Typ sind sowohl Export-Filter-Funktionen als auch Import-Filter-Funktionen. // rFileName ist der komplette Pfadname der zu importierenden bzw. zu exportierenden Datei. // pCallBack darf auch NULL sein. pCallerData wird der Callback-Funktion uebergeben. // pOptionsConfig darf NULL sein. Anderenfalls ist die Gruppe des Config schon gesetzt // und darf von dem Filter nicht geaendert werden! - // Wenn bPrefDialog==TRUE gilt, wird ggf. ein Preferences-Dialog durchgefuehrt. + // Wenn bPrefDialog==sal_True gilt, wird ggf. ein Preferences-Dialog durchgefuehrt. -typedef BOOL ( *PFilterDlgCall )( FltCallDialogParameter& ); +typedef sal_Bool ( *PFilterDlgCall )( FltCallDialogParameter& ); // Von diesem Typ sind sowohl Export-Filter-Funktionen als auch Import-Filter-Funktionen. // Uebergeben wird ein Pointer auf ein Parent-Fenster und auf die Options-Config. - // pOptions und pWindow duerfen NULL sein, in diesem Fall wird FALSE zurueckgeliefert. + // pOptions und pWindow duerfen NULL sein, in diesem Fall wird sal_False zurueckgeliefert. // Anderenfalls ist die Gruppe der Config schon gesetzt // und darf von dem Filter nicht geaendert werden! diff --git a/svtools/inc/svtools/fmtfield.hxx b/svtools/inc/svtools/fmtfield.hxx index 9226f78b77fc..c6caf4e89d42 100644 --- a/svtools/inc/svtools/fmtfield.hxx +++ b/svtools/inc/svtools/fmtfield.hxx @@ -44,7 +44,7 @@ namespace validation { class NumberValidator; } #endif -typedef USHORT FORMAT_CHANGE_TYPE; +typedef sal_uInt16 FORMAT_CHANGE_TYPE; #define FCT_KEYONLY 0x00 // only a new key was set #define FCT_FORMATTER 0x01 // a new formatter weas set, usually implies a change of the key, too #define FCT_PRECISION 0x02 // a new precision was set @@ -60,7 +60,7 @@ private: class StaticFormatter { static SvNumberFormatter* s_cFormatter; - static ULONG s_nReferences; + static sal_uIntPtr s_nReferences; public: StaticFormatter(); ~StaticFormatter(); @@ -77,19 +77,19 @@ protected: double m_dMinValue; double m_dMaxValue; - BOOL m_bHasMin : 1; - BOOL m_bHasMax : 1; + sal_Bool m_bHasMin : 1; + sal_Bool m_bHasMax : 1; - BOOL m_bStrictFormat : 1; + sal_Bool m_bStrictFormat : 1; - BOOL m_bValueDirty : 1; - BOOL m_bEnableEmptyField : 1; - BOOL m_bAutoColor : 1; - BOOL m_bEnableNaN : 1; + sal_Bool m_bValueDirty : 1; + sal_Bool m_bEnableEmptyField : 1; + sal_Bool m_bAutoColor : 1; + sal_Bool m_bEnableNaN : 1; double m_dCurrentValue; double m_dDefaultValue; - ULONG m_nFormatKey; + sal_uIntPtr m_nFormatKey; SvNumberFormatter* m_pFormatter; StaticFormatter m_aStaticFormatter; @@ -100,7 +100,7 @@ protected: // es macht einen Unterschied, ob man bei eingestellter Textformatierung beim LostFocus den aktuellen String durch // den Formatter jagt und das Ergebnis anzeigt oder erst aus dem String ein double macht, das formatiert und dann // ausgibt - BOOL m_bTreatAsNumber; + sal_Bool m_bTreatAsNumber; // und mit den folgenden Members koennen wir das Ganze hier auch zur formatierten Text-Ausgabe benutzen ... String m_sCurrentTextValue; String m_sDefaultText; @@ -112,18 +112,18 @@ protected: bool m_bUseInputStringForFormatting; public: - FormattedField(Window* pParent, WinBits nStyle = 0, SvNumberFormatter* pInitialFormatter = NULL, INT32 nFormatKey = 0); - FormattedField(Window* pParent, const ResId& rResId, SvNumberFormatter* pInitialFormatter = NULL, INT32 nFormatKey = 0); + FormattedField(Window* pParent, WinBits nStyle = 0, SvNumberFormatter* pInitialFormatter = NULL, sal_Int32 nFormatKey = 0); + FormattedField(Window* pParent, const ResId& rResId, SvNumberFormatter* pInitialFormatter = NULL, sal_Int32 nFormatKey = 0); virtual ~FormattedField(); // Min-/Max-Verwaltung - BOOL HasMinValue() const { return m_bHasMin; } - void ClearMinValue() { m_bHasMin = FALSE; } + sal_Bool HasMinValue() const { return m_bHasMin; } + void ClearMinValue() { m_bHasMin = sal_False; } void SetMinValue(double dMin); double GetMinValue() const { return m_dMinValue; } - BOOL HasMaxValue() const { return m_bHasMax; } - void ClearMaxValue() { m_bHasMax = FALSE; } + sal_Bool HasMaxValue() const { return m_bHasMax; } + void ClearMaxValue() { m_bHasMax = sal_False; } void SetMaxValue(double dMax); double GetMaxValue() const { return m_dMaxValue; } @@ -137,30 +137,30 @@ public: void SetTextValue(const XubString& rText); // der String wird in ein double umgewandelt (durch den Formatter) und anschliessen in SetValue gesteckt - BOOL IsEmptyFieldEnabled() const { return m_bEnableEmptyField; } - void EnableEmptyField(BOOL bEnable); + sal_Bool IsEmptyFieldEnabled() const { return m_bEnableEmptyField; } + void EnableEmptyField(sal_Bool bEnable); // wenn nicht enabled, wird beim Verlassen des Feldes der Text auf den letzten gueltigen zurueckgesetzt - void SetDefaultValue(double dDefault) { m_dDefaultValue = dDefault; m_bValueDirty = TRUE; } + void SetDefaultValue(double dDefault) { m_dDefaultValue = dDefault; m_bValueDirty = sal_True; } // wenn der aktuelle String ungueltig ist, liefert GetValue() diesen Default-Wert double GetDefaultValue() const { return m_dDefaultValue; } // Einstellungen fuer das Format - ULONG GetFormatKey() const { return m_nFormatKey; } - void SetFormatKey(ULONG nFormatKey); + sal_uIntPtr GetFormatKey() const { return m_nFormatKey; } + void SetFormatKey(sal_uIntPtr nFormatKey); SvNumberFormatter* GetFormatter() const { return m_pFormatter; } - void SetFormatter(SvNumberFormatter* pFormatter, BOOL bResetFormat = TRUE); - // wenn bResetFormat FALSE ist, wird versucht, das alte eingestellte Format mit 'hinueberzuretten' (teuer, wenn es sich nicht + void SetFormatter(SvNumberFormatter* pFormatter, sal_Bool bResetFormat = sal_True); + // wenn bResetFormat sal_False ist, wird versucht, das alte eingestellte Format mit 'hinueberzuretten' (teuer, wenn es sich nicht // um eines der Standard-Formate handelt, die in allen Formattern gleich sind) - // wenn TRUE, wird als neuer FormatKey 0 gesetzt + // wenn sal_True, wird als neuer FormatKey 0 gesetzt - BOOL GetThousandsSep() const; - void SetThousandsSep(BOOL _bUseSeparator); + sal_Bool GetThousandsSep() const; + void SetThousandsSep(sal_Bool _bUseSeparator); // the is no check if the current format is numeric, so be cautious when calling these functions - USHORT GetDecimalDigits() const; - void SetDecimalDigits(USHORT _nPrecision); + sal_uInt16 GetDecimalDigits() const; + void SetDecimalDigits(sal_uInt16 _nPrecision); // the is no check if the current format is numeric, so be cautious when calling these functions SvNumberFormatter* StandardFormatter() { return m_aStaticFormatter; } @@ -169,11 +169,11 @@ public: // also ist etwas Vorsicht angebracht ... void GetFormat(XubString& rFormatString, LanguageType& eLang) const; - BOOL SetFormat(const XubString& rFormatString, LanguageType eLang); - // FALSE, wenn der FormatString nicht gesetzt werden konnte (also wahrscheinlich ungueltig ist) + sal_Bool SetFormat(const XubString& rFormatString, LanguageType eLang); + // sal_False, wenn der FormatString nicht gesetzt werden konnte (also wahrscheinlich ungueltig ist) - BOOL IsStrictFormat() const { return m_bStrictFormat; } - void SetStrictFormat(BOOL bEnable) { m_bStrictFormat = bEnable; } + sal_Bool IsStrictFormat() const { return m_bStrictFormat; } + void SetStrictFormat(sal_Bool bEnable) { m_bStrictFormat = bEnable; } // Formatueberpruefung waehrend der Eingabe ? // Spin-Handling @@ -193,15 +193,15 @@ public: void SetSpinLast(double dLast) { m_dSpinLast = dLast; } double GetSpinLast() const { return m_dSpinLast; } - BOOL TreatingAsNumber() const { return m_bTreatAsNumber; } - void TreatAsNumber(BOOL bDoSo) { m_bTreatAsNumber = bDoSo; } + sal_Bool TreatingAsNumber() const { return m_bTreatAsNumber; } + void TreatAsNumber(sal_Bool bDoSo) { m_bTreatAsNumber = bDoSo; } public: virtual void SetText( const XubString& rStr ); virtual void SetText( const XubString& rStr, const Selection& rNewSelection ); void SetValidateText(const XubString& rText, const String* pErrorText = NULL); - // die folgenden Methoden sind interesant, wenn m_bTreatAsNumber auf FALSE sitzt + // die folgenden Methoden sind interesant, wenn m_bTreatAsNumber auf sal_False sitzt /** nehmen wir mal an, irgendjemand will das ganze schoene double-Handling gar nicht haben, sondern einfach den Text formatiert ausgeben ... (der Text wird einfach nur durch den Formatter gejagt und dann gesetzt) @@ -222,29 +222,29 @@ public: */ void Commit(); - // enable automatic coloring. if set to TRUE, and the format the field is working with for any current value + // enable automatic coloring. if set to sal_True, and the format the field is working with for any current value // says that it has to be painted in a special color (e.g. a format where negative numbers should be printed // red), the text is painted with that color automatically. // The color used is the same as returned by GetLastOutputColor() - void SetAutoColor(BOOL _bAutomatic); - BOOL GetAutoColor() const { return m_bAutoColor; } + void SetAutoColor(sal_Bool _bAutomatic); + sal_Bool GetAutoColor() const { return m_bAutoColor; } /** enables handling of not-a-number value. - When this is set to (the default), then invalid inputs (i.e. text which cannot be + When this is set to (the default), then invalid inputs (i.e. text which cannot be intepreted, according to the current formatting) will be handled as if the default value has been entered. GetValue the will return this default value. - When set to , then GetValue will return NaN (not a number, see isNan) + When set to , then GetValue will return NaN (not a number, see isNan) when the current input is invalid. - Note that setting this to implies that upon leaving the control, the input + Note that setting this to implies that upon leaving the control, the input will *not* be corrected to a valid value. For example, if the user enters "foo" in the control, and then tabs out of it, the text "foo" will persist, and GetValue will return NaN in subsequent calls. */ - void EnableNotANumber( BOOL _bEnable ); - BOOL IsNotANumberEnabled( ) const { return m_bEnableNaN; } + void EnableNotANumber( sal_Bool _bEnable ); + sal_Bool IsNotANumberEnabled( ) const { return m_bEnableNaN; } /** When being set to true, the strings in the field are formatted using the InputLine format. That's also what you get in Calc when you edit a cell @@ -258,16 +258,16 @@ protected: virtual void Modify(); // CheckText ueberschreiben fuer Ueberpruefung zur Eingabezeit - virtual BOOL CheckText(const XubString&) const { return TRUE; } + virtual sal_Bool CheckText(const XubString&) const { return sal_True; } // any aspect of the current format has changed virtual void FormatChanged(FORMAT_CHANGE_TYPE nWhat); void ImplSetTextImpl(const XubString& rNew, Selection* pNewSel); - void ImplSetValue(double dValue, BOOL bForce); - BOOL ImplGetValue(double& dNewVal); + void ImplSetValue(double dValue, sal_Bool bForce); + sal_Bool ImplGetValue(double& dNewVal); - void ImplSetFormatKey(ULONG nFormatKey); + void ImplSetFormatKey(sal_uIntPtr nFormatKey); // SetFormatKey without FormatChanged notification virtual SvNumberFormatter* CreateFormatter() { SetFormatter(StandardFormatter()); return m_pFormatter; } @@ -313,7 +313,7 @@ public: virtual ~DoubleNumericField(); protected: - virtual BOOL CheckText(const XubString& sText) const; + virtual sal_Bool CheckText(const XubString& sText) const; virtual void FormatChanged(FORMAT_CHANGE_TYPE nWhat); void ResetConformanceTester(); @@ -327,8 +327,8 @@ protected: class DoubleCurrencyField : public FormattedField { XubString m_sCurrencySymbol; - BOOL m_bPrependCurrSym; - BOOL m_bChangingFormat; + sal_Bool m_bPrependCurrSym; + sal_Bool m_bChangingFormat; public: DoubleCurrencyField(Window* pParent, WinBits nStyle = 0); @@ -337,8 +337,8 @@ public: XubString getCurrencySymbol() const { return m_sCurrencySymbol; } void setCurrencySymbol(const XubString& _sSymbol); - BOOL getPrependCurrSym() const { return m_bPrependCurrSym; } - void setPrependCurrSym(BOOL _bPrepend); + sal_Bool getPrependCurrSym() const { return m_bPrependCurrSym; } + void setPrependCurrSym(sal_Bool _bPrepend); protected: virtual void FormatChanged(FORMAT_CHANGE_TYPE nWhat); diff --git a/svtools/inc/svtools/generictoolboxcontroller.hxx b/svtools/inc/svtools/generictoolboxcontroller.hxx index 0e9dc73a6882..674429bf2e4d 100644 --- a/svtools/inc/svtools/generictoolboxcontroller.hxx +++ b/svtools/inc/svtools/generictoolboxcontroller.hxx @@ -46,7 +46,7 @@ class SVT_DLLPUBLIC GenericToolboxController : public svt::ToolboxController GenericToolboxController( const com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >& rServiceManager, const com::sun::star::uno::Reference< com::sun::star::frame::XFrame >& rFrame, ToolBox* pToolBox, - USHORT nID, + sal_uInt16 nID, const rtl::OUString& aCommand ); virtual ~GenericToolboxController(); diff --git a/svtools/inc/svtools/genericunodialog.hxx b/svtools/inc/svtools/genericunodialog.hxx index c5fbe5b840e4..9bc02defda44 100644 --- a/svtools/inc/svtools/genericunodialog.hxx +++ b/svtools/inc/svtools/genericunodialog.hxx @@ -164,7 +164,7 @@ namespace svt m_aMutex is locked @return - if and only if m_pDialog is non- upon returning from the method. Note that the only + if and only if m_pDialog is non- upon returning from the method. Note that the only case where m_pDialog is is when createDialog returned , which is will fire an assertion in non-product builds. */ diff --git a/svtools/inc/svtools/grfmgr.hxx b/svtools/inc/svtools/grfmgr.hxx index 3ed608c1525d..e0f2edbe5994 100644 --- a/svtools/inc/svtools/grfmgr.hxx +++ b/svtools/inc/svtools/grfmgr.hxx @@ -104,14 +104,14 @@ private: long mnTopCrop; long mnRightCrop; long mnBottomCrop; - USHORT mnRotate10; + sal_uInt16 mnRotate10; short mnContPercent; short mnLumPercent; short mnRPercent; short mnGPercent; short mnBPercent; - BOOL mbInvert; - BYTE mcTransparency; + sal_Bool mbInvert; + sal_uInt8 mcTransparency; GraphicDrawMode meDrawMode; void* mpDummy; @@ -121,14 +121,14 @@ public: GraphicAttr(); ~GraphicAttr(); - BOOL operator==( const GraphicAttr& rAttr ) const; - BOOL operator!=( const GraphicAttr& rAttr ) const { return !( *this == rAttr ); } + sal_Bool operator==( const GraphicAttr& rAttr ) const; + sal_Bool operator!=( const GraphicAttr& rAttr ) const { return !( *this == rAttr ); } void SetDrawMode( GraphicDrawMode eDrawMode ) { meDrawMode = eDrawMode; } GraphicDrawMode GetDrawMode() const { return meDrawMode; } - void SetMirrorFlags( ULONG nMirrFlags ) { mnMirrFlags = nMirrFlags; } - ULONG GetMirrorFlags() const { return mnMirrFlags; } + void SetMirrorFlags( sal_uIntPtr nMirrFlags ) { mnMirrFlags = nMirrFlags; } + sal_uIntPtr GetMirrorFlags() const { return mnMirrFlags; } void SetCrop( long nLeft_100TH_MM, long nTop_100TH_MM, long nRight_100TH_MM, long nBottom_100TH_MM ) { @@ -140,8 +140,8 @@ public: long GetRightCrop() const { return mnRightCrop; } long GetBottomCrop() const { return mnBottomCrop; } - void SetRotation( USHORT nRotate10 ) { mnRotate10 = nRotate10; } - USHORT GetRotation() const { return mnRotate10; } + void SetRotation( sal_uInt16 nRotate10 ) { mnRotate10 = nRotate10; } + sal_uInt16 GetRotation() const { return mnRotate10; } void SetLuminance( short nLuminancePercent ) { mnLumPercent = nLuminancePercent; } short GetLuminance() const { return mnLumPercent; } @@ -161,22 +161,22 @@ public: void SetGamma( double fGamma ) { mfGamma = fGamma; } double GetGamma() const { return mfGamma; } - void SetInvert( BOOL bInvert ) { mbInvert = bInvert; } - BOOL IsInvert() const { return mbInvert; } + void SetInvert( sal_Bool bInvert ) { mbInvert = bInvert; } + sal_Bool IsInvert() const { return mbInvert; } - void SetTransparency( BYTE cTransparency ) { mcTransparency = cTransparency; } - BYTE GetTransparency() const { return mcTransparency; } + void SetTransparency( sal_uInt8 cTransparency ) { mcTransparency = cTransparency; } + sal_uInt8 GetTransparency() const { return mcTransparency; } - BOOL IsSpecialDrawMode() const { return( meDrawMode != GRAPHICDRAWMODE_STANDARD ); } - BOOL IsMirrored() const { return( mnMirrFlags != 0UL ); } - BOOL IsCropped() const + sal_Bool IsSpecialDrawMode() const { return( meDrawMode != GRAPHICDRAWMODE_STANDARD ); } + sal_Bool IsMirrored() const { return( mnMirrFlags != 0UL ); } + sal_Bool IsCropped() const { return( mnLeftCrop != 0 || mnTopCrop != 0 || mnRightCrop != 0 || mnBottomCrop != 0 ); } - BOOL IsRotated() const { return( ( mnRotate10 % 3600 ) != 0 ); } - BOOL IsTransparent() const { return( mcTransparency > 0 ); } - BOOL IsAdjusted() const + sal_Bool IsRotated() const { return( ( mnRotate10 % 3600 ) != 0 ); } + sal_Bool IsTransparent() const { return( mcTransparency > 0 ); } + sal_Bool IsAdjusted() const { return( mnLumPercent != 0 || mnContPercent != 0 || mnRPercent != 0 || mnGPercent != 0 || mnBPercent != 0 || mfGamma != 1.0 || mbInvert ); @@ -202,7 +202,7 @@ private: GraphicAttr maAttr; Size maPrefSize; MapMode maPrefMapMode; - ULONG mnSizeBytes; + sal_uIntPtr mnSizeBytes; GraphicType meType; GraphicManager* mpMgr; String* mpLink; @@ -210,17 +210,17 @@ private: String* mpUserData; Timer* mpSwapOutTimer; GrfSimpleCacheObj* mpSimpleCache; - ULONG mnAnimationLoopCount; + sal_uIntPtr mnAnimationLoopCount; void* mpDummy1; void* mpDummy2; - BOOL mbAutoSwapped : 1; - BOOL mbTransparent : 1; - BOOL mbAnimated : 1; - BOOL mbEPS : 1; - BOOL mbIsInSwapIn : 1; - BOOL mbIsInSwapOut : 1; - BOOL mbAlpha : 1; - BOOL mbDummyFlag8 : 1; + sal_Bool mbAutoSwapped : 1; + sal_Bool mbTransparent : 1; + sal_Bool mbAnimated : 1; + sal_Bool mbEPS : 1; + sal_Bool mbIsInSwapIn : 1; + sal_Bool mbIsInSwapOut : 1; + sal_Bool mbAlpha : 1; + sal_Bool mbDummyFlag8 : 1; void SVT_DLLPRIVATE ImplConstruct(); void SVT_DLLPRIVATE ImplAssignGraphicData(); @@ -228,9 +228,9 @@ private: const ByteString* pID = NULL, const GraphicObject* pCopyObj = NULL ); void SVT_DLLPRIVATE ImplAutoSwapIn(); - BOOL SVT_DLLPRIVATE ImplIsAutoSwapped() const { return mbAutoSwapped; } - BOOL SVT_DLLPRIVATE ImplGetCropParams( OutputDevice* pOut, Point& rPt, Size& rSz, const GraphicAttr* pAttr, - PolyPolygon& rClipPolyPoly, BOOL& bRectClipRegion ) const; + sal_Bool SVT_DLLPRIVATE ImplIsAutoSwapped() const { return mbAutoSwapped; } + sal_Bool SVT_DLLPRIVATE ImplGetCropParams( OutputDevice* pOut, Point& rPt, Size& rSz, const GraphicAttr* pAttr, + PolyPolygon& rClipPolyPoly, sal_Bool& bRectClipRegion ) const; /** Render a given number of tiles in an optimized way @@ -276,22 +276,22 @@ private: bool SVT_DLLPRIVATE ImplRenderTempTile( VirtualDevice& rVDev, int nExponent, int nNumTilesX, int nNumTilesY, const Size& rTileSizePixel, - const GraphicAttr* pAttr, ULONG nFlags ); + const GraphicAttr* pAttr, sal_uIntPtr nFlags ); /// internally called by ImplRenderTempTile() bool SVT_DLLPRIVATE ImplRenderTileRecursive( VirtualDevice& rVDev, int nExponent, int nMSBFactor, int nNumOrigTilesX, int nNumOrigTilesY, int nRemainderTilesX, int nRemainderTilesY, const Size& rTileSizePixel, const GraphicAttr* pAttr, - ULONG nFlags, ImplTileInfo& rTileInfo ); + sal_uIntPtr nFlags, ImplTileInfo& rTileInfo ); bool SVT_DLLPRIVATE ImplDrawTiled( OutputDevice* pOut, const Rectangle& rArea, const Size& rSizePixel, - const Size& rOffset, const GraphicAttr* pAttr, ULONG nFlags, int nTileCacheSize1D ); + const Size& rOffset, const GraphicAttr* pAttr, sal_uIntPtr nFlags, int nTileCacheSize1D ); bool SVT_DLLPRIVATE ImplDrawTiled( OutputDevice& rOut, const Point& rPos, int nNumTilesX, int nNumTilesY, const Size& rTileSize, - const GraphicAttr* pAttr, ULONG nFlags ); + const GraphicAttr* pAttr, sal_uIntPtr nFlags ); void SVT_DLLPRIVATE ImplTransformBitmap( BitmapEx& rBmpEx, const GraphicAttr& rAttr, @@ -299,7 +299,7 @@ private: const Size& rCropRightBottom, const Rectangle& rCropRect, const Size& rDstSize, - BOOL bEnlarge ) const; + sal_Bool bEnlarge ) const; DECL_LINK( ImplAutoSwapOutHdl, void* ); @@ -309,7 +309,7 @@ protected: virtual SvStream* GetSwapStream() const; // !!! to be removed - virtual ULONG GetReleaseFromCache() const; + virtual sal_uIntPtr GetReleaseFromCache() const; virtual void Load( SvStream& ); virtual void Save( SvStream& ); @@ -327,14 +327,14 @@ public: ~GraphicObject(); GraphicObject& operator=( const GraphicObject& rCacheObj ); - BOOL operator==( const GraphicObject& rCacheObj ) const; - BOOL operator!=( const GraphicObject& rCacheObj ) const { return !( *this == rCacheObj ); } + sal_Bool operator==( const GraphicObject& rCacheObj ) const; + sal_Bool operator!=( const GraphicObject& rCacheObj ) const { return !( *this == rCacheObj ); } - BOOL HasSwapStreamHdl() const { return( mpSwapStreamHdl != NULL && mpSwapStreamHdl->IsSet() ); } + sal_Bool HasSwapStreamHdl() const { return( mpSwapStreamHdl != NULL && mpSwapStreamHdl->IsSet() ); } void SetSwapStreamHdl(); - void SetSwapStreamHdl( const Link& rHdl, const ULONG nSwapOutTimeout = 0UL ); + void SetSwapStreamHdl( const Link& rHdl, const sal_uIntPtr nSwapOutTimeout = 0UL ); Link GetSwapStreamHdl() const; - ULONG GetSwapOutTimeout() const { return( mpSwapOutTimer ? mpSwapOutTimer->GetTimeout() : 0 ); } + sal_uIntPtr GetSwapOutTimeout() const { return( mpSwapOutTimer ? mpSwapOutTimer->GetTimeout() : 0 ); } void FireSwapInRequest(); void FireSwapOutRequest(); @@ -342,8 +342,8 @@ public: void SetGraphicManager( const GraphicManager& rMgr ); GraphicManager& GetGraphicManager() const { return *mpMgr; } - BOOL IsCached( OutputDevice* pOut, const Point& rPt, const Size& rSz, - const GraphicAttr* pAttr = NULL, ULONG nFlags = GRFMGR_DRAW_STANDARD) const; + sal_Bool IsCached( OutputDevice* pOut, const Point& rPt, const Size& rSz, + const GraphicAttr* pAttr = NULL, sal_uIntPtr nFlags = GRFMGR_DRAW_STANDARD) const; void ReleaseFromCache(); const Graphic& GetGraphic() const; @@ -381,12 +381,12 @@ public: void SetAttr( const GraphicAttr& rAttr ); const GraphicAttr& GetAttr() const { return maAttr; } - BOOL HasLink() const { return( mpLink != NULL && mpLink->Len() > 0 ); } + sal_Bool HasLink() const { return( mpLink != NULL && mpLink->Len() > 0 ); } void SetLink(); void SetLink( const String& rLink ); String GetLink() const; - BOOL HasUserData() const { return( mpUserData != NULL && mpUserData->Len() > 0 ); } + sal_Bool HasUserData() const { return( mpUserData != NULL && mpUserData->Len() > 0 ); } void SetUserData(); void SetUserData( const String& rUserData ); String GetUserData() const; @@ -396,36 +396,36 @@ public: GraphicType GetType() const { return meType; } const Size& GetPrefSize() const { return maPrefSize; } const MapMode& GetPrefMapMode() const { return maPrefMapMode; } - ULONG GetSizeBytes() const { return mnSizeBytes; } - ULONG GetChecksum() const; - BOOL IsTransparent() const { return mbTransparent; } - BOOL IsAlpha() const { return mbAlpha; } - BOOL IsAnimated() const { return mbAnimated; } - BOOL IsEPS() const { return mbEPS; } + sal_uIntPtr GetSizeBytes() const { return mnSizeBytes; } + sal_uIntPtr GetChecksum() const; + sal_Bool IsTransparent() const { return mbTransparent; } + sal_Bool IsAlpha() const { return mbAlpha; } + sal_Bool IsAnimated() const { return mbAnimated; } + sal_Bool IsEPS() const { return mbEPS; } void ResetAnimationLoopCount(); List* GetAnimationInfoList() const; Link GetAnimationNotifyHdl() const { return maGraphic.GetAnimationNotifyHdl(); } void SetAnimationNotifyHdl( const Link& rLink ); - BOOL SwapOut(); - BOOL SwapOut( SvStream* pOStm ); - BOOL SwapIn(); - BOOL SwapIn( SvStream* pIStm ); + sal_Bool SwapOut(); + sal_Bool SwapOut( SvStream* pOStm ); + sal_Bool SwapIn(); + sal_Bool SwapIn( SvStream* pIStm ); - BOOL IsInSwapIn() const { return mbIsInSwapIn; } - BOOL IsInSwapOut() const { return mbIsInSwapOut; } - BOOL IsInSwap() const { return( mbIsInSwapOut || mbIsInSwapOut ); } - BOOL IsSwappedOut() const { return( mbAutoSwapped || maGraphic.IsSwapOut() ); } + sal_Bool IsInSwapIn() const { return mbIsInSwapIn; } + sal_Bool IsInSwapOut() const { return mbIsInSwapOut; } + sal_Bool IsInSwap() const { return( mbIsInSwapOut || mbIsInSwapOut ); } + sal_Bool IsSwappedOut() const { return( mbAutoSwapped || maGraphic.IsSwapOut() ); } void SetSwapState(); - BOOL Draw( OutputDevice* pOut, const Point& rPt, const Size& rSz, - const GraphicAttr* pAttr = NULL, ULONG nFlags = GRFMGR_DRAW_STANDARD ); + sal_Bool Draw( OutputDevice* pOut, const Point& rPt, const Size& rSz, + const GraphicAttr* pAttr = NULL, sal_uIntPtr nFlags = GRFMGR_DRAW_STANDARD ); - BOOL DrawWithPDFHandling( OutputDevice& rOutDev, + sal_Bool DrawWithPDFHandling( OutputDevice& rOutDev, const Point& rPt, const Size& rSz, const GraphicAttr* pGrfAttr = NULL, - const ULONG nFlags = GRFMGR_DRAW_STANDARD ); + const sal_uIntPtr nFlags = GRFMGR_DRAW_STANDARD ); /** Draw the graphic repeatedly into the given output rectangle @@ -458,14 +458,14 @@ public: is. This is useful if e.g. you want only a few, very large bitmap drawings appear on the outdev. - @return TRUE, if drawing completed successfully + @return sal_True, if drawing completed successfully */ - BOOL DrawTiled( OutputDevice* pOut, const Rectangle& rArea, const Size& rSize, + sal_Bool DrawTiled( OutputDevice* pOut, const Rectangle& rArea, const Size& rSize, const Size& rOffset, const GraphicAttr* pAttr = NULL, - ULONG nFlags = GRFMGR_DRAW_STANDARD, int nTileCacheSize1D=128 ); + sal_uIntPtr nFlags = GRFMGR_DRAW_STANDARD, int nTileCacheSize1D=128 ); - BOOL StartAnimation( OutputDevice* pOut, const Point& rPt, const Size& rSz, long nExtraData = 0L, - const GraphicAttr* pAttr = NULL, ULONG nFlags = GRFMGR_DRAW_STANDARD, + sal_Bool StartAnimation( OutputDevice* pOut, const Point& rPt, const Size& rSz, long nExtraData = 0L, + const GraphicAttr* pAttr = NULL, sal_uIntPtr nFlags = GRFMGR_DRAW_STANDARD, OutputDevice* pFirstFrameOutDev = NULL ); void StopAnimation( OutputDevice* pOut = NULL, long nExtraData = 0L ); @@ -493,33 +493,33 @@ private: GraphicManager( const GraphicManager& ) {} GraphicManager& operator=( const GraphicManager& ) { return *this; } - BOOL SVT_DLLPRIVATE ImplDraw( OutputDevice* pOut, const Point& rPt, + sal_Bool SVT_DLLPRIVATE ImplDraw( OutputDevice* pOut, const Point& rPt, const Size& rSz, GraphicObject& rObj, const GraphicAttr& rAttr, - const ULONG nFlags, BOOL& rCached ); + const sal_uIntPtr nFlags, sal_Bool& rCached ); - BOOL SVT_DLLPRIVATE ImplCreateOutput( OutputDevice* pOut, const Point& rPt, const Size& rSz, + sal_Bool SVT_DLLPRIVATE ImplCreateOutput( OutputDevice* pOut, const Point& rPt, const Size& rSz, const BitmapEx& rBmpEx, const GraphicAttr& rAttr, - const ULONG nFlags, BitmapEx* pBmpEx = NULL ); - BOOL SVT_DLLPRIVATE ImplCreateOutput( OutputDevice* pOut, + const sal_uIntPtr nFlags, BitmapEx* pBmpEx = NULL ); + sal_Bool SVT_DLLPRIVATE ImplCreateOutput( OutputDevice* pOut, const Point& rPt, const Size& rSz, const GDIMetaFile& rMtf, const GraphicAttr& rAttr, - const ULONG nFlags, GDIMetaFile& rOutMtf, BitmapEx& rOutBmpEx ); + const sal_uIntPtr nFlags, GDIMetaFile& rOutMtf, BitmapEx& rOutBmpEx ); - BOOL SVT_DLLPRIVATE ImplCreateScaled( const BitmapEx& rBmpEx, + sal_Bool SVT_DLLPRIVATE ImplCreateScaled( const BitmapEx& rBmpEx, long* pMapIX, long* pMapFX, long* pMapIY, long* pMapFY, long nStartX, long nEndX, long nStartY, long nEndY, BitmapEx& rOutBmpEx ); - BOOL SVT_DLLPRIVATE ImplCreateRotatedScaled( const BitmapEx& rBmpEx, - USHORT nRot10, const Size& rOutSzPix, const Size& rUntSzPix, + sal_Bool SVT_DLLPRIVATE ImplCreateRotatedScaled( const BitmapEx& rBmpEx, + sal_uInt16 nRot10, const Size& rOutSzPix, const Size& rUntSzPix, long* pMapIX, long* pMapFX, long* pMapIY, long* pMapFY, long nStartX, long nEndX, long nStartY, long nEndY, BitmapEx& rOutBmpEx ); - static void SVT_DLLPRIVATE ImplAdjust( BitmapEx& rBmpEx, const GraphicAttr& rAttr, ULONG nAdjustmentFlags ); - static void SVT_DLLPRIVATE ImplAdjust( GDIMetaFile& rMtf, const GraphicAttr& rAttr, ULONG nAdjustmentFlags ); - static void SVT_DLLPRIVATE ImplAdjust( Animation& rAnimation, const GraphicAttr& rAttr, ULONG nAdjustmentFlags ); + static void SVT_DLLPRIVATE ImplAdjust( BitmapEx& rBmpEx, const GraphicAttr& rAttr, sal_uIntPtr nAdjustmentFlags ); + static void SVT_DLLPRIVATE ImplAdjust( GDIMetaFile& rMtf, const GraphicAttr& rAttr, sal_uIntPtr nAdjustmentFlags ); + static void SVT_DLLPRIVATE ImplAdjust( Animation& rAnimation, const GraphicAttr& rAttr, sal_uIntPtr nAdjustmentFlags ); static void SVT_DLLPRIVATE ImplDraw( OutputDevice* pOut, const Point& rPt, const Size& rSz, const GDIMetaFile& rMtf, const GraphicAttr& rAttr ); @@ -529,42 +529,42 @@ private: const ByteString* pID = NULL, const GraphicObject* pCopyObj = NULL ); void SVT_DLLPRIVATE ImplUnregisterObj( const GraphicObject& rObj ); - inline BOOL SVT_DLLPRIVATE ImplHasObjects() const { return( maObjList.Count() > 0UL ); } + inline sal_Bool SVT_DLLPRIVATE ImplHasObjects() const { return( maObjList.Count() > 0UL ); } // Only used in swap case by GraphicObject void SVT_DLLPRIVATE ImplGraphicObjectWasSwappedOut( const GraphicObject& rObj ); - BOOL SVT_DLLPRIVATE ImplFillSwappedGraphicObject( const GraphicObject& rObj, Graphic& rSubstitute ); + sal_Bool SVT_DLLPRIVATE ImplFillSwappedGraphicObject( const GraphicObject& rObj, Graphic& rSubstitute ); void SVT_DLLPRIVATE ImplGraphicObjectWasSwappedIn( const GraphicObject& rObj ); ByteString SVT_DLLPRIVATE ImplGetUniqueID( const GraphicObject& rObj ) const; public: - GraphicManager( ULONG nCacheSize = 10000000UL, ULONG nMaxObjCacheSize = 2400000UL ); + GraphicManager( sal_uIntPtr nCacheSize = 10000000UL, sal_uIntPtr nMaxObjCacheSize = 2400000UL ); ~GraphicManager(); - void SetMaxCacheSize( ULONG nNewCacheSize ); - ULONG GetMaxCacheSize() const; + void SetMaxCacheSize( sal_uIntPtr nNewCacheSize ); + sal_uIntPtr GetMaxCacheSize() const; - void SetMaxObjCacheSize( ULONG nNewMaxObjSize, BOOL bDestroyGreaterCached = FALSE ); - ULONG GetMaxObjCacheSize() const; + void SetMaxObjCacheSize( sal_uIntPtr nNewMaxObjSize, sal_Bool bDestroyGreaterCached = sal_False ); + sal_uIntPtr GetMaxObjCacheSize() const; - ULONG GetUsedCacheSize() const; - ULONG GetFreeCacheSize() const; + sal_uIntPtr GetUsedCacheSize() const; + sal_uIntPtr GetFreeCacheSize() const; - void SetCacheTimeout( ULONG nTimeoutSeconds ); - ULONG GetCacheTimeout() const; + void SetCacheTimeout( sal_uIntPtr nTimeoutSeconds ); + sal_uIntPtr GetCacheTimeout() const; void ClearCache(); void ReleaseFromCache( const GraphicObject& rObj ); - BOOL IsInCache( OutputDevice* pOut, const Point& rPt, const Size& rSz, + sal_Bool IsInCache( OutputDevice* pOut, const Point& rPt, const Size& rSz, const GraphicObject& rObj, const GraphicAttr& rAttr ) const; - BOOL DrawObj( OutputDevice* pOut, const Point& rPt, const Size& rSz, + sal_Bool DrawObj( OutputDevice* pOut, const Point& rPt, const Size& rSz, GraphicObject& rObj, const GraphicAttr& rAttr, - const ULONG nFlags, BOOL& rCached ); + const sal_uIntPtr nFlags, sal_Bool& rCached ); }; #endif // _GRFMGR_HXX diff --git a/svtools/inc/svtools/headbar.hxx b/svtools/inc/svtools/headbar.hxx index 1ef7687cfb1d..c52d37fb9745 100644 --- a/svtools/inc/svtools/headbar.hxx +++ b/svtools/inc/svtools/headbar.hxx @@ -105,7 +105,7 @@ StartDrag() Dieser Handler wird gerufen, wenn Draggen gestartet wird, bzw. wenn ein Item angeklickt wurde. In diesem Handler sollte spaetestens mit SetDragSize() die Groesse der Size-Linie gesetzt werden, wenn - IsItemMode() FALSE zurueckliefert. + IsItemMode() sal_False zurueckliefert. Drag() Dieser Handler wird gerufen, wenn gedraggt wird. Wenn mit SetDragSize() keine Groesse gesetzt wird, kann dieser Handler dafuer benutzt werden, um die @@ -116,12 +116,12 @@ Drag() Dieser Handler wird gerufen, wenn gedraggt wird. Wenn EndDrag() Dieser Handler wird gerufen, wenn ein Drag-Vorgang beendet wurde. Wenn im EndDrag-Handler GetCurItemId() 0 zurueckliefert, wurde der Drag-Vorgang abgebrochen. - Wenn dies nicht der Fall ist und IsItemMode() FALSE + Wenn dies nicht der Fall ist und IsItemMode() sal_False zurueckliefert, sollte von dem gedraggten Item die neue Groesse mit GetItemSize() abgefragt werden und entsprechend im dazugehoerigem Control uebernommen - werden. Wenn IsItemMode() TRUE, GetCurItemId() eine Id - und IsItemDrag() TRUE zurueckliefert, wurde dieses + werden. Wenn IsItemMode() sal_True, GetCurItemId() eine Id + und IsItemDrag() sal_True zurueckliefert, wurde dieses Item verschoben. Es sollte dann mit GetItemPos() die neue Position abgefragt werden und auch die Daten im dazugehoerigem Control angepasst werden. Ansonsten @@ -143,12 +143,12 @@ GetItemDragPos() Liefert die Position zurueck, an der ein Item verschoben oder wenn kein ItemDrag aktiv ist. IsItemMode() Mit dieser Methode kann abgefragt werden, ob fuer ein Item oder einen Trenner der Handler gerufen wurde. - TRUE - Handler wurde fuer das Item gerufen - FALSE - Handler wurde fuer den Trenner gerufen + sal_True - Handler wurde fuer das Item gerufen + sal_False - Handler wurde fuer den Trenner gerufen IsItemDrag() Mit dieser Methode kann abgefragt werden, ob ein Item gedragt oder selektiert wurde. - TRUE - Item wird verschoben - FALSE - Item wird selektiert + sal_True - Item wird verschoben + sal_False - Item wird selektiert SetDragSize() Mit dieser Methode wird gesetzt, wir gross der Trennstrich sein soll, der vom Control gemalt wird. Dies sollte so gross sein, wie das angrenzende Fenster @@ -200,7 +200,7 @@ class ImplHeadItemList; // - HeaderBarItemBits - // --------------------- -typedef USHORT HeaderBarItemBits; +typedef sal_uInt16 HeaderBarItemBits; // ---------------------------- // - Bits fuer HeaderBarItems - @@ -227,8 +227,8 @@ typedef USHORT HeaderBarItemBits; // - HeaderBar-Types - // ------------------- -#define HEADERBAR_APPEND ((USHORT)0xFFFF) -#define HEADERBAR_ITEM_NOTFOUND ((USHORT)0xFFFF) +#define HEADERBAR_APPEND ((sal_uInt16)0xFFFF) +#define HEADERBAR_ITEM_NOTFOUND ((sal_uInt16)0xFFFF) #define HEADERBAR_FULLSIZE ((long)1000000000) #define HEADERBAR_TEXTOFF 2 @@ -250,14 +250,14 @@ private: long mnStartPos; long mnDragPos; long mnMouseOff; - USHORT mnCurItemId; - USHORT mnItemDragPos; - BOOL mbDragable; - BOOL mbDrag; - BOOL mbItemDrag; - BOOL mbOutDrag; - BOOL mbButtonStyle; - BOOL mbItemMode; + sal_uInt16 mnCurItemId; + sal_uInt16 mnItemDragPos; + sal_Bool mbDragable; + sal_Bool mbDrag; + sal_Bool mbItemDrag; + sal_Bool mbOutDrag; + sal_Bool mbButtonStyle; + sal_Bool mbItemMode; Link maStartDragHdl; Link maDragHdl; Link maEndDragHdl; @@ -272,25 +272,25 @@ private: #ifdef _SV_HEADBAR_CXX using Window::ImplInit; SVT_DLLPRIVATE void ImplInit( WinBits nWinStyle ); - SVT_DLLPRIVATE void ImplInitSettings( BOOL bFont, BOOL bForeground, BOOL bBackground ); - SVT_DLLPRIVATE long ImplGetItemPos( USHORT nPos ) const; - SVT_DLLPRIVATE Rectangle ImplGetItemRect( USHORT nPos ) const; + SVT_DLLPRIVATE void ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal_Bool bBackground ); + SVT_DLLPRIVATE long ImplGetItemPos( sal_uInt16 nPos ) const; + SVT_DLLPRIVATE Rectangle ImplGetItemRect( sal_uInt16 nPos ) const; using Window::ImplHitTest; - SVT_DLLPRIVATE USHORT ImplHitTest( const Point& rPos, long& nMouseOff, USHORT& nPos ) const; - SVT_DLLPRIVATE void ImplInvertDrag( USHORT nStartPos, USHORT nEndPos ); + SVT_DLLPRIVATE sal_uInt16 ImplHitTest( const Point& rPos, long& nMouseOff, sal_uInt16& nPos ) const; + SVT_DLLPRIVATE void ImplInvertDrag( sal_uInt16 nStartPos, sal_uInt16 nEndPos ); SVT_DLLPRIVATE void ImplDrawItem( OutputDevice* pDev, - USHORT nPos, BOOL bHigh, BOOL bDrag, + sal_uInt16 nPos, sal_Bool bHigh, sal_Bool bDrag, const Rectangle& rItemRect, const Rectangle* pRect, - ULONG nFlags ); - SVT_DLLPRIVATE void ImplDrawItem( USHORT nPos, BOOL bHigh = FALSE, - BOOL bDrag = FALSE, + sal_uIntPtr nFlags ); + SVT_DLLPRIVATE void ImplDrawItem( sal_uInt16 nPos, sal_Bool bHigh = sal_False, + sal_Bool bDrag = sal_False, const Rectangle* pRect = NULL ); - SVT_DLLPRIVATE void ImplUpdate( USHORT nPos, - BOOL bEnd = FALSE, BOOL bDirect = FALSE ); - SVT_DLLPRIVATE void ImplStartDrag( const Point& rPos, BOOL bCommand ); + SVT_DLLPRIVATE void ImplUpdate( sal_uInt16 nPos, + sal_Bool bEnd = sal_False, sal_Bool bDirect = sal_False ); + SVT_DLLPRIVATE void ImplStartDrag( const Point& rPos, sal_Bool bCommand ); SVT_DLLPRIVATE void ImplDrag( const Point& rPos ); - SVT_DLLPRIVATE void ImplEndDrag( BOOL bCancel ); + SVT_DLLPRIVATE void ImplEndDrag( sal_Bool bCancel ); #endif public: @@ -302,7 +302,7 @@ public: virtual void MouseMove( const MouseEvent& rMEvt ); virtual void Tracking( const TrackingEvent& rTEvt ); virtual void Paint( const Rectangle& rRect ); - virtual void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, ULONG nFlags ); + virtual void Draw( OutputDevice* pDev, const Point& rPos, const Size& rSize, sal_uIntPtr nFlags ); virtual void Resize(); virtual void Command( const CommandEvent& rCEvt ); virtual void RequestHelp( const HelpEvent& rHEvt ); @@ -316,18 +316,18 @@ public: virtual void Select(); virtual void DoubleClick(); - void InsertItem( USHORT nItemId, const Image& rImage, + void InsertItem( sal_uInt16 nItemId, const Image& rImage, long nSize, HeaderBarItemBits nBits = HIB_STDSTYLE, - USHORT nPos = HEADERBAR_APPEND ); - void InsertItem( USHORT nItemId, const XubString& rText, + sal_uInt16 nPos = HEADERBAR_APPEND ); + void InsertItem( sal_uInt16 nItemId, const XubString& rText, long nSize, HeaderBarItemBits nBits = HIB_STDSTYLE, - USHORT nPos = HEADERBAR_APPEND ); - void InsertItem( USHORT nItemId, + sal_uInt16 nPos = HEADERBAR_APPEND ); + void InsertItem( sal_uInt16 nItemId, const Image& rImage, const XubString& rText, long nSize, HeaderBarItemBits nBits = HIB_STDSTYLE, - USHORT nPos = HEADERBAR_APPEND ); - void RemoveItem( USHORT nItemId ); - void MoveItem( USHORT nItemId, USHORT nNewPos ); + sal_uInt16 nPos = HEADERBAR_APPEND ); + void RemoveItem( sal_uInt16 nItemId ); + void MoveItem( sal_uInt16 nItemId, sal_uInt16 nNewPos ); void Clear(); void SetOffset( long nNewOffset = 0 ); @@ -335,40 +335,40 @@ public: inline void SetDragSize( long nNewSize = 0 ) { mnDragSize = nNewSize; } long GetDragSize() const { return mnDragSize; } - USHORT GetItemCount() const; - USHORT GetItemPos( USHORT nItemId ) const; - USHORT GetItemId( USHORT nPos ) const; - USHORT GetItemId( const Point& rPos ) const; - Rectangle GetItemRect( USHORT nItemId ) const; - USHORT GetCurItemId() const { return mnCurItemId; } + sal_uInt16 GetItemCount() const; + sal_uInt16 GetItemPos( sal_uInt16 nItemId ) const; + sal_uInt16 GetItemId( sal_uInt16 nPos ) const; + sal_uInt16 GetItemId( const Point& rPos ) const; + Rectangle GetItemRect( sal_uInt16 nItemId ) const; + sal_uInt16 GetCurItemId() const { return mnCurItemId; } long GetDragPos() const { return mnDragPos; } - USHORT GetItemDragPos() const { return mnItemDragPos; } - BOOL IsItemMode() const { return mbItemMode; } - BOOL IsItemDrag() const { return mbItemDrag; } - - void SetItemSize( USHORT nItemId, long nNewSize ); - long GetItemSize( USHORT nItemId ) const; - void SetItemBits( USHORT nItemId, HeaderBarItemBits nNewBits ); - HeaderBarItemBits GetItemBits( USHORT nItemId ) const; - void SetItemData( USHORT nItemId, void* pNewData ); - void* GetItemData( USHORT nItemId ) const; - - void SetItemImage( USHORT nItemId, const Image& rImage ); - Image GetItemImage( USHORT nItemId ) const; - void SetItemText( USHORT nItemId, const XubString& rText ); - XubString GetItemText( USHORT nItemId ) const; - - void SetHelpText( USHORT nItemId, const XubString& rText ); - XubString GetHelpText( USHORT nItemId ) const; - void SetHelpId( USHORT nItemId, ULONG nHelpId ); - ULONG GetHelpId( USHORT nItemId ) const; + sal_uInt16 GetItemDragPos() const { return mnItemDragPos; } + sal_Bool IsItemMode() const { return mbItemMode; } + sal_Bool IsItemDrag() const { return mbItemDrag; } + + void SetItemSize( sal_uInt16 nItemId, long nNewSize ); + long GetItemSize( sal_uInt16 nItemId ) const; + void SetItemBits( sal_uInt16 nItemId, HeaderBarItemBits nNewBits ); + HeaderBarItemBits GetItemBits( sal_uInt16 nItemId ) const; + void SetItemData( sal_uInt16 nItemId, void* pNewData ); + void* GetItemData( sal_uInt16 nItemId ) const; + + void SetItemImage( sal_uInt16 nItemId, const Image& rImage ); + Image GetItemImage( sal_uInt16 nItemId ) const; + void SetItemText( sal_uInt16 nItemId, const XubString& rText ); + XubString GetItemText( sal_uInt16 nItemId ) const; + + void SetHelpText( sal_uInt16 nItemId, const XubString& rText ); + XubString GetHelpText( sal_uInt16 nItemId ) const; + void SetHelpId( sal_uInt16 nItemId, sal_uIntPtr nHelpId ); + sal_uIntPtr GetHelpId( sal_uInt16 nItemId ) const; Size CalcWindowSizePixel() const; inline void SetHelpText( const String& rText ) { Window::SetHelpText( rText ); } inline const String& GetHelpText() const { return Window::GetHelpText(); } - inline void SetHelpId( ULONG nId ) { Window::SetHelpId( nId ); } - inline ULONG GetHelpId() const { return Window::GetHelpId(); } + inline void SetHelpId( sal_uIntPtr nId ) { Window::SetHelpId( nId ); } + inline sal_uIntPtr GetHelpId() const { return Window::GetHelpId(); } inline void SetStartDragHdl( const Link& rLink ) { maStartDragHdl = rLink; } inline const Link& GetStartDragHdl() const { return maStartDragHdl; } @@ -383,7 +383,7 @@ public: inline void SetCreateAccessibleHdl( const Link& rLink ) { maCreateAccessibleHdl = rLink; } inline const Link& GetCreateAccessibleHdl() const { return maCreateAccessibleHdl; } - inline BOOL IsDragable() const { return mbDragable; } + inline sal_Bool IsDragable() const { return mbDragable; } /** Creates and returns the accessible object of the header bar. */ virtual ::com::sun::star::uno::Reference< diff --git a/svtools/inc/svtools/htmlcfg.hxx b/svtools/inc/svtools/htmlcfg.hxx index c27df0a9a67f..7778ffacfd7b 100644 --- a/svtools/inc/svtools/htmlcfg.hxx +++ b/svtools/inc/svtools/htmlcfg.hxx @@ -64,37 +64,37 @@ public: virtual void Commit(); virtual void Notify( const com::sun::star::uno::Sequence< rtl::OUString >& _rPropertyNames); - USHORT GetFontSize(USHORT nPos) const; - void SetFontSize(USHORT nPos, USHORT nSize); + sal_uInt16 GetFontSize(sal_uInt16 nPos) const; + void SetFontSize(sal_uInt16 nPos, sal_uInt16 nSize); - BOOL IsImportUnknown() const; - void SetImportUnknown(BOOL bSet); + sal_Bool IsImportUnknown() const; + void SetImportUnknown(sal_Bool bSet); - USHORT GetExportMode() const; - void SetExportMode(USHORT nSet); + sal_uInt16 GetExportMode() const; + void SetExportMode(sal_uInt16 nSet); - BOOL IsStarBasic() const; - void SetStarBasic(BOOL bSet); + sal_Bool IsStarBasic() const; + void SetStarBasic(sal_Bool bSet); - BOOL IsStarBasicWarning() const; - void SetStarBasicWarning(BOOL bSet); + sal_Bool IsStarBasicWarning() const; + void SetStarBasicWarning(sal_Bool bSet); - BOOL IsSaveGraphicsLocal() const; - void SetSaveGraphicsLocal(BOOL bSet); + sal_Bool IsSaveGraphicsLocal() const; + void SetSaveGraphicsLocal(sal_Bool bSet); - BOOL IsPrintLayoutExtension() const; - void SetPrintLayoutExtension(BOOL bSet); + sal_Bool IsPrintLayoutExtension() const; + void SetPrintLayoutExtension(sal_Bool bSet); - BOOL IsIgnoreFontFamily() const; - void SetIgnoreFontFamily(BOOL bSet); + sal_Bool IsIgnoreFontFamily() const; + void SetIgnoreFontFamily(sal_Bool bSet); sal_Bool IsDefaultTextEncoding() const; rtl_TextEncoding GetTextEncoding() const; void SetTextEncoding( rtl_TextEncoding ); static SvxHtmlOptions* Get(); - BOOL IsNumbersEnglishUS() const; - void SetNumbersEnglishUS(BOOL bSet); + sal_Bool IsNumbersEnglishUS() const; + void SetNumbersEnglishUS(sal_Bool bSet); void AddListenerLink( const Link& rLink ); void RemoveListenerLink( const Link& rLink ); diff --git a/svtools/inc/svtools/htmlout.hxx b/svtools/inc/svtools/htmlout.hxx index 888286b231ee..b7177bfc8fd2 100644 --- a/svtools/inc/svtools/htmlout.hxx +++ b/svtools/inc/svtools/htmlout.hxx @@ -45,7 +45,7 @@ struct HTMLOutEvent { const sal_Char *pBasicName; const sal_Char *pJavaName; - USHORT nEvent; + sal_uInt16 nEvent; }; struct SVT_DLLPUBLIC HTMLOutContext @@ -71,7 +71,7 @@ struct HTMLOutFuncs String *pNonConvertableChars = 0); SVT_DLLPUBLIC static SvStream& Out_AsciiTag( SvStream&, const sal_Char* pStr, - BOOL bOn = TRUE, + sal_Bool bOn = sal_True, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252); SVT_DLLPUBLIC static SvStream& Out_Char( SvStream&, sal_Unicode cChar, HTMLOutContext& rContext, @@ -79,13 +79,13 @@ struct HTMLOutFuncs SVT_DLLPUBLIC static SvStream& Out_String( SvStream&, const String&, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252, String *pNonConvertableChars = 0 ); - SVT_DLLPUBLIC static SvStream& Out_Hex( SvStream&, ULONG nHex, BYTE nLen, + SVT_DLLPUBLIC static SvStream& Out_Hex( SvStream&, sal_uIntPtr nHex, sal_uInt8 nLen, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252 ); SVT_DLLPUBLIC static SvStream& Out_Color( SvStream&, const Color&, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252 ); SVT_DLLPUBLIC static SvStream& Out_ImageMap( SvStream&, const String&, const ImageMap&, const String&, const HTMLOutEvent *pEventTable, - BOOL bOutStarBasic, + sal_Bool bOutStarBasic, const sal_Char *pDelim = 0, const sal_Char *pIndentArea = 0, const sal_Char *pIndentMap = 0, @@ -107,18 +107,18 @@ struct HTMLOutFuncs // der 3. Parameter ist ein Array von HTMLOutEvents, das mit einem // nur aus 0 bestehen Eintrag terminiert ist. SVT_DLLPUBLIC static SvStream& Out_Events( SvStream&, const SvxMacroTableDtor&, - const HTMLOutEvent*, BOOL bOutStarBasic, + const HTMLOutEvent*, sal_Bool bOutStarBasic, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252, String *pNonConvertableChars = 0 ); // SVT_DLLPUBLIC static ByteString& CreateTableDataOptionsValNum( ByteString& aStrTD, - BOOL bValue, double fVal, ULONG nFormat, + sal_Bool bValue, double fVal, sal_uIntPtr nFormat, SvNumberFormatter& rFormatter, rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252, String *pNonConvertableChars = 0 ); - SVT_DLLPUBLIC static BOOL PrivateURLToInternalImg( String& rURL ); + SVT_DLLPUBLIC static sal_Bool PrivateURLToInternalImg( String& rURL ); }; #endif diff --git a/svtools/inc/svtools/imap.hxx b/svtools/inc/svtools/imap.hxx index 52212e365c87..6e3093cb3b57 100644 --- a/svtools/inc/svtools/imap.hxx +++ b/svtools/inc/svtools/imap.hxx @@ -53,13 +53,13 @@ protected: // Binaer laden/speichern void ImpWriteImageMap( SvStream& rOStm, const String& ) const ; - void ImpReadImageMap( SvStream& rIStm, USHORT nCount, const String& ); + void ImpReadImageMap( SvStream& rIStm, sal_uInt16 nCount, const String& ); // Im-/Export void ImpWriteCERN( SvStream& rOStm, const String& rBaseURL ) const; void ImpWriteNCSA( SvStream& rOStm, const String& rBaseURL ) const; - ULONG ImpReadCERN( SvStream& rOStm, const String& rBaseURL ); - ULONG ImpReadNCSA( SvStream& rOStm, const String& rBaseURL ); + sal_uIntPtr ImpReadCERN( SvStream& rOStm, const String& rBaseURL ); + sal_uIntPtr ImpReadNCSA( SvStream& rOStm, const String& rBaseURL ); void ImpReadCERNLine( const ByteString& rLine, const String& rBaseURL ); Point ImpReadCERNCoords( const char** ppStr ); @@ -70,7 +70,7 @@ protected: String ImpReadNCSAURL( const char** ppStr, const String& rBaseURL ); Point ImpReadNCSACoords( const char** ppStr ); - ULONG ImpDetectFormat( SvStream& rIStm ); + sal_uIntPtr ImpDetectFormat( SvStream& rIStm ); public: @@ -89,8 +89,8 @@ public: ImageMap& operator=( const ImageMap& rImageMap ); // Vergleichsoperator (es wird alles auf Gleichheit geprueft) - BOOL operator==( const ImageMap& rImageMap ); - BOOL operator!=( const ImageMap& rImageMap ); + sal_Bool operator==( const ImageMap& rImageMap ); + sal_Bool operator!=( const ImageMap& rImageMap ); // In die Map wird ein neues IMap-Obkekt ans Ende eingefuegt void InsertIMapObject( const IMapObject& rIMapObject ); @@ -101,7 +101,7 @@ public: IMapObject* GetNextIMapObject() { return (IMapObject*) maList.Next(); } IMapObject* GetLastIMapObject() { return (IMapObject*) maList.Last(); } IMapObject* GetPrevIMapObject() { return (IMapObject*) maList.Prev(); } - IMapObject* GetIMapObject( USHORT nPos ) const { return (IMapObject*) maList.GetObject( nPos ); } + IMapObject* GetIMapObject( sal_uInt16 nPos ) const { return (IMapObject*) maList.GetObject( nPos ); } // Gibt das Objekt zurueck, das zuerst getroffen wurde oder NULL; // Groessen- und Positionsangaben sind in 1/100mm; @@ -112,16 +112,16 @@ public: IMapObject* GetHitIMapObject( const Size& rOriginalSize, const Size& rDisplaySize, const Point& rRelHitPoint, - ULONG nFlags = 0 ); + sal_uIntPtr nFlags = 0 ); // Gibt die Gesamtanzahl der IMap-Objekte zurueck - UINT16 GetIMapObjectCount() const { return (UINT16) maList.Count(); } + sal_uInt16 GetIMapObjectCount() const { return (sal_uInt16) maList.Count(); } // Loescht alle internen Objekte void ClearImageMap(); // liefert die aktuelle Versionsnummer - UINT16 GetVersion() const; + sal_uInt16 GetVersion() const; // liefert / setzt den Namen der ImageMap const String& GetName() const { return aName; } @@ -137,8 +137,8 @@ public: void Write ( SvStream& rOStm, const String& rBaseURL ) const; void Read( SvStream& rIStm, const String& rBaseURL ); - void Write( SvStream& rOStm, ULONG nFormat, const String& rBaseURL ) const; - ULONG Read( SvStream& rIStm, ULONG nFormat, const String& rBaseURL ); + void Write( SvStream& rOStm, sal_uIntPtr nFormat, const String& rBaseURL ) const; + sal_uIntPtr Read( SvStream& rIStm, sal_uIntPtr nFormat, const String& rBaseURL ); }; /****************************************************************************** @@ -152,18 +152,18 @@ public: class IMapCompat { SvStream* pRWStm; - ULONG nCompatPos; - ULONG nTotalSize; - USHORT nStmMode; + sal_uIntPtr nCompatPos; + sal_uIntPtr nTotalSize; + sal_uInt16 nStmMode; IMapCompat() {} IMapCompat( const IMapCompat& ) {} IMapCompat& operator=( const IMapCompat& ) { return *this; } - BOOL operator==( const IMapCompat& ) { return FALSE; } + sal_Bool operator==( const IMapCompat& ) { return sal_False; } public: - IMapCompat( SvStream& rStm, const USHORT nStreamMode ); + IMapCompat( SvStream& rStm, const sal_uInt16 nStreamMode ); ~IMapCompat(); }; diff --git a/svtools/inc/svtools/imapcirc.hxx b/svtools/inc/svtools/imapcirc.hxx index e3ea5349d376..82afdb217490 100644 --- a/svtools/inc/svtools/imapcirc.hxx +++ b/svtools/inc/svtools/imapcirc.hxx @@ -42,9 +42,9 @@ class Fraction; class SVT_DLLPUBLIC IMapCircleObject : public IMapObject { Point aCenter; - ULONG nRadius; + sal_uIntPtr nRadius; - void ImpConstruct( const Point& rCenter, ULONG nRad, BOOL bPixel ); + void ImpConstruct( const Point& rCenter, sal_uIntPtr nRad, sal_Bool bPixel ); protected: @@ -55,21 +55,21 @@ protected: public: IMapCircleObject() {}; - IMapCircleObject( const Point& rCenter, ULONG nRad, + IMapCircleObject( const Point& rCenter, sal_uIntPtr nRad, const String& rURL, const String& rAltText, const String& rDesc, const String& rTarget, const String& rName, - BOOL bActive = TRUE, - BOOL bPixelCoords = TRUE ); + sal_Bool bActive = sal_True, + sal_Bool bPixelCoords = sal_True ); virtual ~IMapCircleObject() {}; - virtual UINT16 GetType() const; - virtual BOOL IsHit( const Point& rPoint ) const; + virtual sal_uInt16 GetType() const; + virtual sal_Bool IsHit( const Point& rPoint ) const; - Point GetCenter( BOOL bPixelCoords = TRUE ) const; - ULONG GetRadius( BOOL bPixelCoords = TRUE ) const; + Point GetCenter( sal_Bool bPixelCoords = sal_True ) const; + sal_uIntPtr GetRadius( sal_Bool bPixelCoords = sal_True ) const; // liefert das BoundRect des Kreis-Objektes in 1/100mm virtual Rectangle GetBoundRect() const; @@ -77,7 +77,7 @@ public: void Scale( const Fraction& rFractX, const Fraction& rFracY ); using IMapObject::IsEqual; - BOOL IsEqual( const IMapCircleObject& rEqObj ); + sal_Bool IsEqual( const IMapCircleObject& rEqObj ); // Im-/Export void WriteCERN( SvStream& rOStm, const String& rBaseURL ) const; diff --git a/svtools/inc/svtools/imapobj.hxx b/svtools/inc/svtools/imapobj.hxx index c557727124cc..42e6b1740b70 100644 --- a/svtools/inc/svtools/imapobj.hxx +++ b/svtools/inc/svtools/imapobj.hxx @@ -36,13 +36,13 @@ class Point; class Rectangle; class SvStream; -#define IMAP_OBJ_NONE ((UINT16)0x0000) -#define IMAP_OBJ_RECTANGLE ((UINT16)0x0001) -#define IMAP_OBJ_CIRCLE ((UINT16)0x0002) -#define IMAP_OBJ_POLYGON ((UINT16)0x0003) -#define IMAP_OBJ_VERSION ((UINT16)0x0005) +#define IMAP_OBJ_NONE ((sal_uInt16)0x0000) +#define IMAP_OBJ_RECTANGLE ((sal_uInt16)0x0001) +#define IMAP_OBJ_CIRCLE ((sal_uInt16)0x0002) +#define IMAP_OBJ_POLYGON ((sal_uInt16)0x0003) +#define IMAP_OBJ_VERSION ((sal_uInt16)0x0005) -#define IMAGE_MAP_VERSION ((UINT16)0x0001) +#define IMAGE_MAP_VERSION ((sal_uInt16)0x0001) #define IMAPMAGIC "SDIMAP" @@ -73,11 +73,11 @@ class SVT_DLLPUBLIC IMapObject String aTarget; String aName; SvxMacroTableDtor aEventList; - BOOL bActive; + sal_Bool bActive; protected: - UINT16 nReadVersion; + sal_uInt16 nReadVersion; // Binaer-Im-/Export virtual void WriteIMapObject( SvStream& rOStm ) const = 0; @@ -99,12 +99,12 @@ public: const String& rDesc, const String& rTarget, const String& rName, - BOOL bActive ); + sal_Bool bActive ); virtual ~IMapObject() {}; - virtual UINT16 GetVersion() const; - virtual UINT16 GetType() const = 0; - virtual BOOL IsHit( const Point& rPoint ) const = 0; + virtual sal_uInt16 GetVersion() const; + virtual sal_uInt16 GetType() const = 0; + virtual sal_Bool IsHit( const Point& rPoint ) const = 0; void Write ( SvStream& rOStm, const String& rBaseURL ) const; void Read( SvStream& rIStm, const String& rBaseURL ); @@ -126,33 +126,33 @@ public: const String& GetName() const { return aName; } void SetName( const String& rName ) { aName = rName; } - BOOL IsActive() const { return bActive; } - void SetActive( BOOL bSetActive = TRUE ) { bActive = bSetActive; } + sal_Bool IsActive() const { return bActive; } + void SetActive( sal_Bool bSetActive = sal_True ) { bActive = bSetActive; } static Point GetPixelPoint( const Point& rLogPoint ); static Point GetLogPoint( const Point& rPixelPoint ); - BOOL IsEqual( const IMapObject& rEqObj ); + sal_Bool IsEqual( const IMapObject& rEqObj ); // IMap-Events inline const SvxMacroTableDtor& GetMacroTable() const { return aEventList;} inline void SetMacroTable( const SvxMacroTableDtor& rTbl ) { aEventList = rTbl; } - inline const SvxMacro& GetEvent( USHORT nEvent ) const; - inline BOOL HasEvent( USHORT nEvent ) const; - void SetEvent( USHORT nEvent, const SvxMacro& ); - inline BOOL DelEvent( USHORT nEvent ); + inline const SvxMacro& GetEvent( sal_uInt16 nEvent ) const; + inline sal_Bool HasEvent( sal_uInt16 nEvent ) const; + void SetEvent( sal_uInt16 nEvent, const SvxMacro& ); + inline sal_Bool DelEvent( sal_uInt16 nEvent ); }; -inline BOOL IMapObject::HasEvent( USHORT nEvent ) const +inline sal_Bool IMapObject::HasEvent( sal_uInt16 nEvent ) const { return aEventList.IsKeyValid( nEvent ); } -inline const SvxMacro& IMapObject::GetEvent( USHORT nEvent ) const +inline const SvxMacro& IMapObject::GetEvent( sal_uInt16 nEvent ) const { return *(aEventList.Get( nEvent )); } -inline BOOL IMapObject::DelEvent( USHORT nEvent ) +inline sal_Bool IMapObject::DelEvent( sal_uInt16 nEvent ) { SvxMacro *pMacro = aEventList.Remove( nEvent ); delete pMacro; diff --git a/svtools/inc/svtools/imappoly.hxx b/svtools/inc/svtools/imappoly.hxx index 00d22cbe2de0..e6d31f78597a 100644 --- a/svtools/inc/svtools/imappoly.hxx +++ b/svtools/inc/svtools/imappoly.hxx @@ -44,9 +44,9 @@ class SVT_DLLPUBLIC IMapPolygonObject : public IMapObject { Polygon aPoly; Rectangle aEllipse; - BOOL bEllipse; + sal_Bool bEllipse; - SVT_DLLPRIVATE void ImpConstruct( const Polygon& rPoly, BOOL bPixel ); + SVT_DLLPRIVATE void ImpConstruct( const Polygon& rPoly, sal_Bool bPixel ); protected: @@ -54,7 +54,7 @@ protected: virtual void WriteIMapObject( SvStream& rOStm ) const; virtual void ReadIMapObject( SvStream& rIStm ); - BOOL ReadPreProLine( SvStream& rIStm, String& rStr ); + sal_Bool ReadPreProLine( SvStream& rIStm, String& rStr ); public: IMapPolygonObject() {}; @@ -64,26 +64,26 @@ public: const String& rDesc, const String& rTarget, const String& rName, - BOOL bActive = TRUE, - BOOL bPixelCoords = TRUE ); + sal_Bool bActive = sal_True, + sal_Bool bPixelCoords = sal_True ); virtual ~IMapPolygonObject() {}; - virtual UINT16 GetType() const; - virtual BOOL IsHit( const Point& rPoint ) const; + virtual sal_uInt16 GetType() const; + virtual sal_Bool IsHit( const Point& rPoint ) const; - Polygon GetPolygon( BOOL bPixelCoords = TRUE ) const; + Polygon GetPolygon( sal_Bool bPixelCoords = sal_True ) const; // liefert das BoundRect des Polygon-Objektes in 1/100mm virtual Rectangle GetBoundRect() const { return aPoly.GetBoundRect(); } - BOOL HasExtraEllipse() const { return bEllipse; } + sal_Bool HasExtraEllipse() const { return bEllipse; } const Rectangle& GetExtraEllipse() const { return aEllipse; } void SetExtraEllipse( const Rectangle& rEllipse ); void Scale( const Fraction& rFractX, const Fraction& rFracY ); using IMapObject::IsEqual; - BOOL IsEqual( const IMapPolygonObject& rEqObj ); + sal_Bool IsEqual( const IMapPolygonObject& rEqObj ); // Im-/Export void WriteCERN( SvStream& rOStm, const String& rBaseURL ) const; diff --git a/svtools/inc/svtools/imaprect.hxx b/svtools/inc/svtools/imaprect.hxx index 8eacaaaf3531..3e6d80f52bef 100644 --- a/svtools/inc/svtools/imaprect.hxx +++ b/svtools/inc/svtools/imaprect.hxx @@ -43,7 +43,7 @@ class SVT_DLLPUBLIC IMapRectangleObject : public IMapObject { Rectangle aRect; - SVT_DLLPRIVATE void ImpConstruct( const Rectangle& rRect, BOOL bPixel ); + SVT_DLLPRIVATE void ImpConstruct( const Rectangle& rRect, sal_Bool bPixel ); protected: @@ -60,14 +60,14 @@ public: const String& rDesc, const String& rTarget, const String& rName, - BOOL bActive = TRUE, - BOOL bPixelCoords = TRUE ); + sal_Bool bActive = sal_True, + sal_Bool bPixelCoords = sal_True ); virtual ~IMapRectangleObject() {}; - virtual UINT16 GetType() const; - virtual BOOL IsHit( const Point& rPoint ) const; + virtual sal_uInt16 GetType() const; + virtual sal_Bool IsHit( const Point& rPoint ) const; - Rectangle GetRectangle( BOOL bPixelCoords = TRUE ) const; + Rectangle GetRectangle( sal_Bool bPixelCoords = sal_True ) const; // liefert das BoundRect des Rechteck-Objektes in 1/100mm virtual Rectangle GetBoundRect() const { return aRect; } @@ -75,7 +75,7 @@ public: void Scale( const Fraction& rFractX, const Fraction& rFracY ); using IMapObject::IsEqual; - BOOL IsEqual( const IMapRectangleObject& rEqObj ); + sal_Bool IsEqual( const IMapRectangleObject& rEqObj ); // Im-/Export void WriteCERN( SvStream& rOStm, const String& rBaseURL ) const; diff --git a/svtools/inc/svtools/inettbc.hxx b/svtools/inc/svtools/inettbc.hxx index 9394f1ba5ccd..b65e8b0edea7 100644 --- a/svtools/inc/svtools/inettbc.hxx +++ b/svtools/inc/svtools/inettbc.hxx @@ -51,17 +51,17 @@ friend class SvtURLBox_Impl; SvtMatchContext_Impl* pCtx; SvtURLBox_Impl* pImp; INetProtocol eSmartProtocol; - BOOL bAutoCompleteMode : 1; - BOOL bOnlyDirectories : 1; - BOOL bModified : 1; - BOOL bTryAutoComplete : 1; - BOOL bCtrlClick : 1; - BOOL bHistoryDisabled : 1; - BOOL bNoSelection : 1; - BOOL bIsAutoCompleteEnabled : 1; + sal_Bool bAutoCompleteMode : 1; + sal_Bool bOnlyDirectories : 1; + sal_Bool bModified : 1; + sal_Bool bTryAutoComplete : 1; + sal_Bool bCtrlClick : 1; + sal_Bool bHistoryDisabled : 1; + sal_Bool bNoSelection : 1; + sal_Bool bIsAutoCompleteEnabled : 1; - SVT_DLLPRIVATE BOOL ProcessKey( const KeyCode& rCode ); - SVT_DLLPRIVATE void TryAutoComplete( BOOL bForce ); + SVT_DLLPRIVATE sal_Bool ProcessKey( const KeyCode& rCode ); + SVT_DLLPRIVATE void TryAutoComplete( sal_Bool bForce ); SVT_DLLPRIVATE void UpdatePicklistForSmartProtocol_Impl(); DECL_DLLPRIVATE_LINK( AutoCompleteHdl_Impl, void* ); using Window::ImplInit; @@ -83,11 +83,11 @@ public: const String& GetBaseURL() const { return aBaseURL; } void SetOpenHdl( const Link& rLink ) { aOpenHdl = rLink; } const Link& GetOpenHdl() const { return aOpenHdl; } - void SetOnlyDirectories( BOOL bDir = TRUE ); - void SetNoURLSelection( BOOL bSet = TRUE ); + void SetOnlyDirectories( sal_Bool bDir = sal_True ); + void SetNoURLSelection( sal_Bool bSet = sal_True ); INetProtocol GetSmartProtocol() const { return eSmartProtocol; } void SetSmartProtocol( INetProtocol eProt ); - BOOL IsCtrlOpen() + sal_Bool IsCtrlOpen() { return bCtrlClick; } String GetURL(); void DisableHistory(); @@ -100,7 +100,7 @@ public: void SetUrlFilter( const IUrlFilter* _pFilter ); const IUrlFilter* GetUrlFilter( ) const; - inline void EnableAutocompletion( BOOL _bEnable = TRUE ) + inline void EnableAutocompletion( sal_Bool _bEnable = sal_True ) { bIsAutoCompleteEnabled = _bEnable; } void SetPlaceHolder( const String& sPlaceHolder ) { aPlaceHolder = sPlaceHolder; } String GetPlaceHolder() { return aPlaceHolder; } diff --git a/svtools/inc/svtools/javainteractionhandler.hxx b/svtools/inc/svtools/javainteractionhandler.hxx index 87ed9da0fc3d..56dbe0e03423 100644 --- a/svtools/inc/svtools/javainteractionhandler.hxx +++ b/svtools/inc/svtools/javainteractionhandler.hxx @@ -75,7 +75,7 @@ private: bool m_bJavaNotFound_Handled; bool m_bVMCreationFailure_Handled; bool m_bRestartRequired_Handled; - USHORT m_nResult_JavaDisabled; + sal_uInt16 m_nResult_JavaDisabled; }; } diff --git a/svtools/inc/svtools/logindlg.hxx b/svtools/inc/svtools/logindlg.hxx index 9cf12dd70610..d53253cc6e1d 100644 --- a/svtools/inc/svtools/logindlg.hxx +++ b/svtools/inc/svtools/logindlg.hxx @@ -75,13 +75,13 @@ class SVT_DLLPUBLIC LoginDialog : public ModalDialog CancelButton aCancelBtn; HelpButton aHelpBtn; - SVT_DLLPRIVATE void HideControls_Impl( USHORT nFlags ); + SVT_DLLPRIVATE void HideControls_Impl( sal_uInt16 nFlags ); DECL_DLLPRIVATE_LINK( OKHdl_Impl, OKButton * ); DECL_DLLPRIVATE_LINK( PathHdl_Impl, PushButton * ); public: - LoginDialog( Window* pParent, USHORT nFlags, + LoginDialog( Window* pParent, sal_uInt16 nFlags, const String& rServer, const String* pRealm = NULL ); String GetPath() const { return aPathED.GetText(); } @@ -96,9 +96,9 @@ public: String GetAccount() const { return aAccountED.GetText(); } void SetAccount( const String& rNew ) { aAccountED.SetText( rNew ); } - BOOL IsSavePassword() const + sal_Bool IsSavePassword() const { return aSavePasswdBtn.IsChecked(); } - void SetSavePassword( BOOL bSave ) + void SetSavePassword( sal_Bool bSave ) { aSavePasswdBtn.Check( bSave ); } void SetSavePasswordText( const String& rTxt ) { aSavePasswdBtn.SetText( rTxt ); } diff --git a/svtools/inc/svtools/parhtml.hxx b/svtools/inc/svtools/parhtml.hxx index a302b40d9d4b..626c56b9c516 100644 --- a/svtools/inc/svtools/parhtml.hxx +++ b/svtools/inc/svtools/parhtml.hxx @@ -120,7 +120,7 @@ public: // ... als Enum pOptEnums ist ein HTMLOptionEnum-Array sal_uInt16 GetEnum( const HTMLOptionEnum *pOptEnums, sal_uInt16 nDflt=0 ) const; - BOOL GetEnum( sal_uInt16 &rEnum, const HTMLOptionEnum *pOptEnums ) const; + sal_Bool GetEnum( sal_uInt16 &rEnum, const HTMLOptionEnum *pOptEnums ) const; // ... und als ein par spezielle Enums HTMLInputType GetInputType() const; // @@ -134,20 +134,20 @@ SV_DECL_PTRARR(HTMLOptions,HTMLOptionPtr,16,16) class SVT_DLLPUBLIC HTMLParser : public SvParser { - BOOL bNewDoc : 1; // neues Doc lesen ? - BOOL bIsInHeader : 1; // scanne Header-Bereich - BOOL bIsInBody : 1; // scanne Body-Bereich - BOOL bReadListing : 1; // Lese Listings - BOOL bReadXMP : 1; // Lese XMP - BOOL bReadPRE : 1; // Lese preformatted Text - BOOL bReadTextArea : 1; // Lese TEXTAREA - BOOL bReadScript : 1; // Lesen von oder gefunden - - BOOL bPre_IgnoreNewPara : 1; // Flags fuers lesen von PRE-Absaetzen - BOOL bReadNextChar : 1; // TRUE: NextChar nochmals lesen (JavaScript!) - BOOL bReadComment : 1; // TRUE: NextChar nochmals lesen (JavaScript!) + sal_Bool bNewDoc : 1; // neues Doc lesen ? + sal_Bool bIsInHeader : 1; // scanne Header-Bereich + sal_Bool bIsInBody : 1; // scanne Body-Bereich + sal_Bool bReadListing : 1; // Lese Listings + sal_Bool bReadXMP : 1; // Lese XMP + sal_Bool bReadPRE : 1; // Lese preformatted Text + sal_Bool bReadTextArea : 1; // Lese TEXTAREA + sal_Bool bReadScript : 1; // Lesen von oder gefunden + + sal_Bool bPre_IgnoreNewPara : 1; // Flags fuers lesen von PRE-Absaetzen + sal_Bool bReadNextChar : 1; // sal_True: NextChar nochmals lesen (JavaScript!) + sal_Bool bReadComment : 1; // sal_True: NextChar nochmals lesen (JavaScript!) sal_uInt32 nPre_LinePos; // Pos in der Line im PRE-Tag @@ -166,43 +166,43 @@ protected: virtual ~HTMLParser(); - void FinishHeader( BOOL bBody ) { bIsInHeader = FALSE; bIsInBody = bBody; } + void FinishHeader( sal_Bool bBody ) { bIsInHeader = sal_False; bIsInBody = bBody; } public: - HTMLParser( SvStream& rIn, int bReadNewDoc = TRUE ); + HTMLParser( SvStream& rIn, int bReadNewDoc = sal_True ); virtual SvParserState CallParser(); // Aufruf des Parsers - BOOL IsNewDoc() const { return bNewDoc; } - BOOL IsInHeader() const { return bIsInHeader; } - BOOL IsInBody() const { return bIsInBody; } - BOOL IsValidSyntax() const { return TRUE; } - BOOL IsReadListing() const { return bReadListing; } - BOOL IsReadXMP() const { return bReadXMP; } - BOOL IsReadPRE() const { return bReadPRE; } - BOOL IsReadScript() const { return bReadScript; } - BOOL IsReadStyle() const { return bReadStyle; } + sal_Bool IsNewDoc() const { return bNewDoc; } + sal_Bool IsInHeader() const { return bIsInHeader; } + sal_Bool IsInBody() const { return bIsInBody; } + sal_Bool IsValidSyntax() const { return sal_True; } + sal_Bool IsReadListing() const { return bReadListing; } + sal_Bool IsReadXMP() const { return bReadXMP; } + sal_Bool IsReadPRE() const { return bReadPRE; } + sal_Bool IsReadScript() const { return bReadScript; } + sal_Bool IsReadStyle() const { return bReadStyle; } - void SetReadNextChar() { bReadNextChar = TRUE; } + void SetReadNextChar() { bReadNextChar = sal_True; } // PRE-/LISTING oder XMP-Modus starten/beenden oder Tags entsprechend // filtern - inline void StartPRE( BOOL bRestart=FALSE ); - void FinishPRE() { bReadPRE = FALSE; } + inline void StartPRE( sal_Bool bRestart=sal_False ); + void FinishPRE() { bReadPRE = sal_False; } int FilterPRE( int nToken ); - inline void StartListing( BOOL bRestart=FALSE ); - void FinishListing() { bReadListing = FALSE; } + inline void StartListing( sal_Bool bRestart=sal_False ); + void FinishListing() { bReadListing = sal_False; } int FilterListing( int nToken ); - inline void StartXMP( BOOL bRestart=FALSE ); - void FinishXMP() { bReadXMP = FALSE; } + inline void StartXMP( sal_Bool bRestart=sal_False ); + void FinishXMP() { bReadXMP = sal_False; } int FilterXMP( int nToken ); - void FinishTextArea() { bReadTextArea = FALSE; } + void FinishTextArea() { bReadTextArea = sal_False; } // PRE-/LSITING- und XMP-Modus beenden - void FinishPREListingXMP() { bReadPRE = bReadListing = bReadXMP = FALSE; } + void FinishPREListingXMP() { bReadPRE = bReadListing = bReadXMP = sal_False; } // Das aktuelle Token dem aktuellen Modus (PRE, XMP, ...) entsprechend // Filtern und die Flags setzen. Wird von Continue aufgerufen, bevor @@ -212,7 +212,7 @@ public: // Scannen eines Scripts beenden (sollte nur unmittelbar nach dem // Lesen eines