Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

209 lines
5.8 KiB

  1. // imageatt.h : header file
  2. //
  3. #include "imgdlgs.h"
  4. typedef enum
  5. {
  6. ePIXELS = 0,
  7. eINCHES = 1,
  8. eCM = 2
  9. } eUNITS;
  10. /*************************** CImageAttr dialog *****************************/
  11. class CImageAttr : public CDialog
  12. {
  13. // Construction
  14. public:
  15. CImageAttr(CWnd* pParent = NULL); // standard constructor
  16. void SetWidthHeight(ULONG nWidthPixels, ULONG nHeightPixels, ULONG cXPelsPerMeter, ULONG cYPelsPerMeter);
  17. CSize GetWidthHeight(void);
  18. // Dialog Data
  19. //{{AFX_DATA(CImageAttr)
  20. enum { IDD = IDD_IMAGE_ATTRIBUTES };
  21. CString m_cStringWidth;
  22. CString m_cStringHeight;
  23. //}}AFX_DATA
  24. BOOL m_bMonochrome;
  25. // Implementation
  26. protected:
  27. eUNITS m_eUnitsCurrent;
  28. BOOL bEditFieldModified;
  29. ULONG m_ulHeightPixels;
  30. ULONG m_ulWidthPixels;
  31. ULONG m_ulHeight;
  32. ULONG m_ulWidth;
  33. ULONG m_cXPelsPerMeter;
  34. ULONG m_cYPelsPerMeter;
  35. COLORREF m_crTrans;
  36. void PaintTransBox ( COLORREF );
  37. void FixedFloatPtToString( CString& sString, ULONG ulFixedFloatPt );
  38. ULONG StringToFixedFloatPt( CString& sString );
  39. void ConvertWidthHeight( void );
  40. void PelsToCurrentUnit( void );
  41. void SetNewUnits( eUNITS NewUnit );
  42. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  43. virtual LONG OnHelp(WPARAM wParam, LPARAM lParam);
  44. virtual LONG OnContextMenu(WPARAM wParam, LPARAM lParam);
  45. // Generated message map functions
  46. //{{AFX_MSG(CImageAttr)
  47. virtual BOOL OnInitDialog();
  48. virtual void OnOK();
  49. afx_msg void OnInches();
  50. afx_msg void OnCentimeters();
  51. afx_msg void OnPixels();
  52. afx_msg void OnChangeHeight();
  53. afx_msg void OnChangeWidth();
  54. afx_msg void OnDefault();
  55. afx_msg void OnUseTrans();
  56. afx_msg void OnSelectColor ();
  57. afx_msg void OnPaint();
  58. //}}AFX_MSG
  59. DECLARE_MESSAGE_MAP()
  60. CString ReformatSizeString (DWORD dwNumber);
  61. void UpdateResolutionString();
  62. };
  63. /*************************** CZoomViewDlg dialog ***************************/
  64. class CZoomViewDlg : public CDialog
  65. {
  66. // Construction
  67. public:
  68. CZoomViewDlg(CWnd* pParent = NULL); // standard constructor
  69. // Dialog Data
  70. UINT m_nCurrent;
  71. //{{AFX_DATA(CZoomViewDlg)
  72. enum { IDD = IDD_VIEW_ZOOM };
  73. //}}AFX_DATA
  74. // Implementation
  75. protected:
  76. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  77. virtual LONG OnHelp(WPARAM wParam, LPARAM lParam);
  78. virtual LONG OnContextMenu(WPARAM wParam, LPARAM lParam);
  79. // Generated message map functions
  80. //{{AFX_MSG(CZoomViewDlg)
  81. virtual BOOL OnInitDialog();
  82. virtual void OnOK();
  83. //}}AFX_MSG
  84. DECLARE_MESSAGE_MAP()
  85. };
  86. /************************* CFlipRotateDlg dialog ***************************/
  87. class CFlipRotateDlg : public CDialog
  88. {
  89. // Construction
  90. public:
  91. CFlipRotateDlg(CWnd* pParent = NULL); // standard constructor
  92. // Dialog Data
  93. BOOL m_bHorz;
  94. BOOL m_bAngle;
  95. UINT m_nAngle;
  96. //{{AFX_DATA(CFlipRotateDlg)
  97. enum { IDD = IDD_FLIP_ROTATE };
  98. // NOTE: the ClassWizard will add data members here
  99. //}}AFX_DATA
  100. // Implementation
  101. protected:
  102. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  103. virtual LONG OnHelp(WPARAM wParam, LPARAM lParam);
  104. virtual LONG OnContextMenu(WPARAM wParam, LPARAM lParam);
  105. // Generated message map functions
  106. //{{AFX_MSG(CFlipRotateDlg)
  107. virtual BOOL OnInitDialog();
  108. virtual void OnOK();
  109. afx_msg void OnByAngle();
  110. afx_msg void OnNotByAngle();
  111. //}}AFX_MSG
  112. DECLARE_MESSAGE_MAP()
  113. };
  114. /********************** CStretchSkewDlg dialog *****************************/
  115. class CStretchSkewDlg : public CDialog
  116. {
  117. // Construction
  118. public:
  119. CStretchSkewDlg(CWnd* pParent = NULL); // standard constructor
  120. // Check that the direction was specified and subtract 100 to make it
  121. // equivalent to the 0 based system
  122. // GetStretchHorz() { return(m_bStretchHorz ? m_iStretchHorz - 100 : 0); }
  123. // GetStretchVert() { return(m_bStretchHorz ? 0 : m_iStretchVert - 100); }
  124. int GetStretchHorz() {return (m_iStretchHorz-100);}
  125. int GetStretchVert() {return (m_iStretchVert-100);}
  126. // Check that the direction was specified
  127. // GetSkewHorz() { return(m_bSkewHorz ? m_wSkewHorz : 0); }
  128. // GetSkewVert() { return(m_bSkewHorz ? 0 : m_wSkewVert); }
  129. int GetSkewHorz() { return(m_wSkewHorz); }
  130. int GetSkewVert() { return(m_wSkewVert); }
  131. private:
  132. // Dialog Data
  133. //{{AFX_DATA(CStretchSkewDlg)
  134. enum { IDD = IDD_STRETCH_SKEW };
  135. int m_wSkewHorz;
  136. int m_wSkewVert;
  137. int m_iStretchVert;
  138. int m_iStretchHorz;
  139. //}}AFX_DATA
  140. // Implementation
  141. protected:
  142. BOOL m_bStretchHorz;
  143. BOOL m_bSkewHorz;
  144. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  145. virtual LONG OnHelp(WPARAM wParam, LPARAM lParam);
  146. virtual LONG OnContextMenu(WPARAM wParam, LPARAM lParam);
  147. // Generated message map functions
  148. //{{AFX_MSG(CStretchSkewDlg)
  149. // TODO
  150. // these are commented out of the message map. delete them?
  151. virtual void OnOK();
  152. virtual BOOL OnInitDialog();
  153. afx_msg void OnSkewHorz();
  154. afx_msg void OnSkewVert();
  155. afx_msg void OnStretchHorz();
  156. afx_msg void OnStretchVert();
  157. //}}AFX_MSG
  158. DECLARE_MESSAGE_MAP()
  159. };
  160. /***************************************************************************/