Add Code Styling to Code Blocks
I would really love to see for myself and other developer communities out there, to see support for code block styling similarly to how notepad++ does it added.
Where you simply have a dropdown to select the language and it colour styles it based on that.
Maybe the default for that can simply be set to ‘text’ so that everything remains white, but give the option to set what the code block is written in.
For example when starting to write a code block allow us to add an optional parameter.
Something along the lines of:
```
l=python
if __name__ == "__main__":
print("Hello World!")
```
*The actual implementation of this would probably look very different since you dont necessarily want to read code from within the block to get your parameter but I think it conveys the idea
And here is an example image of what I had in mind for selecting the language as the person reading it, by simply adding a row for a combobox:

-
So turns out, something like this already exists, but its just never explained anywhere as far as I can see.
I found this in a random reddit thread.
Styling can be done for code blocks by adding the language parameter right at the beginning:
```(my language)
// Some code…
```
ie.
```c#
for(var test in varibales)
{
if(test)
return true;
}
```
Here is a guid on the it and a link with reference to more languages:
https://gist.github.com/webermn15/47e3fb4ccadf8ac3cf66ee9011a507f50
댓글을 남기려면 로그인하세요.
댓글
댓글 1개