Fix the DC ceiling in the profile.

entry->ndl is computed and therefore should not be used for showing
the DC's ceiling. That made the DC ceiling jump to 0m when the computed
celing was at 0.

Signed-off-by: Patrick Valsecchi <patrick@thus.ch>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Enable file selection dialog for preferences

This enabled a file selection dialog for selecting default log file
under the preferences.

[Dirk Hohndel: added missing declaration to .h file]

Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
INSTALL: add notes for a native win32 build

There are more details to it, but i decided to exclude them
as these seem situational:

- libraries tend to mostly fail to build from source on win32...
- libiconv may be required by an oddly pre-built libxml2 package
- pkg-config requires a CMD wrapper so that an extra CRLF line is
trimmed from stdout

If someone takes on this task, i guess he/she may pop on the
mailing list for questions.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Print: remove profile border when printing

Custom widget frame styles such as 'Sunken' and 'Raised' which seem to
varry between OS will be captured as well:
http://harmattan-dev.nokia.com/docs/library/html/qt4/qframe.html#Shape-enum

So instead we temporarily set the profile frame to QFrame::NoFrame and
then restore it to the previous value.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Only calculate decompression if the user turned the preference on

There's no point in wasting the cycles otherwise.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Use full version for Mac dmg file

Only tagged releases should get the short version number.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Actually get the correct full version for DMG

This is what I get for trying to be smart and pushing a change from the Linux
box because the fix was 'obvious'. Duh. It was not. In order to get the real
full version including the git hash we always have to pass 'linux' to the
gen-version script, even on a Mac.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Get the version at make time, not qmake time

Let's see how many tries it will take me to get this one right...
The name of the .dmg needs to be determined when running make, not qmake.
Otherwise we'd have to force the user to run qmake every time version.h
changes. This looks better.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Make sure version.h is updated whenever the git version changes

The easiest way to do this seems to make it depend on the correct git
reference. qmake will do the right thing (and create a fixed version.h based on
the VERSION variable) if the user is working from a tar ball.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add test dive with tank pressure sensor information

This is a real data from a Uemis Zurich divecomputer.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
color.h: Define the color BLACK1

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
profile.h: Adjust text sizes (*_TEXT_SIZE)

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
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>
printlayout.cpp: Increase the font size in tables bellow profile

Because of varying font (screen) DPI we use pixel sized fonts
when printing. Apparently 8px does not look that good on Windows
default fonts, but kinda OK on Linux. We compensate by
increasing the font size and table rows to 9px.

Also decrease the padding between the table and profile to 5px.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
profilegraphics.cpp: Use text sizes in plot_text()

Make the active font (fnt) use the 'size' member of the received
text_render_options_t. This allows changing the size of
certain text elements.

For the moment most text elements are set to 12px.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
printdialog: Remove the pre-set DPI and some comments

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
printlayout.cpp: Remove convertPixmapToGrayscale()

Function is redundant as we should only render the profile
with a custom color table.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Random white space cleanup

Because I can.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Fixed the Tab behavior on the QCombobox Delegate

This Patch fixes the tab behavior on the QComboBox
delegate. For a QComboBox, tab was being treated as
'cancel' action on edit, but since it will send a
editingFinished() signal, and the Qt::Key_Return
will also send a editingFinished() signal, I couldn't
use that method and had to do a little hack around it.

The code is mostly clean and works.

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Fix stupid editing error

Don't do "obvious cleanups" at 4 in the morning when you can't sleep because
of emotionally draining issues outside of your control... and if you do,
at least compile test them.

This was introduced by me in commit 2f9f46cb0253 ("Random white space
cleanup").

Sorry.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>