Reuse the platform syntax colors in the Ant editor - #2920
Merged
vogella merged 1 commit intoSep 15, 2026
Merged
Conversation
vogella
force-pushed
the
vogella/shared-markup-colors
branch
from
September 10, 2026 20:54
c7fee4b to
212a431
Compare
Contributor
vogella
force-pushed
the
vogella/shared-markup-colors
branch
2 times, most recently
from
September 14, 2026 08:46
06c1833 to
7342ee8
Compare
vogella
marked this pull request as ready for review
September 14, 2026 13:43
Contributor
Author
vogella
force-pushed
the
vogella/shared-markup-colors
branch
2 times, most recently
from
September 14, 2026 14:40
c55b216 to
403018f
Compare
The Ant editor kept its own syntax colors in the Ant preference store, with a Syntax tab on the Ant > Editor preference page, per token bold and italic flags and a dark palette of its own. It now reads the shared colors that org.eclipse.ui.editors provides, so all editors are configured in one place, under Colors and Fonts. Attribute names get the shared attribute name color instead of the tag color, as in the other XML editors. The Syntax tab and the per token font styles are gone, unstyled text follows the editor foreground color, and existing customizations of the old Ant keys are not migrated. Colors come from the theme color registry rather than the preference store, because a non default theme prefixes the preference key with the theme id. The workbench store is chained into the Ant one so that the editor still repaints when a theme color changes. Contributes to eclipse-platform/eclipse.platform.ui#4291 Assisted-by: multiple AI agents and layers of automated tooling 🤖
vogella
force-pushed
the
vogella/shared-markup-colors
branch
from
September 14, 2026 16:15
403018f to
83835c4
Compare
Contributor
Author
|
This also fixes an existing DataFormatException during theme switch, if an Ant editor is open during that switch as it removes the extra logic with the error. To test, open Ant editor and afterwards switch from light to dark or vice versa. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


The Ant editor kept its syntax colors in the Ant preference store, with a Syntax tab on the Ant > Editor preference page, per token bold and italic flags and a dark palette of its own. It now reads the shared colors from eclipse-platform/eclipse.platform.ui#4372, which removes about 600 lines and puts Ant under the same "Syntax coloring" entry as the other editors. Attribute names now get the shared attribute name color, as in the PDE XML editors.
Worth review attention: the Syntax tab and the per token font styles are gone, the XML declaration and the DTD now share the one directive color instead of two, unstyled text follows the editor foreground color, and old Ant customizations are not migrated. Colors come from the theme color registry rather than the preference store, because a non default theme prefixes the preference key with the theme id and a lookup by bare id would silently miss it.