forked from DebugST/STTextBox
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSTTextBoxCaretInfo.cs
More file actions
53 lines (48 loc) · 1.2 KB
/
STTextBoxCaretInfo.cs
File metadata and controls
53 lines (48 loc) · 1.2 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
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Drawing;
namespace ST.Library.UI.STTextBox
{
public class STTextBoxCaretInfo
{
private int _X;
public int X {
get { return _X; }
internal set {
_X = value;
}
}
private int _Y;
public int Y {
get { return _Y; }
internal set {
_Y = value;
}
}
private int _Width = 1;
public int Width {
get { return _Width; }
set { _Width = value; }
}
public bool Visable;
public int IndexOfLine;
public int IndexOfChar;
public TextLine Line;
public Point Location {
get { return new Point(X, Y); }
}
public bool CopyFromFindInfo(FindInfo fi) {
if (!fi.Find) {
return false;
}
this._X = fi.Location.X;
this._Y = fi.Location.Y;
this.IndexOfChar = fi.IndexOfChar;
this.IndexOfLine = fi.IndexOfLine;
this.Line = fi.Line;
return true;
}
}
}