Compare commits
9 Commits
13.18
...
3e1bddbcfd
Author | SHA1 | Date | |
---|---|---|---|
3e1bddbcfd | |||
b069d2ac3f | |||
9b46845568 | |||
f814d1f5a3 | |||
0f05dd6ba3 | |||
8a069f113e | |||
bfe31023e0 | |||
779f98a206 | |||
a660cbd463 |
@ -1,4 +1,4 @@
|
||||
version: 13.18.{build}
|
||||
version: 13.19.{build}
|
||||
|
||||
configuration:
|
||||
- Release
|
||||
|
@ -3,7 +3,7 @@ unix:!macx:!android {
|
||||
} else {
|
||||
TARGET = GPXSee
|
||||
}
|
||||
VERSION = 13.18
|
||||
VERSION = 13.19
|
||||
|
||||
|
||||
QT += core \
|
||||
|
BIN
icons/symbols/Alert.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 987 B After Width: | Height: | Size: 884 B |
BIN
icons/symbols/Checkpoint.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
icons/symbols/Danger.png
Normal file
After Width: | Height: | Size: 767 B |
BIN
icons/symbols/First Aid.png
Normal file
After Width: | Height: | Size: 606 B |
BIN
icons/symbols/First Category.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 747 B After Width: | Height: | Size: 824 B |
Before Width: | Height: | Size: 724 B After Width: | Height: | Size: 822 B |
Before Width: | Height: | Size: 724 B After Width: | Height: | Size: 822 B |
BIN
icons/symbols/Food.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
icons/symbols/Fourth Category.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
icons/symbols/Gear.png
Normal file
After Width: | Height: | Size: 976 B |
BIN
icons/symbols/Hors Category.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
icons/symbols/Info.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
icons/symbols/Left.png
Normal file
After Width: | Height: | Size: 810 B |
BIN
icons/symbols/Meeting Spot.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
icons/symbols/Obstacle.png
Normal file
After Width: | Height: | Size: 863 B |
BIN
icons/symbols/Overlook.png
Normal file
After Width: | Height: | Size: 821 B |
BIN
icons/symbols/Rest Area.png
Normal file
After Width: | Height: | Size: 918 B |
BIN
icons/symbols/Right.png
Normal file
After Width: | Height: | Size: 821 B |
BIN
icons/symbols/Second Category.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
icons/symbols/Segment End.png
Normal file
After Width: | Height: | Size: 792 B |
BIN
icons/symbols/Segment Start.png
Normal file
After Width: | Height: | Size: 724 B |
BIN
icons/symbols/Service.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
icons/symbols/Sharp Curve.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
icons/symbols/Sharp Left.png
Normal file
After Width: | Height: | Size: 942 B |
BIN
icons/symbols/Sharp Right.png
Normal file
After Width: | Height: | Size: 909 B |
BIN
icons/symbols/Shelter.png
Normal file
After Width: | Height: | Size: 764 B |
BIN
icons/symbols/Slight Left.png
Normal file
After Width: | Height: | Size: 826 B |
BIN
icons/symbols/Slight Right.png
Normal file
After Width: | Height: | Size: 825 B |
BIN
icons/symbols/Sprint.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
icons/symbols/Steep Incline.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
icons/symbols/Store.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
icons/symbols/Straight.png
Normal file
After Width: | Height: | Size: 791 B |
BIN
icons/symbols/Third Category.png
Normal file
After Width: | Height: | Size: 1.6 KiB |
BIN
icons/symbols/Toilet.png
Normal file
After Width: | Height: | Size: 989 B |
BIN
icons/symbols/Transport.png
Normal file
After Width: | Height: | Size: 1.0 KiB |
BIN
icons/symbols/U-Turn.png
Normal file
After Width: | Height: | Size: 989 B |
BIN
icons/symbols/Valley.png
Normal file
After Width: | Height: | Size: 1018 B |
BIN
icons/symbols/Water.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 747 B After Width: | Height: | Size: 824 B |
@ -37,7 +37,7 @@ Unicode true
|
||||
; The name of the installer
|
||||
Name "GPXSee"
|
||||
; Program version
|
||||
!define VERSION "13.18"
|
||||
!define VERSION "13.19"
|
||||
|
||||
; The file to write
|
||||
OutFile "GPXSee-${VERSION}_x64.exe"
|
||||
|
@ -13,15 +13,18 @@ static Qt::PenStyle styles[] = {Qt::SolidLine, Qt::DashLine, Qt::DotLine,
|
||||
|
||||
QIcon StyleComboBox::icon(Qt::PenStyle style)
|
||||
{
|
||||
QPixmap pm(iconSize());
|
||||
qreal ratio(devicePixelRatioF());
|
||||
QSize size(iconSize());
|
||||
QPixmap pm(size * ratio);
|
||||
pm.setDevicePixelRatio(ratio);
|
||||
pm.fill(Qt::transparent);
|
||||
|
||||
QBrush brush(QPalette().brush(QPalette::Active, QPalette::WindowText));
|
||||
QPen pen(brush, pm.height() / LINE_WIDTH_RATIO, style);
|
||||
QPen pen(brush, size.height() / LINE_WIDTH_RATIO, style);
|
||||
|
||||
QPainter painter(&pm);
|
||||
painter.setPen(pen);
|
||||
painter.drawLine(0, pm.height() / 2, pm.width(), pm.height() / 2);
|
||||
painter.drawLine(0, size.height() / 2, size.width(), size.height() / 2);
|
||||
|
||||
return QIcon(pm);
|
||||
}
|
||||
|
@ -106,7 +106,7 @@ Data::Data(const QString &fileName, bool tryUnknown)
|
||||
_errorLine = 0;
|
||||
|
||||
if (!file.open(QFile::ReadOnly)) {
|
||||
_errorString = qPrintable(file.errorString());
|
||||
_errorString = file.errorString();
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -64,7 +64,7 @@ public:
|
||||
SegmentData segment;
|
||||
};
|
||||
|
||||
static QMap<int, QString> coursePointDescInit()
|
||||
static QMap<int, QString> coursePointSymbolsInit()
|
||||
{
|
||||
QMap<int, QString> map;
|
||||
|
||||
@ -76,28 +76,55 @@ static QMap<int, QString> coursePointDescInit()
|
||||
map.insert(6, "Left");
|
||||
map.insert(7, "Right");
|
||||
map.insert(8, "Straight");
|
||||
map.insert(9, "First aid");
|
||||
map.insert(10, "Fourth category");
|
||||
map.insert(11, "Third category");
|
||||
map.insert(12, "Second category");
|
||||
map.insert(13, "First category");
|
||||
map.insert(14, "Hors category");
|
||||
map.insert(9, "First Aid");
|
||||
map.insert(10, "Fourth Category");
|
||||
map.insert(11, "Third Category");
|
||||
map.insert(12, "Second Category");
|
||||
map.insert(13, "First Category");
|
||||
map.insert(14, "Hors Category");
|
||||
map.insert(15, "Sprint");
|
||||
map.insert(16, "Left fork");
|
||||
map.insert(17, "Right fork");
|
||||
map.insert(18, "Middle fork");
|
||||
map.insert(19, "Slight left");
|
||||
map.insert(20, "Sharp left");
|
||||
map.insert(21, "Slight right");
|
||||
map.insert(22, "Sharp right");
|
||||
map.insert(16, "Left Fork");
|
||||
map.insert(17, "Right Fork");
|
||||
map.insert(18, "Middle Fork");
|
||||
map.insert(19, "Slight Left");
|
||||
map.insert(20, "Sharp Left");
|
||||
map.insert(21, "Slight Right");
|
||||
map.insert(22, "Sharp Right");
|
||||
map.insert(23, "U-Turn");
|
||||
map.insert(24, "Segment start");
|
||||
map.insert(25, "Segment end");
|
||||
map.insert(24, "Segment Start");
|
||||
map.insert(25, "Segment End");
|
||||
map.insert(27, "Campground");
|
||||
map.insert(28, "Aid Station");
|
||||
map.insert(29, "Rest Area");
|
||||
map.insert(30, "General Distance");
|
||||
map.insert(31, "Service");
|
||||
map.insert(32, "Energy Gel");
|
||||
map.insert(33, "Sports Drink");
|
||||
map.insert(34, "Mile Marker");
|
||||
map.insert(35, "Checkpoint");
|
||||
map.insert(36, "Shelter");
|
||||
map.insert(37, "Meeting Spot");
|
||||
map.insert(38, "Overlook");
|
||||
map.insert(39, "Toilet");
|
||||
map.insert(40, "Shower");
|
||||
map.insert(41, "Gear");
|
||||
map.insert(42, "Sharp Curve");
|
||||
map.insert(43, "Steep Incline");
|
||||
map.insert(44, "Tunnel");
|
||||
map.insert(45, "Bridge");
|
||||
map.insert(46, "Obstacle");
|
||||
map.insert(47, "Crossing");
|
||||
map.insert(48, "Store");
|
||||
map.insert(49, "Transition");
|
||||
map.insert(50, "Navaid");
|
||||
map.insert(51, "Transport");
|
||||
map.insert(52, "Alert");
|
||||
map.insert(53, "Info");
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
static QMap<int, QString> coursePointDesc = coursePointDescInit();
|
||||
static QMap<int, QString> coursePointSymbols = coursePointSymbolsInit();
|
||||
|
||||
|
||||
bool FITParser::readData(QFile *file, char *data, size_t size)
|
||||
@ -330,8 +357,8 @@ bool FITParser::parseData(CTX &ctx, const MessageDefinition *def)
|
||||
} else if (def->globalId == COURSE_POINT) {
|
||||
switch (field->id) {
|
||||
case 1:
|
||||
waypoint.setTimestamp(QDateTime::fromSecsSinceEpoch(val.toUInt()
|
||||
+ 631065600, Qt::UTC));
|
||||
waypoint.setTimestamp(QDateTime::fromSecsSinceEpoch(
|
||||
val.toUInt() + 631065600, Qt::UTC));
|
||||
break;
|
||||
case 2:
|
||||
waypoint.rcoordinates().setLat(
|
||||
@ -342,7 +369,7 @@ bool FITParser::parseData(CTX &ctx, const MessageDefinition *def)
|
||||
(val.toInt() / (double)0x7fffffff) * 180);
|
||||
break;
|
||||
case 5:
|
||||
waypoint.setDescription(coursePointDesc.value(val.toUInt()));
|
||||
waypoint.setSymbol(coursePointSymbols.value(val.toUInt()));
|
||||
break;
|
||||
case 6:
|
||||
waypoint.setName(val.toString());
|
||||
@ -386,8 +413,8 @@ bool FITParser::parseData(CTX &ctx, const MessageDefinition *def)
|
||||
}
|
||||
} else if (def->globalId == RECORD_MESSAGE) {
|
||||
if (ctx.trackpoint.coordinates().isValid()) {
|
||||
ctx.trackpoint.setTimestamp(QDateTime::fromSecsSinceEpoch(ctx.timestamp
|
||||
+ 631065600, Qt::UTC));
|
||||
ctx.trackpoint.setTimestamp(QDateTime::fromSecsSinceEpoch(
|
||||
ctx.timestamp + 631065600, Qt::UTC));
|
||||
ctx.trackpoint.setRatio(ctx.ratio);
|
||||
ctx.segment.append(ctx.trackpoint);
|
||||
ctx.trackpoint = Trackpoint();
|
||||
|
@ -603,6 +603,8 @@ bool GeoJSONParser::geometryCollection(const QJsonObject &object,
|
||||
bool GeoJSONParser::feature(const QJsonObject &object, const Projection &parent,
|
||||
QList<TrackData> &tracks, QList<Area> &areas, QVector<Waypoint> &waypoints)
|
||||
{
|
||||
if (object["geometry"].isNull())
|
||||
return true;
|
||||
if (!object["geometry"].isObject()) {
|
||||
_errorString = "Invalid/missing Feature geometry object";
|
||||
return false;
|
||||
|
@ -76,6 +76,9 @@ void GPXParser::tpExtension(Trackpoint &trackpoint)
|
||||
trackpoint.setHeartRate(number());
|
||||
else if (_reader.name() == QLatin1String("atemp"))
|
||||
trackpoint.setTemperature(number());
|
||||
else if (_reader.name() == QLatin1String("wtemp")
|
||||
&& !trackpoint.hasTemperature())
|
||||
trackpoint.setTemperature(number());
|
||||
else if (_reader.name() == QLatin1String("cad"))
|
||||
trackpoint.setCadence(number());
|
||||
else if (_reader.name() == QLatin1String("speed"))
|
||||
|