aboutsummaryrefslogtreecommitdiffstats
path: root/runtime/queries/desktop/highlights.scm
blob: ce55d7432928885ac459321cda2acabea66fcd0d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
(comment) @comment @spell

(group_name) @markup.heading

(entry
  key: (identifier) @property)

[
  (language)
  (country)
  (encoding)
  (modifier)
] @string.special

(string) @string

(escape_sequence) @string.escape

(field_code) @character.special

[
  (true)
  (false)
] @boolean

"=" @operator

[
  ";"
  "_"
  "."
  "@"
] @punctuation.delimiter

[
  "["
  "]"
] @punctuation.bracket

; Especial entries
((entry
  key: (identifier) @_key
  value: (string) @type)
  (#eq? @_key "Type")
  (#any-of? @type "Application" "Link" "Directory"))

((entry
  key: (identifier) @_key
  value: (string) @number)
  (#eq? @_key "Version"))

((entry
  key: (identifier) @_key
  value: (string) @string.special.path)
  (#any-of? @_key "TryExec" "Path"))

((entry
  key: (identifier) @_key
  value: (string) @string.special.url)
  (#eq? @_key "URL"))

; https://specifications.freedesktop.org/menu-spec/latest/category-registry.html
((entry
  key: (identifier) @_key
  value: (list
    (string) @constant.builtin))
  (#eq? @_key "Categories")
  (#any-of? @constant.builtin
    ; Main categories
    "AudioVideo" "Audio" "Video" "Development" "Education" "Game" "Graphics" "Network" "Office"
    "Science" "Settings" "System" "Utility"
    ; Additional Categories
    "Building" "Debugger" "IDE" "GUIDesigner" "Profiling" "RevisionControl" "Translation" "Calendar"
    "ContactManagement" "Database" "Dictionary" "Chart" "Email" "Finance" "FlowChart" "PDA"
    "ProjectManagement" "Presentation" "Spreadsheet" "WordProcessor" "2DGraphics" "VectorGraphics"
    "RasterGraphics" "3DGraphics" "Scanning" "OCR" "Photography" "Publishing" "Viewer" "TextTools"
    "DesktopSettings" "HardwareSettings" "Printing" "PackageManager" "Dialup" "InstantMessaging"
    "Chat" "IRCClient" "Feed" "FileTransfer" "HamRadio" "News" "P2P" "RemoteAccess" "Telephony"
    "TelephonyTools" "VideoConference" "WebBrowser" "WebDevelopment" "Midi" "Mixer" "Sequencer"
    "Tuner" "TV" "AudioVideoEditing" "Player" "Recorder" "DiscBurning" "ActionGame" "AdventureGame"
    "ArcadeGame" "BoardGame" "BlocksGame" "CardGame" "KidsGame" "LogicGame" "RolePlaying" "Shooter"
    "Simulation" "SportsGame" "StrategyGame" "Art" "Construction" "Music" "Languages"
    "ArtificialIntelligence" "Astronomy" "Biology" "Chemistry" "ComputerScience" "DataVisualization"
    "Economy" "Electricity" "Geography" "Geology" "Geoscience" "History" "Humanities"
    "ImageProcessing" "Literature" "Maps" "Math" "NumericalAnalysis" "MedicalSoftware" "Physics"
    "Robotics" "Spirituality" "Sports" "ParallelComputing" "Amusement" "Archiving" "Compression"
    "Electronics" "Emulator" "Engineering" "FileTools" "FileManager" "TerminalEmulator" "Filesystem"
    "Monitor" "Security" "Accessibility" "Calculator" "Clock" "TextEditor" "Documentation" "Adult"
    "Core" "KDE" "COSMIC" "GNOME" "XFCE" "DDE" "GTK" "Qt" "Motif" "Java" "ConsoleOnly"
    ; Reserved
    "Screensaver" "TrayIcon" "Applet" "Shell"))