Hi,

Before attempting to work on the Logbook plugin as I proposed in an earlier
message, I thought it made the most sense to get used to working with Qt
and Stellarium by writing a new plugin. I spent the past few nights putting
together a small plugin that provides a ui for managing lists of objects
(stars, planets, nebula etc). The plugin lets you keep multiple lists, add
items to the list by clicking on them and pressing a button to add them,
then go to items in your list by double clicking. I plan to share the code
when I have it stable. I don't imagine that there is a lot of demand for
this but it might be useful to a few users. (One use case would be a
downloadable list of weekly celestial highlights, which when imported by
the plugin would let you see specified objects at a specified time at the
click of a button.)

In the process of writing the plugin I have learned a lot, but I have a few
questions:

1. What is the easiest way to create a new plugin? I just copied another
plugin, stripped out the stuff I didn't need and renamed variables
appropriately. It would be nice if there was a small script to do all of
the laborious bits: collect basic info about the plugin (author, title,
whether it has config etc), create basic source stubs, edit relevant build
files. I actually spent a lot of time just trying to get the plugin to
build.

2. Why does the StelDialog class require so much user code? I may have
misunderstood how to use it, but it seems much more complicated to use than
a QDialog. To get it to work, I had to add title bar with title and close
button, set styles, and set translations. Why isn't this functionality
provided by default in the base StelDialog class? What am I missing?

3. Is there a unique and persistent identifier for objects (stars, planets
etc)? I was using the name, but sometimes this isn't a unique value (some
objects don't have names).

dm
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Stellarium-pubdevel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stellarium-pubdevel

Reply via email to