| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
|
|
| |
Still lacking some configuration options (highlight all, case
insensitive search, …) and focus is not currently restored to the
TermView on close currently.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
With the default priority, the rendering thread would starve if the PTY
already has input ready. For example, when executing yes(1).
|
|\ |
|
| | |
|
|/ |
|
| |
|
| |
|
|
|
|
|
|
| |
Since 61ca4b802c7df75de8a31c6e409eeae15190accf the explicit size check
should no longer be needed, i.e. offset selects nothing already if the
offset exceeds the amount of available entries.
|
|
|
|
|
| |
after reaching current entry. While at it, also attempt to clarify the
comment.
|
|
|
|
|
|
|
|
|
|
|
| |
This mimicks the behavior familiar from most shells. We also make sure
that this doesn't happen when we hit the oldest history entry -- in that
case we will just do nothing if Up is pressed.
To implement this correctly we need to distinguish between a position in
the history and no position in the history. We encode the latter using
`None` and just call `reset_history_index()` in case we encounter it to
reacquire a point of reference.
|
|
|
|
|
| |
Makes the code a bit more readable IMHO. Also add a comment explaining
why we can't use use automatic horizontal scrolling in the first place.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There is an issue [1] in GTK 3 which causes the automatic hyphenation of
GtkTextViews to cause a horizontal scroll bar to appear despite it being
not necessary (in our case the horizontal scrollbar is rendered over the
hyphens which is hardly cause for concern).
Ideally we would just disable auto hyphenation, but this doesn't seem to
be possible [2] in GTK 3 yet. As a workaround we just disable horizontal
scrolling altogether in in update_wrapmode() if wordwrap is enabled.
While we're at it add a note about the GTK 4 feature [3] which would
allow us to disable auto hyphenation. For GTK 3 it seems to require to
set a pango [4] attribute in the pango layout used for rendering the
widget which is not exposed in a modifiable way by GtkTextView
unfortunately -- or at least I haven't been able to figure out how the
desired result could be achieved.
[1]: https://gitlab.gnome.org/GNOME/gtk/-/issues/2384
[2]: https://gitlab.gnome.org/GNOME/gtk/-/issues/2530
[3]: https://docs.gtk.org/gtk4/property.TextTag.insert-hyphens.html
[4]: See these solutions of other projects that ran into this issue:
https://github.com/mate-desktop/caja/pull/1334
https://gitlab.gnome.org/GNOME/nautilus/-/merge_requests/482
|
|
|
|
|
| |
By sorting rows in descending order instead of performing an arithmetic
operation on the maximum value.
|
|
|
|
| |
Should be the default behaviour though.
|
| |
|
|\ |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| | |
Return None if no history entry was found and reset the offset if so.
Without this patch the offset would be continuously
incremented/decrement.
|
| | |
|
| | |
|
|/
|
|
|
|
| |
The current executable is determined by using tcgetpgrp on the PTY file
descriptor. All history entries are stored in an SQL lite database on a
per-line basis.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
This should be made configurable using the context menu and/or a
keybinding in future commits.
|
| |
|
| |
|
|
|
|
|
|
|
| |
This one checks for the output point explicitly and does not allow
movements to go beyond it. To test this, try a shell with `PS1='>'`
(i.e. no space after the prompt character) and try ctrl+w. Without this
patch, words in the previous line would be deleted.
|
|
|
|
|
|
|
|
|
|
|
|
| |
In an user environment (which saneterm would usually be executed in)
$SHELL should point to the current user's login shell as per environ(7).
On startup, check if the variable is set and use it to populate the
default command to run if it is, otherwise fall back to `sh` like
before.
I believe this is the correct change even if it gives users (including
me) more trouble since many login shells people will use (like fish)
don't work well in saneterm, whereas /bin/sh usually will work fine.
|
| |
|
| |
|
|
|
|
|
|
|
| |
Otherwise, when typing a word directly after the output point selecting
this word and attempting to delete it using backspace doesn't work.
Seems to me, if text is selected Gtk treats the beginning of this
selected test as the current cursor position.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Seems to make things easier when actually installing saneterm (or at
least I wouldn't know how to make it work without relative or absoulte
imports). However this breaks executing the __main__.py script directly
which is replaceable by using python -msaneterm which seems fine.
Preserving the __main__.py seems to only be possible using self
modifying PYTHOPATH which is just ugly.
|
| |
|
|
|
|
|
| |
Even if TUIs are not supported, this is used by some applications (most
notably) ls(1) for outputting text in multiple columns.
|
|
|
|
|
| |
Required by application such as ls which assume that every printed
character has the same width.
|
| |
|
| |
|