Next Generation for Desktop Applications Doncho Minkov Telerik School Academy schoolacademy.telerik.com Technical Trainer

Slides:



Advertisements
Similar presentations
Module 1: Creating an Application by Using Windows Presentation Foundation Overview of WPF Creating a Simple WPF Application Handling Events and Commands.
Advertisements

Expression Blend 4 – deep dive
The Microsoft Technical Roadshow 2006 Windows Presentation Foundation (WPF) Marcus Perryman
MULTIMEDIA DEVELOPMENT 4.3 : AUTHORING TOOLS. At the end of the lesson, students should be able to: 1. Describe different types of authoring tools Learning.
Dinko Jakovljević Microsoft Student Partner | BambooLab
An Introduction To Silverlight Gergely Orosz
Developing Rich Web Applications with Silverlight Mike Ormond Developer & Platform Group Microsoft Ltd
July 06, 2006DB&IS Building Web Information Systems using Web Services Flavius Frasincar Erasmus University Rotterdam Eindhoven.
Windows Presetation Foundation (WPF) 1. Introduction.
The Microsoft’s solution for building cross-platform Rich Internet Applications.
WPF. Origins – Who, When, Where  Who? Microsoft  When? November 2006  Where? Windows Vista Windows Server 2003 Windows XP Service Pack 2.
AJAX & By – Anupama Sharma. Defining Ajax Ajax isn’t a technology. It’s really several technologies, each flourishing in its own right, coming together.
Chapter 1 Understanding the Web Design Environment
Tutorial 3: Adding and Formatting Text. 2 Objectives Session 3.1 Type text into a page Copy text from a document and paste it into a page Check for spelling.
The Designer-Developer Workflow Martin Tirion User Experience Evangelist Microsoft.
Desktop and Mobile Testing Miroslav Shtilianov QA Engineer Automated Testing Team Telerik QA Academy
Understanding HTML Style Sheets. What is a style?  A style is a rule that defines the appearance and position of text and graphics. It may define the.
Web Design Basic Concepts.
COM 205 Multimedia Applications
Chapter 11 Adding Media and Interactivity. Flash is a software program that allows you to create low-bandwidth, high-quality animations and interactive.
Chapter 1 Variables in the Web Design Environment
WPF For PowerBuilder Developers
2 A First Look at Windows Presentation Foundation Everywhere ("WPF/E") Joe Stegman Lead Program Manager Microsoft Corporation.
Chapter 11-Multimedia Authoring Tools. Overview Introduction to multimedia authoring tools. Types of authoring tools. Cross-platform authoring notes.
Working with Cascading Style Sheets. Introducing Cascading Style Sheets Style sheets are files or forms that describe the layout and appearance of a document.
Daniel Levy Solutions Consultant, Telerik Testing Tools Division.
Architecture Of ASP.NET. What is ASP?  Server-side scripting technology.  Files containing HTML and scripting code.  Access via HTTP requests.  Scripting.
Introduction to Silverlight. Slide 2 What is Silverlight? It’s part of a Microsoft Web platform called Rich Internet Applications (RIA) There is a service.
1 COS240 O-O Languages AUBG, COS dept Lecture 33 Building Apps Technologies C# (WPF part 1)
WPF chapter 15 Dr. John Abraham Professor UTPA. WPF –an introduction WPF provides a single platform capable of handling graphics, audio and video. WPF.
Zhonghua Qu and Ovidiu Daescu December 24, 2009 University of Texas at Dallas.
A Jumpstart to WPF by Kevin Grossnicklaus ArchitectNow.
Windows Presentation Foundation. Agenda Introduction Developing Applications WPF and WF interoperability Custom Controls Styles and Templates Data Binding.
Windows Presentation Foundation. Goal The goal of Windows Presentation Foundation (WPF) is to provide these advances for Windows. Included in version.
Silverlight Hitesh Trivedi Computer Science B.Tech A-Sec J.I.E.T.
Chapter 1 Understanding the Web Design Environment Principles of Web Design, 4 th Edition.
Week 1 Understanding the Web Design Environment. 1-2 HTML: Then and Now HTML is an application of the Standard Generalized Markup Language Intended to.
XP Dreamweaver 8.0 Tutorial 3 1 Adding Text and Formatting Text with CSS Styles.
Silverlight Technology. Table of Contents 1.What is Silverlight Technology? 2.Silverlight Overview. 2.1 How it works 2.2 Silverlight development tools.
McGraw-Hill/Irwin © 2004 by The McGraw-Hill Companies, Inc. All rights reserved. SMIL Ellen Pearlman Eileen Mullin Programming the Web Using XML.
CHAPTER TEN AUTHORING.
Object Oriented Software Development 9. Creating Graphical User Interfaces.
Windows Presentation Foundation (WPF) Chapter 16 Dr. Abraham.
Tutorial 7 Planning and Creating a Flash Web Site.
The Microsoft Technical Roadshow 2007 Rich Client Development in XAML Mark Johnston Developer & Platform Group Microsoft Ltd
New Features Overview. Agenda Silverlight - Intro Silverlight 3 New Features Overview with Demos, Demos and Demos… RIA Services Overview Demos, Demos,
Discover, Master, Influence1 Windows Presentation Foundation David Burela Senior Developer, Readify.
Developing ASP.NET AJAX Controls with Silverlight Barry Gervin Microsoft Regional Director John Bristowe Developer Advisor, Microsoft.
Doncho Minkov Telerik Software Academy academy.telerik.com Technical Trainer Next Generation for Desktop Applications.
A Lap Around Windows Presentation Foundation. Why hasn’t UX taken off in software? It’s Difficult! Animation 2D 3D Documents Styled Controls Video Windows.
CHAPTER 15 WPF Windows Presentation Foundation Dr. John Abraham Professor, UTPA.
WPF – Windows Presentation Foundation what is it, what can you do with it and how do you get started.
Tutorial 3 Adding and Formatting Text with CSS Styles.
ControlTemplate and DataTemplate Doncho Minkov Telerik School Academy Technical Trainer
Contents : What is Silverlight? Silverlight Overview Silverlight Toolkit Overview Timeline & Packaging Silverlight V1.0 & V1.1 Properties of V1.0 Properties.
Rujchai Ung-arunyawee Department of Computer Engineering Khon Kaen University.
XP Tutorial 7 Creating a Flash Web Site. XP New Perspectives on Macromedia Flash 82 Objectives Plan and create a Flash Web site Create a Flash template.
1 Catching up on Rich Clients (round 1) Mike Ormond, Mike Taulty Developer & Platform Group Microsoft Ltd
1 Välkommen till Sommarkollo Windows Presentation Foundation Per Östman ISV Developer Evangelist
Windows Presentation Foundation. User Experience: Recent Past Web HTML Sacrificed UX for portability, connectivity and simplicity 1997 – DHTML.
WPF (Avalon), Windows App GUI Windows App GUI Web App GUI Web App GUI HTML HTML XML XML WPF WPF LINQ LINQ.
Part of the Microsoft.NET Framework 3.0 Tomer Shamam.NET Technologies Expert Sela Group
Adam Schultz MVVM and WPF. MVVM Model, View, ViewModel A software architecture designed to separate out User Interface design, Business Logic, and Data.
XAML User Interface Creation in C#
Introduction to Silverlight
WPF AKEEL AHMED.
.NET and .NET Core 7. XAML Pan Wuming 2017.
Silverlight Technology
Windows Presentation Foundation
Brown Bag Seminar Summer 2007
Presentation transcript:

Next Generation for Desktop Applications Doncho Minkov Telerik School Academy schoolacademy.telerik.com Technical Trainer

1. What is Windows Presentation Foundation (WPF)? 2. WPF basic features 3. WPF and other UI technologies  Windows Forms  DirectX  Silverlight  HTML + CSS 2

4. WPF architecture 5. WPF core assemblies 6. WPF namespaces 7. WPF classes 8. XAML basics 3

 Windows Presentation Foundation (WPF)  An entirely new graphical display system for Windows  Empowers rich-media applications  Provides a clear separation between the UI (XAML) and the business logic (C#,VB.NET)  Influenced by modern display technologies such as HTML, CSS and Flash  Hardware-accelerated 5

 All WPF graphics are Direct3D applications  Direct3D (part of DirectX) is used in graphical applications where performance is important  Uses the video card hardware for rendering  The result: high-quality rich-media UI  Vector-based graphics allows to scale without loss of quality  WPF implements a floating-point logical pixel system and supports 32-bit ARGB color 7

 WPF includes a number of extremely rich typographic and text rendering features  Some of them were not available in GDI  Building international fonts from composite fonts  WPF text rendering takes advantage of ClearType technology  Use caching of pre-rendered text in the video memory  WPF has resolution-independent architecture 8

 WFP supports time-based animations  Presentation timers are initialized and managed by WPF  Scene changes coordinated by using a storyboard  Animations can be triggered  By other external events  Including user action  Animation can be defined on a per-object basis directly from the XAML markup 9

 WPF can incorporate audio and video into a user interface  Audio support in WPF is a thin layer over the existing functionality in Win32 and WMP  WPF supports the video in formats WMV, MPEG and some AVI files  Relationship between video and animation is also supported  They are both ways of showing moving images  Animation can be synchronized with media 10

 In WPF a style is a set of properties applied to content used for visual rendering  Similar to the concept of CSS  E.g. setting the font weight of a Button control  Use them to standardize non-formatting characteristics  WPF styles have specific features for building applications  Ability to apply different visual effects based on user events 11

 Templates in WPF allow you to fully change the UI of anything in WPF  Kinds of templates available within WPF  ControlTemplate  ItemsPanelTemplate  DataTemplate  HierarchicalDataTemplate 12

 Commands are more abstract and loosely- coupled version of events  Examples: copy, cut, paste, save, etc.  WPF support for commands reduces the amount of code we need to write  It gives us more flexibility to change the UI without breaking the back-end logic  Commands have action, source, target and binding 13

 The power of commands comes from the following three features  WPF defines a number of built-in commands  Commands have automatic support for input actions  Some WPF controls have built-in behavior tied to various commands  Commands are intended to do two things:  Check whether an action is available  Execute an action 14

 WPF introduces a new XML-based language for describing UI elements known as XAML  XAML = eXtensible Application Markup Language  XAML is a completely declarative language  A declarative language says "what"  An imperative language says "how"  XAML describes the behavior and integration of components (in most cases UI components) 15

 At the lower-level WPF works in terms of shapes, not in terms of painting pixels  Shapes are vector-based and can easily scale  Developers create shape objects and let WPF maintain the display in the most optimized way  WPF provides a number of ready-to-use shape objects like line, rectangle, ellipse, path, etc.  Shape objects can be used inside panels and inside most WPF controls 16

 Windows Forms is the culmination of the display technology built on GDI+ and User32  It’s more mature than WPF  Has solid limitations  No separation between UI and the C# code  WPF is the platform for the future of Windows development  Based on DirectX and Direct3D  Separation between the UI and C# code 18

 WPF create multimedia applications with real- time graphics  Such as complex physics-based simulators or cutting-edge action games  WPF applications are DirectX applications  As a result, even the most mundane business applications can use rich effects and antialiasing  WPF graphics is entirely vector-based  This allows zoom-in / soom-out with no loss of quality 19

 Silverlight is a cross-platform, cross-browser plugin, which contains WPF-based technology  Rich Internet Application (RIA) platform  Including XAML and subset of WPF  Provides rich-media features such as video, vector graphics, and animations  Silverlight and WPF share the XAML presentation layer  Both technologies are similar, but Silverlight is limited in many aspects 20

 Cascading Style Sheets (CSS) is a stylesheet language  Used to describe the presentation of information in HTML documents  XAML elements have Style property  Similar to CSS (as a concept)  The HTML and XAML are tag based systems to describe UI  XAML is more powerful in many aspects 21

 XAML is an XML-based language for creating and initializing.NET objects  It’s used in WPF as a human-authorable way of describing the UI  Used to separate the UI from the C# code  XAML contains a hierarchy of elements representing visual objects  These objects are known as user interface elements or UI elements 23

 UI elements have a set of common properties and functions  Such as Width, Height, Cursor, and Tag properties  Declaring an XML element in XAML  Equivalent to instantiating the object via a parameterless constructor  Setting an attribute on the object element  Equivalent to setting a property of the same name 24

 Constructs button with caption "OK" 25 <Window x:Class="MyFirstWpfApp.MainWindow" xmlns= " " xmlns:x= xmlns:x= Title="Hello, WPF" Height="300" Width="300"> Title="Hello, WPF" Height="300" Width="300"> <Button x:Name="button" <Button x:Name="button" Width="200" Width="200" Height="25">OK Height="25">OK </Window>

 The root element, Window is used to declare a portion of a class  The two XML namespace declarations pull in two commonly used namespaces  The one for XAML itself  The one for WPF  Width, Height, Title are the XAML properties 26

Live Demo

 eXtensible Application Markup Language  XAML is a declarative markup language  Used to simplify creation of UI for a.NET apps  Separates UI and Business logic  XAML enables a workflow where different parties can work simultaneously  The UI and the logic of an application can be developed using different tools (VS and Blend)

 XAML is an XML-based language for creating and initializing.NET objects  It’s used in WPF and Silverlight as a human- authorable way of describing the UI  Used to separate the UI from the C# code  XAML contains a hierarchy of elements representing visual objects  These objects are known as user interface elements or UI elements 30

 XAML introduces a new XML-based language for describing UI elements known as XAML  XAML = eXtensible Application Markup Language  XAML is a completely declarative language  A declarative language says "what"  An imperative language says "how"  XAML describes the behavior and integration of components (in most cases UI components) 31

 Not all properties have just a string value  Some must be set to an instance of an object  XAML provide syntax for setting complex property values, called property elements  Take the form TypeName.PropertyName contained inside an TypeName element 33 <Ellipse> </Ellipse> A property element

Live Demo

Why we need XAML?

 In WPF/Silverlight each element can be done either declaratively or programmatically  No difference in the execution and speed  Instantiating element from the code behind ruins the idea of XAML  The same as Windows Forms  The following two examples are identical Button button=new Button(); button.Content="Click me!";  With XAML  From Code Behind

 When not using XAML with WPF/Silverlight  Miss the idea of separation of concerns  Two parties cannot work simultaneously on the same file  What happens when making object declaratively?  It is the same as instantiating the element with parameterless constructor  All the magic happens in InitializeComponents()

 Windows Forms  Framework to design applications with GUI  Does the same job as WPF  Everything is in one place  Much like java's swings (by concept)  Windows Presentation Foundation (WPF)  Separate UI and Business Logic  Why change the concept of the UI?  In Windows Forms all the code is in one place  Harder for front-end and back-end developers

Live Demo

Questions?