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

Can't escape multiple dollar signs in a markdown cell #3197

Closed
Paradosso opened this issue Apr 18, 2013 · 7 comments
Closed

Can't escape multiple dollar signs in a markdown cell #3197

Paradosso opened this issue Apr 18, 2013 · 7 comments
Milestone

Comments

@Paradosso
Copy link

I have a markdown cell in iPython that contains four dollar signs. iPython interprets anything between dollar signs as a MathJax expression, which is not what I want. How do I escape the dollar signs? Escaping them with a backslash prevents MathJax from kicking in, but the backslash shows in the compiled Markdown.

@minrk
Copy link
Member

minrk commented Apr 18, 2013

This is pretty tricky - I guess this is the reason that Mathjax specifically recommends against using $ as the delimiter, which IPython uses. I can't figure out a way to get multiple plain text text dollar signs as it is, so the best I have come up with after a bit of fiddling is $\$\$\$\$$, which will give you dollar signs in the mathjax font.

@minrk
Copy link
Member

minrk commented Jun 19, 2013

fixed by #3428

@minrk minrk closed this as completed Jun 19, 2013
@fonnesbeck
Copy link

This is still an issue when you have multiple dollar signs that are not consecutive (i.e. in different parts of a sentence. For example, the following:

Several starting pitchers have signed or been extended this offseason, and those who would be expected to provide similar value to Jimenez commanded contracts of $$$10-13M per year for contracts ranging from one year (Colon) to four (Garza). A 2-year contract in the range of $$$12-14M annually would be on the higher end of market value, yet cap the total risk to the team below $$$30M. Moreover, the length of the contract might incentivize the player to play for another contract in the near future.

gets rendered as:

dollar signs

In other words, works fine for the first dollar sign, or multiple in the same MathJax expression, but gets confused at multiple separate ones.

@minrk
Copy link
Member

minrk commented Feb 7, 2014

@fonnesbeck the example you gave is working correctly in master. What version are you using?

@fonnesbeck
Copy link

Mine is from master no more than 2 weeks old (__version__ just says says '2.0.0-dev'). I will update again.

@fonnesbeck
Copy link

Just updated from master now, and I get the same thing. Configuration issue?

@Carreau
Copy link
Member

Carreau commented Feb 8, 2014

Huh... depend if I copy your raw comment or if I copy the rendered thing on github.

The one with Dollar-BackSlash-Dollar works for me, the Dollar-BackSlash-BackSlash-Dollar Do not.
capture decran 2014-02-08 a 23 14 27
capture decran 2014-02-08 a 23 14 35

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

4 participants