Commit Graph

674 Commits (main)

Author SHA1 Message Date
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.
1 year ago
Erasin Wang 851ac6cdd3
Add theme keys for (un)checked markup list items (#6434) 1 year ago
Juan C. Müller 6acd200028
Fix spelling of diagnostics (#6418) 1 year ago
zetashift 0e0c16e6fa
Add initial Smithy support (#6370) 1 year ago
Gautam Panchal 3da63fa481
Add instructions for installing via AppImage (#6368) 1 year ago
Aaron Bull Schaefer 203cf1a919
Document `ui.highlight` theme key (#6372)
This scope was added via bf5b9a9f35
1 year ago
angelodlfrtr ac2a7731a6
Add language support for Cap’n Proto format (#6325) 1 year ago
Erasin Wang fb56a4bb75
Improve tree-sitter queries for vlang (#6279)
- Update hightlight
- add indents
- add textobject
- add injections
1 year ago
Jonatan Pettersson d479adfdc6
Add undercurl config option #6196 (#6253)
If set to 'true' this option will force terminal undercurl support.
1 year ago
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
1 year ago
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
1 year ago
Dimitar Gyurov 1661e4b5e1
Add a version-control statusline element (#5682) 1 year ago
Philipp Mildenberger 98415f288f
Improved yuck highlighting (and parser), and introduced a tag.builtin scope (#6242) 1 year ago
Pascal Kuthe d63e570e0a treat replace/insertmode consistently, default to insert 1 year ago
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>
1 year ago
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>
1 year ago
Pascal Kuthe 48b6aa9a69
Add command for resetting diff hunks (#5736) 1 year ago
Davide Galassi f976c004e2
Allow LSP server to be stopped (#5964) 1 year ago
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>
1 year ago
cinerea0 5ebe1014ac
docs: describe tab-width and unit subkeys (#5862) 1 year ago
Roberto Vidal 725d9aecf0
Add support for reStructuredText (#6180) 1 year ago
Nick bf872366fd
Document the file-modification-indicator statusline element (#6036) 1 year ago
Matthias Q 2bd8bc8d84
feat(prql): add prql support (#6126) 1 year ago
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)
1 year ago
Mathieu Agopian a976786a4f
book: Document <space>h and <space>g (#6124) 1 year ago
Mathieu Agopian 98a3d46912
Add elm treesitter textobjects (#6084) 1 year ago
Matthew Toohey a4049e6f55
feat: add nasm language (#6068) 1 year ago
Sophie Dankel f69bb41169
Add language support for sway (#6023) 1 year ago
Erasin 864ee8fdef
Add GNU gettext PO grammar (#5996) 1 year ago
Philipp Mildenberger b89b2eaf68
Added yuck language support (for eww) (#6064) 1 year ago
Jummit 5ff2cb24e2
Add support for the uxntal language (#6047) 1 year ago
Guillaume 78a1e2db60
feat: show current language when no argument is provided (#5895) 1 year ago
vwkd 72e5704f52
docs: clarify `join_selections_space` (#5969) 1 year ago
A-Walrus 8b09b00942
Add :toggle-option command (#4085)
This command toggles the value of boolean options
1 year ago
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
1 year ago
ath3 1840d775c8
Added tree-sitter-hosts (#4950) 1 year ago
ath3 189c3c2ddc
Add tree-sitter-passwd (#4959) 1 year ago
Matthew Toohey 05c5207265
feat: add pem language (#5797) 1 year ago
Jaeho Choi 0eba0db4a0
docs: Fix PowerShell runtime linking command (#5822) 1 year ago
Alex d6e2434f73
Add `ui.virtual.wrap` to theme docs (#5823) 1 year ago
William Etheredge f7bd7b5eaf
Add :character-info command (#4000) 1 year ago
Brett Lyons d8f482e11e
Add MSBuild language based on XML grammar (#5793) 1 year ago
Skyler Hawthorne 06d095f31c provide option to completely disable lsp 1 year ago
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>
1 year ago
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>
1 year ago
Antonius Naumann 56c0810c68
Change default language server for 'v' from 'vls' to 'v ls' (#5677) 1 year ago
Eloi Torrents 7e191f5915
Support sagemath language (#5649) 1 year ago
Doug Kelkhoff 2b58ff4d7c
Add configuration for min width of line-numbers gutter (#4724) 1 year ago
Soso 8347139ff5
book: Use per-theme syntax-highlighting CSS variables (#5406)
Until this patch, all themes used the Colibri values for syntax highlighting.
This made the documentation very hard to read in some light themes.
1 year ago
yashpalgoyal1304 edd0ba7f19
book: Link MSYS2 proper command page (#5601) 1 year ago
Pascal Kuthe 1b69c7b4af
doc: add build instructions for musl-libc (#5572) 1 year ago
gibbz00 deae13f404
Primary cursor colors by mode (#5130)
* (theme) feat: mode based primary cursor colors

* docs/themes: mode based primary cursor colors
1 year ago
Clément Delafargue 9530fab4b6 doc: expand documentation on configuring minor modes
Fixes #3835, #4811
1 year ago
Clément Delafargue a02dd17e82 doc: make the order of unimpaired mappings consistent
Most mappings are next `]` then previous `[`, except for a few ones.

Fixes #5145
1 year ago
Clément Delafargue 7bdba4a6bf doc: add missing `whitespace.render` sub-key 1 year ago
Clément Delafargue 425d7e5f1b doc: add a note about nested bindings in key remapping
It was not clear (to me) that minor modes were configurable in the
keymap configuration.
1 year ago
Clément Delafargue b6331394a3 book: fix the injection-regex example
The regex uses anchors, while all of the language
configs packaged with helix don't use them.
1 year ago
Clément Delafargue 1f6809c9ce Language support for dhall
https://dhall-lang.org/
1 year ago
Matthias Wahl e65f28d41a
Add language support for ponylang (#5416)
See https://www.ponylang.io
1 year ago
Chickenkeeper 486c3ab0d5
Fix Broken Attribute Highlights (#5349)
* Update highlights.scm

* Update highlights.scm

* Update themes.md
1 year ago
Michael Davis b368df5785
Use tree-sitter-ruby for crystal (#5205) 1 year ago
Michal Melewski a39a2ce9a8
book: Recommend '--locked' for cargo installs (#5438) 1 year ago
Biswapriyo Nath 6ae092acce
book: Clarify install commands for msys2 in Windows (#5363) 1 year ago
Dom H 532531c3ca
Add runtime queries for `tfvars` (based on `hcl`) (#5396) 1 year ago
Howard Halim 0196cccb0c
Fix typos (#5415) 1 year ago
Nick c9ed42cdec
Add a status line element that shows just the basename of the file (#5318) 1 year ago
DylanBulfin 1107296ca9
Add command to merge consecutive ranges in selection (#5047) 1 year ago
Jonathan LEI 24cd7f6adf Make prompt suggestions greyed out 1 year ago
g-s-k 042d03269e
Add support for MATLAB/Octave files (#5192) 1 year ago
Jonas Everaert aecb524e50
Crystal language support (#4993) 1 year ago
Ifiok Jr 9c9c775a27
Fix a typo in the docs (#5191) 1 year ago
Blaž Hrastnik ec9aa66902
Remove redraw to fix build 1 year ago
Roberto Vidal f916915b53
add redraw command (#4354)
* add redraw command

* update docs

* Update helix-term/src/commands/typed.rs

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

* update docs

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
1 year ago
gavincrawford 012fc12f97
Add Bash indents (#5149) 1 year ago
Erasin 436296b76c
Add Mermaid.js for markdown support (#5147) 1 year ago
Alexander Schlögl 0b96021643
Add `:pipe-to` typable command that ignores shell output (#4931) 1 year ago
Marco Ieni d5ab974d38
chore(book): link repository (#5101) 1 year ago
Slug c5bfb792b2
update(theme): adjust base16_transparent and dark_high_contrast (#5105) 1 year ago
Ollie Charles 0e8ea13696
Add Haskell text objects (#5061) 1 year ago
Felipe S. S. Schneider d14de27709
Add support for the BibTeX file format (#5064) 1 year ago
TotalKrill 16e13b9789
allow specifying environment for language servers in language.toml (#4004)
Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>
Co-authored-by: Stephen Wakely <fungus.humungus@gmail.com>
Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
1 year ago
Pascal Kuthe af532147c9
Add command/keybinding to jump between hunks (#4650)
* add command and keybding to jump to next/prev hunk

* add textobject for change

* Update helix-vcs/src/diff.rs

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

* select entire hunk instead of first char

* fix selection range

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
1 year ago
nosa 7210c58a51
Change default TS object bindings (#3782)
* Change default TS object bindings

Changes 'match inside/around' bindings for:
- type definition from `c` to `t`
- comments from `o` to `c`
- tests from `t` to `T`

Also changes those for the `]` / `[` bindings.

* Update docs for changed keybinds

Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
1 year ago
Blaž Hrastnik 03ca18b377
Update language support docs 1 year ago
Michael Davis 8c2692caf1
Use the logo as the favicon for the docs book (#4971) 1 year ago
Pascal Kuthe 5a3ff74221
Show (git) diff signs in gutter (#3890)
* Show (git) diff signs in gutter (#3890)

Avoid string allocation when git diffing

Incrementally diff using changesets

refactor diffs to be provider indepndent and improve git implementation

remove dependency on zlib-ng

switch to asynchronus diffing with similar

Update helix-vcs/Cargo.toml

fix toml formatting

Co-authored-by: Ivan Tham <pickfire@riseup.net>

fix typo in documentation

use ropey reexpors from helix-core

fix crash when creating new file

remove useless use if io::Cursor

fix spelling mistakes

implement suggested improvement to repository loading

improve git test isolation

remove lefover comments

Co-authored-by: univerz <univerz@fu-solution.com>

fixed spelling mistake

minor cosmetic changes

fix: set self.differ to None if decoding the diff_base fails

fixup formatting

Co-authored-by: Ivan Tham <pickfire@riseup.net>

reload diff_base when file is reloaded from disk

switch to imara-diff

Fixup formatting

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>

Redraw buffer whenever a diff is updated.

Only store hunks instead of changes for individual lines to easily allow
jumping between them

Update to latest gitoxide version

Change default diff gutter position

Only update gutter after timeout

* update diff gutter synchronously, with a timeout

* Apply suggestions from code review

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>

* address review comments and ensure lock is always aquired

* remove configuration for redraw timeout

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
1 year ago
Michael Davis 67415e096e
Fix file-types declaration for racket (#4915)
Both the racket and scheme entries used the rkt file-extension. This
commit removes that entry for scheme and so that the racket entry takes
precedence. We explicitly point to the scheme grammar now and setup
queries that inherit from scheme. This should enable using the racket
language server configuration.
1 year ago
Lennard Hofmann fc811726e0
Update tree-sitter-java and add Java textobjects (#4886) 1 year ago
alois31 26ec1cf39a
Add QML language support (#4842)
Fixes https://github.com/helix-editor/helix/issues/2771
1 year ago
Sora 420e33a600
Implement simple indents.scm for Elixir (#4821) 2 years ago
Filipe Azevedo 8dac863a5b
Add `:reload-all` command (#4663) 2 years ago
Blaž Hrastnik 767b179839
Update lang-support doc 2 years ago
Gaurav Tyagi 91ff903bf3
Add global error/warning count statusline element (#4569) 2 years ago
Jonathan 1233c9a989
Add support for Bicep files (#4403) 2 years ago
wes adams fd585c1ee4
Statusline indicator to show number of selected chars (#4682)
Co-authored-by: wes adams <wadams@grayshift.com>
2 years ago
Philip Giuliani e17ad2722a
Enable elixir-ls for heex language (#4679) 2 years ago
Matthias Deiml dee5b2a983
Add LSP workspace command picker (#3140)
* Add workspace command picker

* Make command typable

* Add optional argument to lsp-workspace-command
2 years ago
Zhizhen He 0c30aeea5b
fix typo (#4656) 2 years ago
0xflotus 75d7e0555e
fix: small error (#4651) 2 years ago
Doug Kelkhoff 7ed9e9cf25
Dynamically resize line number gutter width (#3469)
* dynamically resize line number gutter width

* removing digits lower-bound, permitting spacer

* removing max line num char limit; adding notes; qualified successors; notes

* updating tests to use new line number width when testing views

* linenr width based on document line count

* using min width of 2 so line numbers relative is useful

* lint rolling; removing unnecessary type parameter lifetime

* merge change resolution

* reformat code

* rename row_styler to style; add int_log resource

* adding spacer to gutters default; updating book config entry

* adding view.inner_height(), swap for loop for iterator

* reverting change of current! to view! now that doc is not needed
2 years ago
seshotake ed7ea8c9ba
add highlights for env and ini file formats (#4536) 2 years ago
hh9527 9df4358492
Support WIT grammar (#4525) 2 years ago
Konstantin Podsvirov f41f28b662
Update windows install instructions (#4530) 2 years ago
Matthew Toohey f054a3f3ed
feat(lang): add xml (#4518) 2 years ago
Jaden b5e7501935
feat(lang): add kdl grammar (#4481) 2 years ago
rsteube 26f21da531
language: added vhs (#4486) 2 years ago
James O. D. Hunt ac0fe29867
commands: Make no arg ':theme' show name (#3740)
Most commands that accept an argument show their current value if no
argument is specified. The `:theme` command previously displayed an
error message in the status bar if not provided with an argument:

```
Theme name not provided
```

It now shows the current theme name in the status bar if no argument is
specified.

Signed-off-by: James O. D. Hunt <jamesodhunt@gmail.com>

Signed-off-by: James O. D. Hunt <jamesodhunt@gmail.com>
2 years ago
Gaurav Tyagi ba9e50e93b
Add `:update` that will write the changes if the file has been modified. (#4426)
* add command update that will write the changes if file hasn been modified

* add docs

* update the docs
2 years ago
Michael Davis 17daf6ac0a
Change syntax for suffix file-types configurations (#4414)
The change in d801a6693c to search for
suffixes in `file-types` is too permissive: files like the tutor or
`*.txt` files are now mistakenly interpreted as R or perl,
respectively.

This change changes the syntax for specifying a file-types entry that
matches by suffix:

```toml
file-types = [{ suffix = ".git/config" }]
```

And changes the file-type detection to first search for any non-suffix
patterns and then search for suffixes only with the file-types entries
marked explicitly as suffixes.
2 years ago
Sora 664064b3cc
Add textobjects.scm for zig (#4409) 2 years ago
Charlie Groves 7e29ee6dae
Autosave all when the terminal loses focus (#3178)
* Autosave all when the terminal loses focus

* Correct comment on focus config

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>

* Need a block_try_flush_writes in all quit_all paths

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
2 years ago
Greg Troszak fbf8078611
Clarify use of `HELIX_RUNTIME` (#4382) 2 years ago
Garrett D'Amore 36f97b6aad
Add support for D (#4372)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2 years ago
midnightexigent d801a6693c
Allow using path suffixes to associate language file-types (#2455)
* feat(syntax): add strategy to associate file to language through pattern

File path will match if it ends with any of the file types provided in the config.
Also used this feature to add support for the .git/config and .ssh/config files

* Add /etc/ssh/ssh_config to languages.toml

* cargo xtask docgen

* Update languages.md

* Update languages.md

* Update book/src/languages.md

Co-authored-by: Ivan Tham <pickfire@riseup.net>

* Update book/src/languages.md

Co-authored-by: Ivan Tham <pickfire@riseup.net>

Co-authored-by: Ivan Tham <pickfire@riseup.net>
2 years ago
Alex 8c9bb23650
Update windows install instructions (#4351) 2 years ago
Blaž Hrastnik 418a622db9
Merge pull request #4061 from pascalkuthe/undercurl-modifier
Support different kinds of underline rendering (updated)
2 years ago
Peter Phillips faf0c521d1
Fix link to textobjects usage from keymap documentation (#4357) 2 years ago
Gokul Soumya 4e691d6247
Change diagnostic picker keybind to <space>d (#4229)
Also changes workspace diagnostic picker bindings to <space>D and
changes the debug menu keybind to <space>g, the previous diagnostic
picker keybind. This brings the diagnostic picker bindings more in
line with the jump to next/previous diagnostic bindings which are
currently on ]d and [d.
2 years ago
Ben White-Horne 63fe423710
Show keys required to enter each minor mode (#4302)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2 years ago
ZJPzjp 0e8e7cae3b
fix `:insert-output` doc: inserting output **before** each selection (#4286) 2 years ago
Dario Oddenino 2d958d6c50
Add support for Purescript language (#4242) 2 years ago
Pascal Kuthe 66a49080bc
merge underline-style and underline-color into a single table 2 years ago
Tim Siegel 425df93fb8 book: Refer to keys by key names, not representations
This is an attempt to clean up the inconsistent way that keys are
written in various places. These rules require the fewest changes to the
existing text.

Use the "Key name", as defined in remapping.md, which uses
"Some-Modifiers-PascalCaseKey". The "Representation", which uses
"S-M-lowercasekey", is only used for configuration entries.

For key combinations which do not present a popup, just present the keys
one after the other, with no intervening space, like `]p`.

For key combinations which present a popup, separate them with ` + `,
like `Space + f`.

The Ctrl modifier is called Ctrl, not Control.
2 years ago
Lennard Hofmann a24fae3b3c
Update tree-sitter-lua and add textobjects for Lua (#3552) 2 years ago
Pascal Kuthe 328c4d002f
adress review comments 2 years ago
Daniel Ebert 081327695f Rename extend indent captures.
Clarify comments in indent code.
2 years ago
Daniel Ebert dc443487d4 Slightly change the behavior of the `@stop-extend` capture.
This improves the behavior in case of multiple nested extensions.
2 years ago
Triton171 8f19956218 Add python indentation support to docs.
Document @extend-indented and @stop-extend captures for indent queries.
2 years ago
Pascal Kuthe 1a87cbd508 remove filterting with C-space from picker 2 years ago
Sumit Sahrawat a079f2c9bd
Add some vertical characters to the editor.indent-guides documentation (#4163)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2 years ago
David 7af7dadd17
Add instructions for gnome desktop support using the `.desktop` file (#4165) 2 years ago
A-Walrus c15f1ea274
Add cursorcolumn (#4084)
* Implement cursorcolumn

* Add documentation

* Separate column style from line with fallback

* Fallback to cursorcolumn first

* Switch to non-fallback try_get_exact

Add new function `try_get_exact`, which doesn't perform fallback,
and use that instead because the fallback behaviour is being handled
manually.
2 years ago
Pascal Kuthe 2f7088c1f3
fix typo
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>
2 years ago
pascalkuthe ad0eb4094b
add deprectation not for underlined modifier to docs 2 years ago
Brandon Dong 18cfe864f4
Fix incorrect scrolloff default in documentation (#4136) 2 years ago
Pascal Kuthe 7bc324fde9
make casing consistent with other configuration 2 years ago
Jaden ccb38e7696
doc: add theme inheritance example (#4096) 2 years ago
Poliorcetics ed5febf4b3
doc: add example to disable arrow keys in insert mode (#4088) 2 years ago
Karsten Gebbert 9124c231f4
respond to SIGUSR1 by reloading config (#3952)
* respond to SIGUSR1 by reloading config

* document USR1 signal handling
2 years ago
Ivan Tham 3d59d3f8be
Keep arrow and special keys in insert (#3915)
* Keep arrow and special keys in insert

Advanced users won't need it and is useful for beginners.
Revert part of #3671.

* Change text for insert mode section

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>

* Remove ctrl-up/down in insert

* Reorganize insert keys and docs

* Improve page up experience on last tutor

The last tutor page can page down multiple times and it will break the
heading on the 80x24 screen paging when reaching the last page, this
keeps the style the same and make sure page up and down won't break it.

Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
2 years ago
Robin 6764744ce9
Add option to skip the first indent guide (#3819)
* Add option to skip the first indent guide

* reorder skip_first option

* change indent-guides.skip_first to a number

* rename skip -> skip_levels

* add skip_levels to the book

* Update book/src/configuration.md

Co-authored-by: A-Walrus <58790821+A-Walrus@users.noreply.github.com>

* Update helix-term/src/ui/editor.rs

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

Co-authored-by: Robin <robinvandijk@klippa.com>
Co-authored-by: A-Walrus <58790821+A-Walrus@users.noreply.github.com>
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
2 years ago
Michael Davis dbec057363
Rename I/A "Insert at start/end of line" (#3753)
* keymap: Rename A "Insert at end of line"

The language for the `A` binding is potentially confusing because
`A` behaves like `i` done at the end of the line rather than `a`.
This change renames the command to match Kakoune's language[^1].

[^1]: 021da117cf/src/normal.cc (L2229)

* keymap: Rename I `insert_at_line_start`
2 years ago
Ivan Tham 66bbba9024
Select inserted space after join (#3549)
* Select inserted space after join

* Split join_selections with space selection to A-J

Kakoune does that too and some users may still want to retain their selections.

* Update join_selections docs
2 years ago
Joshua Pauline c144cc0b04
feat(statusline): add option to show total line numbers in file (#3960)
* feat(statusline): add option to show total line numbers in file

* feat(line numbers): add config to doc book
2 years ago
PeepNSheep 77f33e7b20
Add configureable statusline mode names (#3311)
* Added 'long-mode' statusline element

* Added customizable statusline mode names

* Removed a string clone

* Added documentation

* Updated documentation, moved modenames to a seperate section

* Update configuration.md

* Documentation update

* Documentation update

* Documentation update

* Update configuration.md

* Update configuration.md

* Fixed merge error

* Update configuration.md

* Update configuration.md
2 years ago
ChrHorn 589d17c758
Add `ui.gutter.selected` option for themes (#3303)
* add `ui.gutter.selected`

* add `ui.gutter`, `ui.gutter.selected` to docs
2 years ago
Pascal Kuthe 71ee589bbc
make underline_style a seperate option
Underline styles are mutally exclusive and overwrite each other.
Therefore implementing as an modifier lead to incorrect behaviour
when the underline style is overwritten.

For backwards compatability the "underline" modified is retained (but
deprecated). Instead the "underline_style" and "underline_color"
optios should be used to style underlines.
2 years ago
A-Walrus de72b9c04c
Update theme documentation 2 years ago
Roberto Vidal cc257e9bf9
Add support for webassembly text format (#4040) 2 years ago
Oskar Köök c196a90684
Add documentation for `max-line-length` (#3974) 2 years ago