It takes about a month from the previous post and these days I do not have much time to visit the site, but I try to post more on this site from now on.The WPF video tutorials is the start of the three words of the Windows Presentation Foundation. Anyone who has ever programmed in graphical environments or to modify programmers, visual environments, is certainly familiar with Windows Application concepts, sometimes called WinApp abbreviations. This type of programming began with the arrival of Windows operating systems in the computer world, and found the programmer to be more and more popular with the emergence of different languages.As you know, Windows Applications use the corresponding operating system APIs (which are mostly Windows XP) to draw graphical elements, or the same visual elements. For example, to figure out the types of buttons, forms, and many other elements you are familiar with, you can use the Windows API functions. The same issue has created limitations for programmers to create custom controls with their own appearances. Although with the graphical tools that were included with .NET Framework 2.0, we could have done our best to create custom controls, but this requires knowing a lot about creating custom controls as well as writing Sometimes there were many code to create control. This was because the basic form of the controls was closed and you could not easily customize the controls. At best, a skilled programmer could inherit from the Control class to create a new control with its appearance and features. For example, I've just designed the following menu control for a company. Only one of the classes in this menu has 1000 lines of code other than the codes generated by .NET itself. Perhaps 1000 lines, for a programmer, is negligible. But if you want to design your own control of your plans, you'll see that it's time to write code. This becomes more time-consuming if you want to control most aspects of a control in your custom control. For example, because there are different gradient modes on the menu, use of previous features, such as drawing a text item automatically by the menu itself, or drawing the keys between the item and .... And all of these must be generated by the code. It is true that you can use the controls created by yourself frequently and in different applications, but the experience has shown that you will sometimes have to create another control. This is not because you did not necessarily have well designed your previous control. Many factors can cause the case that they are not bored.Introduction to WPFNow that it's partly up to date with the WinApp programming problems, I'll continue to introduce the WPF. In the discussion below, you will see how WPF solves many of the existing issues. WPF technology works in a different way. In fact, in addition to the fact that the technology still has the control controls you know, it can provide access to most aspects of the controls. In fact, the power of the WPF is that the base of any control, such as the programming, is not closed, and this is
what you are going to tell the WPF how to design the text on the control. Or control the background or the sides of it as you would. For this, it also has a lot of tools for designing your controls. Tools such as gradient brushes with unlimited number of colors, a variety of graphical tools to draw your desired shape, create fantastic and diverse effects on any part of the control, pre-defined effects, design options The 2nd and 3rd Dimensions allow you to create animations and many other features you will be familiar with. WPF is based on DirectX. This makes it possible to take advantage of many graphical aspects without creating additional overhead on the program, and in fact create programs with looks that have been created with previous programming or impossible or too much work. Is. Although the strength of this technology is to apply graphic, animation, etc., this does not mean that it is not possible to create forms and controls with the WPF. This technology allows you to use previous controls and also allows WinApp to be programmed in the same way as you know.
In addition, WPF provides you with the ability to work with text documents, control how to print them, and more. Another point to be made about WPF video tutorials is the ability to program in a way that you may have never seen or seen very little, and also programming based on elements in the WPF, which they Page they say. This kind of programming can be called a web application simulation. This type of programming is called WPF Browser Application, which in the following sections will differentiate it from the usual WPF programming. With this programming model, you can display assemblies in a Web browser such as Internet Explorer without any security messages that are commonly found on web pages. For example, the following photo is an example of how to use the page to display websites in a WPF application. Of course, the use of various graphical features, such as those available in WPF applications, is not possible in page-based applications. You will find the reasons for this in future sections.User32, GDI, GDI +, and DirectXIn general, Windows applications use two functions, User32 and GDI / GDI + functions to draw graphic elements that allow User32 to visualize visual elements with normal appearance. Elements such as forms, buttons, ... and GDI / GDI + provide more extensive features for creating graphical elements such as creating gradients and more. Microsoft has created a high-level library called DirectX because of the limitations in each of the two sections. (The letter X can replace words like Sound and so on). This tool, which is also used today (including the creation of 3D games, etc.), utilizing the power of high-end graphics cards, maximizes its power to create powerful graphics. . But with the great power of the library, due to the difficulty of communicating with them and the need for many coding, this tool was used more in the preparation of games and graphic programs, and did not find much space in the expansion of business plans. WPF technology eliminates all of these problems, and in fact frees the user from engaging in writing large, sometimes overwhelming, direct files in DirectX. WPF uses all of DirectX's power to create 2D, 3D graphics, animations. It also provides many tools for designing. In addition, DirectX adapts to the GDI and GDI + ratios as well as the Texture, Gradient, and so forth. Because these technologies are used to render the pixel method and its algorithms, called Pixel By Pixel Instruction. Another problem with working with DirectX was that it was different because of the type of optimization and how to render forms by video cards, which is also solved by WPF.
One of the most important goals of the WPF is to use the GPU instead of the CPU to perform complex graphics routines, which makes the CPU free and can handle other processes in the system. WPF, as a high-level collaborative API, explained earlier, WPF is able to do a lot of work for you, before which it was very difficult and time consuming to write many code. Listed below are some of the features of this technology, along with a brief explanation: Layout components and program elements like Web applications: WPF video tutorials has new elements and many alignment and layout controls and elements on the form. Your app uses. By using these tools that inherit the base class class, you'll be able to set your elements so that your application can be displayed in a variety of resolutions. Note: A professional WPF video tutorials will not even use the properties of the Width and Height objects to arrange them. Certainly, it's unthinkable for you. Because every element you've used in your program has already started to create the right size after naming it. But in the sample of programs and future sections, you will see the least use of these two features. This is due to the nature of the WPF and non-dependence on the display resolution, which will be further described in the next section.
A professional WPF video tutorials will not even use the properties of the Width and Height objects for their layout. Certainly, it's unthinkable for you. Because every element you've used in your program has already started to create the right size after naming it. But in the sample of programs and future sections, you will see the least use of these two features. This is due to the nature of the WPF video tutorials and non-dependence on the display resolution, which will be further described in the next section. A professional WPF programmer will not even use the properties of the Width and Height objects for their layout. Certainly, it's unthinkable for you. Because every element you've used in your program has already started to create the right size after naming it. But in the sample of programs and future sections, you will see the least use of these two features. This is due to the nature of the WPF and non-dependence on the display resolution, which will be further described in the next section.Some of the WPF's features and aspects of the WPF's powerful and powerful design, the WPF video tutorials will get rid of getting involved with pixels and working on them, interacting with high-level objects and forms. It will also be able to create 3D shapes and more. Note: One of the limitations of WPF is to work with three-dimensional shapes. In fact, though, with WPF you can well figure out this type of bug, but in terms of performance, the 3D shapes created with WPF are less efficient than DirectX or OpenGL.
That's why WPF may not be a good choice if you want to write real-time 3D games. Because it may not provide you the performance you expect. In these cases, you can use other environments suitable for such programs.Animation, Sound and Image As explained earlier, in addition to doing a lot of things you can do with shapes like rotate, zoom, zoom, etc., you can also create beautiful animations by WPF You'll also be able to take audio and video files well. Styles and templatesOne of the concerns of Windows programmers has always been to create a beautiful look for its forms and elements. As most developers go to third-party components that we call third party components, they often use them in their applications. Apart from the fact that these components operate in a correct and accountable manner and that they are consistent with the Persian language criteria (which are not the most), I have another reason to not use these types of components, and that is the dependence Your application will be for the objects and elements of other companies.
This can be a source of irreparable damage to programmers in the long run and repeated use of this type of tool. With WPF technology, almost all of these problems are resolved and you can easily create styles and templates that fit your criteria and your schedule.Commands One of the WPF's super-cute and powerful features and features is the use of commands to coordinate various user responses and synchronize various parts of the program, which I will cover in detail. For the time being, I'm so excited to be surprised by the learning and use of this tool, and you will see how much of your program will work with this tool. Page based programs: I talked a bit earlier about this and saw the sample photo of the application that was used on the pages. We will also be more focused on this type of programming. Create user interfaces descriptivelyWhen a name comes from WPF video tutorials technology, it goes on to name XAML. XAML, a descriptive language and XML Based, is used by Visual Studio so you can create your own forms and elements more quickly. I can safely say that the use of XAML will have a dramatic effect on the speed of production of your programs. At first, you may be confused with its use, as long as you want to abandon it and attempt to create a custom interface environment. But with a little effort and control, you'll enjoy working with it, so you never go to coding anywhere you never want !!! (This will not be possible, of course, because you'll need to be coded too) WPF's dependence on resolutionUndoubtedly one of WPF's incredibly useful and strong aspects is its dependence on the screen resolution. If you remember, a little bit ago, I noticed that a professional programmer in WPF video tutorials will not even use Width and Height properties for the layout. You will find the reason for this statement.
Windows applications that are currently being written with existing technologies depend heavily on the screen resolution. For example, your forms, which are well-designed on your screen at a resolution of 1024 x 768, may well be on another computer with a higher resolution (this is very common in laptops), in addition to being Mostly they use a density of 120 DPI, while CRT monitors typically use 96 DPI densities. "Although it can be changed"), and, in contrast, in a low-resolution system, part of your forms will be removed from the screen. But with the WPF, these problems are overcome. The reason is the use of a specific system to measure the elements and elements of your program. Elements, such as buttons, forms, and any measurable object, are measured by a unit called the Device Independent Unit (DIU). Each DIU is equivalent to 1/96 (1 divided by 96) per inch. In fact, it can be said that each DIU on a screen with standard pixel density of 96 DPI is exactly equal to 1 physical pixel on the screen. Now, if the higher DPI is used, naturally, each DIU (at the same previous resolution) will be less than 1 pixel (why?) Now the WPF can measure the DPI at any resolution that is calculated with a specific formula, Calculate you.Note: This collection is in fluent and fluent language and you do not need a very strong English to use it.