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
e8a1a232
Commit
e8a1a232
authored
May 28, 2002
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
A few fixes in ExtSelectClipRgn metafile functions.
parent
284bcfcf
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
16 deletions
+20
-16
dc.c
dlls/gdi/enhmfdrv/dc.c
+9
-4
graphics.c
dlls/gdi/enhmfdrv/graphics.c
+3
-3
graphics.c
dlls/gdi/mfdrv/graphics.c
+8
-9
No files found.
dlls/gdi/enhmfdrv/dc.c
View file @
e8a1a232
...
...
@@ -134,11 +134,16 @@ INT EMFDRV_ExtSelectClipRgn( PHYSDEV dev, HRGN hrgn, INT mode )
DWORD
size
,
rgnsize
;
BOOL
ret
;
rgnsize
=
GetRegionData
(
hrgn
,
0
,
NULL
);
size
=
rgnsize
+
sizeof
(
*
emr
)
-
1
;
if
(
!
hrgn
)
{
if
(
mode
!=
RGN_COPY
)
return
ERROR
;
rgnsize
=
0
;
}
else
rgnsize
=
GetRegionData
(
hrgn
,
0
,
NULL
);
size
=
rgnsize
+
offsetof
(
EMREXTSELECTCLIPRGN
,
RgnData
);
emr
=
HeapAlloc
(
GetProcessHeap
(),
0
,
size
);
GetRegionData
(
hrgn
,
rgnsize
,
(
RGNDATA
*
)
&
emr
->
RgnData
);
if
(
rgnsize
)
GetRegionData
(
hrgn
,
rgnsize
,
(
RGNDATA
*
)
&
emr
->
RgnData
);
emr
->
emr
.
iType
=
EMR_EXTSELECTCLIPRGN
;
emr
->
emr
.
nSize
=
size
;
...
...
dlls/gdi/enhmfdrv/graphics.c
View file @
e8a1a232
...
...
@@ -490,7 +490,7 @@ BOOL EMFDRV_FillRgn( PHYSDEV dev, HRGN hrgn, HBRUSH hbrush )
if
(
!
index
)
return
FALSE
;
rgnsize
=
GetRegionData
(
hrgn
,
0
,
NULL
);
size
=
rgnsize
+
sizeof
(
EMRFILLRGN
)
-
1
;
size
=
rgnsize
+
offsetof
(
EMRFILLRGN
,
RgnData
)
;
emr
=
HeapAlloc
(
GetProcessHeap
(),
0
,
size
);
GetRegionData
(
hrgn
,
rgnsize
,
(
RGNDATA
*
)
&
emr
->
RgnData
);
...
...
@@ -523,7 +523,7 @@ BOOL EMFDRV_FrameRgn( PHYSDEV dev, HRGN hrgn, HBRUSH hbrush, INT width, INT heig
if
(
!
index
)
return
FALSE
;
rgnsize
=
GetRegionData
(
hrgn
,
0
,
NULL
);
size
=
rgnsize
+
sizeof
(
EMRFRAMERGN
)
-
1
;
size
=
rgnsize
+
offsetof
(
EMRFRAMERGN
,
RgnData
)
;
emr
=
HeapAlloc
(
GetProcessHeap
(),
0
,
size
);
GetRegionData
(
hrgn
,
rgnsize
,
(
RGNDATA
*
)
&
emr
->
RgnData
);
...
...
@@ -559,7 +559,7 @@ static BOOL EMFDRV_PaintInvertRgn( PHYSDEV dev, HRGN hrgn, DWORD iType )
rgnsize
=
GetRegionData
(
hrgn
,
0
,
NULL
);
size
=
rgnsize
+
sizeof
(
EMRINVERTRGN
)
-
1
;
size
=
rgnsize
+
offsetof
(
EMRINVERTRGN
,
RgnData
)
;
emr
=
HeapAlloc
(
GetProcessHeap
(),
0
,
size
);
GetRegionData
(
hrgn
,
rgnsize
,
(
RGNDATA
*
)
&
emr
->
RgnData
);
...
...
dlls/gdi/mfdrv/graphics.c
View file @
e8a1a232
...
...
@@ -237,7 +237,7 @@ static INT16 MFDRV_CreateRegion(PHYSDEV dev, HRGN hrgn)
WORD
*
Param
,
*
StartBand
;
BOOL
ret
;
len
=
GetRegionData
(
hrgn
,
0
,
NULL
)
;
if
(
!
(
len
=
GetRegionData
(
hrgn
,
0
,
NULL
)))
return
-
1
;
if
(
!
(
rgndata
=
HeapAlloc
(
GetProcessHeap
(),
0
,
len
))
)
{
WARN
(
"Can't alloc rgndata buffer
\n
"
);
return
-
1
;
...
...
@@ -376,16 +376,15 @@ MFDRV_FrameRgn( PHYSDEV dev, HRGN hrgn, HBRUSH hbrush, INT x, INT y )
INT
MFDRV_ExtSelectClipRgn
(
PHYSDEV
dev
,
HRGN
hrgn
,
INT
mode
)
{
INT16
iRgn
;
INT
ret
;
if
(
mode
!=
RGN_COPY
)
{
FIXME
(
"mode %d not supported
\n
"
,
mode
);
return
ERROR
;
}
if
(
mode
!=
RGN_COPY
)
return
ERROR
;
if
(
!
hrgn
)
return
NULLREGION
;
iRgn
=
MFDRV_CreateRegion
(
dev
,
hrgn
);
if
(
iRgn
==
-
1
)
return
ERROR
;
return
MFDRV_MetaParam1
(
dev
,
META_SELECTCLIPREGION
,
iRgn
)
?
SIMPLEREGION
:
ERROR
;
if
(
iRgn
==
-
1
)
return
ERROR
;
ret
=
MFDRV_MetaParam1
(
dev
,
META_SELECTCLIPREGION
,
iRgn
)
?
NULLREGION
:
ERROR
;
MFDRV_MetaParam1
(
dev
,
META_DELETEOBJECT
,
iRgn
);
return
ret
;
}
...
...
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