Cargo Features
[dependencies]
syntect = { version = "5.2.0", default-features = false, features = ["dump-load", "dump-create", "regex-fancy", "regex-onig", "parsing", "metadata", "default-syntaxes", "default-themes", "html", "plist-load", "yaml-load", "default-onig", "default-fancy"] }
- dump-load default-fancy? default-onig default-syntaxes? default-themes? parsing? = bincode, flate2
-
Dump loading using flate2
Affects
dumps::from_reader
,dumps::from_binary
,dumps::from_dump_file
,dumps::from_uncompressed_dump_file
,dumps::from_uncompressed_data
,syntect::dumps
… - dump-create default-fancy? default-onig parsing? = bincode, flate2
-
Dump creation using flate2
Affects
dumps::dump_to_writer
,dumps::dump_binary
,dumps::dump_to_file
,dumps::dump_to_uncompressed_file
,syntect::dumps
… - regex-fancy default-fancy? = fancy-regex
- regex-onig default-onig = onig
- parsing default-fancy? default-onig default-syntaxes? html? metadata? yaml-load? = dump-create, dump-load, fnv, regex-syntax
-
Affects
syntect::easy
,parsing::syntax_definition
,util::debug_print_ops
… - metadata = parsing, plist-load
-
Support for .tmPreferenes metadata files (indentation, comment syntax, etc)
Affects
parsing::metadata
… - default-syntaxes default-fancy? default-onig = dump-load, parsing
-
Enables inclusion of the default syntax packages.
- default-themes default-fancy? default-onig = dump-load
-
Enables inclusion of the default theme packages.
- html default-fancy? default-onig = parsing
-
Affects
syntect::html
… - plist-load default-fancy? default-onig metadata? = plist
-
Support for parsing .tmTheme files and .tmPreferences files
- yaml-load default-fancy? default-onig = parsing, yaml-rust
-
Support for parsing .sublime-syntax files
- default-onig default = default-syntaxes, default-themes, dump-create, dump-load, html, parsing, plist-load, regex-onig, yaml-load
- default-fancy = default-syntaxes, default-themes, dump-create, dump-load, html, parsing, plist-load, regex-fancy, yaml-load
-
In order to switch to the fancy-regex engine, disable default features then add the default-fancy feature
- default = default-onig
-
The
default-onig
feature is set by default wheneversyntect
is added without
somewhere in the dependency tree.default-features = false
Features from optional dependencies
In crates that don't use the dep:
syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.