arohl / gdis

A visualization program for the display, manipulation, and analysis of isolated molecules and periodic structures
GNU General Public License v2.0
43 stars 17 forks source link

gui_diffract: another FIX for peak selection from baseline or top value. #31

Closed ovhpa closed 5 years ago

ovhpa commented 5 years ago

I believe this commit is a better fix for the selection of peaks in the diffraction spectra. The good news is that the peaks are label once during the creation of the graph, so there is no need to look for (h,k,l) at each selection. Also the baseline selection now report intensity as an horizontal selection line. This is in order to unambiguously see the peak selection, especially from the baseline. I had to introduce a new restriction: the h, k, and l values are now limited to the [-127,128] range. I don't see why anyone would use such huge value, but if it becomes a problem please let me know.