]> git.draconx.ca Git - rrace.git/commit
motif: Don't query widget width every timer update.
authorNick Bowler <nbowler@draconx.ca>
Thu, 26 Jan 2023 02:18:13 +0000 (21:18 -0500)
committerNick Bowler <nbowler@draconx.ca>
Thu, 26 Jan 2023 02:18:21 +0000 (21:18 -0500)
commit820ca1a966bd2cb0b77d7e36d979645b527a1b2b
treea3d609c199ac4d58ade223a029a77b641735f1b1
parentbb0ef256f417d9847b157c0a204a634d65c98a4b
motif: Don't query widget width every timer update.

Turns out that just getting the widget width from Xt represents
the vast majority of the time spent on the timer update.  It is
very simple to query the width only when it changes, instead,
and save that result for later rendering.
src/xcounter.c
src/xcounter.h