Changed the markup with <div> and <br> tags of the planner output in
a way that is is a good compromise for both displaying in UI and
printing.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
Shellcheck wanted quotes around "$USE_X" - but that makes the script
fail if you run it without the '-x' argument.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Move it to packaging/android where it belongs
Use direct URLs to download Android components
Make sure required packages are installed (only tested on Ubuntu)
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This is what we have same_string() for...
This prevents a crash when saving a dive in the planner.
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
In order to get the translations right for Windows we now explicitly
pull in a lot more translation files - some of which don't exist in
earlier Qt versions.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Adding --win32log as the first command line option on Windows
will now log all stdout and stderr output to the files
subsurface_err.log and subsurface_out.log in the working directory.
This change required a new argument 'bool logfile' to be added to:
subsurface_console_init() which is defined in all platform files
(linux.c, macos.c, etc.)
Example usage:
subsurface.exe --win32log -v -v -v
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
This is important if in one dive we have the real dive and
a planned version of the dive as different computers using
different sets of cylinders.
[Dirk Hohndel: an early version of this was mistakenly pushed out
by me; I reverted that and added this commit since
fixing things up as I had done for the other two
patches made things nearly unreadable]
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
When Suunto Vytecs are used in gauge mode they don't record gasmixes.
If a tank pressure sensor is present they nevertheless record the
pressures. This patch handles this situation by assuming the tanks
contain air (and warning the user about this).
[Dirk Hohndel: I had mistakenly pushed out an earlier version of this
commit, so this fixes things up to the final version]
Reported-by: antonnorth@gmail.com
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
When merging a real dive with a planned dive (for comparison),
we should not try to be clever in merging similar cylinders,
rather keep the union of both cylinder sets as the two versions
of the dive might differ in exctly which gas and how much of it
was used.
Increase MAX_CYLINDERS to 20 to make room for this. We warn if we
exceed this number.
[Dirk Hohndel: I had mistakenly pushed out an earlier version of this
commit, so this fixes things up to the final version]
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Print the SAC values from preferences into the diveplan.
These are the values used for calculation of gas consumption.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Print the ATM pressure and the altitude used for calculation into the resulting diveplan.
Moved this info together with the deco model info below the runtime table.
There is one drawback in this implementation: Altitude will be recalculated from surface pressure and therefore may differ slightly from altitude entered in the UI.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
When merging a real dive with a planned dive (for comparison),
we should not try to be clever in merging similar cylinders,
rather keep the union of both cylinder sets as the two versions
of the dive might differ in exctly which gas and how much of it
was used.
Increase MAX_CYLINDERS to 20 to make room for this.
Signed-off-by: Robert C. Helling <helling@atdotde.de>
When Suunto Vytecs are used in gauge mode they don't record gasmixes.
If a tank pressure sensor is present they nevertheless record the
pressures. This patch handles this situation by assuming the tanks
contain air (and warning the user about this).
Reported-by: antonnorth@gmail.com
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This fixes the missing translations for some standard term like "save",
"cancel" on Windows.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Updates mainly in the comments of the MXE build script:
- File system layout: different proposal
- Hint to not use MXE current version from git
- MXE build JOBS setting to (very) safe value of 1
- export CXXFLAGS=-std=c++11 added for marble build
This allows the user to enter multiple buddies as a comma separated list,
the "Multiple Buddies" entry is still a special case as we can only populate
the combobox with a single name for each entry.
fixes#168
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
When moving the last handle of a dive (in the planner, in dive add, or
when editing a dive), we rescaled the time axis whenever our idea of the
maximum duration that we should show changed. That lead to the odd
situation that you couldn't get to certain dive durations with the
visual editor (e.g. 64 minutes) because just as you approach that time
the scale changes and the dive duration jumps past the desired value.
Fixes issue #174
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Fixes#170 on GitHub
Simple catch function for double click events in the divelist,
prevents users from trying to edit the divenumber ithe wrong way.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
In the cylinder table, the last column ("use") always showed
OC-GAS. Editing was enabled, but the user had to guess to enter
a small integer meaning dilluent or CCR oxygen cylingder. I guess,
nobody has ever done that.
This patch makes this column clickable. A click toggles if the cylinder
is used for planning or not. This wait it is much easier to investigate
the consequences of gas loss on a plan.
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Gas switches appear as special samples with zero or one second duration.
Those can be confusing when they appear as zero duration in the dive plan
when replanning, so better suppress theose.
Signed-off-by: Robert C. Helling <helling@atdotde.de>
The JS string function search returns the position of the string you
search for and -1 if that string isn't found. Also, search allows
regular expression, indexOf does just a string match. So let's use
that as it is much faster.
See issue #168
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
"Multiple Buddies" is magic in that it means "do not change the buddies
set for this dive". Allowing the user to edit that magic phrase defeats
the purpose.
This deals with part of issue #168 - but of course that magic phrase
shouldn't be fixed as English text.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Since we manually track Kirigami we need to compile the desktopicon.cpp
file when not building on Android or iOS.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
When painting the tankbar the function triggers on change in cylinder index,
as a result the new gascolour are changed at the next sample time point.
On a divecomputer with a reasonable fast sample rate the 2-3s offset are hardly
noticable, especially on a longer dive.
For divecomputers with slow sample rate the 10-30s offset are clearly visible.
This is fixed by start painting the new gascolour at the time point of the switch event rather than the time point of the next sample.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
When replanning a dive, do not set the surface pressure when it is 0.
Same for salinity.
This closes#161 .
Signed-off-by: Robert C. Helling <helling@atdotde.de>