-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMyControl.cs
36 lines (29 loc) · 1022 Bytes
/
MyControl.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
using DevExpress.Utils.Serializing;
using DevExpress.XtraPrinting;
using DevExpress.XtraReports.Localization;
using DevExpress.XtraReports;
using DevExpress.XtraReports.UI;
using System.ComponentModel;
using System.Drawing;
public enum MyEnum { One, Two, Three }
public class MyControl : XRLabel {
public static readonly SizeF InitSizeF = new SizeF(200, 50);
[XtraSerializableProperty,
DefaultValue(true),
Favorite(true),
SRCategory(ReportStringId.CatBehavior)]
public bool BoolProp { get; set; }
[XtraSerializableProperty,
DefaultValue(MyEnum.One)]
public MyEnum EnumProp { get; set; }
[XtraSerializableProperty]
public Item[] ArrayProp { get; set; }
protected override void PutStateToBrick(VisualBrick brick, PrintingSystemBase ps) {
base.PutStateToBrick(brick, ps);
brick.Text = EnumProp.ToString();
}
public class Item {
[XtraSerializableProperty]
public int PropA { get; set; }
}
}