Changeset a2e64d518a in tspsg for docs/html/globals_8h_source.html
- Timestamp:
- Jan 7, 2010, 5:31:27 PM (15 years ago)
- Branches:
- 0.1.3.145-beta1-symbian, 0.1.4.170-beta2-bb10, appveyor, imgbot, master, readme
- Children:
- a5be8eb2c8
- Parents:
- 354e06314f
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
docs/html/globals_8h_source.html
r354e06314f ra2e64d518a 102 102 <a name="l00045"></a><a class="code" href="globals_8h.html#af9914e148840572bac46f451db4cb6e5">00045</a> <span class="preprocessor">#define DEF_RAND_MAX 10</span> 103 103 <a name="l00047"></a><a class="code" href="globals_8h.html#a4d1fa8b5b2b213595f30e55d75070ed2">00047</a> <span class="preprocessor">#define DEF_NUM_CITIES 5</span> 104 <a name="l00049"></a><a class="code" href="globals_8h.html#a2982eb0f2aea4cff78bd4aa767ff1988">00049</a> <span class="preprocessor">#define DEF_FONT_FAMILY "Courier New"</span> 105 <a name="l00051"></a><a class="code" href="globals_8h.html#ab73bf542bad61b0b720c0495ef612105">00051</a> <span class="preprocessor">#define DEF_FONT_SIZE 10</span> 106 <a name="l00053"></a><a class="code" href="globals_8h.html#a6bbeb8fbbb2c6ec31993ff56f6b695e3">00053</a> <span class="preprocessor">#define DEF_FONT_COLOR Qt::black</span> 107 <a name="l00054"></a>00054 <span class="preprocessor"></span> 108 <a name="l00056"></a><a class="code" href="globals_8h.html#a70edda218af688662bb006cf0552544e">00056</a> <span class="preprocessor">#define MAX_NUM_CITIES 30</span> 109 <a name="l00058"></a><a class="code" href="globals_8h.html#a1703614f274735e91c1539048ef1093f">00058</a> <span class="preprocessor">#define MAX_RAND_VALUE 1000</span> 110 <a name="l00059"></a>00059 <span class="preprocessor"></span> 111 <a name="l00060"></a>00060 <span class="comment">// Paths</span> 112 <a name="l00069"></a>00069 <span class="comment"></span><span class="preprocessor">#if defined(Q_OS_LINUX) || defined(Q_OS_UNIX)</span> 113 <a name="l00070"></a>00070 <span class="preprocessor"></span><span class="preprocessor"> #define PATH_I18N "/usr/share/tspsg/i18n"</span> 114 <a name="l00071"></a>00071 <span class="preprocessor"></span><span class="preprocessor"> #define PATH_DOCS "/usr/share/doc/tspsg"</span> 115 <a name="l00072"></a>00072 <span class="preprocessor"></span><span class="preprocessor">#else</span> 116 <a name="l00073"></a><a class="code" href="globals_8h.html#ab1289b7280bd75b023ef2d5b19880af9">00073</a> <span class="preprocessor"></span><span class="preprocessor"> #define PATH_I18N "i18n"</span> 117 <a name="l00074"></a><a class="code" href="globals_8h.html#a93de9563d724c12880c908961ca78dae">00074</a> <span class="preprocessor"></span><span class="preprocessor"> #define PATH_DOCS "help"</span> 118 <a name="l00075"></a>00075 <span class="preprocessor"></span><span class="preprocessor">#endif // Q_OS_LINUX</span> 119 <a name="l00076"></a>00076 <span class="preprocessor"></span> 120 <a name="l00078"></a><a class="code" href="globals_8h.html#abd9c3c65456a20b4b281165a29583e78">00078</a> <span class="preprocessor">#define TSPT quint32(0x54535054)</span> 121 <a name="l00080"></a><a class="code" href="globals_8h.html#afc611d658b90f441ae837a2478b5bdb1">00080</a> <span class="preprocessor">#define TSPT_VERSION quint8(1)</span> 122 <a name="l00082"></a><a class="code" href="globals_8h.html#a4c516e985c6e8edf1b54bcd7c15ad89c">00082</a> <span class="preprocessor">#define TSPT_META_VERSION quint8(1)</span> 123 <a name="l00084"></a><a class="code" href="globals_8h.html#a98ea46119cfda59f7b9c6f50ef72636e">00084</a> <span class="preprocessor">#define TSPT_META_SIZE 2</span> 124 <a name="l00086"></a><a class="code" href="globals_8h.html#a437bcbf6414d33f7a885a4507c1b9940">00086</a> <span class="preprocessor">#define ZKT quint16(0x5A4B)</span> 125 <a name="l00088"></a><a class="code" href="globals_8h.html#ab6d630d0a03e4e53fceb0567653ca629">00088</a> <span class="preprocessor">#define ZKT_VERSION quint8(1)</span> 126 <a name="l00089"></a>00089 <span class="preprocessor"></span> 127 <a name="l00097"></a>00097 <span class="preprocessor">#ifdef INFINITY</span> 128 <a name="l00098"></a>00098 <span class="preprocessor"></span><span class="preprocessor"> #undef INFINITY</span> 129 <a name="l00099"></a>00099 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 130 <a name="l00100"></a><a class="code" href="globals_8h.html#a956e2723d559858d08644ac99146e910">00100</a> <span class="preprocessor"></span><span class="preprocessor">#define INFINITY 1.7E+308</span> 131 <a name="l00102"></a><a class="code" href="globals_8h.html#a1ae8033146e07fa0bae37f148b90cd6b">00102</a> <span class="preprocessor">#define INFSTR "---"</span> 132 <a name="l00103"></a>00103 <span class="preprocessor"></span> 133 <a name="l00104"></a>00104 <span class="comment">// Sanity checks</span> 134 <a name="l00105"></a>00105 <span class="comment">// Check that default number of cities is sane (<= MAX_NUM_CITIES)</span> 135 <a name="l00106"></a>00106 <span class="preprocessor">#if DEF_NUM_CITIES > MAX_NUM_CITIES</span> 136 <a name="l00107"></a>00107 <span class="preprocessor"></span><span class="preprocessor"> #undef DEF_NUM_CITIES</span> 137 <a name="l00108"></a>00108 <span class="preprocessor"></span><span class="preprocessor"> #define DEF_NUM_CITIES MAX_NUM_CITIES</span> 138 <a name="l00109"></a>00109 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 139 <a name="l00110"></a>00110 <span class="preprocessor"></span><span class="comment">// Check that maximum for random generation is sane (<= MAX_RAND_VALUE)</span> 140 <a name="l00111"></a>00111 <span class="preprocessor">#if DEF_RAND_MAX > MAX_RAND_VALUE</span> 141 <a name="l00112"></a>00112 <span class="preprocessor"></span><span class="preprocessor"> #undef DEF_RAND_MAX</span> 142 <a name="l00113"></a>00113 <span class="preprocessor"></span><span class="preprocessor"> #define DEF_RAND_MAX MAX_RAND_VALUE</span> 143 <a name="l00114"></a>00114 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 144 <a name="l00115"></a>00115 <span class="preprocessor"></span><span class="comment">// Check that DEF_RAND_MIN <= DEF_RAND_MAX</span> 145 <a name="l00116"></a>00116 <span class="preprocessor">#if DEF_RAND_MIN > DEF_RAND_MAX</span> 146 <a name="l00117"></a>00117 <span class="preprocessor"></span><span class="preprocessor"> #undef DEF_RAND_MIN</span> 147 <a name="l00118"></a>00118 <span class="preprocessor"></span><span class="preprocessor"> #define DEF_RAND_MIN DEF_RAND_MAX</span> 148 <a name="l00119"></a>00119 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 149 <a name="l00120"></a>00120 <span class="preprocessor"></span> 150 <a name="l00121"></a>00121 <span class="preprocessor">#endif // GLOBALS_H</span> 104 <a name="l00048"></a>00048 <span class="preprocessor"></span> 105 <a name="l00052"></a>00052 <span class="preprocessor">#ifdef Q_OS_WINCE</span> 106 <a name="l00053"></a>00053 <span class="preprocessor"></span><span class="preprocessor"> #define DEF_USE_NATIVE_DIALOGS false</span> 107 <a name="l00054"></a>00054 <span class="preprocessor"></span><span class="preprocessor">#else</span> 108 <a name="l00055"></a><a class="code" href="globals_8h.html#a6bbdc41d8e9d2d8050fb973f058a5521">00055</a> <span class="preprocessor"></span><span class="preprocessor"> #define DEF_USE_NATIVE_DIALOGS true</span> 109 <a name="l00056"></a>00056 <span class="preprocessor"></span><span class="preprocessor">#endif // Q_OS_WINCE</span> 110 <a name="l00058"></a><a class="code" href="globals_8h.html#a26cf35c10c1ed2eab930d839284842c6">00058</a> <span class="preprocessor">#define DEF_AUTOSIZE true</span> 111 <a name="l00060"></a><a class="code" href="globals_8h.html#ad983bd19a9662c6cb6fe5ba981cbdbf4">00060</a> <span class="preprocessor">#define DEF_SAVEPOS false</span> 112 <a name="l00062"></a><a class="code" href="globals_8h.html#a4a1e6c04461eabfc0cc0941d342ecfb4">00062</a> <span class="preprocessor">#define DEF_FRACTIONAL_RANDOM false</span> 113 <a name="l00064"></a><a class="code" href="globals_8h.html#a616d74fa946123f424193b007d5a6382">00064</a> <span class="preprocessor">#define DEF_SHOW_MATRIX true</span> 114 <a name="l00066"></a><a class="code" href="globals_8h.html#ae37fe7eb909d7fd076f067900e900c0e">00066</a> <span class="preprocessor">#define DEF_USE_SHOW_MATRIX_LIMIT true</span> 115 <a name="l00068"></a><a class="code" href="globals_8h.html#a261331d449328e53926027d021757d57">00068</a> <span class="preprocessor">#define DEF_SHOW_MATRIX_LIMIT 15</span> 116 <a name="l00070"></a><a class="code" href="globals_8h.html#a6831bc2c2f11c3a14382c8fbe8d87efe">00070</a> <span class="preprocessor">#define DEF_SCROLL_TO_END true</span> 117 <a name="l00072"></a><a class="code" href="globals_8h.html#a2982eb0f2aea4cff78bd4aa767ff1988">00072</a> <span class="preprocessor">#define DEF_FONT_FAMILY "Courier New"</span> 118 <a name="l00074"></a><a class="code" href="globals_8h.html#ab73bf542bad61b0b720c0495ef612105">00074</a> <span class="preprocessor">#define DEF_FONT_SIZE 10</span> 119 <a name="l00076"></a><a class="code" href="globals_8h.html#a6bbeb8fbbb2c6ec31993ff56f6b695e3">00076</a> <span class="preprocessor">#define DEF_FONT_COLOR Qt::black</span> 120 <a name="l00077"></a>00077 <span class="preprocessor"></span> 121 <a name="l00079"></a><a class="code" href="globals_8h.html#a70edda218af688662bb006cf0552544e">00079</a> <span class="preprocessor">#define MAX_NUM_CITIES 50</span> 122 <a name="l00081"></a><a class="code" href="globals_8h.html#a1703614f274735e91c1539048ef1093f">00081</a> <span class="preprocessor">#define MAX_RAND_VALUE 1000</span> 123 <a name="l00082"></a>00082 <span class="preprocessor"></span> 124 <a name="l00083"></a>00083 <span class="comment">// Paths</span> 125 <a name="l00092"></a>00092 <span class="comment"></span><span class="preprocessor">#if defined(Q_OS_LINUX) || defined(Q_OS_UNIX)</span> 126 <a name="l00093"></a>00093 <span class="preprocessor"></span><span class="preprocessor"> #define PATH_I18N "/usr/share/tspsg/i18n"</span> 127 <a name="l00094"></a>00094 <span class="preprocessor"></span><span class="preprocessor"> #define PATH_DOCS "/usr/share/doc/tspsg"</span> 128 <a name="l00095"></a>00095 <span class="preprocessor"></span><span class="preprocessor">#else</span> 129 <a name="l00096"></a><a class="code" href="globals_8h.html#ab1289b7280bd75b023ef2d5b19880af9">00096</a> <span class="preprocessor"></span><span class="preprocessor"> #define PATH_I18N "i18n"</span> 130 <a name="l00097"></a><a class="code" href="globals_8h.html#a93de9563d724c12880c908961ca78dae">00097</a> <span class="preprocessor"></span><span class="preprocessor"> #define PATH_DOCS "help"</span> 131 <a name="l00098"></a>00098 <span class="preprocessor"></span><span class="preprocessor">#endif // Q_OS_LINUX</span> 132 <a name="l00099"></a>00099 <span class="preprocessor"></span> 133 <a name="l00101"></a><a class="code" href="globals_8h.html#abd9c3c65456a20b4b281165a29583e78">00101</a> <span class="preprocessor">#define TSPT quint32(0x54535054)</span> 134 <a name="l00103"></a><a class="code" href="globals_8h.html#afc611d658b90f441ae837a2478b5bdb1">00103</a> <span class="preprocessor">#define TSPT_VERSION quint8(1)</span> 135 <a name="l00105"></a><a class="code" href="globals_8h.html#a4c516e985c6e8edf1b54bcd7c15ad89c">00105</a> <span class="preprocessor">#define TSPT_META_VERSION quint8(1)</span> 136 <a name="l00107"></a><a class="code" href="globals_8h.html#a98ea46119cfda59f7b9c6f50ef72636e">00107</a> <span class="preprocessor">#define TSPT_META_SIZE 2</span> 137 <a name="l00109"></a><a class="code" href="globals_8h.html#a437bcbf6414d33f7a885a4507c1b9940">00109</a> <span class="preprocessor">#define ZKT quint16(0x5A4B)</span> 138 <a name="l00111"></a><a class="code" href="globals_8h.html#ab6d630d0a03e4e53fceb0567653ca629">00111</a> <span class="preprocessor">#define ZKT_VERSION quint8(1)</span> 139 <a name="l00112"></a>00112 <span class="preprocessor"></span> 140 <a name="l00120"></a>00120 <span class="preprocessor">#ifdef INFINITY</span> 141 <a name="l00121"></a>00121 <span class="preprocessor"></span><span class="preprocessor"> #undef INFINITY</span> 142 <a name="l00122"></a>00122 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 143 <a name="l00123"></a><a class="code" href="globals_8h.html#a956e2723d559858d08644ac99146e910">00123</a> <span class="preprocessor"></span><span class="preprocessor">#define INFINITY 1.7E+308</span> 144 <a name="l00125"></a><a class="code" href="globals_8h.html#a1ae8033146e07fa0bae37f148b90cd6b">00125</a> <span class="preprocessor">#define INFSTR "---"</span> 145 <a name="l00126"></a>00126 <span class="preprocessor"></span> 146 <a name="l00127"></a>00127 <span class="comment">// FUNCTIONS</span> 147 <a name="l00133"></a><a class="code" href="globals_8h.html#a594842d2fcaf774c3c42b944f3f031d2">00133</a> <span class="comment"></span><span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="globals_8h.html#a594842d2fcaf774c3c42b944f3f031d2" title="Checks whether x contains an integer value.">isInteger</a>(<span class="keywordtype">double</span> x) 148 <a name="l00134"></a>00134 { 149 <a name="l00135"></a>00135 <span class="keywordtype">double</span> i; 150 <a name="l00136"></a>00136 <span class="keywordflow">return</span> (modf(x, &i) == 0.0); 151 <a name="l00137"></a>00137 } 152 <a name="l00138"></a>00138 153 <a name="l00139"></a>00139 <span class="comment">// Sanity checks</span> 154 <a name="l00140"></a>00140 <span class="comment">// Check that default number of cities is sane (<= MAX_NUM_CITIES)</span> 155 <a name="l00141"></a>00141 <span class="preprocessor">#if DEF_NUM_CITIES > MAX_NUM_CITIES</span> 156 <a name="l00142"></a>00142 <span class="preprocessor"></span><span class="preprocessor"> #undef DEF_NUM_CITIES</span> 157 <a name="l00143"></a>00143 <span class="preprocessor"></span><span class="preprocessor"> #define DEF_NUM_CITIES MAX_NUM_CITIES</span> 158 <a name="l00144"></a>00144 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 159 <a name="l00145"></a>00145 <span class="preprocessor"></span><span class="comment">// Check that maximum for random generation is sane (<= MAX_RAND_VALUE)</span> 160 <a name="l00146"></a>00146 <span class="preprocessor">#if DEF_RAND_MAX > MAX_RAND_VALUE</span> 161 <a name="l00147"></a>00147 <span class="preprocessor"></span><span class="preprocessor"> #undef DEF_RAND_MAX</span> 162 <a name="l00148"></a>00148 <span class="preprocessor"></span><span class="preprocessor"> #define DEF_RAND_MAX MAX_RAND_VALUE</span> 163 <a name="l00149"></a>00149 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 164 <a name="l00150"></a>00150 <span class="preprocessor"></span><span class="comment">// Check that DEF_RAND_MIN <= DEF_RAND_MAX</span> 165 <a name="l00151"></a>00151 <span class="preprocessor">#if DEF_RAND_MIN > DEF_RAND_MAX</span> 166 <a name="l00152"></a>00152 <span class="preprocessor"></span><span class="preprocessor"> #undef DEF_RAND_MIN</span> 167 <a name="l00153"></a>00153 <span class="preprocessor"></span><span class="preprocessor"> #define DEF_RAND_MIN DEF_RAND_MAX</span> 168 <a name="l00154"></a>00154 <span class="preprocessor"></span><span class="preprocessor">#endif</span> 169 <a name="l00155"></a>00155 <span class="preprocessor"></span> 170 <a name="l00156"></a>00156 <span class="preprocessor">#endif // GLOBALS_H</span> 151 171 </pre></div></div> 152 172 <!--- window showing the filter options --> … … 164 184 </div> 165 185 166 <hr size="1"/><address style="text-align: right;"><small>Generated on Thu Dec 17 00:37:27 2009for TSPSG: TSP Solver and Generator by 186 <hr size="1"/><address style="text-align: right;"><small>Generated on Thu Jan 7 18:22:42 2010 for TSPSG: TSP Solver and Generator by 167 187 <a href="http://www.doxygen.org/index.html"> 168 188 <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address>
Note: See TracChangeset
for help on using the changeset viewer.