Forget automatic, self-generating Buttons Help Overlay

Post a reply

In an effort to prevent automatic submissions, we require that you complete the following challenge.
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :| :mrgreen: :geek: :ugeek: :arrow: :angel: :clap: :crazy: :eh: :lolno: :problem: :shh: :shifty: :sick: :silent: :think: :thumbup: :thumbdown: :salute: :wave: :wtf: :yawn: :facepalm: :bravo: :dance: :beard: :morebeard: :xmas: :HeHe: :trollface: :cookie: :rainbow: :monkeysee: :monkeysay: :happybday: :headwall: :offtopic: :superhappy: :terms: :beer:
View more smilies

BBCode is ON
[img] is OFF
[flash] is OFF
[url] is ON
Smilies are ON

Topic review

Expand view Topic review: Forget automatic, self-generating Buttons Help Overlay

Re: Forget automatic, self-generating Buttons Help Overlay

by RUBn » 22 Aug 2015, 07:10

Thanks, peeps.

FG, FYI, your script is the one I ended up with untill my "endeavour".

Further on, considering both to be once integrated into something...
I have too many unfinished projects myself (for a couple of years)*, but if anyone would ever be interested:

First off, I think we all realise it will never work as a direct help hotkey. As you'll have AHK to be running HTML, which will take too much time for a quick help overlay. So, you would rather run it as a run-once-only (when buttons change) and place the resulting screenshot in the desired place to make an existing spashimage work.
(One could even write a script to calculate a unique hash for the script so the whole run-once-script would be automatically generated (or offered) when the script changes.)
Then it will be more or less all right.

And code-wise..
Actually, one doesn't have to have any knowledge of CSS. The CSS stays unchanged. The only thing to do is fill in the HTML-file with the key-names (between the tags <kbd>), o yeah, and the class attribute for mouse buttons**.
E.g. Only the bold things below needs changing
<kbd class="Ms Rt">+<kbd>+<kbd class="Ms">Scroll<kbd>
So, it's quite repetitive.

There are some minor problems, such as icons*** and order/titles****, but solutions seem very likely for these.

* I could "spare" a little bit of time to help anyone getting this done, nonetheless.
** I can change it so that even the mousebuttons are between simple <kbd> tags without classes. I did it a bit inconsistent looking back at it now. (There was a reason, but it's mute here.)
*** As there will be a huge lot of icons to collect to satisfy everyone.
**** In most scripts, there is no freedom (or time) to place the hotkeys in the order you want them (let be under the right section/title). (Also, sometimes you want certain unrelated hotkeys to be together as they need some special code to make them not work against eachother. We've all been there, right?)

Re: Forget automatic, self-generating Buttons Help Overlay

by ozzii » 22 Aug 2015, 03:20

I use Hotkey Help.
But the image is better looking.
and FG is right
The information from Hotkey Help could be used to generate a pretty overlay like you have that would be generated dynamically
This will be EXCELLENT.

Re: Forget automatic, self-generating Buttons Help Overlay

by FanaticGuru » 21 Aug 2015, 12:33

Hotkey Help in my signature can determine what scripts you have running and then use comment information in the script files to generate a help dialog like below.
As long as you comment all your scripts with appropriate help information on the line with each hotkey declaration then it will automatically generate the appropriate help dialog based on the currently running scripts.

If it is just for one user and they always run the same scripts then manually creating a help is probably the way to go but I am in an environment where multiple computers are running different scripts and being used by different people and needed something that would generate a help appropriate to each user.

The information from Hotkey Help could be used to generate a pretty overlay like you have that would be generated dynamically but I do not have the expertise with CSS to do that. Maybe someday I will look at making it prettier using your technique. Nice Work!


Forget automatic, self-generating Buttons Help Overlay

by RUBn » 21 Aug 2015, 06:55

For quite some time now, have I been looking for a nice self- (or AHK-) generated help overlay with all my hotkeys.
I've tried most of what I could find and found them never satisfying, especially the layout. (With due respect to the creators nonetheless!)

Then, I started thinking that I'd probably spend much less time just manually generating an image for it myself and use it as splash image. And since I'm quite adept in css, I decided to do it in html/css, so that I can easily change it if my hotkeys change. Call it semi-manually.
I gather now that if I would have started out like that, the time needed to create and update this in my whole life, would be less than looking for or trying to make an all-round automatic one myself.

Anyway, it's here now and I'd like to share it with you.
If you like to have one yourself, just go over to this page on my attic, download the package and edit the self-explanatory HTML to match your buttons, possibly add your own custom icons.
(You may share your own icons with me if you like; I'll update the package ... if they are nice ;-p )
Then take a screenshot and use the script below to use it as a Buttons Help Overlay.

CSS Keyboard and Mouse Buttons (Overlay)

My splashimage script:

Code: Select all

	SplashImage, C:\Users\Ruben\Documents\Configs`, addresses\Software\AH\Buttons Help\SShot.gif, B
	WinSet, TransColor, 000000 20,SShot.ahk ; not working ??
	Keywait `,
	Keywait RButton
	SplashImage, Off
I hope you peeps like it so I can return something for all the help I got here.