Skip to content

Commit 1f7d6c3

Browse files
authored
Merge pull request neovim#35612 from zeertzjq/vim-e0704a3
vim-patch: runtime file updates
2 parents f9ce939 + 967d226 commit 1f7d6c3

File tree

2 files changed

+108
-19
lines changed

2 files changed

+108
-19
lines changed
Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
" Vim Keymap file for Arabic using Buckwalter Transliteration
2+
" see
3+
" http://qamus.org/transliteration.htm
4+
" https://en.wikipedia.org/wiki/Buckwalter_transliteration
5+
"
6+
" Created By: Rafael Ketsetsides <[email protected]>
7+
" Last Update: 2025 Sep 02
8+
9+
let b:keymap_name = "arabic_buckwalter"
10+
11+
loadkeymap
12+
13+
A <char-0x0627> " ALEF
14+
b <char-0x0628> " BEH
15+
p <char-0x0629> " TEH MARBUTA
16+
t <char-0x062a> " TEH
17+
v <char-0x062b> " THEH
18+
j <char-0x062c> " JEEM
19+
H <char-0x062d> " HAH
20+
x <char-0x062e> " KHAH
21+
d <char-0x062f> " DAL
22+
* <char-0x0630> " THAL
23+
r <char-0x0631> " REH
24+
z <char-0x0632> " ZAIN
25+
s <char-0x0633> " SEEN
26+
$ <char-0x0634> " SHEEN
27+
S <char-0x0635> " SAD
28+
D <char-0x0636> " DAD
29+
T <char-0x0637> " TAH
30+
Z <char-0x0638> " ZAH
31+
E <char-0x0639> " AIN
32+
g <char-0x063a> " GHAIN
33+
_ <char-0x0640> " TATWEEL
34+
f <char-0x0641> " FEH
35+
q <char-0x0642> " QAF
36+
k <char-0x0643> " KAF
37+
l <char-0x0644> " LAM
38+
m <char-0x0645> " MEEM
39+
n <char-0x0646> " NOON
40+
h <char-0x0647> " HEH
41+
w <char-0x0648> " WAW
42+
Y <char-0x0649> " ALEF MAKSURA
43+
y <char-0x064a> " YEH
44+
' <char-0x0621> " HAMZA
45+
| <char-0x0622> " ALEF WITH MADDA ABOVE
46+
> <char-0x0623> " ALEF WITH HAMZA ABOVE
47+
& <char-0x0624> " WAW WITH HAMZA ABOVE
48+
< <char-0x0625> " ALEF WITH HAMZA BELOW
49+
} <char-0x0626> " YEH WITH HAMZA ABOVE
50+
F <char-0x064b> " Tanween -- FATHATAN
51+
N <char-0x064c> " Tanween -- DAMMATAN
52+
K <char-0x064d> " Tanween -- KASRATAN
53+
a <char-0x064e> " Tanween -- FATHA
54+
u <char-0x064f> " Tanween -- DAMMA
55+
i <char-0x0650> " Tanween -- KASRA
56+
~ <char-0x0651> " Tanween -- SHADDA
57+
o <char-0x0652> " Tanween -- SUKUN
58+
; <char-0x061b> " Arabic Semicolon
59+
, <char-0x060c> " Arabic Comma
60+
? <char-0x061f> " Arabic Question Mark
61+
{ <char-0x0671> " ALEF WASLA
62+
P <char-0x067E> " PEH
63+
J <char-0x0686> " TCHEH
64+
V <char-0x06A4> " VEH
65+
G <char-0x06AF> " GAF
66+
0 <char-0x06F0> " Arabic-Indic 0
67+
1 <char-0x06F1> " Arabic-Indic 1
68+
2 <char-0x06F2> " Arabic-Indic 2
69+
3 <char-0x06F3> " Arabic-Indic 3
70+
4 <char-0x06F4> " Arabic-Indic 4
71+
5 <char-0x06F5> " Arabic-Indic 5
72+
6 <char-0x06F6> " Arabic-Indic 6
73+
7 <char-0x06F7> " Arabic-Indic 7
74+
8 <char-0x06F8> " Arabic-Indic 8
75+
9 <char-0x06F9> " Arabic-Indic 9

runtime/syntax/m4.vim

Lines changed: 33 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
" Vim syntax file
2-
" Language: M4
2+
" Language: M4
33
" Maintainer: Claudio Fleiner ([email protected])
4-
" URL: http://www.fleiner.com/vim/syntax/m4.vim
5-
" (outdated)
64
" Last Change: 2022 Jun 12
5+
" 2025 Sep 2 by Vim project: fix a few syntax issues #18192
76

87
" This file will highlight user function calls if they use only
98
" capital letters and have at least one argument (i.e. the '('
@@ -18,6 +17,23 @@ if !exists("main_syntax")
1817
let main_syntax='m4'
1918
endif
2019

20+
" Reference: The Open Group Base Specifications, M4
21+
" https://pubs.opengroup.org/onlinepubs/9799919799/
22+
23+
" Quoting in M4:
24+
" – Quotes are nestable;
25+
" – The delimiters can be redefined with changequote(); here we only handle
26+
" the default pair: ` ... ';
27+
" – Quoted text in M4 is rescanned, not treated as a literal string;
28+
" Therefore the region is marked transparent so contained items retain
29+
" their normal highlighting.
30+
syn region m4Quoted
31+
\ matchgroup=m4QuoteDelim
32+
\ start=+`+
33+
\ end=+'+
34+
\ contains=@m4Top
35+
\ transparent
36+
2137
" define the m4 syntax
2238
syn match m4Variable contained "\$\d\+"
2339
syn match m4Special contained "$[@*#]"
@@ -30,28 +46,26 @@ syn region m4Paren matchgroup=m4Delimiter start="(" end=")" contained contain
3046
syn region m4Command matchgroup=m4Function start="\<\(m4_\)\=\(define\|defn\|pushdef\)(" end=")" contains=@m4Top
3147
syn region m4Command matchgroup=m4Preproc start="\<\(m4_\)\=\(include\|sinclude\)("he=e-1 end=")" contains=@m4Top
3248
syn region m4Command matchgroup=m4Statement start="\<\(m4_\)\=\(syscmd\|esyscmd\|ifdef\|ifelse\|indir\|builtin\|shift\|errprint\|m4exit\|changecom\|changequote\|changeword\|m4wrap\|debugfile\|divert\|undivert\)("he=e-1 end=")" contains=@m4Top
33-
syn region m4Command matchgroup=m4builtin start="\<\(m4_\)\=\(len\|index\|regexp\|substr\|translit\|patsubst\|format\|incr\|decr\|eval\|maketemp\)("he=e-1 end=")" contains=@m4Top
49+
syn region m4Command matchgroup=m4Builtin start="\<\(m4_\)\=\(len\|index\|regexp\|substr\|translit\|patsubst\|format\|incr\|decr\|eval\|maketemp\)("he=e-1 end=")" contains=@m4Top
3450
syn keyword m4Statement divert undivert
3551
syn region m4Command matchgroup=m4Type start="\<\(m4_\)\=\(undefine\|popdef\)("he=e-1 end=")" contains=@m4Top
3652
syn region m4Function matchgroup=m4Type start="\<[_A-Z][_A-Z0-9]*("he=e-1 end=")" contains=@m4Top
37-
syn region m4String start="`" end="'" contains=SpellErrors
38-
syn cluster m4Top contains=m4Comment,m4Constants,m4Special,m4Variable,m4String,m4Paren,m4Command,m4Statement,m4Function
53+
syn cluster m4Top contains=m4Comment,m4Constants,m4Special,m4Variable,m4Paren,m4Command,m4Statement,m4Function,m4Quoted
3954

4055
" Define the default highlighting.
4156
" Only when an item doesn't have highlighting yet
42-
hi def link m4Delimiter Delimiter
43-
hi def link m4Comment Comment
44-
hi def link m4Function Function
45-
hi def link m4Keyword Keyword
46-
hi def link m4Special Special
47-
hi def link m4String String
48-
hi def link m4Statement Statement
49-
hi def link m4Preproc PreProc
50-
hi def link m4Type Type
51-
hi def link m4Special Special
52-
hi def link m4Variable Special
53-
hi def link m4Constants Constant
54-
hi def link m4Builtin Statement
57+
hi def link m4QuoteDelim Delimiter
58+
hi def link m4Delimiter Delimiter
59+
hi def link m4Comment Comment
60+
hi def link m4Function Function
61+
hi def link m4Keyword Keyword
62+
hi def link m4Special Special
63+
hi def link m4Statement Statement
64+
hi def link m4Preproc PreProc
65+
hi def link m4Type Type
66+
hi def link m4Variable Special
67+
hi def link m4Constants Constant
68+
hi def link m4Builtin Statement
5569

5670
let b:current_syntax = "m4"
5771

0 commit comments

Comments
 (0)