Program:   gdcm
   Module:    $RCSfile: gdcmDictEntry.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/06/07 14:50:36 $
-  Version:   $Revision: 1.48 $
+  Date:      $Date: 2005/06/14 14:00:03 $
+  Version:   $Revision: 1.49 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
 
 #include <iomanip> // for std::ios::left, ...
 #include <fstream>
-#include <stdio.h> // for sprintf, grrrr
+#include <stdio.h> // for sprintf
 
 namespace gdcm 
 {
  * @param   group      DICOM-Group Number
  * @param   elem       DICOM-Element Number
  * @param   vr         Value Representation
- * @param   vm         Value Mutlplicity 
- * @param   name      description of the element
+ * @param   vm         Value Multiplicity 
+ * @param   name       description of the element
 */
 
 DictEntry::DictEntry(uint16_t group, uint16_t elem,
 
   Program:   gdcm
   Module:    $RCSfile: gdcmDictSet.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/04/05 10:56:25 $
-  Version:   $Revision: 1.62 $
+  Date:      $Date: 2005/06/14 14:00:04 $
+  Version:   $Revision: 1.63 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
    Dicts.clear();
 
    // Remove virtual dictionary entries
-   VirtualEntry.clear();
+   VirtualEntries.clear();
 }
 
 //-----------------------------------------------------------------------------
 }
 
 /**
- * \brief   Create a DictEntry which will be referenced 
- *          in no dictionary
+ * \brief   Create a DictEntry which will be referenced in no dictionary
+ * @param   group   Group number of the Entry 
+ * @param   elem  Element number of the Entry
+ * @param   vr  Value Representation of the Entry
+ * @param   vm  Value Multiplicity of the Entry
+ * @param   name  English name of the Entry
  * @return  virtual entry
  */
 DictEntry *DictSet::NewVirtualDictEntry( uint16_t group,
-                                         uint16_t element,
+                                         uint16_t elem,
                                          TagName vr,
                                          TagName vm,
                                          TagName name)
 {
    DictEntry *entry;
-   const std::string tag = DictEntry::TranslateToKey(group,element)
-                           + "#" + vr + "#" + vm + "#" + name;
+
+  // Let's follow 'Purify' advice
+  //
+  // const std::string tag = DictEntry::TranslateToKey(group,elem)
+  //                         + "#" + vr + "#" + vm + "#" + name;
+   char res[10];
+   sprintf(res,"%04x|%04x", group, elem);
+   std::string tag = res;
+   tag += "#" + vr + "#" + vm + "#" + name;  
+  
    TagKeyHT::iterator it;
    
-   it = VirtualEntry.find(tag);
-   if(it != VirtualEntry.end())
+   it = VirtualEntries.find(tag);
+   if(it != VirtualEntries.end())
    {
       entry = &(it->second);
    }
    else
    {
-      DictEntry ent(group, element, vr, vm, name);
-      VirtualEntry.insert(
-         std::map<TagKey, DictEntry>::value_type
-            (tag, ent));
-      entry = &(VirtualEntry.find(tag)->second);
+      DictEntry ent(group, elem, vr, vm, name);
+      VirtualEntries.insert(
+         std::map<TagKey, DictEntry>::value_type(tag, ent) );
+      entry = &(VirtualEntries.find(tag)->second);
    }
 
    return entry;
 
   Program:   gdcm
   Module:    $RCSfile: gdcmDictSet.h,v $
   Language:  C++
-  Date:      $Date: 2005/02/06 14:43:27 $
-  Version:   $Revision: 1.42 $
+  Date:      $Date: 2005/06/14 14:00:04 $
+  Version:   $Revision: 1.43 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
 
    Dict *GetDict( DictKey const &DictName );
 
-   /// \brief   Retrieve the default reference DICOM V3 public dictionary.
+   /// \brief   Returns the default reference DICOM V3 public dictionary.
    Dict* GetDefaultPubDict() { return GetDict(PUB_DICT_NAME); };
 
-   // \brief   Retrieve the virtual reference DICOM dictionary.
-   // \warning : not end user intended
-   // Dict *GetVirtualDict() { return &VirtualEntry; };
+   // \ brief   Returns the virtual references DICOM dictionary.
+   // \ warning : not end user intended
+   // Dict *GetVirtualDict() { return &VirtualEntries; };
 
    DictEntry *NewVirtualDictEntry(uint16_t group, uint16_t elem,
                                   TagName vr     = GDCM_UNKNOWN,
    std::string DictPath;
 
    /// H table for the on the fly created DictEntries  
-   TagKeyHT VirtualEntry; 
+   TagKeyHT VirtualEntries; 
 };
 } // end namespace gdcm
 
 
   Program:   gdcm
   Module:    $RCSfile: gdcmDocEntry.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/06/07 13:44:47 $
-  Version:   $Revision: 1.57 $
+  Date:      $Date: 2005/06/14 14:00:04 $
+  Version:   $Revision: 1.58 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
       }
       else
       {
-         st = Util::Format("x(%x)",lgth);
+         st = Util::Format("x(%x)",lgth); // we may keep it
          s.setf(std::ios::left);
          s << std::setw(10-st.size()) << " ";
          s << st << " ";
          s << std::setw(8) << lgth; 
       }
       s << " Off.: ";
-      st = Util::Format("x(%x)",o); 
+      st = Util::Format("x(%x)",o);  // we may keep it
       s << std::setw(10-st.size()) << " ";
       s << st << " ";
       s << std::setw(8) << o;