Re: syntax highlighting for assembler
Posted: Mon Nov 30, 2020 6:36 pm
Procrastin8 wrote:
I know this post is pretty ancient....
Quote:
....so I thought I'd share my solution (though my stylistic choices might bother some or all of you)
That said, what is the point of different colours for label definitions, instructions, and operands in general? It seems to me that the separate columns already do a good job of distinguishing them.
I mention this because the more colours you use, the less power you have with contrast. While BDD's colour-blindness may not be the common case, you should note that the presbyopya that commonly comes along with ageing eyes is not just about focus but also about brightness and contrast. More light reflected from the subject (or generated from it, in the case of computer screens) contracts the pupil, thus improving focus. Thus, light backgrounds with dark text tend to be easier to read, and things like dark red or dark blue on black, being both dark and low-contrast, are seriously suboptimal.
As others have pointed out in this thread, often better syntax or better use of existing syntax is a better solution to readability problems than colourisation. My attitude is that if something is hard to read without colourisation, look first at the syntax, rather than using colourisation as a crutch for bad syntax. Often better formatting or a macro will do a much better job of fixing the problem.
BigDumbDinosaur wrote:
Color is fine and all that, but obviously is not going to help when displayed on a monochrome terminal, which device until relatively recently, dominated computer displays.