Give a hint how to enable build of debug Qt5 DLLs when building MXE.
Take care about the "d"/"xxxd.dll" suffix for DLLs.
Copy libastro.dll from marble to correct loation as well (nevertheless we don't use it)
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
The same ComboBoxDelegate is used for picking a cylinder model
and picking a gas in the planner waypoint table. In the former
case we want to allow the user to edit the string in the second
we don't.
The difference is not if we are in the planner but which use of
the class. So add a bool allowEdit to the constructor.
Fixes#272
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Wfloat-conversion enabled for C++ part of the code
Fix warnings raised by the flag using lrint
Original issue reported on the mailing list:
The ascent/descent rates are sometimes not what is expected.
E.g. setting the ascent rate to 10m/min results in an actual
ascent rate of 9m/min.
This is due to truncating the ascent rate preference,
then effectively rounding up the time to reach each stop to 2s intervals.
The result being that setting the ascent rate to 10m/min
results in 20s to ascend 3m (9m/min), when it should be exactly 18s.
Reported-by: John Smith <noseygit@hotmail.com>
Reported-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Jeremie Guichard <djebrest@gmail.com>
Second attempt to do the thing with the red background color for cylinder
start and end pressure correctly. This now should cover all scenarios.
This rewrites and partitially reverts commit b8e044d
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
Sending nicely readable formatted coordinates to Google Maps does not
result in a correctly positioned map. Google likes unreadable
decimal format.
Little hacky solution. Added a gps_decimal attribute, populate that
with the standard function for format a coordinate to string, but
reset the preferences value temporarly so that it always converts it
to decimal style.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
See also commit acb38c9e00. pSCR is with respect to cylinder planning very
similar to OC planning. Obviously, the SAC is much (max. 8x for counterlung
ration 1:10) lower, but multiple gasses are common (in all but recreational
pSCR diving).
Changed the wording to reflect this.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
from the planner section the follwing paragraph is weird and partially incorrect:
These changes should reflect the cylinders and gas compositions defined in the table
with _Available Gases_. If two or more gases are used, automatic gas switches will be
suggested during the ascent to the surface. These changes can be deleted by
right-clicking the gas change and manually creating a gas change by right-clicking
on the appropriate waypoint.
Yes: during the ascent, gas switches are automatically planned (not suggested). These
can't be deleted by right-clicking (as there are no real waypoints associated with
the gas switches). And futher. To delete a gas change you have to manually create one?
Solution: refrase paragraph.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Add a sentence in the central section on manual profile entry that waypoints
can also be moved by keyboard (arrows).
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Just said that we do not need to plan the ascent. Removed the 2nd ocurrence.
Also: trivial typo corrected
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
The manual suggests that in the Available Gases dialog of the planner, setting of
pO2 is possible. This is not the case, and changed the text accordingly.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Mostly typos and some wording change due to change of UI from
working pressure to starting pressure. And some subscripts changed,
some correction, some style. Now all are in ~2~ format.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Section is called Proxy and nor Proxy Type (which is attribute
in the section).
Simple incorrect wording fixed.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
The old wording suggests that your ISP has something to do with
the Subsurface cloud or companion app. This is not right, so did
a little rewrite.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
This fix seems to fix the enumerate problem: the problem that on a
seemingly non-determinstic way, all the profiles get enumerated
and rendered, causing freeze of the app, or even crash due
to out of memory.
Only 3 lines of code change, but this fix did not come easy. The
enumerate problem seems some kind of race condition between QML,
Kiragami and most definitely, the Subsurface QML code itself.
The breakthrough in my debugging was the setting of
highlightRangeMode: ListView.StrictlyEnforceRange based on
the QML documentation on snapMode: enumeration.
This fix deserves proper testing in multiple environments. As
could be seen on the developpers mailing list, I was (easily)
able to reproduce the enumerate problem, but Rick was not. So
I definitely do not claim to understand why this fix solves
the issue for me.
And as a sidenote: fixes#263 for me as well.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Just an update of comment. The stange issue with Qt5.7.1 is
still present in Qt5.8. Extend the comment accordingly.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Add automatic tests in TestPlan for minimum gas:
- Copy minimum gas result (pressure) to diveplan.
- Add cylinder size and working pressure for bottom gas to every dive in TestPlan
Hint: Unrealistic cylinder sizes (100l, 200l) have to be used for the very long and deep dives in TestPlan
- Add minimum gas check for every dive
- Add two additional test dives in TestPlan which produce sane minimum gas results with 24l tank
Hint: Deco check for these new dives is commented out at the moment
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
For the "crazy" long and deep dives in "TestPlan" an overflow happened here.
Rearranged the calculation to have more margin.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
It's unclear why this code was added in the first place - removing it
makes the highlight of the selected dive in the dive list work.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
In preferences->profile:
Move "bar" from text description to entry field (5x)
Move "l/min" from text description to entry field
Add suffix "%" to GF values
Rename VPM-B conservatism
In planner preferences:
Add prefix "+" to VPM-B conservatism
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
Until now, we did the cylinder import based on its initial pressure (a
tank without pressure is an unused tank). Based in this assumption, we
just dropped those tanks whose initial press was 0, losing user
introduced tank definitions and getting some duplicities due to one
cylinder being numbered (e.g.) 2 by libdivecomputer and 3 by SmartTrak.
The new workflow is: get every single tank reported by SmartTrak (giving
preference to libdivecomputer parsed data), then clean the cylinder
table reverse order, dropping tanks without description and init or end
pressures, and checkig them against the previous cylinder to do a merge,
if they look the same, and try to avoid duplicities.
The new logic assumes a heavier workload for the benefit of lower data
loss (e.g. a user may get his/her tanks descriptions despite he/she
hasn't recorded their pressures because forgot the values or had an issue
with the gas transmitter).
Suggested-by: Alessandro Volpi <volpial@gmail.com>
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
In the past subsurface managed up to 8 tanks, but now it manages up to
20. SmartTrak manages 10 (3 in older no trimix versions) so there is no
more need to drop the last tanks.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
The cylinder info is built one by one. This way, instead of passing dive
and tank number parameters, just passing a pointer to the tank been
worked seems preferable.
It also introduces lrint() in the function to round the doubles values
obtained from libmdb for tank size and workingpressure.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
Framed in a full rework of the cylinders info import management, this
funcs will be used in next patches.
Functions merge_cylinder_type(), merge_cylinder_mix() and
merge_cylinder_info(), have been shamelessly copied from dive.c as they
have been removed by 162767aa dated 2017-03-11 just when I was going to
use them.
Macros MERGE_MAX() and MERGE_MIN() have just been copied from dive.c,
but they could be moved to dive.h so they could be used elsewhere if
needed.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
As commented on mailing list. Most numerical values from libmdb are
doubles obtained via strtod(), so, rounding them instead of just
truncating seems the correct way.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
User can manually add bookmarks on the profile display of SmartTrak.
These are stored in a table with column names which made me think of
cartesian spatial coordinates. In the end the X coordinate is the time.
This makes possible to build subsurface events in those moments of the
dive. The other interesting data is just the text entered by the user.
Suggested-by: Alessandro Volpi <volpial@gmail.com>
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
Fixes some memory leaks, most of them excesive use of copy_string() in
places where it was unnecesary.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
Commits 25dcee139 and 6305361d14 change the user interface, and this
needs to be adapted in the user manual too.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
The section on Dropbox is too verbose to my liking. The Subsurface
manual is not the place to elaborate extensively on something
external as Dropbox.
Removed a section.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
The removed paragraph is not really correct. You do not have to select a trip
to access trip manipulation context menu items, and the behaviour of +/- buttons
is so well known and commonplace that the paragraph before is more than enhough
to explain this trivial feature.
Solution: remove paragraph
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>