Changeset View
Changeset View
Standalone View
Standalone View
tools/selection/text/kpToolText_KeyboardEvents_HandleTypingKeys.cpp
Show First 20 Lines • Show All 160 Lines • ▼ Show 20 Line(s) | |||||
161 | // protected | 161 | // protected | ||
162 | void kpToolText::handleTextTyped (QKeyEvent *e, | 162 | void kpToolText::handleTextTyped (QKeyEvent *e, | ||
163 | const QList <QString> & /*textLines*/, int /*cursorRow*/, int /*cursorCol*/) | 163 | const QList <QString> & /*textLines*/, int /*cursorRow*/, int /*cursorCol*/) | ||
164 | { | 164 | { | ||
165 | #if DEBUG_KP_TOOL_TEXT | 165 | #if DEBUG_KP_TOOL_TEXT | ||
166 | qCDebug(kpLogTools) << "\ttext=" << e->text(); | 166 | qCDebug(kpLogTools) << "\ttext=" << e->text(); | ||
167 | #endif | 167 | #endif | ||
168 | QString usableText; | 168 | QString usableText; | ||
169 | for (int i = 0; i < (int) e->text ().length (); i++) | 169 | for (int i = 0; i < e->text ().length (); i++) | ||
170 | { | 170 | { | ||
171 | if (e->text ().at (i).isPrint ()) | 171 | if (e->text ().at (i).isPrint ()) | ||
172 | usableText += e->text ().at (i); | 172 | usableText += e->text ().at (i); | ||
173 | } | 173 | } | ||
174 | #if DEBUG_KP_TOOL_TEXT | 174 | #if DEBUG_KP_TOOL_TEXT | ||
175 | qCDebug(kpLogTools) << "\tusableText=" << usableText; | 175 | qCDebug(kpLogTools) << "\tusableText=" << usableText; | ||
176 | #endif | 176 | #endif | ||
177 | 177 | | |||
Show All 16 Lines |