Revision 699382

Go back to digest for 19th August 2007

Features in Educational

James Bowlin committed changes in /branches/work/kdeedu_kstars_htm/kstars/kstars:

Labels are now never overlapping the info boxes. The problem _was_ that the coordinates were changing when the boxes weren't being drawn.

[Holy Heisenberg Batman!]

I fixed the problem with the kludge of copying the coordinates every time the boxes are drawn and then using the copies when it came time to reserve space for the boxes in the SkyLabeler. If the coordinates stop changing (when the labels don't move) then this code can be removed.

I made an array of InfoBox* which greatly simplified the drawBoxes() routine and also the new reserveBoxes() routine. The array can be used to simplify a lot of the other code in InfoBoxes but I haven't done that yet.

I also noticed that the InfoBoxes seem to get drawn more often than is needed. The get drawn about 20 times in quick succession at startup and then they get drawn twice per second thereafter. The two draws are in rapid succession and I suspect that just one would suffice.

I'm returning out of SkyMap::drawHighlightConstellation to keep my draws fast. The code that lets the user select this should be waiting for me in the trunk.

File Changes

Modified 3 files
  • /branches/work/kdeedu_kstars_htm/kstars/kstars
  •   /infoboxes.cpp
  •   /infoboxes.h
  •   /skymapdraw.cpp
3 files changed in total