]> Sergey Matveev's repositories - vim-lsp.git/log
vim-lsp.git
15 months agoAdded option for removing duplicate completion items
Daniel Viberg [Tue, 2 Jan 2024 20:24:15 +0000 (21:24 +0100)]
Added option for removing duplicate completion items

16 months agoUpgrade checkout github actions to v4. Run unit-tests on Vim 9.0 and the latest...
Yegappan Lakshmanan [Tue, 26 Dec 2023 15:16:10 +0000 (07:16 -0800)]
Upgrade checkout github actions to v4.  Run unit-tests on Vim 9.0 and the latest nightly

16 months agoWhen displaying completion documentation, check the index is valid
Yegappan Lakshmanan [Mon, 25 Dec 2023 15:38:39 +0000 (07:38 -0800)]
When displaying completion documentation, check the index is valid

16 months agoMerge pull request #426 from girishji/main
Yegappan Lakshmanan [Wed, 20 Dec 2023 17:48:31 +0000 (09:48 -0800)]
Merge pull request #426 from girishji/main

Remove E1013 error when lsp sends kind=null

16 months agorequested change
Girish Palya [Wed, 20 Dec 2023 16:43:20 +0000 (17:43 +0100)]
requested change

M  autoload/lsp/completion.vim

16 months agoMerge pull request #427 from Shane-XB-Qian/fix_cfg_get_len_chk
Yegappan Lakshmanan [Wed, 20 Dec 2023 15:46:45 +0000 (07:46 -0800)]
Merge pull request #427 from Shane-XB-Qian/fix_cfg_get_len_chk

fix: check cfg get len

16 months agofix: check cfg get len
shane.xb.qian [Wed, 20 Dec 2023 15:40:35 +0000 (23:40 +0800)]
fix: check cfg get len

Signed-off-by: shane.xb.qian <shane.qian@foxmail.com>
16 months agoMerge pull request #425 from DanielViberg/main
Yegappan Lakshmanan [Wed, 20 Dec 2023 14:45:55 +0000 (06:45 -0800)]
Merge pull request #425 from DanielViberg/main

Changed default value of missing workspaceConfig from [{}] to [null]

16 months agoRemove E1013 error when lsp sends kind=null
Girish Palya [Wed, 20 Dec 2023 13:08:01 +0000 (14:08 +0100)]
Remove E1013 error when lsp sends kind=null
This is what pyslp sent:
{'label': '''H''', 'data': {'doc_uri': 'file:///...py'},
 'sortText': 'a''H''', 'kind': null, 'insertText': '''H'''}
'kind' property need to be checked for null before
attempting completion.

M  autoload/lsp/completion.vim

16 months agoChanged default value of missing workspaceConfig from [{}] to [null]
Daniel Viberg [Tue, 19 Dec 2023 13:58:43 +0000 (14:58 +0100)]
Changed default value of missing workspaceConfig from [{}] to [null]

16 months agoMerge pull request #422 from Angluca/main
Yegappan Lakshmanan [Tue, 12 Dec 2023 15:03:22 +0000 (07:03 -0800)]
Merge pull request #422 from Angluca/main

Copy to my vimrc Error!!

16 months agoCopy to my vimrc Error!!
Pixeller [Tue, 12 Dec 2023 11:17:10 +0000 (19:17 +0800)]
Copy to my vimrc Error!!

Newbies only copy and paste settings
T. T

16 months agoMerge pull request #421 from Shane-XB-Qian/fix_semantic_flag_typo
Yegappan Lakshmanan [Mon, 4 Dec 2023 15:06:16 +0000 (07:06 -0800)]
Merge pull request #421 from Shane-XB-Qian/fix_semantic_flag_typo

fix: fix semantic flag typo

16 months agofix: fix semantic flag typo
shane.xb.qian [Mon, 4 Dec 2023 09:24:12 +0000 (17:24 +0800)]
fix: fix semantic flag typo

Signed-off-by: shane.xb.qian <shane.qian@foxmail.com>
16 months agoAdd the initial support for semantic highlighting
Yegappan Lakshmanan [Sun, 3 Dec 2023 05:50:59 +0000 (21:50 -0800)]
Add the initial support for semantic highlighting

16 months agoMerge pull request #420 from Shane-XB-Qian/refine_compl_kind_trig_char
Yegappan Lakshmanan [Sat, 2 Dec 2023 15:35:01 +0000 (07:35 -0800)]
Merge pull request #420 from Shane-XB-Qian/refine_compl_kind_trig_char

none: get trig chars always

16 months agonone: get trig chars always
shane.xb.qian [Sat, 2 Dec 2023 04:08:02 +0000 (12:08 +0800)]
none: get trig chars always

Signed-off-by: shane.xb.qian <shane.qian@foxmail.com>
16 months agoMerge pull request #418 from girishji/main
Yegappan Lakshmanan [Fri, 1 Dec 2023 17:26:51 +0000 (09:26 -0800)]
Merge pull request #418 from girishji/main

Make omnifunc() complete keywords based on LSP triggerCharacters

16 months agoImprove doc
Girish Palya [Fri, 1 Dec 2023 16:38:52 +0000 (17:38 +0100)]
Improve doc

M  autoload/lsp/completion.vim

16 months agoMerge branch 'yegappan:main' into main
giri [Fri, 1 Dec 2023 16:26:09 +0000 (17:26 +0100)]
Merge branch 'yegappan:main' into main

16 months agoChanges as requested by reviwers
Girish Palya [Fri, 1 Dec 2023 16:25:50 +0000 (17:25 +0100)]
Changes as requested by reviwers

M  autoload/lsp/completion.vim
M  test/clangd_tests.vim

16 months agoMerge pull request #419 from CoelacanthusHex/fix/list
Yegappan Lakshmanan [Fri, 1 Dec 2023 15:41:31 +0000 (07:41 -0800)]
Merge pull request #419 from CoelacanthusHex/fix/list

fix(inlayhint): fix format when label is a list in Rust Analyzer

16 months agoIn recent Vim versions, prop_list() doesn't return the length item for virtual text
Yegappan Lakshmanan [Fri, 1 Dec 2023 15:39:16 +0000 (07:39 -0800)]
In recent Vim versions, prop_list() doesn't return the length item for virtual text

16 months agofix(inlayhint): fix format when label is a list in Rust Analyzer
Coelacanthus [Fri, 1 Dec 2023 13:51:21 +0000 (21:51 +0800)]
fix(inlayhint): fix format when label is a list in Rust Analyzer

resolve #416

16 months agoFix some of the test failures
Girish Palya [Thu, 30 Nov 2023 21:54:14 +0000 (22:54 +0100)]
Fix some of the test failures
- fixed omnifunc related tests
- diag related tests are still failing

M  autoload/lsp/completion.vim
M  test/clangd_tests.vim

17 months agoPropagate triggerCharacters to omni-completion
Girish Palya [Wed, 29 Nov 2023 12:17:55 +0000 (13:17 +0100)]
Propagate triggerCharacters to omni-completion
Fixed 2 bugs:
- add triggerCharacters to lsp list for omniComplete option
- process triggerCharacters based keywords in omnifunc()

M  autoload/lsp/completion.vim
M  autoload/lsp/lspserver.vim

17 months agoMerge pull request #415 from Konfekt/patch-1
Yegappan Lakshmanan [Tue, 28 Nov 2023 15:42:36 +0000 (07:42 -0800)]
Merge pull request #415 from Konfekt/patch-1

update doc on default options

17 months agoMerge pull request #357 from Shane-XB-Qian/fix_inlay_maybe_delayed
Yegappan Lakshmanan [Tue, 28 Nov 2023 15:41:30 +0000 (07:41 -0800)]
Merge pull request #357 from Shane-XB-Qian/fix_inlay_maybe_delayed

fix: inlay hints maybe a bit delayed if sync init

17 months agoupdate default options
Enno [Mon, 20 Nov 2023 08:24:31 +0000 (09:24 +0100)]
update default options

the documentation no longer reflected autoload/lsp/options.vim (lines 9-162):

export var lspOptions: dict<any> = {
  # Enable ale diagnostics support.
  # If true, diagnostics will be sent to ale, which will be responsible for
  # showing them.
  aleSupport: false,

  # In insert mode, complete the current symbol automatically
  # Otherwise, use omni-completion
  autoComplete: true,

  # In normal mode, highlight the current symbol automatically
  autoHighlight: false,

  # Automatically highlight diagnostics messages from LSP server
  autoHighlightDiags: true,

  # Automatically populate the location list with new diagnostics
  autoPopulateDiags: false,

  # icase | fuzzy | case match for language servers that replies with a full
  # list of completion items
  completionMatcher: 'case',

  # Due to a bug in the earlier versions of Vim, cannot use the
  # COMPLETIONMATCHER_CASE constant here for initialization.
  completionMatcherValue: 1,

  # diagnostics signs options
  diagSignErrorText: 'E>',
  diagSignHintText: 'H>',
  diagSignInfoText: 'I>',
  diagSignWarningText: 'W>',

  # In insert mode, echo the current symbol signature in the status line
  # instead of showing it in a popup
  echoSignature: false,

  # hide disabled code actions
  hideDisabledCodeActions: false,

  # Highlight diagnostics inline
  highlightDiagInline: true,

  # Show the symbol documentation in the preview window instead of in a popup
  hoverInPreview: false,

  # Don't print message when a configured language server is missing.
  ignoreMissingServer: false,

  # Focus on the location list window after ":LspDiag show"
  keepFocusInDiags: true,

  # Focus on the location list window after LspShowReferences
  keepFocusInReferences: true,

  # If true, apply the LSP server supplied text edits after a completion.
  # If a snippet plugin is going to apply the text edits, then set this to
  # false to avoid applying the text edits twice.
  completionTextEdit: true,

  # Alignment of virtual diagnostic text, when showDiagWithVirtualText is true
  # Allowed values: 'above' | 'below' | 'after' (default is 'above')
  diagVirtualTextAlign: 'above',

  # Suppress adding a new line on completion selection with <CR>
  noNewlineInCompletion: false,

  # Omni-completion support.  To keep backward compatibility, this option is
  # set to null by default instead of false.
  omniComplete: null,

  # Open outline window on right side
  outlineOnRight: false,

  # Outline window size
  outlineWinSize: 20,

  # Show diagnostic text in a balloon when the mouse is over the diagnostic
  showDiagInBalloon: true,

  # Make diagnostics show in a popup instead of echoing
  showDiagInPopup: true,

  # Suppress diagnostic hover from appearing when the mouse is over the line
  # Show a diagnostic message on a status line
  showDiagOnStatusLine: false,

  # Show a diagnostic messages using signs
  showDiagWithSign: true,

  # Show a diagnostic messages with virtual text
  showDiagWithVirtualText: false,

  # enable inlay hints
  showInlayHints: false,

  # In insert mode, show the current symbol signature automatically
  showSignature: true,

  # enable snippet completion support
  snippetSupport: false,

  # enable SirVer/ultisnips completion support
  ultisnipsSupport: false,

  # add to autocomplition list current buffer words
  useBufferCompletion: false,

  # Use a floating menu to show the code action menu instead of asking for
  # input
  usePopupInCodeAction: false,

  # ShowReferences in a quickfix list instead of a location list`
  useQuickfixForLocations: false,

  # enable hrsh7th/vim-vsnip completion support
  vsnipSupport: false,

  # Limit the time autocompletion searches for words in current buffer (in
  # milliseconds)
  bufferCompletionTimeout: 100,

  # Enable support for custom completion kinds
  customCompletionKinds: false,

  # A dictionary with all completion kinds that you want to customize
  completionKinds: {}
}

# set the LSP plugin options from the user provided option values
export def OptionsSet(opts: dict<any>)
  lspOptions->extend(opts)
  if !has('patch-9.0.0178')
    lspOptions.showInlayHints = false
  endif
  if !has('patch-9.0.1157')
    lspOptions.showDiagWithVirtualText = false
  endif

  # For faster comparison, convert the 'completionMatcher' option value from a
  # string to a number.
  if lspOptions.completionMatcher == 'icase'
    lspOptions.completionMatcherValue = COMPLETIONMATCHER_ICASE
  elseif lspOptions.completionMatcher == 'fuzzy'
    lspOptions.completionMatcherValue = COMPLETIONMATCHER_FUZZY
  else
    lspOptions.completionMatcherValue = COMPLETIONMATCHER_CASE
  endif

  # Apply the changed options
  if exists('#LspCmds#User#LspOptionsChanged')
    :doautocmd <nomodeline> LspCmds User LspOptionsChanged
  endif
enddef

18 months agoMerge pull request #407 from vimpostor/textedit_cursor
Yegappan Lakshmanan [Mon, 16 Oct 2023 14:39:54 +0000 (07:39 -0700)]
Merge pull request #407 from vimpostor/textedit_cursor

Avoid moving the cursor when applying textedits

18 months agoAvoid moving the cursor when applying textedits
Magnus Groß [Thu, 12 Oct 2023 23:08:06 +0000 (01:08 +0200)]
Avoid moving the cursor when applying textedits

In 33c9dc37bd354391579f669a142699801b13d571 we removed a workaround that
resets the cursor to the previous location after applying an
workspaceEdit, because it interfered with auto-imports.

Turns out the workaround was there for a reason: When we apply general
textedits (e.g. when we rename a variable), then we are always moving
the cursor by accident, because internally (to apply a textedit) we
delete the entire text range and then append the new range.
Obviously this loses the cursor position, hence the reason for the
original manual cursor reset workaround.

Instead of reintroducing that workaround, we now avoid moving the cursor
altogether: We accomplish this by no longer deleting the entire range
and inserting it again. Instead we just remove lines that actually need
to be deleted, add lines that actually need to be added and then handle
the rest with a normal setbufline() call.

This will cause the cursor to never lose the correct position, because
we never remove the entire region where the cursor is located in.

We have to be careful with off-by-one errors, therefore this also adds
an extra test for the scenario where we have to delete some lines. The
two other scenarios already had comprehensive tests (adding lines, and
keeping the amount of lines).

18 months agoAccess the save key in textDocumentSync only if it is a Dict
Yegappan Lakshmanan [Fri, 6 Oct 2023 19:11:39 +0000 (12:11 -0700)]
Access the save key in textDocumentSync only if it is a Dict

18 months agoMerge pull request #405 from mhanberg/didsavetext
Yegappan Lakshmanan [Fri, 6 Oct 2023 15:21:49 +0000 (08:21 -0700)]
Merge pull request #405 from mhanberg/didsavetext

fix: send buffer text on textDocument/didSave

18 months agofixup! fix: send buffer text on textDocument/didSave
Mitchell Hanberg [Fri, 6 Oct 2023 14:42:34 +0000 (10:42 -0400)]
fixup! fix: send buffer text on textDocument/didSave

18 months agofixup! fix: send buffer text on textDocument/didSave
Mitchell Hanberg [Thu, 5 Oct 2023 22:46:08 +0000 (18:46 -0400)]
fixup! fix: send buffer text on textDocument/didSave

18 months agofix: send buffer text on textDocument/didSave
Mitchell Hanberg [Thu, 5 Oct 2023 21:29:09 +0000 (17:29 -0400)]
fix: send buffer text on textDocument/didSave

This sends the full buffer text on the textDocument/didSave notification
if the server's sync options specify it.

19 months agonone: change to use 'LspInlayHintsUpdateNow'
shane.xb.qian [Thu, 21 Sep 2023 05:44:29 +0000 (13:44 +0800)]
none: change to use 'LspInlayHintsUpdateNow'

19 months agofix: inlay hints maybe a bit delayed if sync init
shane.xb.qian [Sat, 8 Jul 2023 11:54:51 +0000 (19:54 +0800)]
fix: inlay hints maybe a bit delayed if sync init

Signed-off-by: shane.xb.qian <shane.qian@foxmail.com>
19 months agoMerge pull request #393 from andlrc/fix-doc-error
Yegappan Lakshmanan [Thu, 14 Sep 2023 04:10:51 +0000 (21:10 -0700)]
Merge pull request #393 from andlrc/fix-doc-error

Fix filetype error in docs

19 months agoFix filetype error in docs
Andreas Louv [Wed, 13 Sep 2023 21:53:58 +0000 (23:53 +0200)]
Fix filetype error in docs

19 months agoMerge pull request #390 from vimpostor/completionitem_fix
Yegappan Lakshmanan [Mon, 4 Sep 2023 18:47:51 +0000 (11:47 -0700)]
Merge pull request #390 from vimpostor/completionitem_fix

Fix additionalTextEdits being ignored

19 months agoFix additionalTextEdits being ignored
Magnus Groß [Mon, 4 Sep 2023 18:16:43 +0000 (20:16 +0200)]
Fix additionalTextEdits being ignored

Regression was introduced in 6f4fdc7bcc3a1ba041c6196b85b506bd0c207cf0.
The logic was still fine if the LSP server delayed the
additionalTextEdits field, but if we already got it, we ended up
ignoring it.

Fix this by checking for additionalTextEdits outside the delayed-resolve
condition.

Also see #389

19 months agoMerge pull request #388 from matthias-margush/fix/initialize-lspserver-with-needOffse...
Yegappan Lakshmanan [Mon, 4 Sep 2023 16:15:47 +0000 (09:15 -0700)]
Merge pull request #388 from matthias-margush/fix/initialize-lspserver-with-needOffsetEncoding

fix: initialize needOffsetEncoding in NewLspServer

19 months agoMerge pull request #389 from vimpostor/completionitem_command
Yegappan Lakshmanan [Mon, 4 Sep 2023 16:15:28 +0000 (09:15 -0700)]
Merge pull request #389 from vimpostor/completionitem_command

Add support for CompletionItem commands

19 months agoDo not reset cursor after workspaceEdit
Magnus Groß [Mon, 4 Sep 2023 15:50:12 +0000 (17:50 +0200)]
Do not reset cursor after workspaceEdit

The workspace edit may add or delete lines, so resetting it to the last
linenumber and column will very likely not match the last logical line
before the workspaceEdit operation.

For example an action might add an auto-import statement at the top of
the file, effectively adding one line in-between. If we now reset the
cursor, we will end up one logical line before the one where we actually
started at.

This behaviour is automatically fixed if we just don't reset the cursor
at all.

19 months agoAdd support for CompletionItem commands
Magnus Groß [Sun, 3 Sep 2023 22:57:59 +0000 (00:57 +0200)]
Add support for CompletionItem commands

When we resolve a completion item with a "completionItem/resolve"
request, the LSP server returns a CompletionItem object [0], which may
contain an optional "command" field. This field describes a command that
must be called **after** inserting the completion.

For example the haskell-language-server may respond with the following
command after autocompleting an unimported function (arguments are left
out for brevity):

{'command': '10619:ghcide-extend-import-action:extendImport', 'arguments': [], 'title': 'extend import'}

Then when we send the matching "workspace/executeCommand" request, the
server will respond with a "workspace/applyEdit" request, that
autoimports the function.

Technically the specification dictates that servers should prefer to set
"additionalTextEdits" for that usecase, but there is still some use for
doing it this way, e.g. haskell-language-server also wants to display an
info message to the user, which doesn't happen with
"additionalTextEdits".

In any case it is important to support the "command" field, as it may
also contain actions unrelated to "additionalTextEdits".

[0] https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#completionItem

19 months agoMerge pull request #387 from maximyurevich/main
Yegappan Lakshmanan [Sun, 3 Sep 2023 20:56:43 +0000 (13:56 -0700)]
Merge pull request #387 from maximyurevich/main

fix(handlers): ignore `sqlLanguageServer.finishSetup`

19 months agofix: initialize needOffsetEncoding in NewLspServer
Matthias Margush [Sun, 3 Sep 2023 20:31:29 +0000 (13:31 -0700)]
fix: initialize needOffsetEncoding in NewLspServer

19 months agofix(handlers): ignore `sqlLanguageServer.finishSetup`
Maxim Yurevich [Sun, 3 Sep 2023 17:58:06 +0000 (20:58 +0300)]
fix(handlers): ignore `sqlLanguageServer.finishSetup`

19 months agoMerge pull request #383 from maximyurevich/main
Yegappan Lakshmanan [Thu, 31 Aug 2023 13:41:19 +0000 (06:41 -0700)]
Merge pull request #383 from maximyurevich/main

fix: ignore `eslint/status` and `taplo/didChangeSchemaAssociation`

20 months agofix: ignore `eslint/status` and `taplo/didChangeSchemaAssociation`
Maxim Yurevich [Tue, 29 Aug 2023 21:36:59 +0000 (00:36 +0300)]
fix: ignore `eslint/status` and `taplo/didChangeSchemaAssociation`

20 months agoMerge pull request #375 from girishji/main
Yegappan Lakshmanan [Mon, 14 Aug 2023 14:44:40 +0000 (07:44 -0700)]
Merge pull request #375 from girishji/main

omnifunc documentation popup should not throw error

20 months agoSilenty ignore a file with empty file type
Yegappan Lakshmanan [Mon, 14 Aug 2023 14:37:54 +0000 (07:37 -0700)]
Silenty ignore a file with empty file type

20 months agoomnifunc documentation popup not throw error
Girish Palya [Thu, 10 Aug 2023 17:26:34 +0000 (19:26 +0200)]
omnifunc documentation popup not throw error
When using Omni completion with other sources of completion items
that do not have 'user_data' dictionary, documentation popup should
not throw error.

I am using my own completion plugin with g:LspOmniFunc and I need
LSP to grab lazy-doc from lsp server. But it should not throw
error when user_data does not contain dictionary.

M  autoload/lsp/completion.vim

20 months agoOptions changed autocmd is not invoked
Yegappan Lakshmanan [Tue, 1 Aug 2023 04:34:01 +0000 (21:34 -0700)]
Options changed autocmd is not invoked

20 months agoOption changes are not handled properly
Yegappan Lakshmanan [Tue, 1 Aug 2023 01:21:50 +0000 (18:21 -0700)]
Option changes are not handled properly

21 months agoAuto import is not working with typescript language server. Fixes #367.
Yegappan Lakshmanan [Sat, 29 Jul 2023 01:01:49 +0000 (18:01 -0700)]
Auto import is not working with typescript language server.  Fixes #367.

21 months agoMove the code for displaying the current diag in the status line to diag.vim
Yegappan Lakshmanan [Fri, 28 Jul 2023 15:31:23 +0000 (08:31 -0700)]
Move the code for displaying the current diag in the status line to diag.vim

21 months agoUpdate help text
Yegappan Lakshmanan [Fri, 28 Jul 2023 14:56:50 +0000 (07:56 -0700)]
Update help text

21 months agoAdd option to enalbe/disable omni-completion
Yegappan Lakshmanan [Fri, 28 Jul 2023 04:32:00 +0000 (21:32 -0700)]
Add option to enalbe/disable omni-completion

21 months agoSkip displaying inlay hints if it is disabled for a language server
Yegappan Lakshmanan [Thu, 27 Jul 2023 14:08:37 +0000 (07:08 -0700)]
Skip displaying inlay hints if it is disabled for a language server

21 months agoWhen signature help is disabled for a lsp server, don't map the trigger characters...
Yegappan Lakshmanan [Wed, 26 Jul 2023 15:14:20 +0000 (08:14 -0700)]
When signature help is disabled for a lsp server, don't map the trigger characters.  Update the help text to use the space character (32)

21 months agoMerge pull request #365 from rcasta74/md_parser
Yegappan Lakshmanan [Wed, 26 Jul 2023 13:54:16 +0000 (06:54 -0700)]
Merge pull request #365 from rcasta74/md_parser

Markdown parser fix for contents with multibyte characters

21 months agoMarkdown parser: add tests for line breaks
Roberto Castagnola [Wed, 26 Jul 2023 12:49:39 +0000 (14:49 +0200)]
Markdown parser: add tests for line breaks

21 months agoMarkdown parser: fix SplitLine with multibyte characters
Roberto Castagnola [Wed, 26 Jul 2023 12:49:05 +0000 (14:49 +0200)]
Markdown parser: fix SplitLine with multibyte characters

21 months agoMarkdown parser: strip leading and trailing whitespaces in heading
Roberto Castagnola [Wed, 26 Jul 2023 12:47:48 +0000 (14:47 +0200)]
Markdown parser: strip leading and trailing whitespaces in heading

21 months agoFix test failure
Yegappan Lakshmanan [Wed, 26 Jul 2023 05:33:48 +0000 (22:33 -0700)]
Fix test failure

21 months agoAdd markdown parser tests
Yegappan Lakshmanan [Wed, 26 Jul 2023 05:30:30 +0000 (22:30 -0700)]
Add markdown parser tests

21 months agoNewline character is not removed from the completion info popup menu text
Yegappan Lakshmanan [Mon, 24 Jul 2023 16:59:40 +0000 (09:59 -0700)]
Newline character is not removed from the completion info popup menu text

21 months agoMerge pull request #363 from rcasta74/md_parser
Yegappan Lakshmanan [Mon, 24 Jul 2023 16:27:37 +0000 (09:27 -0700)]
Merge pull request #363 from rcasta74/md_parser

Fix markdown parser

21 months agoFix markdown parser
Roberto Castagnola [Mon, 24 Jul 2023 16:05:22 +0000 (18:05 +0200)]
Fix markdown parser

21 months agoMerge pull request #362 from rcasta74/md_parser
Yegappan Lakshmanan [Mon, 24 Jul 2023 14:24:48 +0000 (07:24 -0700)]
Merge pull request #362 from rcasta74/md_parser

Markdown parser enhancement

21 months agoHandle soft/hard line breaks in markdown parser
Roberto Castagnola [Mon, 24 Jul 2023 13:24:02 +0000 (15:24 +0200)]
Handle soft/hard line breaks in markdown parser

21 months agoExpand tabs used to define block structure in markdown parser
Roberto Castagnola [Sun, 23 Jul 2023 08:19:20 +0000 (10:19 +0200)]
Expand tabs used to define block structure in markdown parser

21 months agoMerge pull request #361 from girishji/omnifunc
Yegappan Lakshmanan [Wed, 19 Jul 2023 14:29:59 +0000 (07:29 -0700)]
Merge pull request #361 from girishji/omnifunc

Omnifunc optimization and readiness indicator

21 months agoImproved doc
Girish Palya [Wed, 19 Jul 2023 13:47:24 +0000 (15:47 +0200)]
Improved doc

M  doc/lsp.txt

21 months agoImproved doc
Girish Palya [Wed, 19 Jul 2023 13:34:26 +0000 (15:34 +0200)]
Improved doc

M  doc/lsp.txt

21 months agoOptimize regex comparison in omnifunc
Girish Palya [Wed, 19 Jul 2023 13:21:07 +0000 (15:21 +0200)]
Optimize regex comparison in omnifunc

M  autoload/lsp/completion.vim

21 months agoAPI to find out if LSP server has replied
Girish Palya [Wed, 19 Jul 2023 00:22:16 +0000 (02:22 +0200)]
API to find out if LSP server has replied

Add a function to find out if LSP server has replied with completion
matches. This is needed in case of using external completion engines
that expect asynchronous callback. LSP client simply acts as a source
of completion items through omnifunc (g:LspOmniFunc). Before calling
the omnifunc the second time g:LspOmniCompletePending can be checked
to see if LSP server is ready to provide completion items.

M  autoload/lsp/completion.vim
M  doc/lsp.txt

21 months agoUpdate the client capabilities. Pass buffer number to autocmd handler functions...
Yegappan Lakshmanan [Tue, 18 Jul 2023 05:11:34 +0000 (22:11 -0700)]
Update the client capabilities.  Pass buffer number to autocmd handler functions.  Send pending file changes to the language server before updating inlay hints and highlights

21 months agoOptimize the diags handling code
Yegappan Lakshmanan [Tue, 18 Jul 2023 04:46:22 +0000 (21:46 -0700)]
Optimize the diags handling code

21 months agoMarkdown is not applied in the preview window. Fixes #359
Yegappan Lakshmanan [Sat, 15 Jul 2023 19:37:08 +0000 (12:37 -0700)]
Markdown is not applied in the preview window.  Fixes #359

21 months agoPass buffer number as the argument to the autocmd handlers
Yegappan Lakshmanan [Sat, 15 Jul 2023 15:16:09 +0000 (08:16 -0700)]
Pass buffer number as the argument to the autocmd handlers

21 months agoEnable line number in the symbol peek popup window
Yegappan Lakshmanan [Fri, 14 Jul 2023 03:32:18 +0000 (20:32 -0700)]
Enable line number in the symbol peek popup window

21 months agoDiagnostic balloon doesn't work properly
Yegappan Lakshmanan [Fri, 14 Jul 2023 02:54:46 +0000 (19:54 -0700)]
Diagnostic balloon doesn't work properly

21 months agoMerge pull request #358 from vimpostor/diagsbufreload
Yegappan Lakshmanan [Wed, 12 Jul 2023 04:09:19 +0000 (21:09 -0700)]
Merge pull request #358 from vimpostor/diagsbufreload

Respect autoHighlightDiags when reloading a buffer

21 months agoDo not rely on vim's locale in tests
Magnus Groß [Tue, 11 Jul 2023 17:40:38 +0000 (19:40 +0200)]
Do not rely on vim's locale in tests

The language of the user running the tests may be different, which means
that the error message may be different as it is translated.

Instead match only against the error code, which is safer.

21 months agoEnforce disabled autoHighlightDiags when aleSupport is set
Magnus Groß [Tue, 11 Jul 2023 17:01:35 +0000 (19:01 +0200)]
Enforce disabled autoHighlightDiags when aleSupport is set

When someone enables Ale support, it semantically implies disabling
automatic highlighting of diagnostics from this plugin.

Thus we can simplify later checks by automatically disabling
autoHighlightDiags.

21 months agoNever show diagnostics when they are disabled
Magnus Groß [Tue, 11 Jul 2023 16:56:19 +0000 (18:56 +0200)]
Never show diagnostics when they are disabled

A regression was introduced in 6e4ba228eaa0770470060d8d47a360bd05a04ee5
that causes diagnostics to be displayed on buffer reload, even when the
user disabled them.

Fix this by moving the option check directly to DiagsRefresh.

21 months agoAdd the ":LspDiag" command and add sub-commands for the various Lsp
Yegappan Lakshmanan [Tue, 11 Jul 2023 02:29:14 +0000 (19:29 -0700)]
Add the ":LspDiag" command and add sub-commands for the various Lsp
diagnostic functionality.  Update the test scripts to use the new set of
commands.  Add support for dynamically changing the value of the
diagnostic options.  Remove the ":LspDiagHighlightEnable" and the
":LspDiagHighlightDisable" commands (these are replaced by the ":LspDiag
highlight" command)

21 months agoDiags are not highlighted after a buffer is reloaded
Yegappan Lakshmanan [Sun, 9 Jul 2023 16:54:53 +0000 (09:54 -0700)]
Diags are not highlighted after a buffer is reloaded

21 months agoFix test failure
Yegappan Lakshmanan [Sat, 8 Jul 2023 02:46:02 +0000 (19:46 -0700)]
Fix test failure

21 months agoAdd support for enabling/disabling inlay hints
Yegappan Lakshmanan [Sat, 8 Jul 2023 02:33:58 +0000 (19:33 -0700)]
Add support for enabling/disabling inlay hints

21 months agoTest fail with older Vim versions
Yegappan Lakshmanan [Thu, 6 Jul 2023 14:54:31 +0000 (07:54 -0700)]
Test fail with older Vim versions

21 months agoError loading the plugin if OptionsSet() function is not used
Yegappan Lakshmanan [Thu, 6 Jul 2023 14:21:20 +0000 (07:21 -0700)]
Error loading the plugin if OptionsSet() function is not used

21 months agoIgnore unsupported pyright language server notifications. Fixes #355
Yegappan Lakshmanan [Tue, 4 Jul 2023 23:03:42 +0000 (16:03 -0700)]
Ignore unsupported pyright language server notifications.  Fixes #355

21 months agoAdd basic support for InsertReplaceEdit in completion reply. Fixes #354
Yegappan Lakshmanan [Tue, 4 Jul 2023 17:46:21 +0000 (10:46 -0700)]
Add basic support for InsertReplaceEdit in completion reply.  Fixes #354

21 months agoDict key access optimizations
Yegappan Lakshmanan [Tue, 4 Jul 2023 16:58:56 +0000 (09:58 -0700)]
Dict key access optimizations

21 months agoUse the current encoding for the completion popup menu. Fixes #352
Yegappan Lakshmanan [Tue, 4 Jul 2023 14:24:49 +0000 (07:24 -0700)]
Use the current encoding for the completion popup menu.  Fixes #352

22 months agoMinor optimizations
Yegappan Lakshmanan [Sat, 1 Jul 2023 04:50:31 +0000 (21:50 -0700)]
Minor optimizations