Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
364e2164
Commit
364e2164
authored
Oct 26, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Add a helper function to start a new path stroke.
parent
fc5e2948
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
11 deletions
+14
-11
path.c
dlls/gdi32/path.c
+14
-11
No files found.
dlls/gdi32/path.c
View file @
364e2164
...
...
@@ -230,6 +230,18 @@ static BOOL PATH_AddEntry(GdiPath *pPath, const POINT *pPoint, BYTE flags)
return
TRUE
;
}
/* start a new path stroke if necessary */
static
BOOL
start_new_stroke
(
struct
path_physdev
*
physdev
)
{
POINT
pos
;
if
(
!
physdev
->
path
->
newStroke
)
return
TRUE
;
physdev
->
path
->
newStroke
=
FALSE
;
GetCurrentPositionEx
(
physdev
->
dev
.
hdc
,
&
pos
);
LPtoDP
(
physdev
->
dev
.
hdc
,
&
pos
,
1
);
return
PATH_AddEntry
(
physdev
->
path
,
&
pos
,
PT_MOVETO
);
}
/* PATH_AssignGdiPath
*
* Copies the GdiPath structure "pPathSrc" to "pPathDest". A deep copy is
...
...
@@ -902,24 +914,15 @@ static BOOL pathdrv_MoveTo( PHYSDEV dev, INT x, INT y )
static
BOOL
pathdrv_LineTo
(
PHYSDEV
dev
,
INT
x
,
INT
y
)
{
struct
path_physdev
*
physdev
=
get_path_physdev
(
dev
);
POINT
point
,
pointCurPos
;
POINT
point
;
/* Convert point to device coordinates */
point
.
x
=
x
;
point
.
y
=
y
;
LPtoDP
(
dev
->
hdc
,
&
point
,
1
);
/* Add a PT_MOVETO if necessary */
if
(
physdev
->
path
->
newStroke
)
{
physdev
->
path
->
newStroke
=
FALSE
;
GetCurrentPositionEx
(
dev
->
hdc
,
&
pointCurPos
);
LPtoDP
(
dev
->
hdc
,
&
pointCurPos
,
1
);
if
(
!
PATH_AddEntry
(
physdev
->
path
,
&
pointCurPos
,
PT_MOVETO
))
return
FALSE
;
}
if
(
!
start_new_stroke
(
physdev
))
return
FALSE
;
/* Add a PT_LINETO entry */
return
PATH_AddEntry
(
physdev
->
path
,
&
point
,
PT_LINETO
);
}
...
...
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