src/globals.h File Reference

Contains TSPSG global defines. More...

#include <QtCore>
#include <QtGui>
#include <limits>
#include "version.h"
#include "os.h"
#include "defaults.h"
#include "qtwin.h"
Include dependency graph for globals.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define MAX_NUM_CITIES   50
 Maximum available number of cities.
#define MAX_RAND_VALUE   1000
 Maximum allowed value for random generation limits.
#define PATH_L10N   "l10n"
 Path to internationalization files.
#define PATH_DOCS   "help"
 Bath to documentation files.
#define TSPT   quint32(0x54535054)
 TSPSG Task file signature - letters TSPT.
#define TSPT_VERSION   quint8(1)
 TSPSG Task file version.
#define TSPT_META_VERSION   quint8(1)
 TSPSG Task file metadata version.
#define TSPT_META_SIZE   2
 TSPSG Task file metadata size in bytes (incl. version).
#define ZKT   quint16(0x5A4B)
 ZKomModRd Task file signature - letters ZK.
#define ZKT_VERSION   quint8(1)
 ZKomModRd Task file version.
#define INFINITY   std::numeric_limits<double>::infinity()
 This value means infinity :-).
#define INFSTR   "---"
 This string represents infinite value in the table.

Functions

bool isInteger (double x)
 Checks whether x contains an integer value.
void toggleStyle (QWidget *widget, bool enable)
 Enables or disables a mask for the widget.

Detailed Description

Contains TSPSG global defines.

Author:
Copyright © 2007-2010 Lёppa <contacts[at]oleksii[dot]name>
Id
globals.h 98 2010-03-12 19:28:42Z laleppa
URL
https://tspsg.svn.sourceforge.net/svnroot/tspsg/trunk/src/globals.h

TSPSG: TSP Solver and Generator

This file is part of TSPSG.

TSPSG is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

TSPSG is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with TSPSG. If not, see <http://www.gnu.org/licenses/>.


Define Documentation

#define INFINITY   std::numeric_limits<double>::infinity()

This value means infinity :-).

Some libraries already have INFINITY defined. We need to redefine it for the INFINITY to always have the same value.


Function Documentation

bool isInteger ( double  x  )  [inline]

Checks whether x contains an integer value.

Parameters:
x A value to check.
Returns:
true if x countains an integer, oherwise false.
void toggleStyle ( QWidget widget,
bool  enable 
)

Enables or disables a mask for the widget.

Parameters:
widget A widget to toggle mask on.
enable Set to true to enable mask or false to disable it.

This function is used to enable an outlined font effect for QLabel with a static text.

Here is the call graph for this function:

 All Classes Files Functions Variables Typedefs Defines

Generated on Thu Apr 8 23:15:53 2010 for TSPSG: TSP Solver and Generator by  doxygen 1.6.1