Home Download Buy Blog Forum Support

Color Scheme Builder

Re: Color Scheme Builder

Postby DubRBang on Wed Feb 13, 2013 10:35 pm

the theme builder is great *if* you know the list of scopes or their construction method. i, for one, have no idea how to determine what part of my code fits what scope, and, unlike Aptana (for all it's ridiculous faults), there is no command in SB2 to determine text... at least not that i can find.

so. how the heck to we determine scope such that we can build a theme around it?

thanks!

WR!
DubRBang
 
Posts: 1
Joined: Wed Feb 13, 2013 10:25 pm

Re: Color Scheme Builder

Postby quodlibet on Thu Feb 14, 2013 11:27 am

DubRBang wrote:so. how the heck to we determine scope such that we can build a theme around it?


https://github.com/facelessuser/ScopeHunter

There also other, less fancy plugins around the forums.
quodlibet
 
Posts: 542
Joined: Sat Jun 18, 2011 5:53 pm

Re: Color Scheme Builder

Postby FichteFoll on Thu Feb 14, 2013 10:01 pm

"ctrl-alt-shift-p" works well for most cases. If the covered scope is too long (and exceeds the statusbar) or you want to copy it/use multiple cursors:

Code: Select all
import sublime_plugin

class PrintScopeCommand(sublime_plugin.TextCommand):
    def run(self, edit):
        for sel in self.view.sel():
            if sel.empty():
                row, col = self.view.rowcol(sel.a)
                print("line %d, col %d: %s" % (row + 1, col + 1, self.view.scope_name(sel.a)))
FichteFoll
 
Posts: 400
Joined: Fri Mar 16, 2012 11:49 pm
Location: Germany

Previous

Return to Ideas and Feature Requests

Who is online

Users browsing this forum: No registered users and 12 guests