14

There is a problem on the main site with alignment in code blocks that include the dollar sign.

Without $:

Mathematica graphics

With $:

Mathematica graphics

Code is from this post. I will add examples as I find them.

14
  • Can you link to an example of the problem, or give a sample code block that illustrates it (not just a screenshot but something to test with)? Does it happen in the preview as well, or only after saving the edit? Commented Jul 4, 2012 at 16:48
  • Yes, please give actual text, no screenshots. Images aren't helpful for reproducing, let alone fixing, such issues. Commented Jul 4, 2012 at 16:52
  • @balpha sorry, I don't know what I was thinking. I've seen this happen a couple of times but I can only link to the one answer of mine at this time. I'll look for the other instances. Commented Jul 4, 2012 at 16:54
  • That example is enough already, thanks. Reproduced. Commented Jul 4, 2012 at 16:56
  • @balpha okay, great. For reference, is there a way I can search for symbols/strings in a code block? I tried code: but it appears to search strings escaped with backticks rather than indented code blocks. Commented Jul 4, 2012 at 16:58
  • 1
    The reason I couldn't reproduce was that I didn't put in a closing $. It is important to have two $ signs in the example and at least one newline. Thanks for taking a look @balpha! Commented Jul 4, 2012 at 16:58
  • @balpha here's another example where the effect occurs. Look at the code block after the edit. Commented Jul 4, 2012 at 21:28
  • @balpha Any update on this? Commented Sep 27, 2012 at 17:45
  • 1
    This is a currently-unavoidable side-effect of mixing code blocks and MathJax together. Eventually, it should be possible to avoid it, but until then... Commented Feb 15, 2013 at 23:06
  • Another example, in the code block for parseBegin and parseExit. Should we respect the alignment in mardown (so in the future when the bug is fixed, the post will be right automatically), or should we respect the alignment in rendered result? Commented Jun 17, 2013 at 9:43
  • @Silvia I'll leave it to your discretion. I am hoping that "eventually" will be some time soon but it might be years for all I know. Commented Jun 17, 2013 at 10:23
  • Years... OK I think I have to reformat it for good looking.. Commented Jun 17, 2013 at 10:30
  • @Shog9 Any news regarding a fix for this? Commented Aug 26, 2013 at 17:04
  • Is this issue still occurring? If so, could you include more up-to-date reproduction steps, and ping me? Commented Aug 13, 2024 at 18:44

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.