aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeLines
...
| * doc: foot-ctlseq: mention that we support transparency in OSC 11Daniel Eklöf2021-04-18-1/+3
| |
| * changelog: don’t use a hyphen between ‘OSC’ and the numberDaniel Eklöf2021-04-18-1/+1
| |
| * changelog: tweak wording for URxvt’s XParseColor extensionDaniel Eklöf2021-04-18-1/+1
| |
| * osc: parse_legacy_color(): the alpha component is not a floating point numberDaniel Eklöf2021-04-18-8/+7
| | | | | | | | | | | | When using the urxvt extension of the XParseColor format, the alpha component is not a floating point number, but a decimal number in the range 0-100.
| * osc: parse_rgb(): ensure ‘alpha’ has been initializedDaniel Eklöf2021-04-18-1/+1
| |
| * osc: add support for URxvt extension to include alpha in OSC-11Daniel Eklöf2021-04-18-24/+105
| | | | | | | | | | | | | | There are two variants, either using a ‘[percent]’ prefix for legacy colors, or using ‘rgba:r/g/b/a’ instead of ‘rgb:r/g/b’. Closes #436
| * terminal: drain PTY when client terminatesDaniel Eklöf2021-04-18-4/+10
| | | | | | | | | | | | | | | | | | | | This is done by: * Not limiting the number of times we try to read from the PTY when we’ve have POLLHUP * Not requiring the entire the previous read to have filled our buffer. * Not erroring out on EIO.
| * ci: build on alpine/latest, not edgeDaniel Eklöf2021-04-18-8/+6
| |
| * sixel: unhook: tighten up the condition needed for us to free image data pre-maturelyDaniel Eklöf2021-04-18-5/+5
| |
| * sixel: sixel_fini(): free image dataDaniel Eklöf2021-04-18-0/+1
| | | | | | | | | | Normally, this data is always free:d indirectly, when the sixel image that took over ownership is destroyed. But let’s play it safe.
| * config/terminal: refactor: remove “default_*” color members from terminal structDaniel Eklöf2021-04-18-86/+61
| | | | | | | | Access the original colors in the configuration instead.
| * wayland: {xdg_,}output_*(): free old strings before assigning new onesDaniel Eklöf2021-04-18-0/+7
| | | | | | | | | | | | Defensive programming; output_geometry() etc are typically only called once for an output instance. But let’s ensure we’re not leaking memory if it’s called more than once.
| * changelog: move OSC-4/104 fix from 1.7.1 to ‘unreleased’Daniel Eklöf2021-04-18-3/+3
| |
| * osc: verify OSC 4/104 color index is validDaniel Eklöf2021-04-18-1/+14
| | | | | | | | Closes #434
| * config: make {search,url}_binding_action_map[] function localDaniel Eklöf2021-04-18-34/+34
| | | | | | | | | | | | | | | | | | This ensures we don’t accidentally reference them from places we shouldn’t. Unfortunately, binding_action_map[] (for “normal” key bindings) cannot easily be made function local since it is used when parsing both key- and mouse bindings (i.e. it’s used in multiple functions).
| * doc: foot.ini: fix default value for delete-next-wordDaniel Eklöf2021-04-18-1/+1
| |
| * config: parse_key_binding_section(): use provided action-mapDaniel Eklöf2021-04-18-1/+3
| | | | | | | | | | | | | | | | Don’t call has_key_binding_collisions() with ‘binding_action_map’ unconditionally; use the provided ‘action_map’ instead. This fixes wrong error messages for key combo collisions in key binding sections other than the regular “key-bindings”.
| * sixel: fix double free caused by bad free() in sixel_colors_set()Daniel Eklöf2021-04-18-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sixel_color_set() is called when the number of (sixel) color registers is changed. It frees the current palette, and changes the “palette size” variable. Originally, we only had a single palette. This is the one free:d by sixel_color_set(). Later, we added support for private vs. shared palettes. With this change, we now have one palette that is “never” free:d (the shared one), and a private palette that is always free:d after a sixel has been emitted. ‘sixel.palette’ is a pointer to the palette currently in use, and should only be accessed **while emitting a sixel**. This is the pointer sixel_color_set() free:d. So for example, if ‘sixel.palette’ pointed to the shared palette, we’d free the shared palette. But, we didn’t reset ‘sixel.shared_palette’, causing a double free later on. Closes #427
| * revert: input: do not include consumed modifiers in the set sent to the clientDaniel Eklöf2021-04-18-5/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were two issues with it: * Not all applications decode the sequence into a set of modifiers + key, but use a fixed sequence -> combo mapping, that we broke. * There were unforeseen issues with e.g. F1-12, where the modifier were removed from combos like Ctrl+F12, or Alt+F12. The reason is simple; XKB tells us that Ctrl, or Alt, is a consumed modifier. Now, _why_ it thinks that is a different story. This reverts 6cd72bdee6c2b11f7cab15df9afb0ed92a7f8ba0 Closes #425
| * term: free vt.osc8.uri when destroying a terminalDaniel Eklöf2021-04-18-0/+2
| | | | | | | | | | Free vt.osc8.uri in term_destroy(), in the off chance, that the client application emitted an un-terminated OSC-8 URI.
| * install: add ‘ninja test’ to all build typesDaniel Eklöf2021-04-18-0/+3
| | | | | | | | | | | | | | While we don’t (yet) have any unit tests for foot, users can build foot with e.g. fcft and/or tllist as sub-projects. *They* have tests, and when doing PGO builds, those test binaries *must* be executed, or we get link failures in the final build.
| * changelog: add new ‘unreleased’ sectionDaniel Eklöf2021-04-18-0/+11
| |
* | changelog: add cglogic to ‘contributors’Daniel Eklöf2021-04-18-0/+2
| |
* | Merge branch 'brighten-bold-uses-palette-colors'Daniel Eklöf2021-04-18-9/+47
|\ \ | | | | | | | | | Closes #449
| * | config: bold-text-in-bright: add ‘palette-based’ as a special valueDaniel Eklöf2021-04-17-12/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | When ‘bold-text-in-bright’ is set ‘to palette-based’, colors matching one of the 8 regular palette colors are brightened by using the corresponding bright palette color. Other colors, or all colors if ‘bold-text-in-bright’ is set to ‘yes|true’, are brightened by increasing the luminance.
| * | render: brighten: use corresponding bright palette color for base 8 colorsDaniel Eklöf2021-04-17-2/+14
| | | | | | | | | | | | | | | | | | | | | | | | When brightening one of the 8 base (“regular”) colors, use the corresponding bright palette color, instead of increasing the luminance. Closes #449
* | | Merge branch 'terminal-stop-reading-on-eof'Daniel Eklöf2021-04-18-0/+3
|\ \ \
| * | | Fix commentOleh Hushchenkov2021-04-18-3/+1
| | | |
| * | | term: stop reading on eofOleh Hushchenkov2021-04-18-0/+5
|/ / /
* / / term: attributes struct: use ‘bool’ instead of ‘uint32_t’ for 1-bit membersDaniel Eklöf2021-04-17-13/+13
|/ /
* | main: explicitly cast log_colorize to enum fcft_log_colorizeDaniel Eklöf2021-04-17-2/+4
| | | | | | | | | | | | | | | | Fixes error in Clang builds: ../../foot/main.c:376:19: error: implicit conversion from enumeration type 'enum log_colorize' to different enumeration type 'enum fcft_log_colorize' [-Werror,-Wenum-conversion] fcft_log_init(log_colorize, as_server && log_syslog, log_level + 1); ~~~~~~~~~~~~~ ^~~~~~~~~~~~
* | main: call fcft_log_init(). Note that this requires fcft >= 2.3.90Daniel Eklöf2021-04-17-1/+5
| |
* | Merge branch 'sixel-dont-blend-opaque-images'Daniel Eklöf2021-04-14-1/+1
|\ \
| * | render: no need to blend fully opaque sixel images - just blit themDaniel Eklöf2021-04-14-1/+1
|/ /
* | Merge branch 'dont-let-jump-labels-extend-outside-window-geometry'Daniel Eklöf2021-04-10-27/+60
|\ \ | | | | | | | | | Closes #443
| * | render: don’t let URL jump label sub-surfaces extend outside window geometryDaniel Eklöf2021-04-10-27/+60
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have no guarantee that sub-surfaces extending outside the window geometry are rendered correctly (if at all). For example, both Sway and River will render the window border on top of the sub-surface. Future versions of Sway may clip the sub-surface. Since jump-labels are positioned slightly above, and to the left of the URLs first character, having a label on either the top row, or on the first column, will likely position it outside the window. This is handled by simply setting x/y to 0 (or, to -margin, since the label coordinate is later offsetted with the window margins). Second, if the label is very long, it may extend outside the window. This is very unusual for labels only showing the key, and not the URL itself, but could happen in this case too, if e.g. the user has configured double-width key characters. This is handled by calculating its maximum width, and then truncating the label. Although very unlikely, it is possible for a label to also extend outside the window’s vertical size. This could happen for very small font sizes, where the label’s own margins are large, relative to the font size. This case is currently not handled. Closes #443
* | doc: foot.ini: re-phrase the box-drawings-uses-font-glyphs sectionDaniel Eklöf2021-04-10-2/+3
| |
* | Merge branch 'optionally-render-box-drawing-characters-using-font-glyphs'Daniel Eklöf2021-04-10-1/+30
|\ \ | | | | | | | | | Closes #430
| * | doc: foot.ini: codespell: antaliasing -> antialiasingDaniel Eklöf2021-04-09-1/+1
| | |
| * | config: add box-drawings-uses-font-glyphs=no|yes optionDaniel Eklöf2021-04-09-1/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | When disabled, we render box drawing characters ourselves. This is the default. When enabled, we instead use font glyphs. I.e. no special treatment. Closes #430
* | | Merge branch 'underline-cursor-below-text-underline'Daniel Eklöf2021-04-10-2/+8
|\ \ \ | |/ / |/| | | | | Closes #415
| * | render: draw underline cursor below text underlineDaniel Eklöf2021-04-09-2/+8
|/ / | | | | | | | | | | | | This ensures the cursor is visible on cells where the text is underlined. Closes #415
* | changelog: rewrite entry for OSC 17/117/19/119Daniel Eklöf2021-04-08-2/+2
| |
* | Merge branch 'auto-left-margin-on-cub1-only'Daniel Eklöf2021-04-08-40/+20
|\ \ | | | | | | | | | Closes #441
| * | changelog: auto_left_margin on cub1 onlyDaniel Eklöf2021-04-08-0/+2
| | |
| * | term/vt: only do reverse-wrapping (‘bw’) on cub1Daniel Eklöf2021-04-08-40/+18
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | Foot currently does reverse-wrapping (‘auto_left_margin’, or ’bw’) on everything that calls ‘term_cursor_left()’. This is wrong; it should only be done for cub1. From man terminfo: auto_left_margin | bw | bw | cub1 wraps from column 0 to last column This patch moves the reverse-wrapping logic from term_cursor_left() to the handling of BS (backspace). Closes #441
* | Merge branch 'osc-17-19'Daniel Eklöf2021-04-08-13/+67
|\ \
| * | osc: implement OSC 17+19: change selection background/foreground colorsDaniel Eklöf2021-04-08-13/+67
|/ / | | | | | | | | And of course, we also implement the corresponding reset sequences, OSC 117+119.
* | Merge branch 'osc-11-alpha'Daniel Eklöf2021-04-08-26/+110
|\ \ | | | | | | | | | Closes #436
| * | osc: reset background alpha when resetting the background colorDaniel Eklöf2021-04-08-0/+2
| | |
| * | doc: foot-ctlseq: mention that we support transparency in OSC 11Daniel Eklöf2021-04-08-1/+3
| | |
| * | changelog: don’t use a hyphen between ‘OSC’ and the numberDaniel Eklöf2021-04-08-1/+1
| | |
| * | changelog: tweak wording for URxvt’s XParseColor extensionDaniel Eklöf2021-04-08-1/+1
| | |
| * | osc: parse_legacy_color(): the alpha component is not a floating point numberDaniel Eklöf2021-04-08-8/+7
| | | | | | | | | | | | | | | | | | When using the urxvt extension of the XParseColor format, the alpha component is not a floating point number, but a decimal number in the range 0-100.
| * | osc: parse_rgb(): ensure ‘alpha’ has been initializedDaniel Eklöf2021-04-08-1/+1
| | |
| * | osc: add support for URxvt extension to include alpha in OSC-11Daniel Eklöf2021-04-08-24/+105
|/ / | | | | | | | | | | | | There are two variants, either using a ‘[percent]’ prefix for legacy colors, or using ‘rgba:r/g/b/a’ instead of ‘rgb:r/g/b’. Closes #436
* | Merge branch 'drain-pty-when-client-terminates'Daniel Eklöf2021-04-08-4/+10
|\ \
| * | terminal: drain PTY when client terminatesDaniel Eklöf2021-04-07-4/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is done by: * Not limiting the number of times we try to read from the PTY when we’ve have POLLHUP * Not requiring the entire the previous read to have filled our buffer. * Not erroring out on EIO.
* | | ci: build on alpine/latest, not edgeDaniel Eklöf2021-04-07-8/+6
|/ /
* | sixel: unhook: tighten up the condition needed for us to free image data pre-maturelyDaniel Eklöf2021-04-07-5/+5
| |
* | sixel: sixel_fini(): free image dataDaniel Eklöf2021-04-07-0/+1
| | | | | | | | | | Normally, this data is always free:d indirectly, when the sixel image that took over ownership is destroyed. But let’s play it safe.
* | Merge pull request 'Don't copy default colors from config to each terminal instance' (#438) from ↵dnkl2021-04-07-86/+61
|\ \ | | | | | | | | | | | | | | | refactor-colors into master Reviewed-on: https://codeberg.org/dnkl/foot/pulls/438
| * | config/terminal: refactor: remove “default_*” color members from terminal structDaniel Eklöf2021-04-07-86/+61
|/ / | | | | | | Access the original colors in the configuration instead.
* | wayland: {xdg_,}output_*(): free old strings before assigning new onesDaniel Eklöf2021-04-07-0/+7
| | | | | | | | | | | | Defensive programming; output_geometry() etc are typically only called once for an output instance. But let’s ensure we’re not leaking memory if it’s called more than once.
* | changelog: move OSC-4/104 fix from 1.7.1 to ‘unreleased’Daniel Eklöf2021-04-05-3/+3
| |
* | Merge branch 'osc-4-check-index-is-within-bounds'Daniel Eklöf2021-04-05-1/+14
|\ \ | | | | | | | | | Closes #434
| * | osc: verify OSC 4/104 color index is validDaniel Eklöf2021-04-05-1/+14
|/ / | | | | | | Closes #434
* | Merge branch 'fix-error-message-for-key-binding-collisions'Daniel Eklöf2021-04-05-36/+38
|\ \ | | | | | | | | | Closes #432
| * | config: make {search,url}_binding_action_map[] function localDaniel Eklöf2021-04-05-34/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | This ensures we don’t accidentally reference them from places we shouldn’t. Unfortunately, binding_action_map[] (for “normal” key bindings) cannot easily be made function local since it is used when parsing both key- and mouse bindings (i.e. it’s used in multiple functions).
| * | doc: foot.ini: fix default value for delete-next-wordDaniel Eklöf2021-04-05-1/+1
| | |
| * | config: parse_key_binding_section(): use provided action-mapDaniel Eklöf2021-04-05-1/+3
|/ / | | | | | | | | | | | | | | Don’t call has_key_binding_collisions() with ‘binding_action_map’ unconditionally; use the provided ‘action_map’ instead. This fixes wrong error messages for key combo collisions in key binding sections other than the regular “key-bindings”.
* | Merge branch 'sixel-fix-double-free-in-set-palette-size'Daniel Eklöf2021-03-30-2/+7
|\ \ | | | | | | | | | Closes #427
| * | sixel: fix double free caused by bad free() in sixel_colors_set()Daniel Eklöf2021-03-30-2/+7
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | sixel_color_set() is called when the number of (sixel) color registers is changed. It frees the current palette, and changes the “palette size” variable. Originally, we only had a single palette. This is the one free:d by sixel_color_set(). Later, we added support for private vs. shared palettes. With this change, we now have one palette that is “never” free:d (the shared one), and a private palette that is always free:d after a sixel has been emitted. ‘sixel.palette’ is a pointer to the palette currently in use, and should only be accessed **while emitting a sixel**. This is the pointer sixel_color_set() free:d. So for example, if ‘sixel.palette’ pointed to the shared palette, we’d free the shared palette. But, we didn’t reset ‘sixel.shared_palette’, causing a double free later on. Closes #427
* | Merge branch 'revert-remove-consumed-modifiers-from-set-sent-to-client'Daniel Eklöf2021-03-30-5/+10
|\ \ | | | | | | | | | Closes #425
| * | revert: input: do not include consumed modifiers in the set sent to the clientDaniel Eklöf2021-03-29-5/+10
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were two issues with it: * Not all applications decode the sequence into a set of modifiers + key, but use a fixed sequence -> combo mapping, that we broke. * There were unforeseen issues with e.g. F1-12, where the modifier were removed from combos like Ctrl+F12, or Alt+F12. The reason is simple; XKB tells us that Ctrl, or Alt, is a consumed modifier. Now, _why_ it thinks that is a different story. This reverts 6cd72bdee6c2b11f7cab15df9afb0ed92a7f8ba0 Closes #425
* | term: free vt.osc8.uri when destroying a terminalDaniel Eklöf2021-03-28-0/+2
| | | | | | | | | | Free vt.osc8.uri in term_destroy(), in the off chance, that the client application emitted an un-terminated OSC-8 URI.
* | install: add ‘ninja test’ to all build typesDaniel Eklöf2021-03-28-0/+3
| | | | | | | | | | | | | | While we don’t (yet) have any unit tests for foot, users can build foot with e.g. fcft and/or tllist as sub-projects. *They* have tests, and when doing PGO builds, those test binaries *must* be executed, or we get link failures in the final build.
* | changelog: add new ‘unreleased’ sectionDaniel Eklöf2021-03-28-0/+11
| |
* | Merge branch 'releases/1.7'Daniel Eklöf2021-03-28-11/+5
|\|
| * meson/pkgbuild: bump version to 1.7.11.7.1Daniel Eklöf2021-03-28-2/+2
| |
| * changelog: prepare for 1.7.1Daniel Eklöf2021-03-28-9/+3
| |
| * Merge branch 'master' into releases/1.7Daniel Eklöf2021-03-28-262/+463
| |\ | |/ |/|
* | Merge branch 'search-treat-empty-cells-as-spaces'Daniel Eklöf2021-03-28-0/+4
|\ \
| * | changelog: spaces matches empty cells in scrollback search modeDaniel Eklöf2021-03-28-0/+1
| | |
| * | search: when matching cell content, treat empty cells as spacesDaniel Eklöf2021-03-28-0/+3
| | |
* | | Merge branch 'sixel-trimming'Daniel Eklöf2021-03-28-3/+13
|\ \ \ | |/ / |/| |
| * | changelog: empty sixels resulted in non-empty imagesDaniel Eklöf2021-03-28-0/+1
| | |
| * | sixel: free backing buffer if final image size is zeroDaniel Eklöf2021-03-28-0/+5
| | |
| * | sixel: initialize max_non_empty_row_no to -1, not 0Daniel Eklöf2021-03-28-3/+7
|/ / | | | | | | | | | | | | | | | | | | | | | | | | 0 is a perfectly valid row number, and if max_non_empty_row_no==0, that means we have *1* sixel row, and after trimming the image, the image will have a height of 6 pixels. If the sixel sequence is empty (or at least doesn’t emit any non-empty pixels), then trimming the image should result in an image height of 0. When max_non_empty_row_no is initialized to -1, it will still have that value in unhook(), which makes the final image height 0.
* | Merge branch 'pgo-clang-11'Daniel Eklöf2021-03-28-54/+118
|\ \ | | | | | | | | | Closes #418
| * | meson: replace log+debug+xmalloc static libraries with a single ‘common’ libraryDaniel Eklöf2021-03-27-7/+9
| | | | | | | | | | | | | | | | | | | | | There are cyclic dependencies between the log, debug and xmalloc libraries. While having them as separate static libraries work, as long as consumers of them link against all of them, having them in a single library feels slightly better.
| * | changelog: updated PGO build instructionsDaniel Eklöf2021-03-26-0/+5
| | |
| * | install: clang-11.x compatible PGO instructionsDaniel Eklöf2021-03-26-11/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | LLVM/Clang 11.x throws errors for _files_ without any profiling data: error: ../../async.c: Function control flow change detected (hash mismatch) async_write Hash = 72057641800614222 [-Werror,-Wbackend-plugin] This caused multiple issues with the current PGO instructions: * The `pgo` binary failed to link with `meson configure -Db_pgo=use` when doing a full PGO build (since it isn't used in this case); * `footclient` fails to link for the same reason. * `foot` fails to link for the same reason in **partial** PGO builds. The solution is to make sure all binaries that are built in the final phase (`-Db_pgo=use`) have been executed in the _generate_ phase. Doing this also means we can drop `-Wno-missing-profile` and friends. Also add `--sixel` to the `generate-alt-random-writes` command line in the description for a full PGO build. Closes #418
| * | install: add ‘llvm’ as an optional build dependencyDaniel Eklöf2021-03-26-0/+1
| | | | | | | | | | | | It is needed for PGO builds with Clang.
| * | PKGBUILD: do PGO with either gcc or clang, but nothing elseDaniel Eklöf2021-03-26-22/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before this, we assumed gcc was being used. The build would fail if clang (or something else) was used. Now, we check whether we’re compiling with gcc or clang, and disable PGO if it’s neither of them. Furthermore, we’re now adding the necessary flags needed to do PGO with clang. Note that ‘llvm-profdata’, from the ‘llvm’ package is needed for PGO:ing with clang. PGO is disabled if it isn’t available. It would be nice to have ‘llvm’ as an optional make dependency, but PKGBUILDs doesn’t appear to support such a thing. Finally, the -Wno-missing-profile flag, and its friends, have been removed; instead we execute “footclient --version” (and “foot --version”, in partial PGO builds) to ensure all generated binaries have been executed before we do the final build (with -Db_pgo=use). This fixes build failures with clang >= 11.x.
| * | meson: only build the pgo helper binary when -Db_pgo=generateDaniel Eklöf2021-03-26-7/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the only time it’s needed. In non-PGO builds, it is completely unnecessary, and we’re only wasting CPU cycles building it. In full PGO builds, with -Db_pgo=use, we get link warnings and/or failures, depending on compiler, since the pgo binary hasn’t been executed.
| * | meson: build source files common to both foot and footclient as librariesDaniel Eklöf2021-03-26-10/+9
| | | | | | | | | | | | | | | Source files used by both foot and footclient are now compiled as static libraries, which foot and footclient links against.
| * | features: --version now logs +/-pgoDaniel Eklöf2021-03-26-4/+20
| | | | | | | | | | | | That is, whether the binary was compiled with PGO or not.
* | | readme: dpi & fonts: focus on *current* behaviorDaniel Eklöf2021-03-27-13/+14
|/ / | | | | | | | | | | | | | | | | The text was describing the original behavior, where output scaling was completely ignored, and tacked on a “btw, starting with foot-1.6...”. Now, simply describe the current behavior, and be more clear about _how_ dpi-aware can be changed.
* | Merge branch 'buffer-size-multiple-of-scale-factor'Daniel Eklöf2021-03-25-19/+53
|\ \ | | | | | | | | | Closes #409