ReactOS  0.4.14-dev-49-gfb4591c
ToolsModel Class Reference

#include <toolsmodel.h>

Collaboration diagram for ToolsModel:

Public Member Functions

 ToolsModel ()
 
int GetLineWidth ()
 
void SetLineWidth (int nLineWidth)
 
int GetShapeStyle ()
 
void SetShapeStyle (int nShapeStyle)
 
int GetBrushStyle ()
 
void SetBrushStyle (int nBrushStyle)
 
int GetActiveTool ()
 
void SetActiveTool (int nActiveTool)
 
int GetAirBrushWidth ()
 
void SetAirBrushWidth (int nAirBrushWidth)
 
int GetRubberRadius ()
 
void SetRubberRadius (int nRubberRadius)
 
BOOL IsBackgroundTransparent ()
 
void SetBackgroundTransparent (BOOL bTransparent)
 
int GetZoom ()
 
void SetZoom (int nZoom)
 

Private Member Functions

void NotifyToolChanged ()
 
void NotifyToolSettingsChanged ()
 
void NotifyZoomChanged ()
 

Private Attributes

int m_lineWidth
 
int m_shapeStyle
 
int m_brushStyle
 
int m_activeTool
 
int m_airBrushWidth
 
int m_rubberRadius
 
BOOL m_transpBg
 
int m_zoom
 

Detailed Description

Definition at line 13 of file toolsmodel.h.

Constructor & Destructor Documentation

◆ ToolsModel()

ToolsModel::ToolsModel ( )

Definition at line 15 of file toolsmodel.cpp.

16 {
17  m_lineWidth = 1;
18  m_shapeStyle = 0;
19  m_brushStyle = 0;
21  m_airBrushWidth = 5;
22  m_rubberRadius = 4;
23  m_transpBg = FALSE;
24  m_zoom = 1000;
25 }
int m_rubberRadius
Definition: toolsmodel.h:21
int m_activeTool
Definition: toolsmodel.h:19
int m_zoom
Definition: toolsmodel.h:23
#define TOOL_PEN
Definition: definitions.h:141
BOOL m_transpBg
Definition: toolsmodel.h:22
int m_airBrushWidth
Definition: toolsmodel.h:20
int m_brushStyle
Definition: toolsmodel.h:18
int m_lineWidth
Definition: toolsmodel.h:16
int m_shapeStyle
Definition: toolsmodel.h:17

Member Function Documentation

◆ GetActiveTool()

◆ GetAirBrushWidth()

int ToolsModel::GetAirBrushWidth ( )

Definition at line 71 of file toolsmodel.cpp.

72 {
73  return m_airBrushWidth;
74 }
int m_airBrushWidth
Definition: toolsmodel.h:20

Referenced by CToolSettingsWindow::OnPaint(), startPaintingL(), startPaintingR(), whilePaintingL(), and whilePaintingR().

◆ GetBrushStyle()

int ToolsModel::GetBrushStyle ( )

Definition at line 49 of file toolsmodel.cpp.

50 {
51  return m_brushStyle;
52 }
int m_brushStyle
Definition: toolsmodel.h:18

Referenced by CToolSettingsWindow::OnPaint(), startPaintingL(), startPaintingR(), whilePaintingL(), and whilePaintingR().

◆ GetLineWidth()

int ToolsModel::GetLineWidth ( )

◆ GetRubberRadius()

int ToolsModel::GetRubberRadius ( )

◆ GetShapeStyle()

int ToolsModel::GetShapeStyle ( )

◆ GetZoom()

◆ IsBackgroundTransparent()

BOOL ToolsModel::IsBackgroundTransparent ( )

◆ NotifyToolChanged()

void ToolsModel::NotifyToolChanged ( )
private

Definition at line 115 of file toolsmodel.cpp.

116 {
120 }
CToolBox toolBoxContainer
Definition: main.cpp:65
#define WM_TOOLSMODELTOOLCHANGED
Definition: definitions.h:241
int m_activeTool
Definition: toolsmodel.h:19
LRESULT SendMessage(UINT message, WPARAM wParam=0, LPARAM lParam=0)
Definition: atlwin.h:1048
CTextEditWindow textEditWindow
Definition: main.cpp:80
CToolSettingsWindow toolSettingsWindow
Definition: main.cpp:66

Referenced by SetActiveTool().

◆ NotifyToolSettingsChanged()

void ToolsModel::NotifyToolSettingsChanged ( )
private

Definition at line 122 of file toolsmodel.cpp.

123 {
126 }
#define WM_TOOLSMODELSETTINGSCHANGED
Definition: definitions.h:242
CToolSettingsWindow toolSettingsWindow
Definition: main.cpp:66
CSelectionWindow selectionWindow
Definition: main.cpp:70

Referenced by SetAirBrushWidth(), SetBackgroundTransparent(), SetBrushStyle(), SetLineWidth(), SetRubberRadius(), and SetShapeStyle().

◆ NotifyZoomChanged()

void ToolsModel::NotifyZoomChanged ( )
private

Definition at line 128 of file toolsmodel.cpp.

129 {
131 }
#define WM_TOOLSMODELZOOMCHANGED
Definition: definitions.h:243
CToolSettingsWindow toolSettingsWindow
Definition: main.cpp:66

Referenced by SetZoom().

◆ SetActiveTool()

void ToolsModel::SetActiveTool ( int  nActiveTool)

Definition at line 65 of file toolsmodel.cpp.

66 {
67  m_activeTool = nActiveTool;
69 }
int m_activeTool
Definition: toolsmodel.h:19
void NotifyToolChanged()
Definition: toolsmodel.cpp:115

Referenced by CToolBox::OnCommand().

◆ SetAirBrushWidth()

void ToolsModel::SetAirBrushWidth ( int  nAirBrushWidth)

Definition at line 76 of file toolsmodel.cpp.

77 {
78  m_airBrushWidth = nAirBrushWidth;
80 }
int m_airBrushWidth
Definition: toolsmodel.h:20
void NotifyToolSettingsChanged()
Definition: toolsmodel.cpp:122

Referenced by CToolSettingsWindow::OnLButtonDown().

◆ SetBackgroundTransparent()

void ToolsModel::SetBackgroundTransparent ( BOOL  bTransparent)

Definition at line 98 of file toolsmodel.cpp.

99 {
100  m_transpBg = bTransparent;
102 }
BOOL m_transpBg
Definition: toolsmodel.h:22
void NotifyToolSettingsChanged()
Definition: toolsmodel.cpp:122

Referenced by CMainWindow::OnCommand(), and CToolSettingsWindow::OnLButtonDown().

◆ SetBrushStyle()

void ToolsModel::SetBrushStyle ( int  nBrushStyle)

Definition at line 54 of file toolsmodel.cpp.

55 {
56  m_brushStyle = nBrushStyle;
58 }
int m_brushStyle
Definition: toolsmodel.h:18
void NotifyToolSettingsChanged()
Definition: toolsmodel.cpp:122

Referenced by CToolSettingsWindow::OnLButtonDown().

◆ SetLineWidth()

void ToolsModel::SetLineWidth ( int  nLineWidth)

Definition at line 32 of file toolsmodel.cpp.

33 {
34  m_lineWidth = nLineWidth;
36 }
void NotifyToolSettingsChanged()
Definition: toolsmodel.cpp:122
int m_lineWidth
Definition: toolsmodel.h:16

Referenced by CToolSettingsWindow::OnLButtonDown().

◆ SetRubberRadius()

void ToolsModel::SetRubberRadius ( int  nRubberRadius)

Definition at line 87 of file toolsmodel.cpp.

88 {
89  m_rubberRadius = nRubberRadius;
91 }
int m_rubberRadius
Definition: toolsmodel.h:21
void NotifyToolSettingsChanged()
Definition: toolsmodel.cpp:122

Referenced by CToolSettingsWindow::OnLButtonDown().

◆ SetShapeStyle()

void ToolsModel::SetShapeStyle ( int  nShapeStyle)

Definition at line 43 of file toolsmodel.cpp.

44 {
45  m_shapeStyle = nShapeStyle;
47 }
void NotifyToolSettingsChanged()
Definition: toolsmodel.cpp:122
int m_shapeStyle
Definition: toolsmodel.h:17

Referenced by CToolSettingsWindow::OnLButtonDown().

◆ SetZoom()

void ToolsModel::SetZoom ( int  nZoom)

Definition at line 109 of file toolsmodel.cpp.

110 {
111  m_zoom = nZoom;
113 }
int m_zoom
Definition: toolsmodel.h:23
void NotifyZoomChanged()
Definition: toolsmodel.cpp:128

Referenced by zoomTo().

Member Data Documentation

◆ m_activeTool

int ToolsModel::m_activeTool
private

Definition at line 19 of file toolsmodel.h.

Referenced by GetActiveTool(), NotifyToolChanged(), SetActiveTool(), and ToolsModel().

◆ m_airBrushWidth

int ToolsModel::m_airBrushWidth
private

Definition at line 20 of file toolsmodel.h.

Referenced by GetAirBrushWidth(), SetAirBrushWidth(), and ToolsModel().

◆ m_brushStyle

int ToolsModel::m_brushStyle
private

Definition at line 18 of file toolsmodel.h.

Referenced by GetBrushStyle(), SetBrushStyle(), and ToolsModel().

◆ m_lineWidth

int ToolsModel::m_lineWidth
private

Definition at line 16 of file toolsmodel.h.

Referenced by GetLineWidth(), SetLineWidth(), and ToolsModel().

◆ m_rubberRadius

int ToolsModel::m_rubberRadius
private

Definition at line 21 of file toolsmodel.h.

Referenced by GetRubberRadius(), SetRubberRadius(), and ToolsModel().

◆ m_shapeStyle

int ToolsModel::m_shapeStyle
private

Definition at line 17 of file toolsmodel.h.

Referenced by GetShapeStyle(), SetShapeStyle(), and ToolsModel().

◆ m_transpBg

BOOL ToolsModel::m_transpBg
private

Definition at line 22 of file toolsmodel.h.

Referenced by IsBackgroundTransparent(), SetBackgroundTransparent(), and ToolsModel().

◆ m_zoom

int ToolsModel::m_zoom
private

Definition at line 23 of file toolsmodel.h.

Referenced by GetZoom(), SetZoom(), and ToolsModel().


The documentation for this class was generated from the following files: