f



in Tcl/tk, How can I redirect stdout to a text widget?

I already wrote a tcl script. there are many output information sent
to stdout in the script. Now I'm using TK to optimize this script, I
hope to redirect all output information to a text widget, How can i do
it?

I tried to rediect output information to a file, it's OK. then I want
to use "fileevent" command to trace the file's action and then send
new information to a text widget.   but system say that "filehandle
cannot be read" error.   I think that the reason should be the file is
open for "w" and cannot be read.   How can i do it?


close stdout
set file_a [open "testfile" "w"]
fileevent $file_a readable Log      # this Log procedure write
information to a text widget.


Any responses will be very appreciated. thanks.
0
hansyin1 (19)
12/23/2004 7:29:22 AM
comp.lang.tcl 23429 articles. 2 followers. Post Follow

2 Replies
889 Views

Similar Articles

[PageSpeed] 51

Hans Yin wrote:
> 
> I already wrote a tcl script. there are many output information sent
> to stdout in the script. Now I'm using TK to optimize this script, I
> hope to redirect all output information to a text widget, How can i do
> it?
> 
> I tried to rediect output information to a file, it's OK. then I want
> to use "fileevent" command to trace the file's action and then send
> new information to a text widget.   but system say that "filehandle
> cannot be read" error.   I think that the reason should be the file is
> open for "w" and cannot be read.   How can i do it?
> 
> close stdout
> set file_a [open "testfile" "w"]
> fileevent $file_a readable Log      # this Log procedure write
> information to a text widget.
> 
> Any responses will be very appreciated. thanks.

I understand that you have run the program and redirected its
output to a file. In that case:

# Create the widget (I leave the scrollbars to you)

pack [text .t]

# Read the file and put it in the text widget

set infile [open "testfile"]
set contents [read $infile]
close $infile
..t insert end $contents

If you want to catch the output while the program is running,
you indeed need the fileevent command:

set infile [open "|program"]

fileevent $infile readable Log

proc Log {infile} {
    if { [gets $infile line] >= 0 } {
        .t insert end "$line\n"  ;# Add a newline too
    } else {
        # Close the pipe - otherwise we will loop endlessly
        close $infile
    }
}

NOTE: this is merely an illustration - I have not tested this
fragment.

Regards,

Arjen
0
arjen.markus (2628)
12/23/2004 10:04:34 AM
If all output from your script is generated with "puts" you may just
want to redefine its behavior when doing your optimizations.

if {[info exists env(DEBUG)] && [catch {package present Tk}] == 0} {
rename puts tcl_puts
proc puts {args} {
# put special code here to send data to the text widget
# also print to the screen
uplevel 1 tcl_puts $args
}
}

I like to define my own proc for debugging that can be configured to do
different things based on the context.  For example output can be
supressed in a production version of the script but turned on for
debugging.

if {[info exists env(DEBUG)]} {
if {[catch {package present Tk}]} {
proc debug {args} {# do something here}
} else {
proc debug {args} { eval puts $args }
}
else {
  proc debug {args} {# do nothing}
}

-Ahran

0
adunsmoor1 (19)
1/5/2005 8:17:58 PM
Reply:

Similar Artilces:

[TCL/TK interface] Passing variable to TCL/TK
Hi, I am trying to sent to a variable to tcl/tk and unify there it with a string. I wrote the prolog code: :- use_module(library(tcltk)). :- use_package(classic). go(A):- tk_new([name('Simple')], Tcl), tcl_eval(Tcl, 'source simple2.tcl', _), tcl_eval(Tcl, ['ask', br(write(A))], _), tk_main_loop(Tcl), tcl_delete(Tcl). and the tcl file simple2.tcl proc ask {var} { unify_term $var my_value } unfortunatelly when I query for go(S). the interpeter goes into a loop (!?). Where I am wrong. Are there any example code somewhere i...

Tcl/Tk text widget article in Linux Journal
Linux Journal have just published an article I wrote on the Tk text widget. None of the seasoned veterans on c.l.t will learn anything from it, but newbies might find it useful. The information should apply to Windows users too. The link is: http://www.linuxjournal.com/article.php?sid=7357&mode=thread&order=0 This is the first Tcl article (or indeed, any article) I've had published, so I'd welcome any constructive feedback - both on my writing and my Tcl coding. More importantly, this is the first Tcl based article that Linux Journal have published. When I made the original suggestion to the editor he asked why Tcl was better than Perl, Python and shell, which are the usual languages the magazine focuses on. I put forward gentle arguments and he agreed to give something Tcl-based a try. The magazine is now awaiting feedback to see if it is worth them running further Tcl articles. Putting that another way, there's a new opening for spreading the Tcl-word here. Linux Journal receiving page hits and comments from the Tcl community can only be a good thing, so hit the link! In article <400b35da$0$1753$5a62ac22@freenews.iinet.net.au>, Derek Fountain <nomail@hursley.ibm.com> wrote: . . . > http://www.linuxjournal.com/article.php?sid=7357&mode=thread&order=0 > >This is the first Tcl article (or indeed, any article) I've had published, >so I'd welcome any constructive feedback - both on my writing and my Tcl ...

tcl/tk 8.4 text widget question
Hi! Can you help. I have a gui script that displays the output of commands as they are ran in a text widget with scroll bar. However, once the output goes past the height of the text widget, the text does not automatically scroll down. When the processing is complete, I have to scroll to the bottom to see the last few lines including the line where it says "Processing complete" Does anyone know how to fix this? Meg Cooper mulkey_mouse@cox.net wrote: > Hi! > Can you help. > I have a gui script that displays the output of commands as they are > ran in a text widget with scroll bar. However, once the output goes > past the height of the text widget, the text does not automatically > scroll down. When the processing is complete, I have to scroll to the > bottom to see the last few lines including the line where it says > "Processing complete" > > Does anyone know how to fix this? > Meg Cooper Try... $txt see end .... after you add each new line of text. Jeff Hey!! Thanks!! It worked like a charm. ---------- Forwarded message ---------- From: Jeff Godfrey <jeff_godf...@pobox.com> Date: Feb 25, 12:32=A0pm Subject: tcl/tk 8.4 text widget question To: comp.lang.tcl mulkey_mo...@cox.net wrote: > Hi! > Can you help. > I have a gui script that displays the output of commands as they are > ran in a text widget with scroll bar. However, once the output goes > past the height of the text widget, the tex...

Opening a TCL program from within another TCL program in ANSYS Tcl-Tk
Hi everyone, I have been pulling my hair with this one for a couple of days and still have not found a fix. I'm working within ANSYS Tcl-Tk implementation. I created a Tcl-Tk script that generates a simple window with three buttons. Each button opens another window which is created in a separate Tcl file. The second window have a lot of text entries, variables, procedures, etc. I can open the second Tcl file by itself and everything works as supposed, but when I open it using the button in the first window, it opens but any procedure called by the widgets on the second window are not found... Here's the deal... Since I'm working within the ANSYS implementation of Tcl-Tk, I'm actually using an ANSYS command to open the second window. The command I use is: ### ans_sendcommand ~eui,'source O:/mad_projects_2/ANSYS/Macros/ IBR_CAS.tcl' ### It actually sends a command back to ANSYS telling it to execute a Tcl command... I know this is not pretty but its the only way i was able to make it at least show the window. ############################## #Main Tcl (excerpt): ############################## namespace eval Tools { proc IBRCambpell {} { #source O:/mad_projects_2/ANSYS/Macros/IBR_CAS.tcl ans_sendcommand ~eui,'source O:/mad_projects_2/ANSYS/Macros/ IBR_CAS.tcl' } proc viewManager {} { ans_sendcommand ~eui,'source O:/mad_projects_2/ANSYS/Macros/ ViewManager.tcl' } proc powerAnnotation {} { ans_sendcommand ~eui,'source ...

Text widget Tab behaviour in Tcl/Tk 8.5
Last October I noticed that there was a difference in the way text widget tabs are handled in Tcl 8.5 when compared with 8.4. Apparently this is a new feature - but I was told that an option will be added to allow the "old" style of tab behaviour (so that existing code will work properly). I was just wondering if there have been any developments in this area? Best Regards, =Adrian= Adrian Davis wrote: > Last October I noticed that there was a difference in the way text > widget tabs are handled in Tcl 8.5 when compared with 8.4. > > Apparently this is a new feature - but I was told that an option will > be added to allow the "old" style of tab behaviour (so that existing > code will work properly). > > I was just wondering if there have been any developments in this area? > > Best Regards, > =Adrian= I think the -tabstyle option accomplishes what you want. > I think the -tabstyle option accomplishes what you want. That's done the trick. Many Thanks, =Adrian= ...

1. Thank you everyone for your help. 2. Tcl/Tk Designer 3. Text Editor Widget
Hello CLT Thank you everyone that responds to my posts asking for info. I really appreciate it. At this stage of my tcl career I can ask many more questions than I can answer. Speaking of questions, here are a few more: 1. Is there a tcl/tk based user interface designer available? There has been no recent activity on VTCL, and SpecTcl looks even older. I am not averse to using VTCL. I would just prefer to use something that is being actively maintained. 2. Is there a text editor widget that I can drop into an application? I realize I could put something together with the text widget and perhaps ntext. The problem is that this editing feature is not the focus of my application. It adds value for sure. However I cannot spend much of my time there. Try ctext at http://wiki.tcl.tk/4134 /Ashok On Sep 16, 7:07 am, Kuberan Naganathan <kube...@att.net> wrote: > Hello CLT > > Thank you everyone that responds to my posts asking for info. I really > appreciate it. At this stage of my tcl career I can ask many more > questions than I can answer. > > Speaking of questions, here are a few more: > > 1. Is there a tcl/tk based user interface designer available? > There has been no recent activity on VTCL, and SpecTcl looks even > older. I am not averse to using VTCL. I would just prefer to use > something that is being actively maintained. > > 2. Is there a text editor...

How can I set text widget's content via Tcl Library without evaluation ?
Hi all: I am having some fun with the text widget. Whenever I call a TcL_EvalEx to set the text area of a text widget by saying ".t insert end my-text" and my-text is a string like "[exit]" then, yes, Tcl exits my application. Now this is clearly not what I want. Whatever the text content is it should simply appear in text widget's text area. So the idea is to use Tcl_SetVar or some such to do this. Only thing is I can't figure out how. How can I acess a text widget's text without using the insert end mechanism vi the Tcl Library C interface? Any hints appreciated. Thx ! Frank In article <m2k686xage.fsf@pcsde001.local>, Frank Goenninger DG1SBG <dont-email-me@nomail.org> wrote: >Hi all: > >I am having some fun with the text widget. Whenever I call a >TcL_EvalEx to set the text area of a text widget by saying > >".t insert end my-text" > >and my-text is a string like "[exit]" then, yes, Tcl exits my >application. Now this is clearly not what I want. Whatever the text >content is it should simply appear in text widget's text area. > >So the idea is to use Tcl_SetVar or some such to do this. Only thing >is I can't figure out how. How can I acess a text widget's text >without using the insert end mechanism vi the Tcl Library C interface? . . . You are working way too hard. I think what you really want is closer to .t insert end {[exit]} In ...

Debugger for Tcl/Tk and [incr Tcl]
hi, where can i get Coverage for debugging tcl/tk, [incr Tcl] source? this tool is advised to use in 'Practical Programming in Tcl and Tk' or any other good debugger, which i could use? best, s. On Jan 23, 5:56=A0am, Sitaca <sit...@gmail.com> wrote: > hi, > > where can i get Coverage for debugging tcl/tk, [incr Tcl] source? > this tool is advised to use in 'Practical Programming in Tcl and Tk' > > or any other good debugger, which i could use? I see, at http://wiki.tcl.tk/8638 , a brief reference to the topic of coverage for tcl. I don't know whether or not any of the tools mentioned include coverage of itcl. On 23 jan, 12:52, "Larry W. Virden" <lvir...@gmail.com> wrote: > On Jan 23, 5:56=A0am, Sitaca <sit...@gmail.com> wrote: > > > hi, > > > where can i get Coverage for debugging tcl/tk, [incr Tcl] source? > > this tool is advised to use in 'Practical Programming in Tcl and Tk' > > > or any other good debugger, which i could use? > > I see, athttp://wiki.tcl.tk/8638, a brief reference to the topic of > coverage for tcl. I don't know whether or not any of the tools > mentioned include coverage of itcl. I have a more complete version of the coverage tool mentioned on that page. I just never got around to publishing it more widely. As for debuggers: the Wiki has a lot of pointers on that subject as well. Regards, Arjen Larry W. Virden wrote:...

can TCL/Tk do this?
Hi, I'm working on a project for Newcastle University which requires gluing TCL/Tk to Lisp (I've done that) and then making the resulting implementation available on the web (I haven't done this). My superior reckons that TCL/Tk is not suitable and wants to use XML/SVG (of which I know nothing) and Javascript. His reasons are as yet, obscure to me, but one reason is that he feels that the implementation should not use anything that does not come with Windows. Now can you tell me 1. Is TCL/Tk server-based rather than client-based (my book (out of date) says it is server based). 2. Does canvas and all the other goodies run off the web too? 3. Does the user have to load down special plug-ins for TCL/Tk to run this project off the web assuming all the Lisp stuff is on the server? 4. If I have a stand-alone TCL/Tk implementation, does moving it to a web based version involve extnesive rewriting? 5. What do you think of using SVG/XML/Javascript vs TCL/Tk? Mark Mark Tarver wrote: > 1. Is TCL/Tk server-based rather than client-based (my book > (out of date) says it is server based). Well, Tcl can be used anywhere. However, since it doesn't ship with windows, to make it be 'client (browser) based', you would have to get people to install the plugin: http://www.tcl.tk/software/plugin/ > 2. Does canvas and all the other goodies run off the web too? If you have the plugin. > 3. Does the user have to load ...

Newbie to Tcl/Tk: Question about Tcl and VxWorks....
Hello All, I have tried looking on the offical tcl/tk website and also at WindRiver's without success. Please forgive my ignorance on this, but is tcl/tk available for VxWorks or is there in progress a port going on. Many thanks in advance, Richard "Richard Latter" <richard_l@latter.demon.co.uk> writes: > I have tried looking on the offical tcl/tk website and also at WindRiver's > without success. Please forgive my ignorance on this, but is tcl/tk > available for VxWorks or is there in progress a port going on. I have ancient Tcl 7.3 here, but don't know of newer ports. Donald Arseneau asnd@triumf.ca ...

Incr Tcl /Tk for Tcl 8.4
Hi, I am trying to download incr Tcl and incr Tk for Tcl/Tk 8.4.19. I looked at: http://sourceforge.net/projects/incrtcl/files/%5BIncr%20Tcl_Tk%5D-source/3.4.1/ But only itcl seems to be there. And the CVS doesn't have the 3.4.1 tag. Do you know where I can get incr Tk and hopefully a corresponding iwidgets? Thanks, Andres On 5 Okt., 11:16, Andres Garcia <tclc...@gmail.com> wrote: > Hi, > > I am trying to download incr Tcl and incr Tk for Tcl/Tk 8.4.19. > > I looked at: > > http://sourceforge.net/projects/incrtcl/files/%5BIncr%20Tcl_Tk%5D-sou... > > But only itcl seems to be there. And the CVS doesn't have the 3.4.1 > tag. There is no tag for this version. But you can use a date. cvs -d :pserver:anonymous@incrtcl.cvs.sourceforge.net:/cvsroot/incrtcl -z3 co -P -D 2010-10-28 incrTcl > > Do you know where I can get incr Tk and hopefully a corresponding > iwidgets? Itk is inside itcl sources. cvs -d :pserver:anonymous@incrtcl.cvs.sourceforge.net:/cvsroot/incrtcl -z3 co -P -D 2010-10-28 iwidgets HTH rene Thanks. Andres >> I am trying to download incr Tcl and incr Tk for Tcl/Tk 8.4.19. >> >> I looked at: >> >> http://sourceforge.net/projects/incrtcl/files/%5BIncr%20Tcl_Tk%5D-sou... >> >> But only itcl seems to be there. And the CVS doesn't have the 3.4.1 >> tag. The released sources for Itcl 3.4.1 were not developed in SF CVS. SF CVS got abandoned during the January...

Tkinter question: howto redirect text output (stdout) to Text widget?
hi all, could anyone post an example how to redirect text output (stdout) to Text widget? Thank you in advance, Dmitrey. ...

tcl/tk unicode wie kann man formel/math. zeichen in tk unter tcl anzeigen lassen?
Hallo, ich schreibe gerade an einen programm, dass auf windows unix und vielleicht auch anderen plattformen laufen soll. es sollen auch mathematische zeichen wie alpha 'm�' etc. dargestellt werden. mit welchen zeichensatz (vielleicht unicode) kann man dies realisieren? funktioniert es mit einen zeichensatz f�r alle plattformen unabh�ngig? English summary for the rest of the world: sven.rega@gmx.de would like to use mathematical symbols like "mu" in Tk applications. He asks if Unicode is the solution and whether that works on all platforms. I assert that Unicode works since Tcl 8.1 and that UCN syntax like \u00B5 is the way to go with symbols hardcoded in Tcl scripts. I point him to "charmap.exe" (Windows), "Character Palette" (Mac OS X) or generically to <http://www.unicode.org> to find out the Unicode code points. ---------------- Hi, Versuch doch bitte beim n�chsten Mal auf Englisch zu fragen, sonst kann Dir nur ein Bruchteil der Leute hier folgen. sven.rega@gmx.de (xfan) writes: > ich schreibe gerade an einen programm, dass auf windows unix und > vielleicht auch anderen plattformen laufen soll. es sollen auch > mathematische zeichen wie alpha 'm�' etc. dargestellt werden. mit > welchen zeichensatz (vielleicht unicode) kann man dies realisieren? Ja, das funktioniert mit Unicode in Tcl seit Version 8.1. > funktioniert es mit einen zeichensatz f�r alle plattformen > unabh�ngig? Das ist die ...

E.J. Friedman-Hill's Tcl/Tk Course
E.J. Friedman-Hill's Tcl/Tk Course Tcl/Tk Programming in Five Easy Lessons http://www.linbox.com/ucome.rvt/any/doc_distrib/tcltk-8.3.2/TclCourse/ I am unable to open the ppt files that seem very promising. Can anyone see what is the problem with them and can convert/fix so that I can open in the office 2007 or open office ? Thanks Bolega On 24/03/2011 2:51 AM, bolega wrote: > E.J. Friedman-Hill's Tcl/Tk Course > Tcl/Tk Programming in Five Easy Lessons > > http://www.linbox.com/ucome.rvt/any/doc_distrib/tcltk-8.3.2/TclCourse/ > > I am unable to o...

Can TCL/Tk do WYSIWYG?
I was just playing with the canvas postcript operation. Way cool, but my text is coming out a different size. This is on win XP with both wish84 and wish85 beta. I am specifying the font "Times" with various reasonable sizes (12, 24, 36 and more), everything comes out smaller on my HP Laserjet 1200 (and when viewed in GhostView. I guess this could be a font substitution thing, but I had no luck specifying a fontmap (I tried telling it to substitute Helvetica for Times just to see if I was getting through to TCL/Tk, but nothing took -- the example I had was from Welch et al "Practical Programming in TCL and Tk" for mapping from X screen fonts to Postscript, maybe I should not have tried to follow that? I better start another thread <g> -- anyway, so I tried using Times in the hopes that a fontmap would not be necessary and that Tk would get the right font. It /does/ come up with a serif font instead of the Helvetica i was getting when I was originally using a Bodoni TTF, so -- hey, I will try a longer string so i can see if the PS font is indeed Times. Anyway, am I on a fool's errand trying to get WYSIWYG from the canvas postscript operation or TCL/TK in general? ken -- Cells: http://common-lisp.net/project/cells/ "And I will know my song well before I start singing." - Bob Dylan Ken Tilton wrote: > I was just playing with the canvas postcript operation. Way cool, but my > text is coming out a different siz...

tcl-pam: PAM authentication for Tcl (Tcl package)
This is an announcement for a relatively new Tcl project: tcl-pam Tcl-pam is a Tcl interface to the PAM* service of Linux. It provides a Tcl package that allows Tcl scripts to use PAM to authenticate users and programs. It relies on linux-pam library: http://www.kernel.org/pub/linux/libs/pam/ * PAM (Pluggable Authentication Modules): A mechanism to integrate multiple low−level authentication schemes into a high−level application programming interface (API). This enables programs that rely on authentication to be written independently of the underlying authentication scheme. Platform: Linux Home page: http://sourceforge.net/projects/tcl-pam/ Man page: http://tcl-pam.sourceforge.net/ Author: Alexandros Stergiakis alsterg ...

tcl-gaul: Genetic Algorithms for Tcl. (Tcl package)
This is an announcement for a relatively new Tcl project: tcl-gaul Tcl-gaul is a Tcl extension for genetic/evolutionary algorithm processing.It relies on the GAUL library: http://gaul.sourceforge.net/ * A genetic algorithm (GA) is a search technique used in computing to find exact or approximate solutions to optimization and search problems. Genetic algorithms are categorized as global search heuristics. They are a particular class of evolutionary algorithms that use techniques inspired by evolutionary biology such as inheritance, mutation, selection, and crossover. For an introduction to genetic algorithms visit: http://gaul.sourceforge.net/intro.html Platform: Linux (GAUL library dependency) Home page: http://sourceforge.net/projects/tcl-gaul/ Man page: http://tcl-gaul.sourceforge.net/ Author: Alexandros Stergiakis alsterg ...

how to access prolog from tcl?(not using tcl/tk interface from prolog)
hi, I am now doing my thesis project relate to mobile agent technology which need to access prolog from tcl. There are a lot of prologs which have the function to access tcl from prolog, but I need to access prolog from tcl.(I can not use the method that first load prolog, then access tcl via the interface, and reload prolog). So is there any one can help me or give me some tips to solve this problem? Now I can only found one article to solve this problem(http://tkoutline.sourceforge.net/wiki/38). I tried the code, but unfortunately, the terminal always crashed and did not give any response when I run the second command of its example---"% prolog::init". I could run the command of "plcon -s interp.pl -t main -q" in DOS terminal without problem. Originally I thought it is the version problem of tcl, so I changed it from 8.4.9 to 8.0.3, but the problem was still there. My SWI-prolog version is 3.1.2. My operating system is winXP. I am now very nervous about that, Please give me some help to solve this problem, or tell me some other way to access prolog from tcl. Thank you very much I did not give up the solution of (http://tkoutline.sourceforge.net/wiki/38). Now I changed SWI-prolog version to 5.4.4. When I run the second command(prolog::init) of the example from wish.exe, it pop up a window, said that Prolog interpreter closed unexpectedly Prolog interpreter closed unexpectedly while executing "error "Prolog interpreter closed unexpect...

tcl-mmap: A POSIX mmap interface for Tcl. (Tcl package)
This is an announcement for a relatively new Tcl project: tcl-mmap Tcl-mmap is a Tcl interface to the POSIX mmap* system call. It provides a Tcl package that allows Tcl scripts to: 1) Memory map files for improved access efficiency; 2) Share memory between related processes; 3) Easily implement cyclic persistent log files. * See the mmap(2) man page. Platform: Linux/Unix Home page: http://sourceforge.net/projects/tcl-mmap/ Man page: http://tcl-mmap.sourceforge.net/ Author: Alexandros Stergiakis On Sep 3, 11:48=A0am, Alexandros Stergiakis <alst...@gmail.com> wrote: > This is an announcement for a relatively new Tcl project: tcl-mmap > > Tcl-mmap is a Tcl interface to the POSIX mmap* system call. It provides > a Tcl package that allows Tcl scripts to: 1) Memory map files for > improved access efficiency; 2) Share memory between related processes; > 3) Easily implement cyclic persistent log files. > > * See the mmap(2) man page. > Great to see this and the other packages you made. Looking at the manpage it looks a bit misformatted before the usage example. Any specific reason to use GPL for this instead the usual Tcl/MIT/BSD style license used? Michael schlenk wrote: > On Sep 3, 11:48 am, Alexandros Stergiakis <alst...@gmail.com> wrote: >> This is an announcement for a relatively new Tcl project: tcl-mmap >> >> Tcl-mmap is a Tcl interface to the POSIX mmap* system call. It provides >> a Tcl package that...

tcl-syslog: Unix system logging for Tcl (Tcl package)
This is an announcement for a relatively new Tcl project: tcl-syslog Tcl-syslog is a Tcl interface to the *nix syslog service. It provides a Tcl package that allows Tcl scripts to log messages to syslog. Platform: Linux/Unix Home page: http://sourceforge.net/projects/tcl-syslog/ Man page: http://tcl-syslog.sourceforge.net/ Author: Alexandros Stergiakis alsterg ...

tcl-mq: POSIX Message Queues for Tcl. (Tcl package)
This is an announcement for a relatively new Tcl project: tcl-mp Tcl-mp is a Tcl interface to POSIX Message Queues*. It provides a Tcl package that allows scripts to create/open/close/unlink multiple parallel message queues, and to send/receive messages synchronously and asynchronously to/from them. * A POSIX message queue is an Inter-Process Communication mechanism available on Linux and some other POSIX-compliant operating systems. It allows to or more processes (or threads) to communicate under the same OS. The messages are buffered by the kernel, which gives them kernel persistency. A message queue can be thought of as a linked list of messages. Threads with adequate permission can put messages onto the queue, and threads with adequuate permission can remove messages from the queue. Each message is assigned a priority by the sender, and the oldest message of highest priority is always retrieved first. Unlike PIPES and FIFOS, no requirement exists that someone be waiting for a message to arrive on a queue, before some process writes a message to that queue. It's not even a requirement for both processes to exist at the same time. Read mq_overview(7) for more details Platform: Linux Home page: http://sourceforge.net/projects/tcl-mp/ Man page: http://tcl-mp.sourceforge.net/ Author: Alexandros Stergiakis alsterg On Sep 3, 11:37=A0am, Alexandros Stergiakis <alst...@gmail.com> wrote: > This is an announcement for a relatively new Tcl pro...

Redirection of TCL/Tk script errors?
Hi guys. I'm using ActiveTCL 8.4.x. Is there any way to redirect general script error output to a particular Proc rather than the default error widgets? If the worst happens, I'd rather users saw a simple tk_messageBox stating something simple and clear like "Application error" rather than fragments of TCL source code that might scare them. Synic wrote: > I'm using ActiveTCL 8.4.x. Is there any way to redirect general script error > output to a particular Proc rather than the default error widgets? Of course, see manpage about [bgerror]. kind regards -- Matthias Kraft Software AG, Germany (They that can give up essential liberty to obtain a little temporary) (safety deserve neither liberty nor safety. -- Benjamin Franklin) Matthias Kraft <Matthias.Kraft@nospam.softwareag.com> wrote: > Synic wrote: >> I'm using ActiveTCL 8.4.x. Is there any way to redirect general script error >> output to a particular Proc rather than the default error widgets? > > Of course, see manpage about [bgerror]. Thanks Matthias. That does exactly what I was after :-). ...

Can be Tcl/Tk installed in uCLinux?
if can ,how much the memory will be necessary? thx! JettaTang@gmail.com schrieb: > if can ,how much the memory will be necessary? > thx! > Don't know about uCLinux, but if you are looking for a low memory Tcl implementation, take a look at tinytcl and jim and hecl. http://jim.berlios.de http://tinytcl.sourceforge.net http://www.hecl.org/ Michael Michael Schlenker wrote: > JettaTang@gmail.com schrieb: > >> if can ,how much the memory will be necessary? >> thx! >> > Don't know about uCLinux, but if you are looking for a low memory Tcl > implementation, take a look at tinytcl and jim and hecl. > > http://jim.berlios.de > http://tinytcl.sourceforge.net > http://www.hecl.org/ Hecl doesn't take up much space *if* there is a J2ME JVM installed, which is a big if. Jim or TinyTcl is likely to be smaller overall if you can compile stuff for the target device. -- David N. Welton - http://www.dedasys.com/davidw/ Linux, Open Source Consulting - http://www.dedasys.com/ ...

looking for tcl\tk widget demo
Hi, I'm looking for tcl\tk widget demo for something like a setup exe (install application). Thanks, Yael. yael wrote: > I'm looking for tcl\tk widget demo for something like a setup exe > (install application). http://www.activestate.com/Tcl Install it on Windows - that is a fully self-contained Tcl/Tk app that installs Tcl/Tk from within itself. -- Jeff Hobbs The Tcl Guy Senior Developer http://www.ActiveState.com/ Tcl Support and Productivity Solutions Jeff Hobbs wrote: > yael wrote: > >> I'm looking for tcl\tk widget demo for something like a setup exe >> (install application). > > > http://www.activestate.com/Tcl > > Install it on Windows - that is a fully self-contained Tcl/Tk app > that installs Tcl/Tk from within itself. I should add that it is also fully cross-platform, we just haven't released it as a self-installer on *nix because most users are so distrusting of self-extracting executables there. :/ -- Jeff Hobbs The Tcl Guy Senior Developer http://www.ActiveState.com/ Tcl Support and Productivity Solutions "Jeff Hobbs" <jeffh@activestate.com> wrote > > > I'm looking for tcl\tk widget demo for something like a setup exe > > (install application). > > http://www.activestate.com/Tcl > > Install it on Windows - that is a fully self-contained ...

Web resources about - in Tcl/tk, How can I redirect stdout to a text widget? - comp.lang.tcl

Asteroid Redirect Mission - Wikipedia, the free encyclopedia
The Asteroid Redirect Mission ( ARM ), also known as the Asteroid Retrieval and Utilization ( ARU ) mission and the Asteroid Initiative , is ...

What percentage of PageRank is lost through a 301 redirect? - YouTube
Roughly what percentage of PageRank is lost through a 301 redirect? Sam Harries, Exeter, United Kingdom Have a question? Ask it in our Webmaster ...

CloudFlare boss’s Gmail hacked in redirect attack on 4Chan
Content distribution network CloudFlare reset all its customer API keys over the weekend after its CEO’s personal and corporate Gmail was breached ...

Parramatta shootings: We need to redouble our efforts to redirect all at-risk teens from a destructive ...
He was too young to drive, and too young to vote. We may discover why he killed, but we may not. What we can do is boost our efforts to divert ...

Parramatta shootings: We need to redouble our efforts to redirect all at-risk teens from a destructive ...
He was too young to drive, and too young to vote. We may discover why he killed, but we may not. What we can do is boost our efforts to divert ...

Budget 2015: Generic drug prices expected to fall as Government redirects health spending
Patients will benefit from a significant drop in the price of many common drugs with changes due in next week's budget.

Defence review aims to redirect $1B a year in spending
The Department of National Defence today launched a top-down review of how it manages its back office with a goal of finding about a billion ...

Redirect Permanent
Just a little note to tell you this blog has now completely moved to its new home. I hope you find it nicer, especially more mobile-friendly. ...

Colorado governor candidate redirects volunteers to Douglas County races
KUSA-Republican gubernatorial candidate and current Colorado Secretary of State Scott Gessler is wading into a local school board election. ...

China’s ‘Great Cannon’ Uses DDoS Style Redirects for Censorship
... the great firewall works to block traffic by terminating links; it can’t alter the traffic, just stop it. The great cannon modifies and redirects ...

Resources last updated: 3/13/2016 6:32:35 PM