Commit graph

1052 commits

Author SHA1 Message Date
Daniel Eklöf
601f77fb1f
PKGBUILD: tllist is only a make dependency, bump fcft to 0.2.0 2019-12-01 19:25:39 +01:00
Daniel Eklöf
b3334444bb
meson: require fcft 0.2.0 2019-12-01 19:25:15 +01:00
Daniel Eklöf
644f114909
fcft: fixup 2019-12-01 19:25:06 +01:00
Daniel Eklöf
b5780e735e
Add missing includes 2019-12-01 19:22:45 +01:00
Daniel Eklöf
e9fbb371df
fcft: font_from_name() no longer accepts a tllist 2019-12-01 19:22:25 +01:00
Daniel Eklöf
69dc53409e
fcft: bump to 0.2.0 2019-12-01 19:22:09 +01:00
Daniel Eklöf
c92746203a
meson: fcft: version must be 0.1.x 2019-12-01 18:47:39 +01:00
Daniel Eklöf
e5b588977f
fcft: bump 2019-12-01 18:04:03 +01:00
Daniel Eklöf
1307f61da1
PKGBUILD/meson: add version requirements to tllist+fcft 2019-12-01 17:50:27 +01:00
Daniel Eklöf
a041b334af
fcft: bump 2019-12-01 17:45:43 +01:00
Daniel Eklöf
1585edd194
fcft: bump 2019-12-01 16:32:34 +01:00
Daniel Eklöf
50a32a0e15
PKGBUILD: don't allow subproject fallback 2019-12-01 16:28:49 +01:00
Daniel Eklöf
fcea49920f
meson: tllist/fcft: use system dependency first, fallback to subprojects 2019-12-01 16:11:35 +01:00
Daniel Eklöf
ba56379055
meson/PKGBUILD: we no longer depend directly on fontconfig/freetype 2019-12-01 15:42:28 +01:00
Daniel Eklöf
a38d1d6928
PKGBUILD: strip extra git revision data from checked in PKGBUILD 2019-12-01 14:05:56 +01:00
Daniel Eklöf
30335ef32a
fcft: include <fcft/fcft.h>, and use fcft/stride.h instead of local copy 2019-12-01 14:03:24 +01:00
Daniel Eklöf
5919b0642c
README: add tllist and fcft to list of required libraries 2019-12-01 13:57:59 +01:00
Daniel Eklöf
5fe34dc820
PKGBUILD: add tllist and fcft dependencies 2019-12-01 13:55:14 +01:00
Daniel Eklöf
30f58bac56
meson: tllist/fcft: oops, forgot to set 'required: false' 2019-12-01 13:54:18 +01:00
Daniel Eklöf
526f65a392
Merge branch 'use-fcft' 2019-12-01 13:52:30 +01:00
Daniel Eklöf
01c1fcd60f
PKGBUILD: don't error out on missing profile data count files 2019-12-01 13:50:57 +01:00
Daniel Eklöf
fd9c28464d
fcft: use fcft instead of local copy of font.c/font.h 2019-12-01 13:43:51 +01:00
Daniel Eklöf
3c939f76e3
meson: tllist: try subproject first, then fallback to system dependency 2019-12-01 13:40:19 +01:00
Daniel Eklöf
9f91760886
tllist: add git submodule directly under subprojects 2019-12-01 13:39:35 +01:00
Daniel Eklöf
ed176352e2
tllist: remove git submodule and local copy under subprojects 2019-12-01 13:38:59 +01:00
Daniel Eklöf
f0ad3d3afc
font: log fontconfig/freetype version when debug logging has been enabled 2019-12-01 11:38:20 +01:00
Daniel Eklöf
3df292a944
Revert "font: ceil:ing the top value seems to look better when scaled"
This reverts commit 95d97b3973.
2019-12-01 11:33:22 +01:00
Daniel Eklöf
95d97b3973
font: ceil:ing the top value seems to look better when scaled 2019-11-30 23:31:51 +01:00
Daniel Eklöf
16c25f9a8f
font: fix estimated underline thickness; descent is typically negative 2019-11-30 23:16:50 +01:00
Daniel Eklöf
fbeb1e9610
term: mouse reporting functions no longer take modifier state
The mouse reporting functions are called from input when we receive
Wayland mouse events.

We used to pass the current keyboard modifier (shift, alt, ctrl, etc)
to the terminal functions.

This however is wrong, since we may receive Wayland mouse events
without having keyboard focus. When we don't have keyboard focus, the
modifier state doesn't apply to us.

Remove the modifier arguments from the terminal mouse reporting
functions. These functions now read this state directly instead, but
only when the terminal instance in question has keyboard focus.
2019-11-30 17:11:00 +01:00
Daniel Eklöf
2208f4304b
term: add term_mouse_grabbed()
When this returns true, it means we have keyboard focus and are
grabbing the mouse (for e.g. selections), regardless of whether the
client has enabled mouse tracking or not.
2019-11-30 17:06:15 +01:00
Daniel Eklöf
5d2b2dc8a7
commands: scrollback: don't scrollback if mouse tracking is enabled 2019-11-30 16:57:52 +01:00
Daniel Eklöf
664041d04f
input: doh! mouse_scroll: first argument to keyboard_key() is a struct wayland
This is the problem with void* user data pointers in callbacks...
2019-11-30 16:54:41 +01:00
Daniel Eklöf
caee8db89a
commands: scrollback: don't scrollback if mouse tracking is enabled 2019-11-30 16:49:38 +01:00
Daniel Eklöf
6aa14ccdfc
input: mouse_scroll: cache XKB_KEY_Up and XKB_KEY_Down 2019-11-30 16:48:58 +01:00
Daniel Eklöf
62ed0ef4f2
term: "raw" mouse mode requires shift only to be pressed 2019-11-30 16:48:32 +01:00
Daniel Eklöf
90bfcc1fbd
render: fix underline/strikeout positioning
There were two errors:

* We subtracted half the line width instead of adding it to the
  baseline

* We rounded the line positioning and thickness before the positioning
  calculation. In particular, rounding the thickness before using it
  to adjust the position was wrong. Now we round just before the
  pixman call.
2019-11-30 14:53:22 +01:00
Daniel Eklöf
7be98291e1
render: font_baseline(): simply use the primary font's ascent
This is what we used as baseline for regular glyphs anyway. Thus, we
can update that code to call font_baseline() now. This makes it easier
to change how we define the baseline in the future.
2019-11-30 14:51:44 +01:00
Daniel Eklöf
719d521e33
font: bug: bad multiplier when converting from 16.16 fixed float 2019-11-30 13:10:20 +01:00
Daniel Eklöf
8f8ef5df0e
term: define xcursor strings as global variables 2019-11-30 12:43:06 +01:00
Daniel Eklöf
10f563dc6b
font: cache_size -> glyph_cache_size
This makes it more clear it has nothing to do with the font cache.
2019-11-30 12:41:09 +01:00
Daniel Eklöf
7a4d1b1a6e
font: destructor: pop elements as we go
Otherwise we'll end up free:ing the same font over and over again.
2019-11-30 12:39:18 +01:00
Daniel Eklöf
4e1a6b5739
font: original -> requested 2019-11-30 12:38:54 +01:00
Daniel Eklöf
62a239bcd1
font: log freetype errors 2019-11-30 12:35:07 +01:00
Daniel Eklöf
a87b39f6eb
wayland: track current xcursor, and don't update if same
We may have many windows open, which tries to update/change the
xcursor at various points.

Track which cursor is currently loaded, regardless of which window it
was set by. If someone tries to load that very same xcursor again,
simply skip it.

One example is when we've moused over a window that does *not* have
keyboard focus, and then the user clicks, or by some other mean gives
that window keyboard focus. In many cases it will then try to set the
same cursor again (most of the times, the cursor is the same
regardless of keyboard focus, but not always).
2019-11-30 12:09:57 +01:00
Daniel Eklöf
841e20b75b
input: update xcursor on terminal with *keyboard* focus when modifiers change 2019-11-30 12:02:45 +01:00
Daniel Eklöf
c8d94931e6
term: xcursor: use selection_enabled()
Instead of duplicating the code from selection_enabled() that deals
with forced selection, just call selection_enabled().

This was previously not possible since selection_enabled() didn't
require keyboard_focus. Now it does.
2019-11-30 12:01:40 +01:00
Daniel Eklöf
edb78575c7
selection: forced selection requires keyboard focus
Up the requirements for enabling "forced" selection (that is, allowing
selections even though mouse tracking has been disabled).

* Require keyboard focus (if we don't have it, then the shift-key
  isn't is for us)
* Don't just require shift being pressed, but that all other modifiers
  are *not* pressed.
2019-11-30 11:59:47 +01:00
Daniel Eklöf
0e5a69d869
vt: don't try to move cursor outside the terminal
When we insert an auto-newline, we must make sure we don't try to move
outside the terminal window.

This can for example happen when a scrolling region have been
configured, and the cursor is **outside** the scrolling
region (i.e. it's in the bottom margin).
2019-11-30 00:32:34 +01:00
Daniel Eklöf
a81c65caa2
term: reset: set 'origin' to ORIGIN_ABSOLUTE 2019-11-30 00:32:06 +01:00