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
5dd63713
Commit
5dd63713
authored
Jun 05, 2009
by
Tony Wasserka
Committed by
Alexandre Julliard
Jun 24, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9: Implement ID3DXFont_GetTextMetrics.
parent
9733856f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
4 deletions
+15
-4
d3dx9_36_private.h
dlls/d3dx9_36/d3dx9_36_private.h
+1
-0
font.c
dlls/d3dx9_36/font.c
+14
-4
No files found.
dlls/d3dx9_36/d3dx9_36_private.h
View file @
5dd63713
...
...
@@ -45,6 +45,7 @@ typedef struct ID3DXFontImpl
D3DXFONT_DESCW
desc
;
HDC
hdc
;
HFONT
hfont
;
}
ID3DXFontImpl
;
...
...
dlls/d3dx9_36/font.c
View file @
5dd63713
...
...
@@ -55,6 +55,7 @@ static ULONG WINAPI ID3DXFontImpl_Release(LPD3DXFONT iface)
TRACE
(
"(%p): ReleaseRef to %d
\n
"
,
This
,
ref
);
if
(
ref
==
0
)
{
DeleteObject
(
This
->
hfont
);
DeleteDC
(
This
->
hdc
);
IDirect3DDevice9_Release
(
This
->
device
);
HeapFree
(
GetProcessHeap
(),
0
,
This
);
...
...
@@ -100,15 +101,15 @@ static HRESULT WINAPI ID3DXFontImpl_GetDescW(LPD3DXFONT iface, D3DXFONT_DESCW *d
static
BOOL
WINAPI
ID3DXFontImpl_GetTextMetricsA
(
LPD3DXFONT
iface
,
TEXTMETRICA
*
metrics
)
{
ID3DXFontImpl
*
This
=
(
ID3DXFontImpl
*
)
iface
;
FIXME
(
"(%p): stub
\n
"
,
This
);
return
FALSE
;
TRACE
(
"(%p)
\n
"
,
This
);
return
GetTextMetricsA
(
This
->
hdc
,
metrics
)
;
}
static
BOOL
WINAPI
ID3DXFontImpl_GetTextMetricsW
(
LPD3DXFONT
iface
,
TEXTMETRICW
*
metrics
)
{
ID3DXFontImpl
*
This
=
(
ID3DXFontImpl
*
)
iface
;
FIXME
(
"(%p): stub
\n
"
,
This
);
return
FALSE
;
TRACE
(
"(%p)
\n
"
,
This
);
return
GetTextMetricsW
(
This
->
hdc
,
metrics
)
;
}
static
HDC
WINAPI
ID3DXFontImpl_GetDC
(
LPD3DXFONT
iface
)
...
...
@@ -307,6 +308,15 @@ HRESULT WINAPI D3DXCreateFontIndirectW(LPDIRECT3DDEVICE9 device, CONST D3DXFONT_
return
D3DXERR_INVALIDDATA
;
}
object
->
hfont
=
CreateFontW
(
desc
->
Height
,
desc
->
Width
,
0
,
0
,
desc
->
Weight
,
desc
->
Italic
,
FALSE
,
FALSE
,
desc
->
CharSet
,
desc
->
OutputPrecision
,
CLIP_DEFAULT_PRECIS
,
desc
->
Quality
,
desc
->
PitchAndFamily
,
desc
->
FaceName
);
if
(
!
object
->
hfont
)
{
DeleteDC
(
object
->
hdc
);
HeapFree
(
GetProcessHeap
(),
0
,
object
);
return
D3DXERR_INVALIDDATA
;
}
SelectObject
(
object
->
hdc
,
object
->
hfont
);
IDirect3DDevice9_AddRef
(
device
);
*
font
=
(
LPD3DXFONT
)
object
;
...
...
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