tg icon indicating copy to clipboard operation
tg copied to clipboard

Zoom control for paperstrip

Open xyzzy42 opened this issue 3 years ago • 2 comments

This builds on the horizontal chart PR #28.

This adds zoom buttons that overlay the paperstrip drawing area. They allow one to smoothly zoom from displaying a full beat per row to one tenth a beat (default) to one hundred of a beat (calibrate default).

To do this, I had to pretty much re-write the paperstrip drawing code to use a different algorithm that supports smooth zooming. See commit messages for detailed information.

This also reverses the slope, so a fast movement slopes up and left instead of up and right. This was easier to code, seemed more correct to me, and, more importantly, appears to match what other timegraphers like Witschi's use.

Example, with zoom popup opened as zoom is adjusted. Notice chart width of 112.5 ms is not integral fraction of 200 ms beat length. image

xyzzy42 avatar Mar 18 '21 01:03 xyzzy42

I've got an old 2012 Macbook Air and it wasn't too much trouble to brew install gtk+, automake, etc. and build it. More trouble than Linux and brew took forever to install everything. It installed Apple clang version 12.0.0, which had no trouble with unicode in the source and extended constant expressions.

I think I get the same error you are, and the details from the error dialog that OS X throws up tell me enough to fi x it. Should be fixed now.

xyzzy42 avatar Mar 22 '21 22:03 xyzzy42

Tested with a newer gcc compiler. It all works as expected. The zoom is a nice touch.

jpolton avatar Mar 23 '21 09:03 jpolton