3 * Copyright 2002 the LyX Team
4 * Read the file COPYING
6 * \author Asger and Juergen
7 * \author John Levon <moz@compsoc.man.ac.uk>
13 #pragma implementation
16 #include "QLyXKeySym.h"
19 QLyXKeySym::QLyXKeySym()
20 : LyXKeySym(), key_(0), text_("")
25 void QLyXKeySym::set(int key, QString const & text)
32 void QLyXKeySym::init(string const & symbolname)
34 key_ = string_to_qkey(symbolname);
38 bool QLyXKeySym::isOK() const
45 bool QLyXKeySym::isModifier() const
47 return q_is_modifier(key_);
51 string QLyXKeySym::getSymbolName() const
53 return qkey_to_string(key_);
57 char QLyXKeySym::getISOEncoded() const
60 return text_.latin1()[0];
64 bool QLyXKeySym::operator==(LyXKeySym const & k) const
66 QLyXKeySym const & o = static_cast<QLyXKeySym const &>(k);
67 return o.key_ == key_;