This plugin itself can be switched on and off with the following settings. Because there was something that was highlighted each time when editing the text.
Create a plugin to highlight double-byte spaces in Sublime Text 2 http://qiita.com/items/865e1a6605b1146d4341
Well, it's not that difficult, just add if or something to the highlight_fullpitch_spaces method of the FullPitchWhiteSpaceHighlightListener class and do the following:
FullPitchWhiteSpaceHighlight.py
class FullPitchWhiteSpaceHighlightListener(sublime_plugin.EventListener):
    # highlight full-pitch white spaces
    def highlight_fullpitch_spaces(self, view):
        if view.settings().get('fullwhitespace_viewable') == True:
            view.add_regions('FullPitchWhiteSpaceHighlight',
                             view.find_all(u' +'),
                             "entity.name.class",
                             sublime.DRAW_OUTLINED)
        else:
            view.erase_regions('FullPitchWhiteSpaceHighlight')
It feels like fetching fullwhitespace_viewable settings with view.settings (). Get ('fullwhitespace_viewable', True).
If not, the value of the second argument of get will be returned.
You can switch on and off by writing the following in the configuration file.
hoge.sublime-settings
{
	…
	"fullwhitespace_viewable" : True,
	//"fullwhitespace_viewable" : Flase,
	…
}
something like that.
Recommended Posts