ASCII Art comments in C/C++ headers and code files
Recently, when I was searching something in my .php file with list of routes for a site, I've decided to make such big ASCII comments. And now, I use them (not in all source files, but for example in long config files), and these comments really help to navigate.
Here is how it looks in my Sublime Minimap:
So far, I didn't automate the process of creating such comments. I use online ASCII creator from this site. I use font "basic"
Yes I use to add those kinds of "nav" cues. Specially in communication parts which has many similar parts but handle i.e. different message types.
I work on a Mac so here goes my setup.
Previously I used a dashboard widgethttp://memention.com/figlet/
But my latest thing is to create a Service with Automator and install figlet
with homebrew. Then in the Service I have this one-liner (also clicked "Output replaces selected text")
/usr/local/bin/figlet -f smslant -w 132
Now in any App I can have figlets just by right-clicking some text.
My preferred font is smslant
Then I usually just add /*
and */
after.
Edit
Well, I just updated my Service to add that C comment
( echo "/*" ; /usr/local/bin/figlet -f smslant -w 132 ; echo " */" )
NO. I don't use such things and would find such things worse than useless. Screen = bandwidth. Wasting space like this decreases code readability.
______||\ || / \|| \ || | ||| \ || | ||| \|| \______/
:-)