Ay.Framework.WPF 2.0 how fast to build a project

Source: Internet
Author: User

2015-3-31 Today I have optimized a lot of places, so that customers use almost fool-style use, nonsense say, let's start.

The default I provide some pictures, but also only occupy more than 8M, 2.0 version currently has a total of about 45M size, after all, including Fontawesome font package, and Cefsharp

For example, Ay.Framework.WPF.dll also only 935K size, or relatively small

① New WPF Application project

Then copy the Ay.framework.wpf.2.0.zip into the project and unzip

Add a reference and set the x64 bit platform

Configuration can be replaced with release, here casually you, of course, development time with the 32-bit version, because the XAML visual interface needs 32 bits, of course I will provide 32-bit and 64-bit two versions, 64-bit performance better point.

Next build the project, see if the error

Turn App.xaml switch off to shutdownmode= "Onexplicitshutdown"

Open App.xaml.cs Rewrite Onstartup method, we set the unified theme, here the name, for example, default is based on Ay.Framework.WPF themes under the decision, you this in the corresponding folder in the XAML to write a different style is OK

1234567891011121314151617181920212223 using System;using System.Collections.Generic;using System.Configuration;using System.Data;using System.Linq;using System.Threading.Tasks;using System.Windows;using Ay.Framework.WPF.Controls;namespace AyFrameworkDemo{    /// <summary>    /// App.xaml 的交互逻辑    /// </summary>    public partial class App : Application    {        protected override void OnStartup(StartupEventArgs e)        {            Application.Current.ApplyTheme("Default");            base.OnStartup(e);        }    }}

Ok, the use of the first Demo,ayfontbutton

If you want to use it, the first step in XAML must be to introduce space

Xmlns:skin= "CLR-NAMESPACE:AY.FRAMEWORK.WPF.CONTROLS;ASSEMBLY=AY.FRAMEWORK.WPF"

Then use

12345678910111213 <Windowx:Class="AyFrameworkDemo.MainWindow"        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"        xmlns:skin="clr-namespace:Ay.Framework.WPF.Controls;assembly=Ay.Framework.WPF"        Title="MainWindow"Height="350"Width="525">    <Grid>        <skin:AyFontButtonToolTip="我是带图标的按钮"Width="90"FontAwesome="&#xf1cb;"Height="25"                           VerticalAlignment="Center"HorizontalAlignment="center"x:Name="btnSelect3dModel">            模型按钮        </skin:AyFontButton>    </Grid></Window>

In order to use Aywindow, due to the configuration of the background picture, you need to copy the folder structure of ay.framework.wpf.2.0 to the solution or output directory, the solution, you need to set the file can be copied to the output directory

This is a font button, that is, the use of fontawesome, you only need to specify an icon, specify a word, animation full.

OK, then show the most overbearing Aywindow.

You only need to inherit aywindow from the background window, and then in XAML, the window of the foreground is replaced with Skin:aywindow, where the skin is the alias you specify.

Then you need to introduce four libraries of expression provided

OK, come on, run the project.

We click on the small dress icon

Of course, here for the background, is automatically all open, inherit aywindow window Auto-skin, and record the record, next open window or this background image

Animated presentation

With 24 animation effects, open the output directory, here is the release folder under the Ayconfig folder under the Application.xml

Modify the value of the Skinswitchanimation property to 22, modify, save, and then double-click on the EXE program to open

For example 24

More animations don't show up.

Demonstrate browser Control usage

1    <skin:AyBrowserx:Name="cwb"Address="http://www.ayjs.net"/>

Effect Demo:

Of course, this browser is Google 37 kernel, of course, the display of a partial page is still very good, such as a Baidu map location

About the more Aytabcontrol more bull, here do not demonstrate, just to illustrate a point, Ay.Framework.WPF used very simple.

Thank you for reading

Ay.Framework.WPF 2.0 how fast to build a project

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.