[Script] KeypressOSD - Display key press on screen

Post your working scripts, libraries and tools
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

19 Nov 2017, 03:56

Thank you very much! I am really happy to hear this. I plan next to overhaul the feature to make beeps on key presses ... I want that to work better as well.

Best regards, Marius
User avatar
Drugwash
Posts: 304
Joined: 29 May 2014, 21:07
Location: Ploieşti, Romania
Contact:

Re: [Script] KeypressOSD - Display key press on screen

19 Nov 2017, 10:34

For now it still works but apparently worse.
First letter of the sentence (desirably uppercase) is completely missing now, it's not even lowercase, unless Shift+char is pressed twice, which obviously makes the text look stuttering.
Left/right navigation is lagging seriously, not only in OSD but in original application too.
Certain characters are at times messed up (such as 'Đorry' instead of 'Sorry' below).
sorry dorry.png
(14.97 KiB) Not downloaded yet

I'm counting this version as a regression, at least in regard to its usage under XP. Sorry.
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

19 Nov 2017, 12:30

Hello!

oh.... I am so sorry to hear this, drugwash....

I will install WinXP in VirtualBox to test it as well.

Download AHK file from or use the Update now option:
http://marius.sucan.ro/media/files/blog ... ss-osd.ahk

I have a new version. Change log:

v3.50 (2017-11-19)
- added some workarounds for XP related to text drawing
- improved the Shift behaviour
- [new] settings window for the typing mode; I moved a few options from the Keyboard settings window into a new one, it was too big...
- [new] option to control display time when typing
- [new] option to set how much time one has to return to typed text with arrow keys, page up/doown, delete/backspace; with letters or numbers, you always resume typing
- [new] option to have the dead key symbol always treated as a different character
- improved the behavior for page up/down with typed history option turned on
- improved edit fields in preferences windows; now up/down keys can be used to change the values

Best regards, Marius.
Last edited by robodesign on 19 Nov 2017, 14:44, edited 1 time in total.
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

19 Nov 2017, 12:49

Drugwash, please test the newely uploaded version.

I just included a few lines of code that change to Gui Text control instead of Gui Edit control, but only on WinXP. I hope it is working as it did before.

Please let me know. Thank you.

Best regards, Marius.
burque505
Posts: 134
Joined: 22 Jan 2017, 19:37

Re: [Script] KeypressOSD - Display key press on screen

19 Nov 2017, 13:32

Marius, I just tested both this version and the previous one on Win7 64-bit, AHK_H U64. Romanian keyboard screenshot:
Everything seems to be working great on Win7. I haven't had a chance yet to try an XP VM. Sorry I'm having trouble with attachments, it seems to appear twice or not at all.
Regards,
burque505
Image
Attachments
For_Marius.png
For_Marius.png (2.48 KiB) Viewed 187 times
Last edited by burque505 on 19 Nov 2017, 17:07, edited 3 times in total.
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

19 Nov 2017, 14:41

Thank you very much, burque; I am glad to hear this. BTW, image was not uploaded.
rommmcek
Posts: 293
Joined: 15 Aug 2014, 15:18

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 01:42

Win 10: Pretty good.
WIn XP: Sorry, v1.0 installed, but compiled version seems to work fine, except:
Exe won't download the language file on neither of the Os's.
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 03:59

You compiled which version? v1.0 ? I only began working on it since v2.22 which is by tmplinshi and it was just the core idea (it showed only key presses and no support for multi-languages).

I intend to make a compiled version soon, as well. But I must first finish the script itself. I still have to implement/improve some aspects about it.

what compiler did you use?

Best regards, Marius.
rommmcek
Posts: 293
Joined: 15 Aug 2014, 15:18

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 05:11

KeyPress OSD v3.50
Ahk2Exe for AutoHotkey v1.1.25.01 -- Script to EXE Converter

P.s.: You made quite a progress lately!
P.p.s.: v1.0 refers to AutoHotkey 1.0.48.05
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 08:14

Hello!

Thanks, rommmcek.

Today's new version is here:

v3.51 (2017-11-20)
- [new] option: only typing mode
- [new] when only typing mode is activated, the behaviour of Enter key can be changed from adding a space only, to erase the typed text from the OSD.
- [bug fixed] the numpad keys /, *, -, + with Shift were acting exactly like regular characters/symbols :).
- typing window more informative; it indicates if dead keys, AltGr or keys with Shift are defined.

Download AHK file from or use the Update now option:
http://marius.sucan.ro/media/files/blog ... ss-osd.ahk

Best regards, Marius.
burque505
Posts: 134
Joined: 22 Jan 2017, 19:37

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 10:55

Hi Marius,
Win 7- 64bit, AHK_H U64, as per usual.
In "typing mode only", "Enter" doesn't erase the text in the display when "Enter key erases text from the OSD" is checked (or not checked).
Everything in general still working great.
Regards,
burque505
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 12:13

Thank you very much. Yes, my bad... I fixed it now. I forgot this time to test it with other settings ;-), other than mine...

I sometimes make such mistakes... even typos that cause silly bugs... Anyone is encouraged to try it and report any bug[s].

Best regards, Marius.
User avatar
Drugwash
Posts: 304
Joined: 29 May 2014, 21:07
Location: Ploieşti, Romania
Contact:

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 12:37

This 3.51 version is improved, capitals are recognized at start of sentence as they should be.
Navigation seems to be better in terms of lagging but when jumping from one row to another it doesn't quite follow the actual text.
The Đorry/Sorry issue has been fixed.
(Typing mode only is enabled)
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 13:57

I am glad to hear that, Drugwash.

Up/down keys support cannot be implemented. I am still thinking if I should even implement support for Ctrl + [left/right/del/backspace].....

Best regards, Marius.
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 14:50

The compiled version is here, yyaaaayyy:

Download AHK file from or use the Update now option:
http://marius.sucan.ro/media/files/blog ... ss-osd.exe ;-)

Please keep in mind... The Update now feature does not work with the compiled version.
PS. The binary includes the language definitions file. It does not need one externally.

Best regards, Marius.
burque505
Posts: 134
Joined: 22 Jan 2017, 19:37

Re: [Script] KeypressOSD - Display key press on screen

20 Nov 2017, 19:17

Hi Marius, I downloaded the .exe and updated from the script. On my Win 7 setup the .exe and script are working fine in general.
I just noticed something I hadn't before: when in typing mode, at the start of a new line and hitting Shift plus a key, the character doesn't display unless and until you type a second character.
So, if I type:
I[Enter]
I[Enter]
I[Enter]
No 'I's ever appear.
If I type
@[space][Enter]
@[space][Enter]
@[space][Enter]
the '@'s appear.
Maybe that's just on my setup, though (Win7, AHK_H U64, 64-bit).
Regards,
burque505
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

21 Nov 2017, 04:02

Correct observation. Thank you very much. I will fix it for the next release. I am now struggling to improve the functionality of beepers [on key presses].

Best regards, Marius.
User avatar
Drugwash
Posts: 304
Joined: 29 May 2014, 21:07
Location: Ploieşti, Romania
Contact:

Re: [Script] KeypressOSD - Display key press on screen

21 Nov 2017, 10:31

robodesign wrote:Up/down keys support cannot be implemented. I am still thinking if I should even implement support for Ctrl + [left/right/del/backspace].....

At the time I had only used left/right arrows for navigation through the comment, no up/down. Maybe the memory buffer is too small to hold the entire text or it's an intended limitation. Anyway, there are many factors that can break the behavior of the script, for example scrolling this text left into the quote area (which was not typed by the user and therefore is not in the memory buffer) will lead to a Left (xxx) display and then scrolling right back into tthe typed text will not get back to it but will only display Right (yyy). I guess some things just cannot be done perfectly. ;)

Burque's issue only happens in XP until user presses the arrows or Backspace or some other non-character keys once, then the individual capitals do appear in the OSD.
burque505
Posts: 134
Joined: 22 Jan 2017, 19:37

Re: [Script] KeypressOSD - Display key press on screen

21 Nov 2017, 12:37

What Dragoș describes happens for me in Win7 as well. Also, in 'typing-mode-only', if I type, for example '*', or Shift+{any key} on my keyboard, the display itself doesn't even appear until I press another key (whether it be a letter, or some other character, or a non-character such as {End}).
Regards,
burque505
robodesign
Posts: 127
Joined: 30 Sep 2017, 03:59
Facebook: marius.sucan
Contact:

Re: [Script] KeypressOSD - Display key press on screen

21 Nov 2017, 12:57

Hello, guys!

I had some bugs with Left/Right that I fixed now. The OSD can hold a lot of text. Please set the timers to suit your needs in Typing mode settings. You can set long timers and then left, right, home, end, backspace, delete, space will always return to typed text. The bug I had with left/right borked this behaviour, but in this new version it should be fine.

I also fixed the issues with Shift + [any letter/symbol/number] in only typing mode. Now it will display the OSD at once. ;-). Please confirm/infirm having solved these issues.

Here's today's new version change log:

by Marius Sucan (robodesign.ro)
v3.53 (2017-11-21)
- [new] option to play beeps at low volume [by default it is on]
- [new] option to make a generic beep at every key fire
- [new] settings window for Sounds; as a consequence, I removed the options from Keyboard settings related to beeps
- now it uses sound files to make the beeps; if they are missing, it will behave as previously; at start it verifies if audio files are present and, if not, it attempts to download them, without prompting the user; all in background
- fixed two bugs reported by burque505 related to typing mode only and other bugs ;)

Download AHK file from or use the Update now option:
http://marius.sucan.ro/media/files/blog ... ss-osd.ahk

P.S. There's no perfection, but I want it at least... purrfect ;-).
P.P.S. Binary file removed.

Best regards, Marius

Return to “Scripts and Functions”

Who is online

Users browsing this forum: No registered users and 14 guests