TODO features:
V Cursor for rectangular selection tool V Icons for tool buttons V Tooltips now has keyboard shortcuts info V Fix selection info: change comma to x
This commit is contained in:
@@ -4,6 +4,7 @@ using System.Drawing;
|
||||
using System.Drawing.Drawing2D;
|
||||
using System.Drawing.Imaging;
|
||||
using System.Linq;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
@@ -101,5 +102,30 @@ namespace McBitFont {
|
||||
return CreateCursorNoResize(bmp, cellSize / 2, cellSize / 2);
|
||||
}
|
||||
|
||||
public static Cursor GetCursorSelect() {
|
||||
Point[] arrow = { new(1, 1), new(12, 12), new(11, 13), new(6, 13), new(2, 17), new(1, 16) };
|
||||
Point[] corner1 = { new(13, 6), new(20, 6), new(20, 13), new(17, 13), new(17, 9), new(13, 9) };
|
||||
Point[] corner2 = { new(17, 16), new(20, 16), new(20, 23), new(13, 23), new(13, 20), new(17, 20) };
|
||||
Point[] corner3 = { new(3, 16), new(6, 16), new(6, 20), new(10, 20), new(10, 23), new(3, 23) };
|
||||
Point[] corner4 = { new(6, 6), new(10, 6), new(10, 9), new(6, 9) };
|
||||
|
||||
Bitmap bmp = new(21, 24);
|
||||
Pen pb = new(Color.Black, 1);
|
||||
SolidBrush bw = new (Color.White);
|
||||
using (Graphics g = Graphics.FromImage(bmp)) {
|
||||
g.FillPolygon(bw, corner1);
|
||||
g.DrawPolygon(pb, corner1);
|
||||
g.FillPolygon(bw, corner2);
|
||||
g.DrawPolygon(pb, corner2);
|
||||
g.FillPolygon(bw, corner3);
|
||||
g.DrawPolygon(pb, corner3);
|
||||
g.FillPolygon(bw, corner4);
|
||||
g.DrawPolygon(pb, corner4);
|
||||
g.FillPolygon(bw, arrow);
|
||||
g.DrawPolygon(pb, arrow);
|
||||
}
|
||||
return CreateCursorNoResize(bmp, 1, 1);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user