1. Edita: How To Add Ctrl+W As "Close Tab" Quick Key
- Posted by euphoric (admin) Jan 22, 2018
- 1129 views
Ctrl+w is pretty standard across tons of editors, so I'm quite used to it. How can I add that keystroke combo and functionality to Edita?
2. Re: Edita: How To Add Ctrl+W As "Close Tab" Quick Key
- Posted by petelomax Jan 23, 2018
- 1122 views
In edita.exw, in function charInput() at line 4832 you should find
elsif keycode = 23 then selectWord(1) -- Ctrl W (Select Word)
And in the same file, in function virtualKey2() at line 5414 you should find
elsif keycode = VK_F4 then if control then if isEnabled(TC) then closeFile() end if else
So I think, but I haven't tested this, you should be able to change the top one to
-- elsif keycode = 23 then selectWord(1) -- Ctrl W (Select Word) elsif keycode = 23 then closeFile() -- Ctrl W (Close Tab)
Of course that will go AWOL whenever a new version is shipped. (TIP: just make sure you have a pre-compiled version before you start editing the sources.)
In the planned replacement you should be able to achieve this via Options/Keyboard settings, and it'll be preserved across updates.
Regards,
Pete