Kovid Goyal
5cf228e362
Fix tab activity tracking not working unless there is some other activity in tab bar as well
...
Fixes #3571
2021-05-05 14:30:16 +05:30
Kovid Goyal
d782654819
Forgot to handle case of empty scrollback
2021-04-23 16:07:10 +05:30
Kovid Goyal
b32c346eed
A new protocol extension to unscroll the screen
...
See https://gitlab.freedesktop.org/terminal-wg/specifications/-/issues/30
2021-04-23 15:44:38 +05:30
Kovid Goyal
77b8e204ad
Fix graphics being cleared when switching to alt screen if the switch mode is to not clear the alt screen
2021-04-23 14:51:32 +05:30
Kovid Goyal
cf3662442f
Fix #3460
2021-04-09 16:56:53 +05:30
Kovid Goyal
0be5347e6a
Better error message when screen_resize() fails
2021-04-09 10:09:17 +05:30
Kovid Goyal
a13f815591
Fix index_selection() not updating empty selections
...
Newly created selections are empty but must still be indexed.
Fixes #3431
2021-04-03 10:48:43 +05:30
Kovid Goyal
b5ac06e652
Fix #3422
2021-04-03 06:48:10 +05:30
Kovid Goyal
cb515157b3
Fix the selection getting changed if the screen contents scroll while the selection is in progress
...
When the selection object was refactored to track the input
co-ordinates, index_selection() was not updated accordingly.
Fixes #3431
2021-04-01 23:17:13 +05:30
Kovid Goyal
0372242d12
Use an enum for UTF8 decoder state
2021-03-31 15:19:27 +05:30
Kovid Goyal
ca7587c084
Allow skipping zero cells when converting a line to unicode
2021-03-23 09:53:22 +05:30
Kovid Goyal
ccafdacc6f
Ensure cursor position is correct when filling line buffer
2021-03-18 10:39:08 +05:30
Kovid Goyal
4a996c1f76
Use the final cursor position when calculating number of continued lines in resized buffer
2021-03-17 22:29:59 +05:30
Kovid Goyal
d743aff4bc
Make the code to copy lines into linebufs general
2021-03-17 22:02:47 +05:30
Kovid Goyal
0f3ff4e2d9
Scrollback filling should happen after cursor position is finalized
2021-03-17 21:59:11 +05:30
Kovid Goyal
90722ecbe7
historybuf should be used only when current screen is the main linebuf
2021-03-17 13:51:30 +05:30
Kovid Goyal
071986138b
Cleanup previous merge
2021-03-17 13:43:26 +05:30
Kovid Goyal
d61c4a9569
Merge branch 'scrollback-fill-enlarged-window' of https://github.com/elebow/kitty
2021-03-17 12:22:12 +05:30
Eddie Lebow
9fff829ab4
Implement scrollback_fill_enlarged_window
2021-03-17 02:27:59 -04:00
Kovid Goyal
d360d077d1
Handle the XTMODKEYS escape code
...
Treat the XTerm specific modifyOtherKeys escape codes as putting the
disambiguate mode on/off the stack. The escape code causes XTerm to use
a (broken, naturally) variant of CSI u encoding for many keys, so we
treat it as going into the disambiguate mode.
2021-03-16 17:46:11 +05:30
Kovid Goyal
275b8ce2e7
Fix #3322
2021-02-15 21:27:52 +05:30
Kovid Goyal
00edb6058e
Start work on implementing frame transitions
...
Also ensure that the correct OS Window is current when uploading images
to GPU.
2021-01-31 20:58:42 +05:30
Kovid Goyal
ac2a33d09f
Silence the errors about OSC 7
...
Up to now this poorly designed and completely unnecessary escape code
was relegated to only GNOME, however, off late Apple has started using
it as well, so silently ignore it, instead of spamming error messages
for it.
2021-01-29 12:43:41 +05:30
Kovid Goyal
f9844ba3b0
Allow negative numbers in CSI codes
2021-01-21 07:06:43 +05:30
Kovid Goyal
47a901385f
Implement reporting of all keys as escape codes with text
2021-01-16 20:52:13 +05:30
Kovid Goyal
1690718710
More removal of GLFW_KEY_ constants
2021-01-16 20:52:12 +05:30
Kovid Goyal
a30ea2b7f8
Implement progressive enhancement of key event reporting
2021-01-16 20:52:12 +05:30
Kovid Goyal
c8a9336160
Code to encode key events
2021-01-16 20:52:12 +05:30
Kovid Goyal
ca65ad6fa3
Inline qsort
...
Cleaner, more local code and faster sorting by virtue of inlining the
comparisons. What's not to like.
2021-01-04 14:14:15 +05:30
Kovid Goyal
b3ed4c3f40
Simplify implementation of REP
...
Also make it align more with the standard by using the actual last drawn
graphics character rather than the character before the cursor
2021-01-03 04:38:02 +05:30
Kovid Goyal
5f8dee8384
Add support for the color settings stack that XTerm copied from us without acknowledgement and decided to use incompatible escape codes for.
...
Completely in keeping with that project's past behavior.
See https://github.com/kovidgoyal/kitty/issues/879
XTerm announcement:
https://www.mail-archive.com/xorg@lists.x.org/msg06419.html
2020-12-21 21:39:05 +05:30
Kovid Goyal
e97f1a4310
Have the save/restore colors escape codes also save restore the ANSI color table
2020-12-21 19:38:03 +05:30
Kovid Goyal
19870983ca
Allow specifying text formatting in tab_title_template
...
Fixes #3146
2020-12-08 21:42:40 +05:30
Kovid Goyal
b00cd5cbc3
Match save/restore cursor behavior of other terms
...
For the sake of interoperability. This means that doing a DECRC without
a prior DECSC is now undefined. However, one can now issue multiple
DECRC for a single DECSC. Fixes #1264
2020-12-01 17:55:17 +05:30
Roman Perepelitsa
620eaf1ada
Change the flow of lines from the scroll region to the scrollback
...
There are two user-visible changes in here:
1. If a scroll region is set such that there is a bottom margin and no
top margin, scrolling the region forward used to discard the top
lines. Now those lines are appended to the scrollback.
```shell
# Assuming a terminal window with 24 lines.
printf '\033[H\033[J\033[3J\033[0;5r' && seq 100
```
This command used to result in an empty scrollback. Now it contains
the numbers 1-96.
2. If a scroll region is set such that there is a top margin and no bottom
margin, scrolling the region forward used to append the top lines to
the scrollback. Now these lines are discarded.
```shell
# Assuming a terminal window with 24 lines.
printf '\033[H\033[J\033[3J\033[2;24r' && seq 100
```
This command used to populate scrollback with the numbers 2-78. Now
the scrollback is empty. The numbers on the screen are the same as
before: 1 and 79-100.
Related issue: #3113 .
2020-11-20 15:41:57 +01:00
Kovid Goyal
9b32842f66
Fix #3096
2020-11-13 07:47:40 +05:30
Kovid Goyal
9816979169
Don't restrict the DCH control code to only the current scroll region
...
Matches behavior of other terminal emulators. Fixes #3090
2020-11-12 11:44:09 +05:30
Luflosi
e2646c08a5
Fix upwards selection not being cleared when lines change
...
When selecting text by dragging upwards, the "end" of the selection is above the "start". This causes the `selection_has_screen_line()` to never return `true` in this case.
In practice this bug causes the selection to not be cleared when the screen contents under the selection change if it was made by dragging upwards.
2020-10-13 21:40:03 +02:00
Kovid Goyal
2a8c8c0cbb
Fix #2980
2020-09-25 16:06:07 +05:30
Kovid Goyal
9d4246a285
Output hyperlink markup when serializing as ANSI
2020-09-22 16:18:22 +05:30
Kovid Goyal
e0f5c39297
Get rid of unneeded malloc in as_text_generic
2020-09-22 09:57:45 +05:30
Kovid Goyal
0d665495b8
Make getting hyperlinks from ids useable throughtout the codebase
2020-09-22 09:25:16 +05:30
Kovid Goyal
a78515e5bf
Remove the max size limit for line_as_ansi
...
Needed for output of hyperlinks, also more efficient, since avoids
malloc per line. Also fix pagerhist not having SGR reset at the start of
every line.
2020-09-20 11:26:59 +05:30
Kovid Goyal
f8a80ccf5f
Move the wcswidth functions out of screen.c
...
They have nothing to do with screens
2020-09-17 21:24:52 +05:30
Kovid Goyal
6461dccbdc
Make wcswidth ignore more escape codes
...
Needed to ignore OSC 8 hyperlinks since we will
eventually have to send those with SGR formatting to the hints
kitten.
2020-09-17 20:16:17 +05:30
Kovid Goyal
36340caf4c
Fix URL marking + scrolling
...
The ranges have to use on screen line numbers not line->ynum
Fixes #2969
2020-09-17 16:44:10 +05:30
Kovid Goyal
9a80ab0700
More robust
2020-09-17 10:42:30 +05:30
Kovid Goyal
339d972d8d
Use INT_MAX rather than self->lines + 10
...
More likely to never co-incide
2020-09-17 10:41:13 +05:30
Kovid Goyal
6d1e1030bd
...
2020-09-17 10:37:14 +05:30
Kovid Goyal
c26808c59e
Fix #2967
2020-09-17 09:30:30 +05:30