| Commit message (Collapse) | Author | Age | Lines | |
|---|---|---|---|---|
| * | font: initial support for double-width *and* color emoji glyphs | Daniel Eklöf | 2019-07-31 | -4/+4 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fonts are now loaded with FT_LOAD_COLOR and we recognize and support the FT_PIXEL_MODE_BGRA pixel mode. This is mapped to a CAIRO_FORMAT_ARGB32 surface, that is blitted as-is (instead of used as a mask like we do for gray and mono glyphs). Furthermore, since many emojis are double-width, we add initial support for double-width glyphs. These are assumed to always be utf8. When PRINT:ing an utf8 character, we check its width, and add empty "spacer" cells after the cell with the multi-column glyph. When rendering, we render the columns in each row backwards. This ensures the spacer cells get cleared *before* we render the glyph (so that we don't end up erasing part of the glyph). Finally, emoji fonts are usually bitmap fonts with *large* glyphs. These aren't automatically scaled down. I.e. even if we request a glyph of 13 pixels, we might end up getting a 100px glyph. To handle this, fontconfig must be configured to scale bitmap fonts. When it is, we can look at the 'scalable' and 'pixelsizefixup' properties, and use these to scale the rendered glyph. | |||
| * | main: don't shadow final return value inside poll loop | Daniel Eklöf | 2019-07-30 | -3/+3 |
| | | ||||
| * | main: font metrics should be debug logged | Daniel Eklöf | 2019-07-30 | -3/+1 |
| | | ||||
| * | main: pty buffers appear to be ~20KB on modern linux kernels | Daniel Eklöf | 2019-07-30 | -1/+1 |
| | | ||||
| * | font: add support for fallback fonts | Daniel Eklöf | 2019-07-30 | -13/+13 |
| | | | | | | | | | | | | | | | | A top-level font now has a list of fallback fonts. When a glyph cannot be found, we try each fallback font in turn, until we either find one that has the glyph, or until we've exhausted the list. To make this actually work in practise (read: to make performance acceptable), the cache is re-worked and is now populated on demand. It also supports non-ASCII characters, by using the 4-byte unicode character as index instead. Since having an array that can be indexed by a 4-byte value isn't really viable, we now have a simple hash table instead of an array. | |||
| * | render: add a 'clean' bit to each cell; only render cells that aren't clean | Daniel Eklöf | 2019-07-30 | -2/+4 |
| | | | | | | | | | | | | This patch takes a bit from the foreground color value in a cell (todo: split up foreground/background into bitfields with a separate field for 'foreground/background' has been set), and only re-renders cells that aren't marked as clean. Note: we use a 'clean' bit rather than a 'dirty' bit to make it easy to erase cells - we can (keep doing) do that by simply memsetting a cell range to 0. | |||
| * | wip: initial multithreaded renderer | Daniel Eklöf | 2019-07-29 | -1/+43 |
| | | ||||
| * | font: populate glyph cache (ASCII characters only) when instantiating font | Daniel Eklöf | 2019-07-28 | -6/+3 |
| | | ||||
| * | cairo-ft: remove all usages of cairo-ft | Daniel Eklöf | 2019-07-28 | -34/+0 |
| | | ||||
| * | main: calculate *all* font metrics from the FreeType face | Daniel Eklöf | 2019-07-28 | -8/+17 |
| | | ||||
| * | font: load FreeType face, and set it's pixel sizes | Daniel Eklöf | 2019-07-28 | -5/+7 |
| | | ||||
| * | mouse: use discrete axis event if available | Daniel Eklöf | 2019-07-26 | -1/+1 |
| | | | | | This improves the scroll experience with certain devices | |||
| * | render: move frame_callback to term.render | Daniel Eklöf | 2019-07-24 | -2/+2 |
| | | ||||
| * | render: add render_refresh() | Daniel Eklöf | 2019-07-24 | -6/+3 |
| | | ||||
| * | conf: allow the user to configure a fixed cursor color | Daniel Eklöf | 2019-07-23 | -0/+8 |
| | | | | | | | | | | | | | | | | | | | | The default is to reverse the foreground/background colors in the cell with the cursor. But, if the user configures a specific set of cursor colors, those will always be used, regardless of other cell attributes (dim, reverse etc). The cursor color is specified as two color values, 'text' and 'cursor'. The block cursor uses the 'cursor' color as background, and the 'text' color for the glyph. All other cursor styles uses the 'cursor' color for the cursor, but uses the cell's foreground color for the glyph (meaning, dim/reverse/etc applies). | |||
| * | csi: let CSI 0 q mean "switch to user configured cursor style" | Daniel Eklöf | 2019-07-22 | -0/+1 |
| | | | | | | | | | According to the specs, \E[0 q means a blinking block cursor. However, since it also states that \E[1 q *also* is a blinking block cursor, and that it is the default, *and* given that fact that parameter-less CSIs typically means "reset", let's make it mean "reset to the user configured cursor style". | |||
| * | conf: make cursor's default style configurable | Daniel Eklöf | 2019-07-22 | -0/+1 |
| | | ||||
| * | term: group 'blink' state together in a struct | Daniel Eklöf | 2019-07-22 | -6/+8 |
| | | ||||
| * | term: group 'flash' state together in a struct | Daniel Eklöf | 2019-07-22 | -6/+8 |
| | | ||||
| * | main: no need to damage the _entire_ view on blink timer | Daniel Eklöf | 2019-07-21 | -1/+11 |
| | | ||||
| * | blink: implement 'blink' | Daniel Eklöf | 2019-07-21 | -0/+24 |
| | | ||||
| * | flash: implement 'flash' | Daniel Eklöf | 2019-07-21 | -0/+24 |
| | | | | | | | | | | | Use our own escape sequence for the 'flash' terminfo entry. Implemented by arming a timer FD and setting a boolean that indicates we're currently "flashing". The renderer draws a semi-transparent yellowish layer over the entire window when "flashing" is active. | |||
| * | dcs: we have no parent terminal to pass through to | Daniel Eklöf | 2019-07-21 | -1/+0 |
| | | ||||
| * | csi: implement CSI 22t and CSI 23t | Daniel Eklöf | 2019-07-21 | -0/+3 |
| | | | | | | | | | | | | 22;0|1|2t pushes the current window title/icon to the stack, while 23 pops it. The second parameter, 0|1|2 has the following meaning: 0 - push/pop icon+title 1 - push/pop icon 2 - push/pop title | |||
| * | term: track current window title in terminal struct | Daniel Eklöf | 2019-07-21 | -1/+2 |
| | | ||||
| * | conf: config now provides the colors (though still only hardcoded colors) | Daniel Eklöf | 2019-07-21 | -12/+34 |
| | | ||||
| * | term: prepare for configurable colors; add color variables to terminal | Daniel Eklöf | 2019-07-21 | -2/+2 |
| | | ||||
| * | dcs: sort of implement DCS passthrough | Daniel Eklöf | 2019-07-19 | -0/+1 |
| | | | | | | | | We now store the passthrough characters in a buffer, and call dcs_passthrough() on unhook. However, dcs_passthrough() doesn't do anything. | |||
| * | osc: allocate data buffer dynamically | Daniel Eklöf | 2019-07-19 | -0/+1 |
| | | ||||
| * | main: allow TERM to be set on the command line | Daniel Eklöf | 2019-07-18 | -1/+7 |
| | | ||||
| * | conf: TERM can now be set in footrc | Daniel Eklöf | 2019-07-18 | -1/+1 |
| | | ||||
| * | main: use our own terminfo 'foot' by default | Daniel Eklöf | 2019-07-18 | -1/+1 |
| | | ||||
| * | glyph-cache: generate at startup, never update while rendering | Daniel Eklöf | 2019-07-18 | -7/+37 |
| | | ||||
| * | render: cache generated glyphs for regular ASCII characters | Daniel Eklöf | 2019-07-18 | -0/+2 |
| | | | | | | | | | To avoid having to re-generate glyphs, cache the glyphs. For now, we only cache ASCII characters, as this allows us to lookup the cache by simply indexing with the character (into a 256-entry array). | |||
| * | conf: improve configuration file parsing | Daniel Eklöf | 2019-07-17 | -1/+3 |
| | | | | | | | | * Strip whitespaces from keys and values * Detect (and ignore) comments * Detect syntax errors (no value specified etc) * Error out on syntax errors and invalid keys | |||
| * | main: allow user to override shell on the command line | Daniel Eklöf | 2019-07-17 | -2/+19 |
| | | ||||
| * | slave: report exec() failure back to main process | Daniel Eklöf | 2019-07-17 | -13/+41 |
| | | ||||
| * | main: jump to cleanup on failure to load cursor pointer theme | Daniel Eklöf | 2019-07-17 | -1/+1 |
| | | ||||
| * | slave: exec shell from conf | Daniel Eklöf | 2019-07-17 | -1/+1 |
| | | ||||
| * | main: fallback for strikeout positioning seems to work | Daniel Eklöf | 2019-07-16 | -2/+0 |
| | | ||||
| * | render: implement strikeout | Daniel Eklöf | 2019-07-16 | -1/+24 |
| | | ||||
| * | render: implement 'underline' | Daniel Eklöf | 2019-07-16 | -8/+34 |
| | | ||||
| * | terminal: foreground/background in cell attributes are now uint32_t | Daniel Eklöf | 2019-07-16 | -0/+5 |
| | | | | | This reduces the cell size, and thus improves the cache behavour | |||
| * | conf: initial support for configuration file | Daniel Eklöf | 2019-07-16 | -7/+13 |
| | | | | | | | | * Look for configuration file in (in this order): - XDG_CONFIG_HOME/footrc - ~/.config/footrc * Currently supports setting the font | |||
| * | main: default font is 'monospace' | Daniel Eklöf | 2019-07-16 | -1/+1 |
| | | ||||
| * | main: set TERM=xterm-direct | Daniel Eklöf | 2019-07-15 | -0/+1 |
| | | ||||
| * | rename project to 'foot' | Daniel Eklöf | 2019-07-11 | -2/+2 |
| | | ||||
| * | selection: add support for pasting *from* primary | Daniel Eklöf | 2019-07-11 | -5/+24 |
| | | ||||
| * | selection: initial copy-to-clipboard functionality | Daniel Eklöf | 2019-07-11 | -0/+34 |
| | | ||||
| * | selection: selections can be made, and are rendered | Daniel Eklöf | 2019-07-11 | -0/+4 |
| | | | | | | | | * Start selection on mouse button down * Update selection on motion * Button release cancels selection if there were no motion after start * Renderer detects cells inside the selection and inverts their colors | |||
| * | grid: don't pre-allocate the entire grid (with all scrollback lines) | Daniel Eklöf | 2019-07-10 | -8/+4 |
| | | | | | | | | | | | The row array may now contain NULL pointers. This means the corresponding row hasn't yet been allocated and initialized. On a resize, we explicitly allocate the visible rows. Uninitialized rows are then allocated the first time they are referenced. | |||
| * | main: hopefully fix logical error in delayed rendering | Daniel Eklöf | 2019-07-10 | -1/+1 |
| | | | | | | We want the timeout_ms to *not* be -1 (i.e. someone has requested delayed rendering), while we're *not* getting client output. | |||
| * | terminal: rename and redefine cursor keys mode and keypad keys mode | Daniel Eklöf | 2019-07-09 | -2/+2 |
| | | ||||
| * | input: add support for dead keys (composing) | Daniel Eklöf | 2019-07-09 | -0/+5 |
| | | ||||
| * | render: store frame callback pointer in terminal struct | Daniel Eklöf | 2019-07-09 | -1/+3 |
| | | | | | This allows us to free it when exiting | |||
| * | cleanup | Daniel Eklöf | 2019-07-09 | -2/+0 |
| | | ||||
| * | main: verify compositor has WL_SHM_FORMAT_ARGB8888 | Daniel Eklöf | 2019-07-08 | -1/+8 |
| | | ||||
| * | rgba: drop alpha channel support | Daniel Eklöf | 2019-07-08 | -2/+2 |
| | | ||||
| * | wip: grid is now represented as a grid, not a linear array | Daniel Eklöf | 2019-07-08 | -2/+20 |
| | | | | | | | | | | | | | The grid is now represented with an array of row *pointers*. Each row contains an array of cells (the row's columns). The main point of having row pointers is we can now move rows around almost for free. This is useful when scrolling with scroll margins for example, where we previously had to copy the lines in the margins. Now it's just a matter of swapping two pointers. | |||
| * | input: mouse events | Daniel Eklöf | 2019-07-05 | -6/+17 |
| | | ||||
| * | render: load cursor theme from XCURSOR_THEME and XCURSOR_SIZE | Daniel Eklöf | 2019-07-05 | -0/+41 |
| | | ||||
| * | render: break out rendering functions to render.{c,h} | Daniel Eklöf | 2019-07-05 | -729/+133 |
| | | ||||
| * | osc: implement change window title and icon | Daniel Eklöf | 2019-07-05 | -1/+9 |
| | | ||||
| * | render: bump number of glyphs we can render in a single call | Daniel Eklöf | 2019-07-05 | -1/+1 |
| | | ||||
| * | main: it's not the terminal emulators job to set LINES and COLUMNS | Daniel Eklöf | 2019-07-05 | -7/+0 |
| | | ||||
| * | main: initialize colors in VT state | Daniel Eklöf | 2019-07-05 | -0/+4 |
| | | ||||
| * | render: force a full redraw when we cannot reuse last buffer | Daniel Eklöf | 2019-07-05 | -1/+5 |
| | | ||||
| * | resize: cursor reset was off-by-one when cursor was outside new size | Daniel Eklöf | 2019-07-04 | -2/+2 |
| | | ||||
| * | resize: re-align grid offset | Daniel Eklöf | 2019-07-04 | -0/+7 |
| | | ||||
| * | main: handle EINTR in poll() | Daniel Eklöf | 2019-07-04 | -0/+3 |
| | | ||||
| * | flash mitigation: add a small delay before rendering after receiving client data | Daniel Eklöf | 2019-07-04 | -13/+52 |
| | | | | | | | Simply re-trying to read client data is not enough in many cases. Re-work the flash mitigation to instead incur a small delay before rendering. | |||
| * | main: more zenburn:ish default foreground and background colors | Daniel Eklöf | 2019-07-04 | -2/+2 |
| | | ||||
| * | vt: implement (untested!) smam and rmam (auto margins) | Daniel Eklöf | 2019-07-03 | -0/+1 |
| | | | | | | Default is auto-margins enabled (scroll when cursor reaches right margin). | |||
| * | logging: disable debug logging by default | Daniel Eklöf | 2019-07-03 | -1/+1 |
| | | ||||
| * | main: mitigate screen flashes on slow client | Daniel Eklöf | 2019-07-03 | -8/+25 |
| | | | | | | | | | | | | | | | If a client writes to the PTY "too slow", we often end up flashing the screen. This could for example be caused by a client first erasing a line, then we render that frame, followed by the client updating the just-erased line. When we render _that_ frame, it will be perceived as a flash. Mitigate this by trying to read client data again, after finishing processing one batch, but before rendering. To avoid hanging on client output (and never rendering anything), limit this to at most 3 iterations. This may have to be tweaked. | |||
| * | csi: implement 'civis' (show/hide cursor) | Daniel Eklöf | 2019-07-03 | -1/+2 |
| | | ||||
| * | scrolling: initial reverse scrolling support - no scroll regions | Daniel Eklöf | 2019-07-03 | -4/+15 |
| | | ||||
| * | render: fix last-cursor comparison | Daniel Eklöf | 2019-07-03 | -1/+1 |
| | | ||||
| * | main: add --font/-f command line option | Daniel Eklöf | 2019-07-03 | -3/+32 |
| | | ||||
| * | main: make sure cursor is inside the new row/col limits on resize | Daniel Eklöf | 2019-07-02 | -0/+5 |
| | | ||||
| * | render: track last cursor position in absolute values | Daniel Eklöf | 2019-07-02 | -7/+6 |
| | | | | | | This seems to fix an issue where we sometimes saw "ghost" cursors when scrolling. | |||
| * | render: revert glyph caching | Daniel Eklöf | 2019-07-02 | -101/+72 |
| | | | | | | Instead, try to group as long sequences of glyphs as possible, as fewer calls to cairo_show_glyphs() is *much* faster. | |||
| * | render: fix cursor not always being rendered | Daniel Eklöf | 2019-07-02 | -8/+13 |
| | | | | | | In case the only difference between this and the last frame was cursor movement, the cursor was not rendered. | |||
| * | render: draw pre-rendered glyph OVER background | Daniel Eklöf | 2019-07-02 | -0/+1 |
| | | | | | | This allows us to render the background dynamically. Note that pre-rendered glyphs still have wrong foreground color. | |||
| * | render: cache glyph masks | Daniel Eklöf | 2019-07-02 | -38/+102 |
| | | | | | | | | | | Cache rendered glyph masks for each font combo. When rendering text, use these when possible (standard ASCII). For now, use the cached glyph as a mask. This allows colors to just work. It would be faster to cache a completely pre-rendered image, but then we would need one image for each background/foreground combo. | |||
| * | main: log resize event as INFO | Daniel Eklöf | 2019-07-01 | -2/+2 |
| | | ||||
| * | render: always render cursor | Daniel Eklöf | 2019-07-01 | -17/+27 |
| | | ||||
| * | render: use actual grid size when re-allocating grid buffer | Daniel Eklöf | 2019-07-01 | -2/+2 |
| | | ||||
| * | render: re-enable drawing cursor on erase | Daniel Eklöf | 2019-07-01 | -5/+4 |
| | | ||||
| * | wip: use a sliding window instead of memmove() to scroll | Daniel Eklöf | 2019-07-01 | -19/+47 |
| | | | | | | Instead of memmoving a large amount of data on every scroll, use a sliding window. That is, each time we scroll, we offset origin. | |||
| * | terminal: prepare for floating grids | Daniel Eklöf | 2019-06-29 | -28/+30 |
| | | ||||
| * | terminal: move cursor from grid to terminal | Daniel Eklöf | 2019-06-29 | -4/+4 |
| | | ||||
| * | terminal: move fore/background colors from grid to terminal | Daniel Eklöf | 2019-06-29 | -5/+5 |
| | | ||||
| * | terminal: move col/row count, cell width/height and scroll region to terminal | Daniel Eklöf | 2019-06-29 | -42/+42 |
| | | ||||
| * | Rename grid_* functions to term_* | Daniel Eklöf | 2019-06-29 | -1/+1 |
| | | ||||
| * | render: don't try to render glyph for empty cell(s) | Daniel Eklöf | 2019-06-29 | -0/+3 |
| | | ||||
| * | main: increase ptmx slave buffer size | Daniel Eklöf | 2019-06-29 | -1/+1 |
| | | ||||
| * | render: alignment | Daniel Eklöf | 2019-06-29 | -2/+2 |
| | | ||||
| * | render: also check scroll damage list | Daniel Eklöf | 2019-06-29 | -1/+4 |
| | | ||||
| * | colors: store as doubles, rather than uint32_t | Daniel Eklöf | 2019-06-26 | -22/+13 |
| | | | | | | Since cairo uses doubles, we don't want to have to convert a uin32_t to double values every time we render a cell. | |||
