* This file is part of LyX, the document processor.
* Licence details can be found in the file COPYING.
*
* This file is part of LyX, the document processor.
* Licence details can be found in the file COPYING.
*
static char encode(string const & encoding, QString const & str)
{
typedef map<string, QTextCodec *> EncodingMap;
static char encode(string const & encoding, QString const & str)
{
typedef map<string, QTextCodec *> EncodingMap;
void setKeySymbol(KeySymbol * sym, QKeyEvent * ev)
{
sym->setKey(ev->key());
if (ev->text().isNull()) {
void setKeySymbol(KeySymbol * sym, QKeyEvent * ev)
{
sym->setKey(ev->key());
if (ev->text().isNull()) {
- LYXERR(Debug::KEY) << "Getting key " << ev->key() << ", with text '"
- << fromqstr(ev->text()) << "'" << std::endl;
+ LYXERR(Debug::KEY, "Getting key " << ev->key() << ", with text '"
+ << fromqstr(ev->text()) << "'");
// This is unsafe because ev->text() is the unicode representation of the
// key, not the name of the key. For example, Ctrl-x and Alt-x produce
// different texts.
sym->setText(qstring_to_ucs4(ev->text()));
// This is unsafe because ev->text() is the unicode representation of the
// key, not the name of the key. For example, Ctrl-x and Alt-x produce
// different texts.
sym->setText(qstring_to_ucs4(ev->text()));
- LYXERR(Debug::KEY) << "Setting key to " << sym->key() << ", "
- << to_utf8(sym->text()) << endl;
+ LYXERR(Debug::KEY, "Setting key to " << sym->key() << ", "
+ << to_utf8(sym->text()));
- LYXERR(Debug::KEY) << "Init key to " << key_ << ", "
- << to_utf8(text_) << endl;
+ LYXERR(Debug::KEY, "Init key to " << key_ << ", " << to_utf8(text_));
if (lyxerr.debugging() && text_.size() > 1) {
// We don't know yet how well support the full ucs4 range.
if (lyxerr.debugging() && text_.size() > 1) {
// We don't know yet how well support the full ucs4 range.
- LYXERR(Debug::KEY) << "KeySymbol::getUCSEncoded()" << endl;
- for (int i = 0; i != int(text_.size()); ++i) {
- LYXERR(Debug::KEY) << "char " << i << ": "
- << int(text_[i]) << endl;
- }
+ LYXERR(Debug::KEY, "KeySymbol::getUCSEncoded()");
+ for (int i = 0; i != int(text_.size()); ++i)
+ LYXERR(Debug::KEY, "char " << i << ": " << int(text_[i]));