diff --git a/docs/index.html b/docs/index.html index 969d3a084..0ac22e5dd 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1364,8 +1364,8 @@ Toggle windowed/fullscreen mode - Alt + Enter - Cmd + Enter + Alt + Return + Cmd + Return Toggle adapting display refresh rate to game frame rate @@ -1757,11 +1757,6 @@ Backspace Backspace - - Go to parent directory (UI mode) - Backspace - Backspace - Decrease emulation speed (disables 'Turbo' mode) Shift-Control + s @@ -1867,8 +1862,129 @@ +

UI Keys (can be remapped)

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FunctionKey (Standard)Key (macOS)
Move UpUp arrowUp arrow
Move DownDown arrowDown arrow
Move LeftLeft arrowLeft arrow
Move RightRight arrowRight arrow
Move HomeHomeHome
Move EndEndEnd
Move Page UpPage UpPage Up
Move Page DownPage DownPage Down
OK--
CancelEscapeEscape
Select itemReturn/Enter/SpaceReturn/Enter/Space
Move to previous objectShift + TabShift + Tab
Move to next objectTabTab
Move to previous tabShift-Control + TabShift-Control + Tab
Move to next tabControl + TabControl + Tab
Go to parent directoryBackspaceBackspace
Toggle windowed/fullscreen modeAlt + ReturnCmd + Return
Exit emulatorControl + qCmd + q
+

UI Keys in Text Editing areas (cannot be remapped)

+ *** TODO!!! *** + + + + + + + + + + + + + + + + + +
FunctionKey (Standard)Key (macOS)
Move cursor to beginning of lineHome, Control + aHome, Control + a
.........
+
+ @@ -1884,6 +2000,7 @@
KeyEditor Function
Home, Control + aMove cursor to beginning of line
Control + v, Shift + InsertPaste clipboard contents
Control + x, Shift + DeleteCut entire line to clipboard
+

Controller Map

diff --git a/src/gui/EditableWidget.cxx b/src/gui/EditableWidget.cxx index e5808ece8..f58da8c7f 100644 --- a/src/gui/EditableWidget.cxx +++ b/src/gui/EditableWidget.cxx @@ -187,6 +187,10 @@ bool EditableWidget::handleControlKeys(StellaKey key, StellaMod mod) sendCommand(EditableWidget::kChangedCmd, key, _id); break; + case KBDK_Z: + // TODO: undo + break; + case KBDK_LEFT: handled = moveWord(-1, shift); if(!shift) @@ -700,10 +704,26 @@ bool EditableWidget::pasteSelectedText() instance().eventHandler().pasteText(pasted); // remove the currently selected text killSelectedText(); - // insert paste text instead - _editString.insert(_caretPos, pasted); + // insert filtered paste text instead + ostringstream buf; + bool lastOk = true; // only one filler char per invalid character (block) + + for(char c : pasted) + if(_filter(tolower(c))) + { + buf << c; + lastOk = true; + } + else + { + if(lastOk) + buf << '_'; + lastOk = false; + } + + _editString.insert(_caretPos, buf.str()); // position cursor at the end of pasted text - _caretPos += int(pasted.length()); + _caretPos += int(buf.str().length()); return selected || !pasted.empty(); }