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
e1ca5c38
Commit
e1ca5c38
authored
Sep 01, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winex11: Fix SetDIBitsToDevice coordinate mapping in RTL mode.
parent
67b1f29d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
0 deletions
+15
-0
bitmap.c
dlls/gdi32/tests/bitmap.c
+14
-0
dib.c
dlls/winex11.drv/dib.c
+1
-0
No files found.
dlls/gdi32/tests/bitmap.c
View file @
e1ca5c38
...
...
@@ -4287,6 +4287,20 @@ static void test_SetDIBitsToDevice(void)
memset
(
dib_bits
,
0xaa
,
64
*
4
);
SetMapMode
(
hdc
,
MM_TEXT
);
if
(
pSetLayout
)
{
pSetLayout
(
hdc
,
LAYOUT_RTL
);
ret
=
SetDIBitsToDevice
(
hdc
,
1
,
2
,
3
,
2
,
1
,
2
,
1
,
5
,
data
,
info
,
DIB_RGB_COLORS
);
ok
(
ret
==
3
,
"got %d
\n
"
,
ret
);
for
(
i
=
0
;
i
<
64
;
i
++
)
if
(
i
==
36
||
i
==
37
||
i
==
38
||
i
==
44
||
i
==
45
||
i
==
46
)
ok
(
dib_bits
[
i
]
==
data
[
i
-
27
],
"%d: got %08x
\n
"
,
i
,
dib_bits
[
i
]
);
else
ok
(
dib_bits
[
i
]
==
0xaaaaaaaa
,
"%d: got %08x
\n
"
,
i
,
dib_bits
[
i
]
);
memset
(
dib_bits
,
0xaa
,
64
*
4
);
pSetLayout
(
hdc
,
LAYOUT_LTR
);
}
/* t-d -> b-u */
info
->
bmiHeader
.
biHeight
=
-
8
;
ret
=
SetDIBitsToDevice
(
hdc
,
0
,
0
,
8
,
8
,
0
,
0
,
0
,
8
,
data
,
info
,
DIB_RGB_COLORS
);
...
...
dlls/winex11.drv/dib.c
View file @
e1ca5c38
...
...
@@ -3737,6 +3737,7 @@ INT X11DRV_SetDIBitsToDevice( PHYSDEV dev, INT xDest, INT yDest, DWORD cx, DWORD
pt
.
x
=
xDest
;
pt
.
y
=
yDest
;
LPtoDP
(
dev
->
hdc
,
&
pt
,
1
);
if
(
GetLayout
(
dev
->
hdc
)
&
LAYOUT_RTL
)
pt
.
x
-=
cx
-
1
;
if
(
!
lines
||
(
startscan
>=
height
))
return
0
;
if
(
!
top_down
&&
startscan
+
lines
>
height
)
lines
=
height
-
startscan
;
...
...
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