-
When I set the ForeColor property, but the color of the rectangle box did not change. |
Beta Was this translation helpful? Give feedback.
Answered by
RussKie
Feb 22, 2021
Replies: 1 comment 1 reply
-
You can't. All rendering is done in |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
RussKie
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can't.
CheckedListBox
is essentially aListBox
control withListBox.DrawMode = OwnerDrawFixed
and custom drawn items. If you want custom checkboxes you would need to render those manually similarly to how it is done inCheckedListBox
.All rendering is done in
OnDrawItem
, including drawing checkboxes, background and text:winforms/src/System.Windows.Forms/src/System/Windows/Forms/CheckedListBox.cs
Line 519 in a6e8118