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
3138b4a8
Commit
3138b4a8
authored
Nov 21, 2004
by
Huw Davies
Committed by
Alexandre Julliard
Nov 21, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
The default font for the treeview should be the icon title font.
parent
f23b358b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
5 deletions
+9
-5
treeview.c
dlls/comctl32/treeview.c
+9
-5
No files found.
dlls/comctl32/treeview.c
View file @
3138b4a8
...
...
@@ -130,6 +130,7 @@ typedef struct tagTREEVIEW_INFO
COLORREF
clrLine
;
COLORREF
clrInsertMark
;
HFONT
hFont
;
HFONT
hDefaultFont
;
HFONT
hBoldFont
;
HWND
hwndToolTip
;
...
...
@@ -255,11 +256,11 @@ TREEVIEW_ValidItem(TREEVIEW_INFO *infoPtr, HTREEITEM handle)
static
HFONT
TREEVIEW_CreateBoldFont
(
HFONT
hOrigFont
)
{
LOGFONT
A
font
;
LOGFONT
W
font
;
GetObject
A
(
hOrigFont
,
sizeof
(
font
),
&
font
);
GetObject
W
(
hOrigFont
,
sizeof
(
font
),
&
font
);
font
.
lfWeight
=
FW_BOLD
;
return
CreateFontIndirect
A
(
&
font
);
return
CreateFontIndirect
W
(
&
font
);
}
static
inline
HFONT
...
...
@@ -1809,7 +1810,7 @@ TREEVIEW_SetFont(TREEVIEW_INFO *infoPtr, HFONT hFont, BOOL bRedraw)
TRACE
(
"%p %i
\n
"
,
hFont
,
bRedraw
);
infoPtr
->
hFont
=
hFont
?
hFont
:
GetStockObject
(
SYSTEM_FONT
)
;
infoPtr
->
hFont
=
hFont
?
hFont
:
infoPtr
->
hDefaultFont
;
DeleteObject
(
infoPtr
->
hBoldFont
);
infoPtr
->
hBoldFont
=
TREEVIEW_CreateBoldFont
(
infoPtr
->
hFont
);
...
...
@@ -4684,6 +4685,7 @@ TREEVIEW_Create(HWND hwnd, const CREATESTRUCTW *lpcs)
static
const
WCHAR
szDisplayW
[]
=
{
'D'
,
'I'
,
'S'
,
'P'
,
'L'
,
'A'
,
'Y'
,
'\0'
};
RECT
rcClient
;
TREEVIEW_INFO
*
infoPtr
;
LOGFONTW
lf
;
TRACE
(
"wnd %p, style %lx
\n
"
,
hwnd
,
GetWindowLongW
(
hwnd
,
GWL_STYLE
));
...
...
@@ -4749,7 +4751,8 @@ TREEVIEW_Create(HWND hwnd, const CREATESTRUCTW *lpcs)
infoPtr
->
items
=
DPA_Create
(
16
);
infoPtr
->
hFont
=
GetStockObject
(
DEFAULT_GUI_FONT
);
SystemParametersInfoW
(
SPI_GETICONTITLELOGFONT
,
sizeof
(
lf
),
&
lf
,
0
);
infoPtr
->
hFont
=
infoPtr
->
hDefaultFont
=
CreateFontIndirectW
(
&
lf
);
infoPtr
->
hBoldFont
=
TREEVIEW_CreateBoldFont
(
infoPtr
->
hFont
);
infoPtr
->
uItemHeight
=
TREEVIEW_NaturalHeight
(
infoPtr
);
...
...
@@ -4839,6 +4842,7 @@ TREEVIEW_Destroy(TREEVIEW_INFO *infoPtr)
/* Deassociate treeview from the window before doing anything drastic. */
SetWindowLongPtrW
(
infoPtr
->
hwnd
,
0
,
(
DWORD_PTR
)
NULL
);
DeleteObject
(
infoPtr
->
hDefaultFont
);
DeleteObject
(
infoPtr
->
hBoldFont
);
Free
(
infoPtr
);
...
...
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