CSharp_DevExpress_编辑器自定义;

本文介绍如何在C#中利用DevExpress的TextEdit组件,通过继承并创建CustomEdit类,实现自定义编辑器的功能,同时添加了UseDefaultMode属性以控制编辑器的行为。
摘要由CSDN通过智能技术生成

示例:继承TextEdit类的CustomEdit,对应repository项为RepositoryItemCustomEdit,为新编辑器添加UseDefaultMode属性;


// 编辑器类信息
public EditorClassInfo(
    string name,            // 编辑器名称;
    Type editorType,        // 编辑器类别(类名);
    Type repositoryType,    // 编辑器库类类别(库类名);
    Type viewInfoType,      // ViewInfo类别(可以采用父类类别);
    BaseEditPainter painter,// 编辑器Painter类实例(可用父类Painter来声明其实例);
    bool designTimeVisible, // 容器组件设计时刻是否可见;
    Image image,            // 图标;
    Type accessibleType     // Specifies the type of the object that provides accessibility information.
);

// 编辑器自定义
using System.Drawing;
using System.Reflection;
using System.ComponentModel;
using System.Windows.Forms;
using DevExpress.XtraEditors;
using DevExpress.XtraEditors.Repository;
using DevExpress.XtraEditors.Registrator;
using DevExpress.XtraEditors.Drawing;
using DevExpress.XtraEditors.ViewI
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值