Commit graph

15 commits

Author SHA1 Message Date
Willem Ferguson
0de3bc8452 Display CCR setpoint values on the po2 graph
When a CCR dive is viewed and the toolbar button for PO2 is activated,
both the PO2 (green line) and the O2 setpoint (red line) are shown.
This allows evaluation of the PO2 in the CCR loop with respect to the
pre-configured O2 setpoint.

The setpoint graph can be disabled from the Preferences/Graphs tab
by checking the appropriate checkbox.

Signed-off-by: willem ferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2015-01-05 09:18:06 -08:00
Robert C. Helling
3fc9c1e005 Tissue saturation plot a la Sherwater Pretel
This adds a toolbox icon to turn on a tissue plot inspired by the bar
graph of the Sherwater Petrel,

It shows the inert gas partial pressures for individual compartments. If
they are below the ambient pressure (grey line) they are shown in units of
the ambient pressure, if they are above, the excess is shown as a
percentage of the allowed overpressure for plain Buehlmann. So it has the
same units as a gradient factor. Thus also the a gradient factor line (for
the current depth) is shown.

The different tissues get different colors, greener for the faster ones and bluer
for the slower ones.

Positioning and on/off icon action still need some tender loving care.

Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-09-19 21:46:30 -07:00
Dirk Hohndel
2d24779b62 Make heartrate grid less confusing
Having all the grid lines in the same color made things visually
confusing. To clean this up a little make the heartrate lines a light gray
color.

Fixes #484

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-04-28 12:45:42 -07:00
Dirk Hohndel
e5967dd193 Make red ceiling work
The existing code for toggling the DC reported ceiling in red or "surface
color" clearly had never been tested.

This seems to create a reasonably attractive implementation - not exactly
what we had in the past, but good enough.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-04-14 22:52:22 -07:00
Tomaz Canabrava
5bba84e57f Fix colors on the new profile.
This patch fixes the colors on the new profile, the init of the colors map
was not being done. This fixes it.

A few problems were spotted on the new profile dealing with the ruler
graph and a newly added dive, when using the dive add dialog.

I'll be on it later.

Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-03-07 20:37:17 -08:00
Dirk Hohndel
76e6420f6b Massive automated whitespace cleanup
I know everyone will hate it.
Go ahead. Complain. Call me names.
At least now things are consistent and reproducible.
If you want changes, have your complaint come with a patch to
scripts/whitespace.pl so that we can automate it.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-02-27 20:09:57 -08:00
Dirk Hohndel
b5a02e50aa New profile: create new class for DiveHeartrateItem
This allows us to give it a different color (red) and make it a smaller
size.

While implementing this I also fixed the size of the temperature text in
the new profile.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-02-23 15:28:31 -08:00
Dirk Hohndel
6332976c3d Whitespace and dead code cleanup
The coding style for switch isn't the prettiest, but let's at least keep
things consistent.

Also, those ugly break statements never got reached, anyway.

And there was no need to re-declare and re-generate currentString.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-02-12 06:22:10 -08:00
Tomaz Canabrava
fcc17c717d Move the 'getSacColor' out of old profile and use it.
This patch makes the color of the cylinder pressure use the sac colors.

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-01-27 13:00:29 -08:00
Dirk Hohndel
733108b473 Fix potential crash in getColor functions
If the index is out of range, just return black.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-01-18 14:37:08 -08:00
Lubomir I. Ivanov
f818ece074 graphicsview-common.cpp: Add more contrast to certain B/W colors
There was a report that the depth and time texts were small
and require more contrast on the B/W print. Use BLACK1 for these.

Reported-by: Willem Ferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2013-10-15 04:23:43 -07:00
Tomaz Canabrava
493f366765 Use the same line dimensions as the profile, on the planner.
The Planner should be 'almost' like the profile, with the possibility
to use the mouse and keyboard to input a new plan, so this is a bit
of 'getting there.' I don't like too much code duplication but since
the current Profile Graphics is a crude cut-and-paste from the old
Cairo backend, it's easyer to start from scratch and have it well
organized as Qt code.

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
2013-09-16 19:21:13 -03:00
Lubomir I. Ivanov
f470f559d1 Colors: a couple of grayscale color tweaks
change the B/W color (index 1) of some of the
colors - e.g. BACKGROUND, ALERT_FG.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
2013-07-18 12:00:12 -07:00
Tomaz Canabrava
effb7e2fac Change the color of the DepthString based on it's deepness
Change the color of the DepthString based on it's deepness
on the profile planner. The new color of the profileString
( the string that follows the mouse stating how deep you are)
is now interpolated from SAMPLE_SHALLOW and SAMPLE_DEEP -
but since those two colors were the same and I had to change
it so that could work, I want somebody to check if my choose
of colors were ok.

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
2013-07-02 13:31:25 -03:00
Tomaz Canabrava
2df0b398f3 Added 2 new files to handle the common stuff for graphics.
Added 2 new files, graphicsview-common.h/cpp, that should have
the common stuff shared between the dive profile viewer and
the dive planner. the amount of duplicated code would be huge
if we go the road of two different classes for each one, but
since the planner took a more 'Qtish' way of behavior, in
comparisson to the profile - that's most a Cairo-To-Qt literal
translation, we cant easily merge the code without a complete
( and unwanted ) reestruturation of the profile code, thus,
this new files will serve as a bridge between them. Initially
I put there only the colors - since that's wat most easilyy
shareable.

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
2013-07-02 10:08:16 -03:00