Where does Atom's Command Palette's code come from?


I’m trying to implement show invisibles on highlight, but I can’t figure out where the code for toggle invisibles (From the command palette) comes from. Can anyone suggest where I should look? Thanks.


That command is defined here. Since it works based on toggling your config setting, I doubt that there is a method for revealing specific invisible characters, and you might be out of luck. Something you could explore is the idea of making invisible characters the same color as the atom-text-editor background, then styling atom-text-editor .selection .region to something with good contrast with the background color. That would show the invisible characters when highlighted.