Commit Graph
13 Commits
Author SHA1 Message Date
3bb5610ad1 Overhaul handling of font families
* Specify font families in the theme.
* Load fonts eagerly when loading themes, instead of loading
  them lazily when rendering.

Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-26 15:06:00 -07:00
Max BrunsfeldandNathan Sobo 802f1f4e78 Get new theme structure working
* Fix precedence of extends directives
* Always group color with font properties for text theming

Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-04 14:07:19 -07:00
Nathan Sobo bbf803d7dc Store a reference to the LangageRegistry on the Worktree 2021-06-29 20:07:37 -06:00
Max BrunsfeldandNathan Sobo 8b7a314474 Implement bracket matching using queries
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-05-28 13:09:57 -07:00
bf8eee26f8 Add Buffer::enclosing_bracket_ranges
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2021-05-28 19:35:04 +02:00
Antonio Scandurra 07aeb32ef4 Punt on auto-indentation for now 2021-05-28 10:17:10 +02:00
Max BrunsfeldandNathan Sobo 7bea3fd2fe Start on a query-based autoindent system
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-05-26 17:23:53 -07:00
Antonio Scandurra d38d944fef Add indent and indent_nodes configs in the language config.toml 2021-05-26 15:45:58 +02:00
Antonio Scandurra 04c7989720 Extract a LanguageConfig and load it from language-dir/config.toml 2021-05-26 10:27:14 +02:00
Antonio Scandurra 43ddb6f640 WIP: Push failing test for DisplayMap::highlighted_chunks_at 2021-05-25 17:20:46 +02:00
Max Brunsfeld 8340958b33 Convert query capture indices to style ids
* Introduce a Theme struct as a new part of the app's settings
* Store on each Language a ThemeMap, which converts the capture ids
  from that language's highlight query into StyleIds, which identify
  styles in the current Theme.
* Update `highlighted_chunks` methods to provide StyleIds instead of
  capture ids.
2021-05-24 16:44:14 -07:00
Max Brunsfeld 46e6b2cff4 Start maintaining a syntax tree on buffers 2021-05-22 12:34:35 +02:00
2f378be1a8 Introduce LanguageRegistry object
* Include it, along with settings in `OpenParams` grouped under a new struct called `AppState`

Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-05-22 12:34:35 +02:00