Commit graph

276 commits

Author SHA1 Message Date
Daniel Eklöf
771af699f0
meson: bump version to 1.20.2 2025-01-18 09:25:36 +01:00
Daniel Eklöf
f7031a2161
meson: fix dependencies (utf8proc missing in lots of places) 2025-01-18 09:23:29 +01:00
Daniel Eklöf
b0e6645395
meson: bump version to 1.20.1 2025-01-03 08:01:35 +01:00
Daniel Eklöf
9b1c31ebcb
meson: bump version to 1.20.0 2025-01-01 09:21:51 +01:00
Daniel Eklöf
cb91fbb4b6
meson: bump version to 1.19.0 2024-10-23 13:51:15 +02:00
Daniel Eklöf
5ef69fc591
meson: detect wayland-protocols >= 1.37, and conditionally enable xdg-toplevel-icon-v1 2024-09-13 09:04:17 +02:00
Craig Barnes
d4a1283797
xsnprintf: various improvements related to xvsnprintf() and xsnprintf()
Summary of changes:

* Make xvsnprintf() static
* restrict-qualify pointer arguments (as done by the libc equivalents)
* Make comments and spec references more thorough
* Remove pointless `n <= INT_MAX` assertion (see comment)
* Use FATAL_ERROR() instead of xassert() (since the assertion is inside
  a shared util function but the caller is responsible for ensuring the
  condition holds true)
* Change some callers to use size_t instead of int for the return value
  (negative returns are impossible and all subsequent uses are size_t)

The updated comments and code were taken (and adapted) from:

49260bb154/src/util/xsnprintf.c (L6-50)

This work was entirely authored by me and I hereby license this
contribution under the MIT license (stated explicitly, so that
there's no ambiguity w.r.t. the original license).
2024-09-13 09:01:15 +02:00
Daniel Eklöf
c8185aec1d
desktop: rename to foot{,client,-server}.desktop
That is, skip the reverse DNS naming scheme suggested by the .desktop
specification, and directly match our app-ids ("foot", and
"footclient").

This simplifies .desktop -> window instance mapping, allowing DEs to
match the filenames directly, without having to look at the
StartupWMClass key in the .desktop files.

These are the original names of the .desktop files. There were
renamed (to use the reverse DNS syntax) to please the flathub people,
who *required* this scheme to accept the foot package.

But, since:

* We don't package foot ourselves
* We don't go out of our way to support non-distro packaging schemes
* Flathub still hasn't merged the foot PR (it's now 2 years old)
* There are no know issues in any known DE that prevents a non-reverse
  DNS .desktop filename from working
* There are plenty of other applications that doesn't use reverse DNS
  names (a very clear majority, in my case)

Let's just revert back to the simpler naming scheme.

Closes #1607
2024-09-08 13:06:27 +02:00
Daniel Eklöf
ce9c9f6be6
meson: bump version to 1.18.1 2024-08-14 12:00:20 +02:00
Daniel Eklöf
803f712332
meson: add "prefix: '#include <unistd.h>" to cc.has_function()
When checking for execvpe, include <unistd.h>
2024-08-09 08:15:13 +02:00
Shogo Yamazaki
9d5d84a835
meson: fix false positive detection of memfd_create
Add the arguments to `has_function` to properly detect availability of the
function on SDK environments.
2024-08-09 08:14:12 +02:00
Daniel Eklöf
b5e692ef8b
meson: bump version to 1.18.0 2024-08-02 14:28:16 +02:00
Daniel Eklöf
065eb05e3e
meson/pgo: fix PGO build errors with recent meson(?) versions
The back-reference to 'tokenize.c' in the parent directory causes PGO
build failures, where gcc can't find the PGO data. Likely due to
path/naming issues caused by meson's generated build directories.
2024-07-18 09:02:42 +02:00
Daniel Eklöf
9665661445
vt: only apply VS-15/16 to valid sequences
At compile time, build a lookup table from the Unicode data file
'emoji-variation-sequences.txt'.

At run-time, when we detect a VS-15/16 sequence, do a lookup in this
table, and enforce the variation selector iff the sequence is valid.

Closes #1742
2024-06-25 08:20:21 +02:00
Jan Beich
f67449700b
meson: auto-detect execvpe on FreeBSD
0667d0e0e3
2024-06-07 16:31:11 +02:00
Daniel Eklöf
3c96d0b68e
render: use single-pixel buffers for overlays, when possible
The unicode-mode, and flash overlays are single color buffers. This
means we can use the single-pixel buffer protocol.

It's undefined whether the compositor will release the buffer or not;
to make things easier, simply destroy the buffer as soon as we've
committed it.

Note that since compositors don't necessarily release single-pixel
buffers, we can't plug them into our own buffer interface. This means
we can't use buffer pointers to check if we can re-use the previous
buffer (i.e. we can skip comitting a new buffer), or if we have to
create a new one.

It's _almost_ enough to just check if the last overlay style is the
same as the current one. Except that that doesn't take window resizes
into account...
2024-05-22 13:48:46 +02:00
Daniel Eklöf
b88f0d672f
meson: bump version to 1.17.2 2024-04-17 11:26:45 +02:00
Daniel Eklöf
04ebd02874
meson: bump version to 1.17.1 2024-04-11 15:28:17 +02:00
Daniel Eklöf
21951feb2b
meson: bump version to 1.17.0 2024-04-02 16:27:54 +02:00
Daniel Eklöf
8b3dbf0972
meson: bump version to 1.16.2 2023-10-17 17:24:12 +02:00
Daniel Eklöf
195eb3356a
meson: bump version to 1.16.1 2023-10-12 16:36:18 +02:00
Daniel Eklöf
a9d6eaf937
meson: bump version to 1.16.0 2023-10-11 18:15:01 +02:00
Daniel Eklöf
34520aa16e
meson: allow building with wayland-protocols as a subproject 2023-08-08 19:32:45 +02:00
Daniel Eklöf
698c5b54f3
wayland: cursor-shape-v1 is now always available
Since we're requiring wayland-protocols >= 1.32
2023-08-07 16:53:19 +02:00
Daniel Eklöf
7eee415b75
wayland: fractional-scale-v1 is now always available
Since we're requiring wayland-protocols >= 1.32
2023-08-07 16:53:19 +02:00
Daniel Eklöf
d59a4e7a77
wayland: xdg-activation is now always available
Since we're requiring wayland-protocols >= 1.32
2023-08-07 16:53:19 +02:00
Daniel Eklöf
e0475a5421
meson: require wayland-protocols >= 1.32 2023-08-07 16:53:19 +02:00
Daniel Eklöf
f314699945
meson: bump version to 1.15.3 2023-08-07 16:39:54 +02:00
Daniel Eklöf
53a5d62e5a
meson: bump version to 1.15.2 2023-07-30 13:18:55 +02:00
Daniel Eklöf
139fd6d55c
meson: add -Dterminfo-base-name option
This defines the base name of the generated terminfo files. It
defaults to the value of -Ddefault-terminfo (i.e. 'foot')

Example:

  meson -Ddefault-terminfo=foot-bananas -Dterminfo-base-name=foot-apples

The generated terminfo files will be

* terminfo/f/foot-apples
* terminfo/f/foot-apples-direct

The default value of $TERM will be 'foot-bananas'
2023-07-28 15:40:53 +02:00
Daniel Eklöf
9e4d82a484
meson: bump version to 1.15.1 2023-07-21 08:57:03 +02:00
Max Gautier
d3ffb0bde1
Ties systemd units to graphical-session.target
- wayland-instance template target was a mistake.
  Systemd does not support simultaneous same user session, so stop
  trying to go against that.
- Only start systemd units in Wayland environments.
2023-07-21 08:12:55 +02:00
Daniel Eklöf
5a3706ac46
meson: bump version to 1.15.0 2023-07-14 12:26:03 +02:00
Daniel Eklöf
3800b279d6
meson: move cursor-shape.{c,h} from ‘foot’ binary to vtlib
This should fix a build issue when doing partial PGO builds, when
cursor-shape-v1 is *available*.
2023-07-03 14:42:22 +02:00
Daniel Eklöf
8fc43ccd2d
meson: log availability of cursor-shape-v1 2023-07-03 14:36:33 +02:00
Daniel Eklöf
c2e481fb6a
meson: bump wayland-protocols version required for cursor-shape to 1.32 2023-07-03 14:36:32 +02:00
Daniel Eklöf
bf83a0b2bd
meson: cursor-shape: use .xml from wayland-protocols
This patch assumes a git snapshot of wayland-protocols are
installed.

We need to bump the version number as soon as the next version of
wayland-protocols have been released.
2023-07-03 14:36:32 +02:00
Daniel Eklöf
c8e13ad393
cursor-shape: add support for server side cursor shapes
This implements support for the new cursor-shape-v1 protocol. When
available, we use it, instead of client-side cursor surfaces, to
select the xcursor shape.

Note that we still need to keep client side pointers, for:

* backward compatibility
* to be able to "hide" the cursor

Closes #1379
2023-07-03 14:36:32 +02:00
Daniel Eklöf
ee794a121e
refactor: track current xcursor using an enum, instead of a char pointer 2023-07-03 14:36:32 +02:00
Daniel Eklöf
7a37e6891f
meson: log availability of optional wayland protocols 2023-06-30 08:28:20 +02:00
Daniel Eklöf
1e6204e1ac
meson: generate bindings for wp-fractional-scale + wp-viewport 2023-06-29 15:38:17 +02:00
sewn
16872ecc41
meson: use meson feed feature for scdoc input
Removes the need for a shell dependency.
2023-06-14 17:15:20 +00:00
Daniel Eklöf
e78319fccd
utmp: rewrite utmp logging
This patch generalizes the utmp support, to not only support
libutempter, but also ulog (and in the future, even more interfaces).

* Rename config option main.utempter to main.utmp-helper
* Add meson option -Dutmp-backend=none|libutempter|ulog|auto
* Rename meson option -Ddefault-utempter-path to -Dutmp-default-helper-path
* utmp is no longer detected at compile time, but at runtime instead.

Meson will configure the following pre-processor macros, based on the
selected utmp backend:

* UTMP_ADD - argument to pass to utmp helper when adding a record (starting foot)
* UTMP_DEL - argument to pass to utmp helper when removing a record (exiting foot)
* UTMP_DEL_HAVE_ARGUMENT - if defined, UTMP_DEL expects an extra argument ($WAYLAND_DISPLAY)
* UTMP_DEFAULT_HELPER_PATH - path to the default utmp helper binary

The documentation has been updated to mention which arguments are
passed to the helper binary.

Closes #1314
2023-05-22 18:47:25 +02:00
Vivian Szczepanski
98528da5e5
meson: bump tllist dependency version to 1.1.0
The tll_sort() macro was added to tllist in version 1.1.0, and so
building with a previous version causes a linking error.
2023-04-09 09:05:50 +02:00
Daniel Eklöf
ae6bbce6c2
meson: bump version to 1.14.0 2023-04-03 18:52:42 +02:00
Daniel Eklöf
9937d92c85
utils: xtgettcap: new utility, to send XTGETTCAP queries 2022-10-07 14:40:22 +02:00
Daniel Eklöf
aa10b1d2da
Add support for creating utmp records
This patch adds support for creating utmp records using the ‘utempter’
helper binary from the ‘libutempter’ package.

* New config option ‘main.utempter’
* New meson command line option, -Ddefault-utempter-path. Defaults to
  auto-detecting the path.

The default value of the new ‘main.utempter’ config option depends on
the meson command line option ‘-Ddefault-utempter-path’.

If ‘main.utempter’ is *not* set to ‘none’, foot will try to execute
the utempter helper binary to create utmp records when a new terminal
is instantiated. The record is removed when the terminal instance is
destroyed.
2022-09-23 23:02:25 +02:00
Vladimír Magyar
debf1b8453
chore: rename desktop files 2022-09-18 17:57:11 +02:00
Daniel Eklöf
cd1933baf1
meson: bump version to 1.13.1 2022-08-31 19:19:15 +02:00
Daniel Eklöf
e0465d3a7a
meson: bump version to 1.13.0 2022-08-07 09:32:02 +02:00