Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
292c99e3
Commit
292c99e3
authored
Oct 17, 2006
by
Jeff Latimer
Committed by
Alexandre Julliard
Oct 17, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
usp10: Fix dead code in ScriptItemize.
parent
35ee9b05
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
2 deletions
+13
-2
usp10.c
dlls/usp10/tests/usp10.c
+12
-1
usp10.c
dlls/usp10/usp10.c
+1
-1
No files found.
dlls/usp10/tests/usp10.c
View file @
292c99e3
...
...
@@ -46,7 +46,8 @@ static void test_ScriptItemIzeShapePlace(HDC hdc, unsigned short pwOutGlyphs[256
WCHAR
TestItem1
[]
=
{
'T'
,
'e'
,
's'
,
't'
,
'a'
,
0
};
WCHAR
TestItem2
[]
=
{
'T'
,
'e'
,
's'
,
't'
,
'b'
,
0
};
WCHAR
TestItem3
[]
=
{
'T'
,
'e'
,
's'
,
't'
,
'c'
,
' '
,
'1'
,
'2'
,
'3'
,
' '
,
' '
,
'e'
,
'n'
,
'd'
,
0
};
WCHAR
TestItem4
[]
=
{
'T'
,
'e'
,
's'
,
't'
,
'c'
,
' '
,
0x0684
,
0x0694
,
0x06a4
,
' '
,
' '
,
'e'
,
'n'
,
'd'
,
0
};
WCHAR
TestItem4
[]
=
{
'T'
,
'e'
,
's'
,
't'
,
'c'
,
' '
,
0x0684
,
0x0694
,
0x06a4
,
' '
,
' '
,
'e'
,
'n'
,
'd'
,
0
};
WCHAR
TestItem5
[]
=
{
0x0684
,
'T'
,
'e'
,
's'
,
't'
,
'c'
,
' '
,
0x0684
,
0x0694
,
0x06a4
,
' '
,
' '
,
'e'
,
'n'
,
'd'
,
0
};
SCRIPT_CACHE
psc
;
int
cChars
;
...
...
@@ -243,6 +244,16 @@ static void test_ScriptItemIzeShapePlace(HDC hdc, unsigned short pwOutGlyphs[256
hr
=
ScriptFreeCache
(
&
psc
);
ok
(
!
psc
,
"psc is not null after ScriptFreeCache
\n
"
);
}
/*
* This test is for when the first unicode character requires bidi support
*/
cInChars
=
(
sizeof
(
TestItem5
)
-
1
)
/
sizeof
(
WCHAR
);
hr
=
ScriptItemize
(
TestItem5
,
cInChars
,
cMaxItems
,
NULL
,
NULL
,
pItem
,
&
pcItems
);
ok
(
hr
==
0
,
"ScriptItemize should return 0, returned %08x
\n
"
,
hr
);
ok
(
pcItems
==
4
,
"There should have been 4 items, found %d
\n
"
,
pcItems
);
ok
(
pItem
[
0
].
a
.
s
.
uBidiLevel
==
1
,
"The first character should have been bidi=1 not %d
\n
"
,
pItem
[
0
].
a
.
s
.
uBidiLevel
);
}
void
test_ScriptGetCMap
(
HDC
hdc
,
unsigned
short
pwOutGlyphs
[
256
])
...
...
dlls/usp10/usp10.c
View file @
292c99e3
...
...
@@ -326,7 +326,7 @@ HRESULT WINAPI ScriptItemize(const WCHAR *pwcInChars, int cInChars, int cMaxItem
pItems
[
index
].
a
.
fLogicalOrder
=
0
;
pItems
[
index
].
a
.
fNoGlyphIndex
=
0
;
/* set the SCRIPT_STATE */
if
(
New_Script
==
Script_Arabic
)
if
(
pItems
[
index
].
a
.
eScript
==
Script_Arabic
)
pItems
[
index
].
a
.
s
.
uBidiLevel
=
1
;
else
pItems
[
index
].
a
.
s
.
uBidiLevel
=
0
;
...
...
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