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
a91ba787
Commit
a91ba787
authored
Nov 03, 2005
by
Phil Krylov
Committed by
Alexandre Julliard
Nov 03, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added support for EM_REQUESTRESIZE message, EN_REQUESTRESIZE
notification, and ENM_REQUESTRESIZE event mask.
parent
4770d57a
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
40 additions
and
3 deletions
+40
-3
caret.c
dlls/riched20/caret.c
+4
-0
editor.c
dlls/riched20/editor.c
+6
-3
editor.h
dlls/riched20/editor.h
+1
-0
paint.c
dlls/riched20/paint.c
+2
-0
wrap.c
dlls/riched20/wrap.c
+27
-0
No files found.
dlls/riched20/caret.c
View file @
a91ba787
...
...
@@ -1097,6 +1097,7 @@ BOOL ME_ArrowKey(ME_TextEditor *editor, int nVKey, int nCtrl)
editor
->
bCaretAtEnd
=
FALSE
;
/* FIXME or maybe not */
ME_DeleteSelection
(
editor
);
ME_UpdateRepaint
(
editor
);
ME_SendRequestResize
(
editor
,
FALSE
);
return
TRUE
;
}
if
(
ME_ArrowLeft
(
editor
,
p
))
{
...
...
@@ -1105,6 +1106,7 @@ BOOL ME_ArrowKey(ME_TextEditor *editor, int nVKey, int nCtrl)
ME_MoveCaret
(
editor
);
ME_DeleteTextAtCursor
(
editor
,
nCursor
,
1
);
ME_UpdateRepaint
(
editor
);
ME_SendRequestResize
(
editor
,
FALSE
);
}
return
TRUE
;
}
...
...
@@ -1117,11 +1119,13 @@ BOOL ME_ArrowKey(ME_TextEditor *editor, int nVKey, int nCtrl)
ME_DeleteSelection
(
editor
);
ME_ClearTempStyle
(
editor
);
ME_UpdateRepaint
(
editor
);
ME_SendRequestResize
(
editor
,
FALSE
);
return
TRUE
;
}
ME_DeleteTextAtCursor
(
editor
,
nCursor
,
1
);
ME_ClearTempStyle
(
editor
);
ME_UpdateRepaint
(
editor
);
ME_SendRequestResize
(
editor
,
FALSE
);
return
TRUE
;
}
case
VK_HOME
:
{
...
...
dlls/riched20/editor.c
View file @
a91ba787
...
...
@@ -83,7 +83,7 @@
- EM_PASTESPECIAL
+ EM_POSFROMCHAR
+ EM_REDO 2.0
-
EM_REQUESTRESIZE
+
EM_REQUESTRESIZE
+ EM_REPLACESEL (proper style?) ANSI&Unicode
- EM_SCROLL
- EM_SCROLLCARET
...
...
@@ -153,7 +153,7 @@
- EN_MSGFILTER
- EN_OLEOPFAILED
- EN_PROTECTED
-
EN_REQUESTRESIZE
+
EN_REQUESTRESIZE
- EN_SAVECLIPBOARD
+ EN_SELCHANGE
+ EN_SETFOCUS
...
...
@@ -633,6 +633,7 @@ static LRESULT ME_StreamIn(ME_TextEditor *editor, DWORD format, EDITSTREAM *stre
}
ME_MoveCaret
(
editor
);
ME_SendSelChange
(
editor
);
ME_SendRequestResize
(
editor
,
FALSE
);
return
0
;
}
...
...
@@ -1134,7 +1135,6 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
UNSUPPORTED_MSG
(
EM_HIDESELECTION
)
UNSUPPORTED_MSG
(
EM_LIMITTEXT
)
/* also known as EM_SETLIMITTEXT */
UNSUPPORTED_MSG
(
EM_PASTESPECIAL
)
UNSUPPORTED_MSG
(
EM_REQUESTRESIZE
)
UNSUPPORTED_MSG
(
EM_SCROLL
)
UNSUPPORTED_MSG
(
EM_SCROLLCARET
)
UNSUPPORTED_MSG
(
EM_SELECTIONTYPE
)
...
...
@@ -1974,6 +1974,9 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
ME_RewrapRepaint
(
editor
);
return
0
;
}
case
EM_REQUESTRESIZE
:
ME_SendRequestResize
(
editor
,
TRUE
);
return
0
;
case
WM_SETREDRAW
:
editor
->
bRedraw
=
wParam
;
return
0
;
...
...
dlls/riched20/editor.h
View file @
a91ba787
...
...
@@ -173,6 +173,7 @@ ME_DisplayItem *ME_MakeRow(int height, int baseline, int width);
void
ME_InsertRowStart
(
ME_WrapContext
*
wc
,
ME_DisplayItem
*
pEnd
);
void
ME_WrapTextParagraph
(
ME_Context
*
c
,
ME_DisplayItem
*
tp
);
BOOL
ME_WrapMarkedParagraphs
(
ME_TextEditor
*
editor
);
void
ME_SendRequestResize
(
ME_TextEditor
*
editor
,
BOOL
force
);
/* para.c */
ME_DisplayItem
*
ME_GetParagraph
(
ME_DisplayItem
*
run
);
...
...
dlls/riched20/paint.c
View file @
a91ba787
...
...
@@ -90,6 +90,8 @@ void ME_PaintContent(ME_TextEditor *editor, HDC hDC, BOOL bOnlyNew, RECT *rcUpda
if
(
ys
==
c
.
pt
.
y
)
/* don't overwrite the top bar */
ys
++
;
}
if
(
editor
->
nTotalLength
!=
editor
->
nLastTotalLength
)
ME_SendRequestResize
(
editor
,
FALSE
);
editor
->
nLastTotalLength
=
editor
->
nTotalLength
;
ME_DestroyContext
(
&
c
);
}
...
...
dlls/riched20/wrap.c
View file @
a91ba787
...
...
@@ -448,9 +448,36 @@ BOOL ME_WrapMarkedParagraphs(ME_TextEditor *editor) {
}
editor
->
sizeWindow
.
cx
=
c
.
rcView
.
right
-
c
.
rcView
.
left
;
editor
->
sizeWindow
.
cy
=
c
.
rcView
.
bottom
-
c
.
rcView
.
top
;
editor
->
nTotalLength
=
c
.
pt
.
y
;
ME_DestroyContext
(
&
c
);
ReleaseDC
(
hWnd
,
hDC
);
return
bModified
;
}
void
ME_SendRequestResize
(
ME_TextEditor
*
editor
,
BOOL
force
)
{
if
(
editor
->
nEventMask
&
ENM_REQUESTRESIZE
)
{
RECT
rc
;
GetClientRect
(
editor
->
hWnd
,
&
rc
);
if
(
force
||
rc
.
bottom
!=
editor
->
nTotalLength
)
{
REQRESIZE
info
;
info
.
nmhdr
.
hwndFrom
=
editor
->
hWnd
;
info
.
nmhdr
.
idFrom
=
GetWindowLongW
(
editor
->
hWnd
,
GWLP_ID
);
info
.
nmhdr
.
code
=
EN_REQUESTRESIZE
;
info
.
rc
=
rc
;
info
.
rc
.
bottom
=
editor
->
nTotalLength
;
SendMessageW
(
GetParent
(
editor
->
hWnd
),
WM_NOTIFY
,
info
.
nmhdr
.
idFrom
,
(
LPARAM
)
&
info
);
}
}
}
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