Windows Programming Chap 2 MFC MFC n MDI
- Slides: 43
Windows Programming Chap 2. MFC개요 및 아키텍처
MFC 프로그램의 구조 n MDI 애플리케이션의 구조 n n 여러 개의 SDI형태 프로그램 Main Frame n n 독립적으로 설정되어 있고 그 안에 template Template n n n Child Frame View Window Document Main Frame Template View Window Document Child Frame. . . 위의 템플릿이 여러 개 있을 수 있음
MFC 프로그램의 구조 n MFC 형태의 프로그램 구조 n Application Class n MFC프로그램은 템플릿을 포함하고 한 개의 인스턴스를 포함하는 Application class가 있음 Application Class Main Frame Template View Window Document Main Frame Child Frame. 위의 템플릿이 여러. 개 있을 수 있음.
Application Wizard n App. Wizard Step 1 n 프로그램의 형태 선택 n n n Single Document Multiple Document Dialog Based Document 유무 프로그램 지원 언어 n Visual C++ 6. 0 에서 부터 한국어 지원
Application Wizard n App. Wizard Step 4 n Advanced Option 선 택 (Window Styles) n n 메인 프레임 스타일 MDI 형태일 경우 자식 프레임 스타일
Application Wizard n App. Wizard Step 6 n Class 와 파일 대한 정 보 및 수정 n n n Class 이름은 모든 class 에서 변경할 수 있다. Source file과 Header file 이름은 App class 외에 다 른 class 에서만 변경할 수 있다 Base class이름은 View class 에서만 변경할 수 있 다.
Application Wizard n App. Wizard 완료 n App. Wizard를 사 용하여 만든 프로 젝트에 대한 정보 를 보여준다. n n n Application type Classes to be created Features
Application Wizard n MDI형 프로젝트 만들기 n n SDI와 동일하고 Step 1 에서 MDI를 선택 추가된 내용 n n CChild. Frame 만이 추가 되었다 Child Frame class는 Base Class 이름만 변경 할 수 없다.
Project Workspace n File View 화면 n 소스 파일 n 헤더 파일 n 자원 파일
MFC Application Architecture n MFC클래스의 기본 구조 n MFC의 계층적 구조 형태 CObject CCmd. Target CWnd CFrame. Wnd CView CWin. Thread CDialog CDocument 기타 CWin. App ► Cframe. Wnd 과 Cview클래스는 CWnd에서 상속받음
MFC Application Architecture n CWnd클래스 n n n 화면에 보이는 윈도들은 모두 CWnd 에서 상속 받음 가장 많이 사용되는 클래스 윈도우의 최상위 클래스 상속해서 사용하지 직접 CWnd 클래스를 사용하지는 않는다. 윈도우를 구동하는 모든 기능을 가진 함수가 있다. n Initialization Window State Functions Window Size and position n Coordinate Mapping Functions n n Window Message Functions ……. .
CWnd를 상속 받은 클래스들 CWnd CFrame. Wnd 프레임 형태의 윈도우 CControl. Bar 컨트롤 바 CProperty. Sheet CDialog CView Control class 프로퍼티 시트 대화 상자 View 윈도우 컨트롤 들
In. Validate() WM_PAINT 메시지 void CView: : On. Paint() { // standard paint routine CPaint. DC dc(this); class CShape. View : public CView On. Prepare. DC(&dc); On. Draw(&dc); 화면 DC void CShape. View: : On. Draw(CDC *p. DC) } { Cshape. Doc* p. Doc=Get. Document(); void CView: : On. Print(CDC* p. DC ASSERT_VALID(p. Doc); , CPrint. Info*) … 인쇄와 미리 보기 { } ASSERT_VALID(p. DC); On. Draw(p. DC); // Call Draw } 프린터 DC void CView: : On. Draw(CDC*) { // 아무일도 하지 않는 순수 가상 함수로 선언되어 있기 때문에 반드시 오버라이드 해야 함 CView: : On. Draw( ) 는 순수 가상 함수이므로 파생 클래스에서 반드시 오버라이드 (순수가상함수)
- Chap chap slide
- Mdi user interface
- Mdi work
- Medical developments international penthrox
- Mdi status
- Mdi 768
- Brown mdi
- Mdi ubc
- Ultrasonic nebulizer
- Mdi vacuum
- Mdi sciences
- Mdi'q
- Mdi tdi
- Mdi sabah
- Voiture air comprimé mdi
- Sdi mdi
- Ray veness
- Salbutamol mdi
- Mdi pharmacology
- Uabd process
- Windows media player 9 windows 7
- Meida player classic
- Windows xp
- Windows mobile center windows 10
- Live mail windows 7
- Windows identity foundation windows 10
- Windows driver kit windows 7
- Window movie maker 2012
- Windws update
- How to use windows live movie maker
- Herramientas de movie maker
- Ipseq
- Windows xp virtual desktop
- Windows logo ascii
- What is in system programming
- Console programming
- Mouse events in windows programming
- Windows system programming
- Linear programming models graphical and computer methods
- Windows mobile programming
- Integer programming vs linear programming
- Definisi integer
- Perbedaan linear programming dan integer programming
- Greedy algorithm vs dynamic programming