The purpose of winico is to allow a user to manage the icon on the tk toplevel and taskbar - http://sourceforge.net/projects/tcllib/ ''more specifically, http://tktable.sourceforge.net/. Browse the CVS repository [http://cvs.sourceforge.net/viewcvs.py/tktable/winico/] to find it.'' Winico sources are also available through ftp://www.tcl.tk/pub/tcl/nightly-cvs/ . Winico is indispensable for many desired Windows-specific manipulations. [Tom Wilkason] describes how to work with an icon in the [system tray] in a posting to [the comp.lang.tcl newsgroup] [http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&frame=right&th=9aa47598b4aba9a9&seekm=j5br7.31096%24ar5.1911394%40news1.rdc1.ga.home.com#link4]. How does one query whether an icon is still in the tray or not? ''I keep track of this with the use of a variable, as you can then query it whenever the mood takes you. [Ro]'' What: winico Where: http://ftp.bj-ig.de/pub/tcltk/winico03.zip http://www.tcl.tk/software/tcltk/netcvs.html ftp://ftp.procplace.com/pub/tcl/sorted/packages-8.0/distrib/cvs-winico.tar.gz Description: Small extension to Tk 8.x for Windows to allow the user to set the icon on the Tk toplevel and to set taskbar status area icons. Winico source also available via the Tcl core's Net CVS repository. The Net CVS version has a TEA compliant makefile. Updated: 03/2001 Contact: mailto:leo@bj-ig.de (Leo Schubert) Q: Has the functionality of winico been added to the core somewhere in the line of development? (= is it redundent by now?) 08052003 I'm not aware of any TIP to take this action. [Vince]: The ability to set a toplevel's icon has been placed in the core -- see '[wm iconbitmap]'. It also overcomes a number of small shortcomings with winico in that area. Vince - does that mean that winico provides no useful functionality for ''current'' versions of Tk? What version of Tk ? [Vince]: I believe from version 8.4.0. But winico still provides other functionality not in Tk: the ability to manipulate icons/messages in the tray area of the windows taskbar. ---- ''Installing winico is not difficult. It certainly is not easy either. There is plenty of room for mistakes. Installing the docs failed. The rest seems to have turned out OK, but Tcl/Tk cannot find the package. I wonder if it is even supposed to work with 8.4.3, as it makes so many references to Tcl/Tk 8.0'' ---- Q. 19-Oct-2003. I recently downloaded Winico and the package contained 2 winico03.dll files. One was about 77kbytes long and the other was about 27kbytes. The long gave me errors loading it but the shorter one works. Does anyone know why there are two versions. Now that I have winico working, I have placed an icon into the system tray and would like to know how I could create a menu above the icon when the it is left clicked with the mouse. Can anyone help? [MG] April 1st 2004 - I use this for getting menus in the system tray. Works on Win 98, and (I'm told) Win XP. winico taskbar add $winico -callback {winicoCallback %m %x %y} -text $yourAppName proc winicoCallback {t {x 0} {y 0}} { if { $t == "WM_LBUTTONUP" } { wm deiconify . raise . focus . } elseif { $t == "WM_RBUTTONUP" } { .winicoPopup post $x $y .winicoPopup activate 0 } } where ''.winicoPopup'' is a menu I've already created, and ''.'' is the main GUI window of my application. That causes a left-click of the icon to bring the application up to the front, and a right-click to post the menu. Simply because it took me so long to find a working, pre-compiled binary of Winico, I've put a copy up on my website at [http://www.geocities.com/mush_code/winico.zip]. To install it, just unzip those files into somewhere on the $auto_path, and then 'package require winico'. The Readme file that came with this copy of the source (which has some docs for using the code) is at [http://www.geocities.com/mush_code/winico.txt]. ---- Q. Is there no documentation for winico? A. You can find some in the tktable website at http://tktable.sourceforge.net/winico/winico.html ---- Along with the '''winico.html''' documentation referenced immediately above, also be aware of these remarks from [KBK] and [DRH]: "to look 'normal' you need a .ico file with all the sizes. The Windows standards recommend including: 48x48 32bpp 32x32 32bpp 16x16 32bpp 48x48 8bpp 32x32 8bpp 16x16 8bpp (plus same sizes at 4bpp and monochrome). Nowadays, typically only 32bpp and possibly monochrome are relevant ... because few users use 4- or 8-bit depth color settings. ... Windows sometimes reduces the size to 16x16 automatically, but I think you have to give winico a 32x32. The stylized 'Tk' that appears in the upper left is at 16x16. You are also limited to 16 colors, if memory serves." ---- As of October 2005, there's a known right-click issue [https://sourceforge.net/tracker/index.php?func=detail&aid=1297800&group_id=12997&atid=112997]. ---- [Leo Schubert] | [[ [Category Package] | ]]