wg21 icon indicating copy to clipboard operation
wg21 copied to clipboard

Change colours in code blocks

Open jwakely opened this issue 6 months ago • 1 comments

Hi Michael,

A recurring issue during LWG review is that the syntax highlighting in code blocks contains green and red text, which gets confused with the actual edits shown as green <ins> tags and red <del> tags. For example, see:

https://isocpp.org/files/papers/P3503R2.html#wording

In the packaged_task class synopsis:

Image

is "// construction and destruction" supposed to be inserted? No, it's not underlined, and is slightly lighter green. It's not inserted text, just a pre-existing comment.

And in this packaged_task constructor:

Image

is the red && supposed to be removed? No, it's not struck through, it's just pre-existing code in red.

We can always figure it out, but it's not a great use of time to have to disambiguate things based on subtle differences.

Would it be possible to use different colours? Maybe a grey for comments, and a darker blue or purple for ( < & etc.? I dunno, those might look ugly, but green and red seem like the worst of all choices.

jwakely avatar Jun 23 '25 09:06 jwakely

Oh, this is a great point! That is silly indeed. I'll look at alternative colors here.

mpark avatar Jun 26 '25 17:06 mpark