Opened 9 months ago

Closed 9 months ago

Last modified 9 months ago

#15741 closed defect (fixed)

Generic wxListctrl incorrectly sets foreground colour of header creating poor contrast

Reported by: matthew.ault Owned by:
Priority: normal Milestone:
Component: GUI-generic Version: 2.9.3
Keywords: wxListCtrl colour color header Cc:
Blocked By: Blocking:
Patch: yes

Description

Generic wxListctrl and msw wxListCtrl differ in their behaviour when SetForegroundColour is called.

The generic wxListCtrl sets the foreground colour of the header area whereas the msw implementation does not. In the generic implementation this can result in poor contrast seen as SetBackgroundColour does not change the background colour of the header.

Attached patch and script to replicate.

Attachments (2)

wx_list_ctrl_colour.patch download (363 bytes) - added by matthew.ault 9 months ago.
bug fix patch
wxListCtrlDemo.py download (860 bytes) - added by matthew.ault 9 months ago.
Demo that can be used to recreate bug

Download all attachments as: .zip

Change History (4)

Changed 9 months ago by matthew.ault

bug fix patch

Changed 9 months ago by matthew.ault

Demo that can be used to recreate bug

comment:1 Changed 9 months ago by VZ

  • Resolution set to fixed
  • Status changed from new to closed

(In [75325]) Don't change header window foreground colour in wxGenericListCtrl.

As calling wxGenericListCtrl::SetBackgroundColour() doesn't change the header
window background, don't change its foreground in SetForegroundColour()
neither.

Closes #15741.

comment:2 Changed 9 months ago by VZ

(In [75327]) Don't change header window foreground colour in wxGenericListCtrl.

As calling wxGenericListCtrl::SetBackgroundColour() doesn't change the header
window background, don't change its foreground in SetForegroundColour()
neither.

Closes #15741.

Note: See TracTickets for help on using tickets.