본문 바로가기

WPF37

응용프로그램 Application 클래스 이벤트 처리 WPF 응용 프로그램에서 Application 클래스의 이벤트들을 처리할 필요가 있다면 해당하는 이벤트에 대한 이벤트 핸들러를 설치해야 하지만, 가장 편리한 방법은 Application 클래스를 상속하는 클래스를 정의하는 방법입니다. using System; // Application 클래스를 포함하는 Namespace 선언 using System.Windows; using System.Windows.Input; namespace Chapter1 { // Application 클래스 상속 class InheritApp : Application { [STAThread] public static void Main() { InheritApp app = new InheritApp (); app.Run(); } .. 2007. 12. 13.
클래스 계층 구조 WPF의 모든 클래스는 Object 로부터 상속을 받으며 Application이 실행되면 onStartup() 이벤트가 override되어 프로그램이 시작됩니다. 실제 우리 눈에 보이는 Window 클래스까지 여러단계를 거쳐... Window에 여러 Control을 표시합니다. WPF 공부를 하시는 모든분들은 위 그림의 계층구조를 계속해서 접하시게 될겁니다. 하나하나 구조를 파악하면서 프로그래밍을 하다보면 WPF 클래스의 계층간 관계나 구조를 자연스럽게 파악하실 수 있을것입니다. 1년전에는 기본 컨트롤 위주로 Markup Language 즉 XAML을 가지고 강좌를 진행했습니다. 조만간에 진행될 WPF 강좌는 XAML과 실제 동적으로 C#코드로도 구현하는 방법을 통하여 WPF 프로그래밍을 하는 방법을 강.. 2007. 12. 12.
[XPS] Fxied Documents XPS(XML Paper Specification)net Framework 3.0과 Windows Vista가 출시되면서 MS에서 밀고 있는 새로운 형태의 전자출판 문서형식입니다. 대표적인 전자출판 문서파일은 Adobe사의 PDF(portable document format)가 있습니다. XPS는 크게 Fixed Documents와 Flow Documents 2가지 형태로 나누어 집니다. 이번강좌에서는 Fixed Documents에 대해 알아보겠습니다. Fixed Documents는 Read-Only의 읽기전용이며 용도는 XPS로 출판하여 보고서 형태의 기안을 작성한다거나 보안을 걸어서 특정사람에게만 열어보게 할 수도 있습니다. XPS 문서를 보려면 XPS DocumentViwer Control이 필요합.. 2007. 8. 10.
[XPS] View and Generate XPS View and Generate XPS Operating System Download Description Windows Vista None Required XPS documents open within Internet Explorer 7.0 or higher. Any application can generate XPS documents using the Microsoft XPS Document Writer. Windows XP Windows Server 2003 Microsoft .NET Framework 3.0 XPS document viewing and generation capabilities are included in Microsoft .NET Framework 3.0. XPS document.. 2007. 8. 10.