diff options
author | Andreas Martens <ama@openoffice.org> | 2000-11-24 14:53:36 +0000 |
---|---|---|
committer | Andreas Martens <ama@openoffice.org> | 2000-11-24 14:53:36 +0000 |
commit | f625b1d7136219fcf3ed9cc920544847c5a541fd (patch) | |
tree | 17d4dd746d1d5873411e8fd55df5df50f262dcd2 | |
parent | b7f410aa37cce7799424e5927b5d9a293aa0897f (diff) |
#80648#: Script changes => font changes and script space
-rw-r--r-- | sw/source/core/text/itratr.cxx | 10 | ||||
-rw-r--r-- | sw/source/core/text/redlnitr.cxx | 62 |
2 files changed, 6 insertions, 66 deletions
diff --git a/sw/source/core/text/itratr.cxx b/sw/source/core/text/itratr.cxx index 06552cd654a8..56a5420d544e 100644 --- a/sw/source/core/text/itratr.cxx +++ b/sw/source/core/text/itratr.cxx @@ -2,9 +2,9 @@ * * $RCSfile: itratr.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: jp $ $Date: 2000-11-20 16:27:07 $ + * last change: $Author: ama $ $Date: 2000-11-24 15:52:23 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -422,11 +422,7 @@ sal_Bool SwAttrIter::Seek( const xub_StrLen nNewPos ) nScr = SW_CJK; else if( nScript == ScriptType::COMPLEX ) nScr = SW_CTL; -#ifdef DEBUG - static BOOL bAct = FALSE; - if( bAct ) - pFnt->SetActual( nScr ); -#endif + pFnt->SetActual( nScr ); if( pRedln ) nChgCnt += pRedln->Seek( *pFnt, nNewPos, nPos ); nPos = nNewPos; diff --git a/sw/source/core/text/redlnitr.cxx b/sw/source/core/text/redlnitr.cxx index a52713e987f3..e4b0139e31ca 100644 --- a/sw/source/core/text/redlnitr.cxx +++ b/sw/source/core/text/redlnitr.cxx @@ -2,9 +2,9 @@ * * $RCSfile: redlnitr.cxx,v $ * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * - * last change: $Author: jp $ $Date: 2000-11-20 16:27:07 $ + * last change: $Author: ama $ $Date: 2000-11-24 15:53:36 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -174,62 +174,6 @@ void SwAttrIter::CtorInit( SwTxtNode& rTxtNode ) aScriptType.Remove( 0, USHRT_MAX ); } -#ifdef DEBUG - static BOOL bTestCJK = FALSE; - if( bTestCJK ) - { - const String& rTxt = rTxtNode.GetTxt(); - xub_StrLen nCnt = 0; - USHORT nScript = ScriptType::LATIN; - for( xub_StrLen nI = 0; nI < rTxt.Len(); ++nI ) - { - USHORT nNxt = nScript; - const xub_Unicode aChar = rTxt.GetChar( nI ); - if( 'A' <= aChar && aChar <= 'Z' ) - nNxt = ScriptType::LATIN; - else if( 'a' <= aChar && aChar <= 'z' ) - nNxt = ScriptType::ASIAN; - else if( '0' <= aChar && aChar <= '9' ) - nNxt = ScriptType::COMPLEX; - if( nNxt != nScript ) - { - aScriptChg.Insert( nI, nCnt ); - aScriptType.Insert( nScript, nCnt++ ); - BYTE nTmp = 4; - switch ( nScript ) { - case ScriptType::ASIAN : - if( !aMagicNo[SW_CJK] ) nTmp = SW_CJK; break; - case ScriptType::COMPLEX : - if( !aMagicNo[SW_CTL] ) nTmp = SW_CTL; break; - default: - if( !aMagicNo[SW_LATIN ] ) nTmp = SW_LATIN; - } - if( nTmp < 4 ) - { - pFnt->ChkMagic( pShell, nTmp ); - pFnt->GetMagic( aMagicNo[ nTmp ], aFntIdx[ nTmp ], nTmp ); - } - nScript = nNxt; - } - } - aScriptChg.Insert( nI, nCnt ); - aScriptType.Insert( nScript, nCnt++ ); - BYTE nTmp = 4; - switch ( nScript ) { - case ScriptType::ASIAN : - if( !aMagicNo[SW_CJK] ) nTmp = SW_CJK; break; - case ScriptType::COMPLEX : - if( !aMagicNo[SW_CTL] ) nTmp = SW_CTL; break; - default: - if( !aMagicNo[SW_LATIN ] ) nTmp = SW_LATIN; - } - if( nTmp < 4 ) - { - pFnt->ChkMagic( pShell, nTmp ); - pFnt->GetMagic( aMagicNo[ nTmp ], aFntIdx[ nTmp ], nTmp ); - } - } - else if( pBreakIt->xBreak.is() ) { const String& rTxt = rTxtNode.GetTxt(); @@ -268,11 +212,11 @@ void SwAttrIter::CtorInit( SwTxtNode& rTxtNode ) } while( TRUE ); } else -#endif { pFnt->ChkMagic( pShell, SW_LATIN ); pFnt->GetMagic( aMagicNo[ SW_LATIN ], aFntIdx[ SW_LATIN ], SW_LATIN ); } + nStartIndex = nEndIndex = nPos = nChgCnt = 0; SwDoc* pDoc = rTxtNode.GetDoc(); |