| Commit message (Collapse) | Author | Age | Lines |
| ... | |
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When converting mouse scroll events to keyboard input (in alternate
scroll mode), we need to use seat->mouse_focus, not seat->kbd_focus.
To enable this, break out key press/release handling code to a
separate function that takes an explicit term argument. Call this
function from keyboard_key(), input_repeat() and in alternate scroll
mode.
Closes #179
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
These bindings copy from the clipboard or primary selection into the
search buffer.
Default bindings:
* clipboard-paste: ctrl+v, ctrl+y
* primary-paste: shift+insert
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
On some platforms, TIOCSWINSZ has a very large value, >
0x80000000.
On some platforms, the `request` argument to `ioctl(3)` is an `int`.
For platforms where both of the above is true, gcc will warn (and
error out if compiled with `-Werror`) on:
ioctl(fd, TIOCSWINSZ, ...)
To silence this warning, we need to cast `TIOCSWINSZ` to an
integer.
However, doing this on platforms where `request` is an `unsigned long`
will result in `TIOCSWINSZ` being sign-extended (and thus we end up
with an invalid value).
It seems that casting to `unsigned int` works in both cases; it
silences the long -> int conversion warning, while also preserving the
correct value in all cases.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We accept COPY and MOVE actions, for text/plain;charset=utf-8
mime-types.
To implement DnD, we need to track the current DnD data offer *and*
the terminal instance it is (currently) targeting.
To do this, a seat has a new member, ‘dnd_term’. On a DnD enter event,
we lookup the corresponding terminal instance and point ‘dnd_term’ to
it.
On a DnD leave event, ‘dnd_term’ is reset.
The DnD data offer is tracked in the terminal’s wayland window
instance. It is reset, along with the seat’s ‘dnd_term’ on a DnD leave
event.
On a drop event, we immediately clear the seat’s ‘dnd_term’, to ensure
we don’t reset it, or destroy the offer before the drop has been
completed.
The drop’s ‘done()’ callback takes care of destroying and resetting
the DnD offer in the terminal’s wayland window instance.
Closes #175
|
| | | |
|
| |\ \
| | |
| | |
| | | |
Closes #169
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
These options lets the user configure custom fonts and styles, to use
with the bold and italic cell attributes.
By default, they are unset, meaning we use the bold/italic variants of
the regular font.
Closes #169.
|
| |/ / |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Don’t de-reference the xkb context/keymap/state if we failed to
instantiate them.
* Don’t try to send a translated utf8 key sequence if the translation
failed.
* Handle xkb_compose_state_get_utf8() and xkb_state_key_get_utf8()
returning more than 64 bytes.
This _may_ fix #171.
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| | |
Bind to xdg-shell version 2 if available, as this enables us to
track our window’s ‘tiled’ state in the ‘configure’ events.
This in turn allows us to stash the ‘old’ window size when being
tiled, to be used again when restoring the window size when un-tiled.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
Handle xkb_compose_table_new_from_locale() returning NULL. When this
happens, log a warning that “dead keys” will be disabled, and make
sure to never de-reference the compose table pointer.
Closes #170
|
| |\| |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When we ‘consume’ a mouse button event (i.e. when we have a shortcut
mapped to it), the event should *not* be passed on to the client
application.
In 5f64c5c33590a41afd3f621870c6abd89b859073, button handling was
refactored and unfortunately introduced a regression where we once
again started passing consumed button presses to the client
application.
Fixes #168
|
| |\ \
| | |
| | |
| | | |
Closes #149
|
| | | | |
|
| |\ \ \
| | |/
| |/| |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | |
| | |
| | |
| | |
| | | |
Assume it could be a copy-paste typo. We should check PRIMARY, not
CLIPBOARD. Without this fix, we can't use PRIMARY until we copy anything
to CLIPBOARD.
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When a sixel image crosses the scrollback wrap-around, it is split up
into (at least) two pieces.
We use cursor->point.col for all pieces’ x-coordinate. This caused the
final image to appear sheared, since we do a carriage-return (after a
number of linefeeds) after each piece - this causes the cursor’s
position to be reset to the left margin.
The solution is simple; remember the cursor’s initial x-coordinate,
and use that to position all image pieces.
Closes #151.
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This fixes a crash when the emitted sixel extends beyond the right
margin. The crash only happens when there are other sixel images
already emitted.
Fixes part of #151
|
| | | | |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When we detected an invalid section name, we correctly logged this and
warned the user.
However, the internal state machine now had an invalid section enum
value. This caused a crash when the next key/value pair was to be
parsed and we tried to lookup which parser function to call.
Closes #159.
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Trackpad scroll movements are in pixels. Foot previously “translated”
these directly to line movements (i.e. a one pixel scroll event was
translated into a one line scroll).
Now we use the line height of the terminal and correctly convert
pixels to lines.
This makes the trackpad scroll speed in foot consistent with the
scroll speed in e.g. Alacritty and Kitty.
|
| | | |
| | |
| | |
| | | |
Closes #142
|
| | | | |
|
| | | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Allow a mouse binding to match even if its click count is less than
the actual click count.
If there are multiple bindings that match, use the one with the
highest click count (that less than, or equal to the actual click
count).
Closes #146
|
| | | | |
|
| | | | |
|
| | | | |
|
| | |/
|/| |
|
| | | |
|
| | |
| |
| |
| |
| |
| | |
Assume it could be a copy-paste typo. We should check PRIMARY, not
CLIPBOARD. Without this fix, we can't use PRIMARY until we copy anything
to CLIPBOARD.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When csd.preferred == none, we will request CSDs from the compositor,
but internally render as if we are using SSDs. That is, we don’t
render any window decorations at all.
Note that some compositors may ignore our request to use CSDs, and
still render SSDs for us.
Closes #163
|
| |\ \ |
|
| | | | |
|
| |/ / |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When a sixel image crosses the scrollback wrap-around, it is split up
into (at least) two pieces.
We use cursor->point.col for all pieces’ x-coordinate. This caused the
final image to appear sheared, since we do a carriage-return (after a
number of linefeeds) after each piece - this causes the cursor’s
position to be reset to the left margin.
The solution is simple; remember the cursor’s initial x-coordinate,
and use that to position all image pieces.
Closes #151.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
This fixes a crash when the emitted sixel extends beyond the right
margin. The crash only happens when there are other sixel images
already emitted.
Fixes part of #151
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add anew config option, ‘bell=none|set-urgency’. When set to
‘set-urgency’, the margins will be painted in red (if the window did
not have keyboard focus).
This is intended as a cheap replacement for the ‘urgency’ hint, that
doesn’t (yet) exist on Wayland.
Closes #157
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When we detected an invalid section name, we correctly logged this and
warned the user.
However, the internal state machine now had an invalid section enum
value. This caused a crash when the next key/value pair was to be
parsed and we tried to lookup which parser function to call.
Closes #159.
|
| | |
| |
| |
| |
| | |
Since we’re now doing reverse auto-wrapping by default, we add
‘bw’ (‘auto_left_margin’)to terminfo.
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| | |
This reverts commit 02e3e4ac9b2703a0a867211c2482eab257cbc311.
This broke at least Emacs. Cursor movement at the margins *is*
undefined, and the behavior we’re now reverting to matches XTerm.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When lcf is true, cursor is actually beyond the right margin, but the
stored coordinate is at the margin.
This means we need to reduce the number of cells to move the cursor by
one.
This fixes an issue where e.g. backspacing when the cursor is at the
right margin erased the next-to-last character instead of the last
character.
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Trackpad scroll movements are in pixels. Foot previously “translated”
these directly to line movements (i.e. a one pixel scroll event was
translated into a one line scroll).
Now we use the line height of the terminal and correctly convert
pixels to lines.
This makes the trackpad scroll speed in foot consistent with the
scroll speed in e.g. Alacritty and Kitty.
|
| | |
| |
| |
| | |
Closes #142
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Allow a mouse binding to match even if its click count is less than
the actual click count.
If there are multiple bindings that match, use the one with the
highest click count (that less than, or equal to the actual click
count).
Closes #146
|
| | |
| |
| |
| | |
This reverts commit 9d6b2c934222f7e492fba06d02dd2d5991814d1b.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When enabled, man pages are generated and installed, along with
README.md, CHANGELOG.md and LICENSE. This requires ‘scdoc’ as a make
dependency.
When disabled, ‘scdoc’ is no longer required, no man pages will be
built, and no documentation at all is installed.
Defaults to ‘enabled’.
|
| |/ |
|
| | |
|
| | |
|
| |
|
|
| |
This reverts commit 8f3692f9a662c69cadca1b840f22f4f222b550e9.
|
| | |
|
| | |
|
| |
|
|
|
| |
This option controls the initial state of the Alternate Scroll Mode,
and defaults to ‘enabled’.
|
| |
|
|
|
|
|
|
| |
Use the new fcft_set_scaling_filter() API to use a non-default scaling
filter.
By default, we use lanczo3, the ‘best’ filter. This overrides the
default in fcft, which is ‘cubic’ filtering.
|
| |\
| |
| |
| | |
Closes #128
|
| | |
| |
| |
| |
| |
| |
| |
| | |
This deprecates/renames scrollback-up/down to scrollback-up/down-page.
It also renames scrollback-up/down-half to
scrollback-up/down-half-page, and adds the new bindings
scrollback-up/down-line.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
These new bindings scroll up/down half a page in the
scrollback (instead of the full page scrolled by
‘scrollback-{up,down}’).
Closes #128.
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| | |
Even though we translate the cursor position from the old grid
coordinates to the new, the cursor may _still_ end up outside the
visible area.
Make sure it doesn’t.
|
| |/ |
|
| |\ |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* Add -W,--window-size-chars command line option
* Add initial-window-size-chars foot.ini option
* Add -w,--window-size-pixels command line option
* Add initial-window-size-pixels foot.ini option
* Deprecate -g,--geometry command line option in favor of
-w,--window-size-pixels
* Deprecate geometry option in foot.ini in favor of
initial-window-size-pixels
|
| |\ \
| |/
|/| |
|
| | |
| |
| |
| | |
This is what XTerm emits with `modifyOtherKeys=1`, which is foot’s only mode.
|
| |/
|
|
|
|
|
|
| |
The deprecation sections mentions ‘footrc’ being deprecated, and
replaced by ‘foot.ini’. Since a lot of the changelog entries refer to
foot.ini, make sure the user sees this first.
Also, use foot.ini (and not footrc) consistently in all changelog entries.
|
| |\ |
|
| | |
| |
| |
| |
| | |
Before this patch, reflow called `wcwidth()` on our magic values for
composed characters.
|
| |/ |
|
| |
|
|
| |
Thus it’s wrong to say its behavior has changed.
|
| |\
| |
| |
| | |
Closes #116
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Try to detect double-width *glyphs* for single-width *characters*, and
allow them to overflow into the next cell.
This is only done for single-width chars with a glyph width that is at
least 1.5 cells wide, but at most 3 cells.
The feature is gated by the new
‘tweak.allow-overflowing-double-width-glyphs’, and is disabled by
default.
Closes #116
|
| |/ |
|
| | |
|
| |\
| |
| |
| | |
Closes #108
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When calculating where in the scrollback history we are, we previously
did this against the total number of scrollback lines. I.e. the
`scrollback.lines` setting in `footrc`.
Now, we count only the used/allocated scrollback lines.
Note that the initial indicator position might still seem to start a
bit high up, if the number of used scrollback lines is low. This is
because we use the *top* of the screen for the current position. Thus,
we'll never be at the bottom (except for the special case when
we're *really* at the bottom).
|
| |/ |
|