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
832ec705
Commit
832ec705
authored
Feb 28, 2006
by
Dmitry Timoshkov
Committed by
Alexandre Julliard
Feb 28, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
notepad: Wrap long lines by default like Windows does.
parent
8e5d2bdb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
main.c
programs/notepad/main.c
+10
-2
No files found.
programs/notepad/main.c
View file @
832ec705
...
@@ -143,6 +143,9 @@ static VOID NOTEPAD_InitData(VOID)
...
@@ -143,6 +143,9 @@ static VOID NOTEPAD_InitData(VOID)
*
p
=
'\0'
;
*
p
=
'\0'
;
Globals
.
hDevMode
=
NULL
;
Globals
.
hDevMode
=
NULL
;
Globals
.
hDevNames
=
NULL
;
Globals
.
hDevNames
=
NULL
;
CheckMenuItem
(
GetMenu
(
Globals
.
hMainWnd
),
CMD_WRAP
,
MF_BYCOMMAND
|
(
Globals
.
bWrapLongLines
?
MF_CHECKED
:
MF_UNCHECKED
));
}
}
/***********************************************************************
/***********************************************************************
...
@@ -178,11 +181,15 @@ static LRESULT WINAPI NOTEPAD_WndProc(HWND hWnd, UINT msg, WPARAM wParam,
...
@@ -178,11 +181,15 @@ static LRESULT WINAPI NOTEPAD_WndProc(HWND hWnd, UINT msg, WPARAM wParam,
case
WM_CREATE
:
case
WM_CREATE
:
{
{
static
const
WCHAR
editW
[]
=
{
'e'
,
'd'
,
'i'
,
't'
,
0
};
static
const
WCHAR
editW
[]
=
{
'e'
,
'd'
,
'i'
,
't'
,
0
};
DWORD
dwStyle
=
WS_CHILD
|
WS_VISIBLE
|
WS_BORDER
|
WS_VSCROLL
|
ES_AUTOVSCROLL
|
ES_MULTILINE
;
RECT
rc
;
RECT
rc
;
GetClientRect
(
hWnd
,
&
rc
);
GetClientRect
(
hWnd
,
&
rc
);
if
(
!
Globals
.
bWrapLongLines
)
dwStyle
|=
WS_HSCROLL
|
ES_AUTOHSCROLL
;
Globals
.
hEdit
=
CreateWindowEx
(
WS_EX_CLIENTEDGE
,
editW
,
NULL
,
Globals
.
hEdit
=
CreateWindowEx
(
WS_EX_CLIENTEDGE
,
editW
,
NULL
,
WS_CHILD
|
WS_VISIBLE
|
WS_BORDER
|
WS_VSCROLL
|
WS_HSCROLL
|
dwStyle
,
ES_AUTOVSCROLL
|
ES_MULTILINE
,
0
,
0
,
rc
.
right
,
rc
.
bottom
,
hWnd
,
0
,
0
,
rc
.
right
,
rc
.
bottom
,
hWnd
,
NULL
,
Globals
.
hInstance
,
NULL
);
NULL
,
Globals
.
hInstance
,
NULL
);
NOTEPAD_InitFont
();
NOTEPAD_InitFont
();
...
@@ -370,6 +377,7 @@ int PASCAL WinMain(HINSTANCE hInstance, HINSTANCE prev, LPSTR cmdline, int show)
...
@@ -370,6 +377,7 @@ int PASCAL WinMain(HINSTANCE hInstance, HINSTANCE prev, LPSTR cmdline, int show)
ZeroMemory
(
&
Globals
,
sizeof
(
Globals
));
ZeroMemory
(
&
Globals
,
sizeof
(
Globals
));
Globals
.
hInstance
=
hInstance
;
Globals
.
hInstance
=
hInstance
;
Globals
.
bWrapLongLines
=
TRUE
;
ZeroMemory
(
&
class
,
sizeof
(
class
));
ZeroMemory
(
&
class
,
sizeof
(
class
));
class
.
cbSize
=
sizeof
(
class
);
class
.
cbSize
=
sizeof
(
class
);
...
...
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