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
c2cb39b8
Commit
c2cb39b8
authored
Jul 26, 2005
by
Phil Krylov
Committed by
Alexandre Julliard
Jul 26, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implemented EM_CHARFROMPOS RichEdit message.
parent
2b6b09f5
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
2 deletions
+20
-2
caret.c
dlls/riched20/caret.c
+16
-0
editor.c
dlls/riched20/editor.c
+3
-2
editor.h
dlls/riched20/editor.h
+1
-0
No files found.
dlls/riched20/caret.c
View file @
c2cb39b8
...
...
@@ -584,6 +584,22 @@ int ME_FindPixelPos(ME_TextEditor *editor, int x, int y, ME_Cursor *result, BOOL
return
0
;
}
int
ME_CharFromPos
(
ME_TextEditor
*
editor
,
int
x
,
int
y
)
{
ME_Cursor
cursor
;
RECT
rc
;
GetClientRect
(
editor
->
hWnd
,
&
rc
);
if
(
x
<
0
||
y
<
0
||
x
>=
rc
.
right
||
y
>=
rc
.
bottom
)
return
-
1
;
ME_FindPixelPos
(
editor
,
x
,
y
,
&
cursor
,
NULL
);
return
(
ME_GetParagraph
(
cursor
.
pRun
)
->
member
.
para
.
nCharOfs
+
cursor
.
pRun
->
member
.
run
.
nCharOfs
+
cursor
.
nOffset
);
}
void
ME_LButtonDown
(
ME_TextEditor
*
editor
,
int
x
,
int
y
)
{
ME_Cursor
tmp_cursor
;
...
...
dlls/riched20/editor.c
View file @
c2cb39b8
...
...
@@ -26,7 +26,7 @@
+ EM_CANPASTE
+ EM_CANREDO 2.0
+ EM_CANUNDO
-
EM_CHARFROMPOS
+
EM_CHARFROMPOS
- EM_DISPLAYBAND
+ EM_EMPTYUNDOBUFFER
+ EM_EXGETSEL
...
...
@@ -1026,7 +1026,6 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
switch
(
msg
)
{
UNSUPPORTED_MSG
(
EM_AUTOURLDETECT
)
UNSUPPORTED_MSG
(
EM_CHARFROMPOS
)
UNSUPPORTED_MSG
(
EM_DISPLAYBAND
)
UNSUPPORTED_MSG
(
EM_EXLIMITTEXT
)
UNSUPPORTED_MSG
(
EM_FINDWORDBREAK
)
...
...
@@ -1587,6 +1586,8 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
return
TRUE
;
case
EM_SETZOOM
:
return
ME_SetZoom
(
editor
,
wParam
,
lParam
);
case
EM_CHARFROMPOS
:
return
ME_CharFromPos
(
editor
,
((
POINTL
*
)
lParam
)
->
x
,
((
POINTL
*
)
lParam
)
->
y
);
case
WM_CREATE
:
ME_CommitUndo
(
editor
);
ME_WrapMarkedParagraphs
(
editor
);
...
...
dlls/riched20/editor.h
View file @
c2cb39b8
...
...
@@ -141,6 +141,7 @@ void ME_HideCaret(ME_TextEditor *ed);
void
ME_ShowCaret
(
ME_TextEditor
*
ed
);
void
ME_MoveCaret
(
ME_TextEditor
*
ed
);
int
ME_FindPixelPos
(
ME_TextEditor
*
editor
,
int
x
,
int
y
,
ME_Cursor
*
result
,
BOOL
*
is_eol
);
int
ME_CharFromPos
(
ME_TextEditor
*
editor
,
int
x
,
int
y
);
void
ME_LButtonDown
(
ME_TextEditor
*
editor
,
int
x
,
int
y
);
void
ME_MouseMove
(
ME_TextEditor
*
editor
,
int
x
,
int
y
);
void
ME_DeleteTextAtCursor
(
ME_TextEditor
*
editor
,
int
nCursor
,
int
nChars
);
...
...
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