ReactOS 0.4.15-dev-8245-gd24675b
dialogs.cpp File Reference
#include "precomp.h"
#include "dialogs.h"
#include <winnls.h>
Include dependency graph for dialogs.cpp:

Go to the source code of this file.

Functions

void ShowError (INT stringID,...)
 
static INT CALLBACK EnumFontFamProc (ENUMLOGFONTW *lpelf, NEWTEXTMETRICW *lpntm, INT FontType, LPARAM lParam)
 

Variables

CMirrorRotateDialog mirrorRotateDialog
 
CAttributesDialog attributesDialog
 
CStretchSkewDialog stretchSkewDialog
 
CFontsDialog fontsDialog
 

Function Documentation

◆ EnumFontFamProc()

static INT CALLBACK EnumFontFamProc ( ENUMLOGFONTW lpelf,
NEWTEXTMETRICW lpntm,
INT  FontType,
LPARAM  lParam 
)
static

Definition at line 300 of file dialogs.cpp.

301{
302 CSimpleArray<CStringW>& arrFontNames = *reinterpret_cast<CSimpleArray<CStringW>*>(lParam);
304 if (name[0] == L'@') // Vertical fonts
305 return TRUE;
306
307 for (INT i = 0; i < arrFontNames.GetSize(); ++i)
308 {
309 if (arrFontNames[i] == name) // Already exists
310 return TRUE;
311 }
312
313 arrFontNames.Add(name);
314 return TRUE;
315}
LPARAM lParam
Definition: combotst.c:139
#define TRUE
Definition: types.h:120
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
Definition: glfuncs.h:248
#define L(x)
Definition: ntvdm.h:50
Definition: name.c:39
LOGFONTW elfLogFont
Definition: wingdi.h:2691
WCHAR lfFaceName[LF_FACESIZE]
Definition: wingdi.h:1910
int32_t INT
Definition: typedefs.h:58
WCHAR * LPWSTR
Definition: xmlstorage.h:184

Referenced by CFontsDialog::InitFontNames().

◆ ShowError()

void ShowError ( INT  stringID,
  ... 
)

Definition at line 20 of file dialogs.cpp.

21{
22 va_list va;
23 va_start(va, stringID);
24
25 CStringW strFormat, strText;
26 strFormat.LoadString(stringID);
27 strText.FormatV(strFormat, va);
28
29 CStringW strProgramName;
30 strProgramName.LoadString(IDS_PROGRAMNAME);
31
32 mainWindow.MessageBox(strText, strProgramName, MB_ICONERROR);
33 va_end(va);
34}
char * va_list
Definition: acmsvcex.h:78
#define va_end(ap)
Definition: acmsvcex.h:90
#define va_start(ap, A)
Definition: acmsvcex.h:91
CMainWindow mainWindow
Definition: main.cpp:25
#define IDS_PROGRAMNAME
Definition: resource.h:186
BOOL LoadString(_In_ UINT nID)
Definition: cstringt.h:639
void FormatV(PCXSTR pszFormat, va_list args)
Definition: cstringt.h:846
int MessageBox(LPCTSTR lpszText, LPCTSTR lpszCaption=NULL, UINT nType=MB_OK)
Definition: atlwin.h:1002
#define MB_ICONERROR
Definition: winuser.h:787

Variable Documentation

◆ attributesDialog

CAttributesDialog attributesDialog

Definition at line 14 of file dialogs.cpp.

Referenced by CMainWindow::OnCommand().

◆ fontsDialog

◆ mirrorRotateDialog

CMirrorRotateDialog mirrorRotateDialog

Definition at line 13 of file dialogs.cpp.

Referenced by CMainWindow::OnCommand().

◆ stretchSkewDialog

CStretchSkewDialog stretchSkewDialog

Definition at line 15 of file dialogs.cpp.

Referenced by CMainWindow::OnCommand().