aboutsummaryrefslogtreecommitdiff
path: root/render.h (unfollow)
Commit message (Collapse)AuthorLines
2020-03-06render: never render CSD and/or search box "immediately"Daniel Eklöf-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.
2020-03-02csd: initial implementation of minimize/maximize/close buttonsDaniel Eklöf-0/+1
2020-02-29render: csd: split up positioning from renderingDaniel Eklöf-0/+1
2020-02-25render: render_resize_*() returns a boolean indicating whether size changed.Daniel Eklöf-2/+3
2020-02-25render: export render_csd()Daniel Eklöf-0/+1
2020-02-08render: add render_resize_force()Daniel Eklöf-0/+2
This forces a full resize operation, even though actual window size (or scale) hasn't changed.
2020-01-12term/render: move {enable,disable}_application_synchronized_updates()Daniel Eklöf-3/+0
From render -> terminal
2020-01-12render: rename render_{enable,disable}_refresh()Daniel Eklöf-2/+3
2020-01-12render: add render_{enable,disable}_refresh()Daniel Eklöf-0/+2
Calling render_disable_refresh() causes update requests to that terminal to be ignored. Calling render_enable_refresh() re-enables updates.
2020-01-04render: throttle xcursor updatesDaniel Eklöf-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.
2020-01-04render: trigger terminal refreshes in an FDM hookDaniel Eklöf-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.
2020-01-03render: remove 'refresh' from render_resize()Daniel Eklöf-1/+1
2020-01-03render: resize() now only calls refresh() if asked toDaniel Eklöf-1/+1
2019-12-19render: attrs_to_font: const:ifyDaniel Eklöf-1/+1
2019-10-27wayland: move reload_cursor_theme() and update_cursor_surface() to waylandDaniel Eklöf-2/+0
2019-08-29search: move render() function to the 'render' moduleDaniel Eklöf-0/+1
2019-08-21render: reload cursor theme when scale (may) have changedDaniel Eklöf-1/+3
2019-08-12output: track output we're mapped on, and use maximum scaleDaniel Eklöf-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).
2019-08-12output: resize on scale changesDaniel Eklöf-1/+1
2019-07-29wip: initial multithreaded rendererDaniel Eklöf-0/+6
2019-07-24render: add render_refresh()Daniel Eklöf-0/+1
2019-07-18render: cache generated glyphs for regular ASCII charactersDaniel Eklöf-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).
2019-07-16render: implement 'underline'Daniel Eklöf-1/+1
2019-07-05render: load cursor theme from XCURSOR_THEME and XCURSOR_SIZEDaniel Eklöf-0/+1
2019-07-05render: break out rendering functions to render.{c,h}Daniel Eklöf-0/+10