From 56cb9c01a5212fbba757cf6d42b751c5df94b7a7 Mon Sep 17 00:00:00 2001 From: Tim Allen Date: Sat, 11 Nov 2017 18:22:08 +1100 Subject: [PATCH] Hack around some code-block formatting errors. By default, mkdocs uses "highlight.js" to apply syntax-highlighting to code blocks. Left to its own devices, highlight.js will guess the language being used in the code block, apply the "hljs" CSS class (so the code block will be given a nice border, a sensible font-size, etc.) and apply the appropriate formatting markup. If it guesses wrongly, you can give a language hint on the opening line of the block. If you use a language that highlight.js does not recognise, or the special name "nohighlight", highlight.js will leave the block alone. Unfortunately, in mkdocs' default theme, that means it will be formatted like *inline* code, with a border and background that wraps behind each line of the block. In order to make a code-block that looks like a code-block, you have to carefully pick a language that highlight.js has heard of, but whose syntax is sufficiently different from whatever's in the block that no unwanted highlighting will occur. This seems to be fixed in the readthedocs theme that comes with mkdocs 0.16.1, but ReadTheDocs doesn't actually seem to be using that version. :/ --- docs/concepts/game-folders.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/concepts/game-folders.md b/docs/concepts/game-folders.md index b9e5dd7b..d20ebb9b 100644 --- a/docs/concepts/game-folders.md +++ b/docs/concepts/game-folders.md @@ -8,7 +8,7 @@ higan would create a game folder named `dkc3.sfc`, and inside it store the game data as `program.rom` and the save data as `save.ram`: -```text +```python +- Super Famicom | +- dkc3.sfc @@ -27,7 +27,7 @@ For example, if another emulator loaded the game `dkc3.sfc` it might store the save data in `dkc3.srm`: -```text +```python +- Super Famicom | +- dkc3.sfc