From 2fb4d4800c3064c3c7b8573ad39c00d51d9bc41b Mon Sep 17 00:00:00 2001 From: Thomas Arnhold Date: Thu, 20 Jan 2011 11:35:10 +0100 Subject: Replace suitable equalsAscii calls with equalsAsciiL. Done with sed -i 's%\(\.equalsAscii\)(\(\s\?"[^"]\+"\)\(\s\?\))%\1L(\3RTL_CONSTASCII_STRINGPARAM(\2\3)\3)%g'. --- vcl/aqua/source/gdi/salprn.cxx | 2 +- vcl/source/app/svdata.cxx | 4 +- vcl/source/gdi/pdfwriter_impl.cxx | 4 +- vcl/source/gdi/pngwrite.cxx | 6 +-- vcl/source/gdi/print3.cxx | 16 +++--- vcl/source/window/printdlg.cxx | 68 ++++++++++++------------ vcl/unx/gtk/app/gtkdata.cxx | 2 +- vcl/unx/kde/kdedata.cxx | 2 +- vcl/unx/kde4/KDEXLib.cxx | 2 +- vcl/unx/source/app/saldata.cxx | 2 +- vcl/unx/source/desktopdetect/desktopdetector.cxx | 4 +- vcl/unx/source/fontmanager/fontmanager.cxx | 50 ++++++++--------- vcl/workben/outdevgrind.cxx | 4 +- 13 files changed, 83 insertions(+), 83 deletions(-) (limited to 'vcl') diff --git a/vcl/aqua/source/gdi/salprn.cxx b/vcl/aqua/source/gdi/salprn.cxx index 28d554ba9054..f04664e0a719 100644 --- a/vcl/aqua/source/gdi/salprn.cxx +++ b/vcl/aqua/source/gdi/salprn.cxx @@ -500,7 +500,7 @@ static Size getPageSize( vcl::PrinterController& i_rController, sal_Int32 i_nPag Sequence< PropertyValue > aPageParms( i_rController.getPageParameters( i_nPage ) ); for( sal_Int32 nProperty = 0, nPropertyCount = aPageParms.getLength(); nProperty < nPropertyCount; ++nProperty ) { - if( aPageParms[ nProperty ].Name.equalsAscii( "PageSize" ) ) + if( aPageParms[ nProperty ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PageSize" ) ) ) { awt::Size aSize; aPageParms[ nProperty].Value >>= aSize; diff --git a/vcl/source/app/svdata.cxx b/vcl/source/app/svdata.cxx index f29c7c87ac96..fd3158f1172c 100644 --- a/vcl/source/app/svdata.cxx +++ b/vcl/source/app/svdata.cxx @@ -118,7 +118,7 @@ void ImplInitSVData() { rtl::OUString aArg; osl_getCommandArg( i, &aArg.pData ); - if( aArg.equalsAscii( "-enableautomation" ) ) + if( aArg.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "-enableautomation" ) ) ) { pImplSVData->mbIsTestTool = true; break; @@ -263,7 +263,7 @@ com::sun::star::uno::Any AccessBridgeCurrentContext::getValueByName( const rtl:: throw (com::sun::star::uno::RuntimeException) { com::sun::star::uno::Any ret; - if( Name.equalsAscii( "java-vm.interaction-handler" ) ) + if( Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "java-vm.interaction-handler" ) ) ) { // Currently, for accessbility no interaction handler shall be offered. // There may be introduced later on a handler using native toolkits diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx index b740e71ea4a6..80bbbd1415cb 100644 --- a/vcl/source/gdi/pdfwriter_impl.cxx +++ b/vcl/source/gdi/pdfwriter_impl.cxx @@ -11673,7 +11673,7 @@ void PDFWriterImpl::ensureUniqueRadioOnValues() int nKidIndex = rGroupWidget.m_aKidsIndex[nKid]; PDFWidget& rKid = m_aWidgets[nKidIndex]; rKid.m_aOnValue = OUString::valueOf( sal_Int32(nKid+1) ); - if( ! rKid.m_aValue.equalsAscii( "Off" ) ) + if( ! rKid.m_aValue.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Off" ) ) ) rKid.m_aValue = rKid.m_aOnValue; } } @@ -11700,7 +11700,7 @@ void PDFWriterImpl::ensureUniqueRadioOnValues() #endif } // update selected radio button - if( ! rKid.m_aValue.equalsAscii( "Off" ) ) + if( ! rKid.m_aValue.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Off" ) ) ) { rGroupWidget.m_aValue = rKid.m_aValue; } diff --git a/vcl/source/gdi/pngwrite.cxx b/vcl/source/gdi/pngwrite.cxx index 30f098a746dd..6cacfe51aed2 100644 --- a/vcl/source/gdi/pngwrite.cxx +++ b/vcl/source/gdi/pngwrite.cxx @@ -149,11 +149,11 @@ PNGWriterImpl::PNGWriterImpl( const BitmapEx& rBmpEx, sal_Int32 i = 0; for ( i = 0; i < pFilterData->getLength(); i++ ) { - if ( (*pFilterData)[ i ].Name.equalsAscii( "Compression" ) ) + if ( (*pFilterData)[ i ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Compression" ) ) ) (*pFilterData)[ i ].Value >>= mnCompLevel; - else if ( (*pFilterData)[ i ].Name.equalsAscii( "Interlaced" ) ) + else if ( (*pFilterData)[ i ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Interlaced" ) ) ) (*pFilterData)[ i ].Value >>= mnInterlaced; - else if ( (*pFilterData)[ i ].Name.equalsAscii( "MaxChunkSize" ) ) + else if ( (*pFilterData)[ i ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "MaxChunkSize" ) ) ) { sal_Int32 nVal = 0; if ( (*pFilterData)[ i ].Value >>= nVal ) diff --git a/vcl/source/gdi/print3.cxx b/vcl/source/gdi/print3.cxx index be7b72ec3213..494dffdf372f 100644 --- a/vcl/source/gdi/print3.cxx +++ b/vcl/source/gdi/print3.cxx @@ -774,21 +774,21 @@ PrinterController::PageSize vcl::ImplPrinterControllerData::modifyJobSetup( cons sal_Int32 nPaperBin = mnDefaultPaperBin; for( sal_Int32 nProperty = 0, nPropertyCount = i_rProps.getLength(); nProperty < nPropertyCount; ++nProperty ) { - if( i_rProps[ nProperty ].Name.equalsAscii( "PreferredPageSize" ) ) + if( i_rProps[ nProperty ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PreferredPageSize" ) ) ) { i_rProps[ nProperty ].Value >>= aSetSize; } - else if( i_rProps[ nProperty ].Name.equalsAscii( "PageSize" ) ) + else if( i_rProps[ nProperty ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PageSize" ) ) ) { i_rProps[ nProperty ].Value >>= aIsSize; } - else if( i_rProps[ nProperty ].Name.equalsAscii( "PageIncludesNonprintableArea" ) ) + else if( i_rProps[ nProperty ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PageIncludesNonprintableArea" ) ) ) { sal_Bool bVal = sal_False; i_rProps[ nProperty ].Value >>= bVal; aPageSize.bFullPaper = static_cast(bVal); } - else if( i_rProps[ nProperty ].Name.equalsAscii( "PrinterPaperTray" ) ) + else if( i_rProps[ nProperty ].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PrinterPaperTray" ) ) ) { sal_Int32 nBin = -1; i_rProps[ nProperty ].Value >>= nBin; @@ -1342,7 +1342,7 @@ void PrinterController::setUIOptions( const Sequence< beans::PropertyValue >& i_ for( int n = 0; n < aOptProp.getLength(); n++ ) { const beans::PropertyValue& rEntry( aOptProp[ n ] ); - if( rEntry.Name.equalsAscii( "Property" ) ) + if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Property" ) ) ) { PropertyValue aVal; rEntry.Value >>= aVal; @@ -1352,17 +1352,17 @@ void PrinterController::setUIOptions( const Sequence< beans::PropertyValue >& i_ aPropName = aVal.Name; bHaveProperty = true; } - else if( rEntry.Name.equalsAscii( "Enabled" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Enabled" ) ) ) { sal_Bool bValue = sal_True; rEntry.Value >>= bValue; bIsEnabled = bValue; } - else if( rEntry.Name.equalsAscii( "DependsOnName" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "DependsOnName" ) ) ) { rEntry.Value >>= aDep.maDependsOnName; } - else if( rEntry.Name.equalsAscii( "DependsOnEntry" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "DependsOnEntry" ) ) ) { rEntry.Value >>= aDep.mnDependsOnEntry; } diff --git a/vcl/source/window/printdlg.cxx b/vcl/source/window/printdlg.cxx index 887ca0ea8600..0cb19c5fa06c 100644 --- a/vcl/source/window/printdlg.cxx +++ b/vcl/source/window/printdlg.cxx @@ -1111,55 +1111,55 @@ void PrintDialog::setupOptionalUI() for( int n = 0; n < aOptProp.getLength(); n++ ) { const beans::PropertyValue& rEntry( aOptProp[ n ] ); - if( rEntry.Name.equalsAscii( "Text" ) ) + if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Text" ) ) ) { rEntry.Value >>= aText; } - else if( rEntry.Name.equalsAscii( "ControlType" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "ControlType" ) ) ) { rEntry.Value >>= aCtrlType; } - else if( rEntry.Name.equalsAscii( "Choices" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Choices" ) ) ) { rEntry.Value >>= aChoices; } - else if( rEntry.Name.equalsAscii( "Property" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Property" ) ) ) { PropertyValue aVal; rEntry.Value >>= aVal; aPropertyName = aVal.Name; } - else if( rEntry.Name.equalsAscii( "Enabled" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Enabled" ) ) ) { sal_Bool bValue = sal_True; rEntry.Value >>= bValue; bEnabled = bValue; } - else if( rEntry.Name.equalsAscii( "GroupingHint" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GroupingHint" ) ) ) { rEntry.Value >>= aGroupingHint; } - else if( rEntry.Name.equalsAscii( "DependsOnName" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "DependsOnName" ) ) ) { rEntry.Value >>= aDependsOnName; } - else if( rEntry.Name.equalsAscii( "DependsOnEntry" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "DependsOnEntry" ) ) ) { rEntry.Value >>= nDependsOnValue; } - else if( rEntry.Name.equalsAscii( "AttachToDependency" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "AttachToDependency" ) ) ) { rEntry.Value >>= bUseDependencyRow; } - else if( rEntry.Name.equalsAscii( "MinValue" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "MinValue" ) ) ) { rEntry.Value >>= nMinValue; } - else if( rEntry.Name.equalsAscii( "MaxValue" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "MaxValue" ) ) ) { rEntry.Value >>= nMaxValue; } - else if( rEntry.Name.equalsAscii( "HelpText" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "HelpText" ) ) ) { if( ! (rEntry.Value >>= aHelpTexts) ) { @@ -1171,7 +1171,7 @@ void PrintDialog::setupOptionalUI() } } } - else if( rEntry.Name.equalsAscii( "HintNoLayoutPage" ) ) + else if( rEntry.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "HintNoLayoutPage" ) ) ) { sal_Bool bNoLayoutPage = sal_False; rEntry.Value >>= bNoLayoutPage; @@ -1186,7 +1186,7 @@ void PrintDialog::setupOptionalUI() bool bSwitchPage = false; if( aGroupingHint.getLength() ) bSwitchPage = true; - else if( aCtrlType.equalsAscii( "Subgroup" ) || (bOnStaticPage && ! bSubgroupOnStaticPage ) ) + else if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Subgroup" ) ) || (bOnStaticPage && ! bSubgroupOnStaticPage ) ) bSwitchPage = true; if( bSwitchPage ) { @@ -1196,25 +1196,25 @@ void PrintDialog::setupOptionalUI() bOnStaticPage = false; bSubgroupOnStaticPage = false; - if( aGroupingHint.equalsAscii( "PrintRange" ) ) + if( aGroupingHint.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PrintRange" ) ) ) { pCurColumn = maJobPage.mxPrintRange.get(); pCurParent = &maJobPage; // set job page as current parent bOnStaticPage = true; } - else if( aGroupingHint.equalsAscii( "OptionsPage" ) ) + else if( aGroupingHint.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "OptionsPage" ) ) ) { pCurColumn = &maOptionsPage.maLayout; pCurParent = &maOptionsPage; // set options page as current parent bOnStaticPage = true; } - else if( aGroupingHint.equalsAscii( "OptionsPageOptGroup" ) ) + else if( aGroupingHint.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "OptionsPageOptGroup" ) ) ) { pCurColumn = maOptionsPage.mxOptGroup.get(); pCurParent = &maOptionsPage; // set options page as current parent bOnStaticPage = true; } - else if( aGroupingHint.equalsAscii( "LayoutPage" ) ) + else if( aGroupingHint.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "LayoutPage" ) ) ) { pCurColumn = &maNUpPage.maLayout; pCurParent = &maNUpPage; // set layout page as current parent @@ -1228,7 +1228,7 @@ void PrintDialog::setupOptionalUI() } } - if( aCtrlType.equalsAscii( "Group" ) || + if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Group" ) ) || ( ! pCurParent && ! (bOnStaticPage || aGroupingHint.getLength() ) ) ) { // add new tab page @@ -1254,16 +1254,16 @@ void PrintDialog::setupOptionalUI() bSubgroupOnStaticPage = false; bOnStaticPage = false; } - else if( aCtrlType.equalsAscii( "Subgroup" ) && (pCurParent || aGroupingHint.getLength() ) ) + else if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Subgroup" ) ) && (pCurParent || aGroupingHint.getLength() ) ) { bSubgroupOnStaticPage = (aGroupingHint.getLength() != 0); // create group FixedLine - if( ! aGroupingHint.equalsAscii( "PrintRange" ) || + if( ! aGroupingHint.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PrintRange" ) ) || ! pCurColumn->countElements() == 0 ) { Window* pNewSub = NULL; - if( aGroupingHint.equalsAscii( "PrintRange" ) ) + if( aGroupingHint.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PrintRange" ) ) ) pNewSub = new FixedText( pCurParent, WB_VCENTER ); else pNewSub = new FixedLine( pCurParent ); @@ -1287,9 +1287,9 @@ void PrintDialog::setupOptionalUI() pIndent->setChild( pCurColumn ); } // EVIL - else if( aCtrlType.equalsAscii( "Bool" ) && - aGroupingHint.equalsAscii( "LayoutPage" ) && - aPropertyName.equalsAscii( "PrintProspect" ) + else if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Bool" ) ) && + aGroupingHint.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "LayoutPage" ) ) && + aPropertyName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PrintProspect" ) ) ) { maNUpPage.maBrochureBtn.SetText( aText ); @@ -1333,7 +1333,7 @@ void PrintDialog::setupOptionalUI() } } } - if( aCtrlType.equalsAscii( "Bool" ) && pCurParent ) + if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Bool" ) ) && pCurParent ) { // add a check box CheckBox* pNewBox = new CheckBox( pCurParent ); @@ -1363,7 +1363,7 @@ void PrintDialog::setupOptionalUI() // add checkbox to current column pDependencyRow->addWindow( pNewBox ); } - else if( aCtrlType.equalsAscii( "Radio" ) && pCurParent ) + else if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Radio" ) ) && pCurParent ) { vcl::RowOrColumn* pRadioColumn = pCurColumn; if( aText.getLength() ) @@ -1418,9 +1418,9 @@ void PrintDialog::setupOptionalUI() pLabel->setLabel( pBtn ); } } - else if( ( aCtrlType.equalsAscii( "List" ) || - aCtrlType.equalsAscii( "Range" ) || - aCtrlType.equalsAscii( "Edit" ) + else if( ( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "List" ) ) || + aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Range" ) ) || + aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Edit" ) ) ) && pCurParent ) { // create a row in the current column @@ -1446,7 +1446,7 @@ void PrintDialog::setupOptionalUI() pLabel->setLabel( pHeading ); } - if( aCtrlType.equalsAscii( "List" ) ) + if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "List" ) ) ) { ListBox* pList = new ListBox( pCurParent, WB_DROPDOWN | WB_BORDER ); maControls.push_front( pList ); @@ -1479,7 +1479,7 @@ void PrintDialog::setupOptionalUI() else pFieldColumn->addWindow( pList ); } - else if( aCtrlType.equalsAscii( "Range" ) ) + else if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Range" ) ) ) { NumericField* pField = new NumericField( pCurParent, WB_BORDER | WB_SPIN ); maControls.push_front( pField ); @@ -1512,7 +1512,7 @@ void PrintDialog::setupOptionalUI() else pFieldColumn->addWindow( pField ); } - else if( aCtrlType.equalsAscii( "Edit" ) ) + else if( aCtrlType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Edit" ) ) ) { Edit* pField = new Edit( pCurParent, WB_BORDER ); maControls.push_front( pField ); @@ -2195,7 +2195,7 @@ void PrintDialog::updateWindowFromProperty( const rtl::OUString& i_rProperty ) { pBox->Check( bVal ); } - else if( i_rProperty.equalsAscii( "PrintProspect" ) ) + else if( i_rProperty.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PrintProspect" ) ) ) { // EVIL special case if( bVal ) diff --git a/vcl/unx/gtk/app/gtkdata.cxx b/vcl/unx/gtk/app/gtkdata.cxx index 13b8e889d177..24a157723952 100644 --- a/vcl/unx/gtk/app/gtkdata.cxx +++ b/vcl/unx/gtk/app/gtkdata.cxx @@ -608,7 +608,7 @@ void GtkXLib::Init() osl_getCommandArg(i, &aParam.pData ); OString aBParam( OUStringToOString( aParam, aEnc ) ); - if( aParam.equalsAscii( "-display" ) || aParam.equalsAscii( "--display" ) ) + if( aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "-display" ) ) || aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "--display" ) ) ) { pCmdLineAry[i+1] = g_strdup( "--display" ); osl_getCommandArg(i+1, &aParam.pData ); diff --git a/vcl/unx/kde/kdedata.cxx b/vcl/unx/kde/kdedata.cxx index 12b2af378966..881f63db1ffc 100644 --- a/vcl/unx/kde/kdedata.cxx +++ b/vcl/unx/kde/kdedata.cxx @@ -143,7 +143,7 @@ void KDEXLib::Init() for ( nIdx = 0; nIdx < nParams; ++nIdx ) { osl_getCommandArg( nIdx, &aParam.pData ); - if ( !m_pFreeCmdLineArgs && aParam.equalsAscii( "-display" ) && nIdx + 1 < nParams ) + if ( !m_pFreeCmdLineArgs && aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "-display" ) ) && nIdx + 1 < nParams ) { osl_getCommandArg( nIdx + 1, &aParam.pData ); aDisplay = rtl::OUStringToOString( aParam, osl_getThreadTextEncoding() ); diff --git a/vcl/unx/kde4/KDEXLib.cxx b/vcl/unx/kde4/KDEXLib.cxx index cc168a2fe3be..5c7d2a7cf58a 100644 --- a/vcl/unx/kde4/KDEXLib.cxx +++ b/vcl/unx/kde4/KDEXLib.cxx @@ -139,7 +139,7 @@ void KDEXLib::Init() for ( nIdx = 0; nIdx < nParams; ++nIdx ) { osl_getCommandArg( nIdx, &aParam.pData ); - if ( !m_pFreeCmdLineArgs && aParam.equalsAscii( "-display" ) && nIdx + 1 < nParams ) + if ( !m_pFreeCmdLineArgs && aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "-display" ) ) && nIdx + 1 < nParams ) { osl_getCommandArg( nIdx + 1, &aParam.pData ); aDisplay = rtl::OUStringToOString( aParam, osl_getThreadTextEncoding() ); diff --git a/vcl/unx/source/app/saldata.cxx b/vcl/unx/source/app/saldata.cxx index 2d27ec497ec9..7adfdefbf3b7 100644 --- a/vcl/unx/source/app/saldata.cxx +++ b/vcl/unx/source/app/saldata.cxx @@ -407,7 +407,7 @@ void SalXLib::Init() for (USHORT i=0; im_nFamilyName = m_pAtoms->getAtom( ATOM_FAMILYNAME, getString(pProps[n].Value), sal_True ); - else if( pProps[n].Name.equalsAscii( "PSName" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "PSName" ) ) ) pFont->m_nPSName = m_pAtoms->getAtom( ATOM_PSNAME, getString(pProps[n].Value), sal_True ); - else if( pProps[n].Name.equalsAscii( "StyleName" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "StyleName" ) ) ) pFont->m_aStyleName = getString(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "Italic" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Italic" ) ) ) pFont->m_eItalic = static_cast(getInt(pProps[n].Value)); - else if( pProps[n].Name.equalsAscii( "Width" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Width" ) ) ) pFont->m_eWidth = static_cast(getInt(pProps[n].Value)); - else if( pProps[n].Name.equalsAscii( "Weight" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Weight" ) ) ) pFont->m_eWeight = static_cast(getInt(pProps[n].Value)); - else if( pProps[n].Name.equalsAscii( "Pitch" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Pitch" ) ) ) pFont->m_ePitch = static_cast(getInt(pProps[n].Value)); - else if( pProps[n].Name.equalsAscii( "Encoding" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Encoding" ) ) ) pFont->m_aEncoding = static_cast(getInt(pProps[n].Value)); - else if( pProps[n].Name.equalsAscii( "FontEncodingOnly" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "FontEncodingOnly" ) ) ) pFont->m_bFontEncodingOnly = getBool(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "GlobalMetricXWidth" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GlobalMetricXWidth" ) ) ) pFont->m_aGlobalMetricX.width = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "GlobalMetricXHeight" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GlobalMetricXHeight" ) ) ) pFont->m_aGlobalMetricX.height = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "GlobalMetricYWidth" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GlobalMetricYWidth" ) ) ) pFont->m_aGlobalMetricY.width = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "GlobalMetricYHeight" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "GlobalMetricYHeight" ) ) ) pFont->m_aGlobalMetricY.height = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "Ascend" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Ascend" ) ) ) pFont->m_nAscend = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "Descend" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Descend" ) ) ) pFont->m_nDescend = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "Leading" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Leading" ) ) ) pFont->m_nLeading = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "XMin" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "XMin" ) ) ) pFont->m_nXMin = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "YMin" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "YMin" ) ) ) pFont->m_nYMin = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "XMax" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "XMax" ) ) ) pFont->m_nXMax = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "YMax" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "YMax" ) ) ) pFont->m_nYMax = getInt(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "VerticalSubstitutes" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "VerticalSubstitutes" ) ) ) pFont->m_bHaveVerticalSubstitutedGlyphs = getBool(pProps[n].Value); - else if( pProps[n].Name.equalsAscii( "EncodingVector" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "EncodingVector" ) ) ) { Sequence< NamedValue > aEncoding; pProps[n].Value >>= aEncoding; @@ -4025,7 +4025,7 @@ bool PrintFontManager::readOverrideMetrics() pFont->m_aEncodingVector[ cCode ] = nGlyph; } } - else if( pProps[n].Name.equalsAscii( "NonEncoded" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "NonEncoded" ) ) ) { Sequence< NamedValue > aEncoding; pProps[n].Value >>= aEncoding; @@ -4038,7 +4038,7 @@ bool PrintFontManager::readOverrideMetrics() pFont->m_aNonEncoded[ cCode ] = OUStringToOString(aGlyphName,RTL_TEXTENCODING_ASCII_US); } } - else if( pProps[n].Name.equalsAscii( "CharacterMetrics" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "CharacterMetrics" ) ) ) { // fill pFont->m_pMetrics->m_aMetrics // expect triples of int: int -> CharacterMetric.{ width, height } @@ -4052,7 +4052,7 @@ bool PrintFontManager::readOverrideMetrics() pFont->m_pMetrics->m_aMetrics[ pInts[m] ].height = static_cast(pInts[m+2]); } } - else if( pProps[n].Name.equalsAscii( "XKernPairs" ) ) + else if( pProps[n].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "XKernPairs" ) ) ) { // fill pFont->m_pMetrics->m_aXKernPairs // expection name: value: ((height << 16)| width) diff --git a/vcl/workben/outdevgrind.cxx b/vcl/workben/outdevgrind.cxx index fb1709b98765..0d38ff519987 100644 --- a/vcl/workben/outdevgrind.cxx +++ b/vcl/workben/outdevgrind.cxx @@ -923,8 +923,8 @@ int GrindApp::Main() { ::rtl::OUString aParam = GetCommandLineParam( i ); - if( aParam.equalsAscii( "--help" ) || - aParam.equalsAscii( "-h" ) ) + if( aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "--help" ) ) || + aParam.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "-h" ) ) ) bHelp = true; } -- cgit