Exemple #1
0
  def __init__( self ):
    self._connection = None
    self._logger = logging.getLogger( __name__ )
    utils.SetUpLogging( self._logger )

    # These are the user-entered breakpoints.
    self._line_breakpoints = defaultdict( list )
    self._func_breakpoints = []
    self._exception_breakpoints = None
    self._configured_breakpoints = {}

    # FIXME: Remove this. Remove breakpoints nonesense from code.py
    self._breakpoints_handler = None
    self._server_capabilities = {}

    self._next_sign_id = 1

    if not utils.SignDefined( 'vimspectorBP' ):
      vim.command( 'sign define vimspectorBP text==> texthl=Error' )

    if not utils.SignDefined( 'vimspectorBPCond' ):
      vim.command( 'sign define vimspectorBPCond text=?> texthl=Error' )

    if not utils.SignDefined( 'vimspectorBPDisabled' ):
      vim.command( 'sign define vimspectorBPDisabled text=!> texthl=Warning' )
Exemple #2
0
    def __init__(self, window, api_prefix):
        self._window = window
        self._api_prefix = api_prefix

        self._terminal_window = None
        self._terminal_buffer_number = None
        self.current_syntax = None

        self._logger = logging.getLogger(__name__)
        utils.SetUpLogging(self._logger)

        self._next_sign_id = 1
        self._breakpoints = defaultdict(list)
        self._signs = {'vimspectorPC': None, 'breakpoints': []}

        with utils.LetCurrentWindow(self._window):
            vim.command(
                'nnoremenu WinBar.Continue :call vimspector#Continue()<CR>')
            vim.command(
                'nnoremenu WinBar.Next :call vimspector#StepOver()<CR>')
            vim.command(
                'nnoremenu WinBar.Step :call vimspector#StepInto()<CR>')
            vim.command(
                'nnoremenu WinBar.Finish :call vimspector#StepOut()<CR>')
            vim.command('nnoremenu WinBar.Pause :call vimspector#Pause()<CR>')
            vim.command('nnoremenu WinBar.Stop :call vimspector#Stop()<CR>')
            vim.command(
                'nnoremenu WinBar.Restart :call vimspector#Restart()<CR>')
            vim.command('nnoremenu WinBar.Reset :call vimspector#Reset()<CR>')

            if not utils.SignDefined('vimspectorPC'):
                vim.command('sign define vimspectorPC text=-> texthl=Search')
Exemple #3
0
    def __init__(self, window, api_prefix):
        self._window = window
        self._api_prefix = api_prefix

        self._terminal_window = None
        self._terminal_buffer_number = None
        self.current_syntax = None

        self._logger = logging.getLogger(__name__)
        utils.SetUpLogging(self._logger)

        self._next_sign_id = 1
        self._breakpoints = defaultdict(list)
        self._signs = {'vimspectorPC': None, 'breakpoints': []}

        with utils.LetCurrentWindow(self._window):
            vim.command(
                'nnoremenu WinBar.■\\ Stop :call vimspector#Stop()<CR>')
            vim.command(
                'nnoremenu WinBar.▶\\ Cont :call vimspector#Continue()<CR>')
            vim.command(
                'nnoremenu WinBar.▷\\ Pause :call vimspector#Pause()<CR>')
            vim.command(
                'nnoremenu WinBar.↷\\ Next :call vimspector#StepOver()<CR>')
            vim.command(
                'nnoremenu WinBar.→\\ Step :call vimspector#StepInto()<CR>')
            vim.command(
                'nnoremenu WinBar.←\\ Out :call vimspector#StepOut()<CR>')
            vim.command('nnoremenu WinBar.⟲: :call vimspector#Restart()<CR>')
            vim.command('nnoremenu WinBar.✕ :call vimspector#Reset()<CR>')

            if not utils.SignDefined('vimspectorPC'):
                utils.DefineSign('vimspectorPC', text='▶', texthl='MatchParen')