aboutsummaryrefslogtreecommitdiff
path: root/render.h (follow)
Commit message (Collapse)AuthorAgeLines
* osc: add support for osc 176 (app ID)delthas2024-02-06-0/+1
| | | | | | | | | | This adds support for a new OSC escape sequence: OSC 176, that lets terminal programs tell the terminal the name of the app that is running. foot then sets the app ID of the toplevel to that ID, which lets the compositor know which app is running, and typically sets the appropriate icon, window grouping, ... See: https://gist.github.com/delthas/d451e2cc1573bb2364839849c7117239
* feature: add resize-by-cells option to constrain window sizes...Andrew J. Hesford2024-02-05-2/+9
| | | | | ...to multiples of the cell size, and preserve grid size when changing fonts or display scales in floating windows.
* refactor: track current xcursor using an enum, instead of a char pointerDaniel Eklöf2023-07-03-1/+1
|
* render: add render_xcursor_is_valid()Daniel Eklöf2022-02-07-1/+3
| | | | | Returns true if the provided cursor name is non-NULL, and exist in the currently loaded xcursor theme.
* replace gettimeofday with clock_gettimePranjal Kole2022-01-15-0/+1
| | | | | | | | | | | | | POSIX.1-2008 has marked gettimeofday(2) as obsolete, recommending the use of clock_gettime(2) instead. CLOCK_MONOTONIC has been used instead of CLOCK_REALTIME because it is unaffected by manual changes in the system clock. This makes it better for our purposes, namely, measuring the difference between two points in time. tv_sec has been casted to long in most places since POSIX does not define the actual type of time_t.
* input: Add support for xdg_toplevl.show_window_menu()Jonas Ådahl2021-11-29-0/+9
| | | | | This makes, if the compositor supports it, the window menu appear when right clicking on the title bar.
* urls: initial support for detecting URLs and rendering jump-labelsDaniel Eklöf2021-02-07-0/+1
| | | | The jump labels work, but is currently hardcoded to use xdg-open
* render: remove render_refresh_margins()Daniel Eklöf2020-09-29-1/+0
|
* render: implement render_refresh_margins()Daniel Eklöf2020-09-01-0/+1
| | | | | For now, it will reset term->render.last_buf to NULL, and then calls grid_render() to do a full screen refresh.
* multi-seat: improve handling of multiple (mouse) pointersDaniel Eklöf2020-07-09-1/+1
| | | | | | | | * xcursor always set for all pointers * xcursor sometimes not updated when it should be * mouse grabbed state wasn't per seat, but global (i.e. "does at least one seat enable mouse grabbing") * selection enabled state wasn't per seat
* multi-seat: enable xcursor theme support againDaniel Eklöf2020-07-08-1/+1
|
* render: pace title updatesDaniel Eklöf2020-03-25-1/+1
| | | | Synchronize window title updates with window rendering.
* render: never render CSD and/or search box "immediately"Daniel Eklöf2020-03-06-5/+2
| | | | | | | | | | Handle the CSDs and the search box the same way we handle the main grid; when we need to redraw them, call render_refresh_{csd,search}(). This sets a flag that is checked after each FDM iteration. All actual rendering is done here. This also ties the commits of the Wayland sub-surfaces to the commit of the main surface.
* csd: initial implementation of minimize/maximize/close buttonsDaniel Eklöf2020-03-02-0/+1
|
* render: csd: split up positioning from renderingDaniel Eklöf2020-02-29-0/+1
|
* render: render_resize_*() returns a boolean indicating whether size changed.Daniel Eklöf2020-02-25-2/+3
|
* render: export render_csd()Daniel Eklöf2020-02-25-0/+1
|
* render: add render_resize_force()Daniel Eklöf2020-02-08-0/+2
| | | | | This forces a full resize operation, even though actual window size (or scale) hasn't changed.
* render: throttle xcursor updatesDaniel Eklöf2020-01-04-1/+1
| | | | | | | | | | | | | | | | | | | | | | | With a bad behaving client (e.g. 'less' with mouse support enabled), we can end up with a *lot* of xcursor updates (so much, that we flooded the wayland socket before we implemented a blocking wayl_flush()). Since there's little point in updating the cursor more than once per frame interval, use frame callbacks to throttle the updates. This works more or lesslike normal terminal refreshes: render_xcursor_set() stores the last terminal (window) that had (and updated) the cursor. The renderer's FDM hook checks if we have such a pending terminal set, and if so, tries to refresh the cursor. This is done by first checking if we're already waiting for a callback from a previous cursor update, and if so we do nothing; the callback will update the cursor for the next frame. If we're *not* already waiting for a callback, we update the cursor immediately.
* render: trigger terminal refreshes in an FDM hookDaniel Eklöf2020-01-04-2/+5
| | | | | | | | | | | | | | | | | | | | | | In some cases, we end up calling render_refresh() multiple times in the same FDM iteration. This means will render the first update immediately, and then set the 'pending' flag, causing the updated content to be rendered in the next frame. This can cause flicker, or flashes, since we're presenting one or more intermediate frames until the final content is shown. Not to mention that it is inefficient to render multiple frames like this. Fix by: * render_refresh() only sets a flag in the terminal * install an FDM hook; this hook loops all terminals and executes what render_refresh() _used_ to do (that is, render immediately if we're not waiting for a frame callback, otherwise set 'pending' flag). for all terminals that have the 'refresh_needed' flag set.
* render: remove 'refresh' from render_resize()Daniel Eklöf2020-01-03-1/+1
|
* render: resize() now only calls refresh() if asked toDaniel Eklöf2020-01-03-1/+1
|
* render: attrs_to_font: const:ifyDaniel Eklöf2019-12-19-1/+1
|
* wayland: move reload_cursor_theme() and update_cursor_surface() to waylandDaniel Eklöf2019-10-27-2/+0
|
* search: move render() function to the 'render' moduleDaniel Eklöf2019-08-29-0/+1
|
* render: reload cursor theme when scale (may) have changedDaniel Eklöf2019-08-21-1/+3
|
* output: track output we're mapped on, and use maximum scaleDaniel Eklöf2019-08-12-1/+1
| | | | | | Our surface may be on multiple outputs at the same time. In this case, we use the largest scale factor, and let the compositor down scale on the "other" output(s).
* output: resize on scale changesDaniel Eklöf2019-08-12-1/+1
|
* wip: initial multithreaded rendererDaniel Eklöf2019-07-29-0/+6
|
* render: add render_refresh()Daniel Eklöf2019-07-24-0/+1
|
* render: cache generated glyphs for regular ASCII charactersDaniel Eklöf2019-07-18-1/+1
| | | | | | | | 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).
* render: implement 'underline'Daniel Eklöf2019-07-16-1/+1
|
* render: load cursor theme from XCURSOR_THEME and XCURSOR_SIZEDaniel Eklöf2019-07-05-0/+1
|
* render: break out rendering functions to render.{c,h}Daniel Eklöf2019-07-05-0/+10