【发布时间】:2013-11-22 08:07:03
【问题描述】:
我正在使用Graphics 绘制一个矩形:
// x and y are arbitrary integers or floats. Doesn't matter!
Graphics.FillRectangle(Brushes.Black, x, y, 5, 5);
这会产生一个带有 antialiased 边框的黑色矩形。 如何在绘制矩形时禁用抗锯齿功能?
以下不起作用:
Graphics.SmoothingMode = SmoothingMode.HighSpeed;
Graphics.TextRenderingHint = TextRenderingHint.SingleBitPerPixelGridFit;
【问题讨论】: