Re: [sphinx-users] Unselectable code-block prompt

2021-09-14 Thread Slavko
Ahoj, Dňa Wed, 15 Sep 2021 00:36:26 +0900 Komiya Takeshi napísal: > On the other hand, in bash's case, it can't recognizes "$" as a > prompt. So there is no special styles on the output. > > $ echo '$ A prompt' | pygmentize -l bash -f html > $ A prompt > > > So some contribution would be need

Re: [sphinx-users] Unselectable code-block prompt

2021-09-14 Thread Komiya Takeshi
In python's case, the pygmentize command (CLI of pygments) recognizes ">>>" as a prompt and gives style to it. $ echo '>>> A prompt' | pygmentize -l python -f html >>> A prompt On the other hand, in bash's case, it can't recognizes "$" as a prompt. So there is no special styles on the output.

Re: [sphinx-users] Unselectable code-block prompt

2021-09-14 Thread Ron Stone
Thanks again. That sounds simple enough from a user perspective. With: .. code-block:: bash $ A prompt? The '$' should be unelectable in the output, but this is pasted from the html: $ A prompt? I am using 4.2 On Tuesday, September 14, 2021 at 10:54:56 AM UTC-4 i.tk...@gmail.com wrote: >

Re: [sphinx-users] Unselectable code-block prompt

2021-09-14 Thread Komiya Takeshi
Ah, sorry. I had to describe that. We use highlighting library pygments to detect prompts. It can parse the code-block and can recognize the kind of each token. 2021年9月14日(火) 23:22 Ron Stone : > > Thanks, but I am still missing something here. How does the system > distinguish between a prompt an

Re: [sphinx-users] Unselectable code-block prompt

2021-09-14 Thread Komiya Takeshi
Hi, >Can someone please explain how this is configured and invoked? The latest Sphinx uses CSS to make prompts unselectable. refs: https://developer.mozilla.org/en-US/docs/Web/CSS/user-select Thanks, Takeshi KOMIYA 2021年9月14日(火) 18:42 Ron Stone : > > Hi, > > I originally posted this to sphinx-d

[sphinx-users] Unselectable code-block prompt

2021-09-14 Thread Ron Stone
Hi, I originally posted this to sphinx-dev but now believe it belongs here. Apologies for cross-posting. I am using Sphinx 4.2. I see this merge re making prompts in code blocks unelectable. https://github.com/sphinx-doc/sphinx/pull/9120 I don't see any documentation of how this works here: