Hi,
I have submitted a patch for review:
https://gerrit.libreoffice.org/1772
To pull it, you can do:
git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/72/1772/1
Remove more STRINGPARAM macros from filter
Also, remove some chained appends, and sanitize some functions call.
Change-Id: I5bfed073bd84e4dee4bc7e7b4715e413859beb50
---
M filter/source/config/cache/basecontainer.cxx
M filter/source/config/cache/contenthandlerfactory.cxx
M filter/source/config/cache/filtercache.cxx
M filter/source/config/cache/frameloaderfactory.cxx
M filter/source/config/cache/typedetection.cxx
M filter/source/flash/swfdialog.cxx
M filter/source/flash/swfexporter.cxx
M filter/source/flash/swffilter.cxx
M filter/source/flash/swfwriter1.cxx
M filter/source/graphicfilter/egif/egif.cxx
M filter/source/graphicfilter/eps/eps.cxx
M filter/source/graphicfilter/icgm/actimpr.cxx
12 files changed, 160 insertions(+), 178 deletions(-)
diff --git a/filter/source/config/cache/basecontainer.cxx
b/filter/source/config/cache/basecontainer.cxx
index 431bac6..8e65caa 100644
--- a/filter/source/config/cache/basecontainer.cxx
+++ b/filter/source/config/cache/basecontainer.cxx
@@ -133,8 +133,7 @@
if (!m_pFlushCache)
m_pFlushCache = m_rCache->clone();
if (!m_pFlushCache)
- throw css::uno::RuntimeException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Cant create write copy of internal
used cache on demand." )),
+ throw css::uno::RuntimeException( "Cant create write copy of internal used cache on
demand.",
dynamic_cast< css::container::XNameAccess* >(this));
// <- SAFE
}
@@ -203,8 +202,7 @@
css::uno::RuntimeException )
{
if (sItem.isEmpty())
- throw css::lang::IllegalArgumentException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "empty value not allowed as item name."
)),
+ throw css::lang::IllegalArgumentException("empty value not allowed as item name.",
static_cast< css::container::XNameContainer* >(this),
1);
@@ -267,8 +265,7 @@
css::uno::RuntimeException )
{
if (sItem.isEmpty())
- throw css::lang::IllegalArgumentException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "empty value not allowed as item name."
)),
+ throw css::lang::IllegalArgumentException("empty value not allowed as item name.",
static_cast< css::container::XNameContainer* >(this),
1);
@@ -307,8 +304,7 @@
css::uno::RuntimeException )
{
if (sItem.isEmpty())
- throw css::container::NoSuchElementException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "An empty item cant be part of this
cache!" )),
+ throw css::container::NoSuchElementException( "An empty item cant be part of this cache!",
css::uno::Reference< css::uno::XInterface >(static_cast<
css::container::XNameAccess* >(this), css::uno::UNO_QUERY));
css::uno::Any aValue;
@@ -506,7 +502,7 @@
if (!m_pFlushCache)
throw css::lang::WrappedTargetRuntimeException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Cant guarantee cache consistency.
Special flush container does not exists!" )),
+ "Cant guarantee cache consistency. Special flush container does not exists!",
dynamic_cast< css::container::XNameAccess* >(this),
css::uno::Any());
@@ -528,8 +524,7 @@
// user whish to repair it now and calls flush()
// later again ...
- throw css::lang::WrappedTargetRuntimeException(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Flush rejected by internal
container." )),
+ throw css::lang::WrappedTargetRuntimeException( "Flush rejected by internal container.",
dynamic_cast< css::container::XNameAccess* >(this),
css::uno::makeAny(ex));
}
diff --git a/filter/source/config/cache/contenthandlerfactory.cxx
b/filter/source/config/cache/contenthandlerfactory.cxx
index 2733d22..6916c9d 100644
--- a/filter/source/config/cache/contenthandlerfactory.cxx
+++ b/filter/source/config/cache/contenthandlerfactory.cxx
@@ -146,17 +146,17 @@
-::rtl::OUString ContentHandlerFactory::impl_getImplementationName()
+OUString ContentHandlerFactory::impl_getImplementationName()
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.comp.filter.config.ContentHandlerFactory" ));
+ return OUString( "com.sun.star.comp.filter.config.ContentHandlerFactory" );
}
-css::uno::Sequence< ::rtl::OUString > ContentHandlerFactory::impl_getSupportedServiceNames()
+css::uno::Sequence< OUString > ContentHandlerFactory::impl_getSupportedServiceNames()
{
- css::uno::Sequence< ::rtl::OUString > lServiceNames(1);
- lServiceNames[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.frame.ContentHandlerFactory" ));
+ css::uno::Sequence< OUString > lServiceNames(1);
+ lServiceNames[0] = "com.sun.star.frame.ContentHandlerFactory";
return lServiceNames;
}
diff --git a/filter/source/config/cache/filtercache.cxx b/filter/source/config/cache/filtercache.cxx
index 3e512ed..19aba92 100644
--- a/filter/source/config/cache/filtercache.cxx
+++ b/filter/source/config/cache/filtercache.cxx
@@ -671,8 +671,8 @@
// special case. no exception - but not a valid item => set must be finalized or
mandatory!
// Reject flush operation by throwing an exception. At least one item couldnt be
flushed.
if (!xItem.is())
- throw css::uno::Exception(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Cant
add item. Set is finalized or mandatory!" )),
- css::uno::Reference< css::uno::XInterface >()
);
+ throw css::uno::Exception("Cant add item. Set is finalized or mandatory!",
+ css::uno::Reference< css::uno::XInterface >());
CacheItemList::const_iterator pItem = rCache.find(sItem);
impl_saveItem(xItem, eType, pItem->second);
@@ -688,8 +688,8 @@
// special case. no exception - but not a valid item => it must be finalized or
mandatory!
// Reject flush operation by throwing an exception. At least one item couldnt be
flushed.
if (!xItem.is())
- throw css::uno::Exception(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Cant
change item. Its finalized or mandatory!" )),
- css::uno::Reference< css::uno::XInterface >()
);
+ throw css::uno::Exception("Cant change item. Its finalized or mandatory!",
+ css::uno::Reference< css::uno::XInterface >());
CacheItemList::const_iterator pItem = rCache.find(sItem);
impl_saveItem(xItem, eType, pItem->second);
@@ -782,8 +782,8 @@
}
- throw css::uno::Exception(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "unknown sub container
requested." )),
- css::uno::Reference< css::uno::XInterface >()
);
+ throw css::uno::Exception("unknown sub container requested.",
+ css::uno::Reference< css::uno::XInterface >());
// <- SAFE ----------------------------------
}
@@ -802,8 +802,8 @@
}
- throw css::uno::Exception(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "unknown sub container
requested." )),
- css::uno::Reference< css::uno::XInterface >()
);
+ throw css::uno::Exception("unknown sub container requested.",
+ css::uno::Reference< css::uno::XInterface >());
// <- SAFE ----------------------------------
}
@@ -825,7 +825,7 @@
return m_xConfigTypes;
sPath = CFGPACKAGE_TD_TYPES;
pConfig = &m_xConfigTypes;
- sRtlLog = ::rtl::OString("framework (as96863)
::FilterCache::impl_openconfig(E_PROVIDER_TYPES)");
+ sRtlLog = "framework (as96863)
::FilterCache::impl_openconfig(E_PROVIDER_TYPES)";
}
break;
@@ -835,7 +835,7 @@
return m_xConfigFilters;
sPath = CFGPACKAGE_TD_FILTERS;
pConfig = &m_xConfigFilters;
- sRtlLog = ::rtl::OString("framework (as96863)
::FilterCache::impl_openconfig(E_PROVIDER_FILTERS)");
+ sRtlLog = "framework (as96863)
::FilterCache::impl_openconfig(E_PROVIDER_FILTERS)";
}
break;
@@ -845,7 +845,7 @@
return m_xConfigOthers;
sPath = CFGPACKAGE_TD_OTHERS;
pConfig = &m_xConfigOthers;
- sRtlLog = ::rtl::OString("framework (as96863)
::FilterCache::impl_openconfig(E_PROVIDER_OTHERS)");
+ sRtlLog = "framework (as96863) ::FilterCache::impl_openconfig(E_PROVIDER_OTHERS)";
}
break;
@@ -855,11 +855,11 @@
// the old configuration format only. Its not cached!
sPath = CFGPACKAGE_TD_OLD;
pConfig = &xOld;
- sRtlLog = ::rtl::OString("framework (as96863)
::FilterCache::impl_openconfig(E_PROVIDER_OLD)");
+ sRtlLog = "framework (as96863) ::FilterCache::impl_openconfig(E_PROVIDER_OLD)";
}
break;
- default : throw css::uno::Exception(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "These
configuration node isnt supported here for open!" )), 0);
+ default : throw css::uno::Exception("These configuration node isnt supported here for
open!", 0);
}
{
@@ -1035,7 +1035,7 @@
throw css::document::CorruptedFilterConfigurationException(
"filter configuration: the list of types or filters is empty",
css::uno::Reference< css::uno::XInterface >(),
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "The list of types or filters is
empty." )));
+ "The list of types or filters is empty." );
}
// Create a log for all detected problems, which
@@ -1334,7 +1334,7 @@
pList = &m_lChangedDetectServices;
break;
- default : throw css::uno::Exception(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"unsupported item type" )), 0);
+ default : throw css::uno::Exception("unsupported item type", 0);
}
OUStringList::const_iterator pItem = ::std::find(pList->begin(), pList->end(), sItem);
@@ -2343,9 +2343,7 @@
css::uno::Reference< css::container::XNameAccess > xItem;
xSet->getByName(sItem) >>= xItem;
if (!xItem.is())
- throw css::uno::Exception(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Cant read old item." )),
- css::uno::Reference< css::uno::XInterface >());
+ throw css::uno::Exception("Cant read old item.", css::uno::Reference< css::uno::XInterface
());
CacheItem aItem;
aItem[PROPNAME_NAME] <<= sItem;
@@ -2359,16 +2357,14 @@
// Data
::rtl::OUString sData;
OUStringList lData;
- xItem->getByName(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Data" ))) >>= sData;
+ xItem->getByName( "Data" ) >>= sData;
lData = impl_tokenizeString(sData, (sal_Unicode)',');
if (
(sData.isEmpty()) ||
(lData.size()<1 )
)
{
- throw css::uno::Exception(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Cant read old item property DATA."
)),
- css::uno::Reference< css::uno::XInterface >());
+ throw css::uno::Exception( "Cant read old item property DATA.", css::uno::Reference<
css::uno::XInterface >());
}
sal_Int32 nProp = 0;
@@ -2465,7 +2461,7 @@
m_xModuleCfg = css::uno::Reference< css::container::XNameAccess >(
::comphelper::ConfigurationHelper::openConfig(
comphelper::getComponentContext(m_xSMGR),
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"org.openoffice.Setup/Office/Factories" )),
+ "org.openoffice.Setup/Office/Factories",
::comphelper::ConfigurationHelper::E_READONLY),
css::uno::UNO_QUERY_THROW);
}
diff --git a/filter/source/config/cache/frameloaderfactory.cxx
b/filter/source/config/cache/frameloaderfactory.cxx
index 2f25149..c3344d9 100644
--- a/filter/source/config/cache/frameloaderfactory.cxx
+++ b/filter/source/config/cache/frameloaderfactory.cxx
@@ -143,17 +143,17 @@
-::rtl::OUString FrameLoaderFactory::impl_getImplementationName()
+OUString FrameLoaderFactory::impl_getImplementationName()
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.comp.filter.config.FrameLoaderFactory" ));
+ return OUString( "com.sun.star.comp.filter.config.FrameLoaderFactory" );
}
-css::uno::Sequence< ::rtl::OUString > FrameLoaderFactory::impl_getSupportedServiceNames()
+css::uno::Sequence< OUString > FrameLoaderFactory::impl_getSupportedServiceNames()
{
- css::uno::Sequence< ::rtl::OUString > lServiceNames(1);
- lServiceNames[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.frame.FrameLoaderFactory" ));
+ css::uno::Sequence< OUString > lServiceNames(1);
+ lServiceNames[0] = "com.sun.star.frame.FrameLoaderFactory";
return lServiceNames;
}
diff --git a/filter/source/config/cache/typedetection.cxx
b/filter/source/config/cache/typedetection.cxx
index 0732f06..ca19fe0 100644
--- a/filter/source/config/cache/typedetection.cxx
+++ b/filter/source/config/cache/typedetection.cxx
@@ -242,7 +242,7 @@
::rtl::OUString sURL =
stlDescriptor.getUnpackedValueOrDefault(::comphelper::MediaDescriptor::PROP_URL(),
::rtl::OUString());
#if OSL_DEBUG_LEVEL > 0
- if (stlDescriptor.find(::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FileName" ))) !=
stlDescriptor.end())
+ if (stlDescriptor.find( "FileName" ) != stlDescriptor.end())
OSL_FAIL("Detect using of deprecated and already unsupported MediaDescriptor property
\"FileName\"!");
#endif
@@ -1136,7 +1136,7 @@
if (
(sURL.isEmpty() ) || // "non existing file" ?
(!xStream.is() ) || // non existing file !
- (sURL.equalsIgnoreAsciiCaseAsciiL(RTL_CONSTASCII_STRINGPARAM("private:stream"))) // not
a good idea .-)
+ (sURL.equalsIgnoreAsciiCase("private:stream")) // not a good idea .-)
)
return ::rtl::OUString();
@@ -1263,17 +1263,17 @@
-::rtl::OUString TypeDetection::impl_getImplementationName()
+OUString TypeDetection::impl_getImplementationName()
{
- return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.comp.filter.config.TypeDetection" ));
+ return OUString( "com.sun.star.comp.filter.config.TypeDetection" );
}
-css::uno::Sequence< ::rtl::OUString > TypeDetection::impl_getSupportedServiceNames()
+css::uno::Sequence< OUString > TypeDetection::impl_getSupportedServiceNames()
{
- css::uno::Sequence< ::rtl::OUString > lServiceNames(1);
- lServiceNames[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.document.TypeDetection" ));
+ css::uno::Sequence< OUString > lServiceNames(1);
+ lServiceNames[0] = OUString( "com.sun.star.document.TypeDetection" );
return lServiceNames;
}
diff --git a/filter/source/flash/swfdialog.cxx b/filter/source/flash/swfdialog.cxx
index 1480afe..ba3a51e 100644
--- a/filter/source/flash/swfdialog.cxx
+++ b/filter/source/flash/swfdialog.cxx
@@ -48,7 +48,7 @@
OUString SWFDialog_getImplementationName ()
throw (RuntimeException)
{
- return OUString ( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ return OUString ( SERVICE_NAME );
}
// -----------------------------------------------------------------------------
@@ -67,7 +67,7 @@
{
Sequence < OUString > aRet(1);
OUString* pArray = aRet.getArray();
- pArray[0] = OUString ( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ pArray[0] = OUString ( SERVICE_NAME );
return aRet;
}
@@ -239,7 +239,7 @@
if( i == nCount )
maMediaDescriptor.realloc( ++nCount );
- maMediaDescriptor[ i ].Name = String( RTL_CONSTASCII_USTRINGPARAM( "FilterData" ) );
+ maMediaDescriptor[ i ].Name = "FilterData";
maMediaDescriptor[ i ].Value <<= maFilterData;
return maMediaDescriptor;
diff --git a/filter/source/flash/swfexporter.cxx b/filter/source/flash/swfexporter.cxx
index 6b065ce..29da268 100644
--- a/filter/source/flash/swfexporter.cxx
+++ b/filter/source/flash/swfexporter.cxx
@@ -38,7 +38,6 @@
#include "swfexporter.hxx"
#include "swfwriter.hxx"
-using rtl::OUString;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::drawing;
using namespace ::com::sun::star::presentation;
@@ -127,7 +126,7 @@
{
Reference< XServiceInfo > xDocServInfo( xDoc, UNO_QUERY );
if( xDocServInfo.is() )
- mbPresentation = xDocServInfo->supportsService( OUString(
RTL_CONSTASCII_USTRINGPARAM("com.sun.star.presentation.PresentationDocument"))) ;
+ mbPresentation = xDocServInfo->supportsService(
"com.sun.star.presentation.PresentationDocument" );
Reference< XDrawPagesSupplier > xDrawPagesSupplier(xDoc, UNO_QUERY);
if(!xDrawPagesSupplier.is())
@@ -143,8 +142,8 @@
Reference< XPropertySet > xProp( xDrawPage, UNO_QUERY );
try
{
- xProp->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Width") ) ) >>= mnDocWidth;
- xProp->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Height") ) ) >>=
mnDocHeight;
+ xProp->getPropertyValue( "Width" ) >>= mnDocWidth;
+ xProp->getPropertyValue( "Height" ) >>= mnDocHeight;
sal_Int32 nOutputWidth = 14400;
sal_Int32 nOutputHeight = (nOutputWidth * mnDocHeight ) / mnDocWidth;
@@ -160,7 +159,7 @@
const sal_Int32 nPageCount = xDrawPages->getCount();
sal_uInt16 nPage;
if ( xStatusIndicator.is() )
- xStatusIndicator->start(OUString( RTL_CONSTASCII_USTRINGPARAM( "Macromedia Flash (SWF)"
)), nPageCount);
+ xStatusIndicator->start( "Macromedia Flash (SWF)", nPageCount);
for( nPage = 0; nPage < nPageCount; nPage++)
{
mnPageNumber = nPage + 1;
@@ -176,7 +175,7 @@
if( mbPresentation )
{
sal_Bool bVisible = sal_False;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Visible") ) ) >>=
bVisible;
+ xPropSet->getPropertyValue( "Visible" ) >>= bVisible;
if( !bVisible )
continue;
}
@@ -241,8 +240,8 @@
{
if( NULL == mpWriter )
{
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Width") ) ) >>=
mnDocWidth;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Height") ) ) >>=
mnDocHeight;
+ xPropSet->getPropertyValue( "Width" ) >>= mnDocWidth;
+ xPropSet->getPropertyValue( "Height" ) >>= mnDocHeight;
mpWriter = new Writer( 14400, 10800, mnDocWidth, mnDocHeight, mnJPEGcompressMode );
}
@@ -250,7 +249,7 @@
if( mbPresentation )
{
sal_Bool bVisible = sal_False;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Visible") ) ) >>=
bVisible;
+ xPropSet->getPropertyValue( "Visible" ) >>= bVisible;
if( !bVisible )
return sal_False;
}
@@ -275,8 +274,8 @@
if( NULL == mpWriter )
{
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Width") ) ) >>=
mnDocWidth;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Height") ) ) >>=
mnDocHeight;
+ xPropSet->getPropertyValue( "Width" ) >>= mnDocWidth;
+ xPropSet->getPropertyValue( "Height" ) >>= mnDocHeight;
mpWriter = new Writer( 14400, 10800, mnDocWidth, mnDocHeight, mnJPEGcompressMode );
}
@@ -307,8 +306,8 @@
if( mbPresentation )
{
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("IsBackgroundVisible") )
) >>= bBackgroundVisible;
- xPropSet->getPropertyValue( OUString(
RTL_CONSTASCII_USTRINGPARAM("IsBackgroundObjectsVisible") ) ) >>= bBackgroundObjectsVisible;
+ xPropSet->getPropertyValue( "IsBackgroundVisible" ) >>= bBackgroundVisible;
+ xPropSet->getPropertyValue( "IsBackgroundObjectsVisible" ) >>= bBackgroundObjectsVisible;
}
@@ -536,7 +535,7 @@
{
// skip empty presentation objects
sal_Bool bEmpty = sal_False;
- xPropSet->getPropertyValue( OUString(
RTL_CONSTASCII_USTRINGPARAM("IsEmptyPresentationObject") ) ) >>= bEmpty;
+ xPropSet->getPropertyValue( "IsEmptyPresentationObject" ) >>= bEmpty;
if( bEmpty )
return;
@@ -545,12 +544,12 @@
if( bMaster )
{
OUString aShapeType( xShape->getShapeType() );
- if( (0 == aShapeType.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.presentation.TitleTextShape" ))) ||
- (0 == aShapeType.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.presentation.OutlinerShape" ))) ||
- (0 == aShapeType.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.presentation.HeaderShape" ))) ||
- (0 == aShapeType.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.presentation.FooterShape" ))) ||
- (0 == aShapeType.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.presentation.SlideNumberShape" ))) ||
- (0 == aShapeType.reverseCompareToAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.presentation.DateTimeShape" ))))
+ if( (0 == aShapeType.reverseCompareTo( "com.sun.star.presentation.TitleTextShape"
)) ||
+ (0 == aShapeType.reverseCompareTo( "com.sun.star.presentation.OutlinerShape"
)) ||
+ (0 == aShapeType.reverseCompareTo( "com.sun.star.presentation.HeaderShape" ))
||
+ (0 == aShapeType.reverseCompareTo( "com.sun.star.presentation.FooterShape" ))
||
+ (0 == aShapeType.reverseCompareTo(
"com.sun.star.presentation.SlideNumberShape" )) ||
+ (0 == aShapeType.reverseCompareTo( "com.sun.star.presentation.DateTimeShape"
)))
return;
}
}
@@ -563,7 +562,7 @@
try
{
com::sun::star::awt::Rectangle aBoundRect;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("BoundRect") ) ) >>=
aBoundRect;
+ xPropSet->getPropertyValue( "BoundRect" ) >>= aBoundRect;
ShapeInfo* pShapeInfo = new ShapeInfo();
pShapeInfo->mnX = aBoundRect.X;
@@ -573,22 +572,19 @@
if( mbPresentation )
{
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Bookmark") ) )
= pShapeInfo->maBookmark;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("DimColor") ) )
= pShapeInfo->mnDimColor;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("DimHide") ) )
= pShapeInfo->mbDimHide;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("DimPrevious") )
) >>= pShapeInfo->mbDimPrev;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Effect") ) )
= pShapeInfo->meEffect;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("PlayFull") ) )
= pShapeInfo->mbPlayFull;
- xPropSet->getPropertyValue( OUString(
RTL_CONSTASCII_USTRINGPARAM("PresentationOrder") ) ) >>= pShapeInfo->mnPresOrder;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Sound") ) ) >>=
pShapeInfo->maSoundURL;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("SoundOn") ) )
= pShapeInfo->mbSoundOn;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("Speed") ) ) >>=
pShapeInfo->meEffectSpeed;
- xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("TextEffect") )
) >>= pShapeInfo->meTextEffect;
- xPropSet->getPropertyValue( OUString(
RTL_CONSTASCII_USTRINGPARAM("TransparentColor") ) ) >>= pShapeInfo->mnBlueScreenColor;
+ xPropSet->getPropertyValue( "Bookmark" ) >>= pShapeInfo->maBookmark;
+ xPropSet->getPropertyValue( "DimColor" ) >>= pShapeInfo->mnDimColor;
+ xPropSet->getPropertyValue( "DimHide" ) >>= pShapeInfo->mbDimHide;
+ xPropSet->getPropertyValue( "DimPrevious" ) >>= pShapeInfo->mbDimPrev;
+ xPropSet->getPropertyValue( "Effect" ) >>= pShapeInfo->meEffect;
+ xPropSet->getPropertyValue( "PlayFull" ) >>= pShapeInfo->mbPlayFull;
+ xPropSet->getPropertyValue( "PresentationOrder" ) >>= pShapeInfo->mnPresOrder;
+ xPropSet->getPropertyValue( "Sound" ) >>= pShapeInfo->maSoundURL;
+ xPropSet->getPropertyValue( "SoundOn" ) >>= pShapeInfo->mbSoundOn;
+ xPropSet->getPropertyValue( "Speed" ) >>= pShapeInfo->meEffectSpeed;
+ xPropSet->getPropertyValue( "TextEffect" ) >>= pShapeInfo->meTextEffect;
+ xPropSet->getPropertyValue( "TransparentColor" ) >>=
pShapeInfo->mnBlueScreenColor;
}
-
-// long ZOrder;
-// xPropSet->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM("ZOrder") ) ) >>=
ZOrder;
GDIMetaFile aMtf;
Reference< XComponent > xComponent( xShape, UNO_QUERY );
@@ -639,7 +635,7 @@
bool FlashExporter::getMetaFile( Reference< XComponent >&xComponent, GDIMetaFile& rMtf, bool
bOnlyBackground /* = false */, bool bExportAsJPEG /* = false */)
{
if( !mxGraphicExporter.is() )
- mxGraphicExporter = Reference< XExporter >::query( mxMSF->createInstance( OUString(
RTL_CONSTASCII_USTRINGPARAM("com.sun.star.drawing.GraphicExportFilter") ) ) );
+ mxGraphicExporter = Reference< XExporter >::query( mxMSF->createInstance(
"com.sun.star.drawing.GraphicExportFilter" ) );
Reference< XFilter > xFilter( mxGraphicExporter, UNO_QUERY );
@@ -647,32 +643,32 @@
aFile.EnableKillingFile();
Sequence< PropertyValue > aFilterData(bExportAsJPEG ? 3 : 2);
- aFilterData[0].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("Version") );
+ aFilterData[0].Name = "Version";
aFilterData[0].Value <<= (sal_Int32)6000;
- aFilterData[1].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("PageNumber") );
+ aFilterData[1].Name = "PageNumber";
aFilterData[1].Value <<= mnPageNumber;
if(bExportAsJPEG)
{
- aFilterData[2].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("Translucent") );
+ aFilterData[2].Name = "Translucent";
aFilterData[2].Value <<= (sal_Bool)sal_True;
}
Sequence< PropertyValue > aDescriptor( bOnlyBackground ? 4 : 3 );
- aDescriptor[0].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("FilterName") );
+ aDescriptor[0].Name = "FilterName";
// AS: If we've been asked to export as an image, then use the BMP filter.
// Otherwise, use SVM. This is useful for things that don't convert well as
// metafiles, like the occasional OLE object.
- aDescriptor[0].Value <<= OUString( RTL_CONSTASCII_USTRINGPARAM(bExportAsJPEG ? "PNG" : "SVM")
);
+ aDescriptor[0].Value <<= bExportAsJPEG ? OUString("PNG") : OUString("SVM");
- aDescriptor[1].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("URL") );
- aDescriptor[1].Value <<= OUString( aFile.GetURL() );
- aDescriptor[2].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("FilterData") );
+ aDescriptor[1].Name = "URL";
+ aDescriptor[1].Value <<= OUString(aFile.GetURL());
+ aDescriptor[2].Name = "FilterData";
aDescriptor[2].Value <<= aFilterData;
if( bOnlyBackground )
{
- aDescriptor[3].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("ExportOnlyBackground") );
+ aDescriptor[3].Name = "ExportOnlyBackground";
aDescriptor[3].Value <<= (sal_Bool)bOnlyBackground;
}
mxGraphicExporter->setSourceDocument( xComponent );
diff --git a/filter/source/flash/swffilter.cxx b/filter/source/flash/swffilter.cxx
index 7f5037c..210d163 100644
--- a/filter/source/flash/swffilter.cxx
+++ b/filter/source/flash/swffilter.cxx
@@ -329,7 +329,7 @@
const sal_Int32 nPageCount = xDrawPages->getCount();
if ( mxStatusIndicator.is() )
- mxStatusIndicator->start(OUString( RTL_CONSTASCII_USTRINGPARAM( "Saving :" )), nPageCount);
+ mxStatusIndicator->start( "Saving :", nPageCount);
for(sal_Int32 nPage = 0; nPage < nPageCount; nPage++)
{
@@ -451,7 +451,7 @@
OUString FlashExportFilter_getImplementationName ()
throw (RuntimeException)
{
- return OUString ( RTL_CONSTASCII_USTRINGPARAM ( "com.sun.star.comp.Impress.FlashExportFilter"
) );
+ return OUString ( "com.sun.star.comp.Impress.FlashExportFilter" );
}
// -----------------------------------------------------------------------------
@@ -471,7 +471,7 @@
{
Sequence < OUString > aRet(1);
OUString* pArray = aRet.getArray();
- pArray[0] = OUString ( RTL_CONSTASCII_USTRINGPARAM ( SERVICE_NAME ) );
+ pArray[0] = OUString ( SERVICE_NAME );
return aRet;
}
#undef SERVICE_NAME
diff --git a/filter/source/flash/swfwriter1.cxx b/filter/source/flash/swfwriter1.cxx
index ce66447..fd0b91e 100644
--- a/filter/source/flash/swfwriter1.cxx
+++ b/filter/source/flash/swfwriter1.cxx
@@ -866,12 +866,12 @@
Sequence< PropertyValue > aFilterData(nJPEGQualityLevel != -1);
if( nJPEGQualityLevel != -1 )
{
- aFilterData[0].Name = OUString( RTL_CONSTASCII_USTRINGPARAM("Quality"));
+ aFilterData[0].Name = "Quality";
aFilterData[0].Value <<= nJPEGQualityLevel;
}
if( aFilter.ExportGraphic( aGraphic, String(), aDstStm,
- aFilter.GetExportFormatNumberForShortName( OUString(
RTL_CONSTASCII_USTRINGPARAM( JPG_SHORTNAME ) ) ), &aFilterData ) == ERRCODE_NONE )
+ aFilter.GetExportFormatNumberForShortName( OUString(JPG_SHORTNAME)
), &aFilterData ) == ERRCODE_NONE )
{
pJpgData = reinterpret_cast<const sal_uInt8*>(aDstStm.GetData());
nJpgDataLength = aDstStm.Seek( STREAM_SEEK_TO_END );
@@ -1640,7 +1640,7 @@
const sal_uInt8* pData = pA->GetData();
String aSkipComment;
- if(
pA->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XGRAD_SEQ_BEGIN")) )
+ if( pA->GetComment().equalsIgnoreAsciiCase("XGRAD_SEQ_BEGIN") )
{
const MetaGradientExAction* pGradAction = NULL;
sal_Bool bDone = sal_False;
@@ -1652,7 +1652,7 @@
if( pAction->GetType() == META_GRADIENTEX_ACTION )
pGradAction = (const MetaGradientExAction*) pAction;
else if( ( pAction->GetType() == META_COMMENT_ACTION ) &&
- ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XGRAD_SEQ_END")) ) )
+ ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCase("XGRAD_SEQ_END") ) )
{
bDone = sal_True;
}
@@ -1661,8 +1661,7 @@
if( pGradAction )
Impl_writeGradientEx( pGradAction->GetPolyPolygon(),
pGradAction->GetGradient());
}
- else if(
pA->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XPATHFILL_SEQ_BEGIN")) &&
- pData )
+ else if( pA->GetComment().equalsIgnoreAsciiCase("XPATHFILL_SEQ_BEGIN") && pData )
{
// this comment encapsulates all high level information for a filling that
caused
@@ -1685,15 +1684,14 @@
pAction = rMtf.GetAction( i );
if( ( pAction->GetType() == META_COMMENT_ACTION ) &&
- ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XPATHFILL_SEQ_END")) ) )
+ ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCase("XPATHFILL_SEQ_END") ) )
{
bDone = sal_True;
}
}
}
}
- else if(
pA->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XPATHSTROKE_SEQ_BEGIN")) &&
- pData )
+ else if( pA->GetComment().equalsIgnoreAsciiCase("XPATHSTROKE_SEQ_BEGIN") && pData )
{
// this comment encapsulates all high level information for a filling that
caused
@@ -1716,7 +1714,7 @@
pAction = rMtf.GetAction( i );
if( ( pAction->GetType() == META_COMMENT_ACTION ) &&
- ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XPATHSTROKE_SEQ_END")) ) )
+ ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCase("XPATHSTROKE_SEQ_END") ) )
{
bDone = sal_True;
}
diff --git a/filter/source/graphicfilter/egif/egif.cxx b/filter/source/graphicfilter/egif/egif.cxx
index 93be78c..5593941 100644
--- a/filter/source/graphicfilter/egif/egif.cxx
+++ b/filter/source/graphicfilter/egif/egif.cxx
@@ -108,7 +108,7 @@
m_pAcc = NULL;
if ( pFilterConfigItem )
- nInterlaced = pFilterConfigItem->ReadInt32( String( RTL_CONSTASCII_USTRINGPARAM(
"Interlaced" ) ), 0 );
+ nInterlaced = pFilterConfigItem->ReadInt32( "Interlaced", 0 );
m_rGIF.SetNumberFormatInt( NUMBERFORMAT_INT_LITTLEENDIAN );
diff --git a/filter/source/graphicfilter/eps/eps.cxx b/filter/source/graphicfilter/eps/eps.cxx
index d3e0aa9..9405328 100644
--- a/filter/source/graphicfilter/eps/eps.cxx
+++ b/filter/source/graphicfilter/eps/eps.cxx
@@ -298,10 +298,10 @@
if( pResMgr )
{
- String aPreviewStr( RTL_CONSTASCII_USTRINGPARAM( "Preview" ) );
- String aVersionStr( RTL_CONSTASCII_USTRINGPARAM( "Version" ) );
- String aColorStr( RTL_CONSTASCII_USTRINGPARAM( "ColorFormat" ) );
- String aComprStr( RTL_CONSTASCII_USTRINGPARAM( "CompressionMode" ) );
+ String aPreviewStr( "Preview" );
+ String aVersionStr( "Version" );
+ String aColorStr( "ColorFormat" );
+ String aComprStr( "CompressionMode" );
#ifdef UNX // don't put binary tiff preview ahead of postscript code by default on unix as
ghostscript is unable to read it
mnPreview = pFilterConfigItem->ReadInt32( aPreviewStr, 0 );
#else
@@ -316,7 +316,7 @@
#else
mbCompression = pFilterConfigItem->ReadInt32( aComprStr, 1 ) == 1;
#endif
- String sTextMode( RTL_CONSTASCII_USTRINGPARAM( "TextMode" ) );
+ String sTextMode( "TextMode" );
mnTextMode = pFilterConfigItem->ReadInt32( sTextMode, 0 );
if ( mnTextMode > 2 )
mnTextMode = 0;
@@ -468,12 +468,9 @@
ImplWriteLong( aSizePoint.Width() );
ImplWriteLong( aSizePoint.Height() ,PS_RET );
ImplWriteLine( "%%Pages: 0" );
- ::rtl::OUStringBuffer aCreator;
- aCreator.appendAscii( RTL_CONSTASCII_STRINGPARAM( "%%Creator: " ) );
- aCreator.append( utl::ConfigManager::getProductName() );
- aCreator.appendAscii( RTL_CONSTASCII_STRINGPARAM( " " ) );
- aCreator.append( utl::ConfigManager::getProductVersion() );
- ImplWriteLine( ::rtl::OUStringToOString( aCreator.makeStringAndClear(), RTL_TEXTENCODING_UTF8
).getStr() );
+ OUString aCreator( "%%Creator: " + utl::ConfigManager::getProductName() + " " +
+ utl::ConfigManager::getProductVersion() );
+ ImplWriteLine( OUStringToOString( aCreator, RTL_TEXTENCODING_UTF8 ).getStr() );
ImplWriteLine( "%%Title: none" );
ImplWriteLine( "%%CreationDate: none" );
@@ -1222,7 +1219,7 @@
case META_COMMENT_ACTION:
{
const MetaCommentAction* pA = (const MetaCommentAction*) pMA;
- if (
pA->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XGRAD_SEQ_BEGIN")) )
+ if ( pA->GetComment().equalsIgnoreAsciiCase("XGRAD_SEQ_BEGIN") )
{
const MetaGradientExAction* pGradAction = NULL;
while( ++nCurAction < nCount )
@@ -1231,7 +1228,7 @@
if( pAction->GetType() == META_GRADIENTEX_ACTION )
pGradAction = (const MetaGradientExAction*) pAction;
else if( ( pAction->GetType() == META_COMMENT_ACTION ) &&
- ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("XGRAD_SEQ_END")) ) )
+ ( ( (const MetaCommentAction*) pAction
)->GetComment().equalsIgnoreAsciiCase("XGRAD_SEQ_END") ) )
{
break;
}
@@ -1239,7 +1236,7 @@
if( pGradAction )
ImplWriteGradient( pGradAction->GetPolyPolygon(),
pGradAction->GetGradient(), rVDev );
}
- else if (
pA->GetComment().equalsL(RTL_CONSTASCII_STRINGPARAM("XPATHFILL_SEQ_END")) )
+ else if ( pA->GetComment().equals("XPATHFILL_SEQ_END") )
{
if ( aFillPath.Count() )
{
@@ -1256,9 +1253,9 @@
sal_Bool bSkipSequence = sal_False;
rtl::OString sSeqEnd;
- if( pA->GetComment().equalsL(RTL_CONSTASCII_STRINGPARAM(
"XPATHSTROKE_SEQ_BEGIN" )) )
+ if( pA->GetComment().equals( "XPATHSTROKE_SEQ_BEGIN" ) )
{
- sSeqEnd =
rtl::OString(RTL_CONSTASCII_STRINGPARAM("XPATHSTROKE_SEQ_END"));
+ sSeqEnd = "XPATHSTROKE_SEQ_END";
SvtGraphicStroke aStroke;
aMemStm >> aStroke;
@@ -1292,9 +1289,9 @@
ImplPolyLine( aPath );
}
}
- else if
(pA->GetComment().equalsL(RTL_CONSTASCII_STRINGPARAM("XPATHFILL_SEQ_BEGIN")))
+ else if (pA->GetComment().equals("XPATHFILL_SEQ_BEGIN"))
{
- sSeqEnd =
rtl::OString(RTL_CONSTASCII_STRINGPARAM("XPATHFILL_SEQ_END"));
+ sSeqEnd = "XPATHFILL_SEQ_END";
SvtGraphicFill aFill;
aMemStm >> aFill;
switch( aFill.getFillType() )
@@ -1363,7 +1360,7 @@
break;
case META_COMMENT_ACTION :
{
- if (((const
MetaCommentAction*)pAction)->GetComment().equalsL(RTL_CONSTASCII_STRINGPARAM("XPATHFILL_SEQ_END")))
+ if (((const
MetaCommentAction*)pAction)->GetComment().equals("XPATHFILL_SEQ_END"))
bOk = sal_False;
}
break;
diff --git a/filter/source/graphicfilter/icgm/actimpr.cxx
b/filter/source/graphicfilter/icgm/actimpr.cxx
index 6075a4f..049bcd5 100644
--- a/filter/source/graphicfilter/icgm/actimpr.cxx
+++ b/filter/source/graphicfilter/icgm/actimpr.cxx
@@ -117,11 +117,11 @@
{
uno::Any aAny;
aAny <<= (sal_Int32)rRefPoint.X;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "RotationPointX" )),
aAny );
+ maXPropSet->setPropertyValue( "RotationPointX", aAny );
aAny <<= (sal_Int32)rRefPoint.Y;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "RotationPointY" )),
aAny );
+ maXPropSet->setPropertyValue( "RotationPointY", aAny );
aAny <<= (sal_Int32)( rOrientation * 100.0 );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "RotateAngle" )),
aAny );
+ maXPropSet->setPropertyValue( "RotateAngle", aAny );
}
// ---------------------------------------------------------------
@@ -149,10 +149,10 @@
fLineWidth = mpCGM->pElement->aLineBundle.nLineWidth;
aAny <<= (sal_Int32)nLineColor;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineColor" )), aAny
);
+ maXPropSet->setPropertyValue( "LineColor", aAny );
aAny <<= (sal_Int32)fLineWidth;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineWidth" )), aAny
);
+ maXPropSet->setPropertyValue( "LineWidth", aAny );
switch( eLineType )
{
@@ -173,12 +173,12 @@
break;
}
aAny <<= eLS;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineStyle" )), aAny
);
+ maXPropSet->setPropertyValue( "LineStyle", aAny );
if ( eLS == drawing::LineStyle_DASH )
{
drawing::LineDash aLineDash( drawing::DashStyle_RECTRELATIVE, 1, 50, 3, 33, 100 );
aAny <<= aLineDash;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineDash" )),
aAny );
+ maXPropSet->setPropertyValue( "LineDash", aAny );
}
};
@@ -231,7 +231,7 @@
nHatchIndex = (sal_uInt32)mpCGM->pElement->aFillBundle.nFillHatchIndex;
aAny <<= (sal_Int32)nFillColor;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FillColor" )), aAny
);
+ maXPropSet->setPropertyValue( "FillColor", aAny );
switch ( eFillStyle )
{
@@ -279,27 +279,27 @@
if ( eFS == drawing::FillStyle_GRADIENT )
{
aAny <<= *mpGradient;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FillGradient"
)), aAny );
+ maXPropSet->setPropertyValue( "FillGradient", aAny );
}
aAny <<= eFS;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FillStyle" )), aAny
);
+ maXPropSet->setPropertyValue( "FillStyle", aAny );
eLS = drawing::LineStyle_NONE;
if ( eFillStyle == FIS_HOLLOW )
{
eLS = drawing::LineStyle_SOLID;
aAny <<= (sal_Int32)nFillColor;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineColor" )),
aAny );
+ maXPropSet->setPropertyValue( "LineColor", aAny );
aAny <<= (sal_Int32)0;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineWidth" )),
aAny );
+ maXPropSet->setPropertyValue( "LineWidth", aAny );
}
else if ( eEdgeType != ET_NONE )
{
aAny <<= (sal_Int32)nEdgeColor;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineColor" )),
aAny );
+ maXPropSet->setPropertyValue( "LineColor", aAny );
aAny <<= (sal_Int32)fEdgeWidth;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineWidth" )),
aAny );
+ maXPropSet->setPropertyValue( "LineWidth", aAny );
switch( eEdgeType )
{
@@ -319,7 +319,7 @@
}
aAny <<= eLS;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LineStyle" )), aAny
);
+ maXPropSet->setPropertyValue( "LineStyle", aAny );
if ( eFS == drawing::FillStyle_HATCH )
{
@@ -348,7 +348,7 @@
aHatch.Angle = 15 * ( ( nHatchIndex & 0x1f ) - 5 );
}
aAny <<= aHatch;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FillHatch" )),
aAny );
+ maXPropSet->setPropertyValue( "FillHatch", aAny );
}
};
@@ -370,7 +370,7 @@
nTextColor = mpCGM->pElement->aTextBundle.GetColor();
aAny <<= (sal_Int32)nTextColor;
- rProperty->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "CharColor" )), aAny
);
+ rProperty->setPropertyValue( "CharColor", aAny );
sal_uInt32 nFontType = 0;
awt::FontDescriptor aFontDescriptor;
@@ -393,7 +393,7 @@
aFontDescriptor.Underline = awt::FontUnderline::SINGLE;
}
aAny <<= aFontDescriptor;
- rProperty->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "FontDescriptor" )),
aAny );
+ rProperty->setPropertyValue( "FontDescriptor", aAny );
};
// ---------------------------------------------------------------
@@ -472,7 +472,7 @@
{
if ( mnGroupActCount != ( mpCGM->mnActCount - 1 ) ) // POWERPOINT HACK !!!
{
- if ( ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.RectangleShape" )) ) )
+ if ( ImplCreateShape( "com.sun.star.drawing.RectangleShape" ) )
{
awt::Size aSize( (long)(rFloatRect.Right - rFloatRect.Left ),
(long)(rFloatRect.Bottom-rFloatRect.Top ) );
maXShape->setSize( aSize );
@@ -486,11 +486,11 @@
void CGMImpressOutAct::DrawEllipse( FloatPoint& rCenter, FloatPoint& rSize, double& rOrientation )
{
- if ( ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.EllipseShape" )) ) )
+ if ( ImplCreateShape( "com.sun.star.drawing.EllipseShape" ) )
{
drawing::CircleKind eCircleKind = drawing::CircleKind_FULL;
uno::Any aAny( &eCircleKind, ::getCppuType((const drawing::CircleKind*)0) );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "CircleKind" )),
aAny );
+ maXPropSet->setPropertyValue( "CircleKind", aAny );
long nXSize = (long)( rSize.X * 2.0 ); // Merkwuerdigkes Verhalten bei einer
awt::Size von 0
long nYSize = (long)( rSize.Y * 2.0 );
@@ -514,7 +514,7 @@
void CGMImpressOutAct::DrawEllipticalArc( FloatPoint& rCenter, FloatPoint& rSize, double&
rOrientation,
sal_uInt32 nType, double& fStartAngle, double& fEndAngle )
{
- if ( ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.EllipseShape" )) ) )
+ if ( ImplCreateShape( "com.sun.star.drawing.EllipseShape" ) )
{
uno::Any aAny;
drawing::CircleKind eCircleKind;
@@ -553,11 +553,11 @@
else
{
aAny.setValue( &eCircleKind, ::getCppuType((const drawing::CircleKind*)0) );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "CircleKind"
)), aAny );
+ maXPropSet->setPropertyValue( "CircleKind", aAny );
aAny <<= (sal_Int32)( (long)( fStartAngle * 100 ) );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"CircleStartAngle" )), aAny );
+ maXPropSet->setPropertyValue( "CircleStartAngle", aAny );
aAny <<= (sal_Int32)( (long)( fEndAngle * 100 ) );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"CircleEndAngle" )), aAny );
+ maXPropSet->setPropertyValue( "CircleEndAngle", aAny );
}
maXShape->setPosition( awt::Point( (long)( rCenter.X - rSize.X ), (long)( rCenter.Y -
rSize.Y ) ) );
if ( rOrientation != 0 )
@@ -576,7 +576,7 @@
ImplSetLineBundle();
drawing::FillStyle eFillStyle = drawing::FillStyle_NONE;
aAny.setValue( &eFillStyle, ::getCppuType((const drawing::FillStyle*)0) );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"FillStyle" )), aAny );
+ maXPropSet->setPropertyValue( "FillStyle", aAny );
}
}
}
@@ -604,7 +604,7 @@
mpCGM->ImplMapX( fdx );
mpCGM->ImplMapY( fdy );
- if ( ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.GraphicObjectShape" )) ) )
+ if ( ImplCreateShape( "com.sun.star.drawing.GraphicObjectShape" ) )
{
maXShape->setSize( awt::Size( (long)fdx, (long)fdy ) );
maXShape->setPosition( awt::Point( (long)aOrigin.X, (long)aOrigin.Y ) );
@@ -617,7 +617,7 @@
uno::Reference< awt::XBitmap > xBitmap( VCLUnoHelper::CreateBitmap( BitmapEx( *(
pBmpDesc->mpBitmap ) ) ) );
uno::Any aAny;
aAny <<= xBitmap;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"GraphicObjectFillBitmap" )), aAny );
+ maXPropSet->setPropertyValue( "GraphicObjectFillBitmap", aAny );
}
}
@@ -629,7 +629,7 @@
{
sal_uInt16 nPoints = rPoly.GetSize();
- if ( ( nPoints > 1 ) && ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.PolyPolygonShape" )) ) )
+ if ( ( nPoints > 1 ) && ImplCreateShape( "com.sun.star.drawing.PolyPolygonShape" ) )
{
drawing::PointSequenceSequence aRetval;
@@ -650,7 +650,7 @@
uno::Any aParam;
aParam <<= aRetval;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "PolyPolygon"
)), aParam );
+ maXPropSet->setPropertyValue( "PolyPolygon", aParam );
ImplSetFillBundle();
}
};
@@ -662,7 +662,7 @@
{
sal_uInt16 nPoints = rPoly.GetSize();
- if ( ( nPoints > 1 ) && ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.PolyLineShape" )) ) )
+ if ( ( nPoints > 1 ) && ImplCreateShape( "com.sun.star.drawing.PolyLineShape" ) )
{
drawing::PointSequenceSequence aRetval;
@@ -683,7 +683,7 @@
uno::Any aParam;
aParam <<= aRetval;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "PolyPolygon"
)), aParam );
+ maXPropSet->setPropertyValue( "PolyPolygon", aParam );
ImplSetLineBundle();
}
};
@@ -693,7 +693,7 @@
void CGMImpressOutAct::DrawPolybezier( Polygon& rPolygon )
{
sal_uInt16 nPoints = rPolygon.GetSize();
- if ( ( nPoints > 1 ) && ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.OpenBezierShape" )) ) )
+ if ( ( nPoints > 1 ) && ImplCreateShape( "com.sun.star.drawing.OpenBezierShape" ) )
{
drawing::PolyPolygonBezierCoords aRetval;
@@ -718,7 +718,7 @@
}
uno::Any aParam;
aParam <<= aRetval;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"PolyPolygonBezier" )), aParam );
+ maXPropSet->setPropertyValue( "PolyPolygonBezier", aParam );
ImplSetLineBundle();
}
};
@@ -728,7 +728,7 @@
void CGMImpressOutAct::DrawPolyPolygon( PolyPolygon& rPolyPolygon )
{
sal_uInt32 nNumPolys = rPolyPolygon.Count();
- if ( nNumPolys && ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.ClosedBezierShape" )) ) )
+ if ( nNumPolys && ImplCreateShape( "com.sun.star.drawing.ClosedBezierShape" ) )
{
drawing::PolyPolygonBezierCoords aRetval;
@@ -763,7 +763,7 @@
}
uno::Any aParam;
aParam <<= aRetval;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"PolyPolygonBezier" )), aParam);
+ maXPropSet->setPropertyValue( "PolyPolygonBezier", aParam);
ImplSetFillBundle();
}
};
@@ -772,7 +772,7 @@
void CGMImpressOutAct::DrawText( awt::Point& rTextPos, awt::Size& rTextSize, char* pString,
sal_uInt32 /*nSize*/, FinalFlag eFlag )
{
- if ( ImplCreateShape( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"com.sun.star.drawing.TextShape" )) ) )
+ if ( ImplCreateShape( "com.sun.star.drawing.TextShape" ) )
{
uno::Any aAny;
long nWidth = rTextSize.Width;
@@ -825,17 +825,17 @@
if ( nOrientation )
{
aAny <<= (sal_Int32)( aTextPos.X );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"RotationPointX" )), aAny );
+ maXPropSet->setPropertyValue( "RotationPointX", aAny );
aAny <<= (sal_Int32)( aTextPos.Y + nHeight );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"RotationPointY" )), aAny );
+ maXPropSet->setPropertyValue( "RotationPointY", aAny );
aAny <<= (sal_Int32)( (sal_Int32)( nOrientation * 100 ) );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"RotateAngle" )), aAny );
+ maXPropSet->setPropertyValue( "RotateAngle", aAny );
}
if ( nWidth == -1 )
{
sal_Bool bTrue( sal_True );
aAny.setValue( &bTrue, ::getCppuType((const sal_Bool*)0 ));
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"TextAutoGrowWidth" )), aAny );
+ maXPropSet->setPropertyValue( "TextAutoGrowWidth", aAny );
drawing::TextAdjust eTextAdjust;
switch ( mpCGM->pElement->eTextAlignmentH )
@@ -853,13 +853,13 @@
break;
}
aAny <<= eTextAdjust;
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"TextHorizontalAdjust" )), aAny );
+ maXPropSet->setPropertyValue( "TextHorizontalAdjust", aAny );
}
if ( nHeight == -1 )
{
sal_Bool bTrue = sal_True;
aAny.setValue( &bTrue, ::getCppuType((const sal_Bool*)0) );
- maXPropSet->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM(
"TextAutoGrowHeight" )), aAny );
+ maXPropSet->setPropertyValue( "TextAutoGrowHeight", aAny );
}
uno::Reference< text::XText > xText;
uno::Any aFirstQuery( maXShape->queryInterface( ::getCppuType((const uno::Reference<
text::XText >*)0) ));
@@ -895,13 +895,13 @@
aAny <<= (sal_Int16)style::HorizontalAlignment_CENTER;
break;
}
- aCursorPropSet->setPropertyValue( rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM( "ParaAdjust" )), aAny );
+ aCursorPropSet->setPropertyValue( "ParaAdjust", aAny );
}
if ( nWidth > 0 && nHeight > 0 ) // restricted text
{
sal_Bool bTrue = sal_True;
aAny.setValue( &bTrue, ::getCppuType((const sal_Bool*)0));
- maXPropSet->setPropertyValue( rtl::OUString(
RTL_CONSTASCII_USTRINGPARAM( "TextFitToSize" )), aAny );
+ maXPropSet->setPropertyValue( "TextFitToSize", aAny );
}
aCursorText->setString( aStr );
aXTextCursor->gotoEnd( sal_True );
--
To view, visit https://gerrit.libreoffice.org/1772
To unsubscribe, visit https://gerrit.libreoffice.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I5bfed073bd84e4dee4bc7e7b4715e413859beb50
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: master
Gerrit-Owner: Marcos Souza <marcos.souza.org@gmail.com>
Context
- [PATCH] Remove more STRINGPARAM macros from filter · Marcos Souza (via Code Review)
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.