mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-07-18 12:54:23 +02:00
Compare commits
22 Commits
Author | SHA1 | Date | |
---|---|---|---|
d8b54ac342 | |||
60b33064a7 | |||
2efc6fb6d3 | |||
8c9180190a | |||
6839119794 | |||
05f23de1ed | |||
9a0344adac | |||
fdeb24a196 | |||
a986293f20 | |||
ec0b0adba0 | |||
0f670f9ddd | |||
ce59f13de7 | |||
b59112f74e | |||
17b3602fda | |||
c0928097cc | |||
e709fad764 | |||
fb566ae163 | |||
3d8a4cc6b7 | |||
4eb44a53f7 | |||
b61c39ea46 | |||
4767be1972 | |||
ee9e17e31c |
@ -1,4 +1,4 @@
|
||||
version: 7.18.{build}
|
||||
version: 7.19.{build}
|
||||
configuration: Release
|
||||
platform: Any CPU
|
||||
environment:
|
||||
|
@ -3,7 +3,7 @@ unix:!macx {
|
||||
} else {
|
||||
TARGET = GPXSee
|
||||
}
|
||||
VERSION = 7.18
|
||||
VERSION = 7.19
|
||||
|
||||
QT += core \
|
||||
gui \
|
||||
|
@ -1147,12 +1147,12 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="67"/>
|
||||
<source>Non-HiDPI maps are loaded as HiDPI maps. The map is sharp but map objects are small/hard to read.</source>
|
||||
<translation>Les cartes qui n'ont pas de résolution élevée sont chargées comme une carte à résolution élevée. La carte est nette mais ses symboles sont petits ou difficiles à lire.</translation>
|
||||
<translation>Les cartes qui n'ont pas de résolution élevée sont chargées comme une carte à résolution élevée. La carte est nette mais ses symboles sont petits et moins lisible.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="69"/>
|
||||
<source>Non-HiDPI maps are loaded such as they are. Map objects have the expected size but the map is blurry.</source>
|
||||
<translation>Les cartes qui n'ont pas de résolution élevée sont chargées telles quelles. Les symboles de la carte ont leurs tailles attendues mais la carte est floue.</translation>
|
||||
<translation>Les cartes qui n'ont pas de résolution élevée sont chargées telles quelles. Les symboles de la carte ont une taille adaptée mais la carte est floue.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="104"/>
|
||||
@ -1276,7 +1276,7 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="352"/>
|
||||
<source>Automatic</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Automatique</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="366"/>
|
||||
@ -1399,7 +1399,7 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="353"/>
|
||||
<source>Custom</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Personnalisé</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="477"/>
|
||||
@ -1884,7 +1884,7 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/waypointitem.cpp" line="44"/>
|
||||
<source>Address</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Adresse</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/waypointitem.cpp" line="55"/>
|
||||
|
@ -1312,12 +1312,12 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="352"/>
|
||||
<source>Automatic</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Автоматичне</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="353"/>
|
||||
<source>Custom</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Користувацьке</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/optionsdialog.cpp" line="366"/>
|
||||
|
@ -3,9 +3,12 @@ Name=GPXSee
|
||||
Comment=GPS log file viewer and analyzer
|
||||
Comment[cz]=Prohlížeč a analyzátor GPS logů
|
||||
Comment[fi]=Ohjelma GPS-lokien katseluun ja analysointiin
|
||||
Comment[fr]=Visualisation et analyse de fichier GPS
|
||||
Comment[pl]=Przeglądarka i analizator plików dziennika GPS
|
||||
Comment[ru]=Программа для просмотра и анализа GPS логов
|
||||
Comment[sv]=GPS-loggfilsläsare och analysator
|
||||
Comment[tr]=GPS günlük dosyası görüntüleyici ve analizcisi
|
||||
Comment[uk]=Переглядач та аналізатор GPS логів
|
||||
Exec=gpxsee %F
|
||||
Icon=gpxsee
|
||||
Terminal=false
|
||||
|
@ -7,7 +7,7 @@
|
||||
; The name of the installer
|
||||
Name "GPXSee"
|
||||
; Program version
|
||||
!define VERSION "7.18"
|
||||
!define VERSION "7.19"
|
||||
|
||||
; The file to write
|
||||
OutFile "GPXSee-${VERSION}.exe"
|
||||
|
@ -7,7 +7,7 @@
|
||||
; The name of the installer
|
||||
Name "GPXSee"
|
||||
; Program version
|
||||
!define VERSION "7.18"
|
||||
!define VERSION "7.19"
|
||||
|
||||
; The file to write
|
||||
OutFile "GPXSee-${VERSION}_x64.exe"
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map xmlns="http://www.gpxsee.org/map/1.3">
|
||||
<name>4UMaps</name>
|
||||
<url>https://4umaps.com/$z/$x/$y.png</url>
|
||||
<url>https://tileserver.4umaps.com/$z/$x/$y.png</url>
|
||||
<zoom min="2" max="15"/>
|
||||
<bounds bottom="-65"/>
|
||||
<copyright>Map data: © OpenStreetMap contributors (ODbL) | Rendering: © 4UMaps.eu</copyright>
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<map xmlns="http://www.gpxsee.org/map/1.3">
|
||||
<name>Open Street Map</name>
|
||||
<url>http://tile.openstreetmap.org/$z/$x/$y.png</url>
|
||||
<url>https://tile.openstreetmap.org/$z/$x/$y.png</url>
|
||||
<copyright>Map data: © OpenStreetMap contributors (ODbL) | Rendering: © OpenStreetMap (CC-BY-SA)</copyright>
|
||||
</map>
|
||||
|
@ -46,3 +46,9 @@ void GraphicsScene::helpEvent(QGraphicsSceneHelpEvent *event)
|
||||
|
||||
/* No need to process QGraphicsScene::helpEvent() */
|
||||
}
|
||||
|
||||
void GraphicsScene::clear()
|
||||
{
|
||||
Popup::clear();
|
||||
QGraphicsScene::clear();
|
||||
}
|
||||
|
@ -18,6 +18,9 @@ class GraphicsScene : public QGraphicsScene
|
||||
public:
|
||||
GraphicsScene(QObject *parent = 0) : QGraphicsScene(parent) {}
|
||||
|
||||
public slots:
|
||||
void clear();
|
||||
|
||||
protected:
|
||||
void helpEvent(QGraphicsSceneHelpEvent *event);
|
||||
|
||||
|
@ -163,3 +163,9 @@ void Popup::show(const QPoint &pos, const QString &text, QWidget *w)
|
||||
PopupLabel::_instance->place(pos, w);
|
||||
PopupLabel::_instance->showNormal();
|
||||
}
|
||||
|
||||
void Popup::clear()
|
||||
{
|
||||
if (PopupLabel::_instance)
|
||||
delete PopupLabel::_instance;
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ class Popup
|
||||
{
|
||||
public:
|
||||
static void show(const QPoint &pos, const QString &text, QWidget *w);
|
||||
static void clear();
|
||||
};
|
||||
|
||||
#endif // POPUP_H
|
||||
|
@ -10,9 +10,7 @@ inline double toWGS32(qint32 v)
|
||||
|
||||
inline double toWGS24(qint32 v)
|
||||
{
|
||||
return (v < 0x800000)
|
||||
? (double)v * 360.0 / (double)(1U<<24)
|
||||
: (double)(v - 0x1000000) * 360.0 / (double)(1<<24);
|
||||
return toWGS32(v<<8);
|
||||
}
|
||||
|
||||
#endif // GARMIN_H
|
||||
|
@ -1,3 +1,4 @@
|
||||
#include <cstring>
|
||||
#include <QDataStream>
|
||||
#include <QTextCodec>
|
||||
#include <QtEndian>
|
||||
@ -169,15 +170,16 @@ static quint32 readTranslatedObjects(QDataStream &stream, QTextCodec *codec,
|
||||
QList<TranslatedString> &objects)
|
||||
{
|
||||
qint32 size = 0, ret;
|
||||
char lang[2];
|
||||
char lang[3];
|
||||
|
||||
memset(lang, 0, sizeof(lang));
|
||||
objects.clear();
|
||||
|
||||
stream >> size;
|
||||
ret = size + 4;
|
||||
while (stream.status() == QDataStream::Ok && size > 0) {
|
||||
QString str;
|
||||
stream.readRawData(lang, sizeof(lang));
|
||||
stream.readRawData(lang, sizeof(lang) - 1);
|
||||
size -= readString(stream, codec, str) + 2;
|
||||
objects.append(TranslatedString(lang, str));
|
||||
}
|
||||
@ -634,9 +636,10 @@ static void readPOIDatabase(QDataStream &stream, QTextCodec *codec,
|
||||
}
|
||||
|
||||
bool GPIParser::readData(QDataStream &stream, QTextCodec *codec,
|
||||
QVector<Waypoint> &waypoints, QList<Area> &polygons, const QString &fileName,
|
||||
int &imgId)
|
||||
QVector<Waypoint> &waypoints, QList<Area> &polygons, const QString &fileName)
|
||||
{
|
||||
int imgId = 0;
|
||||
|
||||
while (stream.status() == QDataStream::Ok) {
|
||||
switch (nextHeaderType(stream)) {
|
||||
case 0x09: // POI database
|
||||
@ -726,11 +729,9 @@ bool GPIParser::parse(QFile *file, QList<TrackData> &tracks,
|
||||
{
|
||||
Q_UNUSED(tracks);
|
||||
Q_UNUSED(routes);
|
||||
Q_UNUSED(polygons);
|
||||
QDataStream stream(file);
|
||||
QTextCodec *codec = 0;
|
||||
quint32 ebs;
|
||||
int imgId = 0;
|
||||
|
||||
stream.setByteOrder(QDataStream::LittleEndian);
|
||||
|
||||
@ -741,9 +742,8 @@ bool GPIParser::parse(QFile *file, QList<TrackData> &tracks,
|
||||
CryptDevice dev(stream.device(), 0xf870b5, ebs);
|
||||
QDataStream cryptStream(&dev);
|
||||
cryptStream.setByteOrder(QDataStream::LittleEndian);
|
||||
return readData(cryptStream, codec, waypoints, polygons, file->fileName(),
|
||||
imgId);
|
||||
return readData(cryptStream, codec, waypoints, polygons,
|
||||
file->fileName());
|
||||
} else
|
||||
return readData(stream, codec, waypoints, polygons, file->fileName(),
|
||||
imgId);
|
||||
return readData(stream, codec, waypoints, polygons, file->fileName());
|
||||
}
|
||||
|
@ -19,7 +19,7 @@ private:
|
||||
bool readGPIHeader(QDataStream &stream, QTextCodec **codec);
|
||||
bool readData(QDataStream &stream, QTextCodec *codec,
|
||||
QVector<Waypoint> &waypoints, QList<Area> &polygons,
|
||||
const QString &fileName, int &imgId);
|
||||
const QString &fileName);
|
||||
|
||||
QString _errorString;
|
||||
};
|
||||
|
@ -151,7 +151,7 @@ Track::Track(const TrackData &data) : _data(data), _pause(0)
|
||||
qreal pauseSpeed;
|
||||
|
||||
if (_automaticPause) {
|
||||
pauseSpeed = (avg(seg.speed) > 2.8) ? 0.55 : 0.15;
|
||||
pauseSpeed = (avg(seg.speed) > 2.8) ? 0.40 : 0.15;
|
||||
pauseInterval = 10;
|
||||
} else {
|
||||
pauseSpeed = _pauseSpeed;
|
||||
@ -163,7 +163,7 @@ Track::Track(const TrackData &data) : _data(data), _pause(0)
|
||||
if (seg.speed.at(j) > pauseSpeed)
|
||||
ss = -1;
|
||||
else if (ss < 0)
|
||||
ss = j;
|
||||
ss = j-1;
|
||||
|
||||
if (ss >= 0 && seg.time.at(j) > seg.time.at(ss) + pauseInterval) {
|
||||
int l = qMax(ss, la);
|
||||
|
@ -50,8 +50,9 @@ IMG::IMG(const QString &fileName)
|
||||
CHECK(_file.seek(0x49) && read(d1, sizeof(d1)) && _file.seek(0x61)
|
||||
&& readValue(e1) && readValue(e2) && _file.seek(0x65)
|
||||
&& read(d2, sizeof(d2)));
|
||||
|
||||
QByteArray nba(QByteArray(d1, sizeof(d1)) + QByteArray(d2, sizeof(d2)));
|
||||
_name = QString(nba).trimmed();
|
||||
_name = QString::fromLatin1(nba.constData(), nba.size()-1).trimmed();
|
||||
_blockSize = 1 << (e1 + e2);
|
||||
_blockCache.setMaxCost(CACHE_SIZE / _blockSize);
|
||||
|
||||
|
@ -50,9 +50,8 @@ static QString capitalize(const QString &str)
|
||||
}
|
||||
|
||||
|
||||
bool LBLFile::init()
|
||||
bool LBLFile::init(Handle &hdl)
|
||||
{
|
||||
Handle hdl;
|
||||
quint16 codepage;
|
||||
quint8 multiplier, poiMultiplier;
|
||||
|
||||
@ -165,7 +164,7 @@ Label LBLFile::label8b(Handle &hdl, quint32 offset) const
|
||||
|
||||
Label LBLFile::label(Handle &hdl, quint32 offset, bool poi)
|
||||
{
|
||||
if (!_multiplier && !init())
|
||||
if (!_multiplier && !init(hdl))
|
||||
return QString();
|
||||
|
||||
quint32 labelOffset;
|
||||
|
@ -19,7 +19,7 @@ public:
|
||||
Label label(Handle &hdl, quint32 offset, bool poi = false);
|
||||
|
||||
private:
|
||||
bool init();
|
||||
bool init(Handle &hdl);
|
||||
|
||||
Label label6b(Handle &hdl, quint32 offset) const;
|
||||
Label label8b(Handle &hdl, quint32 offset) const;
|
||||
|
@ -1,8 +1,7 @@
|
||||
#include "netfile.h"
|
||||
|
||||
bool NETFile::init()
|
||||
bool NETFile::init(Handle &hdl)
|
||||
{
|
||||
Handle hdl;
|
||||
quint8 multiplier;
|
||||
|
||||
if (!(seek(hdl, _gmpOffset + 0x15) && readUInt32(hdl, _offset)
|
||||
@ -16,7 +15,7 @@ bool NETFile::init()
|
||||
|
||||
bool NETFile::lblOffset(Handle &hdl, quint32 netOffset, quint32 &lblOffset)
|
||||
{
|
||||
if (!_multiplier && !init())
|
||||
if (!_multiplier && !init(hdl))
|
||||
return false;
|
||||
|
||||
if (!(seek(hdl, _offset + netOffset * _multiplier)
|
||||
|
@ -13,7 +13,7 @@ public:
|
||||
bool lblOffset(Handle &hdl, quint32 netOffset, quint32 &lblOffset);
|
||||
|
||||
private:
|
||||
bool init();
|
||||
bool init(Handle &hdl);
|
||||
|
||||
quint32 _offset;
|
||||
quint32 _size;
|
||||
|
@ -119,9 +119,8 @@ bool RGNFile::DeltaStream::sign(int &val)
|
||||
}
|
||||
|
||||
|
||||
bool RGNFile::init()
|
||||
bool RGNFile::init(Handle &hdl)
|
||||
{
|
||||
Handle hdl;
|
||||
quint16 hdrLen;
|
||||
|
||||
if (!(seek(hdl, _gmpOffset) && readUInt16(hdl, hdrLen)
|
||||
@ -395,7 +394,7 @@ void RGNFile::objects(const RectC &rect, const SubDiv *subdiv, LBLFile *lbl,
|
||||
{
|
||||
Handle rgnHdl, lblHdl, netHdl;
|
||||
|
||||
if (!_init && !init())
|
||||
if (!_init && !init(rgnHdl))
|
||||
return;
|
||||
|
||||
QVector<RGNFile::Segment> seg(segments(rgnHdl, subdiv));
|
||||
@ -427,7 +426,7 @@ void RGNFile::extObjects(const RectC &rect, const SubDiv *subdiv, LBLFile *lbl,
|
||||
{
|
||||
Handle rgnHdl, lblHdl;
|
||||
|
||||
if (!_init && !init())
|
||||
if (!_init && !init(rgnHdl))
|
||||
return;
|
||||
|
||||
if (polygons && subdiv->polygonsOffset() != subdiv->polygonsEnd()) {
|
||||
|
@ -93,7 +93,7 @@ private:
|
||||
quint32 _lonBits, _latBits, _readBits;
|
||||
};
|
||||
|
||||
bool init();
|
||||
bool init(Handle &hdl);
|
||||
|
||||
QVector<Segment> segments(Handle &hdl, const SubDiv *subdiv) const;
|
||||
bool polyObjects(const RectC &rect, Handle &hdl, const SubDiv *subdiv,
|
||||
|
@ -966,7 +966,7 @@ const Style::Point &Style::point(quint32 type) const
|
||||
{
|
||||
static Point null;
|
||||
|
||||
QMap<quint16, Point>::const_iterator it = _points.find(type);
|
||||
QMap<quint32, Point>::const_iterator it = _points.find(type);
|
||||
return (it == _points.constEnd()) ? null : *it;
|
||||
}
|
||||
|
||||
|
@ -142,7 +142,7 @@ private:
|
||||
|
||||
QMap<quint32, Line> _lines;
|
||||
QMap<quint32, Polygon> _polygons;
|
||||
QMap<quint16, Point> _points;
|
||||
QMap<quint32, Point> _points;
|
||||
QList<quint32> _drawOrder;
|
||||
};
|
||||
|
||||
|
@ -100,6 +100,8 @@ static QPainterPath textPath(const QPolygonF &path, qreal textWidth,
|
||||
qreal charWidth, const QRectF &tileRect)
|
||||
{
|
||||
QList<QLineF> lines(lineString(path, tileRect));
|
||||
if (lines.isEmpty())
|
||||
return QPainterPath();
|
||||
qreal length = 0;
|
||||
qreal angle = lines.first().angle();
|
||||
int last = 0;
|
||||
|
Reference in New Issue
Block a user