cet.h   cet.h 
skipping to change at line 25 skipping to change at line 25
GNU General Public License for more details. GNU General Public License for more details.
You should have received a copy of the GNU General Public License You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA
*/ */
#ifndef CET_H #ifndef CET_H
#define CET_H #define CET_H
#include <ctype.h>
#include <stdio.h>
#define CET_ERROR 1 #define CET_ERROR 1
#define CET_SUCCESS 0 #define CET_SUCCESS 0
typedef struct cet_ucs4_link_s { typedef struct cet_ucs4_link_s {
int value; /* UCS-4 value */ int value; /* UCS-4 value */
short origin; /* associeted character */ short origin; /* associeted character */
} cet_ucs4_link_t; } cet_ucs4_link_t;
typedef struct cet_cs_vec_s { typedef struct cet_cs_vec_s {
const char* name; /* name of character set */ const char* name; /* name of character set */
 End of changes. 1 change blocks. 
3 lines changed or deleted 0 lines changed or added


 cet_util.h   cet_util.h 
skipping to change at line 25 skipping to change at line 25
GNU General Public License for more details. GNU General Public License for more details.
You should have received a copy of the GNU General Public License You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA
*/ */
#ifndef CET_UTIL_H #ifndef CET_UTIL_H
#define CET_UTIL_H #define CET_UTIL_H
#include <ctype.h>
#include <stdio.h>
#if HAVE_CONFIG_H #if HAVE_CONFIG_H
#include "config.h" #include "config.h"
#endif #endif
#include "cet.h" #include "cet.h"
cet_cs_vec_t* cet_find_cs_by_name(const char* name); cet_cs_vec_t* cet_find_cs_by_name(const char* name);
void cet_register(void); void cet_register(void);
void cet_deregister(void); void cet_deregister(void);
/* short hand transmissions */ /* short hand transmissions */
char* cet_str_utf8_to_cp1252(const char* src); char* cet_str_utf8_to_cp1252(const char* src);
char* cet_str_cp1252_to_utf8(const char* src); char* cet_str_cp1252_to_utf8(const char* src);
extern cet_cs_vec_t cet_cs_vec_cp1252; extern cet_cs_vec_t cet_cs_vec_cp1252;
char* cet_str_iso8859_1_to_utf8(const char* src); char* cet_str_iso8859_1_to_utf8(const char* src);
char* cet_str_utf8_to_iso8859_1(const char* src); char* cet_str_utf8_to_iso8859_1(const char* src);
extern cet_cs_vec_t cet_cs_vec_iso8859_1; extern cet_cs_vec_t cet_cs_vec_iso8859_1;
char* cet_str_iso8859_15_to_utf8(const char* src);
char* cet_str_utf8_to_iso8859_15(const char* src);
extern const cet_cs_vec_t cet_cs_vec_iso8859_15;
char* cet_str_utf8_to_us_ascii(const char* src);
char* cet_str_us_ascii_to_utf8(const char* src);
extern cet_cs_vec_t cet_cs_vec_ansi_x3_4_1968; extern cet_cs_vec_t cet_cs_vec_ansi_x3_4_1968;
short* cet_str_utf8_to_uni(const char* src, int* length); short* cet_str_utf8_to_uni(const char* src, int* length);
extern cet_cs_vec_t cet_cs_vec_utf8; extern cet_cs_vec_t cet_cs_vec_utf8;
/* helpers */ /* helpers */
char* cet_str_uni_to_any(const short* src, int length, const cet_cs_vec_t* dest_vec);
char* cet_str_any_to_any(const char* src, const cet_cs_vec_t* src_vec, cons t cet_cs_vec_t* dest_vec); char* cet_str_any_to_any(const char* src, const cet_cs_vec_t* src_vec, cons t cet_cs_vec_t* dest_vec);
int cet_valid_char(const char* src, const cet_cs_vec_t* vec);
int cet_gbfprintf(gbfile* stream, const cet_cs_vec_t* src_vec, const char* fmt, ...); int cet_gbfprintf(gbfile* stream, const cet_cs_vec_t* src_vec, const char* fmt, ...);
/* cet_convert_string: !!! ONLY VALID WITHIN 'cet_convert_strings' process !!! */ /* cet_convert_string: !!! ONLY VALID WITHIN 'cet_convert_strings' process !!! */
char* cet_convert_string(char* str); char* cet_convert_string(char* str);
const char* cet_convert_string(const QString& str); const char* cet_convert_string(const QString& str);
/* gpsbabel extensions */ /* gpsbabel extensions */
void cet_convert_init(const char* cs_name, const int force); void cet_convert_init(const char* cs_name, const int force);
 End of changes. 4 change blocks. 
10 lines changed or deleted 0 lines changed or added


 config.h   config.h 
skipping to change at line 86 skipping to change at line 86
/* Define to the address where bug reports for this package should be sent. */ /* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT "BUG-REPORT-ADDRESS" #define PACKAGE_BUGREPORT "BUG-REPORT-ADDRESS"
/* Define to the full name of this package. */ /* Define to the full name of this package. */
#define PACKAGE_NAME "GPSBabel" #define PACKAGE_NAME "GPSBabel"
/* Define to the release name of this package. */ /* Define to the release name of this package. */
#define PACKAGE_RELEASE "" #define PACKAGE_RELEASE ""
/* Define to the full name and version of this package. */ /* Define to the full name and version of this package. */
#define PACKAGE_STRING "GPSBabel 1.5.1" #define PACKAGE_STRING "GPSBabel 1.5.2"
/* Define to the one symbol short name of this package. */ /* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "gpsbabel" #define PACKAGE_TARNAME "gpsbabel"
/* Define to the home page for this package. */ /* Define to the home page for this package. */
#define PACKAGE_URL "" #define PACKAGE_URL ""
/* Define to the version of this package. */ /* Define to the version of this package. */
#define PACKAGE_VERSION "1.5.1" #define PACKAGE_VERSION "1.5.2"
/* 1 to enable Palm PDB support */ /* 1 to enable Palm PDB support */
#define PDBFMTS_ENABLED 1 #define PDBFMTS_ENABLED 1
/* 1 to enable shapefile support */ /* 1 to enable shapefile support */
#define SHAPELIB_ENABLED 1 #define SHAPELIB_ENABLED 1
/* Define to 1 if you have the ANSI C header files. */ /* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1 #define STDC_HEADERS 1
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added


 csv_util.h   csv_util.h 
skipping to change at line 21 skipping to change at line 21
but WITHOUT ANY WARRANTY; without even the implied warranty of but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details. GNU General Public License for more details.
You should have received a copy of the GNU General Public License You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA
*/ */
#include <QtCore/QStringList>
/* function prototypes */ /* function prototypes */
char* char*
#ifndef DEBUG_MEM #ifndef DEBUG_MEM
csv_stringtrim(const char* string, const char* enclosure, int strip_max); csv_stringtrim(const char* string, const char* enclosure, int strip_max);
#else #else
CSV_STRINGTRIM(const char* string, const char* enclosure, int strip_max, DE BUG_PARAMS); CSV_STRINGTRIM(const char* string, const char* enclosure, int strip_max, DE BUG_PARAMS);
#define csv_stringtrim( s, e,m ) CSV_STRINGTRIM( s, e, m, __FILE__, __LINE_ _) #define csv_stringtrim( s, e,m ) CSV_STRINGTRIM( s, e, m, __FILE__, __LINE_ _)
#endif #endif
QString csv_stringtrim(const QString& source, const QString& enclosure); QString csv_stringtrim(const QString& source, const QString& enclosure);
skipping to change at line 91 skipping to change at line 93
#define OPTIONS_OPTIONAL 3 #define OPTIONS_OPTIONAL 3
typedef struct field_map { typedef struct field_map {
queue Q; queue Q;
char* key; char* key;
char* val; char* val;
char* printfc; char* printfc;
int hashed_key; int hashed_key;
int options; int options;
} field_map_t; } field_map_t;
/* a queuing struct for prologues / epilogues */
typedef struct ogue {
queue Q;
char* val;
} ogue_t;
/* something to map config file constants to chars */ /* something to map config file constants to chars */
typedef struct char_map { typedef struct char_map {
const char* key; const char* key;
const char* chars; const char* chars;
} char_map_t; } char_map_t;
/* /*
* a type describing all the wonderful elements of xcsv files, in a * a Class describing all the wonderful elements of xcsv files, in a
* nutshell. * nutshell.
* It completely shows that this began life as a C struct...baby steps.
*/ */
typedef struct { class XcsvFile {
int is_internal; /* bool - is internal (1) or parsed (0) */ public:
XcsvFile();
int prologue_lines; /* # of lines to ignore at top of the file * bool is_internal; /* bool - is internal (1) or parsed (0) */
/
int epilogue_lines; /* # of lines to ignore at bottom of file */
/* header lines for writing at the top of the file. */ /* header lines for writing at the top of the file. */
queue prologue; QStringList prologue;
/* footer lines for writing at the bottom of the file. */ /* footer lines for writing at the bottom of the file. */
queue epilogue; QStringList epilogue;
char* field_delimiter; /* comma, quote, etc... */ QString field_delimiter; /* comma, quote, etc... */
char* field_encloser; /* doublequote, etc... */ QString field_encloser; /* doublequote, etc... */
char* record_delimiter; /* newline, c/r, etc... */ QString record_delimiter; /* newline, c/r, etc... */
char* badchars; /* characters we never write to output */ QString badchars; /* characters we never write to output */
queue ifield; /* input field mapping */ queue ifield; /* input field mapping */
queue* ofield; /* output field mapping */ queue* ofield; /* output field mapping */
int ifield_ct; /* actual # of ifields */ int ifield_ct; /* actual # of ifields */
int ofield_ct; /* actual # of ofields */ int ofield_ct; /* actual # of ofields */
gbfile* xcsvfp; /* ptr to current *open* data file */ gbfile* xcsvfp; /* ptr to current *open* data file */
char* fname; /* ptr to filename of above. */ QString fname; /* ptr to filename of above. */
char* description; /* Description for help text */ char* description; /* Description for help text */
char* extension; /* preferred filename extension (for wrapper s)*/ char* extension; /* preferred filename extension (for wrapper s)*/
short_handle mkshort_handle;/* handle for mkshort() */ short_handle mkshort_handle;/* handle for mkshort() */
ff_type type; /* format type for GUI wrappers. */ ff_type type; /* format type for GUI wrappers. */
int gps_datum; /* result of GPS_Lookup_Datum_Index */ int gps_datum; /* result of GPS_Lookup_Datum_Index */
gpsdata_type datatype; /* can be wptdata, rtedata or trkdata */ gpsdata_type datatype; /* can be wptdata, rtedata or trkdata */
/* ... or ZERO to keep the old behaviour */ /* ... or ZERO to keep the old behaviour */
} xcsv_file_t; };
/************************************************************************** **/ /************************************************************************** **/
/* obligatory global struct */ /* obligatory global struct */
/************************************************************************** **/ /************************************************************************** **/
extern xcsv_file_t xcsv_file; extern XcsvFile xcsv_file;
 End of changes. 13 change blocks. 
20 lines changed or deleted 16 lines changed or added


 datetime.h   datetime.h 
skipping to change at line 95 skipping to change at line 95
qint64 msecs = thisutc.time().msecsTo(dtutc.time()); qint64 msecs = thisutc.time().msecsTo(dtutc.time());
return days * (1000 * 3600 * 24) + msecs; return days * (1000 * 3600 * 24) + msecs;
} }
// Qt 4.6 and under doesn't have toMSecsSinceEpoch. // Qt 4.6 and under doesn't have toMSecsSinceEpoch.
qint64 toMSecsSinceEpoch() const { qint64 toMSecsSinceEpoch() const {
QDateTime epoch = QDateTime(QDate(1970, 1, 1), QTime(0, 0, 0, 0), Qt::U TC); QDateTime epoch = QDateTime(QDate(1970, 1, 1), QTime(0, 0, 0, 0), Qt::U TC);
return -msecsTo(epoch); return -msecsTo(epoch);
} }
// This was added in Qt 4.7, but it's easy enough to knock out here.
void setMSecsSinceEpoch(qint64 msecs) {
int ddays = msecs / 86400000;
msecs %= 86400000;
setDate(QDate(1970, 1, 1).addDays(ddays));
setTime(QTime(0,0).addMSecs(msecs));
}
// Like toString, but with subsecond time that's included only when // Like toString, but with subsecond time that's included only when
// the trailing digits aren't .000. Always UTC. // the trailing digits aren't .000. Always UTC.
QString toPrettyString() const { QString toPrettyString() const {
const char* format; const char* format;
if (time().msec()) { if (time().msec()) {
format = "yyyy-MM-ddTHH:mm:ss.zzzZ"; format = "yyyy-MM-ddTHH:mm:ss.zzzZ";
} else { } else {
format = "yyyy-MM-ddTHH:mm:ssZ"; format = "yyyy-MM-ddTHH:mm:ssZ";
} }
return toUTC().toString(format); return toUTC().toString(format);
 End of changes. 1 change blocks. 
0 lines changed or deleted 8 lines changed or added


 defs.h   defs.h 
skipping to change at line 34 skipping to change at line 34
#if HAVE_CONFIG_H #if HAVE_CONFIG_H
#include "config.h" #include "config.h"
#endif #endif
#include "queue.h" #include "queue.h"
#if HAVE_LIBZ #if HAVE_LIBZ
#include <zlib.h> #include <zlib.h>
#elif !ZLIB_INHIBITED #elif !ZLIB_INHIBITED
#include "zlib/zlib.h" #include "zlib/zlib.h"
#endif #endif
#include "gbfile.h" #include "gbfile.h"
#include "cet.h"
#include "cet_util.h"
#include "inifile.h" #include "inifile.h"
#include "session.h" #include "session.h"
#include <QtCore/QString> #include <QtCore/QString>
#include <QtCore/QDebug>
#include <QtCore/QTextStream>
# include "src/core/datetime.h" # include "src/core/datetime.h"
#define CSTR(qstr) (qstr.toUtf8().constData()) #define CSTR(qstr) (qstr.toUtf8().constData())
#define STRFROMUNICODE(qstr) (global_opts.codec->fromUnicode(qstr).constDat
a())
#define STRTOUNICODE(cstr) (global_opts.codec->toUnicode(cstr))
/* /*
* Amazingly, this constant is not specified in the standard... * Amazingly, this constant is not specified in the standard...
*/ */
#ifndef M_PI #ifndef M_PI
# define M_PI 3.14159265358979323846 # define M_PI 3.14159265358979323846
#endif #endif
#ifndef FALSE #ifndef FALSE
# define FALSE false # define FALSE false
skipping to change at line 198 skipping to change at line 196
int synthesize_shortnames; int synthesize_shortnames;
int debug_level; int debug_level;
gpsdata_type objective; gpsdata_type objective;
unsigned int masked_objective; unsigned int masked_objective;
int verbose_status; /* set by GUI wrappers for status */ int verbose_status; /* set by GUI wrappers for status */
int smart_icons; int smart_icons;
int smart_names; int smart_names;
cet_cs_vec_t* charset; cet_cs_vec_t* charset;
char* charset_name; char* charset_name;
inifile_t* inifile; inifile_t* inifile;
QTextCodec* codec;
} global_options; } global_options;
extern global_options global_opts; extern global_options global_opts;
extern const char gpsbabel_version[]; extern const char gpsbabel_version[];
extern time_t gpsbabel_now; /* gpsbabel startup-time; initialized in mai n.c with time() */ extern time_t gpsbabel_now; /* gpsbabel startup-time; initialized in mai n.c with time() */
extern time_t gpsbabel_time; /* gpsbabel startup-time; initialized in mai n.c with current_time(), ! ZERO within testo ! */ extern time_t gpsbabel_time; /* gpsbabel startup-time; initialized in mai n.c with current_time(), ! ZERO within testo ! */
extern int geocaches_present; extern int geocaches_present;
class QTextStream;
extern QTextStream cerr; extern QTextStream cerr;
#define MILLI_TO_MICRO(t) (t * 1000) /* Milliseconds to Microseconds */ #define MILLI_TO_MICRO(t) (t * 1000) /* Milliseconds to Microseconds */
#define MICRO_TO_MILLI(t) (t / 1000) /* Microseconds to Milliseconds*/ #define MICRO_TO_MILLI(t) (t / 1000) /* Microseconds to Milliseconds*/
#define CENTI_TO_MICRO(t) (t * 10000) /* Centiseconds to Microseconds */ #define CENTI_TO_MICRO(t) (t * 10000) /* Centiseconds to Microseconds */
#define MICRO_TO_CENTI(t) (t / 10000) /* Centiseconds to Microseconds */ #define MICRO_TO_CENTI(t) (t / 10000) /* Centiseconds to Microseconds */
/* Short or Long XML Times */ /* Short or Long XML Times */
#define XML_SHORT_TIME 1 #define XML_SHORT_TIME 1
#define XML_LONG_TIME 2 #define XML_LONG_TIME 2
skipping to change at line 943 skipping to change at line 943
// FIXME: case_ignore_strcmp() and case_ignore_strncmp() should probably // FIXME: case_ignore_strcmp() and case_ignore_strncmp() should probably
// just be replaced at the call sites. These shims are just here to make // just be replaced at the call sites. These shims are just here to make
// them more accomidating of QString input. // them more accomidating of QString input.
inline int inline int
case_ignore_strcmp(const QString& s1, const QString& s2) { case_ignore_strcmp(const QString& s1, const QString& s2) {
return QString::compare(s1, s2, Qt::CaseInsensitive); return QString::compare(s1, s2, Qt::CaseInsensitive);
} }
// In 95% of the callers, this could be s1.startsWith(s2)... // In 95% of the callers, this could be s1.startsWith(s2)...
inline int case_ignore_strncmp(const QString& s1, const QString& s2, int n) { inline int case_ignore_strncmp(const QString& s1, const QString& s2, int n) {
return s1.left(n).compare(s2, Qt::CaseInsensitive); return s1.left(n).compare(s2.left(n), Qt::CaseInsensitive);
} }
int str_match(const char* str, const char* match); int str_match(const char* str, const char* match);
int case_ignore_str_match(const char* str, const char* match); int case_ignore_str_match(const char* str, const char* match);
QString strenquote(const QString& str, const QChar quot_char); QString strenquote(const QString& str, const QChar quot_char);
char* strsub(const char* s, const char* search, const char* replace); char* strsub(const char* s, const char* search, const char* replace);
char* gstrsub(const char* s, const char* search, const char* replace); char* gstrsub(const char* s, const char* search, const char* replace);
const char* xstrrstr(const char* s1, const char* s2); const char* xstrrstr(const char* s1, const char* s2);
void rtrim(char* s); void rtrim(char* s);
skipping to change at line 986 skipping to change at line 986
const char* get_filename(const char* fname); /* extract t he filename portion */ const char* get_filename(const char* fname); /* extract t he filename portion */
/* /*
* Character encoding transformations. * Character encoding transformations.
*/ */
#define CET_NOT_CONVERTABLE_DEFAULT '$' #define CET_NOT_CONVERTABLE_DEFAULT '$'
#define CET_CHARSET_ASCII "US-ASCII" #define CET_CHARSET_ASCII "US-ASCII"
#define CET_CHARSET_UTF8 "UTF-8" #define CET_CHARSET_UTF8 "UTF-8"
#define CET_CHARSET_HEBREW "CP1255" #define CET_CHARSET_HEBREW "ISO-8859-8"
#define CET_CHARSET_MS_ANSI "MS-ANSI" #define CET_CHARSET_MS_ANSI "windows-1252"
#define CET_CHARSET_LATIN1 "ISO-8859-1" #define CET_CHARSET_LATIN1 "ISO-8859-1"
#define str_utf8_to_cp1252(str) cet_str_utf8_to_cp1252((str)) #define str_utf8_to_cp1252(str) cet_str_utf8_to_cp1252((str))
#define str_cp1252_to_utf8(str) cet_str_cp1252_to_utf8((str)) #define str_cp1252_to_utf8(str) cet_str_cp1252_to_utf8((str))
#define str_utf8_to_iso8859_1(str) cet_str_utf8_to_iso8859_1((str)) #define str_utf8_to_iso8859_1(str) cet_str_utf8_to_iso8859_1((str))
#define str_iso8859_1_to_utf8(str) cet_str_iso8859_1_to_utf8((str)) #define str_iso8859_1_to_utf8(str) cet_str_iso8859_1_to_utf8((str))
/* this lives in gpx.c */ /* this lives in gpx.c */
gpsbabel::DateTime xml_parse_time(const QString& cdatastr); gpsbabel::DateTime xml_parse_time(const QString& cdatastr);
char* rot13(const QString& str); QString rot13(const QString& str);
/* /*
* PalmOS records like fixed-point numbers, which should be rounded * PalmOS records like fixed-point numbers, which should be rounded
* to deal with possible floating-point representation errors. * to deal with possible floating-point representation errors.
*/ */
signed int si_round(double d); signed int si_round(double d);
#if _MSC_VER #if _MSC_VER
//These functions are not included in the MS pre C99 implementation, use in ternal implementation //These functions are not included in the MS pre C99 implementation, use in ternal implementation
skipping to change at line 1107 skipping to change at line 1107
void gb_setbit(void* buf, const uint32_t nr); void gb_setbit(void* buf, const uint32_t nr);
void* gb_int2ptr(const int i); void* gb_int2ptr(const int i);
int gb_ptr2int(const void* p); int gb_ptr2int(const void* p);
/* /*
* From parse.c * From parse.c
*/ */
int parse_coordinates(const char* str, int datum, const grid_type grid, int parse_coordinates(const char* str, int datum, const grid_type grid,
double* latitude, double* longitude, const char* modu le); double* latitude, double* longitude, const char* modu le);
int parse_coordinates(const QString& str, int datum, const grid_type grid,
double* latitude, double* longitude, const char* modu
le);
int parse_distance(const char* str, double* val, double scale, const char* module); int parse_distance(const char* str, double* val, double scale, const char* module);
int parse_distance(const QString& str, double* val, double scale, const cha r* module);
int parse_speed(const char* str, double* val, const double scale, const cha r* module); int parse_speed(const char* str, double* val, const double scale, const cha r* module);
int parse_speed(const QString& str, double* val, const double scale, const char* module);
time_t parse_date(const char* str, const char* format, const char* module); time_t parse_date(const char* str, const char* format, const char* module);
time_t parse_date(const QString& str, const char* format, const char* modul e);
/* /*
* From util_crc.c * From util_crc.c
*/ */
unsigned long get_crc32(const void* data, int datalen); unsigned long get_crc32(const void* data, int datalen);
unsigned long get_crc32_s(const void* data); unsigned long get_crc32_s(const void* data);
/* /*
* From units.c * From units.c
*/ */
 End of changes. 12 change blocks. 
8 lines changed or deleted 15 lines changed or added


 garmin_fs.h   garmin_fs.h 
skipping to change at line 27 skipping to change at line 27
You should have received a copy of the GNU General Public License You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA
*/ */
#ifndef GARMIN_FS_H #ifndef GARMIN_FS_H
#define GARMIN_FS_H #define GARMIN_FS_H
#include <ctype.h>
#include "defs.h" #include "defs.h"
#include "jeeps/gps.h" #include "jeeps/gps.h"
/* this order is used by most devices */ /* this order is used by most devices */
/* typedef enum { /* typedef enum {
garmin_display_symbol_and_name = 0, garmin_display_symbol_and_name = 0,
garmin_display_symbol_only = 1, garmin_display_symbol_only = 1,
garmin_display_symbol_and_description = 2 garmin_display_symbol_and_description = 2
} garmin_display_t; } garmin_display_t;
*/ */
skipping to change at line 55 skipping to change at line 54
#define GMSD_GET(a,b) ((gmsd) && (gmsd->flags.a)) ? (gmsd->a) : (b) #define GMSD_GET(a,b) ((gmsd) && (gmsd->flags.a)) ? (gmsd->a) : (b)
/* GMSD_SET(a,b): a = numeric gmsd field, b = numeric source */ /* GMSD_SET(a,b): a = numeric gmsd field, b = numeric source */
#define GMSD_SET(a,b) if (gmsd) {gmsd->a = (b); gmsd->flags.a = 1; } #define GMSD_SET(a,b) if (gmsd) {gmsd->a = (b); gmsd->flags.a = 1; }
/* GMSD_UNSET(a): a = gmsd field */ /* GMSD_UNSET(a): a = gmsd field */
#define GMSD_UNSET(a) if (gmsd) { gmsd->flags.a = 0; } #define GMSD_UNSET(a) if (gmsd) { gmsd->flags.a = 0; }
/* GMSD_SETSTR(a,b): a = gmsd field, b = null terminated source */ /* GMSD_SETSTR(a,b): a = gmsd field, b = null terminated source */
#define GMSD_SETSTR(a,b) if (gmsd && (b) && (b)[0]) { gmsd->a = xstrdup((b) ); gmsd->flags.a = 1; } #define GMSD_SETSTR(a,b) if (gmsd && (b) && (b)[0]) { gmsd->a = xstrdup((b) ); gmsd->flags.a = 1; }
#define GMSD_SETQSTR(a,b) if (gmsd) { gmsd->a = xstrdup((b)); gmsd->flags.a = 1; }
#define GMSD_SETSTRQ(a,b) if (gmsd && !b.isEmpty()) { gmsd->a = xstrdup((b )); gmsd->flags.a = 1; } #define GMSD_SETSTRQ(a,b) if (gmsd && !b.isEmpty()) { gmsd->a = xstrdup((b )); gmsd->flags.a = 1; }
/* GMSD_SETNSTR(a,b,c): a = gmsd field, b = source, c = sizeof(source) */ /* GMSD_SETNSTR(a,b,c): a = gmsd field, b = source, c = sizeof(source) */
#define GMSD_SETNSTR(a,b,c) if (gmsd && (b) && (b)[0]) { gmsd->a = xstrndup ((b),(c)); gmsd->flags.a = 1; } #define GMSD_SETNSTR(a,b,c) if (gmsd && (b) && (b)[0]) { gmsd->a = xstrndup ((b),(c)); gmsd->flags.a = 1; }
/* GMSD_GETNSTR(a,b,c): a = gmsd field, b = target, c = sizeof(target) */ /* GMSD_GETNSTR(a,b,c): a = gmsd field, b = target, c = sizeof(target) */
#define GMSD_GETNSTR(a,b,c) if (gmsd && gmsd->flags.a) strncpy((b),gmsd->a, (c)) #define GMSD_GETNSTR(a,b,c) if (gmsd && gmsd->flags.a) strncpy((b),gmsd->a, (c))
typedef struct garmin_ilink_s { typedef struct garmin_ilink_s {
int ref_count; int ref_count;
 End of changes. 2 change blocks. 
1 lines changed or deleted 1 lines changed or added


 garmin_tables.h   garmin_tables.h 
skipping to change at line 39 skipping to change at line 39
#define DEFAULT_ICON_VALUE 18 #define DEFAULT_ICON_VALUE 18
typedef struct icon_mapping { typedef struct icon_mapping {
const int mpssymnum; const int mpssymnum;
const int pcxsymnum; const int pcxsymnum;
const char* icon; const char* icon;
} icon_mapping_t; } icon_mapping_t;
typedef enum {MAPSOURCE, PCX, GARMIN_SERIAL, GDB} garmin_formats_e; typedef enum {MAPSOURCE, PCX, GARMIN_SERIAL, GDB} garmin_formats_e;
const char* gt_find_desc_from_icon_number(const int icon, garmin_formats_e garmin_format, int* dynamic); const QString gt_find_desc_from_icon_number(const int icon, garmin_formats_ e garmin_format);
int gt_find_icon_number_from_desc(const QString& desc, garmin_formats_e gar min_format); int gt_find_icon_number_from_desc(const QString& desc, garmin_formats_e gar min_format);
extern icon_mapping_t garmin_icon_table[]; extern icon_mapping_t garmin_icon_table[];
typedef enum { typedef enum {
gt_waypt_class_user_waypoint = 0, gt_waypt_class_user_waypoint = 0,
gt_waypt_class_airport, gt_waypt_class_airport,
gt_waypt_class_intersection, gt_waypt_class_intersection,
gt_waypt_class_ndb, gt_waypt_class_ndb,
gt_waypt_class_vor, gt_waypt_class_vor,
skipping to change at line 94 skipping to change at line 94
typedef enum { typedef enum {
gt_gdb_display_mode_symbol = 0, gt_gdb_display_mode_symbol = 0,
gt_gdb_display_mode_symbol_and_name, gt_gdb_display_mode_symbol_and_name,
gt_gdb_display_mode_symbol_and_comment gt_gdb_display_mode_symbol_and_comment
} gt_gdb_display_modes_e; } gt_gdb_display_modes_e;
unsigned char gt_convert_category(const char* name, int* category); unsigned char gt_convert_category(const char* name, int* category);
unsigned char gt_switch_display_mode_value(const unsigned char display_mode , const int protoid, const char device); unsigned char gt_switch_display_mode_value(const unsigned char display_mode , const int protoid, const char device);
grid_type gt_lookup_grid_type(const char* grid_name, const char* module); grid_type gt_lookup_grid_type(const char* grid_name, const QString& module) ;
const char* gt_get_mps_grid_longname(const grid_type grid, const char* modu le); const char* gt_get_mps_grid_longname(const grid_type grid, const char* modu le);
int gt_lookup_datum_index(const char* datum_str, const char* module); int gt_lookup_datum_index(const char* datum_str, const QString& module);
const char* gt_get_mps_datum_name(const int datum_index); const char* gt_get_mps_datum_name(const int datum_index);
uint32_t gt_color_value(const unsigned int garmin_index); uint32_t gt_color_value(const unsigned int garmin_index);
uint32_t gt_color_value_by_name(const char* name); uint32_t gt_color_value_by_name(const QString& name);
int gt_color_index_by_name(const char* name); int gt_color_index_by_name(const QString& name);
int gt_color_index_by_rgb(const int rgb); int gt_color_index_by_rgb(const int rgb);
const char* gt_color_name(const unsigned int garmin_index); const char* gt_color_name(const unsigned int garmin_index);
#endif #endif
 End of changes. 4 change blocks. 
5 lines changed or deleted 5 lines changed or added


 gbfile.h   gbfile.h 
skipping to change at line 26 skipping to change at line 26
You should have received a copy of the GNU General Public License You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA
*/ */
#ifndef GBFILE_H #ifndef GBFILE_H
#define GBFILE_H #define GBFILE_H
#include <ctype.h>
#include <stdarg.h>
#include <string.h>
#include <QtCore/QString>
#include "defs.h" #include "defs.h"
#include "cet.h" #include "cet.h"
#include <QtCore/QString>
struct gbfile_s; struct gbfile_s;
typedef struct gbfile_s gbfile; typedef struct gbfile_s gbfile;
typedef uint32_t gbsize_t; typedef uint32_t gbsize_t;
typedef void (*gbfclearerr_cb)(gbfile* self); typedef void (*gbfclearerr_cb)(gbfile* self);
typedef int (*gbfclose_cb)(gbfile* self); typedef int (*gbfclose_cb)(gbfile* self);
typedef int (*gbfeof_cb)(gbfile* self); typedef int (*gbfeof_cb)(gbfile* self);
typedef int (*gbferror_cb)(gbfile* self); typedef int (*gbferror_cb)(gbfile* self);
typedef int (*gbfflush_cb)(gbfile* self); typedef int (*gbfflush_cb)(gbfile* self);
typedef gbfile* (*gbfopen_cb)(gbfile* self, const char* mode); typedef gbfile* (*gbfopen_cb)(gbfile* self, const char* mode);
skipping to change at line 90 skipping to change at line 87
gbferror_cb fileerror; gbferror_cb fileerror;
gbfflush_cb fileflush; gbfflush_cb fileflush;
gbfopen_cb fileopen; gbfopen_cb fileopen;
gbfread_cb fileread; gbfread_cb fileread;
gbfseek_cb fileseek; gbfseek_cb fileseek;
gbftell_cb filetell; gbftell_cb filetell;
gbfungetc_cb fileungetc; gbfungetc_cb fileungetc;
gbfwrite_cb filewrite; gbfwrite_cb filewrite;
} gbfile_t; } gbfile_t;
gbfile* gbfopen(const char* filename, const char* mode, const char* module) gbfile* gbfopen(const QString filename, const char* mode, const char* modul
; e);
gbfile* gbfopen_be(const char* filename, const char* mode, const char* modu gbfile* gbfopen_be(const QString filename, const char* mode, const char* mo
le); dule);
#define gbfopen_le gbfopen #define gbfopen_le gbfopen
void gbfclose(gbfile* file); void gbfclose(gbfile* file);
gbsize_t gbfread(void* buf, const gbsize_t size, const gbsize_t members, gb file* file); gbsize_t gbfread(void* buf, const gbsize_t size, const gbsize_t members, gb file* file);
gbsize_t gbfread(QString& buf, const gbsize_t size, const gbsize_t members, gbfile* file);
int gbfgetc(gbfile* file); int gbfgetc(gbfile* file);
QString gbfgets(char* buf, int len, gbfile* file); QString gbfgets(char* buf, int len, gbfile* file);
int gbvfprintf(gbfile* file, const char* format, va_list ap); int gbvfprintf(gbfile* file, const char* format, va_list ap);
int gbfprintf(gbfile* file, const char* format, ...); int gbfprintf(gbfile* file, const char* format, ...);
int gbfputc(int c, gbfile* file); int gbfputc(int c, gbfile* file);
int gbfputs(const char* s, gbfile* file);
int gbfputs(const QString& s, gbfile* file); int gbfputs(const QString& s, gbfile* file);
int gbfwrite(const void* buf, const gbsize_t size, const gbsize_t members, gbfile* file); int gbfwrite(const void* buf, const gbsize_t size, const gbsize_t members, gbfile* file);
int gbfflush(gbfile* file); int gbfflush(gbfile* file);
void gbfclearerr(gbfile* file); void gbfclearerr(gbfile* file);
int gbferror(gbfile* file); int gbferror(gbfile* file);
void gbfrewind(gbfile* file); void gbfrewind(gbfile* file);
int gbfseek(gbfile* file, int32_t offset, int whence); int gbfseek(gbfile* file, int32_t offset, int whence);
gbsize_t gbftell(gbfile* file); gbsize_t gbftell(gbfile* file);
int gbfeof(gbfile* file); int gbfeof(gbfile* file);
skipping to change at line 134 skipping to change at line 131
char* gbfgetcstr_old(gbfile* file); // read a null terminated st ring char* gbfgetcstr_old(gbfile* file); // read a null terminated st ring
int gbfputint16(const int16_t i, gbfile* file); int gbfputint16(const int16_t i, gbfile* file);
#define gbfputuint16(a,b) gbfputint16((uint16_t)(a),(b)) #define gbfputuint16(a,b) gbfputint16((uint16_t)(a),(b))
int gbfputint32(const int32_t i, gbfile* file); int gbfputint32(const int32_t i, gbfile* file);
#define gbfputuint32(a,b) gbfputint32((uint32_t)(a),(b)) #define gbfputuint32(a,b) gbfputint32((uint32_t)(a),(b))
int gbfputdbl(const double d, gbfile* file); // write a double value int gbfputdbl(const double d, gbfile* file); // write a double value
int gbfputflt(const float f, gbfile* file); // write a float value int gbfputflt(const float f, gbfile* file); // write a float value
int gbfputcstr(const char* s, gbfile* file); // write string including '\ 0'
int gbfputcstr(const QString& s, gbfile* file); // write string incl uding '\0' int gbfputcstr(const QString& s, gbfile* file); // write string incl uding '\0'
int gbfputpstr(const char* s, gbfile* file); // write as pascal string
int gbfputpstr(const QString& s, gbfile* file); // write as pascal s tring int gbfputpstr(const QString& s, gbfile* file); // write as pascal s tring
gbsize_t gbfcopyfrom(gbfile* file, gbfile* src, gbsize_t count); gbsize_t gbfcopyfrom(gbfile* file, gbfile* src, gbsize_t count);
#endif #endif
 End of changes. 7 change blocks. 
12 lines changed or deleted 7 lines changed or added


 gbversion.h   gbversion.h 
/* /*
* gbversion.h is generated from gbversion.h.in which uses autoconf voodoo * gbversion.h is generated from gbversion.h.in which uses autoconf voodoo
* to get the version number from configure.in. * to get the version number from configure.in.
* *
* Isn't simplification via automation grand? * Isn't simplification via automation grand?
*/ */
#define VERSION "1.5.1" #define VERSION "1.5.2"
#define WEB_DOC_DIR "http://www.gpsbabel.org/htmldoc-1.5.1" #define WEB_DOC_DIR "http://www.gpsbabel.org/htmldoc-1.5.2"
 End of changes. 1 change blocks. 
0 lines changed or deleted 0 lines changed or added


 xmlgeneric.h   xmlgeneric.h 
skipping to change at line 28 skipping to change at line 28
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111 USA
*/ */
typedef enum { typedef enum {
cb_start = 1, cb_start = 1,
cb_cdata, cb_cdata,
cb_end, cb_end,
} xg_cb_type; } xg_cb_type;
class QXmlStreamAttributes;
typedef void (xg_callback)(xg_string, const QXmlStreamAttributes*); typedef void (xg_callback)(xg_string, const QXmlStreamAttributes*);
typedef struct xg_tag_mapping { typedef struct xg_tag_mapping {
xg_callback* tag_cb; xg_callback* tag_cb;
xg_cb_type cb_type; xg_cb_type cb_type;
const char* tag_name; const char* tag_name;
} xg_tag_mapping; } xg_tag_mapping;
extern const char* xhtml_entities; extern const char* xhtml_entities;
void xml_ignore_tags(const char** taglist); void xml_ignore_tags(const char** taglist);
 End of changes. 1 change blocks. 
0 lines changed or deleted 1 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/