Commit 7757f4ee authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

gdi32: Use __wine_ prefix for Wine ntgdi extensions.

parent f309721d
......@@ -144,7 +144,10 @@ void free_brush_pattern( struct brush_pattern *pattern )
free( pattern->info );
}
BOOL CDECL get_brush_bitmap_info( HBRUSH handle, BITMAPINFO *info, void *bits, UINT *usage )
/**********************************************************************
* __wine_get_brush_bitmap_info (win32u.@)
*/
BOOL CDECL __wine_get_brush_bitmap_info( HBRUSH handle, BITMAPINFO *info, void *bits, UINT *usage )
{
BRUSHOBJ *brush;
BOOL ret = FALSE;
......
......@@ -1333,9 +1333,9 @@ DWORD WINAPI NtGdiSetLayout( HDC hdc, LONG wox, DWORD layout )
}
/**********************************************************************
* get_icm_profile (win32u.@)
* __wine_get_icm_profile (win32u.@)
*/
BOOL CDECL get_icm_profile( HDC hdc, BOOL allow_default, DWORD *size, WCHAR *filename )
BOOL CDECL __wine_get_icm_profile( HDC hdc, BOOL allow_default, DWORD *size, WCHAR *filename )
{
PHYSDEV physdev;
DC *dc;
......
......@@ -270,7 +270,7 @@ static DWORD emfdc_create_brush( struct emf *emf, HBRUSH brush )
DWORD info_size;
UINT usage;
if (!get_brush_bitmap_info( brush, info, NULL, &usage )) break;
if (!__wine_get_brush_bitmap_info( brush, info, NULL, &usage )) break;
info_size = get_dib_info_size( info, usage );
emr = HeapAlloc( GetProcessHeap(), 0,
......@@ -311,7 +311,7 @@ static DWORD emfdc_create_brush( struct emf *emf, HBRUSH brush )
if (info->bmiHeader.biClrUsed == 1 << info->bmiHeader.biBitCount)
info->bmiHeader.biClrUsed = 0;
memcpy( (BYTE *)emr + emr->offBmi, info, emr->cbBmi );
get_brush_bitmap_info( brush, NULL, (char *)emr + emr->offBits, NULL );
__wine_get_brush_bitmap_info( brush, NULL, (char *)emr + emr->offBits, NULL );
if (!emfdc_record( emf, &emr->emr )) index = 0;
HeapFree( GetProcessHeap(), 0, emr );
......
......@@ -5904,7 +5904,10 @@ DWORD WINAPI NtGdiGetGlyphOutline( HDC hdc, UINT ch, UINT format, GLYPHMETRICS *
}
BOOL CDECL get_file_outline_text_metric( const WCHAR *path, OUTLINETEXTMETRICW *otm )
/**********************************************************************
* __wine_get_file_outline_text_metric (win32u.@)
*/
BOOL CDECL __wine_get_file_outline_text_metric( const WCHAR *path, OUTLINETEXTMETRICW *otm )
{
struct gdi_font *font = NULL;
......
......@@ -279,13 +279,6 @@ extern BOOL EMFDC_WidenPath( DC_ATTR *dc_attr ) DECLSPEC_HIDDEN;
extern HENHMETAFILE EMF_Create_HENHMETAFILE( ENHMETAHEADER *emh, DWORD filesize,
BOOL on_disk ) DECLSPEC_HIDDEN;
extern BOOL CDECL get_brush_bitmap_info( HBRUSH handle, BITMAPINFO *info, void *bits,
UINT *usage ) DECLSPEC_HIDDEN;
extern BOOL CDECL get_icm_profile( HDC hdc, BOOL allow_default, DWORD *size,
WCHAR *filename ) DECLSPEC_HIDDEN;
extern BOOL CDECL get_file_outline_text_metric( const WCHAR *path,
OUTLINETEXTMETRICW *otm ) DECLSPEC_HIDDEN;
static inline int get_dib_stride( int width, int bpp )
{
return ((width * bpp + 31) >> 3) & ~3;
......
......@@ -1241,9 +1241,9 @@ static struct unix_funcs unix_funcs =
SetDCHook,
SetDIBits,
SetHookFlags,
get_brush_bitmap_info,
get_file_outline_text_metric,
get_icm_profile,
__wine_get_brush_bitmap_info,
__wine_get_file_outline_text_metric,
__wine_get_icm_profile,
__wine_get_vulkan_driver,
__wine_get_wgl_driver,
__wine_make_gdi_object_system,
......
......@@ -74,7 +74,7 @@ INT WINAPI EnumICMProfilesW(HDC hdc, ICMENUMPROCW func, LPARAM lparam)
TRACE( "%p, %p, 0x%08lx\n", hdc, func, lparam );
if (!func) return -1;
if (!get_icm_profile( hdc, FALSE, &size, profile )) return -1;
if (!__wine_get_icm_profile( hdc, FALSE, &size, profile )) return -1;
/* FIXME: support multiple profiles */
return func( profile, lparam );
}
......@@ -131,7 +131,7 @@ BOOL WINAPI GetICMProfileW(HDC hdc, LPDWORD size, LPWSTR filename)
{
TRACE("%p, %p, %p\n", hdc, size, filename);
return get_icm_profile( hdc, TRUE, size, filename );
return __wine_get_icm_profile( hdc, TRUE, size, filename );
}
/**********************************************************************
......
......@@ -547,7 +547,7 @@ static INT16 metadc_create_brush( struct metadc *metadc, HBRUSH brush )
DWORD info_size;
UINT usage;
if (!get_brush_bitmap_info( brush, src_info, NULL, &usage )) goto done;
if (!__wine_get_brush_bitmap_info( brush, src_info, NULL, &usage )) goto done;
info_size = get_dib_info_size( src_info, usage );
size = FIELD_OFFSET( METARECORD, rdParm[2] ) +
......@@ -559,7 +559,7 @@ static INT16 metadc_create_brush( struct metadc *metadc, HBRUSH brush )
mr->rdParm[0] = logbrush.lbStyle;
mr->rdParm[1] = usage;
dst_info = (BITMAPINFO *)(mr->rdParm + 2);
get_brush_bitmap_info( brush, dst_info, (char *)dst_info + info_size, NULL );
__wine_get_brush_bitmap_info( brush, dst_info, (char *)dst_info + info_size, NULL );
if (dst_info->bmiHeader.biClrUsed == 1 << dst_info->bmiHeader.biBitCount)
dst_info->bmiHeader.biClrUsed = 0;
break;
......
......@@ -2682,7 +2682,7 @@ BOOL WINAPI CreateScalableFontResourceW( DWORD hidden, const WCHAR *resource_fil
if (!RtlDosPathNameToNtPathName_U( path, &nt_name, NULL, NULL )) goto done;
}
else if (!RtlDosPathNameToNtPathName_U( font_file, &nt_name, NULL, NULL )) goto done;
ret = get_file_outline_text_metric( nt_name.Buffer, &otm );
ret = __wine_get_file_outline_text_metric( nt_name.Buffer, &otm );
RtlFreeUnicodeString( &nt_name );
if (!ret) goto done;
if (!(otm.otmTextMetrics.tmPitchAndFamily & TMPF_TRUETYPE)) goto done;
......
......@@ -296,12 +296,6 @@ struct unix_funcs
UINT WINAPI GDIRealizePalette( HDC hdc );
HPALETTE WINAPI GDISelectPalette( HDC hdc, HPALETTE hpal, WORD wBkg );
extern BOOL CDECL get_brush_bitmap_info( HBRUSH handle, BITMAPINFO *info, void *bits,
UINT *usage ) DECLSPEC_HIDDEN;
extern BOOL CDECL get_icm_profile( HDC hdc, BOOL allow_default, DWORD *size,
WCHAR *filename ) DECLSPEC_HIDDEN;
extern BOOL CDECL get_file_outline_text_metric( const WCHAR *path, OUTLINETEXTMETRICW *otm );
BOOL wrappers_init(void) DECLSPEC_HIDDEN;
......
......@@ -980,7 +980,7 @@ WORD WINAPI SetHookFlags( HDC hdc, WORD flags )
return unix_funcs->pSetHookFlags( hdc, flags );
}
BOOL CDECL get_icm_profile( HDC hdc, BOOL allow_default, DWORD *size, WCHAR *filename )
BOOL CDECL __wine_get_icm_profile( HDC hdc, BOOL allow_default, DWORD *size, WCHAR *filename )
{
return unix_funcs->get_icm_profile( hdc, allow_default, size, filename );
}
......@@ -996,12 +996,12 @@ void CDECL __wine_set_visible_region( HDC hdc, HRGN hrgn, const RECT *vis_rect,
return unix_funcs->set_visible_region( hdc, hrgn, vis_rect, device_rect, surface );
}
BOOL CDECL get_brush_bitmap_info( HBRUSH handle, BITMAPINFO *info, void *bits, UINT *usage )
BOOL CDECL __wine_get_brush_bitmap_info( HBRUSH handle, BITMAPINFO *info, void *bits, UINT *usage )
{
return unix_funcs->get_brush_bitmap_info( handle, info, bits, usage );
}
BOOL CDECL get_file_outline_text_metric( const WCHAR *path, OUTLINETEXTMETRICW *otm )
BOOL CDECL __wine_get_file_outline_text_metric( const WCHAR *path, OUTLINETEXTMETRICW *otm )
{
return unix_funcs->get_file_outline_text_metric( path, otm );
}
......
......@@ -448,4 +448,12 @@ NTSTATUS WINAPI NtGdiDdDDIQueryStatistics( D3DKMT_QUERYSTATISTICS *stats );
NTSTATUS WINAPI NtGdiDdDDISetQueuedLimit( D3DKMT_SETQUEUEDLIMIT *desc );
NTSTATUS WINAPI NtGdiDdDDISetVidPnSourceOwner( const D3DKMT_SETVIDPNSOURCEOWNER *desc );
/* Wine extensions */
extern BOOL CDECL __wine_get_brush_bitmap_info( HBRUSH handle, BITMAPINFO *info, void *bits,
UINT *usage );
extern BOOL CDECL __wine_get_icm_profile( HDC hdc, BOOL allow_default, DWORD *size,
WCHAR *filename );
extern BOOL CDECL __wine_get_file_outline_text_metric( const WCHAR *path,
OUTLINETEXTMETRICW *otm );
#endif /* _NTGDI_ */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment