Skip to content
This repository was archived by the owner on Feb 7, 2026. It is now read-only.

Dispel magic! - #8

Merged
eristhea merged 9 commits into
QuiltMC:mainfrom
supersaiyansubtlety:dispel-magic
Nov 18, 2025
Merged

eristhea merged 9 commits into
QuiltMC:mainfrom
supersaiyansubtlety:dispel-magic

Conversation

@supersaiyansubtlety

@supersaiyansubtlety supersaiyansubtlety commented Oct 20, 2025 •

Copy link
Copy Markdown
Member

This PR eliminates automatic installation of components and listeners and generally tries to reduce the amount of "magical" side-effects-based behavior.

This makes things more customizable and easier to follow.

Can be tested by publishing locally and checking out QuiltMC/enigma#317


Remaining magic:

  • JavaLexer: it's generated by jflex; that's just fundamentally how it works
  • JavaSyntaxKit is still installed to make editors use SyntaxViews and SyntaxDocuments;
    AFAICT there's no way to manually attach a different ViewFactory to an editor without completely replacing its TextUI which would also replace all the functionality of the UI installed by flatlaf.

Also:

  • allows offsetting LineNumbersRuler's numbers (for use in tooltip snippets)
  • removes a few instances of setting colors and fonts in favor of setting them in enigma
  • removes SyntaxpainConfiguration but adds JavaSyntaxKit::setSyntaxColors for SyntaxStyle; keeping this is necessary because JavaSyntaxKit is still magical
  • removes a couple classes that were only necessary for magic or whose functionality made sense to move to other classes

@eristhea
eristhea self-requested a review October 26, 2025 17:52
@eristhea eristhea added the enhancement New feature or request label Nov 15, 2025

@eristhea eristhea left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good! super impressed at how much code you could throw out. we definitely need to do a javadoc pass when we move this into enigma lol

@eristhea
eristhea merged commit 9e04caf into QuiltMC:main Nov 18, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants