ReactOS  0.4.15-dev-5496-g599ba9c
dialogs.cpp
Go to the documentation of this file.
1 /*
2  * PROJECT: PAINT for ReactOS
3  * LICENSE: LGPL
4  * FILE: base/applications/mspaint/dialogs.cpp
5  * PURPOSE: Window procedures of the dialog windows plus launching functions
6  * PROGRAMMERS: Benedikt Freisen
7  */
8 
9 /* INCLUDES *********************************************************/
10 
11 #include "precomp.h"
12 
13 #include "dialogs.h"
14 
15 #include <winnls.h>
16 
17 /* GLOBALS **********************************************************/
18 
23 
24 /* FUNCTIONS ********************************************************/
25 
27 {
30  return 0;
31 }
32 
34 {
35  EndDialog(0);
36  return 0;
37 }
38 
39 LRESULT CMirrorRotateDialog::OnOk(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
40 {
42  EndDialog(1);
44  EndDialog(2);
46  EndDialog(3);
48  EndDialog(4);
50  EndDialog(5);
51  return 0;
52 }
53 
54 LRESULT CMirrorRotateDialog::OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
55 {
56  EndDialog(0);
57  return 0;
58 }
59 
60 LRESULT CMirrorRotateDialog::OnRadioButton3(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
61 {
65  return 0;
66 }
67 
68 LRESULT CMirrorRotateDialog::OnRadioButton12(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
69 {
73  return 0;
74 }
75 
76 
77 
79 {
82 
87 
88  if (isAFile)
89  {
90  TCHAR date[100];
91  TCHAR temp[100];
94  _tcscat(date, _T(" "));
95  _tcscat(date, temp);
96  CString strSize;
97  strSize.Format(IDS_FILESIZE, fileSize);
100  }
101  CString strRes;
104  return 0;
105 }
106 
108 {
109  EndDialog(0);
110  return 0;
111 }
112 
113 LRESULT CAttributesDialog::OnOk(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
114 {
115  EndDialog(1);
116  return 0;
117 }
118 
119 LRESULT CAttributesDialog::OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
120 {
121  EndDialog(0);
122  return 0;
123 }
124 
125 LRESULT CAttributesDialog::OnDefault(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
126 {
133  return 0;
134 }
135 
136 LRESULT CAttributesDialog::OnRadioButton1(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
137 {
138  CString strNum;
139  strNum.Format(_T("%.3lf"), newWidth / (0.0254 * fileHPPM));
141  strNum.Format(_T("%.3lf"), newHeight / (0.0254 * fileVPPM));
143  return 0;
144 }
145 
146 LRESULT CAttributesDialog::OnRadioButton2(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
147 {
148  CString strNum;
149  strNum.Format(_T("%.3lf"), newWidth * 100.0 / fileHPPM);
151  strNum.Format(_T("%.3lf"), newHeight * 100.0 / fileVPPM);
153  return 0;
154 }
155 
156 LRESULT CAttributesDialog::OnRadioButton3(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
157 {
160  return 0;
161 }
162 
163 LRESULT CAttributesDialog::OnEdit1(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
164 {
165  if (Edit_GetModify(hWndCtl))
166  {
167  TCHAR tempS[100];
169  {
171  newWidth = max(1, (int) (_tcstod(tempS, NULL) * fileHPPM * 0.0254));
172  }
174  {
176  newWidth = max(1, (int) (_tcstod(tempS, NULL) * fileHPPM / 100));
177  }
179  {
181  newWidth = max(1, _tstoi(tempS));
182  }
183  Edit_SetModify(hWndCtl, FALSE);
184  }
185  return 0;
186 }
187 
188 LRESULT CAttributesDialog::OnEdit2(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
189 {
190  if (Edit_GetModify(hWndCtl))
191  {
192  TCHAR tempS[100];
194  {
196  newHeight = max(1, (int) (_tcstod(tempS, NULL) * fileVPPM * 0.0254));
197  }
199  {
201  newHeight = max(1, (int) (_tcstod(tempS, NULL) * fileVPPM / 100));
202  }
204  {
206  newHeight = max(1, _tstoi(tempS));
207  }
208  Edit_SetModify(hWndCtl, FALSE);
209  }
210  return 0;
211 }
212 
213 
214 
216 {
221  return 0;
222 }
223 
225 {
226  EndDialog(0);
227  return 0;
228 }
229 
230 LRESULT CStretchSkewDialog::OnOk(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
231 {
232  CString strrcIntNumbers;
233  CString strrcPercentage;
234  CString strrcAngle;
235  BOOL tr1, tr2, tr3, tr4;
236 
237  strrcIntNumbers.LoadString(hProgInstance, IDS_INTNUMBERS);
238  strrcPercentage.LoadString(hProgInstance, IDS_PERCENTAGE);
239  strrcAngle.LoadString(hProgInstance, IDS_ANGLE);
240 
245 
246  if (!(tr1 && tr2 && tr3 && tr4))
247  MessageBox(strrcIntNumbers, NULL, MB_ICONEXCLAMATION);
248  else if (percentage.x < 1 || percentage.x > 500 || percentage.y < 1 || percentage.y > 500)
249  MessageBox(strrcPercentage, NULL, MB_ICONEXCLAMATION);
250  else if (angle.x < -89 || angle.x > 89 || angle.y < -89 || angle.y > 89)
251  MessageBox(strrcAngle, NULL, MB_ICONEXCLAMATION);
252  else
253  EndDialog(1);
254  return 0;
255 }
256 
257 LRESULT CStretchSkewDialog::OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
258 {
259  EndDialog(0);
260  return 0;
261 }
262 
263 static INT CALLBACK
265 {
266  CSimpleArray<CString>& arrFontNames = *reinterpret_cast<CSimpleArray<CString>*>(lParam);
267  LPTSTR name = lpelf->elfLogFont.lfFaceName;
268  if (name[0] == TEXT('@')) // Vertical fonts
269  return TRUE;
270 
271  for (INT i = 0; i < arrFontNames.GetSize(); ++i)
272  {
273  if (arrFontNames[i] == name) // Already exists
274  return TRUE;
275  }
276 
277  arrFontNames.Add(name);
278  return TRUE;
279 }
280 
281 // TODO: AutoComplete font names
282 // TODO: Vertical text
284 {
285 }
286 
288 {
289  // List the fonts
290  CSimpleArray<CString> arrFontNames;
292  if (hDC)
293  {
295  reinterpret_cast<LPARAM>(&arrFontNames));
296  DeleteDC(hDC);
297  }
298 
299  // Actually add them to the combobox
300  HWND hwndNames = GetDlgItem(IDD_FONTSNAMES);
301  SendMessage(hwndNames, CB_RESETCONTENT, 0, 0);
302  for (INT i = 0; i < arrFontNames.GetSize(); ++i)
303  {
304  ComboBox_AddString(hwndNames, arrFontNames[i]);
305  }
306 
308 }
309 
311 {
312  static const INT s_sizes[] =
313  {
314  8, 9, 10, 11, 12, 14, 16, 18, 20, 22, 24, 26, 28, 36, 48, 72
315  };
316 
317  HWND hwndSizes = GetDlgItem(IDD_FONTSSIZES);
318  ComboBox_ResetContent(hwndSizes);
319 
320  TCHAR szText[16];
321  for (UINT i = 0; i < _countof(s_sizes); ++i)
322  {
323  wsprintf(szText, TEXT("%d"), s_sizes[i]);
324  INT iItem = ComboBox_AddString(hwndSizes, szText);
325  if (s_sizes[i] == (INT)registrySettings.PointSize)
326  ComboBox_SetCurSel(hwndSizes, iItem);
327  }
328 
329  if (ComboBox_GetCurSel(hwndSizes) == CB_ERR)
330  {
331  wsprintf(szText, TEXT("%d"), (INT)registrySettings.PointSize);
332  ::SetWindowText(hwndSizes, szText);
333  }
334 }
335 
337 {
338  HWND hwndToolbar = GetDlgItem(IDD_FONTSTOOLBAR);
339  SendMessage(hwndToolbar, TB_BUTTONSTRUCTSIZE, sizeof(TBBUTTON), 0);
340  SendMessage(hwndToolbar, TB_SETBITMAPSIZE, 0, MAKELPARAM(16, 16));
341  SendMessage(hwndToolbar, TB_SETBUTTONWIDTH, 0, MAKELPARAM(20, 20));
342 
344  AddBitmap.hInst = hProgInstance;
346  SendMessage(hwndToolbar, TB_ADDBITMAP, 4, (LPARAM)&AddBitmap);
347 
349  16, 8, RGB(255, 0, 255), IMAGE_BITMAP,
351  SendMessage(hwndToolbar, TB_SETIMAGELIST, 0, (LPARAM)himl);
352 
353  TBBUTTON buttons[] =
354  {
358  { 3, IDM_VERTICAL, 0, TBSTYLE_CHECK }, // TODO:
359  };
361 
365 }
366 
368 {
369  // TODO: Tooltips
370  InitFontNames();
371  InitFontSizes();
372  InitToolbar();
373 
375  {
378  0, 0,
380  SendMessage(DM_REPOSITION, 0, 0);
381  }
382 
385 
386  return TRUE;
387 }
388 
390 {
391  ShowWindow(SW_HIDE); // Just hide. Recycle for optimization
392  return 0;
393 }
394 
396 {
397  HWND hwndNames = GetDlgItem(IDD_FONTSNAMES);
398  INT iItem = CB_ERR;
399  UINT cch;
400  TCHAR szText[LF_FACESIZE];
401 
402  switch (codeNotify)
403  {
404  case CBN_SELCHANGE:
405  iItem = ComboBox_GetCurSel(hwndNames);
406  cch = ComboBox_GetLBTextLen(hwndNames, iItem);
407  if (iItem != CB_ERR && 0 < cch && cch < _countof(szText))
408  {
409  ComboBox_GetLBText(hwndNames, iItem, szText);
410  }
411  break;
412 
413  case CBN_EDITCHANGE:
414  GetDlgItemText(IDD_FONTSNAMES, szText, _countof(szText));
415  iItem = ComboBox_FindStringExact(hwndNames, -1, szText);
416  break;
417  }
418 
419  if (iItem != CB_ERR && registrySettings.strFontName.CompareNoCase(szText) != 0)
420  {
421  registrySettings.strFontName = szText;
423  }
424 }
425 
427 {
428  HWND hwndSizes = GetDlgItem(IDD_FONTSSIZES);
429  WCHAR szText[8];
430  INT iItem, PointSize = 0;
431  UINT cch;
432 
433  switch (codeNotify)
434  {
435  case CBN_SELCHANGE:
436  iItem = ComboBox_GetCurSel(hwndSizes);
437  cch = ComboBox_GetLBTextLen(hwndSizes, iItem);
438  if (iItem != CB_ERR && 0 < cch && cch < _countof(szText))
439  {
440  ComboBox_GetLBText(hwndSizes, iItem, szText);
441  PointSize = _ttoi(szText);
442  }
443  break;
444 
445  case CBN_EDITCHANGE:
446  ::GetWindowText(hwndSizes, szText, _countof(szText));
447  PointSize = _ttoi(szText);
448  break;
449  }
450 
451  if (PointSize > 0)
452  {
453  registrySettings.PointSize = PointSize;
455  }
456 }
457 
459 {
460  UINT id = LOWORD(wParam);
461  UINT codeNotify = HIWORD(wParam);
462  HWND hwndToolbar = GetDlgItem(IDD_FONTSTOOLBAR);
463  BOOL bChecked = ::SendMessage(hwndToolbar, TB_ISBUTTONCHECKED, id, 0);
464 
465  switch (id)
466  {
467  case IDCANCEL:
470  break;
471 
472  case IDD_FONTSNAMES:
473  OnFontName(codeNotify);
474  break;
475 
476  case IDD_FONTSSIZES:
477  OnFontSize(codeNotify);
478  break;
479 
480  case IDM_BOLD:
481  registrySettings.Bold = bChecked;
483  break;
484 
485  case IDM_ITALIC:
486  registrySettings.Italic = bChecked;
488  break;
489 
490  case IDM_UNDERLINE:
491  registrySettings.Underline = bChecked;
493  break;
494 
495  case IDM_VERTICAL:
496  // TODO:
497  break;
498  }
499  return 0;
500 }
501 
503 {
504  NMHDR *pnmhdr = reinterpret_cast<NMHDR *>(lParam);
505  if (pnmhdr->code == TTN_NEEDTEXT)
506  {
507  LPTOOLTIPTEXT pToolTip = reinterpret_cast<LPTOOLTIPTEXT>(lParam);
508  pToolTip->hinst = hProgInstance;
509  switch (pnmhdr->idFrom)
510  {
511  case IDM_BOLD: pToolTip->lpszText = MAKEINTRESOURCE(IDS_BOLD); break;
512  case IDM_ITALIC: pToolTip->lpszText = MAKEINTRESOURCE(IDS_ITALIC); break;
513  case IDM_UNDERLINE: pToolTip->lpszText = MAKEINTRESOURCE(IDS_UNDERLINE); break;
514  case IDM_VERTICAL: pToolTip->lpszText = MAKEINTRESOURCE(IDS_VERTICAL); break;
515 
516  default:
517  break;
518  }
519  }
520  return 0;
521 }
522 
524 {
525  RECT rc;
526  GetWindowRect(&rc);
529  return 0;
530 }
531 
533 {
534  if (wParam != TOOL_TEXT)
536 
537  return 0;
538 }
539 
541 {
542  if (wParam == IDD_FONTSNAMES)
543  {
544  LPMEASUREITEMSTRUCT pMeasureItem = reinterpret_cast<LPMEASUREITEMSTRUCT>(lParam);
545  RECT rc;
547  pMeasureItem->itemWidth = rc.right - rc.left;
548  pMeasureItem->itemHeight = GetSystemMetrics(SM_CYVSCROLL);
549  return TRUE;
550  }
551  return 0;
552 }
553 
555 {
556  // TODO: Owner-draw the font types
557  if (wParam == IDD_FONTSNAMES)
558  {
559  LPDRAWITEMSTRUCT pDrawItem = reinterpret_cast<LPDRAWITEMSTRUCT>(lParam);
560  if (pDrawItem->itemID == (UINT)-1)
561  return TRUE;
562 
563  SetBkMode(pDrawItem->hDC, TRANSPARENT);
564 
565  HWND hwndItem = pDrawItem->hwndItem;
566  RECT rcItem = pDrawItem->rcItem;
567  if (pDrawItem->itemState & ODS_SELECTED)
568  {
569  FillRect(pDrawItem->hDC, &rcItem, GetSysColorBrush(COLOR_HIGHLIGHT));
571  }
572  else
573  {
574  FillRect(pDrawItem->hDC, &rcItem, GetSysColorBrush(COLOR_WINDOW));
576  }
577 
578  TCHAR szText[LF_FACESIZE];
579  if ((UINT)ComboBox_GetLBTextLen(hwndItem, pDrawItem->itemID) < _countof(szText))
580  {
581  szText[0] = 0;
582  ComboBox_GetLBText(hwndItem, pDrawItem->itemID, szText);
583 
584  rcItem.left += 24;
585  DrawText(pDrawItem->hDC, szText, -1, &rcItem, DT_LEFT | DT_VCENTER | DT_SINGLELINE);
586  }
587 
588  if (pDrawItem->itemState & ODS_FOCUS)
589  ::DrawFocusRect(pDrawItem->hDC, &pDrawItem->rcItem);
590 
591  return TRUE;
592  }
593  return 0;
594 }
BOOL isAFile
Definition: main.cpp:53
LRESULT OnClose(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:389
#define MAKEINTRESOURCE
Definition: winuser.h:591
BOOL WINAPI CheckDlgButton(_In_ HWND, _In_ int, _In_ UINT)
ToolsModel toolsModel
Definition: main.cpp:18
#define max(a, b)
Definition: svc.c:63
#define TB_BUTTONSTRUCTSIZE
Definition: commctrl.h:1134
#define Edit_GetModify(hwndCtl)
Definition: windowsx.h:90
#define COLOR_HIGHLIGHT
Definition: winuser.h:920
#define LF_FACESIZE
Definition: dimm.idl:39
#define ComboBox_AddString(hwndCtl, lpsz)
Definition: windowsx.h:41
int fileSize
Definition: main.cpp:55
#define _tstoi
Definition: tchar.h:598
long y
Definition: polytest.cpp:48
LRESULT OnClose(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:33
LRESULT OnInitDialog(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:367
#define ComboBox_GetLBText(hwndCtl, index, lpszBuffer)
Definition: windowsx.h:56
#define RGB(r, g, b)
Definition: precomp.h:62
long x
Definition: polytest.cpp:48
LRESULT OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:119
#define TRUE
Definition: types.h:120
#define SW_HIDE
Definition: winuser.h:762
#define LOCALE_USER_DEFAULT
LRESULT OnInitDialog(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:26
#define IDS_FILESIZE
Definition: resource.h:207
#define MAKELPARAM(l, h)
Definition: winuser.h:3998
BOOL WINAPI DrawFocusRect(_In_ HDC, _In_ LPCRECT)
int CompareNoCase(_In_z_ PCXSTR psz) const
Definition: cstringt.h:695
static HDC
Definition: imagelist.c:92
#define SM_CYVSCROLL
Definition: winuser.h:975
#define CALLBACK
Definition: compat.h:35
LONG top
Definition: windef.h:307
#define ODS_FOCUS
Definition: winuser.h:2539
void __cdecl Format(UINT nFormatID,...)
Definition: cstringt.h:753
#define ComboBox_GetCurSel(hwndCtl)
Definition: windowsx.h:49
LRESULT OnInitDialog(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:215
HDC WINAPI CreateCompatibleDC(_In_opt_ HDC hdc)
UINT_PTR WPARAM
Definition: windef.h:207
CString strFontName
Definition: registry.h:35
GLfloat angle
Definition: glext.h:10853
#define IDD_ATTRIBUTESTEXT7
Definition: resource.h:143
LONG left
Definition: windef.h:306
#define SWP_NOZORDER
Definition: winuser.h:1237
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
#define IDD_FONTSNAMES
Definition: resource.h:175
#define ImageList_LoadImage
Definition: commctrl.h:508
LONG right
Definition: windef.h:308
HIMAGELIST himl
#define COLOR_WINDOW
Definition: winuser.h:912
int32_t INT
Definition: typedefs.h:58
DWORD WINAPI GetSysColor(_In_ int)
BOOL WINAPI EndDialog(_In_ HWND, _In_ INT_PTR)
WPARAM wParam
Definition: combotst.c:138
CHAR * LPTSTR
Definition: xmlstorage.h:192
static INT CALLBACK EnumFontFamProc(ENUMLOGFONT *lpelf, NEWTEXTMETRIC *lpntm, INT FontType, LPARAM lParam)
Definition: dialogs.cpp:264
#define DrawText
Definition: winuser.h:5761
#define GetWindowText
Definition: winuser.h:5788
#define MB_ICONEXCLAMATION
Definition: winuser.h:779
UINT code
Definition: winuser.h:3149
#define IDD_ATTRIBUTESTEXT8
Definition: resource.h:144
int WINAPI SetBkMode(_In_ HDC, _In_ int)
Definition: dc.c:1056
SYSTEMTIME fileTime
Definition: main.cpp:58
#define ComboBox_FindStringExact(hwndCtl, indexStart, lpszFind)
Definition: windowsx.h:47
CMirrorRotateDialog mirrorRotateDialog
Definition: dialogs.cpp:19
void InitFontNames()
Definition: dialogs.cpp:287
#define IDD_MIRRORROTATERB4
Definition: resource.h:130
#define FALSE
Definition: types.h:117
#define DT_LEFT
Definition: winuser.h:534
LRESULT OnNotify(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:502
unsigned int BOOL
Definition: ntddk_ex.h:94
UINT_PTR idFrom
Definition: winuser.h:3148
#define IDS_PRINTRES
Definition: resource.h:208
LRESULT OnInitDialog(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:78
#define TRANSPARENT
Definition: wingdi.h:950
#define IDS_UNDERLINE
Definition: resource.h:219
LRESULT OnRadioButton3(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:156
#define IDM_UNDERLINE
Definition: resource.h:102
UINT WINAPI GetDlgItemInt(_In_ HWND, _In_ int, _Out_opt_ PBOOL, _In_ BOOL)
int fileHPPM
Definition: main.cpp:56
LONG_PTR LPARAM
Definition: windef.h:208
#define TTN_NEEDTEXT
Definition: commctrl.h:1880
CStretchSkewDialog stretchSkewDialog
Definition: dialogs.cpp:21
#define IDD_ATTRIBUTESRB5
Definition: resource.h:152
LRESULT OnRadioButton2(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:146
#define DT_VCENTER
Definition: winuser.h:543
#define COLOR_HIGHLIGHTTEXT
Definition: winuser.h:921
#define CB_RESETCONTENT
Definition: winuser.h:1949
UINT WINAPI IsDlgButtonChecked(_In_ HWND, _In_ int)
#define CB_ERR
Definition: winuser.h:2425
DWORD ShowTextTool
Definition: registry.h:43
int GetWidth() const
Definition: history.cpp:215
DWORD FontsPositionY
Definition: registry.h:42
#define TB_SETIMAGELIST
Definition: commctrl.h:1150
#define LPTOOLTIPTEXT
Definition: commctrl.h:1890
LRESULT OnToolsModelToolChanged(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:532
#define IDM_BOLD
Definition: resource.h:100
char TCHAR
Definition: xmlstorage.h:189
#define IDS_INTNUMBERS
Definition: resource.h:210
#define _T(x)
Definition: vfdio.h:22
#define IDD_ATTRIBUTESEDIT1
Definition: resource.h:135
NTSTATUS AddBitmap(PNTFS_VCB Vcb, PFILE_RECORD_HEADER FileRecord, PNTFS_ATTR_RECORD AttributeAddress, PCWSTR Name, USHORT NameLength)
Definition: attrib.c:72
#define GetDlgItemText
Definition: winuser.h:5775
#define CBN_EDITCHANGE
Definition: winuser.h:1965
#define _tcstod
Definition: xmlstorage.h:197
LRESULT OnCommand(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:458
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define IDD_ATTRIBUTESRB3
Definition: resource.h:150
#define IDS_VERTICAL
Definition: resource.h:220
#define SWP_NOACTIVATE
Definition: winuser.h:1232
#define COLOR_WINDOWTEXT
Definition: winuser.h:915
#define _countof(array)
Definition: sndvol32.h:68
LRESULT OnRadioButton3(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:60
void NotifyToolChanged()
Definition: toolsmodel.cpp:159
unsigned short WORD
Definition: ntddk_ex.h:93
int WINAPI GetSystemMetrics(_In_ int)
DWORD PointSize
Definition: registry.h:36
#define IDD_MIRRORROTATERB5
Definition: resource.h:131
#define IDS_PERCENTAGE
Definition: resource.h:211
void OnFontSize(UINT codeNotify)
Definition: dialogs.cpp:426
#define IDD_MIRRORROTATERB1
Definition: resource.h:127
#define SetDlgItemText
Definition: winuser.h:5839
#define TB_ADDBITMAP
Definition: commctrl.h:1056
#define DM_REPOSITION
Definition: winuser.h:2090
LRESULT OnMove(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:523
#define IDS_ITALIC
Definition: resource.h:218
CAttributesDialog attributesDialog
Definition: dialogs.cpp:20
BOOL WINAPI SetDlgItemInt(_In_ HWND, _In_ int, _In_ UINT, _In_ BOOL)
DWORD FontsPositionX
Definition: registry.h:41
DWORD Underline
Definition: registry.h:39
#define EnumFontFamilies
Definition: wingdi.h:4450
#define IDM_VERTICAL
Definition: resource.h:103
LRESULT OnClose(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:107
#define TB_ADDBUTTONS
Definition: commctrl.h:1271
#define IDD_STRETCHSKEWEDITHSTRETCH
Definition: resource.h:158
#define TB_CHECKBUTTON
Definition: commctrl.h:1043
#define TB_SETBITMAPSIZE
Definition: commctrl.h:1136
ImageModel imageModel
Definition: main.cpp:32
#define IDD_ATTRIBUTESEDIT2
Definition: resource.h:136
#define MessageBox
Definition: winuser.h:5812
LOGFONTA elfLogFont
Definition: wingdi.h:2686
#define ComboBox_GetLBTextLen(hwndCtl, index)
Definition: windowsx.h:57
#define TB_SETBUTTONWIDTH
Definition: commctrl.h:1161
#define IDB_FONTSTOOLBAR
Definition: resource.h:16
#define IDD_MIRRORROTATERB6
Definition: resource.h:132
HINSTANCE hProgInstance
Definition: main.cpp:50
#define Edit_SetModify(hwndCtl, fModified)
Definition: windowsx.h:105
#define IDS_ANGLE
Definition: resource.h:212
#define IDD_ATTRIBUTESRB1
Definition: resource.h:148
#define ComboBox_SetCurSel(hwndCtl, index)
Definition: windowsx.h:66
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
#define SWP_NOSIZE
Definition: winuser.h:1235
#define GetTimeFormat
Definition: winnls.h:1189
COLORREF WINAPI SetTextColor(_In_ HDC, _In_ COLORREF)
Definition: text.c:918
static HDC hDC
Definition: 3dtext.c:33
BOOL WINAPI GetClientRect(_In_ HWND, _Out_ LPRECT)
#define DT_SINGLELINE
Definition: winuser.h:540
POINT percentage
Definition: dialogs.h:86
LRESULT OnRadioButton1(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:136
#define TEXT(s)
Definition: k32.h:26
#define ComboBox_ResetContent(hwndCtl)
Definition: windowsx.h:63
int GetHeight() const
Definition: history.cpp:220
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
LRESULT OnClose(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:224
HWND buttons[5]
Definition: sndrec32.cpp:40
BOOL WINAPI DeleteDC(_In_ HDC)
#define IDD_FONTSTOOLBAR
Definition: resource.h:177
#define IDD_STRETCHSKEWEDITVSKEW
Definition: resource.h:171
CFontsDialog fontsDialog
Definition: dialogs.cpp:22
static calc_node_t temp
Definition: rpn_ieee.c:38
#define GetDateFormat
Definition: winnls.h:1184
__u16 date
Definition: mkdosfs.c:366
#define IDS_BOLD
Definition: resource.h:217
int CDECL _ttoi(const _TCHAR *str)
Definition: atoi.c:10
#define LR_CREATEDIBSECTION
Definition: winuser.h:1092
#define SetWindowText
Definition: winuser.h:5847
LRESULT OnOk(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:230
unsigned int UINT
Definition: ndis.h:50
#define NULL
Definition: types.h:112
LRESULT OnEdit1(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:163
#define IMAGE_BITMAP
Definition: winuser.h:211
#define CBN_SELCHANGE
Definition: winuser.h:1969
#define BST_CHECKED
Definition: winuser.h:197
LRESULT OnOk(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:113
#define IDD_MIRRORROTATERB2
Definition: resource.h:128
#define IDD_ATTRIBUTESTEXT6
Definition: resource.h:142
FONTENUMPROCA FONTENUMPROC
Definition: wingdi.h:2902
Definition: name.c:38
#define ODS_SELECTED
Definition: winuser.h:2535
#define SendMessage
Definition: winuser.h:5833
_TCHAR * _tcscat(_TCHAR *s, const _TCHAR *append)
Definition: tcscat.h:8
#define TBSTATE_ENABLED
Definition: commctrl.h:974
void InitToolbar()
Definition: dialogs.cpp:336
LRESULT OnDrawItem(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:554
#define HIWORD(l)
Definition: typedefs.h:247
#define IDM_ITALIC
Definition: resource.h:101
BOOL LoadString(_In_ UINT nID)
Definition: cstringt.h:591
LRESULT OnOk(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:39
CHAR lfFaceName[LF_FACESIZE]
Definition: dimm.idl:55
#define IDD_FONTSSIZES
Definition: resource.h:176
#define TBSTYLE_CHECK
Definition: commctrl.h:983
LRESULT OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:257
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
#define TB_ISBUTTONCHECKED
Definition: commctrl.h:1049
#define IDD_STRETCHSKEWEDITVSTRETCH
Definition: resource.h:162
#define IDCANCEL
Definition: winuser.h:825
RegistrySettings registrySettings
Definition: main.cpp:30
LONG_PTR LRESULT
Definition: windef.h:209
#define wsprintf
Definition: winuser.h:5855
LRESULT OnRadioButton12(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:68
IN PCTCH IN DWORD cch
Definition: pager.h:36
int WINAPI FillRect(HDC, LPCRECT, HBRUSH)
void OnFontName(UINT codeNotify)
Definition: dialogs.cpp:395
HBRUSH WINAPI GetSysColorBrush(_In_ int)
LRESULT OnDefault(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:125
LRESULT OnMeasureItem(UINT nMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandled)
Definition: dialogs.cpp:540
void InitFontSizes()
Definition: dialogs.cpp:310
LPARAM lParam
Definition: combotst.c:139
#define LOWORD(l)
Definition: pedump.c:82
int fileVPPM
Definition: main.cpp:57
LRESULT OnEdit2(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:188
#define IDD_ATTRIBUTESRB2
Definition: resource.h:149
LRESULT OnCancel(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL &bHandled)
Definition: dialogs.cpp:54
#define IDD_STRETCHSKEWEDITHSKEW
Definition: resource.h:167