[Kstars-devel] KStars script

Jason Harris kstars at 30doradus.org
Mon Jun 27 18:13:48 CEST 2005


Hi Mike,

On Sunday 26 June 2005 06:41 pm, Mike Diehl wrote:
> I have written a KStars script that is a tour of the constellations. I
> first started building the script using the Script Builder tool. The script
> brought out some problems of which one I have a solution for, or at least a
> workaround of sorts.
>
Thanks for writing the script!

> First problem which is the root of the rest is where I had to make a
> workaround. Using changeViewOption leaves you no way to restore the users
> original settings. For this I decided to use some simple bash scripting to
> correct. In the attached script I first set some var's with the original
> configurations of the view options I plan to change, something like this:
>
Yes, I am planning to add DCOP functions that return values eventually, so you 
can probe the config, get the current simulation time, etc.  I should also 
add functions that save and restore the user's config, so you don't have to 
go through and store every option separately.

> Why does KStars refuse the script, is this a security measure, or is it to
> prevent problems with the script builder? I haven't had any time to look at
> the KStars code, but any pointers would be helpful.
>
As written, KStars doesn't execute the DCOP script, it has an interpreter that 
parses the script and makes the calls internally.  I should just change this 
to make it execute the script.

I''l try to get these changes in for 3.5.

Jason
-- 
-------------------------------
KStars: KDE Desktop Planetarium
http://edu.kde.org/kstars


More information about the Kstars-devel mailing list