Commit graph

678 commits

Author SHA1 Message Date
Selwyn
18e07addfd
Use Vue language server based on Volar (#7312) 2023-06-12 00:46:47 +09:00
Luca Schlecker
dbd248fdfa add config option for instant completion entry preview (defaulting to true).
Signed-off-by: Luca Schlecker <luca.schlecker@hotmail.com>
2023-06-09 13:23:29 -04:00
spectre256
00b152facd
Add register statusline element (#7222) 2023-06-08 14:34:07 -05:00
Tshepang Mbambo
e2a1678436
Fix book configuration for edit template (#7278) 2023-06-08 17:12:36 +09:00
Tshepang Mbambo
27891cdc8d
misc doc fixes/improvements (#7282) 2023-06-08 13:27:58 +09:00
Christoph Sax
d324feb072
Add support for language t32 (#7140)
Co-authored-by: Christoph Sax <christoph.sax@mailbox.org>
2023-06-07 18:01:25 -05:00
Tshepang Mbambo
2f9b63999f
Break long sentence in book configuration footnote (#7279) 2023-06-07 23:19:55 +02:00
Alexander Brevig
78e8695420
Add support for Forth (#7256) 2023-06-06 08:14:34 -05:00
Ivan Tkachuk
2022e6175b
Add blueprint language (#7213)
* Add blueprint tree-sitter support

* Add blueprint lsp support

* Run cargo xtask docgen
2023-06-05 10:40:14 +02:00
Rich Seymour
751da01303
Update install.md instructions regarding symlinks (#7231)
* Update install.md

Fixes `ln` command line bug that could hit users moving from packaged to source builds.

* Remove extra 'how to' command example
2023-06-05 02:06:25 +02:00
avaunit02
232d9f96a0
Fix textobject keybindings in usage docs (#7197) 2023-06-04 17:20:54 +02:00
Zisulin Morbrot
d511122279
Add description for 'ui.text.focus' in theme docs (#7177) 2023-05-31 06:57:17 +08:00
Martin Weinelt
61a89956e3
book: Mention Helix package in nixpkgs (#7064) 2023-05-26 04:33:20 -05:00
Blaž Hrastnik
0266ec6ba3
Update language support doc 2023-05-26 13:43:41 +09:00
LeoniePhiline
41f52d74fe
fix(docs): Remove config from language configuration docs (#7082) 2023-05-19 19:27:21 -05:00
Szabin
70e4cdbd8e
Add command to merge non-consecutive ranges (#7053)
* Add command for merging non-consecutive ranges

* Add `merge_selections` command to book

* Simplify `merge_ranges`

Heeded the advice of @the-mikedavis to stop iterating over all ranges and simply merge the first and the last range, as the invariants of `Selection` guarantee that the list of ranges is always sorted and never empty.

* Clarify doc comment of `merge_ranges`
2023-05-20 01:31:39 +02:00
Philipp Mildenberger
f8fa0d8a10 Clarify language-servers documentation for mergeable LSP features (diagnostics, code-action, completion, document-symbols and workspace-symbols) 2023-05-18 22:11:38 +02:00
Philipp Mildenberger
7d20740b5b Fix docgen and lsp-stop documentation 2023-05-18 21:48:32 +02:00
Philipp Mildenberger
d963050621 Format/fix language docs a bit 2023-05-18 21:48:32 +02:00
Philipp Mildenberger
74e21e1b25 Fix some lints/docgen hints 2023-05-18 21:48:32 +02:00
Philipp Mildenberger
71551d395b Adds support for multiple language servers per language.
Language Servers are now configured in a separate table in `languages.toml`:

```toml
[langauge-server.mylang-lsp]
command = "mylang-lsp"
args = ["--stdio"]
config = { provideFormatter = true }

[language-server.efm-lsp-prettier]
command = "efm-langserver"

[language-server.efm-lsp-prettier.config]
documentFormatting = true
languages = { typescript = [ { formatCommand ="prettier --stdin-filepath ${INPUT}", formatStdin = true } ] }
```

The language server for a language is configured like this (`typescript-language-server` is configured by default):

```toml
[[language]]
name = "typescript"
language-servers = [ { name = "efm-lsp-prettier", only-features = [ "format" ] }, "typescript-language-server" ]
```

or equivalent:

```toml
[[language]]
name = "typescript"
language-servers = [ { name = "typescript-language-server", except-features = [ "format" ] }, "efm-lsp-prettier" ]
```

Each requested LSP feature is priorized in the order of the `language-servers` array.
For example the first `goto-definition` supported language server (in this case `typescript-language-server`) will be taken for the relevant LSP request (command `goto_definition`).

If no `except-features` or `only-features` is given all features for the language server are enabled, as long as the language server supports these. If it doesn't the next language server which supports the feature is tried.

The list of supported features are:

- `format`
- `goto-definition`
- `goto-declaration`
- `goto-type-definition`
- `goto-reference`
- `goto-implementation`
- `signature-help`
- `hover`
- `document-highlight`
- `completion`
- `code-action`
- `workspace-command`
- `document-symbols`
- `workspace-symbols`
- `diagnostics`
- `rename-symbol`
- `inlay-hints`

Another side-effect/difference that comes with this PR, is that only one language server instance is started if different languages use the same language server.
2023-05-18 21:48:30 +02:00
Kitsu
92c328c088
Add wbc and wbc! commands (#6947) 2023-05-09 22:21:29 +02:00
Ollie Charles
8424f387b5
Remove tree-sitter-cabal (#6996) 2023-05-09 21:31:22 +02:00
David Else
69332ae3b2
Add Flathub as third party repository (#6994) 2023-05-09 15:38:36 +02:00
Dave Powers
5ae30f1993
Fix keymap select / extend mode anchor link (#6974) 2023-05-05 09:43:56 -05:00
taupiqueur
c49faf5681
Add language server command for Crystal (#6948) 2023-05-03 09:43:37 +09:00
sscheele
f52e81b1f3
Update docs for move_visual_line_* (#6918) 2023-04-30 14:26:18 -05:00
Timothy DeHerrera
9c6c63a2be
inject language based on file extension & shebang (#3970)
* inject language based on file extension

Nodes can now be captured with "injection.filename". If this capture
contains a valid file extension known to Helix, then the content will
be highlighted as that language.

* inject language by shebang

Nodes can now be captured with "injection.shebang". If this capture
contains a valid shebang line known to Helix, then the content will
be highlighted as the language the shebang calls for.

* add documentation for language injection

* nix: fix highlights

The `@` is now highlighted properly on either side of the function arg.

Also, extending the phases with `buildPhase = prev.buildPhase + ''''`
is now highlighted properly.

Fix highlighting of `''$` style escapes (requires tree-sitter-nix bump)

Fix `inherit` highlighting.

* simplify injection_for_match

Split out injection pair logic into its own method to make the overall
flow easier to follow.

Also transform the top-level function into a method on a
HighlightConfiguration.

* markdown: add shebang injection query
2023-04-28 18:21:34 +09:00
jorge
204d1eba4b
feat(commands): add clear-register typable command (#5695)
Co-authored-by: Jorge <chorcheus@tutanota.com>
2023-04-27 21:57:05 +02:00
ap29600
9cdc6b2e8a
Change Odin grammar to ap29600/tree-sitter-odin (#6766)
* Change Odin grammar to `ap29600/tree-sitter-odin`

The previously adopted grammar, `MineBill/tree-sitter-odin`, is unmaintained and mentions my repository as an alternative source.

* update queries

* docgen

* fix queries

* Update runtime/queries/odin/highlights.scm

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* remove `ERROR` query for `odin`

* track the latest rev in `ap29600/tree-sitter-odin`

* runtime/queries/odin/highlights.scm: update rune highlight class

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2023-04-27 16:32:21 +02:00
Vitalii Solodilov
2836ea2ac4
feat: add a config option to exclude declaration from LSP references (#6886)
* feat: added the config option to exclude declaration from reference query

Fixes: #5344

* fix: review

* fix: review
2023-04-27 16:30:15 +02:00
Wesley
903bdaae87
Set PerlNavigator as the language server for Perl (#6860) 2023-04-27 01:28:54 +02:00
Atticus Sebastiani
228a4af35f
make :u alias :update (#6835)
* Gave the command update the alias u

* Re added trailing newline

* generated docs
2023-04-23 04:07:34 +02:00
Michael T. Mordowanec
a1044a6c68
Change soft-wrap.wrap_at_text_width to kebab case in documentation (#6842)
Solves #6803.
2023-04-21 16:45:50 -05:00
David Else
83c307a66a
Improve and update the installation documentation (#6809) 2023-04-20 00:56:18 +02:00
VuiMuich
4cdba7cccd
Add standalone language support for just (#6453)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2023-04-14 17:03:21 +02:00
Michael
161fef2166
Add DTD language support (#6644)
- Added syntax highlighting for the DTD subset of the XML spec.
- Included .dtd and .ent as common file extensions
2023-04-12 15:28:51 -05:00
lefp
fff8543b58
Add OpenCL tree-sitter and LSP config (#6473) 2023-04-12 14:42:41 -05:00
Matouš Dzivjak
70de5026b8
feat(languages): Support markdoc (#6432)
Add basic support for [markdoc](https://markdoc.dev/).

For language server, see: https://github.com/markdoc-extra/markdoc-ls
For tree sitter, see: https://github.com/markdoc-extra/tree-sitter-markdoc
2023-04-12 10:28:03 -05:00
Ollie Charles
92c5f5f18c
Initial Cabal language support (#6485) 2023-04-12 08:38:11 -05:00
tippfehlr
5106a124ed
Fix file-picker.follow-symlinks config option name in docs (#6685) 2023-04-10 10:09:45 -05:00
Nico Bos
894c2b9edb
Add Windows install instructions using Winget (#6602) 2023-04-09 14:57:41 -05:00
Alireza Alavi
78b516430a
Fix minor grammar issue in 'from-vim' docs (#6667) 2023-04-09 14:23:57 -05:00
karei
1148ce1fd9
Add support for Robot Framework files (#6611)
* Add support for Robot Framework files

* Run docgen
2023-04-07 08:19:48 +08:00
Clara Hobbs
4b32b544fc
Add textobject queries for Julia (#6588)
* Add textobjects queries for Julia

* Update docs for Julia textobject queries
2023-04-07 00:35:05 +08:00
Erasin Wang
c22ebfe62e
Add Hurl Support (#6450)
* Add http Support

It's like [vscode-restclient](https://github.com/Huachao/vscode-restclient)

- https://github.com/erasin/tree-sitter-http/tree/main/tests

* Add Hurl Support
2023-04-07 00:26:41 +08:00
Pascal Kuthe
9fe3adcff9
add option to enable/disable lsp snippets 2023-03-31 15:19:36 +09:00
Clara Hobbs
d284444eb4
Add indents.scm for Julia (#6490)
* Add indents.scm for Julia

* Update documentation for new indent support
2023-03-31 10:32:36 +09:00
Pascal Kuthe
5b3dd6a678 implement proper lsp-workspace support
fix typo

Co-authored-by: LeoniePhiline <22329650+LeoniePhiline@users.noreply.github.com>
2023-03-29 12:57:30 +09:00
Pascal Kuthe
2d10a429eb add workspace config and manual LSP root management
fixup documentation

Co-authored-by: LeoniePhiline <22329650+LeoniePhiline@users.noreply.github.com>

fixup typo

Co-authored-by: LeoniePhiline <22329650+LeoniePhiline@users.noreply.github.com>
2023-03-29 12:57:30 +09:00
Filip Dutescu
d59b80514e
feat(debug): highlight current line (#5957)
Add new theme highlight keys, for setting the colour of the breakpoint
character and the current line at which execution has been paused at.
The two new keys are `ui.highlight.frameline` and `ui.debug.breakpoint`.
Highlight according to those keys, both the line at which debugging
is paused at and the breakpoint indicator.

Add an indicator for the current line at which execution is paused
at, themed by the `ui.debug.active` theme scope. Update various themes
to showcase how the new functionality works.

Better icons are dependent on #2869, and as such will be handled in the
future, once it lands.

Closes: #5952

Signed-off-by: Filip Dutescu <filip.dutescu@gmail.com>
2023-03-29 12:52:19 +09:00
Michael Davis
d7431db55c
Update tree-sitter-git-commit, add comment textobject (#6439)
The update includes a fix for comments in commit messages where there
was no space separating the '#' and the comment text.

The comment textobject can be useful occasionally to jump to the
summary part of the commit edit message.
2023-03-27 15:27:38 +09:00
JJ
c8fde8b6f9
Initial Nim language support (#6123) 2023-03-26 17:06:48 -05:00
Juan C. Müller
5d7c90c5cf
Add language support for rego (OpenPolicyAgent) (#6415) 2023-03-26 16:49:37 -05:00
Tom Burdick
685ae2365a
Add vhdl language support (#5826)
Simple highlight query file with keywords and builtin types
matching. Many VHDL types however are defined in std libraries
which do not currently get matched on.

This is because the grammar doesn't consider them builtin types.
2023-03-25 12:10:54 -05:00
Erasin Wang
851ac6cdd3
Add theme keys for (un)checked markup list items (#6434) 2023-03-25 11:41:31 -05:00
Juan C. Müller
6acd200028
Fix spelling of diagnostics (#6418) 2023-03-24 11:26:41 +09:00
zetashift
0e0c16e6fa
Add initial Smithy support (#6370) 2023-03-21 17:12:24 -05:00
Gautam Panchal
3da63fa481
Add instructions for installing via AppImage (#6368) 2023-03-20 18:36:27 -05:00
Aaron Bull Schaefer
203cf1a919
Document ui.highlight theme key (#6372)
This scope was added via bf5b9a9f35
2023-03-20 21:55:48 +08:00
angelodlfrtr
ac2a7731a6
Add language support for Cap’n Proto format (#6325) 2023-03-18 09:17:02 -05:00
Erasin Wang
fb56a4bb75
Improve tree-sitter queries for vlang (#6279)
- Update hightlight
- add indents
- add textobject
- add injections
2023-03-15 16:22:24 -05:00
Jonatan Pettersson
d479adfdc6
Add undercurl config option #6196 (#6253)
If set to 'true' this option will force terminal undercurl support.
2023-03-14 11:53:38 +09:00
Erasin Wang
221a4ac883
Theme onelight add inlay-hint (#6276)
- fix: add `markup.strikethrough` for theme.md 
- add virtual.inlay-hint
- fix ui.virtual.wrap
- rename light-white to grey-300
2023-03-12 11:56:54 -05:00
Poliorcetics
bdcd4d9411
Feat: LSP Type Hints (#5934)
* misc: missing inline, outdated link

* doc: Add new theme keys and config option to book

* fix: don't panic in Tree::try_get(view_id)

Necessary for later, where we could be receiving an LSP response
for a closed window, in which case we don't want to crash while
checking for its existence

* fix: reset idle timer on all mouse events

* refacto: Introduce Overlay::new and InlineAnnotation::new

* refacto: extract make_job_callback from Context::callback

* feat: add LSP display_inlay_hint option to config

* feat: communicate inlay hints support capabilities of helix to LSP server

* feat: Add function to request range of inlay hint from LSP

* feat: Save inlay hints in document, per view

* feat: Update inlay hints on document changes

* feat: Compute inlay hints on idle timeout

* nit: Add todo's about inlay hints for later

* fix: compute text annotations for current view in view.rs, not document.rs

* doc: Improve Document::text_annotations() description

* nit: getters don't use 'get_' in front

* fix: Drop inlay hints annotations on config refresh if necessary

* fix: padding theming for LSP inlay hints

* fix: tracking of outdated inlay hints should not be dependant on document revision (because of undos and such)

* fix: follow LSP spec and don't highlight padding as virtual text

* config: add some LSP inlay hint configs
2023-03-11 11:32:14 +09:00
Dimitar Gyurov
1661e4b5e1
Add a version-control statusline element (#5682) 2023-03-10 16:42:42 -06:00
Philipp Mildenberger
98415f288f
Improved yuck highlighting (and parser), and introduced a tag.builtin scope (#6242) 2023-03-10 10:32:45 -06:00
Pascal Kuthe
d63e570e0a treat replace/insertmode consistently, default to insert 2023-03-10 16:54:17 +09:00
paul-scott
ce1fb9e64c
Generalised to multiple runtime directories with priorities (#5411)
* Generalised to multiple runtime directories with priorities

This is an implementation for #3346.

Previously, one of the following runtime directories were used:

1. `$HELIX_RUNTIME`
2. sibling directory to `$CARGO_MANIFEST_DIR`
3. subdirectory of user config directory
4. subdirectory of path to helix executable

The first directory provided / found to exist in this order was used as a
root for all runtime file searches (grammars, themes, queries).

This change lowers the priority of `$HELIX_RUNTIME` so that the user
config runtime has higher priority. More significantly, all of these
directories are now searched for runtime files, enabling a user to override
default or system-level runtime files. If the same file name appears
in multiple runtime directories, the following priority is now used:

1. sibling directory to `$CARGO_MANIFEST_DIR`
2. subdirectory of user config directory
3. `$HELIX_RUNTIME`
4. subdirectory of path to helix executable

One exception to this rule is that a user can have a `themes`
directory directly in the user config directory that has higher piority
to `themes` directories in runtime directories. That behaviour has been
preserved.

As part of implementing this feature `theme::Loader` was simplified
and the cycle detection logic of the theme inheritance was improved to
cover more cases and to be more explicit.

* Removed AsRef usage to avoid binary growth

* Health displaying ;-separated runtime dirs

* Changed HELIX_RUNTIME build from src instructions

* Updated doc for more detail on runtime directories

* Improved health symlink printing and theme cycle errors

The health display of runtime symlinks now prints both ends of the
link.

Separate errors are given when theme file is not found and when the
only theme file found would form an inheritence cycle.

* Satisfied clippy on passing Path

* Clarified highest priority runtime directory purpose

* Further clarified multiple runtime details in book

Also gave markdown headings to subsections.

Fixed a error with table indentation not building
table that also appears present on master.

---------

Co-authored-by: Paul Scott <paul.scott@anu.edu.au>
Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
2023-03-09 23:50:43 +09:00
Clément Delafargue
8dd1ab4899
Softwrapping improvements (#5893)
* use max_line_width + 1 during softwrap to account for newline char

Helix softwrap implementation always wraps lines so that the newline
character doesn't get cut off so he line wraps one chars earlier then
in other editors. This is necessary, because newline chars are always
selecatble in helix and must never be hidden.

However That means that `max_line_width` currently wraps one char
earlier than expected. The typical definition of line width does not
include the newline character and other helix commands like `:reflow`
also don't count the newline character here.

This commit makes softwrap use `max_line_width + 1` instead of
`max_line_width` to correct the impedance missmatch.

* fix typos

Co-authored-by: Jonathan Lebon <jonathan@jlebon.com>

* Add text-width to config.toml

* text-width: update setting documentation

* rename leftover config item

* remove leftover max-line-length occurrences

* Make `text-width` optional in editor config

When it was only used for `:reflow` it made sense to have a default
value set to `80`, but now that soft-wrapping uses this setting, keeping
a default set to `80` would make soft-wrapping behave more aggressively.

* Allow softwrapping to ignore `text-width`

Softwrapping wraps by default to the viewport width or a configured
`text-width` (whichever's smaller). In some cases we only want to set
`text-width` to use for hard-wrapping and let longer lines flow if they
have enough space. This setting allows that.

* Revert "Make `text-width` optional in editor config"

This reverts commit b247d526d69adf41434b6fd9c4983369c785aa22.

* soft-wrap: allow per-language overrides

* Update book/src/configuration.md

Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>

* Update book/src/languages.md

Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>

* Update book/src/configuration.md

Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>

---------

Co-authored-by: Pascal Kuthe <pascal.kuthe@semimod.de>
Co-authored-by: Jonathan Lebon <jonathan@jlebon.com>
Co-authored-by: Alex Boehm <alexb@ozrunways.com>
Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
2023-03-08 11:02:11 +09:00
Pascal Kuthe
48b6aa9a69
Add command for resetting diff hunks (#5736) 2023-03-08 10:49:14 +09:00
Davide Galassi
f976c004e2
Allow LSP server to be stopped (#5964) 2023-03-07 18:34:31 -06:00
David Else
707457c632
Rewrite and refactor all documentation (#5534)
* Rewrite and refactor all documentation

* Rewrite and refactor the guides

* update runtime directory instructions for windows

* Update the Ubuntu 3rd party repo section with 22.10

* Merge from upstream

* Rewrite and refactor all documentation

* Apply suggestions from code review

Apply the suggestions that can be committed from the GitHub web interface.

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* Add Windows themes folder

Co-authored-by: digidoor <37601466+digidoor@users.noreply.github.com>

* Apply the rest of the suggestions from the code review

* Revert "Apply the rest of the suggestions from the code review"

This reverts commit 498be1b7a1aec3ff567b95130148628beeef9b77.

* Revert "Merge branch 'rewrite-and-refactor-all-documentation' of github.com:David-Else/helix into rewrite-and-refactor-all-documentation"

This reverts commit 7c8404248ffef73b80b9051d5a4359c5bcfa5d1a, reversing
changes made to d932969cfc9fadda12a74cc01665919dee7152fb.

* Apply code review suggestions

* Changes after re-reading all documents

* Missed a full stop

* Code review suggestions and remove macOS and Windows specific sections

* Add OpenBSD to heading

* Add back macOS and Windows sections and further simplify and improve

* Change wording to nightly

* Remove README installation section and turn into a link

* Simplify building from source and follow code review suggestions

* Code review revisions

* Fix copy paste mistake

* Apply the latest code review suggestions

* More small code review items

* Change minor modes for code review

* Fix link and typos

* Add note that you need a c++ compiler to install the tree-sitter grammars

* Add pacman example

* Make sure all headings are lower case

* Revert to the original passage adding a reference to Windows that was missing

* Update book/src/guides/adding_languages.md

Fix grammar typo

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* Update book/src/install.md

Fix tree sitter typo

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* Remove TOC links to main heading

---------

Co-authored-by: CptPotato <3957610+CptPotato@users.noreply.github.com>
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
Co-authored-by: digidoor <37601466+digidoor@users.noreply.github.com>
2023-03-06 18:27:17 +09:00
cinerea0
5ebe1014ac
docs: describe tab-width and unit subkeys (#5862) 2023-03-06 18:20:24 +09:00
Roberto Vidal
725d9aecf0
Add support for reStructuredText (#6180) 2023-03-04 20:36:01 -06:00
Nick
bf872366fd
Document the file-modification-indicator statusline element (#6036) 2023-03-04 11:34:17 -06:00
Matthias Q
2bd8bc8d84
feat(prql): add prql support (#6126) 2023-03-03 13:12:37 -06:00
lesleyrs
8dab8a0a03 Add shift-backspace keybind alias for backspace (#4937)
When the Kitty Keyboard Protocol is enabled, S-backspace is
distinguished from backspace with no modifiers. This is awkward when
typing because it's very easy to accidentally hold shift and press
backspace temporarily when typing capital letters.

Kakoune (which is also a Kitty Keyboard Protocol application) treats
S-backspace as backspace too:
3150e9b3cd/src/input_handler.cc (L1275)
2023-02-28 12:35:52 +09:00
Mathieu Agopian
a976786a4f
book: Document <space>h and <space>g (#6124) 2023-02-27 21:03:56 -06:00
Mathieu Agopian
98a3d46912
Add elm treesitter textobjects (#6084) 2023-02-25 12:55:44 -06:00
Matthew Toohey
a4049e6f55
feat: add nasm language (#6068) 2023-02-25 12:53:37 -06:00
Sophie Dankel
f69bb41169
Add language support for sway (#6023) 2023-02-25 12:47:54 -06:00
Erasin
864ee8fdef
Add GNU gettext PO grammar (#5996) 2023-02-20 17:04:17 -06:00
Philipp Mildenberger
b89b2eaf68
Added yuck language support (for eww) (#6064) 2023-02-20 16:42:54 -06:00
Jummit
5ff2cb24e2
Add support for the uxntal language (#6047) 2023-02-19 12:32:42 -06:00
Guillaume
78a1e2db60
feat: show current language when no argument is provided (#5895) 2023-02-16 23:48:35 +09:00
vwkd
72e5704f52
docs: clarify join_selections_space (#5969) 2023-02-13 13:46:47 -06:00
A-Walrus
8b09b00942
Add :toggle-option command (#4085)
This command toggles the value of boolean options
2023-02-13 11:40:31 +09:00
Erasin
c71b4c5579
Update grammar for godot (#5944)
* update grammar for gdscript.
* add comment injections for gdscript.
* add indent for gdscript
* add file-type support for godot-resource
2023-02-12 14:03:02 -06:00
ath3
1840d775c8
Added tree-sitter-hosts (#4950) 2023-02-10 11:32:04 -06:00
ath3
189c3c2ddc
Add tree-sitter-passwd (#4959) 2023-02-10 11:12:46 -06:00
Matthew Toohey
05c5207265
feat: add pem language (#5797) 2023-02-07 17:24:26 -06:00
Jaeho Choi
0eba0db4a0
docs: Fix PowerShell runtime linking command (#5822) 2023-02-05 13:31:20 -06:00
Alex
d6e2434f73
Add ui.virtual.wrap to theme docs (#5823) 2023-02-04 10:33:53 -06:00
William Etheredge
f7bd7b5eaf
Add :character-info command (#4000) 2023-02-03 08:24:46 -06:00
Brett Lyons
d8f482e11e
Add MSBuild language based on XML grammar (#5793) 2023-02-03 08:24:22 -06:00
Skyler Hawthorne
06d095f31c provide option to completely disable lsp 2023-02-02 14:53:18 -05:00
Pascal Kuthe
6ed2348078
Hide duplicate symlinks from the picker (#5658)
* hide duplicate symlinks from the picker

* Apply suggestions from code review

Co-authored-by: g-re-g <123515925+g-re-g@users.noreply.github.com>

* minor stylistic fix

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

---------

Co-authored-by: g-re-g <123515925+g-re-g@users.noreply.github.com>
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2023-02-02 11:14:02 -06:00
Pascal Kuthe
4dcf1fe66b
rework positioning/rendering and enable softwrap/virtual text (#5420)
* rework positioning/rendering, enables softwrap/virtual text

This commit is a large rework of the core text positioning and
rendering code in helix to remove the assumption that on-screen
columns/lines correspond to text columns/lines.

A generic `DocFormatter` is introduced that positions graphemes on
and is used both for rendering and for movements/scrolling.
Both virtual text support (inline, grapheme overlay and multi-line)
and a capable softwrap implementation is included.

fix picker highlight

cleanup doc formatter, use word bondaries for wrapping

make visual vertical movement a seperate commnad

estimate line gutter width to improve performance

cache cursor position

cleanup and optimize doc formatter

cleanup documentation

fix typos

Co-authored-by: Daniel Hines <d4hines@gmail.com>

update documentation

fix panic in last_visual_line funciton

improve soft-wrap documentation

add extend_visual_line_up/down commands

fix non-visual vertical movement

streamline virtual text highlighting, add softwrap indicator

fix cursor position if softwrap is disabled

improve documentation of text_annotations module

avoid crashes if view anchor is out of bounds

fix: consider horizontal offset when traslation char_idx -> vpos

improve default configuration

fix: mixed up horizontal and vertical offset

reset view position after config reload

apply suggestions from review

disabled softwrap for very small screens to avoid endless spin

fix wrap_indicator setting

fix bar cursor disappearring on the EOF character

add keybinding for linewise vertical movement

fix: inconsistent gutter highlights

improve virtual text API

make scope idx lookup more ergonomic

allow overlapping overlays

correctly track char_pos for virtual text

adjust configuration

deprecate old position fucntions

fix infinite loop in highlight lookup

fix gutter style

fix formatting

document max-line-width interaction with softwrap

change wrap-indicator example to use empty string

fix: rare panic when view is in invalid state (bis)

* Apply suggestions from code review

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* improve documentation for positoning functions

* simplify tests

* fix documentation of Grapheme::width

* Apply suggestions from code review

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* add explicit drop invocation

* Add explicit MoveFn type alias

* add docuntation to Editor::cursor_cache

* fix a few typos

* explain use of allow(deprecated)

* make gj and gk extend in select mode

* remove unneded debug and TODO

* mark tab_width_at #[inline]

* add fast-path to move_vertically_visual in case softwrap is disabled

* rename first_line to first_visual_line

* simplify duplicate if/else

---------

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2023-02-01 02:03:19 +09:00
Antonius Naumann
56c0810c68
Change default language server for 'v' from 'vls' to 'v ls' (#5677) 2023-01-25 09:56:51 -06:00