Hi all, The attached patch implements a picker (aka "data reader" in Origin-speak) tool. This is much deeper into the Veusz codebase than I've gone before, so please look at it in some detail -- there may be better or more idiomatic ways of doing things than what I've written. The patch implements data reading only for the PointPlotter, but it should be easy to extend it to other widgets as well: they just need to implement pickPoint(self, bounds, x0, y0, distance='radial') and pickIndex(self, bounds, index). The first is used for mouse-picking, and locates the closest point to (x0,y0), while the second is used for keyboard navigation to provide an idea of 'next' and 'previous' points. (It may be necessary at some point to make the index be entirely under the control of the widget ala QAbstractItemModel rather than a simple integer, but not yet...) In terms of testing, I've tested it on a bunch of the files in examples/ and used it in day-to-day use for a couple of days.
I've attached the patch, since I don't trust my webmail to not mangle it. Regards, -- BKS
veusz-add-a-picker.patch
Description: Binary data
_______________________________________________ Veusz-discuss mailing list [email protected] https://mail.gna.org/listinfo/veusz-discuss
