summaryrefslogtreecommitdiffstats
path: root/dcop/dcopidl2cpp/type.h
blob: baaacacfbd4f69ae4d202035327d5f5473b8242a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#ifndef TYPE_H
#define TYPE_H

#include <qtextstream.h>
#include <qdom.h>

static QString writeType( QTextStream& str, const QDomElement& r )
{
  Q_ASSERT( r.tagName() == "TYPE" );
  if ( r.hasAttribute( "qleft" ) )
    str << r.attribute("qleft") << " ";
  QString t = r.firstChild().toText().data();
  t = t.replace( ">>", "> >" );
  str << t;
  if ( r.hasAttribute( "qright" ) )
    str << r.attribute("qright") << " ";
  else
    str << " ";
  return t;
}

#endif