Search code examples
pythonscriptingsublimetext3sublime-text-plugin

Restore sublime-text default status bar


I installed a couple of plugins to add more features to sublime's status-bar, but it resulted in removing some basic features of it like getting number of matches of a specific word in Find. [check screenshot]
Plugin link: https://github.com/shagabutdinov/sublime-status-message
I tried removing all relevant plugins, no success.
So, how can I restore default settings of status bar, I tried writing a script to restore or shift the items in status bar with no fruitful result so far

enter image description here


Solution

  • I solved the issue, it's related to the plugin in question which does hide default items of sublime's status-bar, the items don't show up back even after removing the plugin. So, you have to use the plugin's API to restore status bar to default again.
    The following script from their API can restore the default items back:

    import sublime
    import sublime_plugin
    from StatusMessage import status_message
    
    class RestoreDefaultStatus(sublime_plugin.TextCommand):
      def run(self, edit):
        status_message.hide_default_status = not status_message.hide_default_status
        status_message.refresh(self.view)