Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Adding custom message to desktop notification #54

Open
bjornasm opened this issue May 10, 2023 · 3 comments
Open

Feature request: Adding custom message to desktop notification #54

bjornasm opened this issue May 10, 2023 · 3 comments
Labels
enhancement New feature or request

Comments

@bjornasm
Copy link

This is possibly linked to #36 - but it would be nice to add a custom message to be displayed on the desktop notification. Say if you have a timer to remember to take a walk and drink a glass of water every other hour in between other types of timers it would be nice to have a specific textual reminder for that. I can have a quick look on the source to see if this is something I am able to contribute to.

@poetaman
Copy link
Owner

poetaman commented May 10, 2023

@bjornasm Yes it is linked to #36. There is a plan for users to be able to specify their timers in more expressive ways, though I don't see it happening anytime soon. There is a workaround one can use for now: arttime's notification does show the name of art. A user can open multiple instances of arttime, and have different timers or time manager programs in each. If the displayed art in each instances is different, they would be able to get the context of notification.

Check for example the "keypoem" file share/arttime/keypoems/timer.banana10learn_8b below.

----
m2 bananas every hour for next 10 hours = 2000 calorie banana diet!
--------
abanana
--------
g1h;loop10
--------
mYou will get 10 notifications, though don't follow this diet :)

It can be loaded from command line like this: arttime -k timer.banana10learn_8b or from within running arttime instance by pressing k followed by Tab/arrow-keys based navigation followed by Enter.

The good part is you can create as many such "keypoems" and save them in the same or different directory. The syntax is the same as the keystrokes one would type in arttime's interface to get an effect. Essentially arttime interprets contents of the file as if each key were pressed (with couple differences). abanana followed by new line changes the art to banana. Art names refer to file names under directory share/arttime/textart. One can easily add a file for "water" or "glass" and save a timer.drinkwater_8b keypoem like this (_8b just slows down the read rate to 8 bytes per second for a visual effect, one can remove it):

----
mwater is essential for life, drink it! 
--------
awater
--------
g2h;loop10

Supporting info: https://github.com/poetaman/arttime/wiki

Here's the GIF that shows timer.banana10learn_8b in action, arttime does the "typing" for you like a ghost:

bananatimer

@poetaman
Copy link
Owner

@bjornasm Btw... As getting notifications to drink water would be so common, I went ahead and added basic water ASCII art and a keypoem. To give it a try, pull and install the main branch again... Then either launch arttime to load the program at launch time: arttime -k timer.drinkwater_8b or after launching arttime press k followed by Tab/arrow-keys to navigate, and Enter to run the keypoem script.

@bjornasm
Copy link
Author

Thank you for your extremely thorough reply as well as this added feature @poetaman !

@poetaman poetaman added the enhancement New feature or request label Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants