]> git.draconx.ca Git - rrace.git/commit
x11: Shrink colour initialization code.
authorNick Bowler <nbowler@draconx.ca>
Wed, 4 Jan 2023 02:26:31 +0000 (21:26 -0500)
committerNick Bowler <nbowler@draconx.ca>
Sat, 7 Jan 2023 16:43:13 +0000 (11:43 -0500)
commit7aac229d09956b35cf96a3d76900c1adb7b1f42e
tree432da8bca1c5bac8618ad995d9c82307b0925ae3
parent5278747bc6615197749a4e882283c9d06901cd80
x11: Shrink colour initialization code.

Remove the large global XtResource array which is only used once at
program startup and replace it with a much more compact encoding,
(basically just the strings) which is sufficient to generate the
rest at runtime.  This appears to reduce the overall program size
quite a lot.

A further (very small) improvement is also realized by adjusting the
order of the resources to match the order in the state structure.
src/x11.c