Notify - Display Notifications GUIs

Post your working scripts, libraries and tools.
XMCQCX
Posts: 248
Joined: 14 Oct 2020, 23:44

Notify - Display Notifications GUIs

06 May 2024, 17:20

Notify
This class makes it easier to create and display notification GUIs.

Features
  • Changing text, image, font, color.
  • Rounded or edged corners.
  • Positioning at different locations on the screen.
  • Playing sound when it appears.
  • Call function when clicking on it.
Inspired by the Automator Notify Class and the original Notify function by gwarble. I attempted to modify it. However, I struggled to comprehend the code, so I created my own version.

For the latest version of this script, documentation and examples, head over to the GitHub page.
:arrow: Download on GitHub

Image
Image
Last edited by XMCQCX on 18 May 2024, 15:49, edited 8 times in total.
songdg
Posts: 605
Joined: 04 Oct 2017, 20:04

Re: Notify - Display Notifications GUIs

06 May 2024, 22:19

Wonderful, thanks for sharing :clap:
reddyshyam
Posts: 44
Joined: 24 Jul 2023, 04:34

Re: Notify - Display Notifications GUIs

07 May 2024, 10:49

Hi @XMCQCX ,

Thanks for this, much appreciated! I have been using a wonderful script WiseGUI which is just brilliant and I love it. I noticed that WiseGUI lacks html support but it was not a problem at all

Will try to use your lib just for thrill of it and change where ever I would want sound notifications and html content.

It would be nice to show some screenshots too so that we know what we get before we start using it. :) Hope this is ok.
XMCQCX
Posts: 248
Joined: 14 Oct 2020, 23:44

Re: Notify - Display Notifications GUIs

07 May 2024, 14:26

reddyshyam wrote:
07 May 2024, 10:49
It would be nice to show some screenshots too so that we know what we get before we start using it. :) Hope this is ok.
Hi @reddyshyam. Thanks for the suggestion! I’ve updated my post with screenshots.
User avatar
kczx3
Posts: 1648
Joined: 06 Oct 2015, 21:39

Re: Notify - Display Notifications GUIs

09 May 2024, 08:20

XMCQCX wrote:
07 May 2024, 14:26
reddyshyam wrote:
07 May 2024, 10:49
It would be nice to show some screenshots too so that we know what we get before we start using it. :) Hope this is ok.
Hi @reddyshyam. Thanks for the suggestion! I’ve updated my post with screenshots.
You did?
XMCQCX
Posts: 248
Joined: 14 Oct 2020, 23:44

Re: Notify - Display Notifications GUIs

10 May 2024, 08:10

Updated to 1.1.0

- Added a new parameter for destroying currently existing GUIs or not when a new GUI is created.
- Added a GUI to list and hear all the available sounds. Call Notify.SoundsList()
- Sound parameter. Allow using 'Windows Ding', for instance, instead of Notify.mSounds['Windows Ding'].
User avatar
Delta Pythagorean
Posts: 628
Joined: 13 Feb 2017, 13:44
Location: Somewhere in the US
Contact:

Re: Notify - Display Notifications GUIs

13 May 2024, 16:02

Instead of having 18 parameters for one function, needing to remember the position for each one, why not use an object to pass individual parameters?

Code: Select all

Notify.Show({ body_text: "Lorem ipsum", icon: "x", style: "round", duration: 5 * 1000 })

[AHK]......: v2.0.12 | 64-bit
[OS].......: Windows 11 | 23H2 (OS Build: 22621.3296)
[GITHUB]...: github.com/DelPyth
[PAYPAL]...: paypal.me/DelPyth
[DISCORD]..: tophatcat

XMCQCX
Posts: 248
Joined: 14 Oct 2020, 23:44

Re: Notify - Display Notifications GUIs

15 May 2024, 05:58

@Delta Pythagorean I weighed the pros and cons of passing a single object versus passing multiple parameters and hesitated about which one to choose. Ultimately, I chose individual parameters because the thqby v2 language support extension has intelligent prompts for function parameters, which allow a user to see the parameter when typing. However, you are right that using 18 parameters is not optimal. I will probably update it in the next few days to be similar to the original notify v1 by gwarble, in this format:

Code: Select all

Notify.Show('Title text', 'Message Text', 'iconi', 'soundx',, 'TS=35 POS=TL DUR=8 DG=2')
Last edited by XMCQCX on 18 May 2024, 17:06, edited 1 time in total.
XMCQCX
Posts: 248
Joined: 14 Oct 2020, 23:44

Re: Notify - Display Notifications GUIs

Yesterday, 15:51

Updated to 1.2.0
WARNING! This version introduces BREAKING CHANGES if GUIs were created using the previous versions.

- Reduced number of parameters from 18 to 6.
- Added methods for destroying GUIs.
- Added center positioning.
- Added animate window duration option.
- Duration option now in seconds instead of milliseconds.
- Added JSDoc documentation.

Return to “Scripts and Functions (v2)”

Who is online

Users browsing this forum: wilkster and 13 guests