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

Julia style with unicode characters #25

Open
mforets opened this issue Sep 8, 2021 · 1 comment
Open

Julia style with unicode characters #25

mforets opened this issue Sep 8, 2021 · 1 comment

Comments

@mforets
Copy link

mforets commented Sep 8, 2021

Hi,

First off, thanks for your work on this great submission template.

I have found that the listings package doesn't like some unicode characters that we use in our Julia library, eg.

\begin{lstlisting}[label=composition, numbers=left, mathescape]
Ω₀ = CH(X₀, Φ*X₀ ⊕ E₊(X₀))
\end{lstlisting}

gives an error.

A workaround is to escape the math commands like this:

\begin{lstlisting}[label=composition, numbers=left, mathescape]
$\Omega_0$ = CH($X_0, \Phi*X_0 \oplus E_+$)
\end{lstlisting}

While this shows the code, I find this is not great because the colors are wrong (all math characters in dollar signs are shown in red).

@mforets
Copy link
Author

mforets commented Sep 8, 2021

Another solution is to add the missing characters to the jlcode.sty style sheet. For example, if I add {⊕}{{\ucc{$\oplus$}}}{1} then such symbol can be used in listings, and it is displayed in the expected color (black). Do you accept that we make modifications to such file?

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

No branches or pull requests

1 participant