Index: src/rtfdocvisitor.cpp
===================================================================
--- src/rtfdocvisitor.cpp	(révision 741)
+++ src/rtfdocvisitor.cpp	(copie de travail)
@@ -22,6 +22,7 @@
 #include "doxygen.h"
 #include "outputgen.h"
 #include "dot.h"
+#include "msc.h"
 #include "util.h"
 #include "rtfstyle.h"
 #include "message.h"
@@ -1080,7 +1081,22 @@
   DBG_RTF("{\\comment RTFDocVisitor::visitPost(DocDotFile)}\n");
   popEnabled();
 }
+void RTFDocVisitor::visitPre(DocMscFile *df)
+{
+  DBG_RTF("{\\comment RTFDocVisitor::visitPre(MscDotFile)}\n");
+  writeMscFile(df->file());
 
+  // hide caption since it is not supported at the moment
+  pushEnabled();
+  m_hide=TRUE;
+}
+
+void RTFDocVisitor::visitPost(DocMscFile *) 
+{
+  DBG_RTF("{\\comment RTFDocVisitor::visitPost(MscDotFile)}\n");
+  popEnabled();
+}
+
 void RTFDocVisitor::visitPre(DocLink *lnk)
 {
   if (m_hide) return;
Index: src/docvisitor.h
===================================================================
--- src/docvisitor.h	(révision 741)
+++ src/docvisitor.h	(copie de travail)
@@ -65,6 +65,7 @@
 class DocHtmlHeader;
 class DocImage;
 class DocDotFile;
+class DocMscFile;
 class DocLink;
 class DocRef;
 class DocFormula;
@@ -158,7 +159,9 @@
     virtual void visitPost(DocImage *) = 0;
     virtual void visitPre(DocDotFile *) = 0;
     virtual void visitPost(DocDotFile *) = 0;
-    virtual void visitPre(DocLink *) = 0;
+     virtual void visitPre(DocMscFile *) = 0;
+    virtual void visitPost(DocMscFile *) = 0;   
+virtual void visitPre(DocLink *) = 0;
     virtual void visitPost(DocLink *) = 0;
     virtual void visitPre(DocRef *) = 0;
     virtual void visitPost(DocRef *) = 0;
Index: src/portable.cpp
===================================================================
--- src/portable.cpp	(révision 741)
+++ src/portable.cpp	(copie de travail)
@@ -43,9 +43,9 @@
   }
   fullCmd += " ";
   fullCmd += args;
-#ifndef NODEBUG
+//#ifndef NODEBUG
   Debug::print(Debug::ExtCmd,0,"Executing external command `%s`\n",fullCmd.data());
-#endif
+//#endif
 
 #if !defined(_WIN32) || defined(__CYGWIN__)
   commandHasConsole=commandHasConsole;
Index: src/cmdmapper.cpp
===================================================================
--- src/cmdmapper.cpp	(révision 741)
+++ src/cmdmapper.cpp	(copie de travail)
@@ -37,7 +37,7 @@
   { "dontinclude",   CMD_DONTINCLUDE },
   { "dotfile",       CMD_DOTFILE },
   { "e",             CMD_EMPHASIS },
-  { "em",            CMD_EMPHASIS },
+  { "em",            CMD_EMPHASIS} ,
   { "endcode",       CMD_ENDCODE },
   { "endhtmlonly",   CMD_ENDHTMLONLY },
   { "endlatexonly",  CMD_ENDLATEXONLY },
@@ -112,7 +112,8 @@
   { "endmanonly",    CMD_ENDMANONLY },
   { "includelineno", CMD_INCWITHLINES },
   { "inheritdoc",    CMD_INHERITDOC },
-  { 0,               0 }
+  { "mscfile",       CMD_MSCFILE },
+  { 0,               0 },
 };
 
 //----------------------------------------------------------------------------
Index: src/mandocvisitor.cpp
===================================================================
--- src/mandocvisitor.cpp	(révision 741)
+++ src/mandocvisitor.cpp	(copie de travail)
@@ -718,7 +718,15 @@
 void ManDocVisitor::visitPost(DocDotFile *) 
 {
 }
+void ManDocVisitor::visitPre(DocMscFile *)
+{
+}
 
+void ManDocVisitor::visitPost(DocMscFile *) 
+{
+}
+
+
 void ManDocVisitor::visitPre(DocLink *)
 {
   if (m_hide) return;
Index: src/rtfdocvisitor.h
===================================================================
--- src/rtfdocvisitor.h	(révision 741)
+++ src/rtfdocvisitor.h	(copie de travail)
@@ -104,7 +104,9 @@
     void visitPost(DocImage *);
     void visitPre(DocDotFile *);
     void visitPost(DocDotFile *);
-    void visitPre(DocLink *lnk);
+    void visitPre(DocMscFile *);
+    void visitPost(DocMscFile *);
+    void visitPre(DocLink *);
     void visitPost(DocLink *);
     void visitPre(DocRef *ref);
     void visitPost(DocRef *);
Index: src/printdocvisitor.h
===================================================================
--- src/printdocvisitor.h	(révision 741)
+++ src/printdocvisitor.h	(copie de travail)
@@ -503,6 +503,16 @@
       indent_post();
       printf("</dotfile>\n");
     }
+    void visitPre(DocMscFile *df)
+    {
+      indent_pre();
+      printf("<mscfile src=\"%s\">\n",df->name().data());
+    }
+    void visitPost(DocMscFile *) 
+    {
+      indent_post();
+      printf("</mscfile>\n");
+    }
     void visitPre(DocLink *lnk)
     {
       indent_pre();
Index: src/xmldocvisitor.h
===================================================================
--- src/xmldocvisitor.h	(révision 741)
+++ src/xmldocvisitor.h	(copie de travail)
@@ -96,7 +96,8 @@
     void visitPre(DocHtmlCaption *);
     void visitPost(DocHtmlCaption *);
     void visitPre(DocInternal *);
-    void visitPost(DocInternal *);
+    
+void visitPost(DocInternal *);
     void visitPre(DocHRef *);
     void visitPost(DocHRef *);
     void visitPre(DocHtmlHeader *);
@@ -105,6 +106,9 @@
     void visitPost(DocImage *);
     void visitPre(DocDotFile *);
     void visitPost(DocDotFile *);
+
+    void visitPre(DocMscFile *);
+    void visitPost(DocMscFile *);
     void visitPre(DocLink *);
     void visitPost(DocLink *);
     void visitPre(DocRef *);
Index: src/configoptions.cpp
===================================================================
--- src/configoptions.cpp	(révision 741)
+++ src/configoptions.cpp	(copie de travail)
@@ -2186,6 +2186,14 @@
   cl->addDependency("HAVE_DOT");
   cl->setWidgetType(ConfigList::Dir);
   //----
+  cl = cfg->addList(
+                 "MSCFILE_DIRS",
+                 "The MSCFILE_DIRS tag can be used to specify one or more directories that\n"
+                 "contain msc files that are included in the documentation (see the\n"
+                 "\\mscfile command)."
+                );
+  cl->setWidgetType(ConfigList::Dir);
+  //----
   ci = cfg->addInt(
                  "DOT_GRAPH_MAX_NODES",
                  "The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of\n"
Index: src/docparser.cpp
===================================================================
--- src/docparser.cpp	(révision 741)
+++ src/docparser.cpp	(copie de travail)
@@ -2526,7 +2526,88 @@
   ASSERT(n==this);
 }
 
+DocMscFile::DocMscFile(DocNode *parent,const QCString &name,const QCString &context) : 
+      m_name(name), m_relPath(g_relPath), m_context(context)
+{
+  m_parent = parent; 
+}
 
+void DocMscFile::parse()
+{
+  g_nodeStack.push(this);
+  DBG(("DocMscFile::parse() start\n"));
+
+  doctokenizerYYsetStateTitle();
+  int tok;
+  while ((tok=doctokenizerYYlex()))
+  {
+    if (!defaultHandleToken(this,tok,m_children))
+    {
+      switch (tok)
+      {
+        case TK_COMMAND: 
+          warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: Illegal command %s as part of a \\mscfile",
+	       qPrint(g_token->name));
+          break;
+        case TK_SYMBOL: 
+	  warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: Unsupported symbol %s found",
+               qPrint(g_token->name));
+          break;
+        default:
+	  warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: Unexpected token %s",
+		tokToString(tok));
+          break;
+      }
+    }
+  }
+  tok=doctokenizerYYlex();
+  while (tok==TK_WORD) // there are values following the title
+  {
+    if (g_token->name=="width") 
+    {
+      m_width=g_token->chars;
+    }
+    else if (g_token->name=="height") 
+    {
+      m_height=g_token->chars;
+    }
+    else 
+    {
+      warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: Unknown option %s after image title",
+            qPrint(g_token->name));
+    }
+    tok=doctokenizerYYlex();
+  }
+  ASSERT(tok==0);
+  doctokenizerYYsetStatePara();
+  handlePendingStyleCommands(this,m_children);
+
+  bool ambig;
+  FileDef *fd = findFileDef(Doxygen::mscFileNameDict,m_name,ambig);
+  if (fd)
+  {
+    m_file = fd->absFilePath();
+  }
+  else if (ambig)
+  {
+    warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: included msc file name %s is ambiguous.\n"
+           "Possible candidates:\n%s",qPrint(m_name),
+           qPrint(showFileDefMatches(Doxygen::exampleNameDict,m_name))
+          );
+  }
+  else
+  {
+    warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: included dot file %s is not found "
+           "in any of the paths specified via MSCFILE_DIRS!",qPrint(m_name));
+  }
+
+  DBG(("DocMscFile::parse() end\n"));
+  DocNode *n=g_nodeStack.pop();
+  ASSERT(n==this);
+}
+
+
+
 //---------------------------------------------------------------------------
 
 DocImage::DocImage(DocNode *parent,const HtmlAttribList &attribs,const QCString &name,Type t) : 
@@ -4391,6 +4472,29 @@
   m_children.append(df);
   df->parse();
 }
+void DocPara::handleMscFile(const QCString &cmdName)
+{
+  int tok=doctokenizerYYlex();
+  if (tok!=TK_WHITESPACE)
+  {
+    warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: expected whitespace after %s command",
+        qPrint(cmdName));
+    return;
+  }
+  doctokenizerYYsetStateFile();
+  tok=doctokenizerYYlex();
+  doctokenizerYYsetStatePara();
+  if (tok!=TK_WORD)
+  {
+    warn_doc_error(g_fileName,doctokenizerYYlineno,"warning: unexpected token %s as the argument of %s",
+        tokToString(tok),qPrint(cmdName));
+    return;
+  }
+  QCString name = g_token->name;
+  DocMscFile *df = new DocMscFile(this,name,g_context);
+  m_children.append(df);
+  df->parse();
+}
 
 void DocPara::handleLink(const QCString &cmdName,bool isJavaLink)
 {
@@ -4903,6 +5007,9 @@
     case CMD_DOTFILE:
       handleDotFile(cmdName);
       break;
+    case CMD_MSCFILE:
+      handleMscFile(cmdName);
+      break;
     case CMD_LINK:
       handleLink(cmdName,FALSE);
       break;
Index: src/mandocvisitor.h
===================================================================
--- src/mandocvisitor.h	(révision 741)
+++ src/mandocvisitor.h	(copie de travail)
@@ -104,6 +104,8 @@
     void visitPost(DocImage *);
     void visitPre(DocDotFile *);
     void visitPost(DocDotFile *);
+    void visitPre(DocMscFile *);
+    void visitPost(DocMscFile *);
     void visitPre(DocLink *lnk);
     void visitPost(DocLink *);
     void visitPre(DocRef *ref);
Index: src/htmldocvisitor.cpp
===================================================================
--- src/htmldocvisitor.cpp	(révision 741)
+++ src/htmldocvisitor.cpp	(copie de travail)
@@ -1224,6 +1224,26 @@
   m_t << "</div>" << endl;
 }
 
+void HtmlDocVisitor::visitPre(DocMscFile *df)
+{
+  if (m_hide) return;
+  writeMscFile(df->file(),df->relPath(),df->context());
+  m_t << "<div align=\"center\">" << endl;
+  if (df->hasCaption())
+  { 
+    m_t << "<p><strong>";
+  }
+}
+void HtmlDocVisitor::visitPost(DocMscFile *df) 
+{
+  if (m_hide) return;
+  if (df->hasCaption())
+  {
+    m_t << "</strong></p>" << endl;
+  }
+  m_t << "</div>" << endl;
+}
+
 void HtmlDocVisitor::visitPre(DocLink *lnk)
 {
   if (m_hide) return;
Index: src/docparser.h
===================================================================
--- src/docparser.h	(révision 741)
+++ src/docparser.h	(copie de travail)
@@ -131,7 +131,8 @@
                 Kind_ParamList      = 44,
                 Kind_InternalRef    = 45,
                 Kind_Copy           = 46,
-                Kind_Text           = 47
+                Kind_Text           = 47,
+		Kind_MscFile        = 48,
               };
     /*! Creates a new node */
     DocNode() : m_parent(0), m_insidePre(FALSE) {}
@@ -608,6 +609,31 @@
     QCString  m_context;
 };
 
+/*! @brief Node representing a msc file */
+class DocMscFile : public CompAccept<DocMscFile>, public DocNode
+{
+  public:
+    DocMscFile(DocNode *parent,const QCString &name,const QCString &context);
+    void parse();
+    Kind kind() const          { return Kind_MscFile; }
+    QCString name() const       { return m_name; }
+    QCString file() const       { return m_file; }
+    QCString relPath() const    { return m_relPath; }
+    bool hasCaption() const    { return !m_children.isEmpty(); }
+    QCString width() const      { return m_width; }
+    QCString height() const     { return m_height; }
+    QCString context() const    { return m_context; }
+    void accept(DocVisitor *v) { CompAccept<DocMscFile>::accept(this,v); }
+  private:
+    QCString  m_name;
+    QCString  m_file;
+    QCString  m_relPath;
+    QCString  m_width;
+    QCString  m_height;
+    QCString  m_context;
+};
+
+
 /*! @brief Node representing a link to some item */
 class DocLink : public CompAccept<DocLink>, public DocNode
 {
@@ -944,6 +970,7 @@
     void handleIncludeOperator(const QCString &cmdName,DocIncOperator::Type t);
     void handleImage(const QCString &cmdName);
     void handleDotFile(const QCString &cmdName);
+    void handleMscFile(const QCString &cmdName);
     void handleInclude(const QCString &cmdName,DocInclude::Type t);
     void handleLink(const QCString &cmdName,bool isJavaLink);
     void handleRef(const QCString &cmdName);
Index: src/cmdmapper.h
===================================================================
--- src/cmdmapper.h	(révision 741)
+++ src/cmdmapper.h	(copie de travail)
@@ -113,7 +113,8 @@
   CMD_TPARAM       = 79 | SIMPLESECT_BIT,
   CMD_COPYBRIEF    = 80,
   CMD_COPYDETAILS  = 81,
-  CMD_QUOTE        = 82 
+  CMD_QUOTE        = 82,
+  CMD_MSCFILE      = 83, 
 };
 
 enum HtmlTagType
@@ -189,7 +190,7 @@
       return !name.isEmpty() && (result=m_map.find(name)) ? *result: 0;
     }
 
-    Mapper(const CommandMap *cm,bool caseSensitive) : m_map(89), m_cs(caseSensitive)
+    Mapper(const CommandMap *cm,bool caseSensitive) : m_map(90), m_cs(caseSensitive)
     {
       m_map.setAutoDelete(TRUE);
       const CommandMap *p = cm;
Index: src/htmldocvisitor.h
===================================================================
--- src/htmldocvisitor.h	(révision 741)
+++ src/htmldocvisitor.h	(copie de travail)
@@ -103,6 +103,8 @@
     void visitPost(DocImage *);
     void visitPre(DocDotFile *);
     void visitPost(DocDotFile *);
+    void visitPre(DocMscFile *);
+    void visitPost(DocMscFile *);
     void visitPre(DocLink *);
     void visitPost(DocLink *);
     void visitPre(DocRef *);
Index: src/doxygen.h
===================================================================
--- src/doxygen.h	(révision 741)
+++ src/doxygen.h	(copie de travail)
@@ -92,6 +92,7 @@
     static FileNameList             *inputNameList;
     static FileNameDict             *imageNameDict;
     static FileNameDict             *dotFileNameDict;
+    static FileNameDict             *mscFileNameDict;
     static QStrList                  tagfileList;
     static MemberNameSDict          *memberNameSDict;
     static MemberNameSDict          *functionNameSDict;
Index: src/config.xml
===================================================================
--- src/config.xml	(révision 741)
+++ src/config.xml	(copie de travail)
@@ -1431,6 +1431,14 @@
 \dotfile command). 
 ' depends='HAVE_DOT'>
     </option>
+    <option type='list' id='MSCFILE_DIRS' format='dir' docs='
+The MSCFILE_DIRS tag can be used to specify one or more directories that 
+contain msc files that are included in the documentation (see the 
+\mscfile command). 
+' >
+    </option>
+
+
     <option type='int' id='DOT_GRAPH_MAX_NODES' docs='
 The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of 
 nodes that will be shown in the graph. If the number of nodes in a graph 
Index: src/textdocvisitor.h
===================================================================
--- src/textdocvisitor.h	(révision 741)
+++ src/textdocvisitor.h	(copie de travail)
@@ -102,6 +102,9 @@
     void visitPost(DocImage *) {}
     void visitPre(DocDotFile *) {}
     void visitPost(DocDotFile *) {}
+
+    void visitPre(DocMscFile *) {}
+    void visitPost(DocMscFile *) {}
     void visitPre(DocLink *) {}
     void visitPost(DocLink *) {}
     void visitPre(DocRef *) {}
Index: src/latexdocvisitor.h
===================================================================
--- src/latexdocvisitor.h	(révision 741)
+++ src/latexdocvisitor.h	(copie de travail)
@@ -106,6 +106,8 @@
     void visitPost(DocImage *);
     void visitPre(DocDotFile *);
     void visitPost(DocDotFile *);
+    void visitPre(DocMscFile *);
+    void visitPost(DocMscFile *);
     void visitPre(DocLink *lnk);
     void visitPost(DocLink *);
     void visitPre(DocRef *ref);
@@ -144,6 +146,10 @@
     void startDotFile(const QCString &fileName,const QCString &width,
                       const QCString &height, bool hasCaption);
     void endDotFile(bool hasCaption);
+
+    void startMscFile(const QCString &fileName,const QCString &width,
+                      const QCString &height, bool hasCaption);
+    void endMscFile(bool hasCaption);
     void writeMscFile(const QCString &fileName);
 
     void pushEnabled();
Index: src/latexdocvisitor.cpp
===================================================================
--- src/latexdocvisitor.cpp	(révision 741)
+++ src/latexdocvisitor.cpp	(copie de travail)
@@ -1006,7 +1006,17 @@
   if (m_hide) return;
   endDotFile(df->hasCaption());
 }
+void LatexDocVisitor::visitPre(DocMscFile *df)
+{
+  if (m_hide) return;
+  startMscFile(df->file(),df->width(),df->height(),df->hasCaption());
+}
 
+void LatexDocVisitor::visitPost(DocMscFile *df) 
+{
+  if (m_hide) return;
+  endMscFile(df->hasCaption());
+}
 void LatexDocVisitor::visitPre(DocLink *lnk)
 {
   if (m_hide) return;
@@ -1358,6 +1368,70 @@
   }
 }
 
+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 (baseName.right(4)==".eps" || baseName.right(4)==".pdf")
+  {
+    baseName=baseName.left(baseName.length()-4);
+  }
+  if (baseName.right(4)==".dot")
+  {
+    baseName=baseName.left(baseName.length()-4);
+  }
+  QCString outDir = Config_getString("LATEX_OUTPUT");
+  QCString name = fileName;
+//  writeMscGraphFromFile(name,outDir,baseName,EPS); TODO: fix
+  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 << "]";
+  }
+  m_t << "{" << baseName << "}";
+
+  if (hasCaption)
+  {
+    m_t << "\n\\caption{";
+  }
+}
+
+void LatexDocVisitor::endMscFile(bool hasCaption)
+{
+  if (m_hide) return;
+  m_t << "}\n"; // end caption or mbox
+  if (hasCaption)
+  {
+    m_t << "\\end{DoxyImage}\n";
+  }
+  else
+  {
+    m_t << "\\end{DoxyImageNoCaption}\n";
+  }
+}
+
+
 void LatexDocVisitor::writeMscFile(const QCString &baseName)
 {
   QCString shortName = baseName;
Index: src/perlmodgen.cpp
===================================================================
--- src/perlmodgen.cpp	(révision 741)
+++ src/perlmodgen.cpp	(copie de travail)
@@ -350,6 +350,8 @@
   void visitPost(DocImage *);
   void visitPre(DocDotFile *);
   void visitPost(DocDotFile *);
+  void visitPre(DocMscFile *);
+  void visitPost(DocMscFile *);
   void visitPre(DocLink *);
   void visitPost(DocLink *);
   void visitPre(DocRef *);
@@ -1094,7 +1096,21 @@
   m_output.add("</dotfile>");
 #endif
 }
+void PerlModDocVisitor::visitPre(DocMscFile *)
+{
+#if 0
+  m_output.add("<mscfile name=\""); m_output.add(df->file()); m_output.add("\">");
+#endif
+}
 
+void PerlModDocVisitor::visitPost(DocMscFile *)
+{
+#if 0
+  m_output.add("</dotfile>");
+#endif
+}
+
+
 void PerlModDocVisitor::visitPre(DocLink *lnk)
 {
   openItem("link");
Index: src/xmldocvisitor.cpp
===================================================================
--- src/xmldocvisitor.cpp	(révision 741)
+++ src/xmldocvisitor.cpp	(copie de travail)
@@ -711,6 +711,17 @@
   m_t << "</dotfile>" << endl;
 }
 
+void XmlDocVisitor::visitPre(DocMscFile *df)
+{
+  if (m_hide) return;
+  m_t << "<mscfile name=\"" << df->file() << "\">";
+}
+
+void XmlDocVisitor::visitPost(DocMscFile *) 
+{
+  if (m_hide) return;
+  m_t << "</dotfile>" << endl;
+}
 void XmlDocVisitor::visitPre(DocLink *lnk)
 {
   if (m_hide) return;
Index: src/doxygen.cpp
===================================================================
--- src/doxygen.cpp	(révision 741)
+++ src/doxygen.cpp	(copie de travail)
@@ -40,6 +40,7 @@
 #include "pre.h"
 #include "tagreader.h"
 #include "dot.h"
+#include "msc.h"
 #include "docparser.h"
 #include "dirdef.h"
 #include "outputlist.h"
@@ -112,6 +113,7 @@
 FileNameDict    *Doxygen::exampleNameDict = 0;     // examples
 FileNameDict    *Doxygen::imageNameDict = 0;       // images
 FileNameDict    *Doxygen::dotFileNameDict = 0;     // dot files
+FileNameDict    *Doxygen::mscFileNameDict = 0;     // dot files
 StringDict       Doxygen::namespaceAliasDict(257); // all namespace aliases
 StringDict       Doxygen::tagDestinationDict(257); // all tag locations
 QDict<void>      Doxygen::expandAsDefinedDict(257); // all macros that should be expanded
@@ -174,6 +176,7 @@
   Doxygen::exampleNameDict->clear();  
   Doxygen::imageNameDict->clear();     
   Doxygen::dotFileNameDict->clear();     
+  Doxygen::mscFileNameDict->clear();     
   Doxygen::formulaDict.clear();      
   Doxygen::formulaNameDict.clear();  
   Doxygen::tagDestinationDict.clear();
@@ -192,6 +195,8 @@
   Doxygen::imageNameDict->statistics();
   fprintf(stderr,"--- dotFileNameDict stats ----\n");
   Doxygen::dotFileNameDict->statistics();
+  fprintf(stderr,"--- mscFileNameDict stats ----\n");
+  Doxygen::mscFileNameDict->statistics();
   //fprintf(stderr,"--- g_excludeNameDict stats ----\n");
   //g_excludeNameDict.statistics();
   fprintf(stderr,"--- aliasDict stats ----\n");
@@ -9141,6 +9146,7 @@
   Doxygen::exampleNameDict->setAutoDelete(TRUE);
   Doxygen::imageNameDict = new FileNameDict(257);
   Doxygen::dotFileNameDict = new FileNameDict(257);
+  Doxygen::mscFileNameDict = new FileNameDict(257);
   Doxygen::sectionDict.setAutoDelete(TRUE);
   Doxygen::memGrpInfoDict.setAutoDelete(TRUE);
   Doxygen::tagDestinationDict.setAutoDelete(TRUE);
@@ -9155,6 +9161,7 @@
   delete Doxygen::exampleNameDict;
   delete Doxygen::imageNameDict;
   delete Doxygen::dotFileNameDict;
+  delete Doxygen::mscFileNameDict;
   delete Doxygen::mainPage;
   delete Doxygen::pageSDict;  
   delete Doxygen::exampleSDict;
@@ -9738,6 +9745,18 @@
     s=dotFileList.next(); 
   }
 
+  msg("Searching for msc files...\n");
+  QStrList &mscFileList=Config_getList("MSCFILE_DIRS");
+  s=mscFileList.first();
+  while (s)
+  {
+    readFileOrDirectory(s,0,Doxygen::mscFileNameDict,0,0,
+                        0,0,0,
+                        alwaysRecursive);
+    s=dotFileList.next(); 
+  }
+
+
   msg("Searching for files to exclude\n");
   QStrList &excludeList = Config_getList("EXCLUDE");
   s=excludeList.first();
Index: src/msc.cpp
===================================================================
--- src/msc.cpp	(révision 741)
+++ src/msc.cpp	(copie de travail)
@@ -112,11 +112,17 @@
   }
   mscArgs+=" -i \"";
   mscArgs+=inFile;
-  mscArgs+=".msc\" -o \"";
+ 
+  if (strstr(inFile,".msc")!=NULL) {
+	  mscArgs+="\" -o \"";
+  }else{ 
+	  mscArgs+=".msc\" -o \"";
+  }
+
   mscArgs+=outFile;
   mscArgs+=extension+"\"";
   int exitCode;
-  //printf("*** running: %s %s\n",mscExe.data(),mscArgs.data());
+//  printf("*** running: %s %s outDir:%s %s\n",mscExe.data(),mscArgs.data(),outDir,outFile);
   portable_sysTimerStart();
   if ((exitCode=portable_system(mscExe,mscArgs,FALSE))!=0)
   {
@@ -146,6 +152,8 @@
 {
   QCString outFile = inFile + ".map";
 
+
+//  printf("*** running:getMscImageMapFromFile \n");
   // chdir to the output dir, so dot can find the font file.
   QCString oldDir = convertToQCString(QDir::currentDirPath());
   // go to the html output directory (i.e. path)
@@ -154,7 +162,13 @@
 
   QCString mscExe = Config_getString("MSCGEN_PATH")+"mscgen"+portable_commandExtension();
   QCString mscArgs = "-T ismap -i \"";
-  mscArgs+=inFile + ".msc\" -o \"";
+  if (inFile.contains(".msc",FALSE )) {
+	  mscArgs+=inFile  +"\" -o \"";
+  } else {
+	  mscArgs+=inFile + ".msc" +"\" -o \"";
+
+  }
+  mscArgs+=inFile  +"\" -o \"";
   mscArgs+=outFile + "\"";
 
   int exitCode;
Index: doc/commands.doc
===================================================================
--- doc/commands.doc	(révision 741)
+++ doc/commands.doc	(copie de travail)
@@ -65,6 +65,7 @@
 \refitem cmddontinclude \\dontinclude
 \refitem cmddot \\dot
 \refitem cmddotfile \\dotfile
+\refitem cmdmscfile \\mscfile
 \refitem cmde \\e
 \refitem cmdelse \\else
 \refitem cmdelseif \\elseif
@@ -2096,6 +2097,24 @@
   stripped before the caption is displayed.
 
 <hr>
+\section cmdmscfile \\mscfile <file> ["caption"] 
+
+  \addindex \\mscfile
+  Inserts an image generated by mscgen from \<file\> into the documentation. 
+
+  The first argument specifies the file name of the image. 
+  doxygen will look for files in the paths (or files) that you specified 
+  after the \ref cfg_mscfile_dirs "MSCFILE_DIRS" tag. 
+  If the msc file is found it will be used as an input file to the mscgen tool. 
+  The resulting image will be put into the correct output directory.
+  If the dot file name contains spaces you'll have to put quotes ("...") around it.
+
+  The second argument is optional and can be used to specify the caption
+  that is displayed below the image. This argument has to be specified
+  between quotes even if it does not contain any spaces. The quotes are
+  stripped before the caption is displayed.
+
+<hr>
 \section cmde \\e <word>
 
   \addindex \\e 
Index: doc/language.doc
===================================================================
--- doc/language.doc	(révision 741)
+++ doc/language.doc	(copie de travail)
@@ -23,7 +23,7 @@
 than English (the default). The output language is chosen through the
 configuration file (with default name and known as Doxyfile).
 
-Currently (version 1.7.1), 38 languages 
+Currently (version 1.7.1-20100822), 38 languages 
 are supported (sorted alphabetically):
 Afrikaans, Arabic, Brazilian Portuguese, Catalan, Chinese, Chinese
 Traditional, Croatian, Czech, Danish, Dutch, English, Esperanto,
Index: doc/translator_report.txt
===================================================================
--- doc/translator_report.txt	(révision 741)
+++ doc/translator_report.txt	(copie de travail)
@@ -1,4 +1,4 @@
-(1.7.1)
+(1.7.1-20100822)
 
 Doxygen supports the following 38 languages (sorted alphabetically):
 
