Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow reinitialization of font lock regexps #145

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

exot
Copy link

@exot exot commented Jul 3, 2021

In plantuml-mode, initialization of the font locking regular expressions is
done by asking the current version of plantuml for its supported keywords,
builtins, etc. Every so often, this might fail for any reason, leaving the
current Emacs session with invalid font lock information for plantuml. Redoing
the initialization process is tedious, as the corresponding function
plantuml-init-once does not allow for that to be done easily (one would have
to undefine a lot of global variables to do so).

This commit introduces a force parameter for plantuml-init-once to conduct
reinitialization of all font lock information. It also moves regular
expressions meant for indentation out of plantuml-init-once, as those are
initialized by literal values that do not depend on any runtime information.

In `plantuml-mode`, initialization of the font locking regular expressions is
done by asking the current version of plantuml for its supported keywords,
builtins, etc.  Every so often, this might fail for any reason, leaving the
current Emacs session with invalid font lock information for plantuml.  Redoing
the initialization process is tedious, as the corresponding function
`plantuml-init-once` does not allow for that to be done easily (one would have
to undefine a lot of global variables to do so).

This commit introduces a force parameter for `plantuml-init-once` to conduct
reinitialization of all font lock information.  It also moves regular
expressions meant for indentation out of `plantuml-init-once`, as those are
initialized by literal values that do not depend on any runtime information.
@stale
Copy link

stale bot commented Apr 16, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Apr 16, 2022
@exot
Copy link
Author

exot commented Apr 16, 2022

Bump to make stale-bot happy.

@stale stale bot removed the wontfix label Apr 16, 2022
@stale
Copy link

stale bot commented Sep 21, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Sep 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant