181 else if (
argv[
i][0] ==
'/' ||
argv[
i][0] ==
'-')
294 return (
int)
msg.wParam;
305 HWND hDisplay, hButtonInstall, hButtonPrint, hButtonPrev, hButtonNext;
418 HWND hInstall, hPrint, hPrev, hNext, hDisplay;
471 WCHAR szFullName[64];
493 wcscat(szDestPath,
L"\\Fonts\\");
512 L"SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts",
const WCHAR g_szFontDisplayClassName[]
LRESULT Display_OnPrint(HWND hwnd)
BOOL Display_InitClass(HINSTANCE hInstance)
#define IDS_ERROR_OPENKEY
#define IDS_ERROR_FONTCPY
#define IDS_ERROR_REGISTER
#define IDS_ERROR_NOCLASS
#define IDS_ERROR_ISINSTALLED
#define RegCloseKey(hKey)
#define OFN_FILEMUSTEXIST
static TAGREF LPCWSTR LPDWORD LPVOID lpBuffer
LONG WINAPI RegOpenKeyExW(HKEY hKey, LPCWSTR lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
LONG WINAPI RegSetValueExW(_In_ HKEY hKey, _In_ LPCWSTR lpValueName, _In_ DWORD Reserved, _In_ DWORD dwType, _In_ CONST BYTE *lpData, _In_ DWORD cbData)
BOOL WINAPI GetOpenFileNameW(OPENFILENAMEW *ofn)
BOOL WINAPI CopyFileW(IN LPCWSTR lpExistingFileName, IN LPCWSTR lpNewFileName, IN BOOL bFailIfExists)
DWORD WINAPI GetFileAttributesW(LPCWSTR lpFileName)
DWORD WINAPI GetFullPathNameW(IN LPCWSTR lpFileName, IN DWORD nBufferLength, OUT LPWSTR lpBuffer, OUT LPWSTR *lpFilePart)
UINT WINAPI GetWindowsDirectoryW(OUT LPWSTR lpBuffer, IN UINT uSize)
LPWSTR WINAPI GetCommandLineW(VOID)
LANGID WINAPI GetUserDefaultUILanguage(void)
static LRESULT MainWnd_OnNext(HWND hwnd)
static void FormatMsgBox(_In_ HWND hParent, _In_ DWORD dwMessageId, _In_ DWORD dwCaptionId, _In_ UINT uType, _In_ va_list args)
static LRESULT MainWnd_OnInstall(HWND hwnd)
static void ErrorMsgBox(HWND hParent, DWORD dwMessageId,...)
int WINAPI wWinMain(HINSTANCE hThisInstance, HINSTANCE hPrevInstance, LPWSTR lpCmdLine, int nCmdShow)
BOOL WINAPI GetFontResourceInfoW(LPCWSTR lpFileName, DWORD *pdwBufSize, void *lpBuffer, DWORD dwType)
static LRESULT MainWnd_OnPaint(HWND hwnd)
static LRESULT MainWnd_OnCreate(HWND hwnd)
static LRESULT MainWnd_OnPrev(HWND hwnd)
LRESULT CALLBACK MainWndProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
static void SuccessMsgBox(HWND hParent, DWORD dwMessageId,...)
DWORD FormatString(DWORD dwFlags, HINSTANCE hInstance, DWORD dwStringId, DWORD dwLanguageId, LPWSTR lpBuffer, DWORD nSize, va_list *Arguments)
static LRESULT MainWnd_OnSize(HWND hwnd)
static const WCHAR g_szFontViewClassName[]
GLint GLint GLint GLint GLint GLint GLint GLbitfield GLenum filter
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
HLOCAL NTAPI LocalFree(HLOCAL hMem)
_CRTIMP size_t __cdecl wcslen(_In_z_ const wchar_t *_Str)
PSDBQUERYRESULT_VISTA PVOID DWORD * dwSize
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
#define WS_OVERLAPPEDWINDOW
LPWSTR *WINAPI CommandLineToArgvW(LPCWSTR lpCmdline, int *numargs)
TW_UINT32 TW_UINT16 TW_UINT16 MSG
WORD WORD PSZ PSZ pszFileName
#define INVALID_FILE_ATTRIBUTES
BOOL WINAPI SetProcessDefaultLayout(DWORD dwDefaultLayout)
#define FORMAT_MESSAGE_FROM_STRING
#define GetFileAttributes
#define FORMAT_MESSAGE_FROM_SYSTEM
#define FORMAT_MESSAGE_ALLOCATE_BUFFER
#define FORMAT_MESSAGE_FROM_HMODULE
*nSize LPSTR _Inout_ LPDWORD nSize
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
HGDIOBJ WINAPI GetStockObject(_In_ int)
int WINAPI AddFontResourceW(_In_ LPCWSTR pszFilename)
BOOL WINAPI RemoveFontResourceW(_In_ LPCWSTR)
int WINAPI FillRect(HDC, LPCRECT, HBRUSH)
#define HKEY_LOCAL_MACHINE
BOOL WINAPI TranslateMessage(_In_ const MSG *)
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
LRESULT WINAPI DefWindowProcW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
__analysis_noreturn void WINAPI PostQuitMessage(_In_ int)
BOOL WINAPI EndDeferWindowPos(_In_ HDWP)
int WINAPI MessageBoxW(_In_opt_ HWND hWnd, _In_opt_ LPCWSTR lpText, _In_opt_ LPCWSTR lpCaption, _In_ UINT uType)
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
BOOL WINAPI GetClientRect(_In_ HWND, _Out_ LPRECT)
HWND WINAPI CreateWindowExW(_In_ DWORD dwExStyle, _In_opt_ LPCWSTR lpClassName, _In_opt_ LPCWSTR lpWindowName, _In_ DWORD dwStyle, _In_ int X, _In_ int Y, _In_ int nWidth, _In_ int nHeight, _In_opt_ HWND hWndParent, _In_opt_ HMENU hMenu, _In_opt_ HINSTANCE hInstance, _In_opt_ LPVOID lpParam)
BOOL WINAPI EndPaint(_In_ HWND, _In_ const PAINTSTRUCT *)
ATOM WINAPI RegisterClassExW(_In_ CONST WNDCLASSEXW *)
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
#define MB_ICONINFORMATION
struct _WNDCLASSEXW WNDCLASSEXW
HDWP WINAPI DeferWindowPos(_In_ HDWP, _In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
BOOL WINAPI InvalidateRect(_In_opt_ HWND, _In_opt_ LPCRECT, _In_ BOOL)
HDC WINAPI BeginPaint(_In_ HWND, _Out_ LPPAINTSTRUCT)
#define SendDlgItemMessage
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
HDWP WINAPI BeginDeferWindowPos(_In_ int)