2001-02-13 17:08:51 +00:00
|
|
|
|
// -*- C++ -*-
|
2003-08-19 13:00:56 +00:00
|
|
|
|
/**
|
|
|
|
|
* \file math_macrotable.h
|
|
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
|
*
|
|
|
|
|
* \author Andr<EFBFBD> P<EFBFBD>nitz
|
|
|
|
|
*
|
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
|
*/
|
|
|
|
|
|
2001-06-25 00:06:33 +00:00
|
|
|
|
#ifndef MATH_MACROTABLE_H
|
|
|
|
|
#define MATH_MACROTABLE_H
|
2001-02-13 17:08:51 +00:00
|
|
|
|
|
2001-10-12 12:02:49 +00:00
|
|
|
|
#include "math_atom.h"
|
2001-02-13 17:08:51 +00:00
|
|
|
|
|
2003-10-06 15:43:21 +00:00
|
|
|
|
#include <map>
|
2003-10-07 06:45:25 +00:00
|
|
|
|
#include <string>
|
2003-10-06 15:43:21 +00:00
|
|
|
|
|
2001-03-01 14:07:43 +00:00
|
|
|
|
|
2002-07-12 14:24:47 +00:00
|
|
|
|
class MathMacroTable {
|
2001-02-13 17:08:51 +00:00
|
|
|
|
public:
|
2001-03-01 14:07:43 +00:00
|
|
|
|
///
|
2002-07-12 14:24:47 +00:00
|
|
|
|
static void create(MathAtom const &);
|
2001-03-01 14:07:43 +00:00
|
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
|
static MathAtom & provide(std::string const & name);
|
2001-03-01 14:07:43 +00:00
|
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
|
static bool has(std::string const & name);
|
2002-03-27 11:02:56 +00:00
|
|
|
|
///
|
|
|
|
|
static void dump();
|
2001-07-27 12:32:29 +00:00
|
|
|
|
private:
|
2001-03-01 14:07:43 +00:00
|
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
|
typedef std::map<std::string, MathAtom> table_type;
|
2001-04-24 16:13:38 +00:00
|
|
|
|
//
|
|
|
|
|
static table_type macro_table;
|
2001-02-13 17:08:51 +00:00
|
|
|
|
};
|
2002-07-12 14:24:47 +00:00
|
|
|
|
|
2001-02-13 17:08:51 +00:00
|
|
|
|
#endif
|