Filter XML files by extension, not mimetype

In the gtk.FileChooserDialog, filtering XML files by their mimetype
(application/xml) is not working as expected, as, for example, Glade
files (application/x-glade) are also matched. To avoid this, match XML
files with the .xml extension, but use the gtk.FileFilter.add_custom
method to perform a case-insensitive match.
Perform a case-insensitive match also for LEMONdB files
Insert LEMONdB overview into the first page of the gtk.Notebook

The overview of the LEMONdB must be inserted at the first position of
the gtk.Notebook. Appending it after all the other pages was fine as
long as the LEMON database was guaranteed to be the first page to be
added (and so the -1 and 0 indexes were equivalent), but since commit
123b4ce2d2 it is possible to open a serialized AmplitudesSearchPage
before the LEMONdB.

Therefore, we can no longer append the page with the LEMONdB overview,
as in these cases the page would be inserted at a position other than
zero — and LEMONJuicerGUI.handle_close needs the overview to be in the
first page to be able to detect that the user has closed a LEMONdB and
therefore all the pages in the gtk.Notebook must be removed.
Write the name of the observed objects to the offsets XML file

Add the name of the target astronomical object (read from the FITS
header of each image, most probably from the "OBJECT" or "OBJNAME"
keywords) to the XMLOffset class and store it as an attribute of the
"shifted" element when the offsets are written to disk. This value is
as useful, if not more, than the date of observation and photometric
filter (which are already saved in the XML file) and in order to store
it in the LEMONdB, as we intend to do, we first need to write it in
the offsets XML file.
Update outdated comment (the old combine.py module is now mosaic.py)
Store the name of the observed objects in the LEMONdB

Add the name of the target astronomical object as a new column of the
RIMAGE and IMAGES tables (reference and shifted images, respectively)
of the LEMON database. In the case of the shifted images, the name of
the observed object can, since commit b1dc90bc9b846a4, be found in the
offsets XML file, but that of the reference image must still be read
from the FITS header ("OBJECT" or "OBJNAME" keywords, usually).
Read the photometric filter of the shifted images from the XML file
Read the date of observation of the shifted images from the XML file
Do not read the same keyword from the FITS header twice
Store all the data of the shifted image in child XML elements

Although there are no rules about when to use attributes and when to
use child elements, most developers seem to prefer to use attributes
for metadata as opposed to the data itself. Even it that were not the
case, using three attributes ('date', 'filter' and 'object') for the
'shifted' element was resulting in ugly and hard-to-read offsets XML
files. Put this information in child elements — this also requires
that we move the path to the shifted image to its own child element.
Factor out the description of the --fwhmk optparse option.
Write the FWHM of the shifted images to the offsets XML file

The full width at half maximum of each image is computed by seeing.py
and written to the FITS header. Later, at photometry.py, we compute
the median FWHM of each photometric filter — and thus we have to read
the FWHM of all the images taken with the same filter. However, this
also means that annuli.py accesses the header of all the FITS images
every time a new set of photometric parameters is evaluated, in spite
of the fact that the FWHM of the images is always the same. Save them
to the offsets XML file, so that they are read from the FITS header
only once — when offsets are calculated.
Factor out the reference image in the offsets XML file

Instead of using a 'reference' child for each 'shifted' element, and
since the offsets XML files generated by LEMON use the same reference
for all the images (that is, all the offsets are computed with respect
to the same image), we can factor out the 'reference' element, making
it a child of the root element — in this manner, the reference image,
which is the same for all the images, is listed only once.

Note that this change requires that the XMLOffsetFile class enforces
that all of the XMLOffsets in it contained have the same reference
image. This is achieved by modifying its __init__ method: the class
receives at instantiation the path to the reference image, and
XMLOffsetFile.add checks that the reference image of the XMLOffset
being added is the same. We also need XMLOffsetFile.load, which parses
an XML offsets file and returns an XMLOffsetFile instance.
Save information about the reference image to the offsets XML file

Use the 'image' element not only for each of the shifted images, but
also for the reference image — so that the offsets XML file contains,
in addition to the path to the image, its date of observation, filter,
name of the observed object, FWHM and airmass. In this manner, the XML
file has the same information for all the images, whether reference or
shifted, and photometry.py (and, by extension, annuli.py) does not
need to access the FITS header of the reference image to read it.
Remove unused optparse options (--rak and --deck)
Write the airmass of the images to the offsets XML file

The airmass of the images is also stored in the LEMONdB (RIMAGE and
IMAGES tables), so, analogously to what we have already done with the
FWHM, write it to the offsets XML file so that it is not read from the
FITS header over and over, as different sets of photometric parameters
are evaluated, by annuli.py.