void CharDataInformation::staticSetWidgetData(quint8 value, QWidget* w)
{
    KLineEdit* edit = dynamic_cast<KLineEdit*> (w);
    if (edit)
    {
        QChar qchar(value, 0);
        if (! qchar.isPrint())
            qchar = QChar(QChar::ReplacementCharacter);
        edit->setText( qchar );
    }
}
void SysmgrIMEModel::sendKeyEvent(QEvent::Type type, Qt::Key key, Qt::KeyboardModifiers modifiers)
{
    QWidget* focusedWidget = QApplication::focusWidget();
    if (focusedWidget && (type == QEvent::KeyPress || type == QEvent::KeyRelease)) {
		QChar qchar(key);

		// only lower case A to Z. Other keys are unicode characters with proper casing already...
		if (key >= Qt::Key_A && key <= Qt::Key_Z && !(modifiers & Qt::ShiftModifier))
			qchar = qchar.toLower();
		QApplication::postEvent(focusedWidget, new QKeyEvent(type, key, modifiers, qchar));
    }
}
qstring moorecoinunits::formathtmlwithunit(int unit, const camount& amount, bool plussign, separatorstyle separators)
{
    qstring str(formatwithunit(unit, amount, plussign, separators));
    str.replace(qchar(thin_sp_cp), qstring(thin_sp_html));
    return qstring("<span style='white-space: nowrap;'>%1</span>").arg(str);
}