PAT: Process Analysis Toolkit

An Enhanced Simulator, Model Checker and Refinement Checker for Concurrent and Real-time Systems

Display of the current enabled events is fixed.

We found a bug in ListView Control of .NET Framework for the forecolor and backcolor display of sub-items.
The following code samples provide the solution to fix them.

ListView_EnabledEvents.OwnerDraw = true;
ListView_EnabledEvents.DrawItem += new DrawListViewItemEventHandler(ListView_EnabledEvents_DrawItem);
ListView_EnabledEvents.DrawColumnHeader += new DrawListViewColumnHeaderEventHandler(ListView_EnabledEvents_DrawColumnHeader);

private void ListView_EnabledEvents_DrawColumnHeader(object sender, DrawListViewColumnHeaderEventArgs e)
e.Graphics.FillRectangle(Brushes.GreenYellow, e.Bounds);
e.DrawDefault = true;

private void ListView_EnabledEvents_DrawItem(object sender, DrawListViewItemEventArgs e)
Rectangle foo = e.Bounds;
foo.Offset(-10, 0);
e.Graphics.FillRectangle(new SolidBrush(e.Item.BackColor), foo);
e.DrawDefault = true;