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

Font lock module qualification differently #1157

Closed
gracjan opened this issue Feb 13, 2016 · 2 comments
Closed

Font lock module qualification differently #1157

gracjan opened this issue Feb 13, 2016 · 2 comments

Comments

@gracjan
Copy link
Contributor

gracjan commented Feb 13, 2016

Currently we can recognize tokens that are qualified by module path. For example:

Control.Monad.>>=
Data.List.sort
Data.Map.Map
Data.HList.:~:
Control.Category..

We have a regexp that knows about module prefix and the unqualified part. It means that we can highlight differently the parts:

  1. The module names.
  2. The dots that are module separators (last dot can be different if we care).
  3. The unqualified identifier, constructor or symbol.

Note that we do good job of differentiating the dot operator even if it is qualified.

Note2: Unicode prettification composition could be built in in this mechanism so that it is done in the same pass.

@gracjan
Copy link
Contributor Author

gracjan commented Feb 13, 2016

Related: #725.

@gracjan
Copy link
Contributor Author

gracjan commented Feb 15, 2016

So the pull request highlight whole qualified name in the same way as unqualified name would be highlighted. Much less visual noise and I like it that way much better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant