1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2025-07-08 00:04:27 +02:00

Compare commits

...

15 Commits
8.6 ... 8.8

Author SHA1 Message Date
c6cc34c73f Version++ 2021-02-24 00:10:31 +01:00
ddc0e60517 Graphtab->mapview connections can be permanent
(no need to recreate them on every graph change)
2021-02-23 23:12:14 +01:00
48dcc6655b Yet another place with broken graph tab index 2021-02-23 22:55:22 +01:00
f0be0d6774 Fixed broken path<->graph binding setup
fixes #348
2021-02-23 22:35:59 +01:00
e5d5c06a0e Fine-tune OS X fullscreen layout 2021-02-21 10:00:42 +01:00
5f18498138 Merge branch 'origin/master' into Weblate. 2021-02-19 19:37:08 +01:00
4f73150e3e Improved Full-screen layout 2021-02-19 19:36:26 +01:00
3fb81cf987 Merge branch 'origin/master' into Weblate. 2021-02-19 19:33:18 +01:00
c6fb231186 Properly save/restore window geometry
Fixes #328
2021-02-19 19:31:54 +01:00
d1ba44c9f4 Translated using Weblate (Esperanto)
Currently translated at 95.4% (376 of 394 strings)

Translation: GPXSee/Translations
Translate-URL: https://hosted.weblate.org/projects/gpxsee/translations/eo/
2021-02-17 13:41:49 +01:00
7db6029de0 Translated using Weblate (Ukrainian)
Currently translated at 96.7% (381 of 394 strings)

Translation: GPXSee/Translations
Translate-URL: https://hosted.weblate.org/projects/gpxsee/translations/uk/
2021-02-17 13:41:48 +01:00
47c8f12b02 Translated using Weblate (Finnish)
Currently translated at 98.9% (390 of 394 strings)

Translation: GPXSee/Translations
Translate-URL: https://hosted.weblate.org/projects/gpxsee/translations/fi/
2021-02-17 13:41:48 +01:00
8cb56d3783 Version++ 2021-02-16 21:27:10 +01:00
7e41069cde Fixed broken marker date when time graphs are selected 2021-02-15 23:52:10 +01:00
294d26a173 Added Locus/OsmAnd/RMaps SQLite maps info 2021-02-15 00:33:46 +01:00
12 changed files with 46 additions and 46 deletions

View File

@ -1,4 +1,4 @@
version: 8.6.{build} version: 8.8.{build}
configuration: configuration:
- Release - Release

View File

@ -4,7 +4,7 @@ GPXSee is a Qt-based GPS log file viewer and analyzer that supports all common G
## Features ## Features
* Opens GPX, TCX, FIT, KML, NMEA, IGC, CUP, SIGMA SLF, Suunto SML, LOC, GeoJSON, OziExplorer (PLT, RTE, WPT), Garmin GPI&CSV and geotagged JPEG files. * Opens GPX, TCX, FIT, KML, NMEA, IGC, CUP, SIGMA SLF, Suunto SML, LOC, GeoJSON, OziExplorer (PLT, RTE, WPT), Garmin GPI&CSV and geotagged JPEG files.
* User-definable online maps (OpenStreetMap/Google tiles, WMTS, WMS, TMS, QuadTiles). * User-definable online maps (OpenStreetMap/Google tiles, WMTS, WMS, TMS, QuadTiles).
* Offline maps (MBTiles, OziExplorer maps, TrekBuddy maps/atlases, Garmin IMG/GMAP & JNX maps, TwoNav RMaps, GeoTIFF images, BSB charts, KMZ maps, AlpineQuest maps). * Offline maps (MBTiles, OziExplorer maps, TrekBuddy maps/atlases, Garmin IMG/GMAP & JNX maps, TwoNav RMaps, GeoTIFF images, BSB charts, KMZ maps, AlpineQuest maps, Locus/OsmAnd/RMaps SQLite maps).
* Elevation, speed, heart rate, cadence, power, temperature and gear ratio/shifts graphs. * Elevation, speed, heart rate, cadence, power, temperature and gear ratio/shifts graphs.
* Support for DEM files (SRTM HGT). * Support for DEM files (SRTM HGT).
* Support for multiple tracks in one view. * Support for multiple tracks in one view.

View File

@ -3,7 +3,7 @@ unix:!macx {
} else { } else {
TARGET = GPXSee TARGET = GPXSee
} }
VERSION = 8.6 VERSION = 8.8
QT += core \ QT += core \
gui \ gui \

View File

@ -415,7 +415,7 @@
<message> <message>
<location filename="../src/GUI/gui.cpp" line="380"/> <location filename="../src/GUI/gui.cpp" line="380"/>
<source>Do not show</source> <source>Do not show</source>
<translation type="unfinished"></translation> <translation>Ne montri</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="384"/> <location filename="../src/GUI/gui.cpp" line="384"/>
@ -425,12 +425,12 @@
<message> <message>
<location filename="../src/GUI/gui.cpp" line="388"/> <location filename="../src/GUI/gui.cpp" line="388"/>
<source>Date/time</source> <source>Date/time</source>
<translation type="unfinished"></translation> <translation>Dato/tempo</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="392"/> <location filename="../src/GUI/gui.cpp" line="392"/>
<source>Coordinates</source> <source>Coordinates</source>
<translation type="unfinished">Koordinatoj</translation> <translation>Koordinatoj</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="398"/> <location filename="../src/GUI/gui.cpp" line="398"/>
@ -1053,7 +1053,7 @@
<message> <message>
<location filename="../src/map/maplist.cpp" line="113"/> <location filename="../src/map/maplist.cpp" line="113"/>
<source>Locus/OsmAnd/RMaps SQLite maps</source> <source>Locus/OsmAnd/RMaps SQLite maps</source>
<translation type="unfinished"></translation> <translation>Locus/OsmAnd/RMaps SQLite -mapoj</translation>
</message> </message>
<message> <message>
<location filename="../src/map/maplist.cpp" line="117"/> <location filename="../src/map/maplist.cpp" line="117"/>

View File

@ -414,7 +414,7 @@
<message> <message>
<location filename="../src/GUI/gui.cpp" line="380"/> <location filename="../src/GUI/gui.cpp" line="380"/>
<source>Do not show</source> <source>Do not show</source>
<translation type="unfinished"></translation> <translation>Ä näytä</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="384"/> <location filename="../src/GUI/gui.cpp" line="384"/>
@ -424,7 +424,7 @@
<message> <message>
<location filename="../src/GUI/gui.cpp" line="388"/> <location filename="../src/GUI/gui.cpp" line="388"/>
<source>Date/time</source> <source>Date/time</source>
<translation type="unfinished"></translation> <translation>Pvm/aika</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="392"/> <location filename="../src/GUI/gui.cpp" line="392"/>

View File

@ -415,7 +415,7 @@
<message> <message>
<location filename="../src/GUI/gui.cpp" line="380"/> <location filename="../src/GUI/gui.cpp" line="380"/>
<source>Do not show</source> <source>Do not show</source>
<translation type="unfinished"></translation> <translation>Не показувати</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="384"/> <location filename="../src/GUI/gui.cpp" line="384"/>
@ -425,12 +425,12 @@
<message> <message>
<location filename="../src/GUI/gui.cpp" line="388"/> <location filename="../src/GUI/gui.cpp" line="388"/>
<source>Date/time</source> <source>Date/time</source>
<translation type="unfinished"></translation> <translation>Дата/час</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="392"/> <location filename="../src/GUI/gui.cpp" line="392"/>
<source>Coordinates</source> <source>Coordinates</source>
<translation type="unfinished">Координати</translation> <translation>Координати</translation>
</message> </message>
<message> <message>
<location filename="../src/GUI/gui.cpp" line="398"/> <location filename="../src/GUI/gui.cpp" line="398"/>

View File

@ -9,7 +9,7 @@ Unicode true
; The name of the installer ; The name of the installer
Name "GPXSee" Name "GPXSee"
; Program version ; Program version
!define VERSION "8.6" !define VERSION "8.8"
; The file to write ; The file to write
OutFile "GPXSee-${VERSION}.exe" OutFile "GPXSee-${VERSION}.exe"

View File

@ -9,7 +9,7 @@ Unicode true
; The name of the installer ; The name of the installer
Name "GPXSee" Name "GPXSee"
; Program version ; Program version
!define VERSION "8.6" !define VERSION "8.8"
; The file to write ; The file to write
OutFile "GPXSee-${VERSION}_x64.exe" OutFile "GPXSee-${VERSION}_x64.exe"

View File

@ -25,6 +25,7 @@
#include <QWindow> #include <QWindow>
#include <QScreen> #include <QScreen>
#include <QStyle> #include <QStyle>
#include <QTabBar>
#include "common/programpaths.h" #include "common/programpaths.h"
#include "data/data.h" #include "data/data.h"
#include "data/poi.h" #include "data/poi.h"
@ -678,8 +679,9 @@ void GUI::createGraphTabs()
_tabs.append(new TemperatureGraph(_graphTabWidget)); _tabs.append(new TemperatureGraph(_graphTabWidget));
_tabs.append(new GearRatioGraph(_graphTabWidget)); _tabs.append(new GearRatioGraph(_graphTabWidget));
connect(_tabs.first(), SIGNAL(sliderPositionChanged(qreal)), _mapView, for (int i = 0; i < _tabs.size(); i++)
SLOT(setMarkerPosition(qreal))); connect(_tabs.at(i), SIGNAL(sliderPositionChanged(qreal)), _mapView,
SLOT(setMarkerPosition(qreal)));
} }
void GUI::createStatusBar() void GUI::createStatusBar()
@ -879,7 +881,6 @@ void GUI::loadData(const Data &data)
paths = _mapView->loadData(data); paths = _mapView->loadData(data);
GraphTab *gt = static_cast<GraphTab*>(_graphTabWidget->currentWidget()); GraphTab *gt = static_cast<GraphTab*>(_graphTabWidget->currentWidget());
int index = _graphTabWidget->currentIndex();
for (int i = 0; i < paths.count(); i++) { for (int i = 0; i < paths.count(); i++) {
PathItem *pi = paths.at(i); PathItem *pi = paths.at(i);
@ -889,8 +890,8 @@ void GUI::loadData(const Data &data)
for (int j = 0; j < graphs.count(); j++) for (int j = 0; j < graphs.count(); j++)
pi->addGraph(graphs.at(j).at(i)); pi->addGraph(graphs.at(j).at(i));
if (gt && index >= 0) { if (gt) {
pi->setGraph(index); pi->setGraph(_tabs.indexOf(gt));
pi->setMarkerPosition(gt->sliderPosition()); pi->setMarkerPosition(gt->sliderPosition());
} }
} }
@ -1380,7 +1381,7 @@ void GUI::showToolbars(bool show)
if (show) { if (show) {
Q_ASSERT(!_windowStates.isEmpty()); Q_ASSERT(!_windowStates.isEmpty());
restoreState(_windowStates.last()); restoreState(_windowStates.last());
_windowStates.pop_back(); _windowStates.removeLast();
} else { } else {
_windowStates.append(saveState()); _windowStates.append(saveState());
removeToolBar(_fileToolBar); removeToolBar(_fileToolBar);
@ -1392,17 +1393,28 @@ void GUI::showToolbars(bool show)
void GUI::showFullscreen(bool show) void GUI::showFullscreen(bool show)
{ {
if (show) { if (show) {
_windowGeometries.append(saveGeometry());
_frameStyle = _mapView->frameStyle(); _frameStyle = _mapView->frameStyle();
statusBar()->hide(); statusBar()->hide();
menuBar()->hide(); menuBar()->hide();
showToolbars(false); showToolbars(false);
_mapView->setFrameStyle(QFrame::NoFrame); _mapView->setFrameStyle(QFrame::NoFrame);
_graphTabWidget->tabBar()->hide();
#ifdef Q_OS_MAC
_graphTabWidget->setDocumentMode(true);
#endif // Q_OS_MAC
showFullScreen(); showFullScreen();
} else { } else {
Q_ASSERT(!_windowGeometries.isEmpty());
_windowGeometries.removeLast();
statusBar()->show(); statusBar()->show();
menuBar()->show(); menuBar()->show();
showToolbars(true); showToolbars(true);
_mapView->setFrameStyle(_frameStyle); _mapView->setFrameStyle(_frameStyle);
_graphTabWidget->tabBar()->show();
#ifdef Q_OS_MAC
_graphTabWidget->setDocumentMode(false);
#endif // Q_OS_MAC
showNormal(); showNormal();
} }
} }
@ -1714,19 +1726,12 @@ void GUI::graphChanged(int index)
if (index < 0) if (index < 0)
return; return;
_mapView->setGraph(index);
GraphTab *gt = static_cast<GraphTab*>(_graphTabWidget->widget(index)); GraphTab *gt = static_cast<GraphTab*>(_graphTabWidget->widget(index));
if (_lastGraphTab)
disconnect(_lastGraphTab, SIGNAL(sliderPositionChanged(qreal)),
_mapView, SLOT(setMarkerPosition(qreal)));
connect(gt, SIGNAL(sliderPositionChanged(qreal)), _mapView, _mapView->setGraph(_tabs.indexOf(gt));
SLOT(setMarkerPosition(qreal)));
if (_lastGraphTab) if (_lastGraphTab)
gt->setSliderPosition(_lastGraphTab->sliderPosition()); gt->setSliderPosition(_lastGraphTab->sliderPosition());
_lastGraphTab = gt; _lastGraphTab = gt;
} }
@ -1957,14 +1962,13 @@ void GUI::writeSettings()
settings.clear(); settings.clear();
settings.beginGroup(WINDOW_SETTINGS_GROUP); settings.beginGroup(WINDOW_SETTINGS_GROUP);
if (size() != WINDOW_SIZE_DEFAULT) if (!_windowStates.isEmpty() && !_windowGeometries.isEmpty()) {
settings.setValue(WINDOW_SIZE_SETTING, size());
if (pos() != WINDOW_POS_DEFAULT)
settings.setValue(WINDOW_POS_SETTING, pos());
if (_windowStates.isEmpty())
settings.setValue(WINDOW_STATE_SETTING, saveState());
else
settings.setValue(WINDOW_STATE_SETTING, _windowStates.first()); settings.setValue(WINDOW_STATE_SETTING, _windowStates.first());
settings.setValue(WINDOW_GEOMETRY_SETTING, _windowGeometries.first());
} else {
settings.setValue(WINDOW_STATE_SETTING, saveState());
settings.setValue(WINDOW_GEOMETRY_SETTING, saveGeometry());
}
settings.endGroup(); settings.endGroup();
settings.beginGroup(SETTINGS_SETTINGS_GROUP); settings.beginGroup(SETTINGS_SETTINGS_GROUP);
@ -2212,14 +2216,12 @@ void GUI::readSettings()
QSettings settings(qApp->applicationName(), qApp->applicationName()); QSettings settings(qApp->applicationName(), qApp->applicationName());
settings.beginGroup(WINDOW_SETTINGS_GROUP); settings.beginGroup(WINDOW_SETTINGS_GROUP);
resize(settings.value(WINDOW_SIZE_SETTING, WINDOW_SIZE_DEFAULT).toSize()); restoreGeometry(settings.value(WINDOW_GEOMETRY_SETTING).toByteArray());
move(settings.value(WINDOW_POS_SETTING, WINDOW_POS_DEFAULT).toPoint());
restoreState(settings.value(WINDOW_STATE_SETTING).toByteArray()); restoreState(settings.value(WINDOW_STATE_SETTING).toByteArray());
settings.endGroup(); settings.endGroup();
settings.beginGroup(SETTINGS_SETTINGS_GROUP); settings.beginGroup(SETTINGS_SETTINGS_GROUP);
if (settings.value(TIME_TYPE_SETTING, TIME_TYPE_DEFAULT).toInt() if (settings.value(TIME_TYPE_SETTING, TIME_TYPE_DEFAULT).toInt() == Moving)
== Moving)
_movingTimeAction->trigger(); _movingTimeAction->trigger();
else else
_totalTimeAction->trigger(); _totalTimeAction->trigger();
@ -2394,8 +2396,8 @@ void GUI::readSettings()
.toInt(); .toInt();
int mri = settings.value(PNG_MARGIN_RIGHT_SETTING, PNG_MARGIN_RIGHT_DEFAULT) int mri = settings.value(PNG_MARGIN_RIGHT_SETTING, PNG_MARGIN_RIGHT_DEFAULT)
.toInt(); .toInt();
int mbi = settings.value(PNG_MARGIN_BOTTOM_SETTING, PNG_MARGIN_BOTTOM_DEFAULT) int mbi = settings.value(PNG_MARGIN_BOTTOM_SETTING,
.toInt(); PNG_MARGIN_BOTTOM_DEFAULT).toInt();
_pngExport.margins = QMargins(mli, mti, mri, mbi); _pngExport.margins = QMargins(mli, mti, mri, mbi);
_pngExport.antialiasing = settings.value(PNG_ANTIALIASING_SETTING, _pngExport.antialiasing = settings.value(PNG_ANTIALIASING_SETTING,
PNG_ANTIALIASING_DEFAULT).toBool(); PNG_ANTIALIASING_DEFAULT).toBool();

View File

@ -242,6 +242,7 @@ private:
GraphTab *_lastGraphTab; GraphTab *_lastGraphTab;
QList<QByteArray> _windowStates; QList<QByteArray> _windowStates;
QList<QByteArray> _windowGeometries;
int _frameStyle; int _frameStyle;
PDFExport _pdfExport; PDFExport _pdfExport;

View File

@ -304,7 +304,7 @@ void PathItem::setMarkerInfo(qreal pos)
void PathItem::updateMarkerInfo() void PathItem::updateMarkerInfo()
{ {
qreal pos = _graph ? (_graph->graphType() == Time) qreal pos = _graph ? (_graph->graphType() == Time)
? _graph->distanceAtTime(_markerDistance) : _markerDistance : NAN; ? _graph->timeAtDistance(_markerDistance) : _markerDistance : NAN;
setMarkerInfo(pos); setMarkerInfo(pos);
} }

View File

@ -5,10 +5,7 @@
(QLocale::system().measurementSystem() == QLocale::ImperialSystem) (QLocale::system().measurementSystem() == QLocale::ImperialSystem)
#define WINDOW_SETTINGS_GROUP "Window" #define WINDOW_SETTINGS_GROUP "Window"
#define WINDOW_SIZE_SETTING "size" #define WINDOW_GEOMETRY_SETTING "geometry"
#define WINDOW_SIZE_DEFAULT QSize(600, 800)
#define WINDOW_POS_SETTING "pos"
#define WINDOW_POS_DEFAULT QPoint(10, 10)
#define WINDOW_STATE_SETTING "state" #define WINDOW_STATE_SETTING "state"
#define SETTINGS_SETTINGS_GROUP "Settings" #define SETTINGS_SETTINGS_GROUP "Settings"