- I resolve the PRN text scaling issue by comparing the scaled text height with the available space.
If there is not enough space available, the scaling factor is updated so the final scale factor fills the available space as much as possible.
If the height limit has been reached, the corrected scaling is applied to both the PRN and the SNR text to keep both about the same size.
- This scaling works fine on my Windows PC. I therefore removed the maximum width limit for the snrwidget. (was 850px)
The snr widget will now take up all available width. This does not mean that individual bars will be scaled to fit the width of the widget.
However I have implemented a two step scaling for that. If there are less than 16 visible satellites, the width of each bar is calculated
based on a total of 16 bars in the view. Just like before my changes. If there are more than 16 satellites visible, the number of bars displayed
is incremented from 16 to 24. An aging based hysteresis has been added to prevent continuous flapping between both states.
I think this solution is aesthetically more pleasing than scaling the width of the bars to the width of the widget.
Especially for low number of satellites. (This solution would show massive bars if only a few satellites are visible)
- Since there was no copyright header in gpssnrwidget.cpp and gpssnrwidget.h, I have added one. The OP line is based on the last changes seen in the OP repo.
- more professional looking toggle code.
- change PRN font to Digital-7
- updated font size factor for SNR PRN text from .56 to .68
- moved a few class includes from the .h to the .cpp file & forward declared QGraphicsSvgItem class in flatearthwidget.h
- hide marker before resize, display it again after resize.
- corrected issue where marker was crawling to the south on continuous resizes.
Instead of nudging the marker, added a proper forceUpdate parameter to the setPosition() function.
- made sure that only one @author tag is present.
- centered both flatEarth and constellation widgets in their boxes.
- lowered resolution of the map image 1440 -> 1080 & used JPG instead of PNG. Size went from 1105KB on disk to 155KB on disk (PNG version for this resolution is 634KB).
The resolution change has a minor impact on the level of detail seen in the zoomed view.
- added margin for the SNR widget. Although I start to think the SNR widget isn't all that interesting. Removal may be an option.
- Also removed gridLayout_2 from the top left, leftover from a test.
- Delete scene in the widget destructor. I saw this was done in constellation widget, therefore did the same.
I used NULL instead of 0. Looks more correct for pointers to me.
What I didn't implement:
- wider bars in the SNR widget when less than the max number of satellites are shown.
Currently the total width of the SNR widget is limited to 850px. If we go wider with the current implementation, the text becomes too large.
At this time, I don't have a good idea how to handle that.
- Improve Alt label in the GPS display widget. The displayed altitude is Above Mean Sea Level (AMSL).
AMSL label has been added to clarify the reference from which this altitude is measured.
- Make values bold to draw more attention to them. The labels are less important.
- Replaced an empty horizontal layout by a vertical spacer
SDK install script and Qt installer script updated with new version, paths and URL:s
Explicit casts to char added to avoid clang compiler warnings (treated like errors) on MacOSX and XCode 8.3.2