Add LightCurve.ignore_noisy method
Remove unused Adjustment
Add message window to select the SNR threshold used in plots

The options regarding how light curves are plotted will be from now on
grouped in a new submenu, View → Plots. Move the 'Airmasses' entry to
it and add a new one: 'SNR Threshold'. When clicked, it displays a
message window with a spin button that allows the user to select the
minimum signal-to-noise shown in plots. This commit does not takes the
threshold into account nor stores it in the configuration file, but in
future commits the points of the light curves with a SNR below this
value will not be plotted.
Save and read the SNR threshold to and from the configuration file

The minimum signal-to-noise ratio selected by the user with the spin
button (6274bb3e62) is saved to and read from the configuration file,
so that it persists across different executions. The value is not
updated in the configuration file when 'Cancel' is clicked or the
dialog window destroyed — in other words: only changes in the SNR
threshold that are confirmed with the 'Ok' button are saved.
Rename StarDetailsGUI.handle_toggle_airmasses_checkbox method
Update plots when a new SNR threshold is selected

In order to account for the possibility that all the points of a light
curve are below the required minimum signal-to-noise ratio, we now use
a three-row gtk.VBox. The first two are used for the Matplotlib canvas
and navigation toolbar, while the last one contains a gtk.Label with
the error message that is shown when a light curve cannot be plotted
because all its points are below the SNR threshold.

By default, only the first two rows (canvas and toolbar) are visible.
In case the light curve cannot be plotted, the visibility of the rows
in the VBox is reversed and only the error message, "No points have a
signal-to-noise ratio above the current threshold (to modify it, go
to View → Plots → SNR threshold)", is displayed.
Speed up shutdown (quite considerably)

Always use the same handler, LEMONJuicerGUI.handle_quit method, when
the GUI is closed, whether 'Quit' is clicked or the window destroyed.

Take advantage of the fact that the handlers are now unified to speed
up our code: when there are pages in the gtk.Notebook it takes much
longer to close the GUI than when it is empty. We do not know whether
this is how PyGTK works or we are doing something wrong (most probably
the latter), but in any case this can be fixed by removing all the
pages from the notebook before destroying the window.
Use 'button-press-event' signal to switch the photometric filter

In StarDetailsGUI, connecting each photometric filter to the 'clicked'
signal is causing the light curve in the first filter (when sorted by
wavelength) to be plotted first, even if a different one was specified
using the 'init_pfilter' keyword argument (StarDetailsGUI.__init__).
In these cases, the requested filter is plotted, but only after the
first one. Since both plots are made sequentially, this behavior has
gone unnoticed until now.

The reason for this is that the 'clicked' signal is emitted when the
mouse button is pressed and released while the pointer is over the
button. This means that the signal is emitted both when we 'enter'
(press) and 'leave' (unpress) a photometric filter. Since GTK forces
that one of the radio buttons (used to choose the filter) is always
selected, the button of the first filter is always pressed when they
are created (even if the corresponding light curve is not plotted) and
then, when we switch to the filter given in 'init_pfilter', the signal
is emitted twice. The solution is to use the 'button-press-event'
signal, which is only emitted when the mouse button is pressed.
Access LEMONdBs using the LEMONdBMiner class

The usage that we are doing of the LEMON databases is read-only, so
instead of the LEMONdB class we can use LEMONdBMiner, its subclass,
which memoizes some of the methods to avoid unnecessary reads from
the database.
Set 'scrollable' property of the gtk.Notebook to True

If True, scroll arrows are added to the notebook when there are too
many tabs to fit in the area. This property is False by default.
Avoid recursive call in LEMONJuicerGUI.handle_quit

The call to self._main_window.destroy() in LEMONJuicerGUI.handle_quit
emits the 'destroy' signal, which is in turn also connected to this
very method (handle_quit). Therefore, when we shut down the GUI by
clicking 'Quit' we are calling LEMONJuicerGUI.handle_quit twice.
Add explicit method to update the configuration file

We cannot use __del__ to automatically update the configuration file
when the instance is destroyed — this artless approach fails since we
started having more than one reference to the Configuration instance.
We need to use a method that is explicitly called when the GUI shuts
down, as recommended by the wise folks at Stack Overflow:

"You cannot assume that __del__ will ever be called - it is not a
place to hope that resources are automagically deallocated. If you
want to make sure that a (non-memory) resource is released, you should
make a release() or similar method and then call that explicitly [...]"
— http://stackoverflow.com/a/6104568/184363
Do not replot light curves when the SNR threshold is not changed

Make the SNRThresholdDialog.run method return None not only when
'Cancel' is pressed or the dialog window destroyed, but also if 'Ok'
is clicked without having modified the minimum signal-to-noise ratio.
This saves us from unnecessarily replotting the light curves with the
same SNR threshold.
Make LightCurve.amplitude raise ValueError if the instance is empty
Fix serious bug in LightCurve.amplitude method

The peak of the light curve is calculated by computing the median (or
arithmetic mean) of the 'npoints' highest magnitudes, but because of a
missing minus sign what we are actually taking are all of them except
for the first 'npoints'. This means that we are basically computing
the median (or mean) of the entire light curve, and therefore the
amplitudes returned by the method are completely wrong.
Add unit test for LightCurve.amplitude method
Add unit test for LightCurve.ignore_noisy method
Improve explanation of how amplitudes must vary with the wavelength
Use more technical terms (peak and trough)
Include a description of the search in AmplitudesSearchPage

Add a description to the left of AmplitudesSearchPage explaining how
the listed stars were found and the value of all the parameters. This
is essential to allow the user to do multiple searches without having
to strive to remember which parameters were used in each case.