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

`lookForAlignDelims` and `tabbing`? #187

Closed
anyong opened this issue Feb 6, 2020 · 7 comments
Closed

`lookForAlignDelims` and `tabbing`? #187

anyong opened this issue Feb 6, 2020 · 7 comments

Comments

@anyong
Copy link

@anyong anyong commented Feb 6, 2020

According to listing 13, we should be able to add the tabbing environment to lookForAlignDelims. However, tabbing uses \= and \> for alignment, while lookForAlignDelims seems to only recognize &.

Is this a typo in the docs, or is there some other command I missed to align my tabbing delimeters \= and \>?

@cmhughes

This comment has been minimized.

Copy link
Owner

@cmhughes cmhughes commented Feb 6, 2020

@anyong

This comment has been minimized.

Copy link
Author

@anyong anyong commented Feb 6, 2020

Basically exactly the same as the alignment based on &, but in tabbing the first line has \= to set tabstops and subsequent lines use \> to align tabs. Here's an example of what I'd like it to accomplish?

Before:

\begin{tabbing}
    Tone \= 1 changes to Tone \= 7 \qquad Tone \= 5 changes to Tone \= 7 \\
    \> 2 \> 1 \> 7 \> 3 \\
    \> 3 \> 2 \> 8 \> 3 \\
    \> 4 \> 2 \\
\end{tabbing}

After:

\begin{tabbing}
    Tone \= 1 changes to Tone \= 7 \qquad Tone \= 5 changes to Tone \= 7 \\
         \> 2                 \> 1             \> 7                 \> 3 \\
         \> 3                 \> 2             \> 8                 \> 3 \\
         \> 4                 \> 2                                       \\
\end{tabbing}

image

@cmhughes

This comment has been minimized.

Copy link
Owner

@cmhughes cmhughes commented Feb 6, 2020

That's great, thanks. Should be doable, but there's a few ahead of this. I'll let you know when I have an update, but it may well be a while.

@cmhughes

This comment has been minimized.

Copy link
Owner

@cmhughes cmhughes commented Feb 13, 2020

This feature could be interesting for bibliography entries also:

@Article{a-key,
  author    = {Person One},
  title     = {A demo in lowercase},
  journal   = {Journal of Irreproducible Results},
  year      = {2020}
}
@cmhughes

This comment has been minimized.

Copy link
Owner

@cmhughes cmhughes commented Mar 14, 2020

As of e4495d4 this is implemented in the develop branch, and documented.

If you'd like to clone the develop branch, you should be able to test it. For your example, you might like the following YAML:

lookForAlignDelims:
   tabbing: 
    delimiterRegEx: '(\\(?:=|>))'

Thanks for suggesting this!

@cmhughes

This comment has been minimized.

Copy link
Owner

@cmhughes cmhughes commented Mar 21, 2020

demonstration

Starting with

\begin{tabbing}
aa \=
bb \= cc \= dd \= ee \\
\>2\> 1 \> 7 \> 3 \\
\>3 \> 2\>8\> 3 \\
\>4 \>2 \\
\end{tabbing}

and the YAML

lookForAlignDelims:
   tabbing:
   delimiterRegEx: '(\\(?:=|>))'

gives

\begin{tabbing}
	aa \= bb \= cc \= dd \= ee \\
	   \> 2  \> 1  \> 7  \> 3  \\
	   \> 3  \> 2  \> 8  \> 3  \\
	   \> 4  \> 2              \\
\end{tabbing}
@cmhughes

This comment has been minimized.

Copy link
Owner

@cmhughes cmhughes commented Mar 21, 2020

Implemented in Version 3.8, #190

@cmhughes cmhughes closed this Mar 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.