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
2223450a
Commit
2223450a
authored
Apr 08, 2002
by
Hidenori Takeshima
Committed by
Alexandre Julliard
Apr 08, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use default GUI font instead of hard-coded 'MS Sans Serif'.
parent
66503b06
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
35 additions
and
5 deletions
+35
-5
sysparams.c
windows/sysparams.c
+35
-5
No files found.
windows/sysparams.c
View file @
2223450a
...
@@ -483,6 +483,29 @@ INT SYSPARAMS_GetMouseButtonSwap( void )
...
@@ -483,6 +483,29 @@ INT SYSPARAMS_GetMouseButtonSwap( void )
}
}
/***********************************************************************
/***********************************************************************
*
* SYSPARAMS_GetGUIFont
*
* fills LOGFONT with 'default GUI font'.
*/
static
void
SYSPARAMS_GetGUIFont
(
LOGFONTA
*
plf
)
{
HFONT
hf
;
memset
(
plf
,
0
,
sizeof
(
LOGFONTA
)
);
hf
=
(
HFONT
)
GetStockObject
(
DEFAULT_GUI_FONT
);
if
(
GetObjectA
(
hf
,
sizeof
(
LOGFONTA
),
plf
)
!=
sizeof
(
LOGFONTA
)
)
{
/*
* GetObjectA() would be succeeded always
* since this is a stock object
*/
ERR
(
"GetObjectA() failed
\n
"
);
}
}
/***********************************************************************
* SystemParametersInfoA (USER32.@)
* SystemParametersInfoA (USER32.@)
*
*
* Each system parameter has flag which shows whether the parameter
* Each system parameter has flag which shows whether the parameter
...
@@ -1015,10 +1038,17 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
...
@@ -1015,10 +1038,17 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
case
SPI_GETICONTITLELOGFONT
:
/* 31 */
case
SPI_GETICONTITLELOGFONT
:
/* 31 */
{
{
LPLOGFONTA
lpLogFont
=
(
LPLOGFONTA
)
pvParam
;
LPLOGFONTA
lpLogFont
=
(
LPLOGFONTA
)
pvParam
;
LOGFONTA
lfDefault
;
/* from now on we always have an alias for MS Sans Serif */
/*
* The 'default GDI fonts' seems to be returned.
* If a returned font is not a correct font in your environment,
* please try to fix objects/gdiobj.c at first.
*/
SYSPARAMS_GetGUIFont
(
&
lfDefault
);
GetProfileStringA
(
"Desktop"
,
"IconTitleFaceName"
,
"MS Sans Serif"
,
GetProfileStringA
(
"Desktop"
,
"IconTitleFaceName"
,
lfDefault
.
lfFaceName
,
lpLogFont
->
lfFaceName
,
LF_FACESIZE
);
lpLogFont
->
lfFaceName
,
LF_FACESIZE
);
lpLogFont
->
lfHeight
=
-
GetProfileIntA
(
"Desktop"
,
"IconTitleSize"
,
13
);
lpLogFont
->
lfHeight
=
-
GetProfileIntA
(
"Desktop"
,
"IconTitleSize"
,
13
);
lpLogFont
->
lfWidth
=
0
;
lpLogFont
->
lfWidth
=
0
;
...
@@ -1027,7 +1057,7 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
...
@@ -1027,7 +1057,7 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
lpLogFont
->
lfItalic
=
FALSE
;
lpLogFont
->
lfItalic
=
FALSE
;
lpLogFont
->
lfStrikeOut
=
FALSE
;
lpLogFont
->
lfStrikeOut
=
FALSE
;
lpLogFont
->
lfUnderline
=
FALSE
;
lpLogFont
->
lfUnderline
=
FALSE
;
lpLogFont
->
lfCharSet
=
ANSI_CHARSET
;
lpLogFont
->
lfCharSet
=
lfDefault
.
lfCharSet
;
/* at least 'charset' should not be hard-coded */
lpLogFont
->
lfOutPrecision
=
OUT_DEFAULT_PRECIS
;
lpLogFont
->
lfOutPrecision
=
OUT_DEFAULT_PRECIS
;
lpLogFont
->
lfClipPrecision
=
CLIP_DEFAULT_PRECIS
;
lpLogFont
->
lfClipPrecision
=
CLIP_DEFAULT_PRECIS
;
lpLogFont
->
lfPitchAndFamily
=
DEFAULT_PITCH
|
FF_SWISS
;
lpLogFont
->
lfPitchAndFamily
=
DEFAULT_PITCH
|
FF_SWISS
;
...
@@ -1154,7 +1184,7 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
...
@@ -1154,7 +1184,7 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
(
TWEAK_WineLook
>
WIN31_LOOK
)
?
13
:
27
);
(
TWEAK_WineLook
>
WIN31_LOOK
)
?
13
:
27
);
GetProfileStringA
(
"Desktop"
,
"MenuFont"
,
GetProfileStringA
(
"Desktop"
,
"MenuFont"
,
(
TWEAK_WineLook
>
WIN31_LOOK
)
?
"MS Sans Serif"
:
"System"
,
(
TWEAK_WineLook
>
WIN31_LOOK
)
?
lpnm
->
lfCaptionFont
.
lfFaceName
:
"System"
,
lpLogFont
->
lfFaceName
,
LF_FACESIZE
);
lpLogFont
->
lfFaceName
,
LF_FACESIZE
);
lpLogFont
->
lfHeight
=
-
GetProfileIntA
(
"Desktop"
,
"MenuFontSize"
,
13
);
lpLogFont
->
lfHeight
=
-
GetProfileIntA
(
"Desktop"
,
"MenuFontSize"
,
13
);
...
@@ -1164,7 +1194,7 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
...
@@ -1164,7 +1194,7 @@ BOOL WINAPI SystemParametersInfoA( UINT uiAction, UINT uiParam,
lpLogFont
->
lfItalic
=
FALSE
;
lpLogFont
->
lfItalic
=
FALSE
;
lpLogFont
->
lfStrikeOut
=
FALSE
;
lpLogFont
->
lfStrikeOut
=
FALSE
;
lpLogFont
->
lfUnderline
=
FALSE
;
lpLogFont
->
lfUnderline
=
FALSE
;
lpLogFont
->
lfCharSet
=
ANSI_CHARSET
;
lpLogFont
->
lfCharSet
=
lpnm
->
lfCaptionFont
.
lfCharSet
;
lpLogFont
->
lfOutPrecision
=
OUT_DEFAULT_PRECIS
;
lpLogFont
->
lfOutPrecision
=
OUT_DEFAULT_PRECIS
;
lpLogFont
->
lfClipPrecision
=
CLIP_DEFAULT_PRECIS
;
lpLogFont
->
lfClipPrecision
=
CLIP_DEFAULT_PRECIS
;
lpLogFont
->
lfPitchAndFamily
=
DEFAULT_PITCH
|
FF_SWISS
;
lpLogFont
->
lfPitchAndFamily
=
DEFAULT_PITCH
|
FF_SWISS
;
...
...
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