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
33d7cea1
Commit
33d7cea1
authored
Mar 16, 2008
by
Eric Pouech
Committed by
Alexandre Julliard
Mar 17, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
richedit: Added support for EM_SETTARGETDEVICE with a NULL DC.
parent
3502e286
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
6 deletions
+25
-6
editor.c
dlls/riched20/editor.c
+14
-2
editstr.h
dlls/riched20/editstr.h
+2
-1
wrap.c
dlls/riched20/wrap.c
+9
-3
No files found.
dlls/riched20/editor.c
View file @
33d7cea1
...
...
@@ -114,7 +114,7 @@
+ EM_SETSEL
+ EM_SETSCROLLPOS 3.0
- EM_SETTABSTOPS 3.0
- EM_SETTARGETDEVICE
- EM_SETTARGETDEVICE
(partial)
+ EM_SETTEXTEX 3.0 (no rich text insertion handling, proper style?)
- EM_SETTEXTMODE 2.0
- EM_SETTYPOGRAPHYOPTIONS 3.0
...
...
@@ -1590,6 +1590,7 @@ ME_TextEditor *ME_MakeEditor(HWND hWnd) {
ed
->
nLastSelStart
=
ed
->
nLastSelEnd
=
0
;
ed
->
pLastSelStartPara
=
ed
->
pLastSelEndPara
=
ME_FindItemFwd
(
ed
->
pBuffer
->
pFirst
,
diParagraph
);
ed
->
bRedraw
=
TRUE
;
ed
->
bWordWrap
=
FALSE
;
ed
->
bHideSelection
=
FALSE
;
ed
->
nInvalidOfs
=
-
1
;
ed
->
pfnWordBreak
=
NULL
;
...
...
@@ -1901,7 +1902,6 @@ static LRESULT RichEditWndProc_common(HWND hWnd, UINT msg, WPARAM wParam,
UNSUPPORTED_MSG
(
EM_SETLANGOPTIONS
)
UNSUPPORTED_MSG
(
EM_SETPALETTE
)
UNSUPPORTED_MSG
(
EM_SETTABSTOPS
)
UNSUPPORTED_MSG
(
EM_SETTARGETDEVICE
)
UNSUPPORTED_MSG
(
EM_SETTYPOGRAPHYOPTIONS
)
UNSUPPORTED_MSG
(
EM_SETWORDBREAKPROCEX
)
UNSUPPORTED_MSG
(
WM_STYLECHANGING
)
...
...
@@ -3188,6 +3188,18 @@ static LRESULT RichEditWndProc_common(HWND hWnd, UINT msg, WPARAM wParam,
ME_RewrapRepaint
(
editor
);
return
0
;
}
case
EM_SETTARGETDEVICE
:
if
(
wParam
==
0
)
{
switch
(
lParam
)
{
case
0
:
editor
->
bWordWrap
=
TRUE
;
break
;
case
1
:
editor
->
bWordWrap
=
FALSE
;
break
;
default:
FIXME
(
"Unknown option to EM_SETTARGETDEVICE(NULL,%ld)
\n
"
,
lParam
);
}
}
else
FIXME
(
"Unsupported yet non NULL device in EM_SETTARGETDEVICE
\n
"
);
break
;
default:
do_default:
return
DefWindowProcW
(
hWnd
,
msg
,
wParam
,
lParam
);
...
...
dlls/riched20/editstr.h
View file @
33d7cea1
...
...
@@ -312,6 +312,7 @@ typedef struct tagME_TextEditor
int
nZoomNumerator
,
nZoomDenominator
;
RECT
rcFormat
;
BOOL
bRedraw
;
BOOL
bWordWrap
;
int
nInvalidOfs
;
int
nTextLimit
;
EDITWORDBREAKPROCW
pfnWordBreak
;
...
...
@@ -350,7 +351,7 @@ typedef struct tagME_WrapContext
ME_Style
*
style
;
ME_Context
*
context
;
int
nLeftMargin
,
nRightMargin
,
nFirstMargin
;
int
n
TotalWidth
,
n
AvailWidth
;
int
nAvailWidth
;
int
nRow
;
POINT
pt
;
BOOL
bOverflown
;
...
...
dlls/riched20/wrap.c
View file @
33d7cea1
...
...
@@ -47,7 +47,11 @@ static void ME_BeginRow(ME_WrapContext *wc)
wc
->
pRowStart
=
NULL
;
wc
->
bOverflown
=
FALSE
;
wc
->
pLastSplittableRun
=
NULL
;
wc
->
nAvailWidth
=
wc
->
nTotalWidth
-
(
wc
->
nRow
?
wc
->
nLeftMargin
:
wc
->
nFirstMargin
)
-
wc
->
nRightMargin
;
if
(
wc
->
context
->
editor
->
bWordWrap
)
wc
->
nAvailWidth
=
wc
->
context
->
rcView
.
right
-
wc
->
context
->
rcView
.
left
-
(
wc
->
nRow
?
wc
->
nLeftMargin
:
wc
->
nFirstMargin
)
-
wc
->
nRightMargin
;
else
wc
->
nAvailWidth
=
~
0u
>>
1
;
wc
->
pt
.
x
=
0
;
}
...
...
@@ -393,8 +397,10 @@ static void ME_WrapTextParagraph(ME_Context *c, ME_DisplayItem *tp, DWORD begino
wc
.
pt
.
y
+=
border
;
}
wc
.
nTotalWidth
=
c
->
rcView
.
right
-
c
->
rcView
.
left
;
wc
.
nAvailWidth
=
wc
.
nTotalWidth
-
wc
.
nFirstMargin
-
wc
.
nRightMargin
;
if
(
c
->
editor
->
bWordWrap
)
wc
.
nAvailWidth
=
c
->
rcView
.
right
-
c
->
rcView
.
left
-
wc
.
nFirstMargin
-
wc
.
nRightMargin
;
else
wc
.
nAvailWidth
=
~
0u
>>
1
;
wc
.
pRowStart
=
NULL
;
linespace
=
ME_GetParaLineSpace
(
c
,
&
tp
->
member
.
para
);
...
...
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