Пример #1
0
    def run(self, edit):
        conf = Config(self.view).local_on
        if conf:
            uncolorize_file(self.view)
        else:
            colorize_file(self.view, True)

        Config(self.view).local_on = not conf
        generate_menu(self.view)
Пример #2
0
    def run(self, edit):
        state = Config(self.view).local_on
        if state:
            uncolorize_file(self.view)
        else:
            colorize_file(self.view, True)

        Config(self.view).local_on = not state
        generate_menu(self.view)
    def run(self, edit):
        view = self.view
        state = state_for(view)
        conf = Config(view).local_on
        if conf:
            uncolorize_file(view, state)
        else:
            colorize_file(view, state, True)

        Config(view).local_on = not conf
        generate_menu(view)
    def run(self, edit):
        view = self.view
        state = state_for(view)
        conf = Config(view).local_on
        if conf:
            uncolorize_file(view, state)
        else:
            colorize_file(view, state, True)

        Config(view).local_on = not conf
        generate_menu(view)
Пример #5
0
    def run(self, edit):
        state = Config(self.view)

        if state.global_on:
            uncolorize_file(self.view)
            Config(self.view).local_on = not state.global_on
        else:
            if state.local_on:
                colorize_file(self.view, True)

        Config(self.view).global_on = not state.global_on
        generate_menu(self.view)
    def run(self, edit):
        view = self.view
        state = state_for(view)
        conf = Config(view)
        if conf.global_on:
            uncolorize_file(view, state)
            Config(view).local_on = not conf.global_on
        else:
            if conf.local_on:
                colorize_file(view, state, True)

        Config(view).global_on = not conf.global_on
        generate_menu(view)
    def run(self, edit):
        view = self.view
        state = state_for(view)
        conf = Config(view)
        if conf.global_on:
            uncolorize_file(view, state)
            Config(view).local_on = not conf.global_on
        else:
            if conf.local_on:
                colorize_file(view, state, True)

        Config(view).global_on = not conf.global_on
        generate_menu(view)
    def on_activated(self, view):
        if is_colorizable(view):
            generate_menu(view)

        state = state_for(view)
        if state and state.theme_path:
            # set file's own theme path, because we use one per css file
            theme.set(state.theme_path)

        if need_colorization(view):
            colorize_file(view, state)

        if need_uncolorization(view):
            uncolorize_file(view, state_for(view))
Пример #9
0
    def on_activated(self, view):
        if is_colorizable(view):
            generate_menu(view)

        state = state_for(view)
        if state and state.theme_path:
            # set file's own theme path, because we use one per css file
            theme.set(state.theme_path)

        if need_colorization(view):
            colorize_file(view, state)

        if need_uncolorization(view):
            uncolorize_file(view)
Пример #10
0
    def on_activated(self, view):
        if is_colorizable(view):
            generate_menu(view)

            # set file's own theme path
            # because we use one per css file
            state = State(view)
            if state.theme_path:
                theme.set(state.theme_path)

        if need_colorization(view):
            colorize_file(view)

        if need_uncolorization(view):
            uncolorize_file(view)
Пример #11
0
 def run(self, edit):
     colorize_file(self.view, state_for(self.view), True)
Пример #12
0
 def on_modified(self, view):
     if need_colorization(view):
         colorize_file(view)
Пример #13
0
    def on_load(self, view):
        # set hook to recolorize if different theme was chosen
        theme.on_select_new_theme(lambda: colorize_on_select_new_theme(view))

        if need_colorization(view):
            colorize_file(view, True)
Пример #14
0
 def run(self, edit, erase_state=False):
     colorize_file(self.view, erase_state)
 def on_modified(self, view):
     if need_colorization(view):
         colorize_file(view, state_for(view))
    def on_load(self, view):
        # set hook to recolorize if different theme was chosen
        theme.on_select_new_theme(lambda: colorize_on_select_new_theme(view))

        if need_colorization(view):
            colorize_file(view, state_for(view))
 def run(self, edit):
     colorize_file(self.view, state_for(self.view), True)