]> git.lyx.org Git - lyx.git/blobdiff - src/support/translator.h
Create a grfx::Loader class and so move large chunks of code out of
[lyx.git] / src / support / translator.h
index 0b400f714de21c34fe37599c481fe09bc4f7ce9f..3924956d2695eba49bf7bc9baf7211f63e459df2 100644 (file)
@@ -1,13 +1,11 @@
 // -*- C++ -*-
-/* This file is part of
- * =================================================
+/**
+ * \file translator.h
+ * Copyright 1995-2002 the LyX Team
+ * Read the file COPYING
  *
- *          LyX, The Document Processor
- *          Copyright 1995 Matthias Ettrich.
- *          Copyright 1995-2001 The LyX Team.
- *
- *          This file Copyright 2000 Baruch Even
- * ================================================= */
+ * \author Baruch Even <baruch@lyx.org>
+ */
 
 #ifndef TRANSLATOR_H
 #define TRANSLATOR_H
 
 #include "support/LAssert.h"
 #include "support/lyxfunctional.h"
-/** This class template is used to translate between two elements, specifically
-    it was worked out to translate between an enum and strings when reading
-    the lyx file.
-
-    The two template arguments should be of different types.
-*/
+/**
+ * This class template is used to translate between two elements, specifically
+ * it was worked out to translate between an enum and strings when reading
+ * the lyx file.
+ *
+ * The two template arguments should be of different types.
+ */
 template<typename T1, typename T2>
 class Translator {
 public:
@@ -52,7 +51,7 @@ public:
                lyx::Assert(!map.empty());
 
                // For explanation see the next find() function.
-               Map::const_iterator it =
+               typename Map::const_iterator it =
                        std::find_if(map.begin(), map.end(),
                                     lyx::equal_1st_in_pair<MapPair>(first)
                                );
@@ -79,7 +78,7 @@ public:
                //
                // We can depict it as follows:
                // equal_to(select2nd(pair) , second)
-               Map::const_iterator it =
+               typename Map::const_iterator it =
                        std::find_if(map.begin(), map.end(),
                                     lyx::equal_2nd_in_pair<MapPair>(second)
                                );
@@ -99,4 +98,4 @@ private:
        T2 const default_t2;
 };
 
-#endif
+#endif // TRANSLATOR_H