[Kst] Scripting
George Staikos
staikos at kde.org
Fri Apr 1 02:33:04 CEST 2005
The first step of scripting is basically done and working in CVS now. The
following code works:
var f = new DataSource("vector.txt");
var i = new DataVector(f, "INDEX");
var d = new DataVector(f, "2");
i.tagName = "INDEX";
d.tagName = "2";
var e = new Equation("sin(x)", "INDEX");
e.tagName = "myEquation";
var c = new Curve("INDEX", e.yVector);
c.tagName = "myCurve";
var w = new Window;
var p = new Plot(w);
p.curves.append(c);
The bindings for Plot and Window are very incomplete, but the rest of the
objects are quite well bound. I'd appreciate comments, but don't bother with
bugzilla yet. It's possible that this code will be completely rewritten or
redesigned [again]. I hope to make some documentation, but in the meantime,
you can see some of the properties with "dump(variablename)".
I may slow down script implementation for the next few days and work on other
areas in order for people to look over what's there so far. There is still a
very large amount of work to be done on the bindings and I expect it will
take another month or so to get them into shape for a 1.1 release. Some
bindings may be left out in the first release (in particular, matrices,
images, and more complete view object bindings) because major changes need to
be made in those areas.
Looking forward to feedback!
--
George Staikos
KDE Developer http://www.kde.org/
Staikos Computing Services Inc. http://www.staikos.net/
More information about the Kst
mailing list