我正在制作一个 cosmos os 项目并想做一个鼠标光标,但它在运行前继续崩溃
canvas = FullScreenCanvas.GetFullScreenCanvas();
canvas.Clear(System.Drawing.Color.Aqua);
Sys.MouseManager.ScreenWidth = (uint)canvas.Mode.Columns;
Sys.MouseManager.ScreenHeight = (uint)canvas.Mode.Rows;
Pen pen = new Pen(System.Drawing.Color.Red);
uint X = Sys.MouseManager.X;
uint Y = Sys.MouseManager.Y;
canvas.DrawLine(pen, X, Y, X + 5, Y);
canvas.DrawLine(pen, X, Y, X, Y - 5);
canvas.DrawLine(pen, X, Y, X + 5, Y - 5);
}
我希望它能够运行并有一个光标,但它在运行之前就崩溃了