]> git.draconx.ca Git - rrace.git/commit
Make EWMH icon generation more abstract.
authorNick Bowler <nbowler@draconx.ca>
Wed, 30 Nov 2022 01:42:42 +0000 (20:42 -0500)
committerNick Bowler <nbowler@draconx.ca>
Wed, 30 Nov 2022 01:42:42 +0000 (20:42 -0500)
commitf0704cba12e437bbe72744281af71ec19951db46
treea9c0d3a3819b8ff8f30b1f0c9307db7f5fa3f78e
parent372c088b3d4a74b3f2b9881c9a1eb36028bf44e9
Make EWMH icon generation more abstract.

Replace the low level EWMH icon drawing functions with new ones that are
much more generic: instead of the specific icon format these new ones
produce 1-byte-per-pixel images with user-controlled byte values.

These new functions will hopefully be useful for other kinds of icon
formats.  In particular, to directly create colour-index bitmaps without
working backwards from the ARGB values generated currently.

Then for the actual EWMH icon support wrap it all up in a single
function that allocates and creates all of the icon data in one shot,
using the new generic functions under the hood.  This simplifies the
calling code somewhat.

As a bonus, the overall code size seems to be reduced.
Makefile.am
src/ewmhicon.c
src/ewmhicon.h
src/icon.c [new file with mode: 0644]
src/icon.h [new file with mode: 0644]
src/motif.c
src/motif.h
src/x11.c
t/ewmhicon.c