X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=dive.h;h=f0808efb47d3bbe19c4efcb004a957fcc9ad9e9c;hb=af290d5eb281662d336b8186a9df1a489d78ec9d;hp=cf11e1f89384bb34176e9eb5c14879cb89f73be1;hpb=38ccc152140d03b6df1de587a8887663886fff7b;p=ext%2Fsubsurface.git diff --git a/dive.h b/dive.h index cf11e1f..f0808ef 100644 --- a/dive.h +++ b/dive.h @@ -5,6 +5,7 @@ #include #include +#include /* * Some silly typedefs to make our units very explicit. @@ -83,7 +84,7 @@ typedef struct { typedef struct { cylinder_type_t type; struct gasmix gasmix; - pressure_t start, end; + pressure_t start, end, sample_start, sample_end; } cylinder_t; extern int get_pressure_units(unsigned int mb, const char **units); @@ -198,6 +199,7 @@ struct dive { char *location; char *notes; char *divemaster, *buddy; + int rating; double latitude, longitude; depth_t maxdepth, meandepth; duration_t duration, surfacetime; @@ -253,11 +255,13 @@ extern void parse_xml_init(void); extern void parse_xml_file(const char *filename, GError **error); extern void set_filename(const char *filename); +#ifdef XSLT +extern xmlDoc *test_xslt_transforms(xmlDoc *doc); +#endif + extern void show_dive_info(struct dive *); -extern void flush_dive_info_changes(struct dive *); extern void show_dive_equipment(struct dive *); -extern void flush_dive_equipment_changes(struct dive *); extern void show_dive_stats(struct dive *); @@ -299,6 +303,7 @@ extern void add_location(const char *string); extern void remember_event(const char *eventname); extern void evn_foreach(void (*callback)(const char *, int *, void *), void *data); +extern int edit_dive_info(struct dive *dive); extern void dive_list_update_dives(void); extern void flush_divelist(struct dive *dive); @@ -309,5 +314,14 @@ const char *monthname(int mon); #define UTF8_DEGREE "\xc2\xb0" #define UTF8_SUBSCRIPT_2 "\xe2\x82\x82" +#define UTF8_WHITESTAR "\xe2\x98\x86" +#define UTF8_BLACKSTAR "\xe2\x98\x85" +#define ZERO_STARS UTF8_WHITESTAR UTF8_WHITESTAR UTF8_WHITESTAR UTF8_WHITESTAR UTF8_WHITESTAR +#define ONE_STARS UTF8_BLACKSTAR UTF8_WHITESTAR UTF8_WHITESTAR UTF8_WHITESTAR UTF8_WHITESTAR +#define TWO_STARS UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_WHITESTAR UTF8_WHITESTAR UTF8_WHITESTAR +#define THREE_STARS UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_WHITESTAR UTF8_WHITESTAR +#define FOUR_STARS UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_WHITESTAR +#define FIVE_STARS UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_BLACKSTAR UTF8_BLACKSTAR +extern const char *star_strings[]; #endif /* DIVE_H */