Code Monkey home page Code Monkey logo

directui's Introduction

DirectUI

  • DirectUI 是什么 百度百科:DirectUI意为直接在父窗口上绘图(Paint on parent dc directly)。即子窗口不以窗口句柄的形式创建(windowless),只是逻辑上的窗口,绘制在父窗口之上。微软的“DirectUI”技术广泛的应用于Windows XP,Vista,Windows 7,如浏览器左侧的TaskPanel,控制面板导航界面,Media Player播放器,即时通讯工具MSN Messager等。 DirectUI好处在于可以很方便的构建高效,绚丽的,非常易于扩展的界面。国外如微软,国内如腾讯,百度等公司的客户端产品多采用这种方式来组织界面,从而很好的将界面和逻辑分离,同时易于实现各种超炫的界面效果如换色,换肤,透明等。 DirectUI 旨在满足客户端界面快速开发的需要,同时融入业界前沿的皮肤技术,为用户创建更加高效,专业的界面。
  • 我的DirectUI可以做什么? 当前的DirectUI库是基于directUI的基本**,再组合上winform的原生控件构建方式然后封装Direct2D为GDI+的调用方式。只实现了基础控件DUIControl(控件类)、DUIEditableControl(可编辑组件)、DUIScaleableControl(可缩放组件)、DUIScrollableControl(可滚动组件)这四大类组件的封装。只要你有winform和GDI+的基础就可以轻易的驾驭这个库
  • 简单的构建代码如下:
DUINativeControl dUINativeControl = new DUINativeControl() { Dock = DockStyle.Fill };
DUIControl dUIControl = new DUIControl();
public Form1()
{
    InitializeComponent();
    this.Controls.Add(dUINativeControl);
    dUINativeControl.DUIControls.Add(dUIControl);
    dUIControl.Paint += (s, e) =>
    {
        e.Graphics.DrawString("随便写点", dUIControl.Font, DUIBrushes.Red, PointF.Empty);
    };
}

简直和写Winform一毛一样有木有,就连调用Direct2d也像操作GDI+一样是不是?

演示

  • DUIControl

avatar

  • DUIEditableControl

avatar

  • DUIScaleableControl

avatar

  • DUIScrollableControl

avatar

  • Cubes

avatar

directui's People

Contributors

jim-jiang-github avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.