WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Fun with TC POPUP gui  (Read 12459 times)

Offline PDP-8

  • Hero Member
  • *****
  • Posts: 915
Fun with TC POPUP gui
« on: August 07, 2019, 06:52:17 AM »
I was reading bmarkus talking about popups from about 10 years ago ... and just now noticed how cool these lightweight notifications are!

The usual:
Code: [Select]
popup Hello World!
Hijinks:
Code: [Select]
popup About To Erase Boot Drive Y/N ?with only the close button available.... :)

But I see it also works with backticks!

Code: [Select]
popup You have `calc 2*5` minutes left!
popup I really like using TinyCore `version`

Anyway, you get the drift.  I can see using these with backgrounded scripts that merely need to notify me when say a compile is finished, or perhaps with cron jobs etc etc.

Looks like a neat alternative to always having another terminal open and glancing over at it all the time.

Shame on you veteran users and devs from keeping this totally cool secret from me! :)
That's a UNIX book! - cool  -- Garth

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11617
Re: Fun with TC POPUP gui
« Reply #1 on: August 07, 2019, 08:56:50 AM »
Hi PDP-8
... Shame on you veteran users and devs from keeping this totally cool secret from me! :)
You know she has a sister called  popask,  right?

Offline NewUser

  • Full Member
  • ***
  • Posts: 168
Re: Fun with TC POPUP gui
« Reply #2 on: August 08, 2019, 12:28:54 AM »
Is popup usable to another TCL computer, like net send in the old Windows days?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: Fun with TC POPUP gui
« Reply #3 on: August 08, 2019, 03:03:15 AM »
It is a local command, but you can use ssh (or remote X11).
The only barriers that can stop you are the ones you create yourself.

Offline PDP-8

  • Hero Member
  • *****
  • Posts: 915
Re: Fun with TC POPUP gui
« Reply #4 on: August 08, 2019, 04:42:45 AM »
WOW!  I dig it - maybe I'm easily amused, but I can put this to use.

However, I need to file a bug report.  If you don't use the mouse to click, but instead use a tab / return key, it will send a different value if you hit the space key!

For now, stick to mouse clicks.
That's a UNIX book! - cool  -- Garth

Offline pek

  • Full Member
  • ***
  • Posts: 111
Re: Fun with TC POPUP gui
« Reply #5 on: September 23, 2021, 12:26:57 PM »
Hi, how to add new line in popup?
Code: [Select]
popup Hello World \n Newline..Literally printed
Code: [Select]
Hello World \n Newline..I want to get
Code: [Select]
Hello World
Newline..

How to do that?
Thank you.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11617
Re: Fun with TC POPUP gui
« Reply #6 on: September 23, 2021, 03:06:46 PM »
Hi pek
I don't think you can. I think it's limited to 1 line. It won't wrap long lines either. It just displays a wider popup.
If you do this:
Code: [Select]
tc@E310:~$ popup "Hello there" &
tc@E310:~$ popup "Helloooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo there" &
You'll see popup just uses a much wider window to display the text.

Offline pek

  • Full Member
  • ***
  • Posts: 111
Re: Fun with TC POPUP gui
« Reply #7 on: September 23, 2021, 10:13:53 PM »
That's such a pity.
But good to know, so now I can stop tearing my hair trying to figure out how to do that  ;D
Thanks for clarifying Rich.