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
5e530127
Commit
5e530127
authored
Feb 26, 2013
by
Huw Davies
Committed by
Alexandre Julliard
Feb 26, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
riched20: Don't assume the the runs in a row are in visual order.
parent
c5c4d549
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
7 deletions
+10
-7
caret.c
dlls/riched20/caret.c
+10
-7
No files found.
dlls/riched20/caret.c
View file @
5e530127
...
...
@@ -869,6 +869,14 @@ static BOOL ME_FindRunInRow(ME_TextEditor *editor, ME_DisplayItem *pRow,
int
x
,
ME_Cursor
*
cursor
,
int
*
pbCaretAtEnd
)
{
ME_DisplayItem
*
pNext
,
*
pLastRun
;
ME_Row
*
row
=
&
pRow
->
member
.
row
;
BOOL
exact
=
TRUE
;
if
(
x
<
row
->
pt
.
x
)
{
x
=
row
->
pt
.
x
;
exact
=
FALSE
;
}
pNext
=
ME_FindItemFwd
(
pRow
,
diRunOrStartRow
);
assert
(
pNext
->
type
==
diRun
);
if
(
pbCaretAtEnd
)
*
pbCaretAtEnd
=
FALSE
;
...
...
@@ -876,18 +884,13 @@ static BOOL ME_FindRunInRow(ME_TextEditor *editor, ME_DisplayItem *pRow,
do
{
int
run_x
=
pNext
->
member
.
run
.
pt
.
x
;
int
width
=
pNext
->
member
.
run
.
nWidth
;
if
(
x
<
run_x
)
{
cursor
->
pRun
=
pNext
;
cursor
->
pPara
=
ME_GetParagraph
(
cursor
->
pRun
);
return
FALSE
;
}
if
(
x
>=
run_x
&&
x
<
run_x
+
width
)
{
cursor
->
nOffset
=
ME_CharFromPoint
(
editor
,
x
-
run_x
,
&
pNext
->
member
.
run
,
TRUE
);
cursor
->
pRun
=
pNext
;
cursor
->
pPara
=
ME_GetParagraph
(
cursor
->
pRun
);
return
TRUE
;
return
exact
;
}
pLastRun
=
pNext
;
pNext
=
ME_FindItemFwd
(
pNext
,
diRunOrStartRow
);
...
...
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