forked from ahyahy/OneScriptForms
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathHatchBrush.cs
More file actions
61 lines (53 loc) · 1.95 KB
/
HatchBrush.cs
File metadata and controls
61 lines (53 loc) · 1.95 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
using ScriptEngine.Machine.Contexts;
namespace osf
{
public class HatchBrush : Brush
{
public ClHatchBrush dll_obj;
public System.Drawing.Drawing2D.HatchBrush M_HatchBrush;
public HatchBrush(int hatchStyle, osf.Color foreColor, osf.Color backColor = null)
{
if (backColor != null)
{
M_HatchBrush = new System.Drawing.Drawing2D.HatchBrush((System.Drawing.Drawing2D.HatchStyle)hatchStyle, foreColor.M_Color, backColor.M_Color);
base.M_Brush = M_HatchBrush;
OneScriptForms.AddToHashtable(M_HatchBrush, this);
}
else
{
M_HatchBrush = new System.Drawing.Drawing2D.HatchBrush((System.Drawing.Drawing2D.HatchStyle)hatchStyle, foreColor.M_Color);
base.M_Brush = M_HatchBrush;
OneScriptForms.AddToHashtable(M_HatchBrush, this);
}
}
public HatchBrush(osf.HatchBrush p1)
{
M_HatchBrush = p1.M_HatchBrush;
base.M_Brush = M_HatchBrush;
OneScriptForms.AddToHashtable(M_HatchBrush, this);
}
public HatchBrush(System.Drawing.Drawing2D.HatchBrush p1)
{
M_HatchBrush = p1;
base.M_Brush = M_HatchBrush;
OneScriptForms.AddToHashtable(M_HatchBrush, this);
}
}
[ContextClass ("КлПрямоугольнаяКисть", "ClHatchBrush")]
public class ClHatchBrush : AutoContext<ClHatchBrush>
{
public ClHatchBrush(int p1, osf.Color p2, osf.Color p3 = null)
{
HatchBrush HatchBrush1 = new HatchBrush(p1, p2, p3);
HatchBrush1.dll_obj = this;
Base_obj = HatchBrush1;
}
public ClHatchBrush(HatchBrush p1)
{
HatchBrush HatchBrush1 = p1;
HatchBrush1.dll_obj = this;
Base_obj = HatchBrush1;
}
public HatchBrush Base_obj;
}
}