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

Multi-author support for fixme package #2503

Open
lambtho12 opened this issue Sep 28, 2022 · 0 comments
Open

Multi-author support for fixme package #2503

lambtho12 opened this issue Sep 28, 2022 · 0 comments

Comments

@lambtho12
Copy link

Related features requests: #2494, #2497 and #1770

Context

The fixme package provides support for multiple authors. With that feature, fixme allows to register variations of the base commands and environments using a different prefix for each author.

This is done by declaring the author with

% \FXRegisterAuthor{<cmdPrefix>}{<envPrefix>}{<initials>}
\FXRegisterAuthor{jd}{ajd}{JD} % For John Doe

This will then automatically create the commands \jdnote, \jdwarning, etc. and the environments ajdnote, ajdwarning, etc. (see #2494 (comment) for the complete list of comments/environments). This will also work for the starred version of the commands and environments.

Feature

Vimtex already parses the file and put all the fixmebase commands in the TOC (#1770). It can also recognize them and highlight the base commands in the text (#2494) and in the TOC (#2497).

The final step to support fully all features of the fixme package would to detect the commands related to the custom authors, highlight them properly and list them in vimtex TOC as well.

However, I am not sure what would be the optimal solution to achieve that.

  1. Making a regex that detect \<initial>note , \<initial>error, etc. will work every time but will also cause lots of false positive.
  2. Parsing the preamble and look for the \FXRegisterAuthor to detect the initials on-the-fly on a per-document basis. This is probably the most robust and elegant way, but is this even possible? Wouldn't it introduce some overhead?
  3. Adding a vimtex option so the user can tell vimtex which initials to look for will work as well. This could get out of hand quickly if the user has lot of documents with lots of different authors. But I also feel this is the most reasonable option.
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