Commit Graph

53 Commits

Author SHA1 Message Date
Ameer Ghani
6acc18373d Add option to set maximum info box width
Some plugins (*cough* kak-lsp) and help texts tend to have immensely long content
in a single line. This generates info boxes that span the entire terminal width.
This is made especially worse on widescreen monitors or at small text size.

This grants user control over how wide these boxes are.

I deliberately avoid pushing this change to `kak-lsp` because it's not the only
plugin that this could help--see the `hook` help text for an example of this
problem in vanilla Kakoune. I would also suggest that since this is a rendering
concern, it be handled by the terminal rendering logic.
2023-02-15 21:17:22 -05:00
Eve
7831ab8f9d Fix typo in options.asciidoc 2023-01-23 09:11:30 -05:00
Coleman McFarland
f206640abc Grammar correction options.asciidoc 2022-02-13 21:27:31 -05:00
Johannes Altmanninger
c120063da9 doc options: more detail on how completions options are handled
Cross-reference the "completers" option, and explain how filtering works.

Originally submitted as part of #4418

Helped-by: Tim Allen <screwtape@froup.com>
2022-01-10 08:59:30 +11:00
Johannes Altmanninger
068623e1c8 doc options: state that all |-separated tuples need escaping
For the "completions" option type, the documentation states that |
and \ need to be escaped as \| and \\.
The same parser is for other option types that are lists-of-tuples:
range-specs and line-specs, so they need escaping too. Document that.

Only their last element can contain arbitrary data, so range-specs
and line-specs could work without escaping if we tweaked the parser.
2021-10-29 18:25:53 +02:00
Maxime Coste
3acf85f267 Restore diff based terminal output optimization when synchronized
terminal_synchronized ui_option now also controls this behaviour,
update out of date documentation for ui_options as well.

As discussed in #4317
2021-09-26 11:03:50 +10:00
Maxime Coste
b841f3a214 Remove terminal_wheel_up/down_button UI option
It seems nobody uses it, and it is not plugged through anyway.

Closes #2642
2021-09-02 20:46:35 +10:00
Maxime Coste
e839c64375 Fix documentation for terminal_synchronized UI option
Fixes #4321
2021-09-02 20:44:19 +10:00
Maxime Coste
428ddeb97b Add 'terminal_synchronized' ui_option to opt-in synchronized output
Synchronized output does not work well with various terminals
(including the linux console). It should also be unnecessary when
not going through a slow link.

This will eventually be removed if it is not proven to be useful
to some users.
2021-07-12 10:25:59 +10:00
Maxime Coste
7e66846172 Rename NCursesUI to TerminalUI 2021-07-12 10:25:58 +10:00
Maxime Coste
d78da60b45 Merge remote-tracking branch 'Screwtapello/document-completion-escaping' 2021-06-15 20:40:19 +10:00
Tim Allen
bdb668ba54 Document how to escape special characters in completions. 2021-06-11 00:27:13 +10:00
Tim Allen
b228232de7 Clarify which parts of Kakoune the extra_word_chars option affects.
Also, document the "empty option implies underscore" quirk.
2021-06-09 17:50:30 +10:00
nojhan
daa63ba879 [feat] add ui_options: padding_char & padding_fill
In some cases, it may be difficult to easily spot the area out of the buffer
(bad color scheme, small font, superimposed windows).

This patch adds two ncurses ui_options to bypass this problem:
- `ncurses_padding_char`, to configure the padding character,
- `ncurses_padding_fill`, to indicate whether to fill the padding line
  (or to display a single character).

The default config is the legacy one (a single "~").
2021-04-05 20:21:48 +02:00
SeerLite
aa22ea58cf doc options: Clarify how to empty lists/maps 2020-10-27 16:08:16 -03:00
Maxime Coste
ec3d7c3104 Add support for removing from options
`set -remove ...` will remove from the current option value, substracting
from int, removing elements from vectors and maps.
2020-09-09 21:00:30 +10:00
Johannes Altmanninger
e4f7d42396 doc: fix typos and clarify some parts 2020-05-28 18:37:26 +02:00
Maxime Coste
f7a2ecfacb Support empty ranges in replace-ranges highlighter 2020-04-06 11:23:47 +10:00
Joachim Henke
4dd0b432ab the option 'ncurses_builtin_key_parser' has gone 2020-01-19 15:30:18 +01:00
Delapouite
00e44903e7 doc: fix completers option description 2019-11-04 10:11:09 +01:00
Jason Felice
f88cf7ffb4 rc, doc: set extra_word_chars on buffer, not window
For clojure.kak and haskell.kak, set extra_word_chars on the buffer
and not the window, so that the buffer's word db is updated correctly
for word completion.

Document this.

Also, minor refactor of clojure.kak.

Closes #3108
2019-09-26 09:55:02 -04:00
Joachim Henke
4c61f82fb2 fix a few typos 2019-07-06 17:37:30 +02:00
Maxime Coste
9118a18d5d Change completions option docstring element to be an arbitrary command
We can have the previous behaviour by just passing the docstring to
`info -placement menu`.
2019-04-17 08:38:52 +02:00
Aaron Bull Schaefer
ada4e01f97 Document how to view the current value for options 2019-03-18 08:27:08 -07:00
Oliver Jan Krylow
b36ece46c4
rename auto_complete -> autocomplete in docs 2019-02-24 10:45:38 +00:00
Maxime Coste
4dae2c875b Introduce a writemethod option to either overwrite or replace files
This permit to choose if files should be written by overwriting their
content (the default), or by writing to a separate temporary file
and rename it to the current file.

As discussed in #2036
2019-02-12 21:01:19 +11:00
Maxime Coste
64f1c31401 Refactor parsing of keys and introduce a builtin key parser mode
By setting the ncurses_builtin_key_parser ui_option to true, we
can disable ncurses parsing of key strokes to get less portable
parsing but support for more complex modifiers.
2018-12-09 21:35:22 +11:00
Tim Allen
26e5768207 Be specific about the units of ranges and cursor positions. 2018-10-09 14:31:02 +11:00
Tim Allen
e493eba46d expansions.asciidoc: Rewrite to make Kakoune syntax the primary reference.
Also, moved the "Markup strings" section to faces.asciidoc, since it wasn't
anything to do with expansions, and updated various hyperlinks to point at the
new location.
2018-09-25 18:31:29 +10:00
Maxime Coste
df655422d1 Merge remote-tracking branch 'Screwtapello/support-user-map-options' 2018-08-30 20:10:00 +10:00
Maxime Coste
d99cd3981c Merge remote-tracking branch 'henrebotha/fix-1' 2018-08-27 08:14:28 +10:00
Frank LENORMAND
5a066c139e doc options: Make default list values space separated 2018-08-25 15:03:42 +03:00
Henré Botha
aa6d9b8cd5 Fix run-on sentence in options doc 2018-08-22 14:58:11 +02:00
Tim Allen
ede9155fc7 Document which option-types can be used with declare-options. 2018-08-21 18:24:33 +10:00
Tim Allen
49ef9968c0 Support user-defined "str-to-str-map" options. 2018-08-21 18:24:14 +10:00
Delapouite
231e140d37 docs: add -always and -once switch on hooks page 2018-08-16 19:06:57 +02:00
Maxime Coste
bde726d034 Change autoshowcompl to auto_complete with insert|prompt possible values 2018-07-15 11:10:32 +10:00
Maxime Coste
eab98c88bd Refactor handling of startup info to make it configurable
A new `status_info_version` option allows user to disable info
message regarding changes that happened at that version or
earlier.
2018-07-05 07:54:28 +10:00
Maxime Coste
4e2e971033 Update commands.asciidoc, options.asciidoc and expansions.asciidoc pages 2018-07-05 07:54:28 +10:00
Maxime Coste
99fea9c0f9 Fix typo
Thanks @lenormf
2018-04-12 21:28:15 +10:00
Maxime Coste
5fa19f4d7f NCursesUI: Add support for shifted function keys
Shifted function keys are not well standardized around terminals,
Shift F(N) usually returns F(X) + N, with X=12 on xterm, X=10 on
rxvt-unicode... Default to X=12 and make it configuable through
the ncurses_shift_function_key ui_option.

This fixes what #1898 tried to.
2018-04-11 20:39:57 +10:00
Delapouite
2d775921bc Docs: describe the -add switch of set-option 2018-04-05 11:35:03 +02:00
Delapouite
ecd6cebdab Docs: add %/ token to default path option 2018-03-23 10:24:18 +01:00
Delapouite
abc2d28570 Docs: extend explanations about line_flags, ranges and replace-ranges 2018-03-06 12:15:55 +01:00
Maxime Coste
1f02a1f7e2 Doc pages: Use passive form, never address the reader as 'you'
Except for the FAQ, it could be fixed, but it does not have to be
as formal as the rest of the docs.
2017-11-12 22:44:04 +08:00
Maxime Coste
b63f16e7a2 doc.kak: Support anchors and internal links
Underline links, support jumping to a specific anchor either in
the current page or another one, use those new features in some
pages.
2017-11-08 16:32:49 +08:00
Delapouite
3b250fe824 Docs: use asciidoc links between pages 2017-11-06 10:08:59 +01:00
Maxime Coste
7f51e51fcb Introduce matching_pairs option that controls the pairs used by m 2017-11-04 15:53:53 +08:00
Maxime Coste
20fe8e0112 options.asciidoc: use _italic_ for default values 2017-11-02 17:42:44 +08:00
Maxime Coste
3c2159f06c options.asciidoc: Document other option commands, remove tabs 2017-11-02 17:36:10 +08:00