Age | Commit message (Collapse) | Author |
|
- Differentiate between :substitute and substitute(), fixes #13883.
- Match all allowed :substitute delimiters.
- Remove leading context from :substitute matches.
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
closes: #14092
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
methods
Problem: Vim9: need more test for exists()
Solution: Add test for exists() with class/objct variables and methods
(Yegappan Lakshmanan)
closes: #14088
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
closes: #14062
Signed-off-by: Matt Ellis <m.t.ellis@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: font ligatures don't render correctly in the Win32 GUI-version
of gvim even when set rop=type:directx is used. Setting
guiligatures also doesn't make any difference. This leads to
broken font ligatures when the cursor passes through them. It
does not recover from this, and they remain broken until you
re-render the whole buffer (e.g. by using Ctrl+L).
Solution: the problem is that we only re-draw the current and previous
character in gui_undraw_cursor() and only have the special case
for GTK when it comes to rendering ligatures. So let's enable
gui_adjust_undraw_cursor_for_ligatures() to also happen for
Win32 GUI if guiligatures is setup correctly (all this does is
expand the range of gui_undraw_cursor() with ligature characters).
related: #9181
related: #12901
closes: #14084
Signed-off-by: Erik S. V. Jansson <caffeineviking@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
closes: #14080
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
dragonish <no.web.developer@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
rpm-4.19.0 added a new SourceLicense tag. It is used at the same place
as License tag.
This patch adds the new tag name into a Vim syntax file to be
highligted the same way as the License tag. Note that it has to be
defined in the syntax file before Source\d* regexp. Otherwise it's not
recognized by Vim.
Signed-off-by: Petr Písař <ppisar@redhat.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: Internal error when passing mark in another buffer to
getregion().
Solution: Don't allow marks in another buffer (zeertzjq)
closes: #14076
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Internal error when passing mark in another buffer to getregion()
|
|
Fixes issue #7876
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Signed-off-by: Nick Hanley <nicholasjhanley@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
While adding to the documentation, also mention the rolled-back key-translation
strategy in version9.txt
closes: #14069
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: Some minor issues with the getregion() function
Solution: Fix examples in the help, use OP_NOP op_type and MBLOCK
as motion_type in f_getreg(), update vim syntax to
for getregion() (Maxim Kim)
```
:xnoremap <CR>
\ <Cmd>echow getregion('v', '.', mode())<CR>
```
`echo` while in visual mode has no visible effect, thus people trying
example might be frustrated as it looks like nothing happens.
So the option is to change it to `echow` or `echom`.
With `echom` it is again has no visible effect but one can at least inspect `:messages`.
On the other hand `echow` showes selected text in a popup window.
```
Can also be used as a |method|: >
'.'->getregion("'a', 'v')
```
Here is the typo, which makes example invalid, should be `("'a", ...`
closes: #14064
Signed-off-by: Maxim Kim <habamax@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Signed-off-by: Eric Pruitt <eric.pruitt@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: hard to get visual region using Vim script
Solution: Add getregion() Vim script function
(Shougo Matsushita, Jakub Łuczyński)
closes: #13998
closes: #11579
Co-authored-by: =?UTF-8?q?Jakub=20=C5=81uczy=C5=84ski?= <doubleloop@o2.pl>
Co-authored-by: Shougo Matsushita <Shougo.Matsu@gmail.com>
Signed-off-by: Shougo Matsushita <Shougo.Matsu@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: win_splitmove fires WinNewPre and possibly WinNew when moving
windows, even though no new windows are created.
Solution: don't fire WinNew and WinNewPre when inserting an existing
window, even if it isn't the current window. Improve the
accuracy of related documentation. (Sean Dewar)
Likewise, before this patch, WinClosed was not fired anyway (even for :wincmd
H/J/K/L, which also didn't fire WinNew, but did still fire WinNewPre), despite
documentation saying windows are "closed". Note that :wincmd T actually indeed
works by creating a new window (and closing the old one), unlike the others.
This also fixes issues where WinNewPre is fired when split-moving while curwin
doesn't yet have a frame or entry in the window list, causing many things to not
work (it's not considered valid at that point). This was guaranteed when using
:wincmd H/J/K/L.
Because WinNewPre is no longer fired when split-moving, this makes restoring the
previous window layout on failure easier, as we can be sure that frames are not
resized from WinNewPre autocommands if win_split_ins fails. This allows us to
use a different strategy in the following commit.
--
In my opinion, this leaves questions about the current usefulness of WinNewPre.
A motivation described in #10635 states how creating a new window can steal room
from other windows, and how WinNewPre will be useful for detecting that, but
this is also true when inserting an existing window, which now doesn't fire it.
Maybe the autocommand should be changed to have a better name?
There are also other issues I found with the current implementation of WinNewPre
that need addressing:
- it allows switching windows and tabpages, which can cause incorrect windows to
be split/moved, and big problems when switching tabpages.
- it fires before win_split_ins checks for room, before it makes any changes to
window sizes or before it considers allocating a new window. This should be
changed or documented.
I hope to address some of this stuff in a different PR, if possible.
related: #14038
Signed-off-by: Sean Dewar <6256228+seandewar@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: Modula-2 files with a specified priority are not detected.
Solution: Match the priority syntax in module header lines when
performing heuristic content detection.
Disable the :defcompile debug line. This was accidentally left enabled
in commit 68a8947.
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
command (#14050)
With the arrival of Vim9 classes, the syntax must allow for
_new_ constructors; multiple constructor definitions are
supported for a class, provided distinct suffix-names are
used. Currently, the defined constructors match either
vimCommand or vimFunctionError (for any newBar).
For example:
------------------------------------------------------------
vim9script
class Foo
def new()
enddef
def newBar()
enddef
endclass
------------------------------------------------------------
Since every constructor is required to bear a lower-cased
_new_ prefix name, it should suffice to distinguish them
from functions, and so there are no new highlight or syntax
groups introduced.
Signed-off-by: Aliaksei Budavei <0x000c70@gmail.com>
Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: Using freed memory with full tag stack and user data
(Konstantin Khlebnikov)
Solution: Clear the user data pointer of the newest entry.
(zeertzjq, Konstantin Khlebnikov)
fixes: neovim/neovim#27498
closes: #14053
Co-authored-by: Konstantin Khlebnikov koct9i@gmail.com
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Konstantin Khlebnikov koct9i@gmail.com
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Commit 103f1dfb7df350650a5d7caadb0364bd79e9d25b forgot to update the
"Last Change:" header. So update it now.
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
While at it, also do the unmap only if a specific key has been mapped.
There are some keys that are only selectively mapped and it would cause
an error if we are trying to unmap such a key (e.g. z when your
foldmethod is not manual).
fixes: #14040
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
The '*.bats' file type is for Bash Automated Testing System (BATS)
scripts. BATS scripts are Bash with a special '@test' extension but they
otherwise work with Vim's bash filetype.
See https://github.com/bats-core/bats-core
closes: #14039
Signed-off-by: Brandon Maier <brandon.maier@collins.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
The 'Config.in' file type is for Buildroot configuration files.
Buildroot Config.in files use the same Kconfig backend as the Linux
kernel's Kconfig files.
Buildroot also has other filename variants that follow "Config.in.*",
they are used to distinguish multiple Config.in files in the same
directory.
See https://buildroot.org/downloads/manual/manual.html#_literal_config_in_literal_file
closes: #14038
Signed-off-by: Brandon Maier <brandon.maier@collins.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
closes: #13873
Signed-off-by: Luca Saccarola <github.e41mv@aleeas.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: filetype: no support for its files
Solution: Add detection for *.its files as dts file type
(Brandon Maier)
The '*.its' file type is for U-Boot Flattened Image Trees (FIT) which
use the flattened devicetree format.
See https://github.com/u-boot/u-boot/blob/master/doc/usage/fit/source_file_format.rst#terminology
closes: #14037
Signed-off-by: Brandon Maier <brandon.maier@collins.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
These were included with the initial release of the syntax file for Vim
5 and were probably intended to allow for syn-region start/skip/end
patterns with a '!' or '+' delimiter. However, these cases are
currently handled by the vimSynRegPat group.
The removed patterns never match anywhere in the distributed runtime
files and it is believed that this is generally true.
closes: #14035
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
closes: #14036
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
- Add missing "Last Change:" line.
- The date on this line in vim.vim is updated by update_date.vim at
Make time. (I made a mistake in the file path)
- Remove unnecessary "b:loaded_syntax_vim_ex".
- Remove "Base File Date:" line in vim.vim.base
- Add Doug Kearns as Maintainer
closes: #14031
Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: filetype: no support for dtso files
Solution: Add detection for *.dtso files as dts file type
(Markus Schneider-Pargmann)
*.dtso files are devicetree overlay files which have the same syntax as dts or dtsi files.
closes: #14026
Signed-off-by: Markus Schneider-Pargmann <msp@baylibre.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
fixes: #13939
closes: #14021
related: vim-jp/syntax-vim-ex#28
Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: Not able to use diff() with 'diffexpr'
(rickhowe, after v9.1.0096)
Solution: Use a default context length of 0, update diff() help text,
add a test for using diff() with 'diffexpr'
(Yegappan Lakshmanan)
closes: #14013
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
The syntax highlighter is likely to encourage people to use the listed
commands.
But `use-embedded-filename` is a dangerous option that can cause GnuPG
to write arbitrary data to arbitrary files whenever GnuPG encounters
malicious data.
GnuPG upstream explicitly warns against using this option:
https://dev.gnupg.org/T4500
https://dev.gnupg.org/T6972
However, since this is a valid option, we cannot just drop it from the
syntax script. Instead, let's mark it with the WarningMsg highlighting
to make it obvious, that this option is different (and should not be
used for security reasons).
closes: #13961
Co-authored-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
- allow comments after :highight commands
- match the bang in a :highlight[!] command
- highlight the bang in :map[!], :menu[!] and :unlet[!] with vimOper
like all other commands
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: diff() function uses 'diffexpr'
(rickhowe)
Solution: Make diff() always use internal diff(), add support for
unified diff context length, sort diff() options in help
(Yegappan Lakshmanan)
fixes: #13989
closes: #14010
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: Syntax test fails when run with non C locale
Solution: Run syntax tests with C locale, clean up Xtestscript file,
strip environment variables from GetVimCommand()
(h-east)
closes: #14007
Co-authored-by: h-east <h.east.727@gmail.com>
Signed-off-by: h-east <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
closes: #13966
Signed-off-by: Andrew Radev <andrey.radev@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
closes: #13990
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Make doc list-concatenation more clear as for += and extend().
1. describe `+=` for list-concatenation more accurately
2. add `extend()` example for list-concatenation
3. Fix CI errors for missing helptags reference |+=|
closes: #13983
Signed-off-by: qeatzy <qeatzy@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: unexpected error for modifying final list using += operator
(Ernie Rael)
Solution: Allow List value modification of a final variable using +=
operator
(Yegappan Lakshmanan)
fixes: #13745
fixes: #13959
closes: #13962
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Added a syntax region for command blocks so that the highlighting of
`::` comments in them can be controlled. The `dosbatch_colons_comment`
variable now controls if all `::` comments in a code block are
highlighted as comments or errors. A `::` comment at the end of a
command block is always highlighted as an error.
This re-enables the highlighting of `::` comments in `.bat` files as
requested in #13666, while allowing control of highlighting them in
command blocks requested in #11778 and first attempted in #11980.
related: #11980
fixes: #13666
Co-authored-by: Mike Williams <mikew@globalgraphics.com>
Signed-off-by: Mike Williams <mikew@globalgraphics.com>
Signed-off-by: mevanlc <mevanlc@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Vim will lookup color names from the v:colornames dictionary by its
lower case color name. So when sourcing the v:colornames dictionary,
make sure to convert upper case color names to lower case.
Also, while at it, mention in the documentation, that the dictionary
should contain lower case names only.
fixes: #13976
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: luau config file not detected
(lopy)
Solution: Detect it as jsonc
(lopy)
fixes: #13960
closes: #13970
Signed-off-by: lopy <70210066+lopi-py@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Improve string interpolation highlighting.
Use the vimSep group to highlight interpolation braces as vimOperParen
has no highlighting of its own and employs vimSep via matchgroup.
Add vimNumber to the interpolation group's contained list.
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: thinca <thinca@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Problem: Need a diff() Vim script function
Solution: Add the diff() Vim script function using the
xdiff internal diff library, add support for
"unified" and "indices" mode.
(Yegappan Lakshmanan)
fixes: #4241
closes: #12321
Signed-off-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
Improve string escape sequence and special key matching.
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|
|
* runtime (Fortran) update syntax
* runtime (Fortran) small fix
Signed-off-by: Ajit-Thakkar <142174202+Ajit-Thakkar@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
|