aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeLines
...
* osc: fix scaling of RGB formatted color specifiersDaniel Eklöf2020-05-02-4/+4
|
* osc: OSC 12: mimic xterm - a color value of 0 means use inverted fg/bgDaniel Eklöf2020-05-02-1/+6
|
* osc: fix 'OSC 12 ?' to return the cursor color, not the cursor text colorDaniel Eklöf2020-05-02-3/+5
|
* osc: fix scaling of legacy formatted color specifiersDaniel Eklöf2020-05-02-4/+4
|
* render: don't re-instantiate the foreground pixman sourceDaniel Eklöf2020-05-02-6/+5
|
* vt: use signed integers to correctly detect when we're doneDaniel Eklöf2020-05-02-2/+2
|
* readme: sligh re-wording of the "Unicode combining" chapterDaniel Eklöf2020-05-02-8/+9
|
* meson: don't generate pre-compose table when -Dunicode-precompose=falseDaniel Eklöf2020-05-02-6/+12
|
* meson: only define FOOT_UNICODE_PRECOMPOSE if combining chars > 0Daniel Eklöf2020-05-02-2/+3
|
* meson: generate unicode compose tableDaniel Eklöf2020-05-02-1037/+8
| | | | This replaces the pre-generated table used up until now.
* script: generate-unicode-precompose: generate a complete header fileDaniel Eklöf2020-05-02-2/+27
|
* readme: utf8proc is no longer a dependencyDaniel Eklöf2020-05-02-2/+0
|
* changelog: try to fix link for Codebergs markdown parserDaniel Eklöf2020-05-02-1/+1
|
* changelog: remove bad ']' in linkDaniel Eklöf2020-05-02-1/+1
|
* unicode-combine: remove utf8proc dependencyDaniel Eklöf2020-05-02-40/+34934
| | | | | | | | | | | | We only used utf8proc to try to pre-compose a glyph from a base and combining character. We can do this ourselves by using a pre-compiled table of valid pre-compositions. This table isn't _that_ big, and binary searching it is fast. That is, for a very small amount of code, and not too much extra RO data, we can get rid of the utf8proc dependency.
* unicode-combining: don't limit ourselves to the (western) diacritics blocksDaniel Eklöf2020-05-02-13/+19
|
* render: de-indent #if statementDaniel Eklöf2020-05-01-1/+1
|
* unicode-combining: pack structDaniel Eklöf2020-05-01-1/+1
|
* unicode-combine: leave a note saying we might need more than 2 combining charsDaniel Eklöf2020-05-01-1/+1
|
* unicode-combine: only compose if we don't have any other combining charactersDaniel Eklöf2020-05-01-16/+24
| | | | | | | | | If the client sent the sequence SAB, where SA does NOT have a composed representation, but SB does, the old code would compose SB and throw away A. This patch fixes this by only allowing a compose if there aren't any pre-existing combining characters.
* meson: emit a 'summary()' at the endDaniel Eklöf2020-05-01-0/+7
|
* Merge branch 'unicode-combining-for-real'Daniel Eklöf2020-05-01-89/+164
|\
| * unicode-combining: completely remove unicode combining characters when feature is disabledDaniel Eklöf2020-05-01-2/+26
| |
| * term: combining characters: reduce max number of combining charactersDaniel Eklöf2020-05-01-1/+1
| |
| * changelog: rewrite entry for combining charactersDaniel Eklöf2020-05-01-8/+6
| |
| * selection: extract text: also copy combining charactersDaniel Eklöf2020-05-01-14/+23
| |
| * render: render combining charactersDaniel Eklöf2020-05-01-12/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is basically just a loop that renders additional glyphs on top off the base glyph. Since we now need access to the row struct, for the combining characters, the function prototype for 'render_cell()' has changed. When rendering the combining characters we also need to deal with broken fonts; some fonts use positive offsets (as if the combining character was a regular character), while others use a negative offset (to be used as if you had already advanced the pen position). We handle both - a positive offset is rendered just like a regular glyph. When we see a negative offset we simply add the width of a cell first.
| * grid: reflow: copy combining charactersDaniel Eklöf2020-05-01-0/+9
| |
| * vt: utf8: track combining characters that we failed to composeDaniel Eklöf2020-05-01-15/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we detect a combining character, we first try to compose it with the base character (like before). When this fails, we instead add the combining character to the base cell's combining characters array. The reason for using a composed character when possible is twofold: one, the rendered glyph will look better since it will be a single glyph instead of two separate glyphs (possibly from different fonts(!)). And two, for performance. A composed glyph is a single glyph to render, while a decomposed glyph sequence means the renderer has to render multiple glyphs for a single cell.
| * term: print: reset combining characters for this cellDaniel Eklöf2020-05-01-0/+1
| | | | | | | | | | | | | | | | | | | | | | This is the *only* place combining characters are reset. In particular, we do *not* reset them in a normal cell erase. This is a performance design decision - clearing the combining characters in erase is way too slow. This way, we clear it only when we *have* to. Anything looking at the combining characters must first ensure the base character is not 0.
| * grid: add per-cell combining charactersDaniel Eklöf2020-05-01-1/+11
| | | | | | | | | | | | | | | | | | | | The data is *not* added to the cell struct, since that one is too performance critical. Instead, the data is added as a separate array in the row struct. This allows our performance critical code paths that e.g. clear cells to perform as before.
| * util.h: new header file defining commonly used macrosDaniel Eklöf2020-05-01-39/+18
|/
* term: don't enable ptmx FDM callback until Wayland window has been configuredDaniel Eklöf2020-04-30-4/+26
| | | | | | | | | | | | | The way things works right now, we cannot enable the ptmx FDM callback right away. We need to wait for the Wayland window to have been configured. Before the window is configured, we don't have a size, and no grid. Thus, if we try to process ptmx data we'll crash since we have no where to write it to. So, registering the ptmx fd with the FDM is now delayed until we've received the first 'configure' event from Wayland.
* term: start slave before loading fonts and starting rendering threadsDaniel Eklöf2020-04-30-8/+9
| | | | | This allows the client to load in parallel with our font loading, which should improve startup time.
* main: only set LC_CTYPEDaniel Eklöf2020-04-29-1/+1
| | | | | | This is the only locale variable we need. This ensures LC_NUMERIC in particular remains as "C", which is needed by fcft when instantiating new fonts.
* term: font size adjust: re-load fonts in parallelDaniel Eklöf2020-04-29-9/+30
|
* term: destroy: handle rendering threads not being initializedDaniel Eklöf2020-04-29-11/+15
| | | | | We sort of already did this. However, we did not handle the case where the thread array itself hadn't yet been allocated.
* term: initialize rendering worker threads after instantiating fontsDaniel Eklöf2020-04-29-3/+2
| | | | | | This ensures the resources (e.g. stack) used by the transient threads used to load the primary fonts can be re-used by the rendering worker threads.
* csd: buttons: use default color table as default colorsDaniel Eklöf2020-04-29-6/+9
| | | | | If the user hasn't configured any CSD button colors, use the color scheme's default colors for blue/green/red.
* changelog: change -> changesDaniel Eklöf2020-04-28-1/+1
|
* term: load primary fonts in parallelDaniel Eklöf2020-04-28-8/+38
| | | | | | | | Use four threads to load the four primary font variants - normal, bold, italic and bold italic. This speeds up initial startup, and reloading of fonts on a DPI change.
* wayland: monitor unplug: call surface_leave() to handle terminal unmappingDaniel Eklöf2020-04-28-14/+7
|
* wayland: handle outputs disappearingDaniel Eklöf2020-04-27-11/+51
| | | | | | | | | That is, deal with monitors being unplugged. At least on Sway 1.4, surfaces are not unmapped before the output is removed. Thus, in addition to free:ing the monitor resources, we also need to update all terminals that are mapped on this output - remove the output from their "mapped on" list.
* wayland: group handle_global() together with handle_global_removed()Daniel Eklöf2020-04-27-131/+131
|
* Merge branch 'unicode-combining'Daniel Eklöf2020-04-27-22/+68
|\
| * vt: lazily reset utf8 in action_utf8_*_entryDaniel Eklöf2020-04-27-4/+3
| | | | | | | | | | | | | | | | action_clear() is in the super hot code path. Avoid resetting utf8 state there, as utf8 input is relatively uncommon. Instead, reset it when we explicitly enter any of the utf8 collecting states, as this is exactly the point where we need it.
| * vt: action_utf8_print: idx is cleared in action_clear()Daniel Eklöf2020-04-27-3/+0
| |
| * vt: utf8-*-entry: idx is cleared in action_clear()Daniel Eklöf2020-04-27-3/+3
| |
| * term: remove unneeded utf8.left memberDaniel Eklöf2020-04-27-16/+0
| |
| * readme: link to utf8proc was cut offDaniel Eklöf2020-04-27-1/+1
| |
| * readme: add link to utf8procDaniel Eklöf2020-04-27-1/+2
| |
| * readme: add utf8proc to the list of dependenciesDaniel Eklöf2020-04-27-0/+1
| |
| * utf8: add support for unicode combining charactersDaniel Eklöf2020-04-27-3/+67
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This feature lets foot combine e.g. "a\u0301" to "á". We first check if the current character (that we're about to print) is a combining character, by checking if it's in one of the following ranges: * Combining Diacritical Marks (0300–036F), since version 1.0, with modifications in subsequent versions down to 4.1 * Combining Diacritical Marks Extended (1AB0–1AFF), version 7.0 * Combining Diacritical Marks Supplement (1DC0–1DFF), versions 4.1 to 5.2 * Combining Diacritical Marks for Symbols (20D0–20FF), since version 1.0, with modifications in subsequent versions down to 5.1 * Combining Half Marks (FE20–FE2F), versions 1.0, with modifications in subsequent versions down to 8.0 If it is, we check if the last cell appears to contain a valid symbol, and if so, we attempt to compose (combine) the last cell with the current character, using utf8proc. If the result is a combined character, we replace the content in the previous cell with the new, combined character. Thus, if you select and copy the printed character, you would get e.g. "\u00e1" instead of "a\u0301". This feature can be disabled. By default, it is enabled if the utf8proc library is found, but can be explicitly disabled, or enabled, with 'meson -Dunicode-combining=disabled|enabled'.
* meson: bump C standard to c18Daniel Eklöf2020-04-26-1/+1
|
* damage: remove 'scroll' sub structDaniel Eklöf2020-04-26-34/+32
| | | | There is no other types of damage but scroll damage.
* render: make 'glyph' assignment more readableDaniel Eklöf2020-04-26-3/+4
|
* changelog: CSI 13;2t and CSI 14t have also been implementedDaniel Eklöf2020-04-25-1/+1
|
* changelog: use backticks for full escape sequence too, and shorten entryDaniel Eklöf2020-04-25-2/+2
|
* doc: foot.5: man page references do not embolden the section numberDaniel Eklöf2020-04-25-2/+2
|
* doc: foot.5: user -> usersDaniel Eklöf2020-04-25-1/+1
|
* doc: foot.5: padding and geometry are subject to output scalingDaniel Eklöf2020-04-25-4/+4
|
* csi: log 'unhandled' for invalid 'target' and 'operation' in CSI ? SDaniel Eklöf2020-04-25-0/+7
|
* readme: update descriptionDaniel Eklöf2020-04-24-2/+1
|
* changelog: one entry for conf-option + command line option changesDaniel Eklöf2020-04-24-6/+4
|
* Merge branch 'fcft-v2'Daniel Eklöf2020-04-24-42/+130
|\
| * PKGBUILD: bump tllist+fcft version dependenciesDaniel Eklöf2020-04-24-2/+2
| |
| * meson: dependency: use fallback without variable nameDaniel Eklöf2020-04-24-3/+3
| | | | | | | | | | | | | | Now that both tllist and fcft use meson.override_dependency(), we can use the simpler form of fallback in our dependency call(). This requires meson >= 0.53, tllist >= 1.0.1 and fcft >= 2.0.0
| * fcft: fcft_glyph_for_wc() has been renamed to fcft_glyph_rasterize()Daniel Eklöf2020-04-24-2/+4
| |
| * term: fcft: max/space advance fields have been renamedDaniel Eklöf2020-04-23-2/+2
| |
| * meson: we now require fcft 2.0.xDaniel Eklöf2020-04-23-1/+1
| |
| * changelog: current output's subpixel order is preferred over FontConfigDaniel Eklöf2020-04-22-0/+6
| |
| * term: guess subpixel mode after initializing wayland windowDaniel Eklöf2020-04-22-0/+2
| | | | | | | | | | | | | | | | | | At this point, we're not mapped, but we should have all the outputs initialized. Which means we can at least guess which subpixel mode to use. If that turns out to be wrong, something we'll detect when we're mapped, we'll just have to re-render.
| * fcft: adjust to fcft-2.0 API changesDaniel Eklöf2020-04-21-48/+48
| | | | | | | | | | | | | | * font_*() -> fcft_*() * struct font -> struct fcft_font * struct glyph -> struct fcft_glyph * enum subpixel_order -> enum fcft_subpixel
| * Merge branch 'master' into fcft-v2Daniel Eklöf2020-04-21-0/+1
| |\ | |/ |/|
* | main: log localeDaniel Eklöf2020-04-21-0/+1
| |
| * render: use output's subpixel mode when rasterizing glyphsDaniel Eklöf2020-04-20-1/+79
|/
* completions: zsh: -f,--font accepts multiple, comma separated valuesDaniel Eklöf2020-04-20-1/+1
|
* readme: improve descriptionDaniel Eklöf2020-04-19-2/+3
|
* readme: bug reporting: emphasize that debug builds are preferred for backtracesDaniel Eklöf2020-04-19-1/+1
|
* readme: spell 'change' correctlyDaniel Eklöf2020-04-19-1/+1
|
* term: destroy: free scroll damage listsDaniel Eklöf2020-04-19-0/+3
| | | | | | | | | These lists are typically empty when we destroy the terminal. However, if we had queued up damage, and then manage to destroy the terminal instance before the last changes were rendered, then they will *not* be empty. Found by the address sanitizer.
* csi: fix typo - the '(' was in the wrong placeDaniel Eklöf2020-04-19-1/+1
|
* render: search: improve handling of very long search stringsDaniel Eklöf2020-04-19-4/+10
|
* csi: CSI Ps ; Ps ; Ps t: report logical pixelsDaniel Eklöf2020-04-18-5/+8
|
* shm: #ifdef conditional code to measure total size of SHM allocationsDaniel Eklöf2020-04-18-0/+20
|
* server: don't do misaligned loadsDaniel Eklöf2020-04-18-11/+23
|
* Merge branch 'csi-report'Daniel Eklöf2020-04-18-11/+96
|\
| * csi: implement CSI Ps ; Ps ; Ps t reporting escape sequencesDaniel Eklöf2020-04-18-11/+96
|/ | | | | | | | | | | | | | | | | | | | | | A lot of the escape sequences on the "CSI Ps ; Ps ; Ps t" form are expected to return a reply. Thus, not having these implemented means we will hang if the client sends these escapes. Not all of these escapes can be meaningfully implemented on Wayland, and thus this implementation is best effort. We now support the following escapes: * 11t - report if window is iconified (always replies "no") * 13t - report window position (always replies 0,0) * 13;2t - report text area position (replies with margins, since we cannot get the window's position) * 14t - report text area size, in pixels * 14;2t - report window size, in pixels * 15t - report screen size, in pixels * 16t - report cell size, in pixels * 18t - report text area size, in cells * 19t - report screen size, in cells
* changelog: selection is no longer cleared on resizeDaniel Eklöf2020-04-17-0/+1
|
* render: resize: no need to truncate selection anymore - it's being translatedDaniel Eklöf2020-04-17-7/+1
|
* render: resize: need to translate selection coordinatesDaniel Eklöf2020-04-17-2/+15
| | | | | | | | | | | | | While it *looked* like the selection was working before, it really wasn't. When rendering, we're looking at the cells' attributes to determine whether they have been selected or not. When copying text however, we use the terminal's 'selection' state, which consists of 'start' and 'end' coordinates. These need to be translated when reflowing text.
* grid: reflow: make tracking_points array 'const'Daniel Eklöf2020-04-17-2/+2
| | | | | The elements aren't, and cannot be, const. But the array itself can, and should be.
* Merge branch 'translate-cursor-coords-when-reflowing'Daniel Eklöf2020-04-17-195/+236
|\
| * render: resize: no need to clear the selection - just truncate if necessaryDaniel Eklöf2020-04-17-2/+6
| |
| * grid: reflow: caller may now pass a list of coordinates that should be translatedDaniel Eklöf2020-04-17-4/+11
| |
| * grid: reflow: generalize cursor coordinate translationDaniel Eklöf2020-04-17-26/+41
| | | | | | | | | | | | | | | | | | | | | | Define a list of "tracking points" - coordinates that should be translated while reflowing. Add the cursor coordinates to this list. When a coordinate have been translated, it is removed from the list. This means we don't have to create a copy of the 'cursor' coordinate struct.
| * changelog: cursor coordinates are now translated on resizeDaniel Eklöf2020-04-17-0/+1
| |
| * grid: reflow: remove commented out codeDaniel Eklöf2020-04-17-2/+0
| |
| * grid: reflow: turn line-wrapping code into a macroDaniel Eklöf2020-04-17-24/+19
| |
| * grid: reflow: don't randomly insert hard linebreaksDaniel Eklöf2020-04-17-0/+2
| | | | | | | | | | Not sure why I added this code; maybe to workaround issues caused by the fact that the cursor position wasn't properly translated.