Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
67cf9cbe
Kaydet (Commit)
67cf9cbe
authored
Eki 28, 2011
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
add and use an OString::equalsIgnoreAsciiCaseAscii equivalent to OUString one
üst
489272ce
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
9 deletions
+33
-9
implrenderer.cxx
cppcanvas/source/mtfrenderer/implrenderer.cxx
+9
-9
string.hxx
sal/inc/rtl/string.hxx
+24
-0
No files found.
cppcanvas/source/mtfrenderer/implrenderer.cxx
Dosyayı görüntüle @
67cf9cbe
...
...
@@ -516,8 +516,8 @@ namespace cppcanvas
++
io_rCurrActionIndex
;
if
(
pCurrAct
->
GetType
()
==
META_COMMENT_ACTION
&&
static_cast
<
MetaCommentAction
*>
(
pCurrAct
)
->
GetComment
().
CompareIgnoreCaseTo
Ascii
(
pCommentString
)
==
COMPARE_EQUAL
)
static_cast
<
MetaCommentAction
*>
(
pCurrAct
)
->
GetComment
().
equalsIgnoreAsciiCase
Ascii
(
pCommentString
)
)
{
// requested comment found, done
return
;
...
...
@@ -551,8 +551,8 @@ namespace cppcanvas
}
if
(
pCurrAct
->
GetType
()
==
META_COMMENT_ACTION
&&
static_cast
<
MetaCommentAction
*>
(
pCurrAct
)
->
GetComment
().
CompareIgnoreCaseTo
Ascii
(
pCommentString
)
==
COMPARE_EQUAL
)
static_cast
<
MetaCommentAction
*>
(
pCurrAct
)
->
GetComment
().
equalsIgnoreAsciiCase
Ascii
(
pCommentString
)
)
{
// delimiting end comment found, done
bRet
=
false
;
// not yet found
...
...
@@ -1686,7 +1686,7 @@ namespace cppcanvas
MetaCommentAction
*
pAct
=
static_cast
<
MetaCommentAction
*>
(
pCurrAct
);
// Handle gradients
if
(
pAct
->
GetComment
().
CompareIgnoreCaseToAscii
(
"XGRAD_SEQ_BEGIN"
)
==
COMPARE_EQUAL
)
if
(
pAct
->
GetComment
().
equalsIgnoreAsciiCaseAsciiL
(
RTL_CONSTASCII_STRINGPARAM
(
"XGRAD_SEQ_BEGIN"
))
)
{
MetaGradientExAction
*
pGradAction
=
NULL
;
bool
bDone
(
false
);
...
...
@@ -1702,7 +1702,7 @@ namespace cppcanvas
// skip broken-down rendering, output gradient when sequence is ended
case
META_COMMENT_ACTION
:
if
(
static_cast
<
MetaCommentAction
*>
(
pCurrAct
)
->
GetComment
().
CompareIgnoreCaseToAscii
(
"XGRAD_SEQ_END"
)
==
COMPARE_EQUAL
)
if
(
static_cast
<
MetaCommentAction
*>
(
pCurrAct
)
->
GetComment
().
equalsIgnoreAsciiCaseAsciiL
(
RTL_CONSTASCII_STRINGPARAM
(
"XGRAD_SEQ_END"
))
)
{
bDone
=
true
;
...
...
@@ -1723,7 +1723,7 @@ namespace cppcanvas
// XPATHSTROKE_SEQ_BEGIN comment
// Handle drawing layer fills
else
if
(
pAct
->
GetComment
().
Equals
(
"XPATHFILL_SEQ_BEGIN"
)
)
else
if
(
pAct
->
GetComment
().
equalsL
(
RTL_CONSTASCII_STRINGPARAM
(
"XPATHFILL_SEQ_BEGIN"
)
)
)
{
const
sal_uInt8
*
pData
=
pAct
->
GetData
();
if
(
pData
)
...
...
@@ -1839,7 +1839,7 @@ namespace cppcanvas
}
}
// Handle drawing layer fills
else
if
(
pAct
->
GetComment
().
Equals
(
"EMF_PLUS"
)
)
{
else
if
(
pAct
->
GetComment
().
equalsL
(
RTL_CONSTASCII_STRINGPARAM
(
"EMF_PLUS"
)
)
)
{
static
int
count
=
-
1
,
limit
=
0x7fffffff
;
if
(
count
==
-
1
)
{
count
=
0
;
...
...
@@ -1852,7 +1852,7 @@ namespace cppcanvas
if
(
count
<
limit
)
processEMFPlus
(
pAct
,
rFactoryParms
,
getState
(
rStates
),
rCanvas
);
count
++
;
}
else
if
(
pAct
->
GetComment
().
Equals
(
"EMF_PLUS_HEADER_INFO"
)
)
{
}
else
if
(
pAct
->
GetComment
().
equalsL
(
RTL_CONSTASCII_STRINGPARAM
(
"EMF_PLUS_HEADER_INFO"
)
)
)
{
EMFP_DEBUG
(
printf
(
"EMF+ passed to canvas mtf renderer - header info, size: %u
\n
"
,
(
unsigned
int
)
pAct
->
GetDataSize
()));
SvMemoryStream
rMF
((
void
*
)
pAct
->
GetData
(),
pAct
->
GetDataSize
(),
STREAM_READ
);
...
...
sal/inc/rtl/string.hxx
Dosyayı görüntüle @
67cf9cbe
...
...
@@ -396,6 +396,30 @@ public:
str
.
pData
->
buffer
,
str
.
pData
->
length
)
==
0
;
}
/**
Perform a ASCII lowercase comparison of two strings.
The result is true if and only if second string
represents the same sequence of characters as the first string,
ignoring the case.
Character values between 65 and 90 (ASCII A-Z) are interpreted as
values between 97 and 122 (ASCII a-z).
Since this method is optimized for performance, the ASCII character
values are not converted in any way. The caller has to make sure that
all ASCII characters are in the allowed range between 0 and
127. The ASCII string must be NULL-terminated.
This function can't be used for language specific comparison.
@param asciiStr the 8-Bit ASCII character string to be compared.
@return sal_True if the strings are equal;
sal_False, otherwise.
*/
sal_Bool
equalsIgnoreAsciiCaseAscii
(
const
sal_Char
*
asciiStr
)
const
SAL_THROW
(())
{
return
rtl_str_compareIgnoreAsciiCase_WithLength
(
pData
->
buffer
,
pData
->
length
,
asciiStr
,
rtl_str_getLength
(
asciiStr
)
)
==
0
;
}
/**
Perform a ASCII lowercase comparison of two strings.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment