You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by ms...@apache.org on 2026/03/02 23:34:12 UTC

(openoffice) branch AOO42X updated: Cleanup

This is an automated email from the ASF dual-hosted git repository.

mseidel pushed a commit to branch AOO42X
in repository https://gitbox.apache.org/repos/asf/openoffice.git


The following commit(s) were added to refs/heads/AOO42X by this push:
     new c8364738b3 Cleanup
c8364738b3 is described below

commit c8364738b3b7adc64528af2fd2493f2252c9970e
Author: mseidel <ms...@apache.org>
AuthorDate: Tue Mar 3 00:32:04 2026 +0100

    Cleanup
    
    (cherry picked from commit d2a6cdd9af064726123417265fffe9109759577b)
---
 main/sc/source/ui/view/preview.cxx      | 395 ++++++-------
 main/starmath/source/dialog.cxx         | 975 ++++++++++++++------------------
 main/svx/inc/svx/galctrl.hxx            |  65 ++-
 main/sw/source/core/layout/paintfrm.cxx | 804 ++++++++++++--------------
 main/sw/source/core/text/frmpaint.cxx   | 307 +++++-----
 5 files changed, 1168 insertions(+), 1378 deletions(-)

diff --git a/main/sc/source/ui/view/preview.cxx b/main/sc/source/ui/view/preview.cxx
index 3bf6a08ce4..b910324947 100644
--- a/main/sc/source/ui/view/preview.cxx
+++ b/main/sc/source/ui/view/preview.cxx
@@ -27,7 +27,6 @@
 #include "scitems.hxx"
 #include <editeng/eeitem.hxx>
 
-
 #include <svtools/colorcfg.hxx>
 #include <svx/fmview.hxx>
 #include <editeng/sizeitem.hxx>
@@ -39,7 +38,6 @@
 #include <svl/itemset.hxx>
 #include <tools/multisel.hxx>
 #include <vcl/waitobj.hxx>
-#include <vcl/sound.hxx>
 
 #include "preview.hxx"
 #include "prevwsh.hxx"
@@ -69,8 +67,6 @@
 
 // STATIC DATA -----------------------------------------------------------
 
-//#define SC_PREVIEW_SHADOWSIZE	2
-
 long lcl_GetDisplayStart( SCTAB nTab, ScDocument* pDoc, long* pPages )
 {
 	long nDisplayStart = 0;
@@ -84,7 +80,6 @@ long lcl_GetDisplayStart( SCTAB nTab, ScDocument* pDoc, long* pPages )
 	return nDisplayStart;
 }
 
-
 ScPreview::ScPreview( Window* pParent, ScDocShell* pDocSh, ScPreviewShell* pViewSh ) :
 	Window( pParent ),
 	nPageNo( 0 ),
@@ -135,7 +130,6 @@ ScPreview::ScPreview( Window* pParent, ScDocShell* pDocSh, ScPreviewShell* pView
 		nRight[i] = 0; // initialized with actual positions when markers are drawn
 }
 
-
 __EXPORT ScPreview::~ScPreview()
 {
 	delete pDrawView;
@@ -182,7 +176,6 @@ void ScPreview::UpdateDrawView() // nTab muss richtig sein
 	}
 }
 
-
 void ScPreview::TestLastPage()
 {
 	if (nPageNo >= nTotalPages)
@@ -217,7 +210,6 @@ void ScPreview::TestLastPage()
 	}
 }
 
-
 void ScPreview::CalcPages( SCTAB /*nToWhichTab*/ )
 {
 	WaitObject( this );
@@ -282,8 +274,7 @@ void ScPreview::CalcPages( SCTAB /*nToWhichTab*/ )
 	DoInvalidate();
 }
 
-
-void ScPreview::RecalcPages() // nur nPageNo geaendert
+void ScPreview::RecalcPages() // nur nPageNo geändert
 {
 	if (!bValid)
 		return; // dann wird CalcPages aufgerufen
@@ -327,14 +318,13 @@ void ScPreview::RecalcPages() // nur nPageNo geaendert
 	DoInvalidate();
 }
 
-
 void ScPreview::DoPrint( ScPreviewLocationData* pFillLocation )
 {
 	if (!bValid)
 	{
 		CalcPages(0);
 		RecalcPages();
-		UpdateDrawView(); // Tabelle evtl. geaendert
+		UpdateDrawView(); // Tabelle evtl. geändert
 	}
 
 	Fraction aPreviewZoom( nZoom, 100 );
@@ -443,7 +433,7 @@ void ScPreview::DoPrint( ScPreviewLocationData* pFillLocation )
 			}
 		}
 
-		if (nPrinted)	// wenn nichts, alles grau zeichnen
+		if (nPrinted) // wenn nichts, alles grau zeichnen
 		{
 			aLocalPageSize = pPrintFunc->GetPageSize();
 			aLocalPageSize.Width()  = (long) (aLocalPageSize.Width()  * HMM_PER_TWIPS );
@@ -539,25 +529,6 @@ void ScPreview::DoPrint( ScPreviewLocationData* pFillLocation )
 				--aPixel.Bottom();
 				DrawRect( PixelToLogic( aPixel ) );
 			}
-
-			//	draw shadow
-
-//			SetLineColor();
-//			SetFillColor( aBorderColor );
-
-//			Rectangle aPixel;
-
-//			aPixel = LogicToPixel( Rectangle( nPageEndX, -aOffset.Y(), nPageEndX, nPageEndY ) );
-//			aPixel.Top() += SC_PREVIEW_SHADOWSIZE;
-//			aPixel.Right() += SC_PREVIEW_SHADOWSIZE - 1;
-//			aPixel.Bottom() += SC_PREVIEW_SHADOWSIZE - 1;
-//			DrawRect( PixelToLogic( aPixel ) );
-
-//			aPixel = LogicToPixel( Rectangle( -aOffset.X(), nPageEndY, nPageEndX, nPageEndY ) );
-//			aPixel.Left() += SC_PREVIEW_SHADOWSIZE;
-//			aPixel.Right() += SC_PREVIEW_SHADOWSIZE - 1;
-//			aPixel.Bottom() += SC_PREVIEW_SHADOWSIZE - 1;
-//			DrawRect( PixelToLogic( aPixel ) );
 		}
 	}
 }
@@ -592,7 +563,6 @@ void __EXPORT ScPreview::Command( const CommandEvent& rCEvt )
 		Window::Command( rCEvt );
 }
 
-
 void __EXPORT ScPreview::KeyInput( const KeyEvent& rKEvt )
 {
 	// The + and - keys can't be configured as accelerator entries, so they must be handled directly
@@ -621,7 +591,6 @@ void __EXPORT ScPreview::KeyInput( const KeyEvent& rKEvt )
 		Window::KeyInput(rKEvt);
 }
 
-
 const ScPreviewLocationData& ScPreview::GetLocationData()
 {
 	if ( !pLocationData )
@@ -638,7 +607,6 @@ const ScPreviewLocationData& ScPreview::GetLocationData()
 	return *pLocationData;
 }
 
-
 void ScPreview::DataChanged(sal_Bool bNewTime)
 {
 	if (bNewTime)
@@ -652,7 +620,6 @@ void ScPreview::DataChanged(sal_Bool bNewTime)
 	Invalidate();
 }
 
-
 String ScPreview::GetPosString()
 {
 	if (!bValid)
@@ -674,7 +641,6 @@ String ScPreview::GetPosString()
 	return aString;
 }
 
-
 void ScPreview::SetZoom(sal_uInt16 nNewZoom)
 {
 	if (nNewZoom < 20)
@@ -703,7 +669,6 @@ void ScPreview::SetZoom(sal_uInt16 nNewZoom)
 	}
 }
 
-
 void ScPreview::SetPageNo( long nPage )
 {
 	nPageNo = nPage;
@@ -713,7 +678,6 @@ void ScPreview::SetPageNo( long nPage )
 	Invalidate();
 }
 
-
 long ScPreview::GetFirstPage(SCTAB nTabP)
 {
 	SCTAB nDocTabCount = pDocShell->GetDocument()->GetTableCount();
@@ -738,7 +702,6 @@ long ScPreview::GetFirstPage(SCTAB nTabP)
 	return nPage;
 }
 
-
 Size lcl_GetDocPageSize( ScDocument* pDoc, SCTAB nTab )
 {
 	String aName = pDoc->GetPageStyle( nTab );
@@ -756,7 +719,6 @@ Size lcl_GetDocPageSize( ScDocument* pDoc, SCTAB nTab )
 	}
 }
 
-
 sal_uInt16 ScPreview::GetOptimalZoom(sal_Bool bWidthOnly)
 {
 	double nWinScaleX = ScGlobal::nScreenPPTX / pDocShell->GetOutputFactor();
@@ -791,7 +753,6 @@ sal_uInt16 ScPreview::GetOptimalZoom(sal_Bool bWidthOnly)
 		return nZoom;
 }
 
-
 void ScPreview::SetXOffset( long nX )
 {
 	if ( aOffset.X() == nX )
@@ -818,7 +779,6 @@ void ScPreview::SetXOffset( long nX )
 	Paint(Rectangle());
 }
 
-
 void ScPreview::SetYOffset( long nY )
 {
 	if ( aOffset.Y() == nY )
@@ -845,10 +805,9 @@ void ScPreview::SetYOffset( long nY )
 	Paint(Rectangle());
 }
 
-
 void ScPreview::DoInvalidate()
 {
-	// Wenn das ganze aus dem GetState der Shell gerufen wird,
+	// Wenn das Ganze aus dem GetState der Shell gerufen wird,
 	// muss das Invalidate hinterher asynchron kommen...
 
 	if (bInGetState)
@@ -1038,62 +997,62 @@ void __EXPORT ScPreview::MouseButtonUp( const MouseEvent& rMEvt )
 
 				if(( bLeftRulerChange || bRightRulerChange ) && ( aButtonUpPt.X() <= ( 0 - aOffset.X() ) || aButtonUpPt.X() > nWidth * HMM_PER_TWIPS - aOffset.X() ) )
 				{
-                    bMoveRulerAction = sal_False;
-                    Paint(Rectangle(0,0,10000,10000));
-                }
-                else if( bLeftRulerChange && ( aButtonUpPt.X() / HMM_PER_TWIPS > nWidth - aLRItem.GetRight() - aOffset.X() / HMM_PER_TWIPS ) )
-                {
-                    bMoveRulerAction = sal_False;
-                    Paint(Rectangle(0,0,10000,10000));
-                }
-                else if( bRightRulerChange && ( aButtonUpPt.X() / HMM_PER_TWIPS < aLRItem.GetLeft() - aOffset.X() / HMM_PER_TWIPS ) )
-                {
-                    bMoveRulerAction = sal_False;
-                    Paint(Rectangle(0,0,10000,10000));
-                }
-                else if( aButtonDownPt.X() == aButtonUpPt.X() )
-                {
-                    bMoveRulerAction = sal_False;
-                    DrawInvert( aButtonUpPt.X(), POINTER_HSIZEBAR );
-                }
-                if( bMoveRulerAction )
-                {
-                    ScDocShellModificator aModificator( *pDocShell );
-                    if( bLeftRulerChange && bLeftRulerMove )
-                    {
-                       aLRItem.SetLeft( (long)( aButtonUpPt.X() / HMM_PER_TWIPS + aOffset.X() / HMM_PER_TWIPS ));
-                       rStyleSet.Put( aLRItem );
-                    }
-                    else if( bRightRulerChange && bRightRulerMove )
-                    {
-                        aLRItem.SetRight( (long)( nWidth - aButtonUpPt.X() / HMM_PER_TWIPS - aOffset.X() / HMM_PER_TWIPS ));
-                        rStyleSet.Put( aLRItem );
-                    }
-
-                    ScStyleSaveData aNewData;
-                    aNewData.InitFromStyle( pStyleSheet );
-                    if( bUndo )
-                    {
-                        pDocShell->GetUndoManager()->AddUndoAction(
-                            new ScUndoModifyStyle( pDocShell, SFX_STYLE_FAMILY_PAGE,
-                            aOldData, aNewData ) );
-                    }
-
-                    if ( ValidTab( nTab ) )
-                    {
-                        ScPrintFunc aPrintFunc( this, pDocShell, nTab );
-                        aPrintFunc.UpdatePages();
-                    }
-
-                    Rectangle aRect(0,0,10000,10000);
-                    Paint( aRect );
-                    aModificator.SetDocumentModified();
-                    bLeftRulerChange = sal_False;
-                    bRightRulerChange = sal_False;
-                }
-            }
-            bLeftRulerMove = sal_False;
-            bRightRulerMove = sal_False;
+					bMoveRulerAction = sal_False;
+					Paint(Rectangle(0,0,10000,10000));
+				}
+				else if( bLeftRulerChange && ( aButtonUpPt.X() / HMM_PER_TWIPS > nWidth - aLRItem.GetRight() - aOffset.X() / HMM_PER_TWIPS ) )
+				{
+					bMoveRulerAction = sal_False;
+					Paint(Rectangle(0,0,10000,10000));
+				}
+				else if( bRightRulerChange && ( aButtonUpPt.X() / HMM_PER_TWIPS < aLRItem.GetLeft() - aOffset.X() / HMM_PER_TWIPS ) )
+				{
+					bMoveRulerAction = sal_False;
+					Paint(Rectangle(0,0,10000,10000));
+				}
+				else if( aButtonDownPt.X() == aButtonUpPt.X() )
+				{
+					bMoveRulerAction = sal_False;
+					DrawInvert( aButtonUpPt.X(), POINTER_HSIZEBAR );
+				}
+				if( bMoveRulerAction )
+				{
+					ScDocShellModificator aModificator( *pDocShell );
+					if( bLeftRulerChange && bLeftRulerMove )
+					{
+						aLRItem.SetLeft( (long)( aButtonUpPt.X() / HMM_PER_TWIPS + aOffset.X() / HMM_PER_TWIPS ));
+						rStyleSet.Put( aLRItem );
+					}
+					else if( bRightRulerChange && bRightRulerMove )
+					{
+						aLRItem.SetRight( (long)( nWidth - aButtonUpPt.X() / HMM_PER_TWIPS - aOffset.X() / HMM_PER_TWIPS ));
+						rStyleSet.Put( aLRItem );
+					}
+
+					ScStyleSaveData aNewData;
+					aNewData.InitFromStyle( pStyleSheet );
+					if( bUndo )
+					{
+						pDocShell->GetUndoManager()->AddUndoAction(
+							new ScUndoModifyStyle( pDocShell, SFX_STYLE_FAMILY_PAGE,
+							aOldData, aNewData ) );
+					}
+
+					if ( ValidTab( nTab ) )
+					{
+						ScPrintFunc aPrintFunc( this, pDocShell, nTab );
+						aPrintFunc.UpdatePages();
+					}
+
+					Rectangle aRect(0,0,10000,10000);
+					Paint( aRect );
+					aModificator.SetDocumentModified();
+					bLeftRulerChange = sal_False;
+					bRightRulerChange = sal_False;
+				}
+			}
+			bLeftRulerMove = sal_False;
+			bRightRulerMove = sal_False;
 		}
 
 		if( rMEvt.IsLeft() && GetPointer() == POINTER_VSIZEBAR )
@@ -1131,65 +1090,65 @@ void __EXPORT ScPreview::MouseButtonUp( const MouseEvent& rMEvt )
 
 					if( bTopRulerMove && bTopRulerChange )
 					{
-                        aULItem.SetUpperValue( (sal_uInt16)( aButtonUpPt.Y() / HMM_PER_TWIPS + aOffset.Y() / HMM_PER_TWIPS ) );
-                        rStyleSet.Put( aULItem );
-                    }
-                    else if( bBottomRulerMove && bBottomRulerChange )
-                    {
-                        aULItem.SetLowerValue( (sal_uInt16)( nHeight - aButtonUpPt.Y() / HMM_PER_TWIPS - aOffset.Y() / HMM_PER_TWIPS ) );
-                        rStyleSet.Put( aULItem );
-                    }
-                    else if( bHeaderRulerMove && bHeaderRulerChange )
-                    {
-                        const SfxPoolItem* pItem = NULL;
-                        if ( rStyleSet.GetItemState( ATTR_PAGE_HEADERSET, sal_False, &pItem ) == SFX_ITEM_SET )
-                        {
-                            SfxItemSet& pHeaderSet = ((SvxSetItem*)pItem)->GetItemSet();
-                            Size  aHeaderSize = ((const SvxSizeItem&)pHeaderSet.Get(ATTR_PAGE_SIZE)).GetSize();
-                            aHeaderSize.Height() = (long)( aButtonUpPt.Y() / HMM_PER_TWIPS + aOffset.Y() / HMM_PER_TWIPS - aULItem.GetUpper());
-                            aHeaderSize.Height() = aHeaderSize.Height() * 100 / mnScale;
-                            SvxSetItem  aNewHeader( (const SvxSetItem&)rStyleSet.Get(ATTR_PAGE_HEADERSET) );
-                            aNewHeader.GetItemSet().Put( SvxSizeItem( ATTR_PAGE_SIZE, aHeaderSize ) );
-                            rStyleSet.Put( aNewHeader );
-                        }
-                    }
-                    else if( bFooterRulerMove && bFooterRulerChange )
-                    {
-                        const SfxPoolItem* pItem = NULL;
-                        if( rStyleSet.GetItemState( ATTR_PAGE_FOOTERSET, sal_False, &pItem ) == SFX_ITEM_SET )
-                        {
-                            SfxItemSet& pFooterSet = ((SvxSetItem*)pItem)->GetItemSet();
-                            Size aFooterSize = ((const SvxSizeItem&)pFooterSet.Get(ATTR_PAGE_SIZE)).GetSize();
-                            aFooterSize.Height() = (long)( nHeight - aButtonUpPt.Y() / HMM_PER_TWIPS - aOffset.Y() / HMM_PER_TWIPS - aULItem.GetLower() );
-                            aFooterSize.Height() = aFooterSize.Height() * 100 / mnScale;
-                            SvxSetItem  aNewFooter( (const SvxSetItem&)rStyleSet.Get(ATTR_PAGE_FOOTERSET) );
-                            aNewFooter.GetItemSet().Put( SvxSizeItem( ATTR_PAGE_SIZE, aFooterSize ) );
-                            rStyleSet.Put( aNewFooter );
-                        }
-                    }
-
-                    ScStyleSaveData aNewData;
-                    aNewData.InitFromStyle( pStyleSheet );
-                    if( bUndo )
-                    {
-                        pDocShell->GetUndoManager()->AddUndoAction(
-                            new ScUndoModifyStyle( pDocShell, SFX_STYLE_FAMILY_PAGE,
-                            aOldData, aNewData ) );
-                    }
-
-                    if ( ValidTab( nTab ) )
-                    {
-                        ScPrintFunc aPrintFunc( this, pDocShell, nTab );
-                        aPrintFunc.UpdatePages();
-                    }
-
-                    Rectangle  aRect(0,0,10000,10000);
-                    Paint( aRect );
-                    aModificator.SetDocumentModified();
-                    bTopRulerChange = sal_False;
-                    bBottomRulerChange = sal_False;
-                    bHeaderRulerChange = sal_False;
-                    bFooterRulerChange = sal_False;
+						aULItem.SetUpperValue( (sal_uInt16)( aButtonUpPt.Y() / HMM_PER_TWIPS + aOffset.Y() / HMM_PER_TWIPS ) );
+						rStyleSet.Put( aULItem );
+					}
+					else if( bBottomRulerMove && bBottomRulerChange )
+					{
+						aULItem.SetLowerValue( (sal_uInt16)( nHeight - aButtonUpPt.Y() / HMM_PER_TWIPS - aOffset.Y() / HMM_PER_TWIPS ) );
+						rStyleSet.Put( aULItem );
+					}
+					else if( bHeaderRulerMove && bHeaderRulerChange )
+					{
+						const SfxPoolItem* pItem = NULL;
+						if ( rStyleSet.GetItemState( ATTR_PAGE_HEADERSET, sal_False, &pItem ) == SFX_ITEM_SET )
+						{
+							SfxItemSet& pHeaderSet = ((SvxSetItem*)pItem)->GetItemSet();
+							Size  aHeaderSize = ((const SvxSizeItem&)pHeaderSet.Get(ATTR_PAGE_SIZE)).GetSize();
+							aHeaderSize.Height() = (long)( aButtonUpPt.Y() / HMM_PER_TWIPS + aOffset.Y() / HMM_PER_TWIPS - aULItem.GetUpper());
+							aHeaderSize.Height() = aHeaderSize.Height() * 100 / mnScale;
+							SvxSetItem  aNewHeader( (const SvxSetItem&)rStyleSet.Get(ATTR_PAGE_HEADERSET) );
+							aNewHeader.GetItemSet().Put( SvxSizeItem( ATTR_PAGE_SIZE, aHeaderSize ) );
+							rStyleSet.Put( aNewHeader );
+						}
+					}
+					else if( bFooterRulerMove && bFooterRulerChange )
+					{
+						const SfxPoolItem* pItem = NULL;
+						if( rStyleSet.GetItemState( ATTR_PAGE_FOOTERSET, sal_False, &pItem ) == SFX_ITEM_SET )
+						{
+							SfxItemSet& pFooterSet = ((SvxSetItem*)pItem)->GetItemSet();
+							Size aFooterSize = ((const SvxSizeItem&)pFooterSet.Get(ATTR_PAGE_SIZE)).GetSize();
+							aFooterSize.Height() = (long)( nHeight - aButtonUpPt.Y() / HMM_PER_TWIPS - aOffset.Y() / HMM_PER_TWIPS - aULItem.GetLower() );
+							aFooterSize.Height() = aFooterSize.Height() * 100 / mnScale;
+							SvxSetItem  aNewFooter( (const SvxSetItem&)rStyleSet.Get(ATTR_PAGE_FOOTERSET) );
+							aNewFooter.GetItemSet().Put( SvxSizeItem( ATTR_PAGE_SIZE, aFooterSize ) );
+							rStyleSet.Put( aNewFooter );
+						}
+					}
+
+					ScStyleSaveData aNewData;
+					aNewData.InitFromStyle( pStyleSheet );
+					if( bUndo )
+					{
+						pDocShell->GetUndoManager()->AddUndoAction(
+							new ScUndoModifyStyle( pDocShell, SFX_STYLE_FAMILY_PAGE,
+							aOldData, aNewData ) );
+					}
+
+					if ( ValidTab( nTab ) )
+					{
+						ScPrintFunc aPrintFunc( this, pDocShell, nTab );
+						aPrintFunc.UpdatePages();
+					}
+
+					Rectangle  aRect(0,0,10000,10000);
+					Paint( aRect );
+					aModificator.SetDocumentModified();
+					bTopRulerChange = sal_False;
+					bBottomRulerChange = sal_False;
+					bHeaderRulerChange = sal_False;
+					bFooterRulerChange = sal_False;
 				}
 			}
 			bTopRulerMove = sal_False;
@@ -1226,18 +1185,18 @@ void __EXPORT ScPreview::MouseButtonUp( const MouseEvent& rMEvt )
 				else
 				{
 
-                    nNewColWidth = (long) ( PixelToLogic( Point( nRight[ nColNumberButttonDown ] - rMEvt.GetPosPixel().X(), 0), aMMMode ).X() / HMM_PER_TWIPS ) * 100 / mnScale;
-                    nNewColWidth += pDocShell->GetDocument()->GetColWidth( nColNumberButttonDown, nTab );
-                }
-
-                if( nNewColWidth >= 0 )
-                {
-                    aFunc.SetWidthOrHeight( sal_True, 1,nCols, nTab, SC_SIZE_DIRECT, (sal_uInt16)nNewColWidth, sal_True, sal_True);
-                }
-                if ( ValidTab( nTab ) )
-                {
-                    ScPrintFunc aPrintFunc( this, pDocShell, nTab );
-                    aPrintFunc.UpdatePages();
+					nNewColWidth = (long) ( PixelToLogic( Point( nRight[ nColNumberButttonDown ] - rMEvt.GetPosPixel().X(), 0), aMMMode ).X() / HMM_PER_TWIPS ) * 100 / mnScale;
+					nNewColWidth += pDocShell->GetDocument()->GetColWidth( nColNumberButttonDown, nTab );
+				}
+
+				if( nNewColWidth >= 0 )
+				{
+					aFunc.SetWidthOrHeight( sal_True, 1,nCols, nTab, SC_SIZE_DIRECT, (sal_uInt16)nNewColWidth, sal_True, sal_True);
+				}
+				if ( ValidTab( nTab ) )
+				{
+					ScPrintFunc aPrintFunc( this, pDocShell, nTab );
+					aPrintFunc.UpdatePages();
 				}
 				Rectangle  nRect(0,0,10000,10000);
 				Paint( nRect );
@@ -1254,14 +1213,14 @@ void __EXPORT ScPreview::MouseMove( const MouseEvent& rMEvt )
 	MapMode  aMMMode( MAP_100TH_MM, Point(), aHorPrevZoom, aPreviewZoom );
 	Point    aMouseMovePoint = PixelToLogic( rMEvt.GetPosPixel(), aMMMode );
 
-	long    nLeftMargin = 0;
-	long    nRightMargin = 0;
-	long    nTopMargin = 0;
-	long    nBottomMargin = 0;
-	Size    PageSize;
+	long	nLeftMargin = 0;
+	long	nRightMargin = 0;
+	long	nTopMargin = 0;
+	long	nBottomMargin = 0;
+	Size	PageSize;
 
-	long    nWidth = (long) lcl_GetDocPageSize(pDocShell->GetDocument(), nTab).Width();
-	long    nHeight = (long) lcl_GetDocPageSize(pDocShell->GetDocument(), nTab).Height();
+	long	nWidth = (long) lcl_GetDocPageSize(pDocShell->GetDocument(), nTab).Width();
+	long	nHeight = (long) lcl_GetDocPageSize(pDocShell->GetDocument(), nTab).Height();
 
 	if ( nPageNo < nTotalPages )
 	{
@@ -1378,21 +1337,21 @@ void __EXPORT ScPreview::MouseMove( const MouseEvent& rMEvt )
 			{
 				if( bLeftRulerChange && !bTopRulerMove && !bBottomRulerMove && !bHeaderRulerMove && !bFooterRulerMove )
 				{
-                    SetPointer( Pointer( POINTER_HSIZEBAR ) );
-                    if( bLeftRulerMove )
-                    {
-                       if( aMouseMovePoint.X() > -aOffset.X() && aMouseMovePoint.X() < nWidth * HMM_PER_TWIPS - aOffset.X() )
-                           DragMove( aMouseMovePoint.X(), POINTER_HSIZEBAR );
-                    }
+					SetPointer( Pointer( POINTER_HSIZEBAR ) );
+					if( bLeftRulerMove )
+					{
+						if( aMouseMovePoint.X() > -aOffset.X() && aMouseMovePoint.X() < nWidth * HMM_PER_TWIPS - aOffset.X() )
+							DragMove( aMouseMovePoint.X(), POINTER_HSIZEBAR );
+					}
 				}
 				else if( bRightRulerChange && !bTopRulerMove && !bBottomRulerMove && !bHeaderRulerMove && !bFooterRulerMove )
 				{
-                    SetPointer( Pointer( POINTER_HSIZEBAR ) );
-                    if( bRightRulerMove )
-                    {
-                       if( aMouseMovePoint.X() > -aOffset.X() && aMouseMovePoint.X() < nWidth * HMM_PER_TWIPS - aOffset.X() )
-                           DragMove( aMouseMovePoint.X(), POINTER_HSIZEBAR );
-                    }
+					SetPointer( Pointer( POINTER_HSIZEBAR ) );
+					if( bRightRulerMove )
+					{
+						if( aMouseMovePoint.X() > -aOffset.X() && aMouseMovePoint.X() < nWidth * HMM_PER_TWIPS - aOffset.X() )
+							DragMove( aMouseMovePoint.X(), POINTER_HSIZEBAR );
+					}
 				}
 			}
 		}
@@ -1406,33 +1365,33 @@ void __EXPORT ScPreview::MouseMove( const MouseEvent& rMEvt )
 			{
 				if( bTopRulerChange )
 				{
-                    SetPointer( Pointer( POINTER_VSIZEBAR ) );
-                    if( bTopRulerMove )
-                    {
-                        if( aMouseMovePoint.Y() > -aOffset.Y() && aMouseMovePoint.Y() < nHeight * HMM_PER_TWIPS - aOffset.Y() )
-                            DragMove( aMouseMovePoint.Y(), POINTER_VSIZEBAR );
-                    }
-                }
-                else if( bBottomRulerChange )
-                {
-                    SetPointer( Pointer( POINTER_VSIZEBAR ) );
-                    if( bBottomRulerMove )
-                    {
-                        if( aMouseMovePoint.Y() > -aOffset.Y() && aMouseMovePoint.Y() < nHeight * HMM_PER_TWIPS - aOffset.Y() )
-                            DragMove( aMouseMovePoint.Y(), POINTER_VSIZEBAR );
-                    }
-                }
-                else if( bHeaderRulerChange )
-                {
-                    SetPointer( Pointer( POINTER_VSIZEBAR ) );
-                    if( bHeaderRulerMove )
-                    {
-                        if( aMouseMovePoint.Y() > -aOffset.Y() && aMouseMovePoint.Y() < nHeight * HMM_PER_TWIPS - aOffset.Y() )
-                            DragMove( aMouseMovePoint.Y(), POINTER_VSIZEBAR );
-                    }
-                }
-                else if( bFooterRulerChange )
-                {
+					SetPointer( Pointer( POINTER_VSIZEBAR ) );
+					if( bTopRulerMove )
+					{
+						if( aMouseMovePoint.Y() > -aOffset.Y() && aMouseMovePoint.Y() < nHeight * HMM_PER_TWIPS - aOffset.Y() )
+							DragMove( aMouseMovePoint.Y(), POINTER_VSIZEBAR );
+					}
+				}
+				else if( bBottomRulerChange )
+				{
+					SetPointer( Pointer( POINTER_VSIZEBAR ) );
+					if( bBottomRulerMove )
+					{
+						if( aMouseMovePoint.Y() > -aOffset.Y() && aMouseMovePoint.Y() < nHeight * HMM_PER_TWIPS - aOffset.Y() )
+							DragMove( aMouseMovePoint.Y(), POINTER_VSIZEBAR );
+					}
+				}
+				else if( bHeaderRulerChange )
+				{
+					SetPointer( Pointer( POINTER_VSIZEBAR ) );
+					if( bHeaderRulerMove )
+					{
+						if( aMouseMovePoint.Y() > -aOffset.Y() && aMouseMovePoint.Y() < nHeight * HMM_PER_TWIPS - aOffset.Y() )
+							DragMove( aMouseMovePoint.Y(), POINTER_VSIZEBAR );
+					}
+				}
+				else if( bFooterRulerChange )
+				{
 					SetPointer( Pointer( POINTER_VSIZEBAR ) );
 					if( bFooterRulerMove )
 					{
diff --git a/main/starmath/source/dialog.cxx b/main/starmath/source/dialog.cxx
index d502f5c3b2..c2ed6d6f96 100644
--- a/main/starmath/source/dialog.cxx
+++ b/main/starmath/source/dialog.cxx
@@ -31,8 +31,6 @@
 #include <vcl/msgbox.hxx>
 #include <svtools/ctrltool.hxx>
 #include <sfx2/printer.hxx>
-#include <vcl/sound.hxx>
-#include <vcl/sndstyle.hxx>
 #include <vcl/waitobj.hxx>
 #include <vcl/settings.hxx>
 #include <vcl/wall.hxx>
@@ -74,7 +72,6 @@ public:
 	const String &  GetStyleName( sal_uInt16 nIdx ) const;
 };
 
-
 SmFontStyles::SmFontStyles() :
 	aNormal ( ResId( RID_FONTREGULAR, *SM_MOD()->GetResMgr() ) ),
 	aBold   ( ResId( RID_FONTBOLD,    *SM_MOD()->GetResMgr() ) ),
@@ -87,7 +84,6 @@ SmFontStyles::SmFontStyles() :
 	aBoldItalic += aItalic;
 }
 
-
 const String & SmFontStyles::GetStyleName( const Font &rFont ) const
 {
 	//! compare also SmSpecialNode::Prepare
@@ -104,33 +100,30 @@ const String & SmFontStyles::GetStyleName( const Font &rFont ) const
 		return aNormal;
 }
 
-
 const String & SmFontStyles::GetStyleName( sal_uInt16 nIdx ) const
 {
 	// 0 = "normal",  1 = "italic",
 	// 2 = "bold",    3 = "bold italic"
 
 #if OSL_DEBUG_LEVEL > 1
-    DBG_ASSERT( nIdx < GetCount(), "index out of range" );
+	DBG_ASSERT( nIdx < GetCount(), "index out of range" );
 #endif
-    switch (nIdx)
-    {
-        case 0 : return aNormal;
-        case 1 : return aItalic;
-        case 2 : return aBold;
-        case 3 : return aBoldItalic;
-    }
-    return aEmpty;
+	switch (nIdx)
+	{
+		case 0 : return aNormal;
+		case 1 : return aItalic;
+		case 2 : return aBold;
+		case 3 : return aBoldItalic;
+	}
+	return aEmpty;
 }
 
-
 const SmFontStyles & GetFontStyles()
 {
 	static const SmFontStyles aImpl;
 	return aImpl;
 }
 
-
 void SetFontStyle(const XubString &rStyleName, Font &rFont)
 {
 	// finden des Index passend zum StyleName für den leeren StyleName wird
@@ -153,7 +146,6 @@ void SetFontStyle(const XubString &rStyleName, Font &rFont)
 	rFont.SetWeight((nIndex & 0x2) ? WEIGHT_BOLD : WEIGHT_NORMAL);
 }
 
-
 /**************************************************************************/
 
 IMPL_LINK_INLINE_START( SmPrintOptionsTabPage, SizeButtonClickHdl, Button *, EMPTYARG/*pButton*/ )
@@ -163,18 +155,17 @@ IMPL_LINK_INLINE_START( SmPrintOptionsTabPage, SizeButtonClickHdl, Button *, EMP
 }
 IMPL_LINK_INLINE_END( SmPrintOptionsTabPage, SizeButtonClickHdl, Button *, pButton )
 
-
 SmPrintOptionsTabPage::SmPrintOptionsTabPage(Window *pParent, const SfxItemSet &rOptions)
 	: SfxTabPage(pParent, SmResId(RID_PRINTOPTIONPAGE), rOptions),
 	aFixedLine1		(this, SmResId( FL_PRINTOPTIONS )),
 	aTitle			(this, SmResId( CB_TITLEROW )),
-	aText		   	(this, SmResId( CB_EQUATION_TEXT )),
-	aFrame		   	(this, SmResId( CB_FRAME )),
+	aText			(this, SmResId( CB_EQUATION_TEXT )),
+	aFrame			(this, SmResId( CB_FRAME )),
 	aFixedLine2		(this, SmResId( FL_PRINT_FORMAT )),
 	aSizeNormal		(this, SmResId( RB_ORIGINAL_SIZE )),
 	aSizeScaled		(this, SmResId( RB_FIT_TO_PAGE )),
 	aSizeZoomed		(this, SmResId( RB_ZOOM )),
-	aZoom		   	(this, SmResId( MF_ZOOM )),
+	aZoom			(this, SmResId( MF_ZOOM )),
 	aFixedLine3		(this, SmResId( FL_MISC_OPTIONS )),
 	aNoRightSpaces  (this, SmResId( CB_IGNORE_SPACING )),
 	aSaveOnlyUsedSymbols  (this, SmResId( CB_SAVE_ONLY_USED_SYMBOLS ))
@@ -188,7 +179,6 @@ SmPrintOptionsTabPage::SmPrintOptionsTabPage(Window *pParent, const SfxItemSet &
 	Reset(rOptions);
 }
 
-
 sal_Bool SmPrintOptionsTabPage::FillItemSet(SfxItemSet& rSet)
 {
 	sal_uInt16  nPrintSize;
@@ -210,7 +200,6 @@ sal_Bool SmPrintOptionsTabPage::FillItemSet(SfxItemSet& rSet)
 	return sal_True;
 }
 
-
 void SmPrintOptionsTabPage::Reset(const SfxItemSet& rSet)
 {
 	SmPrintSize ePrintSize = (SmPrintSize)((const SfxUInt16Item &)rSet.Get(GetWhich(SID_PRINTSIZE))).GetValue();
@@ -230,7 +219,6 @@ void SmPrintOptionsTabPage::Reset(const SfxItemSet& rSet)
 	aSaveOnlyUsedSymbols.Check(((const SfxBoolItem &)rSet.Get(GetWhich(SID_SAVE_ONLY_USED_SYMBOLS))).GetValue());
 }
 
-
 SfxTabPage* SmPrintOptionsTabPage::Create(Window* pWindow, const SfxItemSet& rSet)
 {
 	return (new SmPrintOptionsTabPage(pWindow, rSet));
@@ -238,7 +226,6 @@ SfxTabPage* SmPrintOptionsTabPage::Create(Window* pWindow, const SfxItemSet& rSe
 
 /**************************************************************************/
 
-
 void SmShowFont::Paint(const Rectangle& rRect )
 {
 	Control::Paint( rRect );
@@ -250,7 +237,6 @@ void SmShowFont::Paint(const Rectangle& rRect )
 				   (GetOutputSize().Height() - TextSize.Height()) / 2), Text);
 }
 
-
 void SmShowFont::SetFont(const Font& rFont)
 {
 	Color aTxtColor( GetTextColor() );
@@ -265,7 +251,6 @@ void SmShowFont::SetFont(const Font& rFont)
 	SetTextColor( aTxtColor );
 }
 
-
 IMPL_LINK_INLINE_START( SmFontDialog, FontSelectHdl, ComboBox *, pComboBox )
 {
 	Face.SetName(pComboBox->GetText());
@@ -274,7 +259,6 @@ IMPL_LINK_INLINE_START( SmFontDialog, FontSelectHdl, ComboBox *, pComboBox )
 }
 IMPL_LINK_INLINE_END( SmFontDialog, FontSelectHdl, ComboBox *, pComboBox )
 
-
 IMPL_LINK( SmFontDialog, FontModifyHdl, ComboBox *, pComboBox )
 {
 	// if font is available in list then use it
@@ -286,7 +270,6 @@ IMPL_LINK( SmFontDialog, FontModifyHdl, ComboBox *, pComboBox )
 	return 0;
 }
 
-
 IMPL_LINK( SmFontDialog, AttrChangeHdl, CheckBox *, EMPTYARG /*pCheckBox*/ )
 {
 	if (aBoldCheckBox.IsChecked())
@@ -303,7 +286,6 @@ IMPL_LINK( SmFontDialog, AttrChangeHdl, CheckBox *, EMPTYARG /*pCheckBox*/ )
 	return 0;
 }
 
-
 void SmFontDialog::SetFont(const Font &rFont)
 {
 	Face = rFont;
@@ -315,11 +297,10 @@ void SmFontDialog::SetFont(const Font &rFont)
 	aShowFont.SetFont(Face);
 }
 
-
 SmFontDialog::SmFontDialog(Window * pParent,
 		OutputDevice *pFntListDevice, sal_Bool bHideCheckboxes, sal_Bool bFreeRes)
 	: ModalDialog(pParent,SmResId(RID_FONTDIALOG)),
-	aFixedText1 	(this, SmResId(1)),
+	aFixedText1		(this, SmResId(1)),
 	aFontBox		(this, SmResId(1)),
 	aBoldCheckBox	(this, SmResId(1)),
 	aItalicCheckBox (this, SmResId(2)),
@@ -398,7 +379,6 @@ void SmFontDialog::InitColor_Impl()
 	aShowFont.SetTextColor( aTxtColor );
 }
 
-
 void SmFontDialog::DataChanged( const DataChangedEvent& rDCEvt )
 {
 	if ( rDCEvt.GetType() == DATACHANGED_SETTINGS  &&
@@ -410,7 +390,6 @@ void SmFontDialog::DataChanged( const DataChangedEvent& rDCEvt )
 
 /**************************************************************************/
 
-
 IMPL_LINK( SmFontSizeDialog, DefaultButtonClickHdl, Button *, EMPTYARG /*pButton*/ )
 {
 	QueryBox *pQueryBox = new QueryBox(this, SmResId(RID_DEFAULTSAVEQUERY));
@@ -427,7 +406,6 @@ IMPL_LINK( SmFontSizeDialog, DefaultButtonClickHdl, Button *, EMPTYARG /*pButton
 	return 0;
 }
 
-
 SmFontSizeDialog::SmFontSizeDialog(Window * pParent, sal_Bool bFreeRes)
 	: ModalDialog(pParent, SmResId(RID_FONTSIZEDIALOG)),
 	aFixedText1(this, SmResId(1)),
@@ -453,7 +431,6 @@ SmFontSizeDialog::SmFontSizeDialog(Window * pParent, sal_Bool bFreeRes)
 	aDefaultButton.SetClickHdl(LINK(this, SmFontSizeDialog, DefaultButtonClickHdl));
 }
 
-
 void SmFontSizeDialog::ReadFrom(const SmFormat &rFormat)
 {
 	//! aufpassen: richtig runden!
@@ -467,7 +444,6 @@ void SmFontSizeDialog::ReadFrom(const SmFormat &rFormat)
 	aBorderSize  .SetValue( rFormat.GetRelSize(SIZ_LIMITS) );
 }
 
-
 void SmFontSizeDialog::WriteTo(SmFormat &rFormat) const
 {
 	rFormat.SetBaseSize( Size(0, SmPtsTo100th_mm( static_cast< long >(aBaseSize.GetValue()))) );
@@ -485,10 +461,8 @@ void SmFontSizeDialog::WriteTo(SmFormat &rFormat) const
 	rFormat.RequestApplyChanges();
 }
 
-
 /**************************************************************************/
 
-
 IMPL_LINK( SmFontTypeDialog, MenuSelectHdl, Menu *, pMenu )
 {
 	SmFontPickListBox *pActiveListBox;
@@ -518,7 +492,6 @@ IMPL_LINK( SmFontTypeDialog, MenuSelectHdl, Menu *, pMenu )
 	return 0;
 }
 
-
 IMPL_LINK_INLINE_START( SmFontTypeDialog, DefaultButtonClickHdl, Button *, EMPTYARG /*pButton*/ )
 {
 	QueryBox *pQueryBox = new QueryBox(this, SmResId(RID_DEFAULTSAVEQUERY));
@@ -535,7 +508,6 @@ IMPL_LINK_INLINE_START( SmFontTypeDialog, DefaultButtonClickHdl, Button *, EMPTY
 }
 IMPL_LINK_INLINE_END( SmFontTypeDialog, DefaultButtonClickHdl, Button *, pButton )
 
-
 SmFontTypeDialog::SmFontTypeDialog(Window * pParent, OutputDevice *pFntListDevice, sal_Bool bFreeRes)
 	: ModalDialog(pParent, SmResId(RID_FONTTYPEDIALOG)),
 	aFixedText1    (this, SmResId(1)),
@@ -589,7 +561,6 @@ void SmFontTypeDialog::ReadFrom(const SmFormat &rFormat)
 	aFixedFont   .Insert( rFormat.GetFont(FNT_FIXED) );
 }
 
-
 void SmFontTypeDialog::WriteTo(SmFormat &rFormat) const
 {
 	SmModule *pp = SM_MOD();
@@ -684,7 +655,6 @@ SmCategoryDesc::SmCategoryDesc(const ResId& rResId, sal_uInt16 nCategoryIdx) :
 	FreeResource();
 }
 
-
 SmCategoryDesc::~SmCategoryDesc()
 {
 	for (int i = 0; i < 4; i++)
@@ -724,7 +694,6 @@ IMPL_LINK( SmDistanceDialog, MenuSelectHdl, Menu *, pMenu )
 	return 0;
 }
 
-
 IMPL_LINK( SmDistanceDialog, DefaultButtonClickHdl, Button *, EMPTYARG /*pButton*/ )
 {
 	QueryBox *pQueryBox = new QueryBox(this, SmResId(RID_DEFAULTSAVEQUERY));
@@ -740,7 +709,6 @@ IMPL_LINK( SmDistanceDialog, DefaultButtonClickHdl, Button *, EMPTYARG /*pButton
 	return 0;
 }
 
-
 IMPL_LINK( SmDistanceDialog, CheckBoxClickHdl, CheckBox *, pCheckBox )
 {
 	if (pCheckBox == &aCheckBox1)
@@ -754,7 +722,6 @@ IMPL_LINK( SmDistanceDialog, CheckBoxClickHdl, CheckBox *, pCheckBox )
 	return 0;
 }
 
-
 void SmDistanceDialog::SetHelpId(MetricField &rField, const rtl::OString& sHelpId)
 {
 	//! HelpID's die auf diese Weise explizit gesetzt werden, müssen im
@@ -780,7 +747,6 @@ void SmDistanceDialog::SetHelpId(MetricField &rField, const rtl::OString& sHelpI
 	}
 }
 
-
 void SmDistanceDialog::SetCategory(sal_uInt16 nCategory)
 {
 #if OSL_DEBUG_LEVEL > 1
@@ -797,14 +763,14 @@ void SmDistanceDialog::SetCategory(sal_uInt16 nCategory)
 	{
 		{ HID_SMA_DEFAULT_DIST,         HID_SMA_LINE_DIST,          HID_SMA_ROOT_DIST, 0 },
 		{ HID_SMA_SUP_DIST,             HID_SMA_SUB_DIST ,          0, 0 },
-        { HID_SMA_NUMERATOR_DIST,       HID_SMA_DENOMINATOR_DIST,   0, 0 },
-        { HID_SMA_FRACLINE_EXCWIDTH,    HID_SMA_FRACLINE_LINEWIDTH, 0, 0 },
-        { HID_SMA_UPPERLIMIT_DIST,      HID_SMA_LOWERLIMIT_DIST,    0, 0 },
-        { HID_SMA_BRACKET_EXCHEIGHT,    HID_SMA_BRACKET_DIST,       0, HID_SMA_BRACKET_EXCHEIGHT2 },
-        { HID_SMA_MATRIXROW_DIST,       HID_SMA_MATRIXCOL_DIST,     0, 0 },
-        { HID_SMA_ATTRIBUT_DIST,        HID_SMA_INTERATTRIBUT_DIST, 0, 0 },
-        { HID_SMA_OPERATOR_EXCHEIGHT,   HID_SMA_OPERATOR_DIST,      0, 0 },
-        { HID_SMA_LEFTBORDER_DIST,      HID_SMA_RIGHTBORDER_DIST,   HID_SMA_UPPERBORDER_DIST, HID_SMA_LOWERBORDER_DIST }
+		{ HID_SMA_NUMERATOR_DIST,       HID_SMA_DENOMINATOR_DIST,   0, 0 },
+		{ HID_SMA_FRACLINE_EXCWIDTH,    HID_SMA_FRACLINE_LINEWIDTH, 0, 0 },
+		{ HID_SMA_UPPERLIMIT_DIST,      HID_SMA_LOWERLIMIT_DIST,    0, 0 },
+		{ HID_SMA_BRACKET_EXCHEIGHT,    HID_SMA_BRACKET_DIST,       0, HID_SMA_BRACKET_EXCHEIGHT2 },
+		{ HID_SMA_MATRIXROW_DIST,       HID_SMA_MATRIXCOL_DIST,     0, 0 },
+		{ HID_SMA_ATTRIBUT_DIST,        HID_SMA_INTERATTRIBUT_DIST, 0, 0 },
+		{ HID_SMA_OPERATOR_EXCHEIGHT,   HID_SMA_OPERATOR_DIST,      0, 0 },
+		{ HID_SMA_LEFTBORDER_DIST,      HID_SMA_RIGHTBORDER_DIST,   HID_SMA_UPPERBORDER_DIST, HID_SMA_LOWERBORDER_DIST }
 	};
 
 	// array to help iterate over the controls
@@ -818,7 +784,7 @@ void SmDistanceDialog::SetCategory(sal_uInt16 nCategory)
 
 	SmCategoryDesc *pCat;
 
-	// merken der (evtl neuen) Einstellungen der aktiven SmCategoryDesc
+	// merken der (evtl. neuen) Einstellungen der aktiven SmCategoryDesc
 	// bevor zu der neuen gewechselt wird.
 	if (nActiveCategory != CATEGORY_NONE)
 	{
@@ -843,7 +809,7 @@ void SmDistanceDialog::SetCategory(sal_uInt16 nCategory)
 		MetricField *pMF = (MetricField * const) aWin[i][1];
 
 		// Um feststellen welche Controls aktiv sein sollen wird das
-		// vorhandensein einer zugehörigen HelpID überprüft.
+		// Vorhandensein einer zugehörigen HelpID überprüft.
 		bActive = aCatMf2Hid[nCategory][i] != 0;
 
 		pFT->Show(bActive);
@@ -851,7 +817,7 @@ void SmDistanceDialog::SetCategory(sal_uInt16 nCategory)
 		pMF->Show(bActive);
 		pMF->Enable(bActive);
 
-		// setzen von Masseinheit und Anzahl der Nachkommastellen
+		// setzen von Maßeinheit und Anzahl der Nachkommastellen
 		FieldUnit  eUnit;
 		sal_uInt16     nDigits;
 		if (nCategory < 9)
@@ -903,7 +869,6 @@ void SmDistanceDialog::SetCategory(sal_uInt16 nCategory)
 	Update();
 }
 
-
 SmDistanceDialog::SmDistanceDialog(Window *pParent, sal_Bool bFreeRes)
 	: ModalDialog(pParent, SmResId(RID_DISTANCEDIALOG)),
 	aFixedText1    (this, SmResId(1)),
@@ -946,7 +911,6 @@ SmDistanceDialog::SmDistanceDialog(Window *pParent, sal_Bool bFreeRes)
 	aDefaultButton.SetClickHdl(LINK(this, SmDistanceDialog, DefaultButtonClickHdl));
 }
 
-
 SmDistanceDialog::~SmDistanceDialog()
 {
 	for (int i = 0; i < NOCATEGORIES; i++)
@@ -958,16 +922,16 @@ void SmDistanceDialog::ApplyImages()
 	sal_Bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
 	for (int i = 0;  i < NOCATEGORIES;  ++i)
 	{
-        SmCategoryDesc *pCat = Categories[i];
-        if (pCat)
-            pCat->SetHighContrast( bHighContrast );
+		SmCategoryDesc *pCat = Categories[i];
+		if (pCat)
+			pCat->SetHighContrast( bHighContrast );
 	}
 }
 
 void SmDistanceDialog::DataChanged( const DataChangedEvent &rEvt )
 {
 	if ( (rEvt.GetType() == DATACHANGED_SETTINGS) && (rEvt.GetFlags() & SETTINGS_STYLE) )
-            ApplyImages();
+			ApplyImages();
 
 	ModalDialog::DataChanged( rEvt );
 }
@@ -1007,73 +971,69 @@ void SmDistanceDialog::ReadFrom(const SmFormat &rFormat)
 	SetCategory(0);
 }
 
-
 void SmDistanceDialog::WriteTo(SmFormat &rFormat) /*const*/
 {
-    // hmm... können die tatsächlich unterschiedlich sein?
-    // wenn nicht kann oben nämlich das const stehen!
+	// hmm... können die tatsächlich unterschiedlich sein?
+	// wenn nicht kann oben nämlich das const stehen!
 	SetCategory(nActiveCategory);
 
-	rFormat.SetDistance( DIS_HORIZONTAL,    	Categories[0]->GetValue(0) );
-	rFormat.SetDistance( DIS_VERTICAL,  		Categories[0]->GetValue(1) );
-	rFormat.SetDistance( DIS_ROOT,  			Categories[0]->GetValue(2) );
-	rFormat.SetDistance( DIS_SUPERSCRIPT,   	Categories[1]->GetValue(0) );
-	rFormat.SetDistance( DIS_SUBSCRIPT,     	Categories[1]->GetValue(1) );
-	rFormat.SetDistance( DIS_NUMERATOR,     	Categories[2]->GetValue(0) );
-	rFormat.SetDistance( DIS_DENOMINATOR,   	Categories[2]->GetValue(1) );
-	rFormat.SetDistance( DIS_FRACTION,  		Categories[3]->GetValue(0) );
-	rFormat.SetDistance( DIS_STROKEWIDTH,   	Categories[3]->GetValue(1) );
-	rFormat.SetDistance( DIS_UPPERLIMIT,    	Categories[4]->GetValue(0) );
-	rFormat.SetDistance( DIS_LOWERLIMIT,    	Categories[4]->GetValue(1) );
-	rFormat.SetDistance( DIS_BRACKETSIZE,   	Categories[5]->GetValue(0) );
-	rFormat.SetDistance( DIS_BRACKETSPACE,  	Categories[5]->GetValue(1) );
-	rFormat.SetDistance( DIS_MATRIXROW,     	Categories[6]->GetValue(0) );
-	rFormat.SetDistance( DIS_MATRIXCOL,     	Categories[6]->GetValue(1) );
-	rFormat.SetDistance( DIS_ORNAMENTSIZE,  	Categories[7]->GetValue(0) );
-	rFormat.SetDistance( DIS_ORNAMENTSPACE, 	Categories[7]->GetValue(1) );
-	rFormat.SetDistance( DIS_OPERATORSIZE,  	Categories[8]->GetValue(0) );
-	rFormat.SetDistance( DIS_OPERATORSPACE, 	Categories[8]->GetValue(1) );
-	rFormat.SetDistance( DIS_LEFTSPACE,     	Categories[9]->GetValue(0) );
-	rFormat.SetDistance( DIS_RIGHTSPACE,    	Categories[9]->GetValue(1) );
-	rFormat.SetDistance( DIS_TOPSPACE,  		Categories[9]->GetValue(2) );
-	rFormat.SetDistance( DIS_BOTTOMSPACE,   	Categories[9]->GetValue(3) );
-	rFormat.SetDistance( DIS_NORMALBRACKETSIZE, Categories[5]->GetValue(3) );
+	rFormat.SetDistance( DIS_HORIZONTAL,		Categories[0]->GetValue(0) );
+	rFormat.SetDistance( DIS_VERTICAL,			Categories[0]->GetValue(1) );
+	rFormat.SetDistance( DIS_ROOT,				Categories[0]->GetValue(2) );
+	rFormat.SetDistance( DIS_SUPERSCRIPT,		Categories[1]->GetValue(0) );
+	rFormat.SetDistance( DIS_SUBSCRIPT,			Categories[1]->GetValue(1) );
+	rFormat.SetDistance( DIS_NUMERATOR,			Categories[2]->GetValue(0) );
+	rFormat.SetDistance( DIS_DENOMINATOR,		Categories[2]->GetValue(1) );
+	rFormat.SetDistance( DIS_FRACTION,			Categories[3]->GetValue(0) );
+	rFormat.SetDistance( DIS_STROKEWIDTH,		Categories[3]->GetValue(1) );
+	rFormat.SetDistance( DIS_UPPERLIMIT,		Categories[4]->GetValue(0) );
+	rFormat.SetDistance( DIS_LOWERLIMIT,		Categories[4]->GetValue(1) );
+	rFormat.SetDistance( DIS_BRACKETSIZE,		Categories[5]->GetValue(0) );
+	rFormat.SetDistance( DIS_BRACKETSPACE,		Categories[5]->GetValue(1) );
+	rFormat.SetDistance( DIS_MATRIXROW,			Categories[6]->GetValue(0) );
+	rFormat.SetDistance( DIS_MATRIXCOL,			Categories[6]->GetValue(1) );
+	rFormat.SetDistance( DIS_ORNAMENTSIZE,		Categories[7]->GetValue(0) );
+	rFormat.SetDistance( DIS_ORNAMENTSPACE,		Categories[7]->GetValue(1) );
+	rFormat.SetDistance( DIS_OPERATORSIZE,		Categories[8]->GetValue(0) );
+	rFormat.SetDistance( DIS_OPERATORSPACE,		Categories[8]->GetValue(1) );
+	rFormat.SetDistance( DIS_LEFTSPACE,			Categories[9]->GetValue(0) );
+	rFormat.SetDistance( DIS_RIGHTSPACE,		Categories[9]->GetValue(1) );
+	rFormat.SetDistance( DIS_TOPSPACE,			Categories[9]->GetValue(2) );
+	rFormat.SetDistance( DIS_BOTTOMSPACE,		Categories[9]->GetValue(3) );
+	rFormat.SetDistance( DIS_NORMALBRACKETSIZE,	Categories[5]->GetValue(3) );
 
 	rFormat.SetScaleNormalBrackets( bScaleAllBrackets );
 
 	rFormat.RequestApplyChanges();
 }
 
-
 /**************************************************************************/
 
-
 IMPL_LINK( SmAlignDialog, DefaultButtonClickHdl, Button *, EMPTYARG /*pButton*/ )
 {
    QueryBox *pQueryBox = new QueryBox(this, SmResId(RID_DEFAULTSAVEQUERY));
 
 	if (pQueryBox->Execute() == RET_YES)
 	{
-        SmModule *pp = SM_MOD();
-        SmFormat aFmt( pp->GetConfig()->GetStandardFormat() );
-        WriteTo( aFmt );
-        pp->GetConfig()->SetStandardFormat( aFmt );
+		SmModule *pp = SM_MOD();
+		SmFormat aFmt( pp->GetConfig()->GetStandardFormat() );
+		WriteTo( aFmt );
+		pp->GetConfig()->SetStandardFormat( aFmt );
 	}
 
 	delete pQueryBox;
 	return 0;
 }
 
-
 SmAlignDialog::SmAlignDialog(Window * pParent, sal_Bool bFreeRes)
 	: ModalDialog(pParent, SmResId(RID_ALIGNDIALOG)),
-	aLeft		   (this, SmResId(1)),
-	aCenter 	   (this, SmResId(2)),
-	aRight		   (this, SmResId(3)),
-    aFixedLine1    (this, SmResId(1)),
-	aOKButton1	   (this, SmResId(1)),
-	aCancelButton1 (this, SmResId(1)),
-	aDefaultButton (this, SmResId(1))
+	aLeft			(this, SmResId(1)),
+	aCenter			(this, SmResId(2)),
+	aRight			(this, SmResId(3)),
+	aFixedLine1		(this, SmResId(1)),
+	aOKButton1		(this, SmResId(1)),
+	aCancelButton1	(this, SmResId(1)),
+	aDefaultButton	(this, SmResId(1))
 {
 	if (bFreeRes)
 		FreeResource();
@@ -1081,7 +1041,6 @@ SmAlignDialog::SmAlignDialog(Window * pParent, sal_Bool bFreeRes)
 	aDefaultButton.SetClickHdl(LINK(this, SmAlignDialog, DefaultButtonClickHdl));
 }
 
-
 void SmAlignDialog::ReadFrom(const SmFormat &rFormat)
 {
 	switch (rFormat.GetHorAlign())
@@ -1106,7 +1065,6 @@ void SmAlignDialog::ReadFrom(const SmFormat &rFormat)
 	}
 }
 
-
 void SmAlignDialog::WriteTo(SmFormat &rFormat) const
 {
 	if (aLeft.IsChecked())
@@ -1119,37 +1077,35 @@ void SmAlignDialog::WriteTo(SmFormat &rFormat) const
 	rFormat.RequestApplyChanges();
 }
 
-
 /**************************************************************************/
 
-
 void SmShowSymbolSet::Paint(const Rectangle&)
 {
 	Push(PUSH_MAPMODE);
 
-    // MapUnit einstellen für die 'nLen' berechnet wurde
+	// MapUnit einstellen für die 'nLen' berechnet wurde
 	SetMapMode(MapMode(MAP_PIXEL));
 
-    sal_uInt16 v        = sal::static_int_cast< sal_uInt16 >((aVScrollBar.GetThumbPos() * nColumns));
-    size_t nSymbols = aSymbolSet.size();
+	sal_uInt16 v        = sal::static_int_cast< sal_uInt16 >((aVScrollBar.GetThumbPos() * nColumns));
+	size_t nSymbols = aSymbolSet.size();
 
-    Color aTxtColor( GetTextColor() );
-    for (sal_uInt16 i = v; i < nSymbols ; i++)
+	Color aTxtColor( GetTextColor() );
+	for (sal_uInt16 i = v; i < nSymbols ; i++)
 	{
-        SmSym    aSymbol (*aSymbolSet[i]);
+		SmSym    aSymbol (*aSymbolSet[i]);
 		Font     aFont	 (aSymbol.GetFace());
-        aFont.SetAlign(ALIGN_TOP);
+		aFont.SetAlign(ALIGN_TOP);
 
 		// etwas kleinere FontSize nehmen (als nLen) um etwas Luft zu haben
-        // (hoffentlich auch genug für links und rechts!)
+		// (hoffentlich auch genug für links und rechts!)
 		aFont.SetSize(Size(0, nLen - (nLen / 3)));
 		SetFont(aFont);
-        // keep text color
-        SetTextColor( aTxtColor );
+		// keep text color
+		SetTextColor( aTxtColor );
 
 		int   nIV 	= i - v;
-        sal_UCS4 cChar = aSymbol.GetCharacter();
-        String aText( OUString( &cChar, 1 ) );
+		sal_UCS4 cChar = aSymbol.GetCharacter();
+		String aText( OUString( &cChar, 1 ) );
 		Size  aSize( GetTextWidth( aText ), GetTextHeight());
 
 		DrawText(Point((nIV % nColumns) * nLen + (nLen - aSize.Width()) / 2,
@@ -1167,16 +1123,15 @@ void SmShowSymbolSet::Paint(const Rectangle&)
 	Pop();
 }
 
-
 void SmShowSymbolSet::MouseButtonDown(const MouseEvent& rMEvt)
 {
 	GrabFocus();
 
 	if (rMEvt.IsLeft() && Rectangle(Point(0, 0), aOutputSize).IsInside(rMEvt.GetPosPixel()))
 	{
-        long nPos = (rMEvt.GetPosPixel().Y() / nLen) * nColumns + (rMEvt.GetPosPixel().X() / nLen) +
-                      aVScrollBar.GetThumbPos() * nColumns;
-        SelectSymbol( sal::static_int_cast< sal_uInt16 >(nPos) );
+		long nPos = (rMEvt.GetPosPixel().Y() / nLen) * nColumns + (rMEvt.GetPosPixel().X() / nLen) +
+					 aVScrollBar.GetThumbPos() * nColumns;
+		SelectSymbol( sal::static_int_cast< sal_uInt16 >(nPos) );
 
 		aSelectHdlLink.Call(this);
 
@@ -1185,7 +1140,6 @@ void SmShowSymbolSet::MouseButtonDown(const MouseEvent& rMEvt)
 	else Control::MouseButtonDown (rMEvt);
 }
 
-
 void SmShowSymbolSet::KeyInput(const KeyEvent& rKEvt)
 {
 	sal_uInt16 n = nSelectSymbol;
@@ -1194,12 +1148,12 @@ void SmShowSymbolSet::KeyInput(const KeyEvent& rKEvt)
 	{
 		switch (rKEvt.GetKeyCode().GetCode())
 		{
-            case KEY_DOWN:      n = n + nColumns;   break;
-            case KEY_UP:        n = n - nColumns;   break;
+			case KEY_DOWN:		n = n + nColumns;   break;
+			case KEY_UP:		n = n - nColumns;   break;
 			case KEY_LEFT:		n -= 1;	break;
 			case KEY_RIGHT:		n += 1;	break;
 			case KEY_HOME:		n  = 0;	break;
-            case KEY_END:       n  = static_cast< sal_uInt16 >(aSymbolSet.size() - 1);   break;
+			case KEY_END:		n  = static_cast< sal_uInt16 >(aSymbolSet.size() - 1);   break;
 			case KEY_PAGEUP:	n -= nColumns * nRows;	break;
 			case KEY_PAGEDOWN:	n += nColumns * nRows;	break;
 
@@ -1211,7 +1165,7 @@ void SmShowSymbolSet::KeyInput(const KeyEvent& rKEvt)
 	else
 		n = 0;
 
-    if (n >= aSymbolSet.size())
+	if (n >= aSymbolSet.size())
 		n = nSelectSymbol;
 
 	// adjust scrollbar
@@ -1227,7 +1181,6 @@ void SmShowSymbolSet::KeyInput(const KeyEvent& rKEvt)
 	aSelectHdlLink.Call(this);
 }
 
-
 SmShowSymbolSet::SmShowSymbolSet(Window *pParent, const ResId& rResId) :
 	Control(pParent, rResId),
 	aVScrollBar(this, WinBits(WB_VSCROLL))
@@ -1238,13 +1191,13 @@ SmShowSymbolSet::SmShowSymbolSet(Window *pParent, const ResId& rResId) :
 	long nScrollBarWidth = aVScrollBar.GetSizePixel().Width(),
 		 nUseableWidth   = aOutputSize.Width() - nScrollBarWidth;
 
-    // Hoehe von 16pt in Pixeln (passend zu 'aOutputSize')
+	// Höhe von 16pt in Pixeln (passend zu 'aOutputSize')
 	nLen = (sal_uInt16) LogicToPixel(Size(0, 16), MapMode(MAP_POINT)).Height();
 
-    nColumns = sal::static_int_cast< sal_uInt16 >(nUseableWidth / nLen);
+	nColumns = sal::static_int_cast< sal_uInt16 >(nUseableWidth / nLen);
 	if (nColumns > 2  && nColumns % 2 != 0)
 		nColumns--;
-    nRows    = sal::static_int_cast< sal_uInt16 >(aOutputSize.Height() / nLen);
+	nRows = sal::static_int_cast< sal_uInt16 >(aOutputSize.Height() / nLen);
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(nColumns > 0, "Sm : keine Spalten");
 	DBG_ASSERT(nRows > 0, "Sm : keine Zeilen");
@@ -1266,14 +1219,13 @@ SmShowSymbolSet::SmShowSymbolSet(Window *pParent, const ResId& rResId) :
 
 }
 
-
 void SmShowSymbolSet::SetSymbolSet(const SymbolPtrVec_t& rSymbolSet)
 {
 	aSymbolSet = rSymbolSet;
 
-    if (static_cast< sal_uInt16 >(aSymbolSet.size()) > (nColumns * nRows))
+	if (static_cast< sal_uInt16 >(aSymbolSet.size()) > (nColumns * nRows))
 	{
-        aVScrollBar.SetRange(Range(0, ((aSymbolSet.size() + (nColumns - 1)) / nColumns) - nRows));
+		aVScrollBar.SetRange(Range(0, ((aSymbolSet.size() + (nColumns - 1)) / nColumns) - nRows));
 		aVScrollBar.Enable(sal_True);
 	}
 	else
@@ -1285,7 +1237,6 @@ void SmShowSymbolSet::SetSymbolSet(const SymbolPtrVec_t& rSymbolSet)
 	Invalidate();
 }
 
-
 void SmShowSymbolSet::SelectSymbol(sal_uInt16 nSymbol)
 {
 	int v = (int) (aVScrollBar.GetThumbPos() * nColumns);
@@ -1295,10 +1246,10 @@ void SmShowSymbolSet::SelectSymbol(sal_uInt16 nSymbol)
 								   ((nSelectSymbol - v) / nColumns) * nLen),
 							 Size(nLen, nLen)));
 
-    if (nSymbol < aSymbolSet.size())
+	if (nSymbol < aSymbolSet.size())
 		nSelectSymbol = nSymbol;
 
-    if (aSymbolSet.size() == 0)
+	if (aSymbolSet.size() == 0)
 		nSelectSymbol = SYMBOL_NONE;
 
 	if (nSelectSymbol != SYMBOL_NONE)
@@ -1309,17 +1260,15 @@ void SmShowSymbolSet::SelectSymbol(sal_uInt16 nSymbol)
 	Update();
 }
 
-
 IMPL_LINK( SmShowSymbolSet, ScrollHdl, ScrollBar*, EMPTYARG /*pScrollBar*/)
 {
 	Invalidate();
 	return 0;
 }
 
-
 void SmShowSymbol::Paint(const Rectangle &rRect)
 {
-    Control::Paint( rRect );
+	Control::Paint( rRect );
 
 	const XubString &rText = GetText();
 	Size            aTextSize(GetTextWidth(rText), GetTextHeight());
@@ -1328,7 +1277,6 @@ void SmShowSymbol::Paint(const Rectangle &rRect)
 				   (GetOutputSize().Height() * 7/10)), rText);
 }
 
-
 void SmShowSymbol::MouseButtonDown(const MouseEvent& rMEvt)
 {
 	if (rMEvt.GetClicks() > 1)
@@ -1337,29 +1285,26 @@ void SmShowSymbol::MouseButtonDown(const MouseEvent& rMEvt)
 		Control::MouseButtonDown (rMEvt);
 }
 
-
 void SmShowSymbol::SetSymbol(const SmSym *pSymbol)
 {
 	if (pSymbol)
 	{
 		Font aFont (pSymbol->GetFace());
 		aFont.SetSize(Size(0, GetOutputSize().Height() - GetOutputSize().Height() / 3));
-        aFont.SetAlign(ALIGN_BASELINE);
+		aFont.SetAlign(ALIGN_BASELINE);
 		SetFont(aFont);
 
-        sal_UCS4 cChar = pSymbol->GetCharacter();
-        String aText( OUString( &cChar, 1 ) );
+		sal_UCS4 cChar = pSymbol->GetCharacter();
+		String aText( OUString( &cChar, 1 ) );
 		SetText( aText );
 	}
 
-    // 'Invalidate' fuellt den background mit der background-Farbe.
-    // Falls der NULL pointer uebergeben wurde reicht dies also zum loeschen
+	// 'Invalidate' füllt den background mit der background-Farbe.
+	// Falls der NULL pointer übergeben wurde reicht dies also zum löschen
 	// der Anzeige
 	Invalidate();
 }
 
-
-
 void SmSymbolDialog::FillSymbolSets(sal_Bool bDeleteText)
 	// füllt die Einträge der möglichen 'SymbolsSet's im Dialog mit den
 	// aktuellen Werten des SymbolSet Managers, selektiert aber keinen.
@@ -1368,16 +1313,15 @@ void SmSymbolDialog::FillSymbolSets(sal_Bool bDeleteText)
 	if (bDeleteText)
 		aSymbolSets.SetNoSelection();
 
-    std::set< String >  aSymbolSetNames( rSymbolMgr.GetSymbolSetNames() );
-    std::set< String >::const_iterator aIt( aSymbolSetNames.begin() );
-    for ( ; aIt != aSymbolSetNames.end(); ++aIt)
-        aSymbolSets.InsertEntry( *aIt );
+	std::set< String >  aSymbolSetNames( rSymbolMgr.GetSymbolSetNames() );
+	std::set< String >::const_iterator aIt( aSymbolSetNames.begin() );
+	for ( ; aIt != aSymbolSetNames.end(); ++aIt)
+		aSymbolSets.InsertEntry( *aIt );
 }
 
-
 IMPL_LINK( SmSymbolDialog, SymbolSetChangeHdl, ListBox *, EMPTYARG pListBox )
 {
-    (void) pListBox;
+	(void) pListBox;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pListBox == &aSymbolSets, "Sm : Wrong argument");
 #endif
@@ -1386,10 +1330,9 @@ IMPL_LINK( SmSymbolDialog, SymbolSetChangeHdl, ListBox *, EMPTYARG pListBox )
 	return 0;
 }
 
-
 IMPL_LINK( SmSymbolDialog, SymbolChangeHdl, SmShowSymbolSet *, EMPTYARG pShowSymbolSet )
 {
-    (void) pShowSymbolSet;
+	(void) pShowSymbolSet;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pShowSymbolSet == &aSymbolSetDisplay, "Sm : Wrong argument");
 #endif
@@ -1400,12 +1343,12 @@ IMPL_LINK( SmSymbolDialog, SymbolChangeHdl, SmShowSymbolSet *, EMPTYARG pShowSym
 
 IMPL_LINK( SmSymbolDialog, EditClickHdl, Button *, EMPTYARG pButton )
 {
-    (void) pButton;
+	(void) pButton;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pButton == &aEditBtn, "Sm : Wrong argument");
 #endif
 
-    SmSymDefineDialog *pDialog = new SmSymDefineDialog(this, pFontListDev, rSymbolMgr);
+	SmSymDefineDialog *pDialog = new SmSymDefineDialog(this, pFontListDev, rSymbolMgr);
 
 	// aktuelles Symbol und SymbolSet am neuen Dialog setzen
 	const XubString  aSymSetName (aSymbolSets.GetSelectEntry()),
@@ -1418,12 +1361,12 @@ IMPL_LINK( SmSymbolDialog, EditClickHdl, Button *, EMPTYARG pButton )
 	// altes SymbolSet merken
 	XubString  aOldSymbolSet (aSymbolSets.GetSelectEntry());
 
-    sal_uInt16 nSymPos = GetSelectedSymbol();
+	sal_uInt16 nSymPos = GetSelectedSymbol();
 
-    // Dialog an evtl geänderte Daten des SymbolSet Manager anpassen
-    if (pDialog->Execute() == RET_OK  &&  rSymbolMgr.IsModified())
+	// Dialog an evtl geänderte Daten des SymbolSet Manager anpassen
+	if (pDialog->Execute() == RET_OK  &&  rSymbolMgr.IsModified())
 	{
-        rSymbolMgr.Save();
+		rSymbolMgr.Save();
 		FillSymbolSets();
 	}
 
@@ -1431,26 +1374,25 @@ IMPL_LINK( SmSymbolDialog, EditClickHdl, Button *, EMPTYARG pButton )
 	// (soweit eines vorhanden ist)
 	if (!SelectSymbolSet(aOldSymbolSet)  &&  aSymbolSets.GetEntryCount() > 0)
 		SelectSymbolSet(aSymbolSets.GetEntry(0));
-    else
-    {
-        // just update display of current symbol set
-        DBG_ASSERT( aSymSetName == aSymSetName, "unexpected change in symbol set name" );
-       	aSymbolSet      = rSymbolMgr.GetSymbolSet( aSymbolSetName );
-        aSymbolSetDisplay.SetSymbolSet( aSymbolSet );
-    }
-
-    if (nSymPos >= aSymbolSet.size())
-        nSymPos = static_cast< sal_uInt16 >(aSymbolSet.size()) - 1;
-    SelectSymbol( nSymPos );
+	else
+	{
+		// just update display of current symbol set
+		DBG_ASSERT( aSymSetName == aSymSetName, "unexpected change in symbol set name" );
+		aSymbolSet      = rSymbolMgr.GetSymbolSet( aSymbolSetName );
+		aSymbolSetDisplay.SetSymbolSet( aSymbolSet );
+	}
+
+	if (nSymPos >= aSymbolSet.size())
+		nSymPos = static_cast< sal_uInt16 >(aSymbolSet.size()) - 1;
+	SelectSymbol( nSymPos );
 
 	delete pDialog;
 	return 0;
 }
 
-
 IMPL_LINK( SmSymbolDialog, SymbolDblClickHdl, SmShowSymbolSet *, EMPTYARG pShowSymbolSet )
 {
-    (void) pShowSymbolSet;
+	(void) pShowSymbolSet;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pShowSymbolSet == &aSymbolSetDisplay, "Sm : Wrong argument");
 #endif
@@ -1460,10 +1402,9 @@ IMPL_LINK( SmSymbolDialog, SymbolDblClickHdl, SmShowSymbolSet *, EMPTYARG pShowS
 	return 0;
 }
 
-
 IMPL_LINK( SmSymbolDialog, GetClickHdl, Button *, EMPTYARG pButton )
 {
-    (void) pButton;
+	(void) pButton;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pButton == &aGetBtn, "Sm : Wrong button");
 #endif
@@ -1475,18 +1416,17 @@ IMPL_LINK( SmSymbolDialog, GetClickHdl, Button *, EMPTYARG pButton )
 		aText += pSym->GetName();
 		aText += (sal_Unicode)' ';
 
-        rViewSh.GetViewFrame()->GetDispatcher()->Execute(
-                SID_INSERTTEXT, SFX_CALLMODE_STANDARD,
-                new SfxStringItem(SID_INSERTTEXT, aText), 0L);
+		rViewSh.GetViewFrame()->GetDispatcher()->Execute(
+				SID_INSERTTEXT, SFX_CALLMODE_STANDARD,
+				new SfxStringItem(SID_INSERTTEXT, aText), 0L);
 	}
 
 	return 0;
 }
 
-
 IMPL_LINK_INLINE_START( SmSymbolDialog, CloseClickHdl, Button *, EMPTYARG pButton )
 {
-    (void) pButton;
+	(void) pButton;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pButton == &aCloseBtn, "Sm : Wrong button");
 #endif
@@ -1496,35 +1436,34 @@ IMPL_LINK_INLINE_START( SmSymbolDialog, CloseClickHdl, Button *, EMPTYARG pButto
 }
 IMPL_LINK_INLINE_END( SmSymbolDialog, CloseClickHdl, Button *, pButton )
 
-
 SmSymbolDialog::SmSymbolDialog(Window *pParent, OutputDevice *pFntListDevice,
-        SmSymbolManager &rMgr, SmViewShell &rViewShell, sal_Bool bFreeRes) :
+		SmSymbolManager &rMgr, SmViewShell &rViewShell, sal_Bool bFreeRes) :
 	ModalDialog			(pParent, SmResId(RID_SYMBOLDIALOG)),
-    aSymbolSetText      (this, SmResId(1)),
-    aSymbolSets         (this, SmResId(1)),
-    aSymbolSetDisplay   (this, SmResId(1)),
-    aSymbolName         (this, SmResId(2)),
-    aSymbolDisplay      (this, SmResId(2)),
-    aGetBtn             (this, SmResId(2)),
-    aCloseBtn           (this, SmResId(3)),
-    aEditBtn            (this, SmResId(1)),
-    rViewSh             (rViewShell),
-    rSymbolMgr          (rMgr),
-    pFontListDev        (pFntListDevice)
+	aSymbolSetText		(this, SmResId(1)),
+	aSymbolSets			(this, SmResId(1)),
+	aSymbolSetDisplay	(this, SmResId(1)),
+	aSymbolName			(this, SmResId(2)),
+	aSymbolDisplay		(this, SmResId(2)),
+	aGetBtn				(this, SmResId(2)),
+	aCloseBtn			(this, SmResId(3)),
+	aEditBtn			(this, SmResId(1)),
+	rViewSh				(rViewShell),
+	rSymbolMgr			(rMgr),
+	pFontListDev		(pFntListDevice)
 {
 	if (bFreeRes)
 		FreeResource();
 
-    aSymbolSetName = String();
-    aSymbolSet.clear();
+	aSymbolSetName = String();
+	aSymbolSet.clear();
 	FillSymbolSets();
 	if (aSymbolSets.GetEntryCount() > 0)
 		SelectSymbolSet(aSymbolSets.GetEntry(0));
 
-    InitColor_Impl();
+	InitColor_Impl();
 
-    // preview like controls should have a 2D look
-    aSymbolDisplay.SetBorderStyle( WINDOW_BORDER_MONO );
+	// preview like controls should have a 2D look
+	aSymbolDisplay.SetBorderStyle( WINDOW_BORDER_MONO );
 
 	aSymbolSets		 .SetSelectHdl	(LINK(this, SmSymbolDialog, SymbolSetChangeHdl));
 	aSymbolSetDisplay.SetSelectHdl  (LINK(this, SmSymbolDialog, SymbolChangeHdl));
@@ -1535,65 +1474,61 @@ SmSymbolDialog::SmSymbolDialog(Window *pParent, OutputDevice *pFntListDevice,
 	aGetBtn			 .SetClickHdl   (LINK(this, SmSymbolDialog, GetClickHdl));
 }
 
-
 SmSymbolDialog::~SmSymbolDialog()
 {
 }
 
-
 void SmSymbolDialog::InitColor_Impl()
 {
 #if OSL_DEBUG_LEVEL > 1
-    Color aBC( GetDisplayBackground().GetColor() );
+	Color aBC( GetDisplayBackground().GetColor() );
 #endif
-    ColorData   nBgCol  = COL_WHITE,
-                nTxtCol = COL_BLACK;
-    const StyleSettings &rS = GetSettings().GetStyleSettings();
-    if (rS.GetHighContrastMode())
-    {
-        nBgCol  = rS.GetFieldColor().GetColor();
-        nTxtCol = rS.GetFieldTextColor().GetColor();
-    }
+	ColorData   nBgCol  = COL_WHITE,
+				nTxtCol = COL_BLACK;
+	const StyleSettings &rS = GetSettings().GetStyleSettings();
+	if (rS.GetHighContrastMode())
+	{
+		nBgCol  = rS.GetFieldColor().GetColor();
+		nTxtCol = rS.GetFieldTextColor().GetColor();
+	}
 
-    Color aTmpColor( nBgCol );
-    Wallpaper aWall( aTmpColor );
-    Color aTxtColor( nTxtCol );
-    aSymbolDisplay   .SetBackground( aWall );
-    aSymbolDisplay   .SetTextColor( aTxtColor );
-    aSymbolSetDisplay.SetBackground( aWall );
-    aSymbolSetDisplay.SetTextColor( aTxtColor );
+	Color aTmpColor( nBgCol );
+	Wallpaper aWall( aTmpColor );
+	Color aTxtColor( nTxtCol );
+	aSymbolDisplay   .SetBackground( aWall );
+	aSymbolDisplay   .SetTextColor( aTxtColor );
+	aSymbolSetDisplay.SetBackground( aWall );
+	aSymbolSetDisplay.SetTextColor( aTxtColor );
 }
 
-
 void SmSymbolDialog::DataChanged( const DataChangedEvent& rDCEvt )
 {
-    if ( rDCEvt.GetType() == DATACHANGED_SETTINGS  &&
-         (rDCEvt.GetFlags() & SETTINGS_STYLE) )
-            InitColor_Impl();
+	if ( rDCEvt.GetType() == DATACHANGED_SETTINGS  &&
+		(rDCEvt.GetFlags() & SETTINGS_STYLE) )
+			InitColor_Impl();
 
-    ModalDialog::DataChanged( rDCEvt );
+	ModalDialog::DataChanged( rDCEvt );
 }
 
-
 sal_Bool SmSymbolDialog::SelectSymbolSet(const XubString &rSymbolSetName)
 {
 	sal_Bool	bRet = sal_False;
-	sal_uInt16 	nPos = aSymbolSets.GetEntryPos(rSymbolSetName);
+	sal_uInt16	nPos = aSymbolSets.GetEntryPos(rSymbolSetName);
 
-    aSymbolSetName = String();
-    aSymbolSet.clear();
+	aSymbolSetName = String();
+	aSymbolSet.clear();
 	if (nPos != LISTBOX_ENTRY_NOTFOUND)
 	{
 		aSymbolSets.SelectEntryPos(nPos);
 
-        aSymbolSetName  = rSymbolSetName;
-        aSymbolSet      = rSymbolMgr.GetSymbolSet( aSymbolSetName );
+		aSymbolSetName  = rSymbolSetName;
+		aSymbolSet      = rSymbolMgr.GetSymbolSet( aSymbolSetName );
 
-        // sort symbols by Unicode position (useful for displaying Greek characters alphabetically)
-        std::sort( aSymbolSet.begin(), aSymbolSet.end(), lt_SmSymPtr() );
+		// sort symbols by Unicode position (useful for displaying Greek characters alphabetically)
+		std::sort( aSymbolSet.begin(), aSymbolSet.end(), lt_SmSymPtr() );
 
-        aSymbolSetDisplay.SetSymbolSet( aSymbolSet );
-        if (aSymbolSet.size() > 0)
+		aSymbolSetDisplay.SetSymbolSet( aSymbolSet );
+		if (aSymbolSet.size() > 0)
 			SelectSymbol(0);
 
 		bRet = sal_True;
@@ -1604,40 +1539,35 @@ sal_Bool SmSymbolDialog::SelectSymbolSet(const XubString &rSymbolSetName)
 	return bRet;
 }
 
-
 void SmSymbolDialog::SelectSymbol(sal_uInt16 nSymbolNo)
 {
 	const SmSym *pSym = NULL;
-    if (aSymbolSetName.Len() > 0  &&  nSymbolNo < static_cast< sal_uInt16 >(aSymbolSet.size()))
-        pSym = aSymbolSet[ nSymbolNo ];
+	if (aSymbolSetName.Len() > 0  &&  nSymbolNo < static_cast< sal_uInt16 >(aSymbolSet.size()))
+		pSym = aSymbolSet[ nSymbolNo ];
 
 	aSymbolSetDisplay.SelectSymbol(nSymbolNo);
 	aSymbolDisplay.SetSymbol(pSym);
 	aSymbolName.SetText(pSym ? pSym->GetName() : XubString());
 }
 
-
 const SmSym * SmSymbolDialog::GetSymbol() const
 {
 	sal_uInt16 nSymbolNo = aSymbolSetDisplay.GetSelectSymbol();
-    bool bValid = aSymbolSetName.Len() > 0  &&  nSymbolNo < static_cast< sal_uInt16 >(aSymbolSet.size());
-    return bValid ? aSymbolSet[ nSymbolNo ] : NULL;
+	bool bValid = aSymbolSetName.Len() > 0  &&  nSymbolNo < static_cast< sal_uInt16 >(aSymbolSet.size());
+	return bValid ? aSymbolSet[ nSymbolNo ] : NULL;
 }
 
-
-
-
 void SmShowChar::Paint(const Rectangle &rRect)
 {
-    Control::Paint( rRect );
+	Control::Paint( rRect );
 
 	OUString aText( GetText() );
-    if (aText.getLength() > 0)
+	if (aText.getLength() > 0)
 	{
 #if OSL_DEBUG_LEVEL > 1
-        sal_Int32 nPos = 0;
-        sal_UCS4 cChar = aText.iterateCodePoints( &nPos );
-        (void) cChar;
+		sal_Int32 nPos = 0;
+		sal_UCS4 cChar = aText.iterateCodePoints( &nPos );
+		(void) cChar;
 #endif
 		Size aTextSize(GetTextWidth(aText), GetTextHeight());
 
@@ -1646,29 +1576,25 @@ void SmShowChar::Paint(const Rectangle &rRect)
 	}
 }
 
-
 void SmShowChar::SetSymbol( const SmSym *pSym )
 {
-    if (pSym)
-        SetSymbol( pSym->GetCharacter(), pSym->GetFace() );
+	if (pSym)
+		SetSymbol( pSym->GetCharacter(), pSym->GetFace() );
 }
 
-
 void SmShowChar::SetSymbol( sal_UCS4 cChar, const Font &rFont )
 {
-    Font aFont( rFont );
-    aFont.SetSize( Size(0, GetOutputSize().Height() - GetOutputSize().Height() / 3) );
-    aFont.SetAlign(ALIGN_BASELINE);
-    SetFont(aFont);
+	Font aFont( rFont );
+	aFont.SetSize( Size(0, GetOutputSize().Height() - GetOutputSize().Height() / 3) );
+	aFont.SetAlign(ALIGN_BASELINE);
+	SetFont(aFont);
 
-    String aText( OUString( &cChar, 1) );
-    SetText( aText );
+	String aText( OUString( &cChar, 1) );
+	SetText( aText );
 
-    Invalidate();
+	Invalidate();
 }
 
-
-
 void SmSymDefineDialog::FillSymbols(ComboBox &rComboBox, sal_Bool bDeleteText)
 {
 #if OSL_DEBUG_LEVEL > 1
@@ -1680,13 +1606,12 @@ void SmSymDefineDialog::FillSymbols(ComboBox &rComboBox, sal_Bool bDeleteText)
 	if (bDeleteText)
 		rComboBox.SetText(XubString());
 
-    ComboBox &rBox = &rComboBox == &aOldSymbols ? aOldSymbolSets : aSymbolSets;
-    SymbolPtrVec_t aSymSet( aSymbolMgrCopy.GetSymbolSet( rBox.GetText() ) );
-    for (size_t i = 0;  i < aSymSet.size();  ++i)
-        rComboBox.InsertEntry( aSymSet[i]->GetName() );
+	ComboBox &rBox = &rComboBox == &aOldSymbols ? aOldSymbolSets : aSymbolSets;
+	SymbolPtrVec_t aSymSet( aSymbolMgrCopy.GetSymbolSet( rBox.GetText() ) );
+	for (size_t i = 0;  i < aSymSet.size();  ++i)
+		rComboBox.InsertEntry( aSymSet[i]->GetName() );
 }
 
-
 void SmSymDefineDialog::FillSymbolSets(ComboBox &rComboBox, sal_Bool bDeleteText)
 {
 #if OSL_DEBUG_LEVEL > 1
@@ -1698,13 +1623,12 @@ void SmSymDefineDialog::FillSymbolSets(ComboBox &rComboBox, sal_Bool bDeleteText
 	if (bDeleteText)
 		rComboBox.SetText(XubString());
 
-    const std::set< String >  aSymbolSetNames( aSymbolMgrCopy.GetSymbolSetNames() );
-    std::set< String >::const_iterator aIt( aSymbolSetNames.begin() );
-    for ( ;  aIt != aSymbolSetNames.end();  ++aIt)
-        rComboBox.InsertEntry( *aIt );
+	const std::set< String >  aSymbolSetNames( aSymbolMgrCopy.GetSymbolSetNames() );
+	std::set< String >::const_iterator aIt( aSymbolSetNames.begin() );
+	for ( ;  aIt != aSymbolSetNames.end();  ++aIt)
+		rComboBox.InsertEntry( *aIt );
 }
 
-
 void SmSymDefineDialog::FillFonts(sal_Bool bDelete)
 {
 	aFonts.Clear();
@@ -1713,16 +1637,15 @@ void SmSymDefineDialog::FillFonts(sal_Bool bDelete)
 
 	// alle Fonts der 'FontList' in die Fontliste aufnehmen
 	// von denen mit gleichen Namen jedoch nur einen (denn der Style wird
-    // ueber die 'FontStyleBox' gewaehlt und nicht auch noch hier)
-    if (pFontList)
-    {
-        sal_uInt16  nCount = pFontList->GetFontNameCount();
-        for (sal_uInt16 i = 0;  i < nCount;  i++)
-            aFonts.InsertEntry( pFontList->GetFontName(i).GetName() );
-    }
+	// über die 'FontStyleBox' gewählt und nicht auch noch hier)
+	if (pFontList)
+	{
+		sal_uInt16  nCount = pFontList->GetFontNameCount();
+		for (sal_uInt16 i = 0;  i < nCount;  i++)
+			aFonts.InsertEntry( pFontList->GetFontName(i).GetName() );
+	}
 }
 
-
 void SmSymDefineDialog::FillStyles(sal_Bool bDeleteText)
 {
 	aStyles.Clear();
@@ -1734,42 +1657,39 @@ void SmSymDefineDialog::FillStyles(sal_Bool bDeleteText)
 	{
 		//aStyles.Fill(aText, &aFontList);
 		// eigene StyleName's verwenden
-        const SmFontStyles &rStyles = GetFontStyles();
-        for (sal_uInt16 i = 0;  i < rStyles.GetCount();  i++)
-            aStyles.InsertEntry( rStyles.GetStyleName(i) );
+		const SmFontStyles &rStyles = GetFontStyles();
+		for (sal_uInt16 i = 0;  i < rStyles.GetCount();  i++)
+			aStyles.InsertEntry( rStyles.GetStyleName(i) );
 
 #if OSL_DEBUG_LEVEL > 1
 		DBG_ASSERT(aStyles.GetEntryCount() > 0, "Sm : keine Styles vorhanden");
 #endif
-        aStyles.SetText( aStyles.GetEntry(0) );
+		aStyles.SetText( aStyles.GetEntry(0) );
 	}
 }
 
-
 SmSym * SmSymDefineDialog::GetSymbol(const ComboBox &rComboBox)
 {
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(&rComboBox == &aOldSymbols  ||  &rComboBox == &aSymbols,
 		"Sm : Wrong comboBox");
 #endif
-    return aSymbolMgrCopy.GetSymbolByName(rComboBox.GetText());
+	return aSymbolMgrCopy.GetSymbolByName(rComboBox.GetText());
 }
 
-
 IMPL_LINK( SmSymDefineDialog, OldSymbolChangeHdl, ComboBox *, EMPTYARG pComboBox )
 {
-    (void) pComboBox;
+	(void) pComboBox;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pComboBox == &aOldSymbols, "Sm : Wrong argument");
 #endif
-    SelectSymbol(aOldSymbols, aOldSymbols.GetText(), sal_False);
+	SelectSymbol(aOldSymbols, aOldSymbols.GetText(), sal_False);
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, OldSymbolSetChangeHdl, ComboBox *, EMPTYARG pComboBox )
 {
-    (void) pComboBox;
+	(void) pComboBox;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pComboBox == &aOldSymbolSets, "Sm : Wrong argument");
 #endif
@@ -1777,7 +1697,6 @@ IMPL_LINK( SmSymDefineDialog, OldSymbolSetChangeHdl, ComboBox *, EMPTYARG pCombo
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, ModifyHdl, ComboBox *, pComboBox )
 {
 	// merken der Cursorposition zum wiederherstellen derselben
@@ -1797,11 +1716,11 @@ IMPL_LINK( SmSymDefineDialog, ModifyHdl, ComboBox *, pComboBox )
 		// nur Namen aus der Liste erlauben (ist hier eh immer der Fall)
 		SelectStyle(aStyles.GetText(), sal_True);
 	else
-    {
+	{
 #if OSL_DEBUG_LEVEL > 1
 		DBG_ASSERT(0, "Sm : Wrong comboBox argument");
 #endif
-    }
+	}
 
 	pComboBox->SetSelection(aSelection);
 
@@ -1810,10 +1729,9 @@ IMPL_LINK( SmSymDefineDialog, ModifyHdl, ComboBox *, pComboBox )
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, FontChangeHdl, ListBox *, EMPTYARG pListBox )
 {
-    (void) pListBox;
+	(void) pListBox;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pListBox == &aFonts, "Sm : Wrong argument");
 #endif
@@ -1822,26 +1740,24 @@ IMPL_LINK( SmSymDefineDialog, FontChangeHdl, ListBox *, EMPTYARG pListBox )
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, SubsetChangeHdl, ListBox *, EMPTYARG pListBox )
 {
-    (void) pListBox;
-    sal_uInt16 nPos = aFontsSubsetLB.GetSelectEntryPos();
-    if (LISTBOX_ENTRY_NOTFOUND != nPos)
-    {
-        const Subset* pSubset = reinterpret_cast<const Subset*> (aFontsSubsetLB.GetEntryData( nPos ));
-        if (pSubset)
-        {
-            aCharsetDisplay.SelectCharacter( pSubset->GetRangeMin() );
-        }
-    }
-    return 0;
+	(void) pListBox;
+	sal_uInt16 nPos = aFontsSubsetLB.GetSelectEntryPos();
+	if (LISTBOX_ENTRY_NOTFOUND != nPos)
+	{
+		const Subset* pSubset = reinterpret_cast<const Subset*> (aFontsSubsetLB.GetEntryData( nPos ));
+		if (pSubset)
+		{
+			aCharsetDisplay.SelectCharacter( pSubset->GetRangeMin() );
+		}
+	}
+	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, StyleChangeHdl, ComboBox *, EMPTYARG pComboBox )
 {
-    (void) pComboBox;
+	(void) pComboBox;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pComboBox == &aStyles, "Sm : Wrong argument");
 #endif
@@ -1850,57 +1766,55 @@ IMPL_LINK( SmSymDefineDialog, StyleChangeHdl, ComboBox *, EMPTYARG pComboBox )
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, CharHighlightHdl, Control *, EMPTYARG )
 {
-   sal_UCS4 cChar = aCharsetDisplay.GetSelectCharacter();
+	sal_UCS4 cChar = aCharsetDisplay.GetSelectCharacter();
 
 #if OSL_DEBUG_LEVEL > 1
-    DBG_ASSERT( pSubsetMap, "SubsetMap missing" );
+	DBG_ASSERT( pSubsetMap, "SubsetMap missing" );
 #endif
-    if (pSubsetMap)
-    {
-        const Subset* pSubset = pSubsetMap->GetSubsetByUnicode( cChar );
-        if (pSubset)
-            aFontsSubsetLB.SelectEntry( pSubset->GetName() );
-        else
-            aFontsSubsetLB.SetNoSelection();
-    }
+	if (pSubsetMap)
+	{
+		const Subset* pSubset = pSubsetMap->GetSubsetByUnicode( cChar );
+		if (pSubset)
+			aFontsSubsetLB.SelectEntry( pSubset->GetName() );
+		else
+			aFontsSubsetLB.SetNoSelection();
+	}
 
-    aSymbolDisplay.SetSymbol( cChar, aCharsetDisplay.GetFont() );
+	aSymbolDisplay.SetSymbol( cChar, aCharsetDisplay.GetFont() );
 
 	UpdateButtons();
 
-    // display Unicode position as symbol name while iterating over characters
-    const String aHex( String::CreateFromInt64( cChar, 16 ).ToUpperAscii() );
-    const String aPattern( A2OU( aHex.Len() > 4 ? "Ux000000" : "Ux0000" ) );
-    String aUnicodePos( aPattern.Copy( 0, aPattern.Len() - aHex.Len() ) );
-    aUnicodePos += aHex;
-    aSymbols.SetText( aUnicodePos );
-    aSymbolName.SetText( aUnicodePos );
+	// display Unicode position as symbol name while iterating over characters
+	const String aHex( String::CreateFromInt64( cChar, 16 ).ToUpperAscii() );
+	const String aPattern( A2OU( aHex.Len() > 4 ? "Ux000000" : "Ux0000" ) );
+	String aUnicodePos( aPattern.Copy( 0, aPattern.Len() - aHex.Len() ) );
+	aUnicodePos += aHex;
+	aSymbols.SetText( aUnicodePos );
+	aSymbolName.SetText( aUnicodePos );
 
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, AddClickHdl, Button *, EMPTYARG pButton )
 {
-    (void) pButton;
+	(void) pButton;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pButton == &aAddBtn, "Sm : Wrong argument");
-    DBG_ASSERT(aAddBtn.IsEnabled(), "Sm : Voraussetzungen erfüllt?");
+	DBG_ASSERT(aAddBtn.IsEnabled(), "Sm : Voraussetzungen erfüllt?");
 #endif
 
-    // add symbol
-    const SmSym aNewSymbol( aSymbols.GetText(), aCharsetDisplay.GetFont(),
-            aCharsetDisplay.GetSelectCharacter(), aSymbolSets.GetText() );
-    //DBG_ASSERT( aSymbolMgrCopy.GetSymbolByName(aTmpSymbolName) == NULL, "symbol already exists" );
-    aSymbolMgrCopy.AddOrReplaceSymbol( aNewSymbol );
+	// add symbol
+	const SmSym aNewSymbol( aSymbols.GetText(), aCharsetDisplay.GetFont(),
+			aCharsetDisplay.GetSelectCharacter(), aSymbolSets.GetText() );
+	//DBG_ASSERT( aSymbolMgrCopy.GetSymbolByName(aTmpSymbolName) == NULL, "symbol already exists" );
+	aSymbolMgrCopy.AddOrReplaceSymbol( aNewSymbol );
 
-    // update display of new symbol
-    aSymbolDisplay.SetSymbol( &aNewSymbol );
-    aSymbolName.SetText( aNewSymbol.GetName() );
-    aSymbolSetName.SetText( aNewSymbol.GetSymbolSetName() );
+	// update display of new symbol
+	aSymbolDisplay.SetSymbol( &aNewSymbol );
+	aSymbolName.SetText( aNewSymbol.GetName() );
+	aSymbolSetName.SetText( aNewSymbol.GetSymbolSetName() );
 
 	// update list box entries
 	FillSymbolSets(aOldSymbolSets, sal_False);
@@ -1913,7 +1827,6 @@ IMPL_LINK( SmSymDefineDialog, AddClickHdl, Button *, EMPTYARG pButton )
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, ChangeClickHdl, Button *, EMPTYARG pButton )
 {
 	(void) pButton;
@@ -1926,7 +1839,7 @@ IMPL_LINK( SmSymDefineDialog, ChangeClickHdl, Button *, EMPTYARG pButton )
 	//! get font from symbol-disp lay since charset-display does not keep
 	//! the bold attribute.
 	const SmSym aNewSymbol( aSymbols.GetText(), aCharsetDisplay.GetFont(),
-            aCharsetDisplay.GetSelectCharacter(), aSymbolSets.GetText() );
+			aCharsetDisplay.GetSelectCharacter(), aSymbolSets.GetText() );
 
 	// remove old symbol if the name was changed then add new one
 //	const bool bSetNameChanged    = aOldSymbolSets.GetText() != aSymbolSets.GetText();
@@ -1947,35 +1860,34 @@ IMPL_LINK( SmSymDefineDialog, ChangeClickHdl, Button *, EMPTYARG pButton )
 	// update list box entries
 	FillSymbolSets(aOldSymbolSets, sal_False);
 	FillSymbolSets(aSymbolSets,    sal_False);
-    FillSymbols(aOldSymbols ,sal_False);
-    FillSymbols(aSymbols    ,sal_False);
+	FillSymbols(aOldSymbols ,sal_False);
+	FillSymbols(aSymbols    ,sal_False);
 
-    UpdateButtons();
+	UpdateButtons();
 
 	return 0;
 }
 
-
 IMPL_LINK( SmSymDefineDialog, DeleteClickHdl, Button *, EMPTYARG pButton )
 {
-    (void) pButton;
+	(void) pButton;
 #if OSL_DEBUG_LEVEL > 1
 	DBG_ASSERT(pButton == &aDeleteBtn, "Sm : Wrong argument");
-    DBG_ASSERT(aDeleteBtn.IsEnabled(), "Sm : Voraussetzungen erfüllt?");
+	DBG_ASSERT(aDeleteBtn.IsEnabled(), "Sm : Voraussetzungen erfüllt?");
 #endif
 
 	if (pOrigSymbol)
 	{
-        aSymbolMgrCopy.RemoveSymbol( pOrigSymbol->GetName() );
+		aSymbolMgrCopy.RemoveSymbol( pOrigSymbol->GetName() );
 
-        // clear display for original symbol
+		// clear display for original symbol
 		SetOrigSymbol(NULL, XubString());
 
-        // update list box entries
-        FillSymbolSets(aOldSymbolSets, sal_False);
-        FillSymbolSets(aSymbolSets,    sal_False);
-        FillSymbols(aOldSymbols ,sal_False);
-        FillSymbols(aSymbols    ,sal_False);
+		// update list box entries
+		FillSymbolSets(aOldSymbolSets, sal_False);
+		FillSymbolSets(aSymbolSets,    sal_False);
+		FillSymbols(aOldSymbols ,sal_False);
+		FillSymbols(aSymbols    ,sal_False);
 	}
 
 	UpdateButtons();
@@ -1983,42 +1895,41 @@ IMPL_LINK( SmSymDefineDialog, DeleteClickHdl, Button *, EMPTYARG pButton )
 	return 0;
 }
 
-
 void SmSymDefineDialog::UpdateButtons()
 {
 	sal_Bool  bAdd    = sal_False,
 		  bChange = sal_False,
 		  bDelete = sal_False,
 		  bEqual;
-    XubString aTmpSymbolName    (aSymbols.GetText()),
-              aTmpSymbolSetName (aSymbolSets.GetText());
+	XubString aTmpSymbolName    (aSymbols.GetText()),
+			  aTmpSymbolSetName (aSymbolSets.GetText());
 
-    if (aTmpSymbolName.Len() > 0  &&  aTmpSymbolSetName.Len() > 0)
+	if (aTmpSymbolName.Len() > 0  &&  aTmpSymbolSetName.Len() > 0)
 	{
 		// alle Einstellungen gleich?
 		//! (Font-, Style- und SymbolSet Name werden nicht case sensitiv verglichen)
 		bEqual = pOrigSymbol
-                    && aTmpSymbolSetName.EqualsIgnoreCaseAscii(aOldSymbolSetName.GetText())
-                    && aTmpSymbolName.Equals(pOrigSymbol->GetName())
-                    && aFonts.GetSelectEntry().EqualsIgnoreCaseAscii(
-                            pOrigSymbol->GetFace().GetName())
-                    && aStyles.GetText().EqualsIgnoreCaseAscii(
-                            GetFontStyles().GetStyleName(pOrigSymbol->GetFace()))
-                    && aCharsetDisplay.GetSelectCharacter() == pOrigSymbol->GetCharacter();
-
-        // hinzufuegen nur wenn es noch kein Symbol desgleichen Namens gibt
-        bAdd    = aSymbolMgrCopy.GetSymbolByName(aTmpSymbolName) == NULL;
-
-        // loeschen nur wenn alle Einstellungen gleich sind
+					&& aTmpSymbolSetName.EqualsIgnoreCaseAscii(aOldSymbolSetName.GetText())
+					&& aTmpSymbolName.Equals(pOrigSymbol->GetName())
+					&& aFonts.GetSelectEntry().EqualsIgnoreCaseAscii(
+							pOrigSymbol->GetFace().GetName())
+					&& aStyles.GetText().EqualsIgnoreCaseAscii(
+							GetFontStyles().GetStyleName(pOrigSymbol->GetFace()))
+					&& aCharsetDisplay.GetSelectCharacter() == pOrigSymbol->GetCharacter();
+
+		// hinzufügen nur, wenn es noch kein Symbol des gleichen Namens gibt
+		bAdd = aSymbolMgrCopy.GetSymbolByName(aTmpSymbolName) == NULL;
+
+		// löschen nur, wenn alle Einstellungen gleich sind
 		bDelete = pOrigSymbol != NULL;
 
-        // aendern wenn bei gleichem Namen mindestens eine Einstellung anders ist
-        // oder wenn es noch kein Symbol des neuen Namens gibt (wuerde implizites
-        // loeschen des bereits vorhandenen Symbols erfordern)
-//        sal_Bool  bEqualName = pOrigSymbol && aTmpSymbolName == pOrigSymbol->GetName();
+		// ändern wenn bei gleichem Namen mindestens eine Einstellung anders ist
+		// oder wenn es noch kein Symbol des neuen Namens gibt (würde implizites
+		// löschen des bereits vorhandenen Symbols erfordern)
+//		sal_Bool  bEqualName = pOrigSymbol && aTmpSymbolName == pOrigSymbol->GetName();
 //		bChange = pOrigSymbol && ( (bEqualName && !bEqual) || (!bEqualName && bAdd) );
 
-        // aendern nur falls altes Symbol vorhanden und am neuen etwas anders ist
+		// ändern nur, falls altes Symbol vorhanden und am neuen etwas anders ist
 		bChange = pOrigSymbol && !bEqual;
 }
 
@@ -2027,62 +1938,61 @@ void SmSymDefineDialog::UpdateButtons()
 	aDeleteBtn.Enable(bDelete);
 }
 
-
 SmSymDefineDialog::SmSymDefineDialog(Window * pParent,
-        OutputDevice *pFntListDevice, SmSymbolManager &rMgr, sal_Bool bFreeRes) :
+		OutputDevice *pFntListDevice, SmSymbolManager &rMgr, sal_Bool bFreeRes) :
 	ModalDialog			(pParent, SmResId(RID_SYMDEFINEDIALOG)),
-    aOldSymbolText      (this, SmResId(1)),
-    aOldSymbols         (this, SmResId(1)),
-    aOldSymbolSetText   (this, SmResId(2)),
-    aOldSymbolSets      (this, SmResId(2)),
-    aCharsetDisplay     (this, SmResId(1)),
-    aSymbolText         (this, SmResId(9)),
-    aSymbols            (this, SmResId(4)),
-    aSymbolSetText      (this, SmResId(10)),
-    aSymbolSets         (this, SmResId(5)),
-    aFontText           (this, SmResId(3)),
-    aFonts              (this, SmResId(1)),
-    aFontsSubsetFT      (this, SmResId( FT_FONTS_SUBSET )),
-    aFontsSubsetLB      (this, SmResId( LB_FONTS_SUBSET )),
-    aStyleText          (this, SmResId(4)),
-    aStyles             (this, SmResId(3)),
-    aOldSymbolName      (this, SmResId(7)),
-    aOldSymbolDisplay   (this, SmResId(3)),
-    aOldSymbolSetName   (this, SmResId(8)),
-    aSymbolName         (this, SmResId(5)),
-    aSymbolDisplay      (this, SmResId(2)),
-    aSymbolSetName      (this, SmResId(6)),
-    aOkBtn              (this, SmResId(1)),
-    aCancelBtn          (this, SmResId(1)),
-    aAddBtn             (this, SmResId(1)),
-    aChangeBtn          (this, SmResId(2)),
-    aDeleteBtn          (this, SmResId(3)),
-    aRightArrow         (this, SmResId(1)),
-    aRightArrow_Im      (SmResId(1)),
-    aRightArrow_Im_HC   (SmResId(2)),   // hi-contrast version
-    rSymbolMgr          (rMgr),
-    pSubsetMap          (NULL),
-    pFontList           (NULL)
+	aOldSymbolText      (this, SmResId(1)),
+	aOldSymbols         (this, SmResId(1)),
+	aOldSymbolSetText   (this, SmResId(2)),
+	aOldSymbolSets      (this, SmResId(2)),
+	aCharsetDisplay     (this, SmResId(1)),
+	aSymbolText         (this, SmResId(9)),
+	aSymbols            (this, SmResId(4)),
+	aSymbolSetText      (this, SmResId(10)),
+	aSymbolSets         (this, SmResId(5)),
+	aFontText           (this, SmResId(3)),
+	aFonts              (this, SmResId(1)),
+	aFontsSubsetFT      (this, SmResId( FT_FONTS_SUBSET )),
+	aFontsSubsetLB      (this, SmResId( LB_FONTS_SUBSET )),
+	aStyleText          (this, SmResId(4)),
+	aStyles             (this, SmResId(3)),
+	aOldSymbolName      (this, SmResId(7)),
+	aOldSymbolDisplay   (this, SmResId(3)),
+	aOldSymbolSetName   (this, SmResId(8)),
+	aSymbolName         (this, SmResId(5)),
+	aSymbolDisplay      (this, SmResId(2)),
+	aSymbolSetName      (this, SmResId(6)),
+	aOkBtn              (this, SmResId(1)),
+	aCancelBtn          (this, SmResId(1)),
+	aAddBtn             (this, SmResId(1)),
+	aChangeBtn          (this, SmResId(2)),
+	aDeleteBtn          (this, SmResId(3)),
+	aRightArrow         (this, SmResId(1)),
+	aRightArrow_Im      (SmResId(1)),
+	aRightArrow_Im_HC   (SmResId(2)), // hi-contrast version
+	rSymbolMgr          (rMgr),
+	pSubsetMap          (NULL),
+	pFontList           (NULL)
 {
 	if (bFreeRes)
 		FreeResource();
 
-    pFontList = new FontList( pFntListDevice );
+	pFontList = new FontList( pFntListDevice );
 
 	pOrigSymbol = 0;
 
-    // auto completion is troublesome since that symbols character also gets automatically selected in the
-    // display and if the user previously selected a character to define/redefine that one this is bad
-    aOldSymbols.EnableAutocomplete( sal_False, sal_True );
-    aSymbols   .EnableAutocomplete( sal_False, sal_True );
+	// auto completion is troublesome since that symbols character also gets automatically selected in the
+	// display and if the user previously selected a character to define/redefine that one this is bad
+	aOldSymbols.EnableAutocomplete( sal_False, sal_True );
+	aSymbols   .EnableAutocomplete( sal_False, sal_True );
 
 	FillFonts();
 	if (aFonts.GetEntryCount() > 0)
 		SelectFont(aFonts.GetEntry(0));
 
-    InitColor_Impl();
+	InitColor_Impl();
 
-    SetSymbolSetManager(rSymbolMgr);
+	SetSymbolSetManager(rSymbolMgr);
 
 	aOldSymbols	   .SetSelectHdl(LINK(this, SmSymDefineDialog, OldSymbolChangeHdl));
 	aOldSymbolSets .SetSelectHdl(LINK(this, SmSymDefineDialog, OldSymbolSetChangeHdl));
@@ -2092,87 +2002,83 @@ SmSymDefineDialog::SmSymDefineDialog(Window * pParent,
 	aOldSymbols    .SetModifyHdl(LINK(this, SmSymDefineDialog, ModifyHdl));
 	aStyles		   .SetModifyHdl(LINK(this, SmSymDefineDialog, ModifyHdl));
 	aFonts         .SetSelectHdl(LINK(this, SmSymDefineDialog, FontChangeHdl));
-    aFontsSubsetLB .SetSelectHdl(LINK(this, SmSymDefineDialog, SubsetChangeHdl));
+	aFontsSubsetLB .SetSelectHdl(LINK(this, SmSymDefineDialog, SubsetChangeHdl));
 	aStyles        .SetSelectHdl(LINK(this, SmSymDefineDialog, StyleChangeHdl));
 	aAddBtn        .SetClickHdl (LINK(this, SmSymDefineDialog, AddClickHdl));
 	aChangeBtn     .SetClickHdl (LINK(this, SmSymDefineDialog, ChangeClickHdl));
 	aDeleteBtn     .SetClickHdl (LINK(this, SmSymDefineDialog, DeleteClickHdl));
-    aCharsetDisplay.SetHighlightHdl( LINK( this, SmSymDefineDialog, CharHighlightHdl ) );
+	aCharsetDisplay.SetHighlightHdl( LINK( this, SmSymDefineDialog, CharHighlightHdl ) );
 
-    // preview like controls should have a 2D look
-    aOldSymbolDisplay.SetBorderStyle( WINDOW_BORDER_MONO );
-    aSymbolDisplay   .SetBorderStyle( WINDOW_BORDER_MONO );
+	// preview like controls should have a 2D look
+	aOldSymbolDisplay.SetBorderStyle( WINDOW_BORDER_MONO );
+	aSymbolDisplay   .SetBorderStyle( WINDOW_BORDER_MONO );
 }
 
-
 SmSymDefineDialog::~SmSymDefineDialog()
 {
-    delete pSubsetMap;
-    delete pOrigSymbol;
+	delete pSubsetMap;
+	delete pOrigSymbol;
 }
 
 void SmSymDefineDialog::InitColor_Impl()
 {
 #if OSL_DEBUG_LEVEL > 1
-    Color aBC( GetDisplayBackground().GetColor() );
+	Color aBC( GetDisplayBackground().GetColor() );
 #endif
-    ColorData   nBgCol  = COL_WHITE,
-                nTxtCol = COL_BLACK;
-    sal_Bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
-    if (bHighContrast)
-    {
-        const StyleSettings &rS = GetSettings().GetStyleSettings();
-        nBgCol  = rS.GetFieldColor().GetColor();
-        nTxtCol = rS.GetFieldTextColor().GetColor();
-    }
-
-    Color aTmpColor( nBgCol );
-    Wallpaper aWall( aTmpColor );
-    Color aTxtColor( nTxtCol );
-    aCharsetDisplay  .SetBackground( aWall );
-    aCharsetDisplay  .SetTextColor( aTxtColor );
-    aOldSymbolDisplay.SetBackground( aWall );
-    aOldSymbolDisplay.SetTextColor( aTxtColor );
-    aSymbolDisplay   .SetBackground( aWall );
-    aSymbolDisplay   .SetTextColor( aTxtColor );
-
-    const Image &rArrowRight = bHighContrast ? aRightArrow_Im_HC : aRightArrow_Im;
-    aRightArrow.SetImage( rArrowRight );
-}
+	ColorData	nBgCol  = COL_WHITE,
+				nTxtCol = COL_BLACK;
+	sal_Bool bHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
+	if (bHighContrast)
+	{
+		const StyleSettings &rS = GetSettings().GetStyleSettings();
+		nBgCol  = rS.GetFieldColor().GetColor();
+		nTxtCol = rS.GetFieldTextColor().GetColor();
+	}
+
+	Color aTmpColor( nBgCol );
+	Wallpaper aWall( aTmpColor );
+	Color aTxtColor( nTxtCol );
+	aCharsetDisplay  .SetBackground( aWall );
+	aCharsetDisplay  .SetTextColor( aTxtColor );
+	aOldSymbolDisplay.SetBackground( aWall );
+	aOldSymbolDisplay.SetTextColor( aTxtColor );
+	aSymbolDisplay   .SetBackground( aWall );
+	aSymbolDisplay   .SetTextColor( aTxtColor );
 
+	const Image &rArrowRight = bHighContrast ? aRightArrow_Im_HC : aRightArrow_Im;
+	aRightArrow.SetImage( rArrowRight );
+}
 
 void SmSymDefineDialog::DataChanged( const DataChangedEvent& rDCEvt )
 {
-    if ( rDCEvt.GetType() == DATACHANGED_SETTINGS  &&
-         (rDCEvt.GetFlags() & SETTINGS_STYLE) )
-            InitColor_Impl();
+	if ( rDCEvt.GetType() == DATACHANGED_SETTINGS  &&
+		(rDCEvt.GetFlags() & SETTINGS_STYLE) )
+			InitColor_Impl();
 
-    ModalDialog::DataChanged( rDCEvt );
+	ModalDialog::DataChanged( rDCEvt );
 }
 
-
 short SmSymDefineDialog::Execute()
 {
 	short nResult = ModalDialog::Execute();
 
-    // Aenderungen uebernehmen falls Dialog mit OK beendet wurde
-    if (aSymbolMgrCopy.IsModified()  &&  nResult == RET_OK)
-        rSymbolMgr = aSymbolMgrCopy;
+	// Änderungen übernehmen falls Dialog mit OK beendet wurde
+	if (aSymbolMgrCopy.IsModified()  &&  nResult == RET_OK)
+		rSymbolMgr = aSymbolMgrCopy;
 
 	return nResult;
 }
 
-
 void SmSymDefineDialog::SetSymbolSetManager(const SmSymbolManager &rMgr)
 {
-    aSymbolMgrCopy = rMgr;
+	aSymbolMgrCopy = rMgr;
 #ifdef DEBUG
-//        sal_uInt16 nS = aSymbolMgrCopy.GetSymbolSetCount();
+//		sal_uInt16 nS = aSymbolMgrCopy.GetSymbolSetCount();
 #endif
 
-    // Das modified Flag der Kopie auf sal_False setzen, damit man spaeter damit
-    // testen kann ob sich was geaendert hat.
-    aSymbolMgrCopy.SetModified(sal_False);
+	// Das modified Flag der Kopie auf sal_False setzen, damit man später damit
+	// testen kann ob sich was geändert hat.
+	aSymbolMgrCopy.SetModified(sal_False);
 
 	FillSymbolSets(aOldSymbolSets);
 	if (aOldSymbolSets.GetEntryCount() > 0)
@@ -2190,7 +2096,6 @@ void SmSymDefineDialog::SetSymbolSetManager(const SmSymbolManager &rMgr)
 	UpdateButtons();
 }
 
-
 sal_Bool SmSymDefineDialog::SelectSymbolSet(ComboBox &rComboBox,
 		const XubString &rSymbolSetName, sal_Bool bDeleteText)
 {
@@ -2203,7 +2108,7 @@ sal_Bool SmSymDefineDialog::SelectSymbolSet(ComboBox &rComboBox,
 	XubString  aNormName (rSymbolSetName);
 	aNormName.EraseLeadingChars(' ');
 	aNormName.EraseTrailingChars(' ');
-	// und evtl Abweichungen in der Eingabe beseitigen
+	// und evtl. Abweichungen in der Eingabe beseitigen
 	rComboBox.SetText(aNormName);
 
 	sal_Bool   bRet = sal_False;
@@ -2219,23 +2124,23 @@ sal_Bool SmSymDefineDialog::SelectSymbolSet(ComboBox &rComboBox,
 
 	sal_Bool  bIsOld = &rComboBox == &aOldSymbolSets;
 
-    // setzen des SymbolSet Namens an der zugehörigen Darstellung
+	// setzen des SymbolSet Namens an der zugehörigen Darstellung
 	FixedText &rFT = bIsOld ? aOldSymbolSetName : aSymbolSetName;
 	rFT.SetText(rComboBox.GetText());
 
-    // setzen der zum SymbolSet gehörenden Symbol Namen an der zugehörigen
+	// setzen der zum SymbolSet gehörenden Symbol Namen an der zugehörigen
 	// Auswahlbox
 	ComboBox  &rCB = bIsOld ? aOldSymbols : aSymbols;
 	FillSymbols(rCB, sal_False);
 
-    // bei Wechsel des SymbolSets für das alte Zeichen ein gültiges
+	// bei Wechsel des SymbolSets für das alte Zeichen ein gültiges
 	// Symbol bzw keins zur Anzeige bringen
 	if (bIsOld)
 	{
-        XubString  aTmpOldSymbolName;
+		XubString  aTmpOldSymbolName;
 		if (aOldSymbols.GetEntryCount() > 0)
-            aTmpOldSymbolName = aOldSymbols.GetEntry(0);
-        SelectSymbol(aOldSymbols, aTmpOldSymbolName, sal_True);
+			aTmpOldSymbolName = aOldSymbols.GetEntry(0);
+		SelectSymbol(aOldSymbols, aTmpOldSymbolName, sal_True);
 	}
 
 	UpdateButtons();
@@ -2243,27 +2148,26 @@ sal_Bool SmSymDefineDialog::SelectSymbolSet(ComboBox &rComboBox,
 	return bRet;
 }
 
-
 void SmSymDefineDialog::SetOrigSymbol(const SmSym *pSymbol,
 									  const XubString &rSymbolSetName)
 {
-    // clear old symbol
-    delete pOrigSymbol;
-    pOrigSymbol = 0;
+	// clear old symbol
+	delete pOrigSymbol;
+	pOrigSymbol = 0;
 
-    XubString   aSymName,
-                aSymSetName;
+	XubString	aSymName,
+				aSymSetName;
 	if (pSymbol)
 	{
-        // set new symbol
-        pOrigSymbol = new SmSym( *pSymbol );
+		// set new symbol
+		pOrigSymbol = new SmSym( *pSymbol );
 
 		aSymName    = pSymbol->GetName();
 		aSymSetName = rSymbolSetName;
 		aOldSymbolDisplay.SetSymbol( pSymbol );
 	}
 	else
-    {   // loeschen des angezeigten Symbols
+	{   // löschen des angezeigten Symbols
 		aOldSymbolDisplay.SetText(XubString());
 		aOldSymbolDisplay.Invalidate();
 	}
@@ -2271,7 +2175,6 @@ void SmSymDefineDialog::SetOrigSymbol(const SmSym *pSymbol,
 	aOldSymbolSetName.SetText(aSymSetName);
 }
 
-
 sal_Bool SmSymDefineDialog::SelectSymbol(ComboBox &rComboBox,
 		const XubString &rSymbolName, sal_Bool bDeleteText)
 {
@@ -2300,24 +2203,24 @@ sal_Bool SmSymDefineDialog::SelectSymbol(ComboBox &rComboBox,
 			const SmSym *pSymbol = GetSymbol(aSymbols);
 			if (pSymbol)
 			{
-                // Font und Style entsprechend waehlen
+				// Font und Style entsprechend wählen
 				const Font &rFont = pSymbol->GetFace();
 				SelectFont(rFont.GetName(), sal_False);
-                SelectStyle(GetFontStyles().GetStyleName(rFont), sal_False);
+				SelectStyle(GetFontStyles().GetStyleName(rFont), sal_False);
 
-                // da das setzen des Fonts ueber den Style Namen des SymbolsFonts nicht
-				// so gut klappt (er kann zB leer sein obwohl der Font selbst 'bold' und
-                // 'italic' ist!). Setzen wir hier den Font wie er zum Symbol gehoert
-                // zu Fuss.
+				// da das setzen des Fonts über den Style Namen des SymbolsFonts nicht
+				// so gut klappt (er kann z.B. leer sein obwohl der Font selbst 'bold' und
+				// 'italic' ist!). Setzen wir hier den Font wie er zum Symbol gehört
+				// zu Fuß.
 				aCharsetDisplay.SetFont(rFont);
 				aSymbolDisplay.SetFont(rFont);
 
-                // das zugehoerige Zeichen auswaehlen
+				// das zugehörige Zeichen auswählen
 				SelectChar(pSymbol->GetCharacter());
 
-                // since SelectChar will also set the unicode point as text in the
-                // symbols box, we have to set the symbol name again to get that one displayed
-                aSymbols.SetText( pSymbol->GetName() );
+				// since SelectChar will also set the unicode point as text in the
+				// symbols box, we have to set the symbol name again to get that one displayed
+				aSymbols.SetText( pSymbol->GetName() );
 			}
 		}
 
@@ -2330,13 +2233,13 @@ sal_Bool SmSymDefineDialog::SelectSymbol(ComboBox &rComboBox,
 	{
 		// bei Wechsel des alten Symbols nur vorhandene anzeigen sonst keins
 		const SmSym *pOldSymbol = NULL;
-        XubString     aTmpOldSymbolSetName;
+		XubString     aTmpOldSymbolSetName;
 		if (nPos != COMBOBOX_ENTRY_NOTFOUND)
 		{
-            pOldSymbol        = aSymbolMgrCopy.GetSymbolByName(aNormName);
-            aTmpOldSymbolSetName = aOldSymbolSets.GetText();
+			pOldSymbol        = aSymbolMgrCopy.GetSymbolByName(aNormName);
+			aTmpOldSymbolSetName = aOldSymbolSets.GetText();
 		}
-        SetOrigSymbol(pOldSymbol, aTmpOldSymbolSetName);
+		SetOrigSymbol(pOldSymbol, aTmpOldSymbolSetName);
 	}
 	else
 		aSymbolName.SetText(rComboBox.GetText());
@@ -2346,43 +2249,41 @@ sal_Bool SmSymDefineDialog::SelectSymbol(ComboBox &rComboBox,
 	return bRet;
 }
 
-
 void SmSymDefineDialog::SetFont(const XubString &rFontName, const XubString &rStyleName)
 {
 	// Font (FontInfo) passend zu Namen und Style holen
-    FontInfo aFI;
-    if (pFontList)
-        aFI = pFontList->Get(rFontName, WEIGHT_NORMAL, ITALIC_NONE);
+	FontInfo aFI;
+	if (pFontList)
+		aFI = pFontList->Get(rFontName, WEIGHT_NORMAL, ITALIC_NONE);
 	SetFontStyle(rStyleName, aFI);
 
 	aCharsetDisplay.SetFont(aFI);
 	aSymbolDisplay.SetFont(aFI);
 
-    // update subset listbox for new font's unicode subsets
-    FontCharMap aFontCharMap;
-    aCharsetDisplay.GetFontCharMap( aFontCharMap );
-    if (pSubsetMap)
-        delete pSubsetMap;
-    pSubsetMap = new SubsetMap( &aFontCharMap );
-    //
-    aFontsSubsetLB.Clear();
-    bool bFirst = true;
-    const Subset* pSubset;
-    while( NULL != (pSubset = pSubsetMap->GetNextSubset( bFirst )) )
-    {
-        sal_uInt16 nPos = aFontsSubsetLB.InsertEntry( pSubset->GetName());
-        aFontsSubsetLB.SetEntryData( nPos, (void *) pSubset );
-        // subset must live at least as long as the selected font !!!
-        if( bFirst )
-	        aFontsSubsetLB.SelectEntryPos( nPos );
-        bFirst = false;
-    }
-    if( bFirst )
-        aFontsSubsetLB.SetNoSelection();
-    aFontsSubsetLB.Enable( !bFirst );
+	// update subset listbox for new font's unicode subsets
+	FontCharMap aFontCharMap;
+	aCharsetDisplay.GetFontCharMap( aFontCharMap );
+	if (pSubsetMap)
+		delete pSubsetMap;
+	pSubsetMap = new SubsetMap( &aFontCharMap );
+	//
+	aFontsSubsetLB.Clear();
+	bool bFirst = true;
+	const Subset* pSubset;
+	while( NULL != (pSubset = pSubsetMap->GetNextSubset( bFirst )) )
+	{
+		sal_uInt16 nPos = aFontsSubsetLB.InsertEntry( pSubset->GetName());
+		aFontsSubsetLB.SetEntryData( nPos, (void *) pSubset );
+		// subset must live at least as long as the selected font !!!
+		if( bFirst )
+			aFontsSubsetLB.SelectEntryPos( nPos );
+		bFirst = false;
+	}
+	if( bFirst )
+		aFontsSubsetLB.SetNoSelection();
+	aFontsSubsetLB.Enable( !bFirst );
 }
 
-
 sal_Bool SmSymDefineDialog::SelectFont(const XubString &rFontName, sal_Bool bApplyFont)
 {
 	sal_Bool   bRet = sal_False;
@@ -2394,11 +2295,11 @@ sal_Bool SmSymDefineDialog::SelectFont(const XubString &rFontName, sal_Bool bApp
 		if (aStyles.GetEntryCount() > 0)
 			SelectStyle(aStyles.GetEntry(0));
 		if (bApplyFont)
-        {
+		{
 			SetFont(aFonts.GetSelectEntry(), aStyles.GetText());
-            // update preview to use new font
-            aSymbolDisplay.SetSymbol( aCharsetDisplay.GetSelectCharacter(), aCharsetDisplay.GetFont() );
-        }
+			// update preview to use new font
+			aSymbolDisplay.SetSymbol( aCharsetDisplay.GetSelectCharacter(), aCharsetDisplay.GetFont() );
+		}
 		bRet = sal_True;
 	}
 	else
@@ -2410,13 +2311,12 @@ sal_Bool SmSymDefineDialog::SelectFont(const XubString &rFontName, sal_Bool bApp
 	return bRet;
 }
 
-
 sal_Bool SmSymDefineDialog::SelectStyle(const XubString &rStyleName, sal_Bool bApplyFont)
 {
 	sal_Bool   bRet = sal_False;
 	sal_uInt16 nPos = aStyles.GetEntryPos(rStyleName);
 
-    // falls der Style nicht zur Auswahl steht nehmen wir den erst moeglichen
+	// falls der Style nicht zur Auswahl steht nehmen wir den erst möglichen
 	// (sofern vorhanden)
 	if (nPos == COMBOBOX_ENTRY_NOTFOUND  &&  aStyles.GetEntryCount() > 0)
 		nPos = 0;
@@ -2425,11 +2325,11 @@ sal_Bool SmSymDefineDialog::SelectStyle(const XubString &rStyleName, sal_Bool bA
 	{
 		aStyles.SetText(aStyles.GetEntry(nPos));
 		if (bApplyFont)
-        {
+		{
 			SetFont(aFonts.GetSelectEntry(), aStyles.GetText());
-            // update preview to use new font
-            aSymbolDisplay.SetSymbol( aCharsetDisplay.GetSelectCharacter(), aCharsetDisplay.GetFont() );
-        }
+			// update preview to use new font
+			aSymbolDisplay.SetSymbol( aCharsetDisplay.GetSelectCharacter(), aCharsetDisplay.GetFont() );
+		}
 		bRet = sal_True;
 	}
 	else
@@ -2440,11 +2340,10 @@ sal_Bool SmSymDefineDialog::SelectStyle(const XubString &rStyleName, sal_Bool bA
 	return bRet;
 }
 
-
 void SmSymDefineDialog::SelectChar(xub_Unicode cChar)
 {
-    aCharsetDisplay.SelectCharacter( cChar );
-    aSymbolDisplay.SetSymbol( cChar, aCharsetDisplay.GetFont() );
+	aCharsetDisplay.SelectCharacter( cChar );
+	aSymbolDisplay.SetSymbol( cChar, aCharsetDisplay.GetFont() );
 
 	UpdateButtons();
 }
diff --git a/main/svx/inc/svx/galctrl.hxx b/main/svx/inc/svx/galctrl.hxx
index 2077d1b378..39547b6c55 100644
--- a/main/svx/inc/svx/galctrl.hxx
+++ b/main/svx/inc/svx/galctrl.hxx
@@ -19,8 +19,6 @@
  *
  *************************************************************/
 
-
-
 #ifndef _SVX_GALCTRL_HXX_
 #define _SVX_GALCTRL_HXX_
 
@@ -33,7 +31,6 @@
 #include <vcl/menu.hxx>
 #include <vcl/edit.hxx>
 #include <vcl/combobox.hxx>
-#include <vcl/sound.hxx>
 #include <svl/slstitm.hxx>
 #include <svtools/transfer.hxx>
 #include <svtools/valueset.hxx>
@@ -57,26 +54,26 @@ class SVX_DLLPUBLIC GalleryPreview : public Window, public DropTargetHelper, pub
 {
 private:
 
-    GraphicObject		aGraphicObj;
+	GraphicObject		aGraphicObj;
 	Rectangle			aPreviewRect;
-    GalleryTheme*       mpTheme;
+	GalleryTheme*		mpTheme;
 
 	SVX_DLLPRIVATE sal_Bool				ImplGetGraphicCenterRect( const Graphic& rGraphic, Rectangle& rResultRect ) const;
-    SVX_DLLPRIVATE void                InitSettings();
+	SVX_DLLPRIVATE void					InitSettings();
 
 	// Window
 	SVX_DLLPRIVATE virtual void 		Paint(const Rectangle& rRect);
 	SVX_DLLPRIVATE virtual void 		MouseButtonDown(const MouseEvent& rMEvt);
 	SVX_DLLPRIVATE virtual void		Command(const CommandEvent& rCEvt);
-	SVX_DLLPRIVATE virtual void	    KeyInput( const KeyEvent& rKEvt );
-    SVX_DLLPRIVATE virtual void        DataChanged( const DataChangedEvent& rDCEvt );
+	SVX_DLLPRIVATE virtual void		KeyInput( const KeyEvent& rKEvt );
+	SVX_DLLPRIVATE virtual void			DataChanged( const DataChangedEvent& rDCEvt );
 
 
 	// DropTargetHelper
 	SVX_DLLPRIVATE virtual sal_Int8	AcceptDrop( const AcceptDropEvent& rEvt );
 	SVX_DLLPRIVATE virtual sal_Int8	ExecuteDrop( const ExecuteDropEvent& rEvt );
 
-    // DragSourceHelper
+	// DragSourceHelper
 	SVX_DLLPRIVATE virtual void		StartDrag( sal_Int8 nAction, const Point& rPosPixel );
 
 						DECL_LINK( MenuSelectHdl, Menu* );
@@ -84,7 +81,7 @@ private:
 public:
 
 						GalleryPreview( GalleryBrowser2* pParent, GalleryTheme* pTheme );
-                        GalleryPreview( Window* pParent, const ResId& rResId  );
+						GalleryPreview( Window* pParent, const ResId& rResId  );
 						~GalleryPreview();
 
 	void				SetGraphic( const Graphic& rGraphic ) { aGraphicObj.SetGraphic( rGraphic ); }
@@ -104,22 +101,22 @@ private:
 
 	GalleryTheme*		mpTheme;
 
-    void                InitSettings();
+	void				InitSettings();
 
 	// ValueSet
 	virtual void 		UserDraw( const UserDrawEvent& rUDEvt );
 
-    // Window
-    virtual void		MouseButtonDown( const MouseEvent& rMEvt );
+	// Window
+	virtual void		MouseButtonDown( const MouseEvent& rMEvt );
 	virtual void		Command( const CommandEvent& rCEvt );
-	virtual void	    KeyInput( const KeyEvent& rKEvt );
-    virtual void        DataChanged( const DataChangedEvent& rDCEvt );
+	virtual void		KeyInput( const KeyEvent& rKEvt );
+	virtual void		DataChanged( const DataChangedEvent& rDCEvt );
 
 	// DropTargetHelper
 	virtual sal_Int8	AcceptDrop( const AcceptDropEvent& rEvt );
 	virtual sal_Int8	ExecuteDrop( const ExecuteDropEvent& rEvt );
 
-    // DragSourceHelper
+	// DragSourceHelper
 	virtual void		StartDrag( sal_Int8 nAction, const Point& rPosPixel );
 
 public:
@@ -139,27 +136,27 @@ class GalleryListView : public BrowseBox
 
 private:
 
-	Link                maSelectHdl;
-    GalleryTheme*		mpTheme;
-    sal_uIntPtr               mnCurRow;
-    sal_Bool                mbInit;
+	Link				maSelectHdl;
+	GalleryTheme*		mpTheme;
+	sal_uIntPtr				mnCurRow;
+	sal_Bool				mbInit;
 
-    void                InitSettings();
+	void				InitSettings();
 
 	// BrowseBox
-	virtual sal_Bool        SeekRow( long nRow );
-	virtual void        PaintField( OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColumnId ) const;
-	virtual void        DoubleClick( const BrowserMouseEvent& rEvt );
-	virtual void        Select();
-	virtual sal_Int8    AcceptDrop( const BrowserAcceptDropEvent& rEvt );
-	virtual sal_Int8    ExecuteDrop( const BrowserExecuteDropEvent& rEvt );
-	virtual void	    KeyInput( const KeyEvent& rKEvt );
+	virtual sal_Bool		SeekRow( long nRow );
+	virtual void		PaintField( OutputDevice& rDev, const Rectangle& rRect, sal_uInt16 nColumnId ) const;
+	virtual void		DoubleClick( const BrowserMouseEvent& rEvt );
+	virtual void		Select();
+	virtual sal_Int8	AcceptDrop( const BrowserAcceptDropEvent& rEvt );
+	virtual sal_Int8	ExecuteDrop( const BrowserExecuteDropEvent& rEvt );
+	virtual void		KeyInput( const KeyEvent& rKEvt );
 
 	// Window
-    virtual void		Command( const CommandEvent& rCEvt );
-    virtual void        DataChanged( const DataChangedEvent& rDCEvt );
+	virtual void		Command( const CommandEvent& rCEvt );
+	virtual void		DataChanged( const DataChangedEvent& rDCEvt );
 
-    // DragSourceHelper
+	// DragSourceHelper
 	virtual void		StartDrag( sal_Int8 nAction, const Point& rPosPixel );
 
 public:
@@ -167,7 +164,7 @@ public:
 						GalleryListView( GalleryBrowser2* pParent, GalleryTheme* pTheme );
 						~GalleryListView();
 
-    void                SetSelectHdl( const Link& rSelectHdl ) { maSelectHdl = rSelectHdl; }
+	void				SetSelectHdl( const Link& rSelectHdl ) { maSelectHdl = rSelectHdl; }
 
 	/** GetCellText returns the text at the given position
 		@param	_nRow
@@ -179,9 +176,11 @@ public:
 	*/
 	virtual String	GetCellText(long _nRow, sal_uInt16 _nColId) const;
 
-    // from IAccessibleTableProvider
+	// from IAccessibleTableProvider
 	virtual Rectangle GetFieldCharacterBounds(sal_Int32 _nRow,sal_Int32 _nColumnPos,sal_Int32 nIndex);
 	virtual sal_Int32 GetFieldIndexAtPoint(sal_Int32 _nRow,sal_Int32 _nColumnPos,const Point& _rPoint);
 };
 
 #endif // _SVX_GALCTRL_HXX_
+
+/* vim: set noet sw=4 ts=4: */
diff --git a/main/sw/source/core/layout/paintfrm.cxx b/main/sw/source/core/layout/paintfrm.cxx
index 6ea08d5d09..8a54bcadf4 100644
--- a/main/sw/source/core/layout/paintfrm.cxx
+++ b/main/sw/source/core/layout/paintfrm.cxx
@@ -19,14 +19,11 @@
  *
  *************************************************************/
 
-
-
 // MARKER(update_precomp.py): autogen include statement, do not remove
 #include "precompiled_sw.hxx"
 
 #include <com/sun/star/text/HoriOrientation.hpp>
 #include <hintids.hxx>
-#include <vcl/sound.hxx>
 #include <tools/poly.hxx>
 #define _SVSTDARR_LONGS
 #include <svl/svstdarr.hxx>
@@ -103,19 +100,19 @@ using namespace ::com::sun::star;
 
 #define GETOBJSHELL()		((SfxObjectShell*)rSh.GetDoc()->GetDocShell())
 
-//Tabellenhilfslinien an?
+// Tabellenhilfslinien an?
 #define IS_SUBS_TABLE \
-    (pGlobalShell->GetViewOptions()->IsTable() && \
-    !pGlobalShell->GetViewOptions()->IsPagePreview()&&\
-    !pGlobalShell->GetViewOptions()->IsReadonly()&&\
-    !pGlobalShell->GetViewOptions()->IsFormView() &&\
-     SwViewOption::IsTableBoundaries())
-//sonstige Hilfslinien an?
+	(pGlobalShell->GetViewOptions()->IsTable() && \
+	!pGlobalShell->GetViewOptions()->IsPagePreview()&&\
+	!pGlobalShell->GetViewOptions()->IsReadonly()&&\
+	!pGlobalShell->GetViewOptions()->IsFormView() &&\
+	 SwViewOption::IsTableBoundaries())
+// sonstige Hilfslinien an?
 #define IS_SUBS (!pGlobalShell->GetViewOptions()->IsPagePreview() && \
-        !pGlobalShell->GetViewOptions()->IsReadonly() && \
-        !pGlobalShell->GetViewOptions()->IsFormView() &&\
-         SwViewOption::IsDocBoundaries())
-//Hilfslinien fuer Bereiche
+		!pGlobalShell->GetViewOptions()->IsReadonly() && \
+		!pGlobalShell->GetViewOptions()->IsFormView() &&\
+		 SwViewOption::IsDocBoundaries())
+// Hilfslinien für Bereiche
 #define IS_SUBS_SECTION (!pGlobalShell->GetViewOptions()->IsPagePreview() && \
                          !pGlobalShell->GetViewOptions()->IsReadonly()&&\
                          !pGlobalShell->GetViewOptions()->IsFormView() &&\
@@ -127,14 +124,14 @@ using namespace ::com::sun::star;
 
 #define SW_MAXBORDERCACHE 20
 
-//Klassendeklarationen. Hier weil sie eben nur in diesem File benoetigt
-//werden.
+// Klassendeklarationen. Hier weil sie eben nur in diesem File benötigt
+// werden.
 
-#define SUBCOL_PAGE     0x01    //Helplines of the page
-#define SUBCOL_BREAK    0x02    //Helpline for a page or column break
-#define SUBCOL_TAB      0x08    //Helplines inside tables
-#define SUBCOL_FLY      0x10    //Helplines inside fly frames
-#define SUBCOL_SECT     0x20    //Helplines inside sections
+#define SUBCOL_PAGE		0x01 //Helplines of the page
+#define SUBCOL_BREAK	0x02 //Helpline for a page or column break
+#define SUBCOL_TAB		0x08 //Helplines inside tables
+#define SUBCOL_FLY		0x10 //Helplines inside fly frames
+#define SUBCOL_SECT		0x20 //Helplines inside sections
 
 //----- Klassen zum Sammeln von Umrandungen und Hilfslinien ---
 class SwLineRect : public SwRect
@@ -146,7 +143,7 @@ class SwLineRect : public SwRect
 		  sal_uInt8		nLock;		//Um die Linien zum Hell-Layer abzugrenzen.
 public:
 	SwLineRect( const SwRect &rRect, const Color *pCol,
-                const SwTabFrm *pT , const sal_uInt8 nSCol );
+				const SwTabFrm *pT , const sal_uInt8 nSCol );
 
 	const Color			*GetColor() const { return pColor;}
 	const SwTabFrm		*GetTab()	const { return pTab;  }
@@ -176,8 +173,8 @@ public:
 	void PaintLines  ( OutputDevice *pOut );
 	void LockLines( sal_Bool bLock );
 
-    /// OD 13.08.2002 - correct type of function
-    sal_uInt16 Free() const { return nFree; }
+	/// OD 13.08.2002 - correct type of function
+	sal_uInt16 Free() const { return nFree; }
 };
 
 class SwSubsRects : public SwLineRects
@@ -193,23 +190,23 @@ public:
 
 static ViewShell *pGlobalShell = 0;
 
-//Wenn durchsichtige FlyInCnts im PaintBackground gepaintet werden so soll der
-//Hintergrund nicht mehr retouchiert werden.
+// Wenn durchsichtige FlyInCnts im PaintBackground gepaintet werden so soll der
+// Hintergrund nicht mehr retouchiert werden.
 //static sal_Bool bLockFlyBackground = sal_False;
 
-//Wenn vom Fly ein Metafile abgezogen wird, so soll nur der FlyInhalt und vor
-//nur hintergrund vom FlyInhalt gepaintet werden.
+// Wenn vom Fly ein Metafile abgezogen wird, so soll nur der FlyInhalt und vor
+// nur hintergrund vom FlyInhalt gepaintet werden.
 static sal_Bool bFlyMetafile = sal_False;
 static OutputDevice *pFlyMetafileOut = 0;
 
-//Die Retouche fuer Durchsichtige Flys wird vom Hintergrund der Flys
-//erledigt. Dabei darf der Fly selbst natuerlich nicht ausgespart werden.
-//siehe PaintBackground und lcl_SubtractFlys()
+// Die Retouche fuer Durchsichtige Flys wird vom Hintergrund der Flys
+// erledigt. Dabei darf der Fly selbst natürlich nicht ausgespart werden.
+// siehe PaintBackground und lcl_SubtractFlys()
 static SwFlyFrm *pRetoucheFly  = 0;
 static SwFlyFrm *pRetoucheFly2 = 0;
 
-//Groesse eines Pixel und die Haelfte davon. Wird jeweils bei Eintritt in
-//SwRootFrm::Paint neu gesetzt.
+// Größe eines Pixel und die Hälfte davon. Wird jeweils bei Eintritt in
+// SwRootFrm::Paint neu gesetzt.
 static long nPixelSzW = 0, nPixelSzH = 0;
 static long nHalfPixelSzW = 0, nHalfPixelSzH = 0;
 static long nMinDistPixelW = 0, nMinDistPixelH = 0;
@@ -220,13 +217,12 @@ static double aScaleY = 1.0;
 static double aMinDistScale = 0.73;
 static double aEdgeScale = 0.5;
 
-
-//In pLines werden Umrandungen waehrend des Paint gesammelt und soweit
-//moeglich zusammengefasst.
-//In pSubsLines werden Hilfslinien gesammelt und zusammengefasst. Diese
-//werden vor der Ausgabe mit pLines abgeglichen, so dass moeglichst keine
-//Umrandungen von den Hilfslinen verdeckt werden.
-//bTablines ist waehrend des Paints einer Tabelle sal_True.
+// In pLines werden Umrandungen während des Paint gesammelt und soweit
+// möglich zusammengefasst.
+// In pSubsLines werden Hilfslinien gesammelt und zusammengefasst. Diese
+// werden vor der Ausgabe mit pLines abgeglichen, so dass möglichst keine
+// Umrandungen von den Hilfslinen verdeckt werden.
+// bTablines ist während des Paints einer Tabelle sal_True.
 static SwLineRects *pLines = 0;
 static SwSubsRects *pSubsLines = 0;
 // OD 18.11.2002 #99672# - global variable for sub-lines of body, header, footer,
@@ -237,10 +233,10 @@ static SfxProgress *pProgress = 0;
 
 static SwFlyFrm *pFlyOnlyDraw = 0;
 
-//Damit die Flys auch fuer den Hack richtig gepaintet werden koennen.
+// Damit die Flys auch für den Hack richtig gepaintet werden können.
 static sal_Bool bTableHack = sal_False;
 
-//Um das teure Ermitteln der RetoucheColor zu optimieren
+// Um das teure Ermitteln der RetoucheColor zu optimieren
 Color aGlobalRetoucheColor;
 
 //Statics fuer Umrandungsalignment setzen.
@@ -249,10 +245,10 @@ Color aGlobalRetoucheColor;
 // values of <nHalfPixelSzW> and <nHalfPixelSzH> are set to ZERO.
 void SwCalcPixStatics( OutputDevice *pOut )
 {
-    // OD 30.04.2003 #107169# - determine 'small' twip-to-pixel relation
-    sal_Bool bSmallTwipToPxRelW = sal_False;
-    sal_Bool bSmallTwipToPxRelH = sal_False;
-    {
+	// OD 30.04.2003 #107169# - determine 'small' twip-to-pixel relation
+	sal_Bool bSmallTwipToPxRelW = sal_False;
+	sal_Bool bSmallTwipToPxRelH = sal_False;
+	{
         Size aCheckTwipToPxRelSz( pOut->PixelToLogic( Size( 100, 100 )) );
         if ( (aCheckTwipToPxRelSz.Width()/100.0) < 2.0 )
         {
@@ -262,37 +258,37 @@ void SwCalcPixStatics( OutputDevice *pOut )
         {
             bSmallTwipToPxRelH = sal_True;
         }
-    }
+	}
 
-    Size aSz( pOut->PixelToLogic( Size( 1,1 )) );
+	Size aSz( pOut->PixelToLogic( Size( 1,1 )) );
 
-    nPixelSzW = aSz.Width();
-    if( !nPixelSzW )
-        nPixelSzW = 1;
-    nPixelSzH = aSz.Height();
-    if( !nPixelSzH )
-        nPixelSzH = 1;
+	nPixelSzW = aSz.Width();
+	if( !nPixelSzW )
+		nPixelSzW = 1;
+	nPixelSzH = aSz.Height();
+	if( !nPixelSzH )
+		nPixelSzH = 1;
 
-    // OD 06.05.2003 #107169# - consider 'small' twip-to-pixel relations
-    if ( !bSmallTwipToPxRelW )
-    {
+	// OD 06.05.2003 #107169# - consider 'small' twip-to-pixel relations
+	if ( !bSmallTwipToPxRelW )
+	{
         nHalfPixelSzW = nPixelSzW / 2 + 1;
     }
     else
     {
         nHalfPixelSzW = 0;
-    }
-    // OD 06.05.2003 #107169# - consider 'small' twip-to-pixel relations
-    if ( !bSmallTwipToPxRelH )
-    {
-        nHalfPixelSzH = nPixelSzH / 2 + 1;
-    }
-    else
-    {
-        nHalfPixelSzH = 0;
-    }
+	}
+	// OD 06.05.2003 #107169# - consider 'small' twip-to-pixel relations
+	if ( !bSmallTwipToPxRelH )
+	{
+		nHalfPixelSzH = nPixelSzH / 2 + 1;
+	}
+	else
+	{
+		nHalfPixelSzH = 0;
+	}
 
-    nMinDistPixelW = nPixelSzW * 2 + 1;
+	nMinDistPixelW = nPixelSzW * 2 + 1;
 	nMinDistPixelH = nPixelSzH * 2 + 1;
 
 	const MapMode &rMap = pOut->GetMapMode();
@@ -311,9 +307,9 @@ class SwSavePaintStatics
 					   *pSFlyOnlyDraw;
 	SwLineRects		   *pSLines;
 	SwSubsRects		   *pSSubsLines;
-    // --> OD 2005-07-04 #123196#
-    SwSubsRects*        pSSpecSubsLines;
-    // <--
+	// --> OD 2005-07-04 #123196#
+	SwSubsRects*		pSSpecSubsLines;
+	// <--
 	SfxProgress		   *pSProgress;
 	long				nSPixelSzW,
 						nSPixelSzH,
@@ -331,16 +327,16 @@ public:
 
 SwSavePaintStatics::SwSavePaintStatics() :
 	bSFlyMetafile       ( bFlyMetafile      ),
-    pSGlobalShell       ( pGlobalShell      ),
+	pSGlobalShell       ( pGlobalShell      ),
 	pSFlyMetafileOut    ( pFlyMetafileOut   ),
 	pSRetoucheFly       ( pRetoucheFly      ),
 	pSRetoucheFly2      ( pRetoucheFly2     ),
 	pSFlyOnlyDraw       ( pFlyOnlyDraw      ),
 	pSLines             ( pLines            ),
 	pSSubsLines         ( pSubsLines        ),
-    // --> OD 2005-07-04 #123196#
-    pSSpecSubsLines     ( pSpecSubsLines    ),
-    // <--
+	// --> OD 2005-07-04 #123196#
+	pSSpecSubsLines     ( pSpecSubsLines    ),
+	// <--
 	pSProgress          ( pProgress         ),
 	nSPixelSzW          ( nPixelSzW         ),
 	nSPixelSzH          ( nPixelSzH         ),
@@ -350,9 +346,9 @@ SwSavePaintStatics::SwSavePaintStatics() :
 	nSMinDistPixelH     ( nMinDistPixelH    ),
 	aSGlobalRetoucheColor( aGlobalRetoucheColor ),
 	aSScaleX            ( aScaleX           ),
-    aSScaleY            ( aScaleY           )
+	aSScaleY            ( aScaleY           )
 {
-    bFlyMetafile = sal_False;
+	bFlyMetafile = sal_False;
 	pFlyMetafileOut = 0;
 	pRetoucheFly  = 0;
 	pRetoucheFly2 = 0;
@@ -364,9 +360,9 @@ SwSavePaintStatics::SwSavePaintStatics() :
 	aEdgeScale = 0.5;
 	pLines = 0;
 	pSubsLines = 0;
-    // --> OD 2005-07-04 #123196#
-    pSpecSubsLines = 0L;
-    // <--
+	// --> OD 2005-07-04 #123196#
+	pSpecSubsLines = 0L;
+	// <--
 	pProgress = 0;
 }
 
@@ -374,16 +370,16 @@ SwSavePaintStatics::~SwSavePaintStatics()
 {
 	pGlobalShell	   = pSGlobalShell;
 	bFlyMetafile       = bSFlyMetafile;
-    pFlyMetafileOut    = pSFlyMetafileOut;
+	pFlyMetafileOut    = pSFlyMetafileOut;
 	pRetoucheFly       = pSRetoucheFly;
 	pRetoucheFly2      = pSRetoucheFly2;
 	pFlyOnlyDraw       = pSFlyOnlyDraw;
 	pLines             = pSLines;
 	pSubsLines         = pSSubsLines;
-    // --> OD 2005-07-04 #123196#
-    pSpecSubsLines     = pSSpecSubsLines;
-    // <--
-    pProgress          = pSProgress;
+	// --> OD 2005-07-04 #123196#
+	pSpecSubsLines     = pSSpecSubsLines;
+	// <--
+	pProgress          = pSProgress;
 	nPixelSzW          = nSPixelSzW;
 	nPixelSzH          = nSPixelSzH;
 	nHalfPixelSzW      = nSHalfPixelSzW;
@@ -399,15 +395,14 @@ SwSavePaintStatics::~SwSavePaintStatics()
 
 SV_IMPL_VARARR( SwLRects, SwLineRect );
 
-
 SwLineRect::SwLineRect( const SwRect &rRect, const Color *pCol,
 						const SwTabFrm *pT, const sal_uInt8 nSCol ) :
 	SwRect( rRect ),
 	pColor( pCol ),
 	pTab( pT ),
-    nSubColor( nSCol ),
-    bPainted( sal_False ),
-    nLock( 0 )
+	nSubColor( nSCol ),
+	bPainted( sal_False ),
+	nLock( 0 )
 {
 }
 
@@ -434,10 +429,10 @@ sal_Bool SwLineRect::MakeUnion( const SwRect &rRect )
 	{
 		if ( Top()	== rRect.Top() && Height() == rRect.Height() )
 		{
-			//Zusammenfassen wenn kein Luecke zwischen den Linien ist.
+			// Zusammenfassen wenn kein Lücke zwischen den Linien ist.
 			const long nAdd = nPixelSzW + nHalfPixelSzW;
 			if ( Right() + nAdd >= rRect.Left() &&
-                 Left()  - nAdd <= rRect.Right() )
+				 Left()  - nAdd <= rRect.Right() )
 			{
 				Right( Max( Right(), rRect.Right() ) );
 				Left ( Min( Left(),  rRect.Left()  ) );
@@ -451,12 +446,12 @@ sal_Bool SwLineRect::MakeUnion( const SwRect &rRect )
 void SwLineRects::AddLineRect( const SwRect &rRect, const Color *pCol,
 							   const SwTabFrm *pTab, const sal_uInt8 nSCol )
 {
-	//Rueckwaerts durch, weil Linien die zusammengefasst werden koennen i.d.R.
-	//im gleichen Kontext gepaintet werden.
+	// Rückwärts durch, weil Linien die zusammengefasst werden können i.d.R.
+	// im gleichen Kontext gepaintet werden.
 	for ( sal_uInt16 i = Count(); i ; )
 	{
 		SwLineRect &rLRect = operator[](--i);
-		//Pruefen von Ausrichtung, Farbe, Tabelle.
+		// Prüfen von Ausrichtung, Farbe, Tabelle.
 		if ( rLRect.GetTab() == pTab &&
 			 !rLRect.IsPainted() && rLRect.GetSubColor() == nSCol &&
 			 (rLRect.Height() > rLRect.Width()) == (rRect.Height() > rRect.Width()) &&
@@ -474,7 +469,7 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 {
 	if ( pOut->GetOutDevType() != OUTDEV_PRINTER )
 	{
-		//Fuer einen zu kleinen Zoom arbeite ich nicht.
+		// Für einen zu kleinen Zoom arbeite ich nicht.
 		if ( aScaleX < aEdgeScale || aScaleY < aEdgeScale )
 			return;
 	}
@@ -495,17 +490,17 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 		long nL1a, nL1b, nL1c, nL1d;
 
 		if ( bVert )
-        {
-            nL1a = rL1.Top();   nL1b = rL1.Left();
+		{
+			nL1a = rL1.Top();   nL1b = rL1.Left();
 			nL1c = rL1.Right(); nL1d = rL1.Bottom();
 		}
 		else
-        {
-            nL1a = rL1.Left();   nL1b = rL1.Top();
+		{
+			nL1a = rL1.Left();   nL1b = rL1.Top();
 			nL1c = rL1.Bottom(); nL1d = rL1.Right();
 		}
 
-		//Alle moeglicherweise mit i1 zu verbindenden Linien einsammeln.
+		// Alle möglicherweise mit i1 zu verbindenden Linien einsammeln.
 		for ( sal_uInt16 i2 = 0; i2 < Count(); ++i2 )
 		{
 			SwLineRect &rL2 = operator[](i2);
@@ -517,13 +512,13 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 
 			long nL2a, nL2b, nL2c, nL2d;
 			if ( bVert )
-            {
-                nL2a = rL2.Top();   nL2b = rL2.Left();
+			{
+				nL2a = rL2.Top();   nL2b = rL2.Left();
 				nL2c = rL2.Right(); nL2d = rL2.Bottom();
 			}
 			else
-            {
-                nL2a = rL2.Left();   nL2b = rL2.Top();
+			{
+				nL2a = rL2.Left();   nL2b = rL2.Top();
 				nL2c = rL2.Bottom(); nL2d = rL2.Right();
 			}
 
@@ -541,7 +536,7 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 
 		sal_Bool bRemove = sal_False;
 
-		//Fuer jede Linie jede alle folgenden checken.
+		// Für jede Linie jede alle folgenden checken.
 		for ( sal_uInt16 k = 0; !bRemove && k < aCheck.Count(); ++k )
 		{
 			SwLineRect &rR1 = (SwLineRect&)*(SwLineRect*)aCheck[k];
@@ -552,7 +547,7 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 				if ( bVert )
 				{
 					SwLineRect *pLA = 0;
-                    SwLineRect *pLB = 0;
+					SwLineRect *pLB = 0;
 					if ( rR1.Top() < rR2.Top() )
 					{
 						pLA = &rR1; pLB = &rR2;
@@ -561,22 +556,22 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 					{
 						pLA = &rR2; pLB = &rR1;
 					}
-					//beschreiben k1 und k2 eine Doppellinie?
+					// beschreiben k1 und k2 eine Doppellinie?
 					if ( pLA && pLA->Bottom() + 60 > pLB->Top() )
 					{
 						if ( rL1.Top() < pLA->Top() )
 						{
 							if ( rL1.Bottom() == pLA->Bottom() )
-								continue;	//kleiner Irrtum (woher?)
+								continue;	// kleiner Irrtum (woher?)
 
 							SwRect aIns( rL1 );
 							aIns.Bottom( pLA->Bottom() );
 							if ( !rL1.IsInside( aIns ) )
 								continue;
-                            const sal_uInt16 nTmpFree = Free();
+							const sal_uInt16 nTmpFree = Free();
 							Insert( SwLineRect( aIns, rL1.GetColor(),
-                                        rL1.GetTab(), SUBCOL_TAB ), Count() );
-                            if ( !nTmpFree )
+									rL1.GetTab(), SUBCOL_TAB ), Count() );
+							if ( !nTmpFree )
 							{
 								--i;
 								k = aCheck.Count();
@@ -585,15 +580,15 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 						}
 
 						if ( rL1.Bottom() > pLB->Bottom() )
-							rL1.Top( pLB->Top() );	//i1 nach oben verlaengern
+							rL1.Top( pLB->Top() );	// i1 nach oben verlängern
 						else
-							bRemove = sal_True;			//abbrechen, i1 entfernen
+							bRemove = sal_True;			// abbrechen, i1 entfernen
 					}
 				}
 				else
 				{
 					SwLineRect *pLA = 0;
-                    SwLineRect *pLB = 0;
+					SwLineRect *pLB = 0;
 					if ( rR1.Left() < rR2.Left() )
 					{
 						pLA = &rR1; pLB = &rR2;
@@ -602,22 +597,22 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 					{
 						pLA = &rR2; pLB = &rR1;
 					}
-					//Liegt eine 'doppellinie' vor?
+					// Liegt eine 'Doppellinie' vor?
 					if ( pLA && pLA->Right() + 60 > pLB->Left() )
 					{
 						if ( rL1.Left() < pLA->Left() )
 						{
 							if ( rL1.Right() == pLA->Right() )
-								continue;	//kleiner irrtum
+								continue;	// kleiner Irrtum
 
 							SwRect aIns( rL1 );
 							aIns.Right( pLA->Right() );
 							if ( !rL1.IsInside( aIns ) )
 								continue;
-                            const sal_uInt16 nTmpFree = Free();
+							const sal_uInt16 nTmpFree = Free();
 							Insert( SwLineRect( aIns, rL1.GetColor(),
-                                        rL1.GetTab(), SUBCOL_TAB ), Count() );
-                            if ( !nTmpFree )
+									rL1.GetTab(), SUBCOL_TAB ), Count() );
+							if ( !nTmpFree )
 							{
 								--i;
 								k = aCheck.Count();
@@ -635,66 +630,66 @@ void SwLineRects::ConnectEdges( OutputDevice *pOut )
 		if ( bRemove )
 		{
 			Remove( static_cast<sal_uInt16>(i), 1 );
-			--i;			//keinen auslassen!
+			--i;			// keinen auslassen!
 		}
 	}
 }
 
 inline void SwSubsRects::Ins( const SwRect &rRect, const sal_uInt8 nSCol )
 {
-	//Linien die kuerzer als die breiteste Linienbreite sind werden
-	//nicht aufgenommen.
+	// Linien die kürzer als die breiteste Linienbreite sind werden
+	// nicht aufgenommen.
 	if ( rRect.Height() > DEF_LINE_WIDTH_4 || rRect.Width() > DEF_LINE_WIDTH_4 )
 		Insert( SwLineRect( rRect, 0, 0, nSCol ), Count());
 }
 
 void SwSubsRects::RemoveSuperfluousSubsidiaryLines( const SwLineRects &rRects )
 {
-	//Alle Hilfslinien, die sich mit irgendwelchen Umrandungen decken werden
-	//entfernt bzw. zerstueckelt..
+	// Alle Hilfslinien, die sich mit irgendwelchen Umrandungen decken werden
+	// entfernt bzw. zerstückelt..
 	for ( sal_uInt16 i = 0; i < Count(); ++i )
 	{
-        // OD 18.11.2002 #99672# - get a copy instead of a reference, because
-        // an <insert> may destroy the object due to a necessary array resize.
-        const SwLineRect aSubsLineRect = SwLineRect( operator[](i) );
-
-        // OD 19.12.2002 #106318# - add condition <aSubsLineRect.IsLocked()>
-        // in order to consider only border lines, which are *not* locked.
-        if ( aSubsLineRect.IsPainted() ||
-             aSubsLineRect.IsLocked() )
+		// OD 18.11.2002 #99672# - get a copy instead of a reference, because
+		// an <insert> may destroy the object due to a necessary array resize.
+		const SwLineRect aSubsLineRect = SwLineRect( operator[](i) );
+
+		// OD 19.12.2002 #106318# - add condition <aSubsLineRect.IsLocked()>
+		// in order to consider only border lines, which are *not* locked.
+		if ( aSubsLineRect.IsPainted() ||
+			 aSubsLineRect.IsLocked() )
 			continue;
 
-        const bool bVerticalSubs = aSubsLineRect.Height() > aSubsLineRect.Width();
-        SwRect aSubsRect( aSubsLineRect );
-        if ( bVerticalSubs )
+		const bool bVerticalSubs = aSubsLineRect.Height() > aSubsLineRect.Width();
+		SwRect aSubsRect( aSubsLineRect );
+		if ( bVerticalSubs )
 		{
-            aSubsRect.Left  ( aSubsRect.Left()  - (nPixelSzW+nHalfPixelSzW) );
-            aSubsRect.Right ( aSubsRect.Right() + (nPixelSzW+nHalfPixelSzW) );
+			aSubsRect.Left  ( aSubsRect.Left()  - (nPixelSzW+nHalfPixelSzW) );
+			aSubsRect.Right ( aSubsRect.Right() + (nPixelSzW+nHalfPixelSzW) );
 		}
 		else
 		{
-            aSubsRect.Top   ( aSubsRect.Top()    - (nPixelSzH+nHalfPixelSzH) );
-            aSubsRect.Bottom( aSubsRect.Bottom() + (nPixelSzH+nHalfPixelSzH) );
+			aSubsRect.Top   ( aSubsRect.Top()    - (nPixelSzH+nHalfPixelSzH) );
+			aSubsRect.Bottom( aSubsRect.Bottom() + (nPixelSzH+nHalfPixelSzH) );
 		}
 		for ( sal_uInt16 k = 0; k < rRects.Count(); ++k )
 		{
 			SwLineRect &rLine = rRects[k];
 
-            // OD 20.12.2002 #106318# - do *not* consider painted or locked
-            // border lines.
-            // OD 20.01.2003 #i1837# - locked border lines have to be considered.
-            if ( rLine.IsLocked () )
-                continue;
+			// OD 20.12.2002 #106318# - do *not* consider painted or locked
+			// border lines.
+			// OD 20.01.2003 #i1837# - locked border lines have to be considered.
+			if ( rLine.IsLocked () )
+				continue;
 
-            if ( (!bVerticalSubs == (rLine.Height() > rLine.Width())) ) //gleiche Ausrichtung?
+			if ( (!bVerticalSubs == (rLine.Height() > rLine.Width())) ) //gleiche Ausrichtung?
 				continue;
 
-            if ( aSubsRect.IsOver( rLine ) )
+			if ( aSubsRect.IsOver( rLine ) )
 			{
-                if ( bVerticalSubs ) //Vertikal?
+				if ( bVerticalSubs ) //Vertikal?
 				{
-                    if ( aSubsRect.Left()  <= rLine.Right() &&
-                         aSubsRect.Right() >= rLine.Left() )
+					if ( aSubsRect.Left()  <= rLine.Right() &&
+						 aSubsRect.Right() >= rLine.Left() )
 					{
 						long nTmp = rLine.Top()-(nPixelSzH+1);
                         if ( aSubsLineRect.Top() < nTmp )
@@ -756,18 +751,18 @@ void SwLineRects::LockLines( sal_Bool bLock )
 
 void SwLineRects::PaintLines( OutputDevice *pOut )
 {
-	//Painten der Umrandungen. Leider muessen wir zweimal durch.
-	//Einmal fuer die innenliegenden und einmal fuer die Aussenkanten
-	//der Tabellen.
+	// Painten der Umrandungen. Leider müssen wir zweimal durch.
+	// Einmal für die innenliegenden und einmal für die Außenkanten
+	// der Tabellen.
 	if ( Count() != nLastCount )
 	{
-        // --> FME 2004-06-24 #i16816# tagged pdf support
-        SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pOut );
-        // <--
+		// --> FME 2004-06-24 #i16816# tagged pdf support
+		SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pOut );
+		// <--
 
-        // OD 2004-04-23 #116347#
-        pOut->Push( PUSH_FILLCOLOR|PUSH_LINECOLOR );
-        pOut->SetLineColor();
+		// OD 2004-04-23 #116347#
+		pOut->Push( PUSH_FILLCOLOR|PUSH_LINECOLOR );
+		pOut->SetLineColor();
 		ConnectEdges( pOut );
 		const Color *pLast = 0;
 
@@ -788,13 +783,13 @@ void SwLineRects::PaintLines( OutputDevice *pOut )
 				continue;
 			}
 
-			//Jetzt malen oder erst in der zweiten Runde?
+			// Jetzt malen oder erst in der zweiten Runde?
 			sal_Bool bPaint = sal_True;
 			if ( rLRect.GetTab() )
 			{
 				if ( rLRect.Height() > rLRect.Width() )
 				{
-					//Senkrechte Kante, ueberlappt sie mit der TabellenKante?
+					// Senkrechte Kante, überlappt sie mit der Tabellenkante?
 					SwTwips nLLeft	= rLRect.Left()  - 30,
 							nLRight = rLRect.Right() + 30,
 							nTLeft	= rLRect.GetTab()->Frm().Left() + rLRect.GetTab()->Prt().Left(),
@@ -804,7 +799,7 @@ void SwLineRects::PaintLines( OutputDevice *pOut )
 						bPaint = sal_False;
 				}
 				else
-				{	//Waagerechte Kante, ueberlappt sie mit der Tabellenkante?
+				{	//Waagerechte Kante, überlappt sie mit der Tabellenkante?
 					SwTwips nLTop	 = rLRect.Top()    - 30,
 							nLBottom = rLRect.Bottom() + 30,
 							nTTop	 = rLRect.GetTab()->Frm().Top()  + rLRect.GetTab()->Prt().Top(),
@@ -816,7 +811,7 @@ void SwLineRects::PaintLines( OutputDevice *pOut )
 			}
 			if ( bPaint )
 			{
-                if ( !pLast || *pLast != *rLRect.GetColor() )
+				if ( !pLast || *pLast != *rLRect.GetColor() )
 				{
 					pLast = rLRect.GetColor();
 
@@ -876,15 +871,15 @@ void SwSubsRects::PaintSubsidiary( OutputDevice *pOut,
 {
 	if ( Count() )
 	{
-        // --> FME 2004-06-24 #i16816# tagged pdf support
-        SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pOut );
-        // <--
+		// --> FME 2004-06-24 #i16816# tagged pdf support
+		SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pOut );
+		// <--
 
-		//Alle Hilfslinien, die sich fast decken entfernen (Tabellen)
+		// Alle Hilfslinien, die sich fast decken entfernen (Tabellen)
 		for ( sal_uInt16 i = 0; i < Count(); ++i )
 		{
 			SwLineRect &rLi = operator[](i);
-            const bool bVerticalSubs = rLi.Height() > rLi.Width();
+			const bool bVerticalSubs = rLi.Height() > rLi.Width();
 
 			for ( sal_uInt16 k = i+1; k < Count(); ++k )
 			{
@@ -902,8 +897,8 @@ void SwSubsRects::PaintSubsidiary( OutputDevice *pOut,
 								  (nLk < rLi.Left() && nLk+21 > rLi.Left())))
 							{
 								Remove( k, 1 );
-								//Nicht mit der inneren Schleife weiter, weil
-								//das Array schrumpfen koennte!
+								// Nicht mit der inneren Schleife weiter, weil
+								// das Array schrumpfen könnte!
 								--i; k = Count();
 							}
 						}
@@ -924,15 +919,14 @@ void SwSubsRects::PaintSubsidiary( OutputDevice *pOut,
 			}
 		}
 
-
 		if ( pRects && pRects->Count() )
 			RemoveSuperfluousSubsidiaryLines( *pRects );
 
 		if ( Count() )
 		{
-            // OD 2004-04-23 #116347#
-            pOut->Push( PUSH_FILLCOLOR|PUSH_LINECOLOR );
-            pOut->SetLineColor();
+			// OD 2004-04-23 #116347#
+			pOut->Push( PUSH_FILLCOLOR|PUSH_LINECOLOR );
+			pOut->SetLineColor();
 
             // OD 14.01.2003 #106660# - reset draw mode in high contrast
             // mode in order to get fill color set at output device.
@@ -1066,7 +1060,7 @@ void MA_FASTCALL SwAlignRect( SwRect &rRect, ViewShell *pSh )
         bZeroHeight = sal_True;
     }
 
-    rRect = pOut->PixelToLogic( aAlignedPxRect.SVRect() );
+	rRect = pOut->PixelToLogic( aAlignedPxRect.SVRect() );
 
     // OD 30.04.2003 #107169# - consider zero width/height and adjust calculated
     // aligned twip rectangle.
@@ -1084,11 +1078,11 @@ void MA_FASTCALL SwAlignRect( SwRect &rRect, ViewShell *pSh )
 
 /** OD 19.05.2003 #109667# - helper method for twip adjustments on pixel base
 
-    method compares the x- or y-pixel position of two twip-point. If the x-/y-pixel
-    positions are the same, the x-/y-pixel position of the second twip point is
-    adjusted by a given amount of pixels.
+	method compares the x- or y-pixel position of two twip-point. If the x-/y-pixel
+	positions are the same, the x-/y-pixel position of the second twip point is
+	adjusted by a given amount of pixels.
 
-    @author OD
+	@author OD
 */
 void lcl_CompPxPosAndAdjustPos( const OutputDevice&  _rOut,
                                 const Point&         _rRefPt,
@@ -1131,18 +1125,18 @@ void lcl_CompPxPosAndAdjustPos( const OutputDevice&  _rOut,
     with left-top-corner and size.
     Call this method before each <GraphicObject.Draw(...)>
 
-    @author OD
+	@author OD
 */
 void SwAlignGrfRect( SwRect *pGrfRect, const OutputDevice &rOut )
 {
-    Rectangle aPxRect = rOut.LogicToPixel( pGrfRect->SVRect() );
-    pGrfRect->Pos( rOut.PixelToLogic( aPxRect.TopLeft() ) );
-    pGrfRect->SSize( rOut.PixelToLogic( aPxRect.GetSize() ) );
+	Rectangle aPxRect = rOut.LogicToPixel( pGrfRect->SVRect() );
+	pGrfRect->Pos( rOut.PixelToLogic( aPxRect.TopLeft() ) );
+	pGrfRect->SSize( rOut.PixelToLogic( aPxRect.GetSize() ) );
 }
 
 long MA_FASTCALL lcl_AlignWidth( const long nWidth )
 {
-    if ( nWidth )
+	if ( nWidth )
 	{
 		const long nW = nWidth % nPixelSzW;
 
@@ -1178,7 +1172,6 @@ long MA_FASTCALL lcl_MinWidthDist( const long nDist )
 	return ::lcl_AlignWidth( Max( nDist, nMinDistPixelW ));
 }
 
-
 //Ermittelt PrtArea plus Umrandung plus Schatten.
 void MA_FASTCALL lcl_CalcBorderRect( SwRect &rRect, const SwFrm *pFrm,
 										const SwBorderAttrs &rAttrs,
@@ -1223,7 +1216,7 @@ void MA_FASTCALL lcl_CalcBorderRect( SwRect &rRect, const SwFrm *pFrm,
                     (rRect.*fnRect->fnSubTop)( nDiff );
 			}
 
-            const sal_Bool bBottom = 0 != (pFrm->*fnRect->fnGetBottomMargin)();
+			const sal_Bool bBottom = 0 != (pFrm->*fnRect->fnGetBottomMargin)();
 			if ( bBottom )
 			{
                 SwTwips nDiff = 0;
@@ -1283,22 +1276,21 @@ void MA_FASTCALL lcl_ExtendLeftAndRight( SwRect&                _rRect,
                                          const SwBorderAttrs&   _rAttrs,
                                          const SwRectFn&        _rRectFn )
 {
-    // OD 21.05.2003 #108789# - extend left/right border/shadow rectangle to
-    // bottom of previous frame/to top of next frame, if border/shadow is joined
-    // with previous/next frame.
-    if ( _rAttrs.JoinedWithPrev( _rFrm ) )
+	// OD 21.05.2003 #108789# - extend left/right border/shadow rectangle to
+	// bottom of previous frame/to top of next frame, if border/shadow is joined
+	// with previous/next frame.
+	if ( _rAttrs.JoinedWithPrev( _rFrm ) )
 	{
-        const SwFrm* pPrevFrm = _rFrm.GetPrev();
-        (_rRect.*_rRectFn->fnSetTop)( (pPrevFrm->*_rRectFn->fnGetPrtBottom)() );
+		const SwFrm* pPrevFrm = _rFrm.GetPrev();
+		(_rRect.*_rRectFn->fnSetTop)( (pPrevFrm->*_rRectFn->fnGetPrtBottom)() );
 	}
-    if ( _rAttrs.JoinedWithNext( _rFrm ) )
+	if ( _rAttrs.JoinedWithNext( _rFrm ) )
 	{
-        const SwFrm* pNextFrm = _rFrm.GetNext();
-        (_rRect.*_rRectFn->fnSetBottom)( (pNextFrm->*_rRectFn->fnGetPrtTop)() );
+		const SwFrm* pNextFrm = _rFrm.GetNext();
+		(_rRect.*_rRectFn->fnSetBottom)( (pNextFrm->*_rRectFn->fnGetPrtTop)() );
 	}
 }
 
-
 //void MA_FASTCALL lcl_SubtractFlys( const SwFrm *pFrm, const SwPageFrm *pPage,
 //						   const SwRect &rRect, SwRegionRects &rRegion )
 //{
@@ -1339,14 +1331,14 @@ void MA_FASTCALL lcl_ExtendLeftAndRight( SwRect&                _rRect,
 //        if ( pSelfFly && pSelfFly->IsLowerOf( pFly ) )
 //			continue;
 //
-//		//#57194# Und warum gilt das nicht analog fuer den RetoucheFly?
+//		// #57194# Und warum gilt das nicht analog für den RetoucheFly?
 //        if ( pRetoucheFly && pRetoucheFly->IsLowerOf( pFly ) )
 //			continue;
 //
 //
 //#ifdef DBG_UTIL
-//		//Flys, die innerhalb des eigenen verankert sind, muessen eine
-//		//groessere OrdNum haben oder Zeichengebunden sein.
+//		// Flys, die innerhalb des eigenen verankert sind, müssen eine
+//		// größere OrdNum haben oder Zeichengebunden sein.
 //		if ( pSelfFly && bLowerOfSelf )
 //		{
 //			ASSERT( pFly->IsFlyInCntFrm() ||
@@ -1362,14 +1354,14 @@ void MA_FASTCALL lcl_ExtendLeftAndRight( SwRect&                _rRect,
 //            if ( pSdrObj->GetLayer() == pTmp->GetLayer() )
 //			{
 //                if ( pSdrObj->GetOrdNumDirect() < pTmp->GetOrdNumDirect() )
-//					//Im gleichen Layer werden nur obenliegende beachtet.
+//					// Im gleichen Layer werden nur obenliegende beachtet.
 //					continue;
 //			}
 //			else
 //			{
 //				if ( !bLowerOfSelf && !pFly->GetFmt()->GetOpaque().GetValue() )
-//					//Aus anderem Layer interessieren uns nur nicht transparente
-//					//oder innenliegende
+//					// Aus anderem Layer interessieren uns nur nicht transparente
+//					// oder innenliegende
 //					continue;
 //				bStopOnHell = sal_False;
 //			}
@@ -1393,10 +1385,10 @@ void MA_FASTCALL lcl_ExtendLeftAndRight( SwRect&                _rRect,
 //			}
 //		}
 //
-//		//Wenn der Inhalt des Fly Transparent ist, wird er nicht abgezogen, es sei denn
-//		//er steht im Hell-Layer (#31941#)
-//        const IDocumentDrawModelAccess* pIDDMA = pFly->GetFmt()->getIDocumentDrawModelAccess();
-//        sal_Bool bHell = pSdrObj->GetLayer() == pIDDMA->GetHellId();
+//		// Wenn der Inhalt des Fly Transparent ist, wird er nicht abgezogen, es sei denn
+//		// er steht im Hell-Layer (#31941#)
+//		const IDocumentDrawModelAccess* pIDDMA = pFly->GetFmt()->getIDocumentDrawModelAccess();
+//		sal_Bool bHell = pSdrObj->GetLayer() == pIDDMA->GetHellId();
 //		if ( (bStopOnHell && bHell) ||
 //             /// OD 05.08.2002 - change internal order of condition
 //             ///    first check "!bHell", then "..->Lower()" and "..->IsNoTxtFrm()"
@@ -1472,8 +1464,8 @@ void MA_FASTCALL lcl_ExtendLeftAndRight( SwRect&                _rRect,
 // --> OD 2008-05-16 #i84659# - no longer needed
 //inline sal_Bool IsShortCut( const SwRect &rRect, const SwRect &rFrmRect )
 //{
-//    //Wenn der Frm vollstaendig rechts neben bzw. unter dem
-//    //Rect sitzt ist's genug mit Painten.
+//    // Wenn der Frm vollständig rechts neben bzw. unter dem
+//    // Rect sitzt ist es genug mit Painten.
 //        return rFrmRect.Top() > rRect.Bottom();
 //        // PAGES01 || (rFrmRect.Left() > rRect.Right()) );
 //}
@@ -2155,10 +2147,7 @@ void lcl_AdjustRectToPixelSize( SwRect& io_aSwRect, const OutputDevice &aOut )
 #endif
 }
 
-
-//
 // FUNCTIONS USED FOR COLLAPSING TABLE BORDER LINES START
-//
 
 struct SwLineEntry
 {
@@ -2786,9 +2775,7 @@ void SwTabFrmPainter::Insert( SwLineEntry& rNew, bool bHori )
         pLineSet->insert( rNew );
 }
 
-//
 // FUNCTIONS USED FOR COLLAPSING TABLE BORDER LINES END
-//
 
 // --> OD #i76669#
 namespace
@@ -2832,7 +2819,6 @@ namespace
 // <--
 
 /*************************************************************************
-|*
 |*	SwRootFrm::Paint()
 |*
 |*	Beschreibung
@@ -2841,11 +2827,10 @@ namespace
 |*		2. Den Draw Layer (Rahmen und Zeichenobjekte) der unter dem Dokument
 |* 		   liegt painten (Hoelle).
 |*		3. Den Dokumentinhalt (Text) Painten.
-|*		4. Den Drawlayer der ueber dem Dokument liegt painten.
+|*		4. Den Drawlayer der über dem Dokument liegt painten.
 |*
 |*	Ersterstellung		MA 01. Jun. 92
-|*	Letzte Aenderung	MA 10. Oct. 97
-|*
+|*	Letzte Änderung		MA 10. Oct. 97
 |*************************************************************************/
 
 void
@@ -3195,12 +3180,10 @@ SwRootFrm::Paint(SwRect const& rRect, SwPrintData const*const pPrintData) const
 #ifdef LONG_TABLE_HACK
 
 /*************************************************************************
-|*
 |*	SwRootFrm::HackPrepareLongTblPaint()
 |*
 |*	Ersterstellung		MA 27. Sep. 96
-|*	Letzte Aenderung	MA 18. Nov. 97
-|*
+|*	Letzte Änderung		MA 18. Nov. 97
 |*************************************************************************/
 
 void SwRootFrm::HackPrepareLongTblPaint( int nMode )
@@ -3227,14 +3210,11 @@ void SwRootFrm::HackPrepareLongTblPaint( int nMode )
 
 #endif
 
-
 /*************************************************************************
-|*
 |*	SwLayoutFrm::Paint()
 |*
 |*	Ersterstellung		MA 19. May. 92
-|*	Letzte Aenderung	MA 19. Apr. 95
-|*
+|*	Letzte Änderung		MA 19. Apr. 95
 |*************************************************************************/
 
 void MA_FASTCALL lcl_EmergencyFormatFtnCont( SwFtnContFrm *pCont )
@@ -3410,7 +3390,6 @@ void SwLayoutFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 	}
 }
 
-
 /** FlyFrm::IsBackgroundTransparent - for feature #99657#
 
     OD 12.08.2002
@@ -3490,12 +3469,10 @@ sal_Bool SwFlyFrm::IsShadowTransparent() const
 };
 
 /*************************************************************************
-|*
 |*	SwFlyFrm::IsPaint()
 |*
 |*	Ersterstellung		MA 16. Jan. 97
-|*	Letzte Aenderung	MA 16. Jan. 97
-|*
+|*	Letzte Änderung		MA 16. Jan. 97
 |*************************************************************************/
 
 sal_Bool SwFlyFrm::IsPaint( SdrObject *pObj, const ViewShell *pSh )
@@ -3605,12 +3582,10 @@ void SwCellFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 }
 
 /*************************************************************************
-|*
 |*	SwFlyFrm::Paint()
 |*
 |*	Ersterstellung		MA ??
-|*	Letzte Aenderung	MA 16. Jan. 97
-|*
+|*	Letzte Änderung		MA 16. Jan. 97
 |*************************************************************************/
 
 //Weiter unten definiert
@@ -3874,12 +3849,10 @@ void SwFlyFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 		pProgress->Reschedule();
 }
 /*************************************************************************
-|*
 |*	  SwTabFrm::Paint()
 |*
 |*	  Ersterstellung	MA 11. May. 93
-|*	  Letzte Aenderung	MA 23. Mar. 95
-|*
+|*	  Letzte Änderung	MA 23. Mar. 95
 |*************************************************************************/
 
 void SwTabFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
@@ -3923,7 +3896,6 @@ void SwTabFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 }
 
 /*************************************************************************
-|*
 |*	SwFrm::PaintShadow()
 |*
 |*	Beschreibung		Malt einen Schatten wenns das FrmFormat fordert.
@@ -3931,8 +3903,7 @@ void SwTabFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 |* 		Das OutRect wird ggf. so verkleinert, dass auf diesem das
 |* 		malen der Umrandung stattfinden kann.
 |*	Ersterstellung		MA 21. Dec. 92
-|*	Letzte Aenderung	MA 29. May. 97
-|*
+|*	Letzte Änderung		MA 29. May. 97
 |*************************************************************************/
 /// OD 23.08.2002 #99657#
 ///     draw full shadow rectangle for frames with transparent drawn backgrounds.
@@ -4136,12 +4107,10 @@ void SwFrm::PaintShadow( const SwRect& rRect, SwRect& rOutRect,
 }
 
 /*************************************************************************
-|*
 |*	SwFrm::PaintBorderLine()
 |*
 |*	Ersterstellung		MA 22. Dec. 92
-|*	Letzte Aenderung	MA 22. Jan. 95
-|*
+|*	Letzte Änderung		MA 22. Jan. 95
 |*************************************************************************/
 
 void SwFrm::PaintBorderLine( const SwRect& rRect,
@@ -4177,13 +4146,11 @@ void SwFrm::PaintBorderLine( const SwRect& rRect,
 }
 
 /*************************************************************************
-|*
 |*	SwFrm::PaintBorderLines()
 |*
 |*	Beschreibung		Nur alle Linien einfach oder alle Linien doppelt!!!!
 |*	Ersterstellung		MA 22. Dec. 92
-|*	Letzte Aenderung	MA 22. Mar. 95
-|*
+|*	Letzte Änderung		MA 22. Mar. 95
 |*************************************************************************/
 
 // OD 29.04.2003 #107169# - method called for left and right border rectangles.
@@ -4612,13 +4579,10 @@ void lcl_PaintTopBottomLine( const sal_Bool         _bTop,
 	}
 }
 
-
 /*************************************************************************
-|*
 |*  const SwFrm* lcl_HasNextCell( const SwFrm& rFrm )
 |*
 |* No comment. #i15844#
-|*
 |*************************************************************************/
 
 const SwFrm* lcl_HasNextCell( const SwFrm& rFrm )
@@ -4639,15 +4603,12 @@ const SwFrm* lcl_HasNextCell( const SwFrm& rFrm )
     return 0;
 }
 
-
 /*************************************************************************
-|*
 |*	SwFrm::PaintBorder()
 |*
 |*	Beschreibung		Malt Schatten und Umrandung
 |*	Ersterstellung		MA 23.01.92
-|*	Letzte Aenderung	MA 29. Jul. 96
-|*
+|*	Letzte Änderung		MA 29. Jul. 96
 |*************************************************************************/
 
 /** local method to determine cell frame, from which the border attributes
@@ -4657,7 +4618,6 @@ const SwFrm* lcl_HasNextCell( const SwFrm& rFrm )
 
     @author OD
 
-
     @param _pCellFrm
     input parameter - constant pointer to cell frame for which the cell frame
     for the border attributes has to be determined.
@@ -4961,15 +4921,13 @@ void SwFrm::PaintBorder( const SwRect& rRect, const SwPageFrm *pPage,
 	}
 }
 /*************************************************************************
-|*
 |*	SwFtnContFrm::PaintBorder()
 |*
 |*	Beschreibung		Spezialimplementierung wg. der Fussnotenlinie.
-|* 		Derzeit braucht nur der obere Rand beruecksichtigt werden.
+|* 		Derzeit braucht nur der obere Rand berücksichtigt werden.
 |* 		Auf andere Linien und Schatten wird verzichtet.
 |*	Ersterstellung		MA 27. Feb. 93
-|*	Letzte Aenderung	MA 08. Sep. 93
-|*
+|*	Letzte Änderung		MA 08. Sep. 93
 |*************************************************************************/
 
 void SwFtnContFrm::PaintBorder( const SwRect& rRect, const SwPageFrm *pPage,
@@ -4983,38 +4941,36 @@ void SwFtnContFrm::PaintBorder( const SwRect& rRect, const SwPageFrm *pPage,
 		PaintLine( rRect, pPage );
 }
 /*************************************************************************
-|*
 |*	SwFtnContFrm::PaintLine()
 |*
 |*	Beschreibung		Fussnotenline malen.
 |*	Ersterstellung		MA 02. Mar. 93
-|*	Letzte Aenderung	MA 28. Mar. 94
-|*
+|*	Letzte Änderung		MA 28. Mar. 94
 |*************************************************************************/
 
 void SwFtnContFrm::PaintLine( const SwRect& rRect,
 							  const SwPageFrm *pPage ) const
 {
-	//Laenge der Linie ergibt sich aus der prozentualen Angabe am PageDesc.
-	//Die Position ist ebenfalls am PageDesc angegeben.
-	//Der Pen steht direkt im PageDesc.
+	// Länge der Linie ergibt sich aus der prozentualen Angabe am PageDesc.
+	// Die Position ist ebenfalls am PageDesc angegeben.
+	// Der Pen steht direkt im PageDesc.
 
 	if ( !pPage )
 		pPage = FindPageFrm();
 	const SwPageFtnInfo &rInf = pPage->GetPageDesc()->GetFtnInfo();
 
-    SWRECTFN( this )
-    SwTwips nPrtWidth = (Prt().*fnRect->fnGetWidth)();
-    Fraction aFract( nPrtWidth, 1 );
+	SWRECTFN( this )
+	SwTwips nPrtWidth = (Prt().*fnRect->fnGetWidth)();
+	Fraction aFract( nPrtWidth, 1 );
 	const SwTwips nWidth = (long)(aFract *= rInf.GetWidth());
 
-    SwTwips nX = (this->*fnRect->fnGetPrtLeft)();
+	SwTwips nX = (this->*fnRect->fnGetPrtLeft)();
 	switch ( rInf.GetAdj() )
 	{
 		case FTNADJ_CENTER:
-            nX += nPrtWidth/2 - nWidth/2; break;
+			nX += nPrtWidth/2 - nWidth/2; break;
 		case FTNADJ_RIGHT:
-            nX += nPrtWidth - nWidth; break;
+			nX += nPrtWidth - nWidth; break;
 		case FTNADJ_LEFT:
 			/* do nothing */; break;
 		default:
@@ -5031,14 +4987,12 @@ void SwFtnContFrm::PaintLine( const SwRect& rRect,
 }
 
 /*************************************************************************
-|*
 |*	SwLayoutFrm::PaintColLines()
 |*
-|*	Beschreibung		Painted die Trennlinien fuer die innenliegenden
+|*	Beschreibung		Painted die Trennlinien für die innenliegenden
 |* 						Spalten.
 |*	Ersterstellung		MA 21. Jun. 93
-|*	Letzte Aenderung	MA 28. Mar. 94
-|*
+|*	Letzte Änderung		MA 28. Mar. 94
 |*************************************************************************/
 
 void SwLayoutFrm::PaintColLines( const SwRect &rRect, const SwFmtCol &rFmtCol,
@@ -5048,10 +5002,10 @@ void SwLayoutFrm::PaintColLines( const SwRect &rRect, const SwFmtCol &rFmtCol,
 	if ( !pCol || !pCol->IsColumnFrm() )
 		return;
 	//Badaa: 2008-04-18 * Support for Classical Mongolian Script (SCMS) joint with Jiayanmin
-    SwRectFn fnRect = pCol->IsVertical() ? ( pCol->IsVertLR() ? fnRectVertL2R : fnRectVert ) : fnRectHori;
+	SwRectFn fnRect = pCol->IsVertical() ? ( pCol->IsVertLR() ? fnRectVertL2R : fnRectVert ) : fnRectHori;
 
-    SwRect aLineRect = Prt();
-    aLineRect += Frm().Pos();
+	SwRect aLineRect = Prt();
+	aLineRect += Frm().Pos();
 
     SwTwips nTop = ((aLineRect.*fnRect->fnGetHeight)()*rFmtCol.GetLineHeight())
                    / 100 - (aLineRect.*fnRect->fnGetHeight)();
@@ -5060,29 +5014,29 @@ void SwLayoutFrm::PaintColLines( const SwRect &rRect, const SwFmtCol &rFmtCol,
 	switch ( rFmtCol.GetLineAdj() )
 	{
 		case COLADJ_CENTER:
-            nBottom = nTop / 2; nTop -= nBottom; break;
+			nBottom = nTop / 2; nTop -= nBottom; break;
 		case COLADJ_TOP:
-            nBottom = nTop; nTop = 0; break;
+			nBottom = nTop; nTop = 0; break;
 		case COLADJ_BOTTOM:
-            break;
+			break;
 		default:
 			ASSERT( sal_False, "New adjustment for column line?" );
 	}
 
-    if( nTop )
-        (aLineRect.*fnRect->fnSubTop)( nTop );
-    if( nBottom )
-        (aLineRect.*fnRect->fnAddBottom)( nBottom );
+	if( nTop )
+		(aLineRect.*fnRect->fnSubTop)( nTop );
+	if( nBottom )
+		(aLineRect.*fnRect->fnAddBottom)( nBottom );
 
-    SwTwips nPenHalf = rFmtCol.GetLineWidth();
-    (aLineRect.*fnRect->fnSetWidth)( nPenHalf );
-    nPenHalf /= 2;
+	SwTwips nPenHalf = rFmtCol.GetLineWidth();
+	(aLineRect.*fnRect->fnSetWidth)( nPenHalf );
+	nPenHalf /= 2;
 
-    //Damit uns nichts verlorengeht muessen wir hier etwas grosszuegiger sein.
+	// Damit uns nichts verloren geht müssen wir hier etwas großzügiger sein.
 	SwRect aRect( rRect );
-    (aRect.*fnRect->fnSubLeft)( nPenHalf + nPixelSzW );
-    (aRect.*fnRect->fnAddRight)( nPenHalf + nPixelSzW );
-    SwRectGet fnGetX = IsRightToLeft() ? fnRect->fnGetLeft : fnRect->fnGetRight;
+	(aRect.*fnRect->fnSubLeft)( nPenHalf + nPixelSzW );
+	(aRect.*fnRect->fnAddRight)( nPenHalf + nPixelSzW );
+	SwRectGet fnGetX = IsRightToLeft() ? fnRect->fnGetLeft : fnRect->fnGetRight;
 	while ( pCol->GetNext() )
 	{
         (aLineRect.*fnRect->fnSetPosX)
@@ -5710,18 +5664,16 @@ const sal_Int8 SwPageFrm::mnBorderPxWidth = 1;
 
 /*static*/ SwTwips SwPageFrm::GetSidebarBorderWidth( const ViewShell* _pViewShell )
 {
-    const SwPostItMgr* pPostItMgr = _pViewShell ? _pViewShell->GetPostItMgr() : 0;
-    const SwTwips nRet = pPostItMgr && pPostItMgr->HasNotes() && pPostItMgr->ShowNotes() ? pPostItMgr->GetSidebarWidth() + pPostItMgr->GetSidebarBorderWidth() : 0;
-    return nRet;
+	const SwPostItMgr* pPostItMgr = _pViewShell ? _pViewShell->GetPostItMgr() : 0;
+	const SwTwips nRet = pPostItMgr && pPostItMgr->HasNotes() && pPostItMgr->ShowNotes() ? pPostItMgr->GetSidebarWidth() + pPostItMgr->GetSidebarBorderWidth() : 0;
+	return nRet;
 }
 
 /*************************************************************************
-|*
 |*	SwFrm::PaintBaBo()
 |*
 |*	Ersterstellung		MA 22. Oct. 93
-|*	Letzte Aenderung	MA 19. Jun. 96
-|*
+|*	Letzte Änderung		MA 19. Jun. 96
 |*************************************************************************/
 
 void SwFrm::PaintBaBo( const SwRect& rRect, const SwPageFrm *pPage,
@@ -5732,13 +5684,13 @@ void SwFrm::PaintBaBo( const SwRect& rRect, const SwPageFrm *pPage,
 
 	OutputDevice *pOut = pGlobalShell->GetOut();
 
-    // --> FME 2004-06-24 #i16816# tagged pdf support
-    SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pOut );
-    // <--
+	// --> FME 2004-06-24 #i16816# tagged pdf support
+	SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pOut );
+	// <--
 
-    // OD 2004-04-23 #116347#
-    pOut->Push( PUSH_FILLCOLOR|PUSH_LINECOLOR );
-    pOut->SetLineColor();
+	// OD 2004-04-23 #116347#
+	pOut->Push( PUSH_FILLCOLOR|PUSH_LINECOLOR );
+	pOut->SetLineColor();
 
 	SwBorderAttrAccess aAccess( SwFrm::GetCache(), (SwFrm*)this );
 	const SwBorderAttrs &rAttrs = *aAccess.Get();
@@ -5769,12 +5721,10 @@ void SwFrm::PaintBaBo( const SwRect& rRect, const SwPageFrm *pPage,
 }
 
 /*************************************************************************
-|*
 |*	SwFrm::PaintBackground()
 |*
 |*	Ersterstellung		MA 04. Jan. 93
-|*	Letzte Aenderung	MA 06. Feb. 97
-|*
+|*	Letzte Änderung		MA 06. Feb. 97
 |*************************************************************************/
 /// OD 05.09.2002 #102912#
 /// Do not paint background for fly frames without a background brush by
@@ -5796,25 +5746,25 @@ void SwFrm::PaintBackground( const SwRect &rRect, const SwPageFrm *pPage,
 	if( IsCellFrm() && IsCoveredCell() )
 		return;
 
-    ViewShell *pSh = pGlobalShell;
+	ViewShell *pSh = pGlobalShell;
 
-    // --> FME 2004-06-24 #i16816# tagged pdf support
-    SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pSh->GetOut() );
-    // <--
+	// --> FME 2004-06-24 #i16816# tagged pdf support
+	SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pSh->GetOut() );
+	// <--
 
-    const SvxBrushItem* pItem;
-    /// OD 05.09.2002 #102912#
-    /// temporary background brush for a fly frame without a background brush
-    SvxBrushItem* pTmpBackBrush = 0;
-    const Color* pCol;
+	const SvxBrushItem* pItem;
+	/// OD 05.09.2002 #102912#
+	/// temporary background brush for a fly frame without a background brush
+	SvxBrushItem* pTmpBackBrush = 0;
+	const Color* pCol;
 	SwRect aOrigBackRect;
 	const sal_Bool bPageFrm = IsPageFrm();
 	sal_Bool bLowMode = sal_True;
 
-    //UUUU
-    drawinglayer::attribute::SdrAllFillAttributesHelperPtr aFillAttributes;
+	//UUUU
+	drawinglayer::attribute::SdrAllFillAttributesHelperPtr aFillAttributes;
 
-    sal_Bool bBack = GetBackgroundBrush( aFillAttributes, pItem, pCol, aOrigBackRect, bLowerMode );
+	sal_Bool bBack = GetBackgroundBrush( aFillAttributes, pItem, pCol, aOrigBackRect, bLowerMode );
 
     //- Ausgabe wenn ein eigener Hintergrund mitgebracht wird.
     bool bNoFlyBackground = !bFlyMetafile && !bBack && IsFlyFrm();
@@ -5976,21 +5926,21 @@ void SwFrm::PaintBackground( const SwRect &rRect, const SwPageFrm *pPage,
             bLowMode = bLowerMode ? sal_True : sal_False;
 	}
 
-    /// OD 05.09.2002 #102912#
-    /// delete temporary background brush.
-    delete pTmpBackBrush;
+	/// OD 05.09.2002 #102912#
+	/// delete temporary background brush.
+	delete pTmpBackBrush;
 
-    //Jetzt noch Lower und dessen Nachbarn.
-	//Wenn ein Frm dabei die Kette verlaesst also nicht mehr Lower von mir ist
-	//so hoert der Spass auf.
+	// Jetzt noch Lower und dessen Nachbarn.
+	// Wenn ein Frm dabei die Kette verlässt also nicht mehr Lower von mir ist
+	// so hört der Spass auf.
 	const SwFrm *pFrm = GetLower();
-    if ( pFrm )
+	if ( pFrm )
 	{
 		SwRect aFrmRect;
 		SwRect aRect( PaintArea() );
 		aRect._Intersection( rRect );
 		SwRect aBorderRect( aRect );
-        SwShortCut aShortCut( *pFrm, aBorderRect );
+		SwShortCut aShortCut( *pFrm, aBorderRect );
 		do
 		{   if ( pProgress )
 				pProgress->Reschedule();
@@ -6015,27 +5965,25 @@ void SwFrm::PaintBackground( const SwRect &rRect, const SwPageFrm *pPage,
 }
 
 /*************************************************************************
-|*
 |*	SwPageFrm::RefreshSubsidiary()
 |*
 |*	Beschreibung		Erneuert alle Hilfslinien der Seite.
 |*	Ersterstellung		MA 04. Nov. 92
-|*	Letzte Aenderung	MA 10. May. 95
-|*
+|*	Letzte Änderung		MA 10. May. 95
 |*************************************************************************/
 
 void SwPageFrm::RefreshSubsidiary( const SwRect &rRect ) const
 {
-    if ( IS_SUBS || IS_SUBS_TABLE || IS_SUBS_SECTION || IS_SUBS_FLYS )
+	if ( IS_SUBS || IS_SUBS_TABLE || IS_SUBS_SECTION || IS_SUBS_FLYS )
 	{
 		SwRect aRect( rRect );
-        // OD 18.02.2003 #104989# - Not necessary and incorrect alignment of
-        // the output rectangle.
-        //::SwAlignRect( aRect, pGlobalShell );
+		// OD 18.02.2003 #104989# - Not necessary and incorrect alignment of
+		// the output rectangle.
+		//::SwAlignRect( aRect, pGlobalShell );
 		if ( aRect.HasArea() )
 		{
-			//Beim Paint ueber die Root wird das Array von dort gesteuert.
-			//Anderfalls kuemmern wir uns selbst darum.
+			// Beim Paint über die Root wird das Array von dort gesteuert.
+			// Anderfalls kümmern wir uns selbst darum.
 			sal_Bool bDelSubs = sal_False;
 			if ( !pSubsLines )
 			{
@@ -6047,7 +5995,7 @@ void SwPageFrm::RefreshSubsidiary( const SwRect &rRect ) const
 
 			RefreshLaySubsidiary( this, aRect );
 
-            if ( bDelSubs )
+			if ( bDelSubs )
 			{
                 // OD 20.12.2002 #106318# - paint special subsidiary lines
                 // and delete its container
@@ -6062,24 +6010,22 @@ void SwPageFrm::RefreshSubsidiary( const SwRect &rRect ) const
 }
 
 /*************************************************************************
-|*
 |*	SwLayoutFrm::RefreshLaySubsidiary()
 |*
 |*	Ersterstellung		MA 04. Nov. 92
-|*	Letzte Aenderung	MA 22. Jan. 95
-|*
+|*	Letzte Änderung		MA 22. Jan. 95
 |*************************************************************************/
 void SwLayoutFrm::RefreshLaySubsidiary( const SwPageFrm *pPage,
                                         const SwRect &rRect ) const
 {
 	const sal_Bool bNoLowerColumn = !Lower() || !Lower()->IsColumnFrm();
 	const sal_Bool bSubsOpt	  = IS_SUBS;
-    const sal_Bool bSubsTable = ((GetType() & (FRM_ROW | FRM_CELL)) && IS_SUBS_TABLE);
-    const sal_Bool bSubsOther = (GetType() & (FRM_HEADER | FRM_FOOTER | FRM_FTN )) && bSubsOpt;
+	const sal_Bool bSubsTable = ((GetType() & (FRM_ROW | FRM_CELL)) && IS_SUBS_TABLE);
+	const sal_Bool bSubsOther = (GetType() & (FRM_HEADER | FRM_FOOTER | FRM_FTN )) && bSubsOpt;
 	const sal_Bool bSubsSect  = IsSctFrm() &&
 								bNoLowerColumn &&
 								IS_SUBS_SECTION;
-    const sal_Bool bSubsFly   = IS_SUBS_FLYS &&
+	const sal_Bool bSubsFly   = IS_SUBS_FLYS &&
                                 (GetType() & FRM_FLY) &&
                                 bNoLowerColumn &&
 								(!Lower() || !Lower()->IsNoTxtFrm() ||
@@ -6089,7 +6035,7 @@ void SwLayoutFrm::RefreshLaySubsidiary( const SwPageFrm *pPage,
 	{
 		if ( IsPageBodyFrm() )
 			bSubsBody = bSubsOpt && bNoLowerColumn;									//nur ohne Spalten
-        else    //Spaltenbody
+		else //Spaltenbody
 		{
 			if ( GetUpper()->GetUpper()->IsSctFrm() )
 				bSubsBody = IS_SUBS_SECTION;
@@ -6138,14 +6084,12 @@ void SwLayoutFrm::RefreshLaySubsidiary( const SwPageFrm *pPage,
 }
 
 /*************************************************************************
-|*
 |*	SwLayoutFrm::PaintSubsidiaryLines()
 |*
 |*	Beschreibung		Hilfslinien um die PrtAreas malen
 |* 		Nur die LayoutFrm's die direkt Cntnt enthalten.
 |*	Ersterstellung		MA 21. May. 92
-|*	Letzte Aenderung	MA 22. Jan. 95
-|*
+|*	Letzte Änderung		MA 22. Jan. 95
 |*************************************************************************/
 
 //Malt die angegebene Linie, achtet darauf, dass keine Flys uebermalt werden.
@@ -6169,31 +6113,31 @@ void MA_FASTCALL lcl_RefreshLine( const SwLayoutFrm *pLay,
 	//In welche Richtung gehts? Kann nur Horizontal oder Vertikal sein.
 	ASSERT( ((rP1.X() == rP2.X()) || (rP1.Y() == rP2.Y())),
 			"Schraege Hilfslinien sind nicht erlaubt." );
-    const PointPtr pDirPt = rP1.X() == rP2.X() ? pY : pX;
-    const PointPtr pOthPt = pDirPt == pX ? pY : pX;
-    const SizePtr pDirSz = pDirPt == pX ? pWidth : pHeight;
-    const SizePtr pOthSz = pDirSz == pWidth ? pHeight : pWidth;
+	const PointPtr pDirPt = rP1.X() == rP2.X() ? pY : pX;
+	const PointPtr pOthPt = pDirPt == pX ? pY : pX;
+	const SizePtr pDirSz = pDirPt == pX ? pWidth : pHeight;
+	const SizePtr pOthSz = pDirSz == pWidth ? pHeight : pWidth;
 	Point aP1( rP1 ),
 		  aP2( rP2 );
 
 	while ( aP1.*pDirPt < aP2.*pDirPt )
-	{	//Der Startpunkt wird jetzt, falls er in einem Fly sitzt, direkt
-		//hinter den Fly gesetzt.
-		//Wenn der Endpunkt in einem Fly sitzt oder zwischen Start und Endpunkt
-		//ein Fly sitzt, so wird der Endpunkt eben an den Start herangezogen.
-		//Auf diese Art und Weise wird eine Portion nach der anderen
-		//ausgegeben.
-
-		//Wenn ich selbst ein Fly bin, weiche ich nur denjenigen Flys aus,
-		//die 'ueber' mir sitzen; d.h. die in dem Array hinter mir stehen.
-		//Auch wenn ich in einem Fly sitze oder in einem Fly im Fly usw. weiche
-		//ich keinem dieser Flys aus.
+	{	// Der Startpunkt wird jetzt, falls er in einem Fly sitzt, direkt
+		// hinter den Fly gesetzt.
+		// Wenn der Endpunkt in einem Fly sitzt oder zwischen Start und Endpunkt
+		// ein Fly sitzt, so wird der Endpunkt eben an den Start herangezogen.
+		// Auf diese Art und Weise wird eine Portion nach der anderen
+		// ausgegeben.
+
+		// Wenn ich selbst ein Fly bin, weiche ich nur denjenigen Flys aus,
+		// die 'über' mir sitzen; d.h. die in dem Array hinter mir stehen.
+		// Auch wenn ich in einem Fly sitze oder in einem Fly im Fly usw. weiche
+		// ich keinem dieser Flys aus.
 		SwOrderIter aIter( pPage );
 		const SwFlyFrm *pMyFly = pLay->FindFlyFrm();
 		if ( pMyFly )
 		{
 			aIter.Current( pMyFly->GetVirtDrawObj() );
-            while ( 0 != (pMyFly = pMyFly->GetAnchorFrm()->FindFlyFrm()) )
+			while ( 0 != (pMyFly = pMyFly->GetAnchorFrm()->FindFlyFrm()) )
 			{
 				if ( aIter()->GetOrdNum() > pMyFly->GetVirtDrawObj()->GetOrdNum() )
 					aIter.Current( pMyFly->GetVirtDrawObj() );
@@ -6210,8 +6154,8 @@ void MA_FASTCALL lcl_RefreshLine( const SwLayoutFrm *pLay,
 			//Mir selbst weiche ich natuerlich nicht aus. Auch wenn ich
 			//_in_ dem Fly sitze weiche ich nicht aus.
 			if ( !pFly || (pFly == pLay || pFly->IsAnLower( pLay )) )
-            {
-                aIter.Next();
+			{
+				aIter.Next();
 				continue;
 			}
 
@@ -6247,9 +6191,9 @@ void MA_FASTCALL lcl_RefreshLine( const SwLayoutFrm *pLay,
 		if ( aP1.*pDirPt < aP2.*pDirPt )
 		{
 			SwRect aRect( aP1, aP2 );
-            // OD 18.11.2002 #99672# - use parameter <_pSubsLines> instead of
-            // global variable <pSubsLines>.
-            _pSubsLines->AddLineRect( aRect, 0, 0, nSubColor );
+			// OD 18.11.2002 #99672# - use parameter <_pSubsLines> instead of
+			// global variable <pSubsLines>.
+			_pSubsLines->AddLineRect( aRect, 0, 0, nSubColor );
 		}
 		aP1 = aP2;
 		aP1.*pDirPt += 1;
@@ -6303,20 +6247,20 @@ void SwLayoutFrm::PaintSubsidiaryLines( const SwPageFrm *pPage,
             aOriginal.Top( GetUpper()->GetUpper()->Frm().Top() );
     }
 
-    ::SwAlignRect( aOriginal, pGlobalShell );
+	::SwAlignRect( aOriginal, pGlobalShell );
 
-    if ( !aOriginal.IsOver( rRect ) )
+	if ( !aOriginal.IsOver( rRect ) )
 		return;
 
 	SwRect aOut( aOriginal );
 	aOut._Intersection( rRect );
-    // OD 13.02.2003 #i3662# - do not intersect *enlarged* column body frame's
-    // printing area with the paint area of the body frame. Otherwise enlargement
-    // will get lost.
-    if ( !bColBodyInSection )
-    {
-        aOut.Intersection( PaintArea() );
-    }
+	// OD 13.02.2003 #i3662# - do not intersect *enlarged* column body frame's
+	// printing area with the paint area of the body frame. Otherwise enlargement
+	// will get lost.
+	if ( !bColBodyInSection )
+	{
+		aOut.Intersection( PaintArea() );
+	}
 
 	const SwTwips nRight = aOut.Right();
 	const SwTwips nBottom= aOut.Bottom();
@@ -6325,7 +6269,7 @@ void SwLayoutFrm::PaintSubsidiaryLines( const SwPageFrm *pPage,
 	const Point aRB( nRight, nBottom );
 	const Point aLB( aOut.Left(), nBottom );
 
-    sal_uInt8 nSubColor = ( bCell || IsRowFrm() ) ? SUBCOL_TAB :
+	sal_uInt8 nSubColor = ( bCell || IsRowFrm() ) ? SUBCOL_TAB :
                      ( IsInSct() ? SUBCOL_SECT :
                      ( IsInFly() ? SUBCOL_FLY : SUBCOL_PAGE ) );
 
@@ -6403,37 +6347,35 @@ void SwLayoutFrm::PaintSubsidiaryLines( const SwPageFrm *pPage,
         {
 			if ( aOriginal.Top() == aOut.Top() )
 			{
-                // OD 14.11.2002 #104821# - in horizontal layout set page/column break at top
+				// OD 14.11.2002 #104821# - in horizontal layout set page/column break at top
 				const SwRect aRect( aOut.Pos(), aRT );
-                pUsedSubsLines->AddLineRect( aRect, 0, 0,
+				pUsedSubsLines->AddLineRect( aRect, 0, 0,
                         (bBreak && !bVert) ? SUBCOL_BREAK : nSubColor );
 			}
 			if ( aOriginal.Bottom() == nBottom )
 			{
 				const SwRect aRect( aLB, aRB );
-                pUsedSubsLines->AddLineRect( aRect, 0, 0, nSubColor );
+				pUsedSubsLines->AddLineRect( aRect, 0, 0, nSubColor );
 			}
-        }
+		}
 	}
 }
 
 /*************************************************************************
-|*
 |*	SwPageFrm::RefreshExtraData(), SwLayoutFrm::RefreshExtraData()
 |*
 |*	Beschreibung		Erneuert alle Extradaten (Zeilennummern usw) der Seite.
-|* 						Grundsaetzlich sind nur diejenigen Objekte beruecksichtig,
+|* 						Grundsätzlich sind nur diejenigen Objekte berücksichtigt,
 |* 						die in die seitliche Ausdehnung des Rects ragen.
 |*	Ersterstellung		MA 20. Jan. 98
-|*	Letzte Aenderung	MA 18. Feb. 98
-|*
+|*	Letzte Änderung		MA 18. Feb. 98
 |*************************************************************************/
 
 void SwPageFrm::RefreshExtraData( const SwRect &rRect ) const
 {
 	const SwLineNumberInfo &rInfo = GetFmt()->GetDoc()->GetLineNumberInfo();
 	sal_Bool bLineInFly = (rInfo.IsPaintLineNumbers() && rInfo.IsCountInFlys())
-        || (sal_Int16)SW_MOD()->GetRedlineMarkPos() != text::HoriOrientation::NONE;
+		|| (sal_Int16)SW_MOD()->GetRedlineMarkPos() != text::HoriOrientation::NONE;
 
 	SwRect aRect( rRect );
 	::SwAlignRect( aRect, pGlobalShell );
@@ -6462,7 +6404,7 @@ void SwLayoutFrm::RefreshExtraData( const SwRect &rRect ) const
 	const SwLineNumberInfo &rInfo = GetFmt()->GetDoc()->GetLineNumberInfo();
 	sal_Bool bLineInBody = rInfo.IsPaintLineNumbers(),
 			 bLineInFly  = bLineInBody && rInfo.IsCountInFlys(),
-             bRedLine = (sal_Int16)SW_MOD()->GetRedlineMarkPos()!=text::HoriOrientation::NONE;
+			 bRedLine = (sal_Int16)SW_MOD()->GetRedlineMarkPos()!=text::HoriOrientation::NONE;
 
 	const SwCntntFrm *pCnt = ContainsCntnt();
 	while ( pCnt && IsAnLower( pCnt ) )
@@ -6477,7 +6419,7 @@ void SwLayoutFrm::RefreshExtraData( const SwRect &rRect ) const
 			((SwTxtFrm*)pCnt)->PaintExtraData( rRect );
 		}
 		if ( bLineInFly && pCnt->GetDrawObjs() )
-            for ( sal_uInt32 i = 0; i < pCnt->GetDrawObjs()->Count(); ++i )
+			for ( sal_uInt32 i = 0; i < pCnt->GetDrawObjs()->Count(); ++i )
 			{
                 const SwAnchoredObject* pAnchoredObj = (*pCnt->GetDrawObjs())[i];
                 if ( pAnchoredObj->ISA(SwFlyFrm) )
@@ -6545,43 +6487,39 @@ const Color SwPageFrm::GetDrawBackgrdColor() const
 }
 
 /*************************************************************************
-|*
 |*    SwPageFrm::GetEmptyPageFont()
 |*
 |*    create/return font used to paint the "empty page" string
-|*
 |*************************************************************************/
 
 const Font& SwPageFrm::GetEmptyPageFont()
 {
-    static Font* pEmptyPgFont = 0;
-    if ( 0 == pEmptyPgFont )
-    {
-        pEmptyPgFont = new Font;
-        pEmptyPgFont->SetSize( Size( 0, 80 * 20 )); // == 80 pt
-        pEmptyPgFont->SetWeight( WEIGHT_BOLD );
-        pEmptyPgFont->SetStyleName( aEmptyStr );
-        pEmptyPgFont->SetName( String::CreateFromAscii(
-                RTL_CONSTASCII_STRINGPARAM( "Helvetica" )) );
-        pEmptyPgFont->SetFamily( FAMILY_SWISS );
-        pEmptyPgFont->SetTransparent( sal_True );
-        pEmptyPgFont->SetColor( COL_GRAY );
-    }
+	static Font* pEmptyPgFont = 0;
+	if ( 0 == pEmptyPgFont )
+	{
+		pEmptyPgFont = new Font;
+		pEmptyPgFont->SetSize( Size( 0, 80 * 20 )); // == 80 pt
+		pEmptyPgFont->SetWeight( WEIGHT_BOLD );
+		pEmptyPgFont->SetStyleName( aEmptyStr );
+		pEmptyPgFont->SetName( String::CreateFromAscii(
+				RTL_CONSTASCII_STRINGPARAM( "Helvetica" )) );
+		pEmptyPgFont->SetFamily( FAMILY_SWISS );
+		pEmptyPgFont->SetTransparent( sal_True );
+		pEmptyPgFont->SetColor( COL_GRAY );
+	}
 
-    return *pEmptyPgFont;
+	return *pEmptyPgFont;
 }
 
 /*************************************************************************
-|*
 |*	  SwFrm::Retouche
 |*
-|*	  Beschreibung		Retouche fuer einen Bereich.
-|*		Retouche wird nur dann durchgefuehrt, wenn der Frm der letzte seiner
+|*	  Beschreibung		Retouche für einen Bereich.
+|*		Retouche wird nur dann durchgeführt, wenn der Frm der letzte seiner
 |* 		Kette ist. Der Gesamte Bereich des Upper unterhalb des Frm wird
 |* 		per PaintBackground gecleared.
 |*	  Ersterstellung	MA 13. Apr. 93
-|*	  Letzte Aenderung	MA 25. Jul. 96
-|*
+|*	  Letzte Änderung	MA 25. Jul. 96
 |*************************************************************************/
 
 void SwFrm::Retouche( const SwPageFrm * pPage, const SwRect &rRect ) const
@@ -6598,8 +6536,8 @@ void SwFrm::Retouche( const SwPageFrm * pPage, const SwRect &rRect ) const
 
 	if ( aRetouche.HasArea() )
 	{
-        //Uebergebenes Rect aussparen. Dafuer brauchen wir leider eine Region
-		//zum ausstanzen.
+		// Übergebenes Rect aussparen. Dafür brauchen wir leider eine Region
+		// zum ausstanzen.
 		SwRegionRects aRegion( aRetouche );
 		aRegion -= rRect;
 		ViewShell *pSh = getRootFrm()->GetCurrShell();
@@ -6614,9 +6552,9 @@ void SwFrm::Retouche( const SwPageFrm * pPage, const SwRect &rRect ) const
 
 			GetUpper()->PaintBaBo( rRetouche, pPage, sal_True );
 
-			//Hoelle und Himmel muessen auch refreshed werden.
-			//Um Rekursionen zu vermeiden muss mein Retouche Flag zuerst
-			//zurueckgesetzt werden!
+			// Hölle und Himmel müssen auch refreshed werden.
+			// Um Rekursionen zu vermeiden muss mein Retouche Flag zuerst
+			// zurückgesetzt werden!
 			ResetRetouche();
             SwRect aRetouchePart( rRetouche );
             if ( aRetouchePart.HasArea() )
@@ -6662,10 +6600,10 @@ void SwFrm::Retouche( const SwPageFrm * pPage, const SwRect &rRect ) const
     (3) New (OD 20.08.2002) - Background brush is taken, if on background drawing
         of the frame transparency is considered and its color is not "no fill"/"auto fill"
     ---- old description in german:
-    Beschreibung        Liefert die Backgroundbrush fuer den Bereich des
+    Beschreibung        Liefert die Backgroundbrush für den Bereich des
         des Frm. Die Brush wird entweder von ihm selbst oder von einem
         Upper vorgegeben, die erste Brush wird benutzt.
-        Ist fuer keinen Frm eine Brush angegeben, so wird sal_False zurueck-
+        Ist für keinen Frm eine Brush angegeben, so wird sal_False zurück-
         geliefert.
     Ersterstellung      MA 23. Dec. 92
     Letzte Aenderung    MA 04. Feb. 97
@@ -6837,16 +6775,14 @@ sal_Bool SwFrm::GetBackgroundBrush(
         }
     } while ( pFrm );
 
-    return sal_False;
+	return sal_False;
 }
 
 /*************************************************************************
-|*
 |*	SwFrmFmt::GetGraphic()
 |*
 |*	Ersterstellung		MA 23. Jul. 96
-|*	Letzte Aenderung	MA 23. Jul. 96
-|*
+|*	Letzte Änderung		MA 23. Jul. 96
 |*************************************************************************/
 
 void SetOutDevAndWin( ViewShell *pSh, OutputDevice *pO,
@@ -6867,9 +6803,9 @@ Graphic SwFlyFrmFmt::MakeGraphic( ImageMap* pMap )
 	Graphic aRet;
 	//irgendeinen Fly suchen!
 	SwIterator<SwFrm,SwFmt> aIter( *this );
-    SwFrm *pFirst = aIter.First();
+	SwFrm *pFirst = aIter.First();
 	ViewShell *pSh;
-    if ( pFirst && 0 != ( pSh = pFirst->getRootFrm()->GetCurrShell()) )
+	if ( pFirst && 0 != ( pSh = pFirst->getRootFrm()->GetCurrShell()) )
 	{
 		ViewShell *pOldGlobal = pGlobalShell;
 		pGlobalShell = pSh;
@@ -6911,9 +6847,9 @@ Graphic SwFlyFrmFmt::MakeGraphic( ImageMap* pMap )
 
 		// #i92711# start Pre/PostPaint encapsulation before pOut is changed to the buffering VDev
 		const Region aRepaintRegion(aOut.SVRect());
-    	pSh->DLPrePaint2(aRepaintRegion);
+		pSh->DLPrePaint2(aRepaintRegion);
 
-        Window *pWin = pSh->GetWin();
+		Window *pWin = pSh->GetWin();
 		sal_uInt16 nZoom = pSh->GetViewOptions()->GetZoom();
 		::SetOutDevAndWin( pSh, &aDev, 0, 100 );
 		bFlyMetafile = sal_True;
@@ -6923,22 +6859,22 @@ Graphic SwFlyFrmFmt::MakeGraphic( ImageMap* pMap )
 		pFlyOnlyDraw = pFly;
 		pLines = new SwLineRects;
 
-        // OD 09.12.2002 #103045# - determine page, fly frame is on
-        const SwPageFrm* pFlyPage = pFly->FindPageFrm();
-        const Color aPageBackgrdColor(pFlyPage->GetDrawBackgrdColor());
-        const IDocumentDrawModelAccess* pIDDMA = pSh->getIDocumentDrawModelAccess();
-        // --> OD #i76669#
-        SwViewObjectContactRedirector aSwRedirector( *pSh );
-        // <--
-        pImp->PaintLayer( pIDDMA->GetHellId(), 0, aOut, &aPageBackgrdColor,
+		// OD 09.12.2002 #103045# - determine page, fly frame is on
+		const SwPageFrm* pFlyPage = pFly->FindPageFrm();
+		const Color aPageBackgrdColor(pFlyPage->GetDrawBackgrdColor());
+		const IDocumentDrawModelAccess* pIDDMA = pSh->getIDocumentDrawModelAccess();
+		// --> OD #i76669#
+		SwViewObjectContactRedirector aSwRedirector( *pSh );
+		// <--
+		pImp->PaintLayer( pIDDMA->GetHellId(), 0, aOut, &aPageBackgrdColor,
                           (pFlyPage->IsRightToLeft() ? true : false),
                           &aSwRedirector );
 		pLines->PaintLines( &aDev );
 		if ( pFly->IsFlyInCntFrm() )
 			pFly->Paint( aOut );
 		pLines->PaintLines( &aDev );
-        /// OD 30.08.2002 #102450# - add 3rd parameter
-        pImp->PaintLayer( pIDDMA->GetHeavenId(), 0, aOut, &aPageBackgrdColor,
+		/// OD 30.08.2002 #102450# - add 3rd parameter
+		pImp->PaintLayer( pIDDMA->GetHeavenId(), 0, aOut, &aPageBackgrdColor,
                           (pFlyPage->IsRightToLeft() ? true : false),
                           &aSwRedirector );
 		pLines->PaintLines( &aDev );
@@ -6950,9 +6886,9 @@ Graphic SwFlyFrmFmt::MakeGraphic( ImageMap* pMap )
 		::SetOutDevAndWin( pSh, pOld, pWin, nZoom );
 
 		// #i92711# end Pre/PostPaint encapsulation when pOut is back and content is painted
-   		pSh->DLPostPaint2(true);
+		pSh->DLPostPaint2(true);
 
-        aMet.Stop();
+		aMet.Stop();
 		aMet.Move( -pFly->Frm().Left(), -pFly->Frm().Top() );
 		aRet = Graphic( aMet );
 
@@ -6971,7 +6907,7 @@ Graphic SwFlyFrmFmt::MakeGraphic( ImageMap* pMap )
 Graphic SwDrawFrmFmt::MakeGraphic( ImageMap* )
 {
 	Graphic aRet;
-    SwDrawModel* pMod = getIDocumentDrawModelAccess()->GetDrawModel();
+	SwDrawModel* pMod = getIDocumentDrawModelAccess()->GetDrawModel();
 	if ( pMod )
 	{
 		SdrObject *pObj = FindSdrObject();
@@ -6985,4 +6921,4 @@ Graphic SwDrawFrmFmt::MakeGraphic( ImageMap* )
 	return aRet;
 }
 
-//eof
+/* vim: set noet sw=4 ts=4: */
diff --git a/main/sw/source/core/text/frmpaint.cxx b/main/sw/source/core/text/frmpaint.cxx
index 33b50e3a8d..e7646b7d92 100644
--- a/main/sw/source/core/text/frmpaint.cxx
+++ b/main/sw/source/core/text/frmpaint.cxx
@@ -19,14 +19,11 @@
  *
  *************************************************************/
 
-
-
 // MARKER(update_precomp.py): autogen include statement, do not remove
 #include "precompiled_sw.hxx"
 
 #include <com/sun/star/text/HoriOrientation.hpp>
 #include <hintids.hxx>
-#include <vcl/sound.hxx>
 #include <tools/shl.hxx> // SW_MOD
 #include <editeng/pgrditem.hxx>
 #include <editeng/lrspitem.hxx>
@@ -66,12 +63,11 @@
 //extern const sal_Char __FAR_DATA sBulletFntName[];
 namespace numfunc
 {
-    extern const String& GetDefBulletFontname();
-    extern bool IsDefBulletFontUserDefined();
+	extern const String& GetDefBulletFontname();
+	extern bool IsDefBulletFontUserDefined();
 }
 // <--
 
-
 #define REDLINE_DISTANCE 567/4
 #define REDLINE_MINDIST  567/10
 
@@ -85,7 +81,7 @@ class SwExtraPainter
 {
 	SwSaveClip aClip;
 	SwRect aRect;
-    const SwTxtFrm* pTxtFrm;
+	const SwTxtFrm* pTxtFrm;
 	ViewShell *pSh;
 	SwFont* pFnt;
 	const SwLineNumberInfo &rLineInf;
@@ -98,8 +94,8 @@ class SwExtraPainter
 	inline sal_Bool IsClipChg() { return aClip.IsChg(); }
 public:
 	SwExtraPainter( const SwTxtFrm *pFrm, ViewShell *pVwSh,
-        const SwLineNumberInfo &rLnInf, const SwRect &rRct,
-        sal_Int16 eHor, sal_Bool bLnNm );
+		const SwLineNumberInfo &rLnInf, const SwRect &rRct,
+		sal_Int16 eHor, sal_Bool bLnNm );
 	~SwExtraPainter() { delete pFnt; }
 	inline SwFont* GetFont() const { return pFnt; }
 	inline void IncLineNr() { ++nLineNr; }
@@ -111,13 +107,12 @@ public:
 	void PaintRedline( SwTwips nY, long nMax );
 };
 
-
 SwExtraPainter::SwExtraPainter( const SwTxtFrm *pFrm, ViewShell *pVwSh,
-    const SwLineNumberInfo &rLnInf, const SwRect &rRct,
-    sal_Int16 eHor, sal_Bool bLnNm )
-    : aClip( pVwSh->GetWin() || pFrm->IsUndersized() ? pVwSh->GetOut() : 0 ),
-      aRect( rRct ), pTxtFrm( pFrm ), pSh( pVwSh ), pFnt( 0 ), rLineInf( rLnInf ),
-      nLineNr( 1L ), bLineNum( bLnNm )
+	const SwLineNumberInfo &rLnInf, const SwRect &rRct,
+	sal_Int16 eHor, sal_Bool bLnNm )
+	: aClip( pVwSh->GetWin() || pFrm->IsUndersized() ? pVwSh->GetOut() : 0 ),
+	  aRect( rRct ), pTxtFrm( pFrm ), pSh( pVwSh ), pFnt( 0 ), rLineInf( rLnInf ),
+	  nLineNr( 1L ), bLineNum( bLnNm )
 {
 	if( pFrm->IsUndersized() )
 	{
@@ -127,22 +122,22 @@ SwExtraPainter::SwExtraPainter( const SwTxtFrm *pFrm, ViewShell *pVwSh,
 	}
 	MSHORT nVirtPageNum = 0;
 	if( bLineNum )
-	{   /* initialisiert die Member, die bei Zeilennumerierung notwendig sind:
+	{   /* initialisiert die Member, die bei Zeilennummerierung notwendig sind:
 
-			nDivider,	wie oft ist ein Teilerstring gewuenscht, 0 == nie;
+			nDivider,	wie oft ist ein Teilerstring gewünscht, 0 == nie;
 			nX,			X-Position der Zeilennummern;
 			pFnt,		der Font der Zeilennummern;
 			nLineNr,	die erste Zeilennummer;
-		bLineNum wird ggf.wieder auf sal_False gesetzt, wenn die Numerierung sich
-		komplett ausserhalb des Paint-Rechtecks aufhaelt. */
+		bLineNum wird ggf.wieder auf sal_False gesetzt, wenn die Nummerierung sich
+		komplett außerhalb des Paint-Rechtecks aufhält. */
 		nDivider = rLineInf.GetDivider().Len() ? rLineInf.GetDividerCountBy() : 0;
 		nX = pFrm->Frm().Left();
-        SwCharFmt* pFmt = rLineInf.GetCharFmt( const_cast<IDocumentStylePoolAccess&>(*pFrm->GetNode()->getIDocumentStylePoolAccess()) );
+		SwCharFmt* pFmt = rLineInf.GetCharFmt( const_cast<IDocumentStylePoolAccess&>(*pFrm->GetNode()->getIDocumentStylePoolAccess()) );
 		ASSERT( pFmt, "PaintExtraData without CharFmt" );
-        pFnt = new SwFont( &pFmt->GetAttrSet(), pFrm->GetTxtNode()->getIDocumentSettingAccess() );
+		pFnt = new SwFont( &pFmt->GetAttrSet(), pFrm->GetTxtNode()->getIDocumentSettingAccess() );
 		pFnt->Invalidate();
-        pFnt->ChgPhysFnt( pSh, *pSh->GetOut() );
-        pFnt->SetVertical( 0, pFrm->IsVertical() );
+		pFnt->ChgPhysFnt( pSh, *pSh->GetOut() );
+		pFnt->SetVertical( 0, pFrm->IsVertical() );
 		nLineNr += pFrm->GetAllLines() - pFrm->GetThisLines();
 		LineNumberPosition ePos = rLineInf.GetPos();
 		if( ePos != LINENUMBER_POS_LEFT && ePos != LINENUMBER_POS_RIGHT )
@@ -164,7 +159,7 @@ SwExtraPainter::SwExtraPainter( const SwTxtFrm *pFrm, ViewShell *pVwSh,
 		{
 			bGoLeft = sal_True;
 			nX -= rLineInf.GetPosFromLeft();
-            if( nX < aRect.Left() )
+			if( nX < aRect.Left() )
 				bLineNum = sal_False;
 		}
 		else
@@ -175,21 +170,21 @@ SwExtraPainter::SwExtraPainter( const SwTxtFrm *pFrm, ViewShell *pVwSh,
 				bLineNum = sal_False;
 		}
 	}
-    if( eHor != text::HoriOrientation::NONE )
+	if( eHor != text::HoriOrientation::NONE )
 	{
-        if( text::HoriOrientation::INSIDE == eHor || text::HoriOrientation::OUTSIDE == eHor )
+		if( text::HoriOrientation::INSIDE == eHor || text::HoriOrientation::OUTSIDE == eHor )
 		{
 			if( !nVirtPageNum )
 				nVirtPageNum = pFrm->FindPageFrm()->OnRightPage() ? 1 : 2;
 			if( nVirtPageNum % 2 )
-                eHor = eHor == text::HoriOrientation::INSIDE ? text::HoriOrientation::LEFT : text::HoriOrientation::RIGHT;
+				eHor = eHor == text::HoriOrientation::INSIDE ? text::HoriOrientation::LEFT : text::HoriOrientation::RIGHT;
 			else
-                eHor = eHor == text::HoriOrientation::OUTSIDE ? text::HoriOrientation::LEFT : text::HoriOrientation::RIGHT;
+				eHor = eHor == text::HoriOrientation::OUTSIDE ? text::HoriOrientation::LEFT : text::HoriOrientation::RIGHT;
 		}
 		const SwFrm* pTmpFrm = pFrm->FindTabFrm();
 		if( !pTmpFrm )
 			pTmpFrm = pFrm;
-        nRedX = text::HoriOrientation::LEFT == eHor ? pTmpFrm->Frm().Left() - REDLINE_DISTANCE :
+		nRedX = text::HoriOrientation::LEFT == eHor ? pTmpFrm->Frm().Left() - REDLINE_DISTANCE :
 			pTmpFrm->Frm().Right() + REDLINE_DISTANCE;
 	}
 }
@@ -200,24 +195,24 @@ SwExtraPainter::SwExtraPainter( const SwTxtFrm *pFrm, ViewShell *pVwSh,
 
 void SwExtraPainter::PaintExtra( SwTwips nY, long nAsc, long nMax, sal_Bool bRed )
 {
-	//Zeilennummer ist staerker als der Teiler
-    const XubString aTmp( HasNumber() ? rLineInf.GetNumType().GetNumStr( nLineNr )
+	//Zeilennummer ist stärker als der Teiler
+	const XubString aTmp( HasNumber() ? rLineInf.GetNumType().GetNumStr( nLineNr )
 								: rLineInf.GetDivider() );
 
-    // get script type of line numbering:
-    pFnt->SetActual( SwScriptInfo::WhichFont( 0, &aTmp, 0 ) );
+	// get script type of line numbering:
+	pFnt->SetActual( SwScriptInfo::WhichFont( 0, &aTmp, 0 ) );
 
-    SwDrawTextInfo aDrawInf( pSh, *pSh->GetOut(), 0, aTmp, 0, aTmp.Len() );
+	SwDrawTextInfo aDrawInf( pSh, *pSh->GetOut(), 0, aTmp, 0, aTmp.Len() );
 	aDrawInf.SetSpace( 0 );
 	aDrawInf.SetWrong( NULL );
-    aDrawInf.SetGrammarCheck( NULL );
-    aDrawInf.SetSmartTags( NULL ); // SMARTTAGS
+	aDrawInf.SetGrammarCheck( NULL );
+	aDrawInf.SetSmartTags( NULL ); // SMARTTAGS
 	aDrawInf.SetLeft( 0 );
 	aDrawInf.SetRight( LONG_MAX );
-    aDrawInf.SetFrm( pTxtFrm );
-    aDrawInf.SetFont( pFnt );
-    aDrawInf.SetSnapToGrid( sal_False );
-    aDrawInf.SetIgnoreFrmRTL( sal_True );
+	aDrawInf.SetFrm( pTxtFrm );
+	aDrawInf.SetFont( pFnt );
+	aDrawInf.SetSnapToGrid( sal_False );
+	aDrawInf.SetIgnoreFrmRTL( sal_True );
 
 	sal_Bool bTooBig = pFnt->GetSize( pFnt->GetActual() ).Height() > nMax &&
                 pFnt->GetHeight( pSh, *pSh->GetOut() ) > nMax;
@@ -234,16 +229,16 @@ void SwExtraPainter::PaintExtra( SwTwips nY, long nAsc, long nMax, sal_Bool bRed
 	}
 	else
 		pTmpFnt = GetFont();
-    Point aTmpPos( nX, nY );
-    aTmpPos.Y() += nAsc;
+	Point aTmpPos( nX, nY );
+	aTmpPos.Y() += nAsc;
 	sal_Bool bPaint = sal_True;
 	if( !IsClipChg() )
 	{
-        Size aSize = pTmpFnt->_GetTxtSize( aDrawInf );
+		Size aSize = pTmpFnt->_GetTxtSize( aDrawInf );
 		if( bGoLeft )
 			aTmpPos.X() -= aSize.Width();
-        // calculate rectangle containing the line number
-        SwRect aRct( Point( aTmpPos.X(),
+		// calculate rectangle containing the line number
+		SwRect aRct( Point( aTmpPos.X(),
                          aTmpPos.Y() - pTmpFnt->GetAscent( pSh, *pSh->GetOut() )
                           ), aSize );
 		if( !aRect.IsInside( aRct ) )
@@ -251,11 +246,11 @@ void SwExtraPainter::PaintExtra( SwTwips nY, long nAsc, long nMax, sal_Bool bRed
 			if( aRct.Intersection( aRect ).IsEmpty() )
 				bPaint = sal_False;
 			else
-                aClip.ChgClip( aRect, pTxtFrm );
+				aClip.ChgClip( aRect, pTxtFrm );
 		}
 	}
 	else if( bGoLeft )
-        aTmpPos.X() -= pTmpFnt->_GetTxtSize( aDrawInf ).Width();
+		aTmpPos.X() -= pTmpFnt->_GetTxtSize( aDrawInf ).Width();
 	aDrawInf.SetPos( aTmpPos );
 	if( bPaint )
 		pTmpFnt->_DrawText( aDrawInf );
@@ -282,17 +277,17 @@ void SwExtraPainter::PaintRedline( SwTwips nY, long nMax )
 		{
 			if( aRct.Intersection( aRect ).IsEmpty() )
 				return;
-            aClip.ChgClip( aRect, pTxtFrm );
+			aClip.ChgClip( aRect, pTxtFrm );
 		}
 	}
 	const Color aOldCol( pSh->GetOut()->GetLineColor() );
 	pSh->GetOut()->SetLineColor( SW_MOD()->GetRedlineMarkColor() );
 
-    if ( pTxtFrm->IsVertical() )
-    {
-        pTxtFrm->SwitchHorizontalToVertical( aStart );
-        pTxtFrm->SwitchHorizontalToVertical( aEnd );
-    }
+	if ( pTxtFrm->IsVertical() )
+	{
+		pTxtFrm->SwitchHorizontalToVertical( aStart );
+		pTxtFrm->SwitchHorizontalToVertical( aEnd );
+	}
 
 	pSh->GetOut()->DrawLine( aStart, aEnd );
 	pSh->GetOut()->SetLineColor( aOldCol );
@@ -304,46 +299,46 @@ void SwTxtFrm::PaintExtraData( const SwRect &rRect ) const
 		return;
 
 	const SwTxtNode& rTxtNode = *GetTxtNode();
-    const IDocumentRedlineAccess* pIDRA = rTxtNode.getIDocumentRedlineAccess();
-    const SwLineNumberInfo &rLineInf = rTxtNode.getIDocumentLineNumberAccess()->GetLineNumberInfo();
+	const IDocumentRedlineAccess* pIDRA = rTxtNode.getIDocumentRedlineAccess();
+	const SwLineNumberInfo &rLineInf = rTxtNode.getIDocumentLineNumberAccess()->GetLineNumberInfo();
 	const SwFmtLineNumber &rLineNum = GetAttrSet()->GetLineNumber();
 	sal_Bool bLineNum = !IsInTab() && rLineInf.IsPaintLineNumbers() &&
 			   ( !IsInFly() || rLineInf.IsCountInFlys() ) && rLineNum.IsCount();
-    sal_Int16 eHor = (sal_Int16)SW_MOD()->GetRedlineMarkPos();
-    if( eHor != text::HoriOrientation::NONE && !IDocumentRedlineAccess::IsShowChanges( pIDRA->GetRedlineMode() ) )
-        eHor = text::HoriOrientation::NONE;
-    sal_Bool bRedLine = eHor != text::HoriOrientation::NONE;
+	sal_Int16 eHor = (sal_Int16)SW_MOD()->GetRedlineMarkPos();
+	if( eHor != text::HoriOrientation::NONE && !IDocumentRedlineAccess::IsShowChanges( pIDRA->GetRedlineMode() ) )
+		eHor = text::HoriOrientation::NONE;
+	sal_Bool bRedLine = eHor != text::HoriOrientation::NONE;
 	if ( bLineNum || bRedLine )
 	{
 		if( IsLocked() || IsHiddenNow() || !Prt().Height() )
 			return;
 		ViewShell *pSh = getRootFrm()->GetCurrShell();
 
-        SWAP_IF_NOT_SWAPPED( this )
-        SwRect rOldRect( rRect );
+		SWAP_IF_NOT_SWAPPED( this )
+		SwRect rOldRect( rRect );
 
-        if ( IsVertical() )
-            SwitchVerticalToHorizontal( (SwRect&)rRect );
+		if ( IsVertical() )
+			SwitchVerticalToHorizontal( (SwRect&)rRect );
 
-        SwLayoutModeModifier aLayoutModeModifier( *pSh->GetOut() );
-        aLayoutModeModifier.Modify( sal_False );
+		SwLayoutModeModifier aLayoutModeModifier( *pSh->GetOut() );
+		aLayoutModeModifier.Modify( sal_False );
 
-        // --> FME 2004-06-24 #i16816# tagged pdf support
-        SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pSh->GetOut() );
-        // <--
+		// --> FME 2004-06-24 #i16816# tagged pdf support
+		SwTaggedPDFHelper aTaggedPDFHelper( 0, 0, 0, *pSh->GetOut() );
+		// <--
 
-        SwExtraPainter aExtra( this, pSh, rLineInf, rRect, eHor, bLineNum );
+		SwExtraPainter aExtra( this, pSh, rLineInf, rRect, eHor, bLineNum );
 
 		if( HasPara() )
 		{
 			SwTxtFrmLocker aLock((SwTxtFrm*)this);
 
 			SwTxtLineAccess aAccess( (SwTxtFrm*)this );
-            aAccess.GetPara();
+			aAccess.GetPara();
 
-            SwTxtPaintInfo aInf( (SwTxtFrm*)this, rRect );
+			SwTxtPaintInfo aInf( (SwTxtFrm*)this, rRect );
 
-            aLayoutModeModifier.Modify( sal_False );
+			aLayoutModeModifier.Modify( sal_False );
 
 			SwTxtPainter  aLine( (SwTxtFrm*)this, &aInf );
 			sal_Bool bNoDummy = !aLine.GetNext(); // Nur eine Leerzeile!
@@ -355,11 +350,11 @@ void SwTxtFrm::PaintExtraData( const SwRect &rRect ) const
 					  aLine.GetCurr()->HasCntnt() ) )
 					aExtra.IncLineNr();
 				if( !aLine.Next() )
-                {
-                    (SwRect&)rRect = rOldRect;
-                    UNDO_SWAP( this )
-                    return;
-                }
+				{
+					(SwRect&)rRect = rOldRect;
+					UNDO_SWAP( this )
+					return;
+				}
 			}
 
 			long nBottom = rRect.Bottom();
@@ -405,7 +400,7 @@ void SwTxtFrm::PaintExtraData( const SwRect &rRect ) const
 		}
 		else
 		{
-            bRedLine &= ( MSHRT_MAX!= pIDRA->GetRedlinePos(rTxtNode, USHRT_MAX) );
+			bRedLine &= ( MSHRT_MAX!= pIDRA->GetRedlinePos(rTxtNode, USHRT_MAX) );
 
 			if( bLineNum && rLineInf.IsCountBlankLines() &&
 				( aExtra.HasNumber() || aExtra.HasDivider() ) )
@@ -417,20 +412,20 @@ void SwTxtFrm::PaintExtraData( const SwRect &rRect ) const
 				aExtra.PaintRedline( Frm().Top()+Prt().Top(), Prt().Height() );
 		}
 
-        (SwRect&)rRect = rOldRect;
-        UNDO_SWAP( this )
+		(SwRect&)rRect = rOldRect;
+		UNDO_SWAP( this )
 	}
 }
 
 /*************************************************************************
- *                      SwTxtFrm::Paint()
+ * SwTxtFrm::Paint()
  *************************************************************************/
 
 SwRect SwTxtFrm::Paint()
 {
 #if OSL_DEBUG_LEVEL > 1
 	const SwTwips nDbgY = Frm().Top();
-    (void)nDbgY;
+	(void)nDbgY;
 #endif
 
 	// finger layout
@@ -441,13 +436,13 @@ SwRect SwTxtFrm::Paint()
 		aRet += Frm().Pos();
 	else
 	{
-		// AMA: Wir liefern jetzt mal das richtige Repaintrechteck zurueck,
+		// AMA: Wir liefern jetzt mal das richtige Repaintrechteck zurück,
 		// 		d.h. als linken Rand den berechneten PaintOfst!
 		SwRepaint *pRepaint = GetPara()->GetRepaint();
 		long l;
 		//Badaa: 2008-04-18 * Support for Classical Mongolian Script (SCMS) joint with Jiayanmin
-        if ( IsVertLR() ) // mba: the following line was added, but we don't need it for the existing directions; kept for IsVertLR(), but should be checked
-		    pRepaint->Chg( ( GetUpper()->Frm() ).Pos() + ( GetUpper()->Prt() ).Pos(), ( GetUpper()->Prt() ).SSize() );
+		if ( IsVertLR() ) // mba: the following line was added, but we don't need it for the existing directions; kept for IsVertLR(), but should be checked
+			pRepaint->Chg( ( GetUpper()->Frm() ).Pos() + ( GetUpper()->Prt() ).Pos(), ( GetUpper()->Prt() ).SSize() );
 
 		if( pRepaint->GetOfst() )
 			pRepaint->Left( pRepaint->GetOfst() );
@@ -458,19 +453,19 @@ SwRect SwTxtFrm::Paint()
 		pRepaint->SetOfst( 0 );
 		aRet = *pRepaint;
 
-        if ( IsRightToLeft() )
-            SwitchLTRtoRTL( aRet );
+		if ( IsRightToLeft() )
+			SwitchLTRtoRTL( aRet );
 
-        if ( IsVertical() )
-            SwitchHorizontalToVertical( aRet );
+		if ( IsVertical() )
+			SwitchHorizontalToVertical( aRet );
 	}
 	ResetRepaint();
 
-    return aRet;
+	return aRet;
 }
 
 /*************************************************************************
- *                      SwTxtFrm::Paint()
+ * SwTxtFrm::Paint()
  *************************************************************************/
 
 sal_Bool SwTxtFrm::PaintEmpty( const SwRect &rRect, sal_Bool bCheck ) const
@@ -484,23 +479,23 @@ sal_Bool SwTxtFrm::PaintEmpty( const SwRect &rRect, sal_Bool bCheck ) const
 		SwRect aRect;
 		if( bCheck && aTxtFly.IsOn() && aTxtFly.IsAnyObj( aRect ) )
 			return sal_False;
-        else if( pSh->GetWin() )
+		else if( pSh->GetWin() )
 		{
 			SwFont *pFnt;
 			const SwTxtNode& rTxtNode = *GetTxtNode();
 			if ( rTxtNode.HasSwAttrSet() )
 			{
 				const SwAttrSet *pAttrSet = &( rTxtNode.GetSwAttrSet() );
-                pFnt = new SwFont( pAttrSet, rTxtNode.getIDocumentSettingAccess() );
+				pFnt = new SwFont( pAttrSet, rTxtNode.getIDocumentSettingAccess() );
 			}
 			else
 			{
-                SwFontAccess aFontAccess( &rTxtNode.GetAnyFmtColl(), pSh );
-                pFnt = new SwFont( *aFontAccess.Get()->GetFont() );
+				SwFontAccess aFontAccess( &rTxtNode.GetAnyFmtColl(), pSh );
+				pFnt = new SwFont( *aFontAccess.Get()->GetFont() );
 			}
 
-            const IDocumentRedlineAccess* pIDRA = rTxtNode.getIDocumentRedlineAccess();
-            if( IDocumentRedlineAccess::IsShowChanges( pIDRA->GetRedlineMode() ) )
+			const IDocumentRedlineAccess* pIDRA = rTxtNode.getIDocumentRedlineAccess();
+			if( IDocumentRedlineAccess::IsShowChanges( pIDRA->GetRedlineMode() ) )
 			{
                 MSHORT nRedlPos = pIDRA->GetRedlinePos( rTxtNode, USHRT_MAX );
                 if( MSHRT_MAX != nRedlPos )
@@ -563,19 +558,19 @@ sal_Bool SwTxtFrm::PaintEmpty( const SwRect &rRect, sal_Bool bCheck ) const
                     }
                 }
 
-                const XubString aTmp( CH_PAR );
-                SwDrawTextInfo aDrawInf( pSh, *pSh->GetOut(), 0, aTmp, 0, 1 );
+				const XubString aTmp( CH_PAR );
+				SwDrawTextInfo aDrawInf( pSh, *pSh->GetOut(), 0, aTmp, 0, 1 );
 				aDrawInf.SetLeft( rRect.Left() );
 				aDrawInf.SetRight( rRect.Right() );
 				aDrawInf.SetPos( aPos );
 				aDrawInf.SetSpace( 0 );
-                aDrawInf.SetKanaComp( 0 );
-                aDrawInf.SetWrong( NULL );
-                aDrawInf.SetGrammarCheck( NULL );
-                aDrawInf.SetSmartTags( NULL ); // SMARTTAGS
-                aDrawInf.SetFrm( this );
-                aDrawInf.SetFont( pFnt );
-                aDrawInf.SetSnapToGrid( sal_False );
+				aDrawInf.SetKanaComp( 0 );
+				aDrawInf.SetWrong( NULL );
+				aDrawInf.SetGrammarCheck( NULL );
+				aDrawInf.SetSmartTags( NULL ); // SMARTTAGS
+				aDrawInf.SetFrm( this );
+				aDrawInf.SetFont( pFnt );
+				aDrawInf.SetSnapToGrid( sal_False );
 
 				pFnt->_DrawText( aDrawInf );
 				delete pClip;
@@ -590,48 +585,48 @@ sal_Bool SwTxtFrm::PaintEmpty( const SwRect &rRect, sal_Bool bCheck ) const
 }
 
 /*************************************************************************
- *                      SwTxtFrm::Paint()
+ * SwTxtFrm::Paint()
  *************************************************************************/
 
 void SwTxtFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 {
 	ResetRepaint();
 
-    // --> FME 2004-06-24 #i16816# tagged pdf support
-    ViewShell *pSh = getRootFrm()->GetCurrShell();
+	// --> FME 2004-06-24 #i16816# tagged pdf support
+	ViewShell *pSh = getRootFrm()->GetCurrShell();
 
-    Num_Info aNumInfo( *this );
-    SwTaggedPDFHelper aTaggedPDFHelperNumbering( &aNumInfo, 0, 0, *pSh->GetOut() );
+	Num_Info aNumInfo( *this );
+	SwTaggedPDFHelper aTaggedPDFHelperNumbering( &aNumInfo, 0, 0, *pSh->GetOut() );
 
-    Frm_Info aFrmInfo( *this );
-    SwTaggedPDFHelper aTaggedPDFHelperParagraph( 0, &aFrmInfo, 0, *pSh->GetOut() );
-    // <--
+	Frm_Info aFrmInfo( *this );
+	SwTaggedPDFHelper aTaggedPDFHelperParagraph( 0, &aFrmInfo, 0, *pSh->GetOut() );
+	// <--
 
 	DBG_LOOP_RESET;
 	if( !IsEmpty() || !PaintEmpty( rRect, sal_True ) )
 	{
 #if OSL_DEBUG_LEVEL > 1
 		const SwTwips nDbgY = Frm().Top();
-        (void)nDbgY;
+		(void)nDbgY;
 #endif
 
 #ifdef DBGTXT
 		if( IsDbg( this ) )
 			DBTXTFRM << "Paint()" << endl;
 #endif
-        if( IsLocked() || IsHiddenNow() || ! Prt().HasArea() )
-            return;
+		if( IsLocked() || IsHiddenNow() || ! Prt().HasArea() )
+			return;
 
-		//Kann gut sein, dass mir der IdleCollector mir die gecachten
-		//Informationen entzogen hat.
+		// Kann gut sein, dass mir der IdleCollector mir die gecachten
+		// Informationen entzogen hat.
 		if( !HasPara() )
 		{
 			ASSERT( GetValidPosFlag(), "+SwTxtFrm::Paint: no Calc()" );
 
-            // --> FME 2004-10-29 #i29062# pass info that we are currently
-            // painting.
-            ((SwTxtFrm*)this)->GetFormatted( true );
-            // <--
+			// --> FME 2004-10-29 #i29062# pass info that we are currently
+			// painting.
+			((SwTxtFrm*)this)->GetFormatted( true );
+			// <--
 			if( IsEmpty() )
 			{
 				PaintEmpty( rRect, sal_False );
@@ -644,24 +639,24 @@ void SwTxtFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 			}
 		}
 
-		// Waehrend wir painten, wollen wir nicht gestoert werden.
+		// Während wir painten, wollen wir nicht gestört werden.
 		// Aber erst hinter dem Format() !
 		SwTxtFrmLocker aLock((SwTxtFrm*)this);
 
-		//Hier wird ggf. nur der Teil des TxtFrm ausgegeben, der sich veraendert
-		//hat und der in dem Bereich liegt, dessen Ausgabe angefordert wurde.
-		//Man kann jetzt auf die Idee kommen, dass der Bereich rRect ausgegeben
-		//werden _muss_ obwohl rRepaint gesetzt ist; in der Tat kann dieses
-		//Problem nicht formal vermieden werden. Gluecklicherweise koennen
-		//wir davon ausgehen, dass rRepaint immer dann leer ist, wenn der Frm
-		//komplett gepainted werden muss.
+		// Hier wird ggf. nur der Teil des TxtFrm ausgegeben, der sich verändert
+		// hat und der in dem Bereich liegt, dessen Ausgabe angefordert wurde.
+		// Man kann jetzt auf die Idee kommen, dass der Bereich rRect ausgegeben
+		// werden _muss_ obwohl rRepaint gesetzt ist; in der Tat kann dieses
+		// Problem nicht formal vermieden werden. Glücklicherweise können
+		// wir davon ausgehen, dass rRepaint immer dann leer ist, wenn der Frm
+		// komplett gepainted werden muss.
 		SwTxtLineAccess aAccess( (SwTxtFrm*)this );
 		SwParaPortion *pPara = aAccess.GetPara();
 
 		SwRepaint &rRepaint = *(pPara->GetRepaint());
 
 		// Das Recycling muss abgeschaltet werden, wenn wir uns im
-		// FlyCntFrm befinden, weil ein DrawRect fuer die Retusche der
+		// FlyCntFrm befinden, weil ein DrawRect für die Retusche der
 		// Zeile aufgerufen wird.
 		if( rRepaint.GetOfst() )
 		{
@@ -670,40 +665,40 @@ void SwTxtFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 				rRepaint.SetOfst( 0 );
 		}
 
-		// Hier holen wir uns den String fuer die Ausgabe, besonders
-		// die Laenge ist immer wieder interessant.
+		// Hier holen wir uns den String für die Ausgabe, besonders
+		// die Länge ist immer wieder interessant.
 
-        // Rectangle
-        ASSERT( ! IsSwapped(), "A frame is swapped before Paint" );
-        SwRect aOldRect( rRect );
+		// Rectangle
+		ASSERT( ! IsSwapped(), "A frame is swapped before Paint" );
+		SwRect aOldRect( rRect );
 
-        SWAP_IF_NOT_SWAPPED( this )
+		SWAP_IF_NOT_SWAPPED( this )
 
-        if ( IsVertical() )
-            SwitchVerticalToHorizontal( (SwRect&)rRect );
+		if ( IsVertical() )
+			SwitchVerticalToHorizontal( (SwRect&)rRect );
 
-        if ( IsRightToLeft() )
-            SwitchRTLtoLTR( (SwRect&)rRect );
+		if ( IsRightToLeft() )
+			SwitchRTLtoLTR( (SwRect&)rRect );
 
-        SwTxtPaintInfo aInf( (SwTxtFrm*)this, rRect );
+		SwTxtPaintInfo aInf( (SwTxtFrm*)this, rRect );
 		aInf.SetWrongList( ( (SwTxtNode*)GetTxtNode() )->GetWrong() );
-        aInf.SetGrammarCheckList( ( (SwTxtNode*)GetTxtNode() )->GetGrammarCheck() );
-        aInf.SetSmartTags( ( (SwTxtNode*)GetTxtNode() )->GetSmartTags() );  // SMARTTAGS
-        aInf.GetTxtFly()->SetTopRule();
+		aInf.SetGrammarCheckList( ( (SwTxtNode*)GetTxtNode() )->GetGrammarCheck() );
+		aInf.SetSmartTags( ( (SwTxtNode*)GetTxtNode() )->GetSmartTags() );  // SMARTTAGS
+		aInf.GetTxtFly()->SetTopRule();
 
 		SwTxtPainter  aLine( (SwTxtFrm*)this, &aInf );
 		// Eine Optimierung, die sich lohnt: wenn kein freifliegender Frame
 		// in unsere Zeile ragt, schaltet sich der SwTxtFly einfach ab:
 		aInf.GetTxtFly()->Relax();
 
-        OutputDevice* pOut = aInf.GetOut();
+		OutputDevice* pOut = aInf.GetOut();
 		const sal_Bool bOnWin = pSh->GetWin() != 0;
 
 		SwSaveClip aClip( bOnWin || IsUndersized() ? pOut : 0 );
 
-		// Ausgabeschleife: Fuer jede Zeile ... (die noch zu sehen ist) ...
+		// Ausgabeschleife: Für jede Zeile ... (die noch zu sehen ist) ...
 		// rRect muss angepasst werden (Top+1, Bottom-1), weil der Iterator
-		// die Zeilen nahtlos aneinanderfuegt.
+		// die Zeilen nahtlos aneinanderfügt.
 		aLine.TwipsToLine( rRect.Top() + 1 );
 		long nBottom = rRect.Bottom();
 
@@ -718,8 +713,8 @@ void SwTxtFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 		{
 			do
 			{
-				//DBG_LOOP; shadows declaration above.
-				//resolved into:
+				// DBG_LOOP; shadows declaration above.
+				// resolved into:
 #if  OSL_DEBUG_LEVEL > 1
 #ifdef DBG_UTIL
 				DbgLoop aDbgLoop2( (const void*) this );
@@ -737,9 +732,11 @@ void SwTxtFrm::Paint(SwRect const& rRect, SwPrintData const*const) const
 		if( rRepaint.HasArea() )
 			rRepaint.Clear();
 
-        UNDO_SWAP( this )
-        (SwRect&)rRect = aOldRect;
+		UNDO_SWAP( this )
+		(SwRect&)rRect = aOldRect;
 
-        ASSERT( ! IsSwapped(), "A frame is swapped after Paint" );
-    }
+		ASSERT( ! IsSwapped(), "A frame is swapped after Paint" );
+	}
 }
+
+/* vim: set noet sw=4 ts=4: */