高级会员

- 积分
- 561
- 金钱
- 561
- 注册时间
- 2017-8-29
- 在线时间
- 89 小时
|

楼主 |
发表于 2018-1-5 13:27:06
|
显示全部楼层
测试环境:"探索者开发板"
随意一个emWin测试程序中,将GUIDRV_Template.c文件中static void _FillRect(GUI_DEVICE * pDevice, int x0, int y0, int x1, int y1) 修改如下(参考STemWin源码修改):
static void _FillRect(GUI_DEVICE * pDevice, int x0, int y0, int x1, int y1)
{
LCD_PIXELINDEX PixelIndex;
int x;
PixelIndex = LCD__GetColorIndex();
if (GUI_pContext->DrawMode & LCD_DRAWMODE_XOR)
{
for (; y0 <= y1; y0++)
{
for (x = x0; x <= x1; x++)
{
_XorPixel(pDevice, x, y0);
}
}
}
else
{
for (; y0 <= y1; y0++) {
for (x = x0; x <= x1; x++) {
_SetPixelIndex(pDevice, x, y0, PixelIndex);
}
}
}
// LCD_Fill(x0, y0, x1, y1, LCD_COLORINDEX);
}
之后光标就可以闪烁,为什么原子使用LCD_Fill(...)函数导致光标不闪烁的问题就不知道了! |
|