Sign in Join
Wiki copytemporary

Revision 2 of 4, by WikiArchive on 11-4-2026. The page as it is now.

CudaText files formats

Contents

Format of auto-completion acp file

Common auto-completion file format is ANSI text file, it contains list of lines in forms:

pascal
Type Id |Hint
    Type Id (Param1; Param2; ...) |Hint
    Type Id (Param1; Param2; ...): ResultType |Hint

First line in the file can be the "control" line: it specifies what chars are "word chars" for the used syntax. For example, if word chars are minus, dot, and # sign, the control line should be:

pascal
#chars .-#

Format of install.inf files

User can open addons in zip files (using "File-Open") and install them. To make such zip file, pack into zip also "install.inf" with meta-info.

Install.inf supported "os" values

Value of "os" field is comma-separated list of platforms (no spaces around commas). Each platform is supported OS name, with optional trailing "-" and CPU family name.

OS names are:

CPU families are:

So for example Windows x86 platform values are "win" and "win-i386", Linux AMD64 platform values are "linux" and "linux-x86_64".

Install.inf for plugins

Example of install.inf for plugin (plugin adds 2 menu items with menu separator between):

pascal
[info]
    title=MyName
    desc=Plugin allows smth
    type=cudatext-plugin
    subdir=cuda_test
    homepage=http://github.com/some/name/
    api=1.0.200
    
    [item1]
    section=commands
    caption=MyPlugin\Cmd one
    method=run
    lexers=CSS,HTML
    hotkey=Alt+F
    
    [item2]
    section=commands
    caption=MyPlugin\-
    method=nnnn
    
    [item3]
    section=commands
    caption=MyPlugin\Cmd other
    method=run_more
    menu=0

Section names: "item" followed by any string (e.g. "item1"). Fields in sections:

Only for "section=events":

Install.inf sidebar buttons

CudaText can show plugin's sidebar buttons even without running the plugin in "on_start" event. Plugin should add sections "sidebar*" ("*" means any substring), with the keys:

Plugin should add sections "bottombar*" ("*" means any substring) to perform the same, but for the bottom part of sidebar, where buttons "Console" and "Output" are placed.

Install.inf lexer lists

If plugin has many [itemN] sections, it is possible to set list of lexers using variable (not to write each time "lexers=name,name2,name3"). Declare list of lexers in [info] section like this, any variable name:

pascal
[info]
    $var=Name1,Name2,Name3

In [itemN] sections set lexers like this:

pascal
[itemN]
    lexers=$var

You can set lexers by reg-ex, e.g. reg-ex ".SQL." means all names with substring "SQL". To do it, write variable with prefix:

pascal
[info]
    $var=regex:.*SQL.*

Install.inf for data files

Example of install.inf for data files, to be copied into subdir of "data" dir. Name of subdir can be any, for example "themes".

pascal
[info]
    title=NiceDarkTheme
    desc=Nice Dark theme (by AuthorName)
    type=cudatext-data
    subdir=themes

Install.inf for lexers

To see example of install.inf for lexers, download any lexer. To see complex example, download lexer zip for "HTML Smarty" which has 2 lexers inside, one lexer is linked to another.

pascal
[info]
    title=HTML Smarty
    type=lexer
    subdir=-
    
    [lexer1]
    file=HTML Smarty internal
    [lexer2]
    file=HTML Smarty
    link1=CSS
    link2=VBScript
    link3=JavaScript
    link4=JavaScript
    link5=VBScript
    link6=PHP
    link7=PHP
    link8=HTML Smarty internal

Install.inf for lite lexers

Example of install.inf for lite lexer. Note that "^" suffix not needed here.

pascal
[info]
    title=MyLexer
    type=lexer-lite
    subdir=-

Format of .cuda-lexops files

Files keep lexer styles, which user changed in the "Lexer Properties" dialog. JSON format.

Root keys:

Color in Pascal format: hex number (6..8 digits) with "$" prefix, or constants. See possible constants (with hex values) in Lazarus file Graphics.pp, where string 'clBlack' is defined. https://gitlab.com/freepascal.org/lazarus/lazarus/-/blob/main/lcl/graphics.pp


From the Free Pascal wiki, page "CudaText files formats", as the Internet Archive kept it on 2023-12-03. Copyright stays with the author who wrote it, according to the old wiki's Licensing page. If you have concerns about this material, message the admin.