Sujet : Re: console not working
De : rich (at) *nospam* example.invalid (Rich)
Groupes : comp.lang.tclDate : 18. Dec 2024, 01:06:44
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <vjt3mk$1vehm$1@dont-email.me>
References : 1
User-Agent : tin/2.6.1-20211226 ("Convalmore") (Linux/5.15.139 (x86_64))
Luc <
luc@sep.invalid> wrote:
I am trying to run the 'console show' command. But Tk is not having it.
Error in startup script: invalid command name "console"
while executing
"console show"
(file "p1.tcl" line 4)
Compilation failed.
To my dismay, the manual says,
"Except for TkAqua, this command is not available when Tk is loaded
into a tclsh interpreter with 'package require Tk' as a conventional
terminal is expected to be present in that case."
I guess I will never understand that decision. So what if a terminal
is expected to be present? How about letting that decision up to us?
Anyway, I try to run the script with wish and the same error happens
Any solution to that?
It is also only available on Windows (and maybe Mac) builds.
Linux (Unix) builds don't include it because a 'console' is already
available as the terminal emulator you launch the script from.
So if you are launchin p1.tcl on Linux, you'll get that error if you
try to do 'console show'.
The typical replacement under Linux is tkcon
https://wiki.tcl-lang.org/page/Tkcon