void MemberHandler::startLocation(const QXmlAttributes& attrib)
{
  m_defFile = attrib.value("file");
  m_bodyFile = attrib.value("bodyfile");
  QCString s;
  s = attrib.value("line");
  if (!s.isEmpty()) m_defLine=s.toInt();
  s = attrib.value("bodystart");
  if (!s.isEmpty()) m_bodyStart=s.toInt();
  s = attrib.value("bodyend");
  if (!s.isEmpty()) m_bodyEnd=s.toInt();
}
예제 #2
0
void LatexDocVisitor::endLink(const QCString &ref,const QCString &file,const QCString &anchor)
{
    m_t << "}";
    if (ref.isEmpty() && !Config_getBool("PDF_HYPERLINKS"))
    {
        m_t << "{";
        filter(theTranslator->trPageAbbreviation());
        m_t << "}{" << file;
        if (!file.isEmpty() && !anchor.isEmpty()) m_t << "_";
        m_t << anchor << "}";
    }
}
예제 #3
0
void UmlItem::write_description_properties(FileOut & out) {
  if (! description().isEmpty()) {
    static int rank = 0;
    
    out.indent();
    out << "<ownedComment xmi:type=\"uml:Comment\" xmi:id=\"COMMENT_"
      << ++rank << "\" body=\"";
    out.quote(description());
    out << "\"/>\n";
  }

  QCString ste = stereotype();
  
  if (_gen_extension) {
    const QDict<QCString> up = properties();    
    QDictIterator<QCString> it(up);
    
    if (it.current()) {
      out.indent();
      out << "<xmi:Extension extender=\"Bouml\">\n";
      
      if (! ste.isEmpty()) {
	out.indent();
	out << "\t<stereotype name=\"";
	out.quote(ste);
	out << "\"/>\n";
      }
      
      do {
	out.indent();
	out << "\t<taggedValue tag=\"";
	out.quote(it.currentKey());
	out << "\" value=\"";
	out.quote(*(it.current()));
	out << "\"/>\n";
	++it;
      } while (it.current());
      
      out.indent();
      out << "</xmi:Extension>\n";
    }
    else if (! ste.isEmpty()) {
      out.indent();
      out << "<xmi:Extension extender=\"Bouml\"><stereotype name=\"";
      out.quote(ste);
      out << "\"/></xmi:Extension>\n";
    }
  } 
  
  if (ste.contains(':') == 1)
    // probably a stereotype part of profile
    _stereotypes[ste].append(this);
}
예제 #4
0
void DocbookDocVisitor::startDotFile(const QCString &fileName,
    const QCString &width,
    const QCString &height,
    bool hasCaption
    )
{
  QCString baseName=fileName;
  int i;
  if ((i=baseName.findRev('/'))!=-1)
  {
    baseName=baseName.right(baseName.length()-i-1);
  }
  if ((i=baseName.find('.'))!=-1)
  {
    baseName=baseName.left(i);
  }
  baseName.prepend("dot_");
  QCString outDir = Config_getString("DOCBOOK_OUTPUT");
  QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT");
  writeDotGraphFromFile(fileName,outDir,baseName,GOF_BITMAP);
  m_t << "<para>" << endl;
  m_t << "    <figure>" << endl;
  m_t << "        <title></title>" << endl;
  m_t << "        <mediaobject>" << endl;
  m_t << "            <imageobject>" << endl;
  m_t << "                <imagedata";
  if (!width.isEmpty())
  {
    m_t << " width=\"";
    m_t << width;
    m_t << "\"";
  }
  else
  {
    m_t << " width=\"50%\"";
  }
  if (!height.isEmpty())
  {
    m_t << " depth=\"";
    m_t << height;
    m_t << "\"";
  }
  m_t << " align=\"center\" valign=\"middle\" scalefit=\"1\" fileref=\"" << baseName << "." << imgExt << "\">";
  m_t << "</imagedata>" << endl;
  m_t << "            </imageobject>" << endl;
  if (hasCaption)
  {
    m_t << "        <caption>" << endl;
  }
}
예제 #5
0
void LatexDocVisitor::startMscFile(const QCString &fileName,
                                   const QCString &width,
                                   const QCString &height,
                                   bool hasCaption
                                  )
{
  QCString baseName=fileName;
  int i;
  if ((i=baseName.findRev('/'))!=-1)
  {
    baseName=baseName.right(baseName.length()-i-1);
  } 
  if ((i=baseName.find('.'))!=-1)
  {
    baseName=baseName.left(i);
  }
  baseName.prepend("msc_");

  QCString outDir = Config_getString("LATEX_OUTPUT");
  QCString name = fileName;
  writeMscGraphFromFile(name,outDir,baseName,MSC_EPS); 
  if (hasCaption)
  {
    m_t << "\n\\begin{DoxyImage}\n";
  }
  else
  {
    m_t << "\n\\begin{DoxyImageNoCaption}\n"
           "  \\mbox{";
  }
  m_t << "\\includegraphics";
  if (!width.isEmpty())
  {
    m_t << "[width=" << width << "]";
  }
  else if (!height.isEmpty())
  {
    m_t << "[height=" << height << "]";
  }
  else
  {
    m_t << "[width=\\textwidth]";
  }
  m_t << "{" << baseName << "}";

  if (hasCaption)
  {
    m_t << "\n\\caption{";
  }
}
예제 #6
0
void LatexDocVisitor::startLink(const QCString &ref,const QCString &file,const QCString &anchor)
{
  if (ref.isEmpty() && Config_getBool("PDF_HYPERLINKS")) // internal PDF link 
  {
    if (ref.isEmpty()) {
      m_t << "\\hyperlink{";
      if (!file.isEmpty()) m_t << stripPath(file);
      if (!file.isEmpty() && !anchor.isEmpty()) m_t << "_";
      if (!anchor.isEmpty()) m_t << anchor;
      m_t << "}{";
    }
    else
    {
      QCString *dest;
      m_t << "\\href{";
      if ((dest=Doxygen::tagDestinationDict[ref])) m_t << *dest << "/";
      if (!file.isEmpty()) m_t << file << Doxygen::htmlFileExtension;
      if (!anchor.isEmpty()) m_t << "#" << anchor;
      m_t << "}{";
    }
  }
  else if (ref.isEmpty()) // internal non-PDF link
  {
    m_t << "\\doxyref{";
  }
  else // external link
  { 
    m_t << "{\\bf ";
  }
}
예제 #7
0
/**
 * Disconnects "signal" of the client named "sender" from the "slot" of
 * "receiverObj" in the "conn" client.
 *
 * Special case:
 *   If sender & signal are empty all connections that involve
 *       conn & receiverObj (either as receiver or as sender)
 *   are disconnected.
 */
bool DCOPSignals::disconnectSignal(const QCString &sender, const QCString &senderObj, const QCString &signal, DCOPConnection *conn,
                                   const QCString &receiverObj, const QCString &slot)
{
    if(sender.isEmpty() && signal.isEmpty())
    {
        removeConnections(conn, receiverObj);
        return true;
    }

    DCOPSignalConnectionList *list = connections.find(signal);
    if(!list)
        return false; // Not found...

    DCOPSignalConnection *next = 0;
    bool result = false;

    for(DCOPSignalConnection *current = list->first(); current; current = next)
    {
        next = list->next();

        if(current->recvConn != conn)
            continue;

        if(current->senderConn)
        {
            if(current->senderConn->appId != sender)
                continue;
        }
        else if(current->sender != sender)
            continue;

        if(!senderObj.isEmpty() && (current->senderObj != senderObj))
            continue;

        if(!receiverObj.isEmpty() && (current->recvObj != receiverObj))
            continue;

        if(!slot.isEmpty() && (current->slot != slot))
            continue;

        result = true;
        list->removeRef(current);
        conn->signalConnectionList()->removeRef(current);
        if(current->senderConn)
            current->senderConn->signalConnectionList()->removeRef(current);
        delete current;
    }
    return result;
}
예제 #8
0
void UmlState::importActivity(FileIn & in, Token & token) {
  QCString k = token.what();
  const char * kstr = k;
  QCString b = token.valueOf("body");
  
  if (b.isEmpty()) {
    if (! token.closed()) {
      while (in.read(), !token.close(kstr)) {
	QCString s = token.what();
    
	if (s == "body") {
	  b = in.body("body");
	  in.finish(k);
	  break;
	}
	else if ((s == "node") &&
		 (token.xmiType() == "uml:CallOperationAction")) {
	  s = token.valueOf("operation");
	  if (! s.isEmpty()) {
	    if (k == "entry")
	      UnresolvedWithContext::add(this, s, 0);
	    else if (k == "exit")
	      UnresolvedWithContext::add(this, s, 1);
	    else
	      UnresolvedWithContext::add(this, s, 2);
	  }
	  if (! token.closed())
	    in.finish("node");
	  in.finish(k);
	  return;
	}
	else if (! token.closed())
	  in.finish(s);
      }
    }
  }
  else if (! token.closed())
    in.finish(k);
  
  if (! b.isEmpty()) {
    if (k == "entry")
      set_EntryBehavior(b);
    else if (k == "exit")
      set_ExitBehavior(b);
    else
      set_DoActivity(b);
  }

}
예제 #9
0
/*
 * The actual work.
 * Return values: -1 = unknown error, 0 = ok, >0 = error code.
 */
int ChfnProcess::ConverseChfn(const char *pass)
{
  int status=-1;

  QCString line;
  while(1)
  {
    line = readLine();

    if ( line.isEmpty() )
      continue;// discard line

    if ( line.contains( "Password: "******"password" )*/ )
    {
      WaitSlave();
      write(m_Fd, pass, strlen(pass));
      write(m_Fd, "\n", 1);
    }

    line = readLine(); // Let's see what the outcome was

    if ( line.contains( "Changing finger info" ) )
    {
      // do nothing
    }
    else if ( line.contains( "information changed" ) )
    {
      status=0;
      break;
    }
    else if ( line.isEmpty() )
    {
	    status=0;
	    break;
    }
    else if ( line.contains( "Password error" ) || line.contains("Incorrect password") )
    {
      status=PasswordError;
      break;
    }
    else
    {
      status=MiscError;
      m_Error=line;
      break;
    }
  }
  return status;
}
예제 #10
0
void KIMProxy::registeredToDCOP( const QCString& appId )
{
	//kdDebug( 790 ) << k_funcinfo << " appId '" << appId << "'" << endl;
	// check that appId implements our service
	// if the appId ends with a number, i.e. a pid like in foobar-12345,
	if ( appId.isEmpty() )
		return;

	bool newApp = false;
	// get an up to date list of offers in case a new app was installed
	// and check each of the offers that implement the service type we're looking for,
	// to see if any of them are the app that just registered
	const KService::List offers = KServiceType::offers( IM_SERVICE_TYPE );
	KService::List::const_iterator it;
	for ( it = offers.begin(); it != offers.end(); ++it )
	{
		QCString dcopObjectId = "KIMIface";
		QCString dcopService = (*it)->property("X-DCOP-ServiceName").toString().latin1();
		if ( appId.left( dcopService.length() ) == dcopService )
		{
			// if it's not already known, insert it
			if ( !m_im_client_stubs.find( appId ) )
			{
				newApp = true;
				kdDebug( 790 ) << "App: " << appId << ", dcopService: " << dcopService << " started, using it for presence info."<< endl;
				m_im_client_stubs.insert( appId, new KIMIface_stub( d->dc, appId, dcopObjectId ) );
			}
		}
		//else
		//	kdDebug( 790 ) << "App doesn't implement our ServiceType" << endl;
	}
	//if ( newApp )
	//	emit sigPresenceInfoExpired();
}
예제 #11
0
파일: mangen.cpp 프로젝트: AmesianX/doxygen
static QCString getExtension()
{
  /*
   * [.][nuber][rest]
   * in case of . missing, just ignore it
   * in case number missing, just place a 3 in front of it
   */
  QCString ext = Config_getString("MAN_EXTENSION");
  if (ext.isEmpty())
  {
    ext = "3"; 
  }
  else
  {
    if (ext.at(0)=='.')
    {
      if (ext.length()==1)
      {
        ext = "3"; 
      }
      else // strip .
      {
        ext = ext.mid(1);
      }
    }
    if (ext.at(0)<'0' || ext.at(0)>'9')
    {
      ext.prepend("3");
    }
  }
  return ext;
}
예제 #12
0
void ConnectionHandler::respond(int ok, QCString s)
{
    QCString buf;

    switch(ok)
    {
        case Res_OK:
            buf = "OK";
            break;
        case Res_NO:
        default:
            buf = "NO";
            break;
    }

    if(!s.isEmpty())
    {
        buf += ' ';
        buf += s;
    }

    buf += '\n';

    send(m_Fd, buf.data(), buf.length(), 0);
}
예제 #13
0
static void writePageFooter(QTextStream &t,const QCString &lastTitle,
                            const QCString relPath)
{
  if (g_footer.isEmpty())
  {
    t << "<hr size=\"1\"><address style=\"align: right;\"><small>";
    t << theTranslator->trGeneratedAt(
        dateToString(TRUE),
        Config_getString("PROJECT_NAME")
        );
    t << "&nbsp;" << endl << "<a href=\"http://www.doxygen.org/index.html\">";
    t << endl << "<img src=\"" << relPath << "doxygen.png\" alt=\"doxygen\" " 
      << "align=\"middle\" border=\"0\">" << "</a> " << versionString << " ";
    t << "</small></address>";
    if (Debug::isFlagSet(Debug::Validate))
    {
      t << "<p><a href=\"http://validator.w3.org/check/referer\">"
           "<img border=\"0\" src=\"http://www.w3.org/Icons/valid-html401\""
           " height=\"31\" width=\"88\" alt=\"This page is Valid HTML 4.01 "
           "Transitional!\"></a><a href=\"http://jigsaw.w3.org/css-validator/\">"
           "<img style=\"border:0;width:88px;height:31px\" "
           "src=\"http://jigsaw.w3.org/css-validator/images/vcss\" "
           "alt=\"This page uses valid CSS!\"></a></p>";
    }
    t << "\n</body>\n</html>\n";
  }
  else
  {
    t << substituteKeywords(g_footer,convertToHtml(lastTitle),relPath);
  }
}
예제 #14
0
void FixedFormParser::process(const QCString &line, const QString &fileName, int lineNum)
{
    QCString simplified;
    int l = line.length();
    for (int i=0; i < l; ++i)
        if (line[i] != ' ')
            simplified += line[i];

    if ( simplified.isEmpty() ) return;

    QString name;
    if (functionre.search(simplified) != -1)
        name = functionre.cap(3);
    else if (subroutinere.search(simplified) != -1) 
        name = subroutinere.cap(1);
    else
        return;

    FunctionDom method = m_model->create<FunctionModel>();
    method->setName(name);
    method->setFileName(fileName);
    method->setStartPosition(lineNum, 0);

    if( !m_file->hasFunction(method->name()) )
        m_file->addFunction(method);
}
예제 #15
0
파일: doxyapp.cpp 프로젝트: kaos/doxygen
static void lookupSymbols(const QCString &sym)
{
  if (!sym.isEmpty())
  {
    DefinitionIntf *di = Doxygen::symbolMap->find(sym);
    if (di)
    {
      if (di->definitionType()==DefinitionIntf::TypeSymbolList)
      {
        DefinitionListIterator dli(*(DefinitionList*)di);
        Definition *d;
        // for each symbol with the given name
        for (dli.toFirst();(d=dli.current());++dli)
        {
          lookupSymbol(d);
        }
      }
      else
      {
        lookupSymbol((Definition*)di);
      }
    }
    else
    {
      printf("Unknown symbol\n");
    }
  }
}
예제 #16
0
void FixedFormParser::parse(const QString &fileName)
{
    QFile f(QFile::encodeName(fileName));
    if (!f.open(IO_ReadOnly))
        return;
    QTextStream stream(&f);

    m_file = m_model->create<FileModel>();
    m_file->setName( fileName );

    QCString line;
    int lineNum=0, startLineNum=0;
    while (!stream.atEnd()) {
        ++lineNum;
        QCString str = stream.readLine().local8Bit();
        if (!str.isEmpty() && QCString("*Cc#!").find(str[0]) != -1)
            continue;
        // Continuation line
        if (str.length() > 6 && str.left(5) == "     " && str[5] != ' ') {
            line += str.right(str.length()-6);
            continue;
        }
        // An initial or invalid line. We don't care
        // about validity
        process(line, fileName, startLineNum);
        line = str.right(str.length()-6);
        startLineNum = lineNum-1;
    }
    process(line, fileName, startLineNum);

    f.close();

    m_model->addFile( m_file );
}
예제 #17
0
/*!
 * \brief Initialize the Eclipse generator
 *
 * This method opens the XML TOC file and writes headers of the files.
 * \sa finalize()
 */
void EclipseHelp::initialize() 
{
  // -- read path prefix from the configuration
  //m_pathprefix = Config_getString("ECLIPSE_PATHPREFIX");
  //if (m_pathprefix.isEmpty()) m_pathprefix = "html/";

  // -- open the contents file 
  QCString name = Config_getString("HTML_OUTPUT") + "/toc.xml";
  m_tocfile = new QFile(name);
  if (!m_tocfile->open(IO_WriteOnly)) 
  {
    err("Could not open file %s for writing\n", name.data());
    exit(1);
  }

  // -- initialize its text stream
  m_tocstream.setDevice(m_tocfile);
  //m_tocstream.setEncoding(FTextStream::UnicodeUTF8);

  // -- write the opening tag
  QCString title = Config_getString("PROJECT_NAME");
  if (title.isEmpty())
  {
    title = "Doxygen generated documentation";
  }
  m_tocstream << "<toc label=\"" << convertToXML(title) 
              << "\" topic=\"" << convertToXML(m_pathprefix) 
              << "index" << Doxygen::htmlFileExtension << "\">" << endl;
  ++ m_depth;
}
예제 #18
0
KStringList KDEsuClient::getKeys(const QCString &group)
{
    QCString cmd = "GETK ";
    cmd += escape(group);
    cmd += "\n";
    QCString reply;
    command(cmd, &reply);
    int index = 0, pos;
    KStringList list;
    if(!reply.isEmpty())
    {
        // kdDebug(900) << "Found a matching entry: " << reply << endl;
        while(1)
        {
            pos = reply.find('\007', index);
            if(pos == -1)
            {
                if(index == 0)
                    list.append(reply);
                else
                    list.append(reply.mid(index));
                break;
            }
            else
            {
                list.append(reply.mid(index, pos - index));
            }
            index = pos + 1;
        }
    }
    return list;
}
예제 #19
0
void ClangParser::linkInclude(CodeOutputInterface &ol,FileDef *fd,
    uint &line,uint &column,const char *text)
{
  QCString incName = text;
  incName = incName.mid(1,incName.length()-2); // strip ".." or  <..>
  FileDef *ifd=0;
  if (!incName.isEmpty())
  {
    FileName *fn = Doxygen::inputNameDict->find(incName);
    if (fn)
    {
      bool found=false;
      FileNameIterator fni(*fn);
      // for each include name
      for (fni.toFirst();!found && (ifd=fni.current());++fni)
      {
        // see if this source file actually includes the file
        found = fd->isIncluded(ifd->absFilePath());
        //printf("      include file %s found=%d\n",ifd->absFilePath().data(),found);
      }
    }
  }
  if (ifd)
  {
    ol.writeCodeLink(ifd->getReference(),ifd->getOutputFileBase(),0,text,ifd->briefDescriptionAsTooltip());
  }
  else
  {
    codifyLines(ol,ifd,text,line,column,"preprocessor");
  }
}
예제 #20
0
QCString Definition::pathFragment() const
{
  makeResident();
  QCString result;
  if (m_impl->outerScope && m_impl->outerScope!=Doxygen::globalScope)
  {
    result = m_impl->outerScope->pathFragment();
  }
  if (isLinkable())
  {
    if (!result.isEmpty()) result+="/";
    if (definitionType()==Definition::TypeGroup && ((const GroupDef*)this)->groupTitle())
    {
      result+=((const GroupDef*)this)->groupTitle();
    }
    else if (definitionType()==Definition::TypePage && !((const PageDef*)this)->title().isEmpty())
    {
      result+=((const PageDef*)this)->title();
    }
    else
    {
      result+=m_impl->localName;
    }
  }
  else
  {
    result+=m_impl->localName;
  }
  return result;
}
예제 #21
0
void UmlArtifact::genpro() {
  UmlPackage * pack = (UmlPackage *) parent()->parent();
  
  QCString path;

  if (! propertyValue("genpro path", path)) {

    path = pack->cppSrcDir();
  
    if (path.isEmpty())
      path = root_dir();
    else if (QDir::isRelativePath(path)) {
      QDir d(root_dir());
      
      d.cd(path);
      path = d.absPath();
    }
  }

  if (stereotype() == "executable") {
    gen_app(path);
  }
  else
    UmlCom::trace(stereotype() + " : not managed");
}
예제 #22
0
void FileDef::acquireFileVersion()
{
  QCString vercmd = Config_getString("FILE_VERSION_FILTER");
  if (!vercmd.isEmpty() && filepath!="generated") 
  {
    msg("Version of %s : ",filepath.data());
    QCString cmd = vercmd+" \""+filepath+"\"";
    Debug::print(Debug::ExtCmd,0,"Executing popen(`%s`)\n",cmd.data());
    FILE *f=portable_popen(cmd,"r");
    if (!f)
    {
      err("error: could not execute %s\n",vercmd.data());
      return;
    }
    const int bufSize=1024;
    char buf[bufSize];
    int numRead = fread(buf,1,bufSize,f);
    portable_pclose(f);
    if (numRead > 0) 
    {
      fileVersion = QCString(buf,numRead).stripWhiteSpace();
      msg("%s\n",fileVersion.data());
    }
    else 
    {
      msg("no version available\n");
    }
  }
}
예제 #23
0
bool OutputList::generateDoc(const char *fileName,int startLine,
                  Definition *ctx,MemberDef * md,
                  const QCString &docStr,bool indexWords,
                  bool isExample,const char *exampleName,
                  bool singleLine,bool linkFromIndex)
{
  int count=0;
  if (docStr.isEmpty()) return TRUE;

  QListIterator<OutputGenerator> it(m_outputs);
  OutputGenerator *og;
  for (it.toFirst();(og=it.current());++it)
  {
    if (og->isEnabled()) count++;
  }
  if (count==0) return TRUE; // no output formats enabled.

  DocRoot *root=0;
  root = validatingParseDoc(fileName,startLine,
                            ctx,md,docStr,indexWords,isExample,exampleName,
                            singleLine,linkFromIndex);

  writeDoc(root,ctx,md);

  bool isEmpty = root->isEmpty();

  delete root;

  return isEmpty;
}
예제 #24
0
QCString SshProcess::dcopForward()
{
    QCString result;

    setDcopTransport("tcp");

    QCString srv = StubProcess::dcopServer();
    if(srv.isEmpty())
        return result;

    int i = srv.find('/');
    if(i == -1)
        return result;
    if(srv.left(i) != "tcp")
        return result;
    int j = srv.find(':', ++i);
    if(j == -1)
        return result;
    QCString host = srv.mid(i, j - i);
    bool ok;
    int port = srv.mid(++j).toInt(&ok);
    if(!ok)
        return result;

    m_dcopPort = 10000 + (int)((40000.0 * rand()) / (1.0 + RAND_MAX));
    result.sprintf("%d:%s:%d", m_dcopPort, host.data(), port);
    return result;
}
예제 #25
0
QCString writePlantUMLSource(const QCString &outDir,const QCString &fileName,const QCString &content)
{
  QCString baseName(4096);
  static int umlindex=1;

  if (fileName.isEmpty()) // generate name
  {
    baseName = outDir+"/inline_umlgraph_"+QCString().setNum(umlindex++);
  }
  else // user specified name
  {
    baseName = fileName;
    int i=baseName.findRev('.');
    if (i!=-1) baseName = baseName.left(i);
    baseName.prepend(outDir+"/");
  }
  QFile file(baseName+".pu");
  if (!file.open(IO_WriteOnly))
  {
    err("Could not open file %s for writing\n",baseName.data());
  }
  QCString text = "@startuml\n";
  text+=content;
  text+="@enduml\n";
  file.writeBlock( text, text.length() );
  file.close();
  return baseName;
}
예제 #26
0
static QCString getListOfBibFiles(const QCString &sep,bool stripExtension)
{
  QCString result;
  QStrList &citeDataList = Config_getList("CITE_BIB_FILES");
  const char *bibdata = citeDataList.first();
  while (bibdata)
  {
    int i;
    QCString bibFile = bibdata;
    if (stripExtension && bibFile.right(4)==".bib")
    {
      bibFile = bibFile.left(bibFile.length()-4);
    }
    if (stripExtension && (i=bibFile.findRev('/'))!=-1)
    {
      bibFile = bibFile.mid(i+1);
    }
    if (!bibFile.isEmpty())
    {
      result+=bibFile;
      bibdata = citeDataList.next();
      if (bibdata)
      {
        result+=sep;
      }
    }
    else
    {
      bibdata = citeDataList.next();
    }
  }
  return result;
}
예제 #27
0
파일: diagram.cpp 프로젝트: dnjsflagh1/code
static void writeMapArea(FTextStream &t,ClassDef *cd,QCString relPath,
                         int x,int y,int w,int h)
{
  if (cd->isLinkable())
  {
    QCString ref=cd->getReference();
    t << "<area ";
    if (!ref.isEmpty()) 
    {
      t << externalLinkTarget() << externalRef(relPath,ref,FALSE);
    }
    t << "href=\"";
    t << externalRef(relPath,ref,TRUE);
    t << cd->getOutputFileBase() << Doxygen::htmlFileExtension;
    if (!cd->anchor().isEmpty())
    {
      t << "#" << cd->anchor();
    }
    t << "\" ";
    QCString tooltip = cd->briefDescriptionAsTooltip();
    if (!tooltip.isEmpty())
    {
      t << "title=\"" << tooltip << "\" ";
    }
    t << "alt=\"" << convertToXML(cd->displayName()); 
    t << "\" shape=\"rect\" coords=\"" << x << "," << y << ",";
    t << (x+w) << "," << (y+h) << "\"/>" << endl;
  }
}
예제 #28
0
void TESession::zmodemStatus(KProcess *, char *data, int len)
{
    QCString msg(data, len+1);
    while(!msg.isEmpty())
    {
        int i = msg.find('\015');
        int j = msg.find('\012');
        QCString txt;
        if ((i != -1) && ((j == -1) || (i < j)))
        {
            msg = msg.mid(i+1);
        }
        else if (j != -1)
        {
            txt = msg.left(j);
            msg = msg.mid(j+1);
        }
        else
        {
            txt = msg;
            msg.truncate(0);
        }
        if (!txt.isEmpty())
            zmodemProgress->addProgressText(QString::fromLocal8Bit(txt));
    }
}
예제 #29
0
void NLNoatun::update()
{
	// Thanks mETz for telling me about Noatun's currentProperty()
	m_playing = false;
	QString newTrack;
	// see if it's registered with DCOP
	QCString appname = find();
	if ( !appname.isEmpty() )
	{
		// see if it's playing
		QByteArray data, replyData;
		QCString replyType;
		if ( !m_client->call( appname, "Noatun", "state()", data,
					replyType, replyData ) )
		{
			kdDebug( 14307 ) <<  "NLNoatun::update() DCOP error on " << appname << endl;
		}
		else
		{
			QDataStream reply( replyData, IO_ReadOnly );
			if ( replyType == "int" ) {
				int state = 0;
				reply >> state;
				m_playing = ( state == 2 );
				//kdDebug( 14307 ) << "checked if Noatun is playing!" << endl;
			}
		}
예제 #30
0
void FileIn::bypassedId(Token & tk) {
  QCString s = tk.xmiId();
  
  if (! s.isEmpty())
    BypassedIds.insert(QString(s), "");

}