Improved Code Syntax Highlighting (Python)
CompletedI believe requests for syntax highlighting exist in other languages. I have gone through all the different themes available and found that the syntax highlighting for Python, in particular, could use some work. I do understand there is a balance to strike between simplicity and readability when choosing a syntax highlighting scheme. In the attached example:
- The block comment (triple quote multiline comment) is the same color as the code, which makes it very confusing. My biggest ask would be to make this the same color as single line comments.
- The variable names, declared types and default values are all the same color in the function signature (most IDEs would give you more color cues to quickly distinguish those).
- Some IDEs, such as Sublime Text and PyCharm, color class and function usages in the code (e.g. OEScalarGrid, OEFloatArray). I would love it that were an option, but I would say it is less of a big deal than addressing #1 above.
Thank you!
-
Official comment
Thanks for the detailed report Scott. We use a version of highlight.js behind the scenes and I've created an issue on GH: https://github.com/highlightjs/highlight.js/issues/1918
If we have a bit of time, we might also tackle the bug in the coming weeks.
Comment actions
Please sign in to leave a comment.
Comments
2 comments