kradio4  r778
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
utils.h
Go to the documentation of this file.
1 /***************************************************************************
2  utils.h - description
3  -------------------
4  begin : Sun Feb 3 2002
5  copyright : (C) 2002 by Martin Witte / Frank Schwanz
6  email : emw-kradio@nocabal.de / schwanz@fh-brandenburg.de
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  ***************************************************************************/
17 
18 #ifndef KRADIO_UTILS_H
19 #define KRADIO_UTILS_H
20 
21 #ifdef HAVE_CONFIG_H
22 #include <config.h>
23 #endif
24 
25 using namespace std;
26 
27 #include <kconfig.h>
28 #include <klocale.h>
29 #include <kdebug.h>
30 #include <QtCore/QString>
31 #define __USE_ISOC99 1
32 #include <math.h>
33 
34 //extern const char *mixerChannelLabels[];
35 //extern const char *mixerChannelNames[];
36 
37 extern QString XMLEscape (const QString &s);
38 QString xmlOpenTag (const QString &tag, bool newline = true);
39 QString xmlTag (const QString &tag, const QString &s, bool newline = true);
40 QString xmlTag (const QString &tag, int i, bool newline = true);
41 QString xmlTag (const QString &tag, float f, bool newline = true);
42 QString xmlCloseTag (const QString &tag, bool newline = true);
43 
44 template<class T1, class T2> inline T1 min (T1 a, T2 b) { return a < b ? a : b; }
45 template<class T1, class T2> inline T1 max (T1 a, T2 b) { return a < b ? b : a; }
46 
47 #endif
T1 max(T1 a, T2 b)
Definition: utils.h:45
QString xmlCloseTag(const QString &tag, bool newline=true)
QString XMLEscape(const QString &s)
QString xmlTag(const QString &tag, const QString &s, bool newline=true)
QString xmlOpenTag(const QString &tag, bool newline=true)
T1 min(T1 a, T2 b)
Definition: utils.h:44