Skip to content

Conversation

@DevCharly
Copy link
Collaborator

This PR enables full styling indeterminate state of tri-state check boxes (issue #919).
See check box icons in red rectangles (left is FlatLightLaf, right is FlatIntelliJLaf):

image

There are a lot of new UI properties to do this. See source code of FlatCheckBoxIcon in this PR.

Samples

Change blue border to gray:

CheckBox.icon.indeterminateBorderColor = $CheckBox.icon.borderColor

image

Also change blue indeterminate checkmark to gray:

CheckBox.icon.indeterminateBorderColor = $CheckBox.icon.borderColor
CheckBox.icon.indeterminateCheckmarkColor = $CheckBox.icon.disabledCheckmarkColor

image

Use white background for FlatIntelliJLaf:

CheckBox.icon[filled].indeterminateBackground = $CheckBox.icon.background
CheckBox.icon[filled].focusedIndeterminateBackground = $CheckBox.icon.background
CheckBox.icon[filled].indeterminateCheckmarkColor = $CheckBox.icon.checkmarkColor

image

Theme Editor

Above screenshots are made with FlatLaf Theme Editor.

image

@DevCharly DevCharly added this to the 3.6 milestone Dec 11, 2024
@DevCharly DevCharly merged commit a3a49ce into main Dec 18, 2024
8 checks passed
@DevCharly DevCharly deleted the checkbox-indeterminate-styling branch December 18, 2024 11:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants