1KITTY.CONF(5) kitty KITTY.CONF(5)
2
3
4
6 kitty.conf - kitty.conf Documentation
7
8 kitty is highly customizable, everything from keyboard shortcuts, to
9 painting frames-per-second. See below for an overview of all customiza‐
10 tion possibilities.
11
12 You can open the config file within kitty by pressing ctrl+shift+f2.
13 You can also display the current configuration by running kitty --de‐
14 bug-config.
15
16 kitty looks for a config file in the OS config directories (usually
17 ~/.config/kitty/kitty.conf) but you can pass a specific path via the
18 kitty --config option or use the KITTY_CONFIG_DIRECTORY environment
19 variable. See the kitty --config option for full details.
20
21 Comments can be added to the config file as lines starting with the #
22 character. This works only if the # character is the first character in
23 the line.
24
25 You can include secondary config files via the include directive. If
26 you use a relative path for include, it is resolved with respect to the
27 location of the current config file. Note that environment variables
28 are expanded, so ${USER}.conf becomes name.conf if USER=name. For ex‐
29 ample:
30
31 include other.conf
32
34 kitty has very powerful font management. You can configure individual
35 font faces and even specify special fonts for particular characters.
36
37 font_family, bold_font, italic_font, bold_italic_font
38
39 font_family monospace
40 bold_font auto
41 italic_font auto
42 bold_italic_font auto
43
44 You can specify different fonts for the bold/italic/bold-italic vari‐
45 ants. To get a full list of supported fonts use the kitty list-fonts
46 command. By default they are derived automatically, by the OSes font
47 system. Setting them manually is useful for font families that have
48 many weight variants like Book, Medium, Thick, etc. For example:
49
50 font_family Operator Mono Book
51 bold_font Operator Mono Medium
52 italic_font Operator Mono Book Italic
53 bold_italic_font Operator Mono Medium Italic
54
55 font_size
56
57 font_size 11.0
58
59 Font size (in pts)
60
61 force_ltr
62
63 force_ltr no
64
65 kitty does not support BIDI (bidirectional text), however, for RTL
66 scripts, words are automatically displayed in RTL. That is to say, in
67 an RTL script, the words "HELLO WORLD" display in kitty as "WORLD
68 HELLO", and if you try to select a substring of an RTL-shaped string,
69 you will get the character that would be there had the the string been
70 LTR. For example, assuming the Hebrew word ירושלים, selecting the char‐
71 acter that on the screen appears to be ם actually writes into the se‐
72 lection buffer the character י.
73
74 kitty's default behavior is useful in conjunction with a filter to re‐
75 verse the word order, however, if you wish to manipulate RTL glyphs, it
76 can be very challenging to work with, so this option is provided to
77 turn it off. Furthermore, this option can be used with the command
78 line program GNU FriBidi to get BIDI support, because it will force
79 kitty to always treat the text as LTR, which FriBidi expects for termi‐
80 nals.
81
82 adjust_line_height, adjust_column_width
83
84 adjust_line_height 0
85 adjust_column_width 0
86
87 Change the size of each character cell kitty renders. You can use ei‐
88 ther numbers, which are interpreted as pixels or percentages (number
89 followed by %), which are interpreted as percentages of the unmodified
90 values. You can use negative pixels or percentages less than 100% to
91 reduce sizes (but this might cause rendering artifacts).
92
93 symbol_map
94
95 symbol_map U+E0A0-U+E0A3,U+E0C0-U+E0C7 PowerlineSymbols
96
97 Map the specified unicode codepoints to a particular font. Useful if
98 you need special rendering for some symbols, such as for Powerline.
99 Avoids the need for patched fonts. Each unicode code point is specified
100 in the form U+<code point in hexadecimal>. You can specify multiple
101 code points, separated by commas and ranges separated by hyphens. sym‐
102 bol_map itself can be specified multiple times. Syntax is:
103
104 symbol_map codepoints Font Family Name
105
106 disable_ligatures
107
108 disable_ligatures never
109
110 Choose how you want to handle multi-character ligatures. The default is
111 to always render them. You can tell kitty to not render them when the
112 cursor is over them by using cursor to make editing easier, or have
113 kitty never render them at all by using always, if you don't like them.
114 The ligature strategy can be set per-window either using the kitty re‐
115 mote control facility or by defining shortcuts for it in kitty.conf,
116 for example:
117
118 map alt+1 disable_ligatures_in active always
119 map alt+2 disable_ligatures_in all never
120 map alt+3 disable_ligatures_in tab cursor
121
122 Note that this refers to programming ligatures, typically implemented
123 using the calt OpenType feature. For disabling general ligatures, use
124 the font_features setting.
125
126 font_features
127
128 font_features none
129
130 Choose exactly which OpenType features to enable or disable. This is
131 useful as some fonts might have features worthwhile in a terminal. For
132 example, Fira Code Retina includes a discretionary feature, zero, which
133 in that font changes the appearance of the zero (0), to make it more
134 easily distinguishable from Ø. Fira Code Retina also includes other
135 discretionary features known as Stylistic Sets which have the tags ss01
136 through ss20.
137
138 Note that this code is indexed by PostScript name, and not the font
139 family. This allows you to define very precise feature settings; e.g.
140 you can disable a feature in the italic font but not in the regular
141 font.
142
143 On Linux, these are read from the FontConfig database first and then
144 this, setting is applied, so they can be configured in a single, cen‐
145 tral place.
146
147 To get the PostScript name for a font, use kitty + list-fonts
148 --psnames:
149
150 $ kitty + list-fonts --psnames | grep Fira
151 Fira Code
152 Fira Code Bold (FiraCode-Bold)
153 Fira Code Light (FiraCode-Light)
154 Fira Code Medium (FiraCode-Medium)
155 Fira Code Regular (FiraCode-Regular)
156 Fira Code Retina (FiraCode-Retina)
157
158 The part in brackets is the PostScript name.
159
160 Enable alternate zero and oldstyle numerals:
161
162 font_features FiraCode-Retina +zero +onum
163
164 Enable only alternate zero:
165
166 font_features FiraCode-Retina +zero
167
168 Disable the normal ligatures, but keep the calt feature which (in this
169 font) breaks up monotony:
170
171 font_features TT2020StyleB-Regular -liga +calt
172
173 In conjunction with force_ltr, you may want to disable Arabic shaping
174 entirely, and only look at their isolated forms if they show up in a
175 document. You can do this with e.g.:
176
177 font_features UnifontMedium +isol -medi -fina -init
178
179 box_drawing_scale
180
181 box_drawing_scale 0.001, 1, 1.5, 2
182
183 Change the sizes of the lines used for the box drawing unicode charac‐
184 ters These values are in pts. They will be scaled by the monitor DPI to
185 arrive at a pixel value. There must be four values corresponding to
186 thin, normal, thick, and very thick lines.
187
189 cursor
190
191 cursor #cccccc
192
193 Default cursor color
194
195 cursor_text_color
196
197 cursor_text_color #111111
198
199 Choose the color of text under the cursor. If you want it rendered with
200 the background color of the cell underneath instead, use the special
201 keyword: background
202
203 cursor_shape
204
205 cursor_shape block
206
207 The cursor shape can be one of (block, beam, underline)
208
209 cursor_beam_thickness
210
211 cursor_beam_thickness 1.5
212
213 Defines the thickness of the beam cursor (in pts)
214
215 cursor_underline_thickness
216
217 cursor_underline_thickness 2.0
218
219 Defines the thickness of the underline cursor (in pts)
220
221 cursor_blink_interval
222
223 cursor_blink_interval -1
224
225 The interval (in seconds) at which to blink the cursor. Set to zero to
226 disable blinking. Negative values mean use system default. Note that
227 numbers smaller than repaint_delay will be limited to repaint_delay.
228
229 cursor_stop_blinking_after
230
231 cursor_stop_blinking_after 15.0
232
233 Stop blinking cursor after the specified number of seconds of keyboard
234 inactivity. Set to zero to never stop blinking.
235
237 scrollback_lines
238
239 scrollback_lines 2000
240
241 Number of lines of history to keep in memory for scrolling back. Memory
242 is allocated on demand. Negative numbers are (effectively) infinite
243 scrollback. Note that using very large scrollback is not recommended as
244 it can slow down performance of the terminal and also use large amounts
245 of RAM. Instead, consider using scrollback_pager_history_size.
246
247 scrollback_pager
248
249 scrollback_pager less --chop-long-lines --RAW-CONTROL-CHARS +INPUT_LINE_NUMBER
250
251 Program with which to view scrollback in a new window. The scrollback
252 buffer is passed as STDIN to this program. If you change it, make sure
253 the program you use can handle ANSI escape sequences for colors and
254 text formatting. INPUT_LINE_NUMBER in the command line above will be
255 replaced by an integer representing which line should be at the top of
256 the screen. Similarly CURSOR_LINE and CURSOR_COLUMN will be replaced by
257 the current cursor position.
258
259 scrollback_pager_history_size
260
261 scrollback_pager_history_size 0
262
263 Separate scrollback history size, used only for browsing the scrollback
264 buffer (in MB). This separate buffer is not available for interactive
265 scrolling but will be piped to the pager program when viewing scroll‐
266 back buffer in a separate window. The current implementation stores
267 the data in UTF-8, so approximatively 10000 lines per megabyte at 100
268 chars per line, for pure ASCII text, unformatted text. A value of zero
269 or less disables this feature. The maximum allowed size is 4GB.
270
271 scrollback_fill_enlarged_window
272
273 scrollback_fill_enlarged_window no
274
275 Fill new space with lines from the scrollback buffer after enlarging a
276 window.
277
278 wheel_scroll_multiplier
279
280 wheel_scroll_multiplier 5.0
281
282 Modify the amount scrolled by the mouse wheel. Note this is only used
283 for low precision scrolling devices, not for high precision scrolling
284 on platforms such as macOS and Wayland. Use negative numbers to change
285 scroll direction.
286
287 touch_scroll_multiplier
288
289 touch_scroll_multiplier 1.0
290
291 Modify the amount scrolled by a touchpad. Note this is only used for
292 high precision scrolling devices on platforms such as macOS and Way‐
293 land. Use negative numbers to change scroll direction.
294
296 mouse_hide_wait
297
298 mouse_hide_wait 3.0
299
300 Hide mouse cursor after the specified number of seconds of the mouse
301 not being used. Set to zero to disable mouse cursor hiding. Set to a
302 negative value to hide the mouse cursor immediately when typing text.
303 Disabled by default on macOS as getting it to work robustly with the
304 ever-changing sea of bugs that is Cocoa is too much effort.
305
306 url_color, url_style
307
308 url_color #0087bd
309 url_style curly
310
311 The color and style for highlighting URLs on mouse-over. url_style can
312 be one of: none, single, double, curly
313
314 open_url_modifiers
315
316 open_url_modifiers kitty_mod
317
318 The modifier keys to press when clicking with the mouse on URLs to open
319 the URL
320
321 open_url_with
322
323 open_url_with default
324
325 The program with which to open URLs that are clicked on. The special
326 value default means to use the operating system's default URL handler.
327
328 url_prefixes
329
330 url_prefixes http https file ftp gemini irc gopher mailto news git
331
332 The set of URL prefixes to look for when detecting a URL under the
333 mouse cursor.
334
335 detect_urls
336
337 detect_urls yes
338
339 Detect URLs under the mouse. Detected URLs are highlighted with an un‐
340 derline and the mouse cursor becomes a hand over them. Even if this
341 option is disabled, URLs are still clickable.
342
343 copy_on_select
344
345 copy_on_select no
346
347 Copy to clipboard or a private buffer on select. With this set to clip‐
348 board, simply selecting text with the mouse will cause the text to be
349 copied to clipboard. Useful on platforms such as macOS that do not have
350 the concept of primary selections. You can instead specify a name such
351 as a1 to copy to a private kitty buffer instead. Map a shortcut with
352 the paste_from_buffer action to paste from this private buffer. For
353 example:
354
355 map cmd+shift+v paste_from_buffer a1
356
357 Note that copying to the clipboard is a security risk, as all programs,
358 including websites open in your browser can read the contents of the
359 system clipboard.
360
361 strip_trailing_spaces
362
363 strip_trailing_spaces never
364
365 Remove spaces at the end of lines when copying to clipboard. A value
366 of smart will do it when using normal selections, but not rectangle se‐
367 lections. always will always do it.
368
369 rectangle_select_modifiers
370
371 rectangle_select_modifiers ctrl+alt
372
373 The modifiers to use rectangular selection (i.e. to select text in a
374 rectangular block with the mouse)
375
376 terminal_select_modifiers
377
378 terminal_select_modifiers shift
379
380 The modifiers to override mouse selection even when a terminal applica‐
381 tion has grabbed the mouse
382
383 select_by_word_characters
384
385 select_by_word_characters @-./_~?&=%+#
386
387 Characters considered part of a word when double clicking. In addition
388 to these characters any character that is marked as an alphanumeric
389 character in the unicode database will be matched.
390
391 click_interval
392
393 click_interval -1.0
394
395 The interval between successive clicks to detect double/triple clicks
396 (in seconds). Negative numbers will use the system default instead, if
397 available, or fallback to 0.5.
398
399 focus_follows_mouse
400
401 focus_follows_mouse no
402
403 Set the active window to the window under the mouse when moving the
404 mouse around
405
406 pointer_shape_when_grabbed
407
408 pointer_shape_when_grabbed arrow
409
410 The shape of the mouse pointer when the program running in the terminal
411 grabs the mouse. Valid values are: arrow, beam and hand
412
413 default_pointer_shape
414
415 default_pointer_shape beam
416
417 The default shape of the mouse pointer. Valid values are: arrow, beam
418 and hand
419
420 pointer_shape_when_dragging
421
422 pointer_shape_when_dragging beam
423
424 The default shape of the mouse pointer when dragging across text.
425 Valid values are: arrow, beam and hand
426
428 repaint_delay
429
430 repaint_delay 10
431
432 Delay (in milliseconds) between screen updates. Decreasing it, in‐
433 creases frames-per-second (FPS) at the cost of more CPU usage. The de‐
434 fault value yields ~100 FPS which is more than sufficient for most
435 uses. Note that to actually achieve 100 FPS you have to either set
436 sync_to_monitor to no or use a monitor with a high refresh rate. Also,
437 to minimize latency when there is pending input to be processed, re‐
438 paint_delay is ignored.
439
440 input_delay
441
442 input_delay 3
443
444 Delay (in milliseconds) before input from the program running in the
445 terminal is processed. Note that decreasing it will increase respon‐
446 siveness, but also increase CPU usage and might cause flicker in full
447 screen programs that redraw the entire screen on each loop, because
448 kitty is so fast that partial screen updates will be drawn.
449
450 sync_to_monitor
451
452 sync_to_monitor yes
453
454 Sync screen updates to the refresh rate of the monitor. This prevents
455 tearing (https://en.wikipedia.org/wiki/Screen_tearing) when scrolling.
456 However, it limits the rendering speed to the refresh rate of your mon‐
457 itor. With a very high speed mouse/high keyboard repeat rate, you may
458 notice some slight input latency. If so, set this to no.
459
461 enable_audio_bell
462
463 enable_audio_bell yes
464
465 Enable/disable the audio bell. Useful in environments that require si‐
466 lence.
467
468 visual_bell_duration
469
470 visual_bell_duration 0.0
471
472 Visual bell duration. Flash the screen when a bell occurs for the spec‐
473 ified number of seconds. Set to zero to disable.
474
475 window_alert_on_bell
476
477 window_alert_on_bell yes
478
479 Request window attention on bell. Makes the dock icon bounce on macOS
480 or the taskbar flash on linux.
481
482 bell_on_tab
483
484 bell_on_tab yes
485
486 Show a bell symbol on the tab if a bell occurs in one of the windows in
487 the tab and the window is not the currently focused window
488
489 command_on_bell
490
491 command_on_bell none
492
493 Program to run when a bell occurs.
494
496 remember_window_size, initial_window_width, initial_window_height
497
498 remember_window_size yes
499 initial_window_width 640
500 initial_window_height 400
501
502 If enabled, the window size will be remembered so that new instances of
503 kitty will have the same size as the previous instance. If disabled,
504 the window will initially have size configured by initial_win‐
505 dow_width/height, in pixels. You can use a suffix of "c" on the
506 width/height values to have them interpreted as number of cells instead
507 of pixels.
508
509 enabled_layouts
510
511 enabled_layouts *
512
513 The enabled window layouts. A comma separated list of layout names. The
514 special value all means all layouts. The first listed layout will be
515 used as the startup layout. Default configuration is all layouts in al‐
516 phabetical order. For a list of available layouts, see the layouts.
517
518 window_resize_step_cells, window_resize_step_lines
519
520 window_resize_step_cells 2
521 window_resize_step_lines 2
522
523 The step size (in units of cell width/cell height) to use when resizing
524 windows. The cells value is used for horizontal resizing and the lines
525 value for vertical resizing.
526
527 window_border_width
528
529 window_border_width 0.5pt
530
531 The width of window borders. Can be either in pixels (px) or pts (pt).
532 Values in pts will be rounded to the nearest number of pixels based on
533 screen resolution. If not specified the unit is assumed to be pts.
534 Note that borders are displayed only when more than one window is visi‐
535 ble. They are meant to separate multiple windows.
536
537 draw_minimal_borders
538
539 draw_minimal_borders yes
540
541 Draw only the minimum borders needed. This means that only the minimum
542 needed borders for inactive windows are drawn. That is only the borders
543 that separate the inactive window from a neighbor. Note that setting a
544 non-zero window margin overrides this and causes all borders to be
545 drawn.
546
547 window_margin_width
548
549 window_margin_width 0
550
551 The window margin (in pts) (blank area outside the border). A single
552 value sets all four sides. Two values set the vertical and horizontal
553 sides. Three values set top, horizontal and bottom. Four values set
554 top, right, bottom and left.
555
556 single_window_margin_width
557
558 single_window_margin_width -1
559
560 The window margin (in pts) to use when only a single window is visible.
561 Negative values will cause the value of window_margin_width to be used
562 instead. A single value sets all four sides. Two values set the verti‐
563 cal and horizontal sides. Three values set top, horizontal and bottom.
564 Four values set top, right, bottom and left.
565
566 window_padding_width
567
568 window_padding_width 0
569
570 The window padding (in pts) (blank area between the text and the window
571 border). A single value sets all four sides. Two values set the verti‐
572 cal and horizontal sides. Three values set top, horizontal and bottom.
573 Four values set top, right, bottom and left.
574
575 placement_strategy
576
577 placement_strategy center
578
579 When the window size is not an exact multiple of the cell size, the
580 cell area of the terminal window will have some extra padding on the
581 sides. You can control how that padding is distributed with this op‐
582 tion. Using a value of center means the cell area will be placed cen‐
583 trally. A value of top-left means the padding will be on only the bot‐
584 tom and right edges.
585
586 active_border_color
587
588 active_border_color #00ff00
589
590 The color for the border of the active window. Set this to none to not
591 draw borders around the active window.
592
593 inactive_border_color
594
595 inactive_border_color #cccccc
596
597 The color for the border of inactive windows
598
599 bell_border_color
600
601 bell_border_color #ff5a00
602
603 The color for the border of inactive windows in which a bell has oc‐
604 curred
605
606 inactive_text_alpha
607
608 inactive_text_alpha 1.0
609
610 Fade the text in inactive windows by the specified amount (a number be‐
611 tween zero and one, with zero being fully faded).
612
613 hide_window_decorations
614
615 hide_window_decorations no
616
617 Hide the window decorations (title-bar and window borders) with yes.
618 On macOS, titlebar-only can be used to only hide the titlebar. Whether
619 this works and exactly what effect it has depends on the window man‐
620 ager/operating system.
621
622 resize_debounce_time
623
624 resize_debounce_time 0.1
625
626 The time (in seconds) to wait before redrawing the screen when a resize
627 event is received. On platforms such as macOS, where the operating sys‐
628 tem sends events corresponding to the start and end of a resize, this
629 number is ignored.
630
631 resize_draw_strategy
632
633 resize_draw_strategy static
634
635 Choose how kitty draws a window while a resize is in progress. A value
636 of static means draw the current window contents, mostly unchanged. A
637 value of scale means draw the current window contents scaled. A value
638 of blank means draw a blank window. A value of size means show the
639 window size in cells.
640
641 resize_in_steps
642
643 resize_in_steps no
644
645 Resize the OS window in steps as large as the cells, instead of with
646 the usual pixel accuracy. Combined with an initial_window_width and
647 initial_window_height in number of cells, this option can be used to
648 keep the margins as small as possible when resizing the OS window.
649 Note that this does not currently work on Wayland.
650
651 confirm_os_window_close
652
653 confirm_os_window_close 0
654
655 Ask for confirmation when closing an OS window or a tab that has at
656 least this number of kitty windows in it. A value of zero disables con‐
657 firmation. This confirmation also applies to requests to quit the en‐
658 tire application (all OS windows, via the quit action).
659
661 tab_bar_edge
662
663 tab_bar_edge bottom
664
665 Which edge to show the tab bar on, top or bottom
666
667 tab_bar_margin_width
668
669 tab_bar_margin_width 0.0
670
671 The margin to the left and right of the tab bar (in pts)
672
673 tab_bar_style
674
675 tab_bar_style fade
676
677 The tab bar style, can be one of: fade, separator, powerline, or hid‐
678 den. In the fade style, each tab's edges fade into the background
679 color, in the separator style, tabs are separated by a configurable
680 separator, and the powerline shows the tabs as a continuous line. If
681 you use the hidden style, you might want to create a mapping for the
682 select_tab action which presents you with a list of tabs and allows for
683 easy switching to a tab.
684
685 tab_bar_min_tabs
686
687 tab_bar_min_tabs 2
688
689 The minimum number of tabs that must exist before the tab bar is shown
690
691 tab_switch_strategy
692
693 tab_switch_strategy previous
694
695 The algorithm to use when switching to a tab when the current tab is
696 closed. The default of previous will switch to the last used tab. A
697 value of left will switch to the tab to the left of the closed tab. A
698 value of right will switch to the tab to the right of the closed tab.
699 A value of last will switch to the right-most tab.
700
701 tab_fade
702
703 tab_fade 0.25 0.5 0.75 1
704
705 Control how each tab fades into the background when using fade for the
706 tab_bar_style. Each number is an alpha (between zero and one) that con‐
707 trols how much the corresponding cell fades into the background, with
708 zero being no fade and one being full fade. You can change the number
709 of cells used by adding/removing entries to this list.
710
711 tab_separator
712
713 tab_separator " ┇"
714
715 The separator between tabs in the tab bar when using separator as the
716 tab_bar_style.
717
718 tab_powerline_style
719
720 tab_powerline_style angled
721
722 The powerline separator style between tabs in the tab bar when using
723 powerline as the tab_bar_style, can be one of: angled, slanted, or
724 round.
725
726 tab_activity_symbol
727
728 tab_activity_symbol none
729
730 Some text or a unicode symbol to show on the tab if a window in the tab
731 that does not have focus has some activity.
732
733 tab_title_template
734
735 tab_title_template "{title}"
736
737 A template to render the tab title. The default just renders the title.
738 If you wish to include the tab-index as well, use something like: {in‐
739 dex}: {title}. Useful if you have shortcuts mapped for goto_tab N. In
740 addition you can use {layout_name} for the current layout name and
741 {num_windows} for the number of windows in the tab. Note that format‐
742 ting is done by Python's string formatting machinery, so you can use,
743 for instance, {layout_name[:2].upper()} to show only the first two let‐
744 ters of the layout name, upper-cased. If you want to style the text,
745 you can use styling directives, for example: {fmt.fg.red}red{fmt.fg.de‐
746 fault}normal{fmt.bg._00FF00}green bg{fmt.bg.normal}. Similarly, for
747 bold and italic: {fmt.bold}bold{fmt.nobold}nor‐
748 mal{fmt.italic}italic{fmt.noitalic}.
749
750 active_tab_title_template
751
752 active_tab_title_template none
753
754 Template to use for active tabs, if not specified falls back to
755 tab_title_template.
756
757 active_tab_foreground, active_tab_background, active_tab_font_style,
758 inactive_tab_foreground, inactive_tab_background, inac‐
759 tive_tab_font_style
760
761 active_tab_foreground #000
762 active_tab_background #eee
763 active_tab_font_style bold-italic
764 inactive_tab_foreground #444
765 inactive_tab_background #999
766 inactive_tab_font_style normal
767
768 Tab bar colors and styles
769
770 tab_bar_background
771
772 tab_bar_background none
773
774 Background color for the tab bar. Defaults to using the terminal back‐
775 ground color.
776
778 foreground, background
779
780 foreground #dddddd
781 background #000000
782
783 The foreground and background colors
784
785 background_opacity
786
787 background_opacity 1.0
788
789 The opacity of the background. A number between 0 and 1, where 1 is
790 opaque and 0 is fully transparent. This will only work if supported by
791 the OS (for instance, when using a compositor under X11). Note that it
792 only sets the background color's opacity in cells that have the same
793 background color as the default terminal background. This is so that
794 things like the status bar in vim, powerline prompts, etc. still look
795 good. But it means that if you use a color theme with a background
796 color in your editor, it will not be rendered as transparent. Instead
797 you should change the default background color in your kitty config and
798 not use a background color in the editor color scheme. Or use the es‐
799 cape codes to set the terminals default colors in a shell script to
800 launch your editor. Be aware that using a value less than 1.0 is a
801 (possibly significant) performance hit. If you want to dynamically
802 change transparency of windows set dynamic_background_opacity to yes
803 (this is off by default as it has a performance cost)
804
805 background_image
806
807 background_image none
808
809 Path to a background image. Must be in PNG format.
810
811 background_image_layout
812
813 background_image_layout tiled
814
815 Whether to tile or scale the background image.
816
817 background_image_linear
818
819 background_image_linear no
820
821 When background image is scaled, whether linear interpolation should be
822 used.
823
824 dynamic_background_opacity
825
826 dynamic_background_opacity no
827
828 Allow changing of the background_opacity dynamically, using either key‐
829 board shortcuts (ctrl+shift+a>m and ctrl+shift+a>l) or the remote con‐
830 trol facility.
831
832 background_tint
833
834 background_tint 0.0
835
836 How much to tint the background image by the background color. The tint
837 is applied only under the text area, not margin/borders. Makes it eas‐
838 ier to read the text. Tinting is done using the current background
839 color for each window. This setting applies only if background_opacity
840 is set and transparent windows are supported or background_image is
841 set.
842
843 dim_opacity
844
845 dim_opacity 0.75
846
847 How much to dim text that has the DIM/FAINT attribute set. One means no
848 dimming and zero means fully dimmed (i.e. invisible).
849
850 selection_foreground
851
852 selection_foreground #000000
853
854 The foreground for text selected with the mouse. A value of none means
855 to leave the color unchanged.
856
857 selection_background
858
859 selection_background #fffacd
860
861 The background for text selected with the mouse.
862
863 The color table
864 The 256 terminal colors. There are 8 basic colors, each color has a
865 dull and bright version, for the first 16 colors. You can set the re‐
866 maining 240 colors as color16 to color255.
867
868 color0, color8
869
870 color0 #000000
871 color8 #767676
872
873 black
874
875 color1, color9
876
877 color1 #cc0403
878 color9 #f2201f
879
880 red
881
882 color2, color10
883
884 color2 #19cb00
885 color10 #23fd00
886
887 green
888
889 color3, color11
890
891 color3 #cecb00
892 color11 #fffd00
893
894 yellow
895
896 color4, color12
897
898 color4 #0d73cc
899 color12 #1a8fff
900
901 blue
902
903 color5, color13
904
905 color5 #cb1ed1
906 color13 #fd28ff
907
908 magenta
909
910 color6, color14
911
912 color6 #0dcdcd
913 color14 #14ffff
914
915 cyan
916
917 color7, color15
918
919 color7 #dddddd
920 color15 #ffffff
921
922 white
923
924 mark1_foreground
925
926 mark1_foreground black
927
928 Color for marks of type 1
929
930 mark1_background
931
932 mark1_background #98d3cb
933
934 Color for marks of type 1 (light steel blue)
935
936 mark2_foreground
937
938 mark2_foreground black
939
940 Color for marks of type 2
941
942 mark2_background
943
944 mark2_background #f2dcd3
945
946 Color for marks of type 1 (beige)
947
948 mark3_foreground
949
950 mark3_foreground black
951
952 Color for marks of type 3
953
954 mark3_background
955
956 mark3_background #f274bc
957
958 Color for marks of type 1 (violet)
959
961 shell
962
963 shell .
964
965 The shell program to execute. The default value of . means to use what‐
966 ever shell is set as the default shell for the current user. Note that
967 on macOS if you change this, you might need to add --login to ensure
968 that the shell starts in interactive mode and reads its startup rc
969 files.
970
971 editor
972
973 editor .
974
975 The console editor to use when editing the kitty config file or similar
976 tasks. A value of . means to use the environment variables VISUAL and
977 EDITOR in that order. Note that this environment variable has to be set
978 not just in your shell startup scripts but system-wide, otherwise kitty
979 will not see it.
980
981 close_on_child_death
982
983 close_on_child_death no
984
985 Close the window when the child process (shell) exits. If no (the de‐
986 fault), the terminal will remain open when the child exits as long as
987 there are still processes outputting to the terminal (for example dis‐
988 owned or backgrounded processes). If yes, the window will close as soon
989 as the child process exits. Note that setting it to yes means that any
990 background processes still using the terminal can fail silently because
991 their stdout/stderr/stdin no longer work.
992
993 allow_remote_control
994
995 allow_remote_control no
996
997 Allow other programs to control kitty. If you turn this on other pro‐
998 grams can control all aspects of kitty, including sending text to kitty
999 windows, opening new windows, closing windows, reading the content of
1000 windows, etc. Note that this even works over ssh connections. You can
1001 chose to either allow any program running within kitty to control it,
1002 with yes or only programs that connect to the socket specified with the
1003 kitty --listen-on command line option, if you use the value
1004 socket-only. The latter is useful if you want to prevent programs run‐
1005 ning on a remote computer over ssh from controlling kitty.
1006
1007 listen_on
1008
1009 listen_on none
1010
1011 Tell kitty to listen to the specified unix/tcp socket for remote con‐
1012 trol connections. Note that this will apply to all kitty instances. It
1013 can be overridden by the kitty --listen-on command line flag. This op‐
1014 tion accepts only UNIX sockets, such as unix:${TEMP}/mykitty or (on
1015 Linux) unix:@mykitty. Environment variables are expanded. If
1016 {kitty_pid} is present then it is replaced by the PID of the kitty
1017 process, otherwise the PID of the kitty process is appended to the
1018 value, with a hyphen. This option is ignored unless you also set
1019 allow_remote_control to enable remote control. See the help for kitty
1020 --listen-on for more details.
1021
1022 env
1023
1024 env
1025
1026 Specify environment variables to set in all child processes. Note that
1027 environment variables are expanded recursively, so if you use:
1028
1029 env MYVAR1=a
1030 env MYVAR2=${MYVAR1}/${HOME}/b
1031
1032 The value of MYVAR2 will be a/<path to home directory>/b.
1033
1034 update_check_interval
1035
1036 update_check_interval 24
1037
1038 Periodically check if an update to kitty is available. If an update is
1039 found a system notification is displayed informing you of the available
1040 update. The default is to check every 24 hrs, set to zero to disable.
1041
1042 startup_session
1043
1044 startup_session none
1045
1046 Path to a session file to use for all kitty instances. Can be overrid‐
1047 den by using the kitty --session command line option for individual in‐
1048 stances. See sessions in the kitty documentation for details. Note that
1049 relative paths are interpreted with respect to the kitty config direc‐
1050 tory. Environment variables in the path are expanded.
1051
1052 clipboard_control
1053
1054 clipboard_control write-clipboard write-primary
1055
1056 Allow programs running in kitty to read and write from the clipboard.
1057 You can control exactly which actions are allowed. The set of possible
1058 actions is: write-clipboard read-clipboard write-primary read-primary.
1059 You can additionally specify no-append to disable kitty's protocol ex‐
1060 tension for clipboard concatenation. The default is to allow writing to
1061 the clipboard and primary selection with concatenation enabled. Note
1062 that enabling the read functionality is a security risk as it means
1063 that any program, even one running on a remote server via SSH can read
1064 your clipboard.
1065
1066 allow_hyperlinks
1067
1068 allow_hyperlinks yes
1069
1070 Process hyperlink (OSC 8) escape sequences. If disabled OSC 8 escape
1071 sequences are ignored. Otherwise they become clickable links, that you
1072 can click by holding down ctrl+shift and clicking with the mouse. The
1073 special value of ask means that kitty will ask before opening the link.
1074
1075 term
1076
1077 term xterm-kitty
1078
1079 The value of the TERM environment variable to set. Changing this can
1080 break many terminal programs, only change it if you know what you are
1081 doing, not because you read some advice on Stack Overflow to change it.
1082 The TERM variable is used by various programs to get information about
1083 the capabilities and behavior of the terminal. If you change it, de‐
1084 pending on what programs you run, and how different the terminal you
1085 are changing it to is, various things from key-presses, to colors, to
1086 various advanced features may not work.
1087
1089 wayland_titlebar_color
1090
1091 wayland_titlebar_color system
1092
1093 Change the color of the kitty window's titlebar on Wayland systems with
1094 client side window decorations such as GNOME. A value of system means
1095 to use the default system color, a value of background means to use the
1096 background color of the currently active window and finally you can use
1097 an arbitrary color, such as #12af59 or red.
1098
1099 macos_titlebar_color
1100
1101 macos_titlebar_color system
1102
1103 Change the color of the kitty window's titlebar on macOS. A value of
1104 system means to use the default system color, a value of background
1105 means to use the background color of the currently active window and
1106 finally you can use an arbitrary color, such as #12af59 or red. WARN‐
1107 ING: This option works by using a hack, as there is no proper Cocoa API
1108 for it. It sets the background color of the entire window and makes the
1109 titlebar transparent. As such it is incompatible with
1110 background_opacity. If you want to use both, you are probably better
1111 off just hiding the titlebar with hide_window_decorations.
1112
1113 macos_option_as_alt
1114
1115 macos_option_as_alt no
1116
1117 Use the option key as an alt key. With this set to no, kitty will use
1118 the macOS native Option+Key = unicode character behavior. This will
1119 break any Alt+key keyboard shortcuts in your terminal programs, but you
1120 can use the macOS unicode input technique. You can use the values:
1121 left, right, or both to use only the left, right or both Option keys as
1122 Alt, instead.
1123
1124 macos_hide_from_tasks
1125
1126 macos_hide_from_tasks no
1127
1128 Hide the kitty window from running tasks (⌘+Tab) on macOS.
1129
1130 macos_quit_when_last_window_closed
1131
1132 macos_quit_when_last_window_closed no
1133
1134 Have kitty quit when all the top-level windows are closed. By default,
1135 kitty will stay running, even with no open windows, as is the expected
1136 behavior on macOS.
1137
1138 macos_window_resizable
1139
1140 macos_window_resizable yes
1141
1142 Disable this if you want kitty top-level (OS) windows to not be resiz‐
1143 able on macOS.
1144
1145 macos_thicken_font
1146
1147 macos_thicken_font 0
1148
1149 Draw an extra border around the font with the given width, to increase
1150 legibility at small font sizes. For example, a value of 0.75 will re‐
1151 sult in rendering that looks similar to sub-pixel antialiasing at com‐
1152 mon font sizes.
1153
1154 macos_traditional_fullscreen
1155
1156 macos_traditional_fullscreen no
1157
1158 Use the traditional full-screen transition, that is faster, but less
1159 pretty.
1160
1161 macos_show_window_title_in
1162
1163 macos_show_window_title_in all
1164
1165 Show or hide the window title in the macOS window or menu-bar. A value
1166 of window will show the title of the currently active window at the top
1167 of the macOS window. A value of menubar will show the title of the cur‐
1168 rently active window in the macOS menu-bar, making use of otherwise
1169 wasted space. all will show the title everywhere and none hides the
1170 title in the window and the menu-bar.
1171
1172 macos_custom_beam_cursor
1173
1174 macos_custom_beam_cursor no
1175
1176 Enable/disable custom mouse cursor for macOS that is easier to see on
1177 both light and dark backgrounds. WARNING: this might make your mouse
1178 cursor invisible on dual GPU machines.
1179
1180 linux_display_server
1181
1182 linux_display_server auto
1183
1184 Choose between Wayland and X11 backends. By default, an appropriate
1185 backend based on the system state is chosen automatically. Set it to
1186 x11 or wayland to force the choice.
1187
1189 Keys are identified simply by their lowercase unicode characters. For
1190 example: a for the A key, [ for the left square bracket key, etc. For
1191 functional keys, such as Enter or Escape the names are present at func‐
1192 tional. For a list of modifier names, see: GLFW mods
1193
1194 On Linux you can also use XKB key names to bind keys that are not sup‐
1195 ported by GLFW. See XKB keys for a list of key names. The name to use
1196 is the part after the XKB_KEY_ prefix. Note that you can only use an
1197 XKB key name for keys that are not known as GLFW keys.
1198
1199 Finally, you can use raw system key codes to map keys, again only for
1200 keys that are not known as GLFW keys. To see the system key code for a
1201 key, start kitty with the kitty --debug-keyboard option. Then kitty
1202 will output some debug text for every key event. In that text look for
1203 native_code the value of that becomes the key name in the shortcut. For
1204 example:
1205
1206 on_key_input: glfw key: 65 native_code: 0x61 action: PRESS mods: 0x0 text: 'a'
1207
1208 Here, the key name for the A key is 0x61 and you can use it with:
1209
1210 map ctrl+0x61 something
1211
1212 to map ctrl+a to something.
1213
1214 You can use the special action no_op to unmap a keyboard shortcut that
1215 is assigned in the default configuration:
1216
1217 map kitty_mod+space no_op
1218
1219 You can combine multiple actions to be triggered by a single shortcut,
1220 using the syntax below:
1221
1222 map key combine <separator> action1 <separator> action2 <separator> action3 ...
1223
1224 For example:
1225
1226 map kitty_mod+e combine : new_window : next_layout
1227
1228 this will create a new window and switch to the next available layout
1229
1230 You can use multi-key shortcuts using the syntax shown below:
1231
1232 map key1>key2>key3 action
1233
1234 For example:
1235
1236 map ctrl+f>2 set_font_size 20
1237
1238 kitty_mod
1239
1240 kitty_mod ctrl+shift
1241
1242 The value of kitty_mod is used as the modifier for all default short‐
1243 cuts, you can change it in your kitty.conf to change the modifiers for
1244 all the default shortcuts.
1245
1246 clear_all_shortcuts
1247
1248 clear_all_shortcuts no
1249
1250 You can have kitty remove all shortcut definition seen up to this
1251 point. Useful, for instance, to remove the default shortcuts.
1252
1253 kitten_alias
1254
1255 kitten_alias hints hints --hints-offset=0
1256
1257 You can create aliases for kitten names, this allows overriding the de‐
1258 faults for kitten options and can also be used to shorten repeated map‐
1259 pings of the same kitten with a specific group of options. For example,
1260 the above alias changes the default value of kitty +kitten hints
1261 --hints-offset to zero for all mappings, including the builtin ones.
1262
1263 Clipboard
1264 Copy to clipboard
1265
1266 map ctrl+shift+c copy_to_clipboard
1267
1268 There is also a copy_or_interrupt action that can be optionally mapped
1269 to Ctrl+c. It will copy only if there is a selection and send an in‐
1270 terrupt otherwise. Similarly, copy_and_clear_or_interrupt will copy and
1271 clear the selection or send an interrupt if there is no selection.
1272
1273 Paste from clipboard
1274
1275 map ctrl+shift+v paste_from_clipboard
1276
1277 Paste from selection
1278
1279 map ctrl+shift+s paste_from_selection
1280 map shift+insert paste_from_selection
1281
1282 Pass selection to program
1283
1284 map ctrl+shift+o pass_selection_to_program
1285
1286 You can also pass the contents of the current selection to any program
1287 using pass_selection_to_program. By default, the system's open program
1288 is used, but you can specify your own, the selection will be passed as
1289 a command line argument to the program, for example:
1290
1291 map kitty_mod+o pass_selection_to_program firefox
1292
1293 You can pass the current selection to a terminal program running in a
1294 new kitty window, by using the @selection placeholder:
1295
1296 map kitty_mod+y new_window less @selection
1297
1298 Scrolling
1299 Scroll line up
1300
1301 map ctrl+shift+up scroll_line_up
1302 map ctrl+shift+k scroll_line_up
1303
1304 Scroll line down
1305
1306 map ctrl+shift+down scroll_line_down
1307 map ctrl+shift+j scroll_line_down
1308
1309 Scroll page up
1310
1311 map ctrl+shift+page_up scroll_page_up
1312
1313 Scroll page down
1314
1315 map ctrl+shift+page_down scroll_page_down
1316
1317 Scroll to top
1318
1319 map ctrl+shift+home scroll_home
1320
1321 Scroll to bottom
1322
1323 map ctrl+shift+end scroll_end
1324
1325 Browse scrollback buffer in less
1326
1327 map ctrl+shift+h show_scrollback
1328
1329 You can pipe the contents of the current screen + history buffer as
1330 STDIN to an arbitrary program using the launch function. For example,
1331 the following opens the scrollback buffer in less in an overlay window:
1332
1333 map f1 launch --stdin-source=@screen_scrollback --stdin-add-formatting --type=overlay less +G -R
1334
1335 For more details on piping screen and buffer contents to external pro‐
1336 grams, see launch.
1337
1338 Window management
1339 map ctrl+shift+enter new_window
1340
1341 You can open a new window running an arbitrary program, for example:
1342
1343 map kitty_mod+y launch mutt
1344
1345 You can open a new window with the current working directory set to the
1346 working directory of the current window using:
1347
1348 map ctrl+alt+enter launch --cwd=current
1349
1350 You can open a new window that is allowed to control kitty via the
1351 kitty remote control facility by prefixing the command line with @.
1352 Any programs running in that window will be allowed to control kitty.
1353 For example:
1354
1355 map ctrl+enter launch --allow-remote-control some_program
1356
1357 You can open a new window next to the currently active window or as the
1358 first window, with:
1359
1360 map ctrl+n launch --location=neighbor some_program
1361 map ctrl+f launch --location=first some_program
1362
1363 For more details, see launch.
1364
1365 New OS window
1366
1367 map ctrl+shift+n new_os_window
1368
1369 Works like new_window above, except that it opens a top level OS kitty
1370 window. In particular you can use new_os_window_with_cwd to open a win‐
1371 dow with the current working directory.
1372
1373 Close window
1374
1375 map ctrl+shift+w close_window
1376
1377 Next window
1378
1379 map ctrl+shift+] next_window
1380
1381 Previous window
1382
1383 map ctrl+shift+[ previous_window
1384
1385 Move window forward
1386
1387 map ctrl+shift+f move_window_forward
1388
1389 Move window backward
1390
1391 map ctrl+shift+b move_window_backward
1392
1393 Move window to top
1394
1395 map ctrl+shift+` move_window_to_top
1396
1397 Start resizing window
1398
1399 map ctrl+shift+r start_resizing_window
1400
1401 First window
1402
1403 map ctrl+shift+1 first_window
1404
1405 Second window
1406
1407 map ctrl+shift+2 second_window
1408
1409 Third window
1410
1411 map ctrl+shift+3 third_window
1412
1413 Fourth window
1414
1415 map ctrl+shift+4 fourth_window
1416
1417 Fifth window
1418
1419 map ctrl+shift+5 fifth_window
1420
1421 Sixth window
1422
1423 map ctrl+shift+6 sixth_window
1424
1425 Seventh window
1426
1427 map ctrl+shift+7 seventh_window
1428
1429 Eight window
1430
1431 map ctrl+shift+8 eighth_window
1432
1433 Ninth window
1434
1435 map ctrl+shift+9 ninth_window
1436
1437 Tenth window
1438
1439 map ctrl+shift+0 tenth_window
1440
1441 Tab management
1442 Next tab
1443
1444 map ctrl+shift+right next_tab
1445
1446 Previous tab
1447
1448 map ctrl+shift+left previous_tab
1449
1450 New tab
1451
1452 map ctrl+shift+t new_tab
1453
1454 Close tab
1455
1456 map ctrl+shift+q close_tab
1457
1458 Move tab forward
1459
1460 map ctrl+shift+. move_tab_forward
1461
1462 Move tab backward
1463
1464 map ctrl+shift+, move_tab_backward
1465
1466 Set tab title
1467
1468 map ctrl+shift+alt+t set_tab_title
1469
1470 You can also create shortcuts to go to specific tabs, with 1 being the
1471 first tab, 2 the second tab and -1 being the previously active tab, and
1472 any number larger than the last tab being the last tab:
1473
1474 map ctrl+alt+1 goto_tab 1
1475 map ctrl+alt+2 goto_tab 2
1476
1477 Just as with new_window above, you can also pass the name of arbitrary
1478 commands to run when using new_tab and use new_tab_with_cwd. Finally,
1479 if you want the new tab to open next to the current tab rather than at
1480 the end of the tabs list, use:
1481
1482 map ctrl+t new_tab !neighbor [optional cmd to run]
1483
1484 Layout management
1485 Next layout
1486
1487 map ctrl+shift+l next_layout
1488
1489 You can also create shortcuts to switch to specific layouts:
1490
1491 map ctrl+alt+t goto_layout tall
1492 map ctrl+alt+s goto_layout stack
1493
1494 Similarly, to switch back to the previous layout:
1495
1496 map ctrl+alt+p last_used_layout
1497
1498 Font sizes
1499 You can change the font size for all top-level kitty OS windows at a
1500 time or only the current one.
1501
1502 Increase font size
1503
1504 map ctrl+shift+equal change_font_size all +2.0
1505 map ctrl+shift+plus change_font_size all +2.0
1506 map ctrl+shift+kp_add change_font_size all +2.0
1507
1508 Decrease font size
1509
1510 map ctrl+shift+minus change_font_size all -2.0
1511 map ctrl+shift+kp_subtract change_font_size all -2.0
1512
1513 Reset font size
1514
1515 map ctrl+shift+backspace change_font_size all 0
1516
1517 To setup shortcuts for specific font sizes:
1518
1519 map kitty_mod+f6 change_font_size all 10.0
1520
1521 To setup shortcuts to change only the current OS window's font size:
1522
1523 map kitty_mod+f6 change_font_size current 10.0
1524
1525 Select and act on visible text
1526 Use the hints kitten to select text and either pass it to an external
1527 program or insert it into the terminal or copy it to the clipboard.
1528
1529 Open URL
1530
1531 map ctrl+shift+e kitten hints
1532
1533 Open a currently visible URL using the keyboard. The program used to
1534 open the URL is specified in open_url_with.
1535
1536 Insert selected path
1537
1538 map ctrl+shift+p>f kitten hints --type path --program -
1539
1540 Select a path/filename and insert it into the terminal. Useful, for in‐
1541 stance to run git commands on a filename output from a previous git
1542 command.
1543
1544 Open selected path
1545
1546 map ctrl+shift+p>shift+f kitten hints --type path
1547
1548 Select a path/filename and open it with the default open program.
1549
1550 Insert selected line
1551
1552 map ctrl+shift+p>l kitten hints --type line --program -
1553
1554 Select a line of text and insert it into the terminal. Use for the out‐
1555 put of things like: ls -1
1556
1557 Insert selected word
1558
1559 map ctrl+shift+p>w kitten hints --type word --program -
1560
1561 Select words and insert into terminal.
1562
1563 Insert selected hash
1564
1565 map ctrl+shift+p>h kitten hints --type hash --program -
1566
1567 Select something that looks like a hash and insert it into the termi‐
1568 nal. Useful with git, which uses sha1 hashes to identify commits
1569
1570 Open the selected file at the selected line
1571
1572 map ctrl+shift+p>n kitten hints --type linenum
1573
1574 Select something that looks like filename:linenum and open it in vim at
1575 the specified line number.
1576
1577 Open the selected hyperlink
1578
1579 map ctrl+shift+p>y kitten hints --type hyperlink
1580
1581 Select a hyperlink (i.e. a URL that has been marked as such by the ter‐
1582 minal program, for example, by ls --hyperlink=auto).
1583
1584 The hints kitten has many more modes of operation that you can map to
1585 different shortcuts. For a full description see kittens/hints.
1586
1587 Miscellaneous
1588 Toggle fullscreen
1589
1590 map ctrl+shift+f11 toggle_fullscreen
1591
1592 Toggle maximized
1593
1594 map ctrl+shift+f10 toggle_maximized
1595
1596 Unicode input
1597
1598 map ctrl+shift+u kitten unicode_input
1599
1600 Edit config file
1601
1602 map ctrl+shift+f2 edit_config_file
1603
1604 Open the kitty command shell
1605
1606 map ctrl+shift+escape kitty_shell window
1607
1608 Open the kitty shell in a new window/tab/overlay/os_window to control
1609 kitty using commands.
1610
1611 Increase background opacity
1612
1613 map ctrl+shift+a>m set_background_opacity +0.1
1614
1615 Decrease background opacity
1616
1617 map ctrl+shift+a>l set_background_opacity -0.1
1618
1619 Make background fully opaque
1620
1621 map ctrl+shift+a>1 set_background_opacity 1
1622
1623 Reset background opacity
1624
1625 map ctrl+shift+a>d set_background_opacity default
1626
1627 Reset the terminal
1628
1629 map ctrl+shift+delete clear_terminal reset active
1630
1631 You can create shortcuts to clear/reset the terminal. For example:
1632
1633 # Reset the terminal
1634 map kitty_mod+f9 clear_terminal reset active
1635 # Clear the terminal screen by erasing all contents
1636 map kitty_mod+f10 clear_terminal clear active
1637 # Clear the terminal scrollback by erasing it
1638 map kitty_mod+f11 clear_terminal scrollback active
1639 # Scroll the contents of the screen into the scrollback
1640 map kitty_mod+f12 clear_terminal scroll active
1641
1642 If you want to operate on all windows instead of just the current one,
1643 use all instead of active.
1644
1645 It is also possible to remap Ctrl+L to both scroll the current screen
1646 contents into the scrollback buffer and clear the screen, instead of
1647 just clearing the screen:
1648
1649 map ctrl+l combine : clear_terminal scroll active : send_text normal,application \x0c
1650
1651 Send arbitrary text on key presses
1652
1653 You can tell kitty to send arbitrary (UTF-8) encoded text to the client
1654 program when pressing specified shortcut keys. For example:
1655
1656 map ctrl+alt+a send_text all Special text
1657
1658 This will send "Special text" when you press the ctrl+alt+a key combi‐
1659 nation. The text to be sent is a python string literal so you can use
1660 escapes like \x1b to send control codes or \u21fb to send unicode char‐
1661 acters (or you can just input the unicode characters directly as UTF-8
1662 text). The first argument to send_text is the keyboard modes in which
1663 to activate the shortcut. The possible values are normal or application
1664 or kitty or a comma separated combination of them. The special keyword
1665 all means all modes. The modes normal and application refer to the DEC‐
1666 CKM cursor key mode for terminals, and kitty refers to the special
1667 kitty extended keyboard protocol.
1668
1669 Another example, that outputs a word and then moves the cursor to the
1670 start of the line (same as pressing the Home key):
1671
1672 map ctrl+alt+a send_text normal Word\x1b[H
1673 map ctrl+alt+a send_text application Word\x1bOH
1674
1676 You can edit a fully commented sample kitty.conf by pressing the
1677 ctrl+shift+f2 shortcut in kitty. This will generate a config file with
1678 full documentation and all settings commented out. If you have a
1679 pre-existing kitty.conf, then that will be used instead, delete it to
1680 see the sample file.
1681
1683 Kovid Goyal
1684
1686 2021, Kovid Goyal
1687
1688
1689
1690
16910.20.3 May 06, 2021 KITTY.CONF(5)