[issue23156] Update tix install information in tkinter tix chapter of doc
New submission from Terry J. Reedy: Update tix install info in doc. "Using tix" starts with 3 lines for testing one's tix install and continues '''If this fails, you have a Tk installation problem which must be resolved before proceeding. Use the environment variable TIX_LIBRARY to point to the installed Tix library directory, and make sure you have the dynamic object library (tix8183.dll or libtix8183.so) in the same directory that contains your Tk dynamic object library (tk8183.dll or libtk8183.so). The directory with the dynamic object library should also have a file called pkgIndex.tcl (case sensitive), which contains the line: package ifneeded Tix 8.1 [list load "[file join $dir tix8183.dll]" Tix]''' Almost nothing above matches my working-with-tix 3.4.2 Win 7 install. I do have a tix library directory: python34/tcl/tix8.4.3, but the version number is much newer. Since it is in the right place, TIX_LIBRARY is not needed and there is none. python34/DLLs contains tcl86t.dll and tk86t.dll and NO tix####.dll. Is the once separate tix dll now part of tk dll? I cannot find pkgIndex.tcl; it is certainly not in the DLLs directory nor in the /tcl. The current doc seems useless to people who do not have tix working. See, for example, https://stackoverflow.com/questions/27751923/tix-widgets-installation-issue which is a semi-repeat question and which claims seeing similar reports elsewhere on the net. ---------- assignee: docs@python components: Documentation, Tkinter messages: 233368 nosy: docs@python, serhiy.storchaka, terry.reedy, zach.ware priority: normal severity: normal stage: needs patch status: open title: Update tix install information in tkinter tix chapter of doc type: behavior versions: Python 2.7, Python 3.4, Python 3.5 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue23156> _______________________________________
Terry J. Reedy added the comment: Added Zach for Window build info, Ned for OSX info. ---------- nosy: +ned.deily _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue23156> _______________________________________
Ned Deily added the comment: I'm no expert on Tk but, as best I can tell, Tix is a very old third-party set of Tk extension widgets that has been made obsolete by the Ttk widget set integrated into standard Tk 8.5. See, for example, Kevin Walzer's comments here: http://www.thecodingforums.com/threads/state-of-the-art-tkinter-tk-8-5-tix.6.... Unlike Ttk, Tix is not part of the core Tk distribution so whether or not Tix is available depends on the Tcl/Tk distribution in use. For the Python Windows installer, we ship our own version of Tcl/Tk and include a version of Tix. For the Python OS X installer, we currently do not ship our own version of Tcl/Tk, rather we depend on the user installing a third-party version of Tcl/Tk (we currently recommend ActiveState's ActiveTcl if the use is compatible with ActiveState's license) or falling back to an (old) Apple-supplied version of Tcl/Tk. Neither Apple nor ActiveState include Tix by default. However, ActiveTcl does include Tix in the Tcl Extension Archive (http://wiki.tcl.tk/17340) it maintains and provides a command-line program, teacup, to download, install, and manage TEA extensions, analogous to Python's pip. So it's straightforward to install Tix if you are using ActiveTcl: sudo teacup install Tix Unfortunately, A/S's OS X version of Tix currently downloadable via teacup is built as a 32-bit binary only. The vast majority of users, running on up-to-date OS X systems, will run into another failure since their Python will likely be running in 64-bit mode:
root = Tix.Tk() Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-tk/Tix.py", line 221, in __init__ self.tk.eval('package require Tix') _tkinter.TclError: dlopen(/Library/Tcl/teapot/package/macosx10.5-i386-x86_64/lib/Tix8.4.3/libTix8.4.3.dylib, 6): no suitable image found. Did find: /Library/Tcl/teapot/package/macosx10.5-i386-x86_64/lib/Tix8.4.3/libTix8.4.3.dylib: mach-o, but wrong architecture
Depending on the Python instance in use, running a universal Python in 32-bit mode may be an option or installing a 32-bit-only Python can be done. Either way, it's an unexpected hack. I don't know whether there is a fundamental problem in building Tix for 64-bit on OS X but I think it is telling that there isn't one available from A/S. Likewise, for other platforms, how you make Tix available, if at all, varies. For example, Ubuntu and Debian distributions also do not install Tix by default but it can be installed via their standard package managers. So, all in all, trying to document Tix installation is a major can of worms; I don't think we should be trying to do so in the Python documentation. Further, it seems like we should be strongly discouraging use of Tix in favor of Ttk. ---------- _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue23156> _______________________________________
Terry J. Reedy added the comment: I found tix8.4.3.dll and pkgIndex.tcl inside tcl/tix8.4.3, which is not where the doc currently says to look. Christian Gollwitzer posted a response on the python-list thread "Python Tk Tix GUI documentation & builder overview and tips" (which helped inspire this issue in addition to the SO post). He basically agrees with Ned's ending comment that "we should be strongly discouraging use of Tix in favor of Ttk." "Note that Tix is LEGACY. There are much better options for its widgets available that are based on ttk. ... Not to mention that the Tix widgets are extremely ugly, while the widgets from ttk have a near-native look and feel." So I agree that the opening paragraph of the (T)tkinter.tix section https://docs.python.org/3/library/tkinter.tix.html#module-tkinter.tix should identify it as a legacy python interface to the old, optional, tcl/tk tix extension that has been mostly superceded by widgets added either directly to tk or by ttk. Cristian also listed the ttk replacements. ''' * Hierarchical Listbox use ttk::treeview, tablelist_tile or tkTreeCtrl, with increasing order of capabilities and install complexity * TList: I think tkTreeCtrl can do it, never have used this layout * CheckList: tablelist can be used with an editable field * Grid widget: use tkTable * NoteBook, PanedWindow, ComboBox, LabelFrame -> ttk::notebook, ttk::panedwindow, ttk::combobox, ttk::labelframe * Balloon: tcllib::tooltip ''' The tkinter and tkinter.ttk replacements could similarly be added to the tix widget listing in the doc. ---------- _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue23156> _______________________________________
Mike Basca added the comment: Hi, I'm the original poster in the stack-exchange link. Based on your responses, It seems Ttk is the way to go if you're on Mac OSX 64-bit. Thanks for your time and input. Really appreciate it! ---------- nosy: +abaskm _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue23156> _______________________________________
Cheryl Sabella <cheryl.sabella@gmail.com> added the comment: Since tix has been deprecated since 3.6 (according to the docs with commit bd63353b7433ea8aa831ffb158ac29fb646a6fc9), should this ticket be closed as out of date? ---------- nosy: +cheryl.sabella _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
Change by Terry J. Reedy <tjreedy@udel.edu>: ---------- keywords: +patch pull_requests: +11298 stage: needs patch -> patch review _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
Change by Terry J. Reedy <tjreedy@udel.edu>: ---------- keywords: +patch, patch pull_requests: +11298, 11299 stage: needs patch -> patch review _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
Change by Terry J. Reedy <tjreedy@udel.edu>: ---------- keywords: +patch, patch, patch pull_requests: +11298, 11299, 11300 stage: needs patch -> patch review _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
Terry J. Reedy <tjreedy@udel.edu> added the comment: If the obsolete text is not to revised, it should be removed, as Ned suggested. I don't now think a replacement list is needed. Serhiy, if you have any opinion either way, please say go. ---------- stage: patch review -> needs patch versions: +Python 3.8 -Python 2.7, Python 3.4, Python 3.5 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
Terry J. Reedy <tjreedy@udel.edu> added the comment: /go/so ---------- _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
Terry J. Reedy <tjreedy@udel.edu> added the comment: New changeset cf27c06229eb4b8280bb5f2b93a57e33163411f4 by Terry Jan Reedy in branch 'master': bpo-23156: Remove obsolete tix install directions (GH-11595) https://github.com/python/cpython/commit/cf27c06229eb4b8280bb5f2b93a57e33163... ---------- _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
miss-islington <mariatta.wijaya+miss-islington@gmail.com> added the comment: New changeset ebb08beb08461eb5f147aaca6f86cafa4ea15bff by Miss Islington (bot) in branch '3.7': bpo-23156: Remove obsolete tix install directions (GH-11595) https://github.com/python/cpython/commit/ebb08beb08461eb5f147aaca6f86cafa4ea... ---------- nosy: +miss-islington _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
Change by Terry J. Reedy <tjreedy@udel.edu>: ---------- resolution: -> fixed stage: patch review -> resolved status: open -> closed title: Update tix install information in tkinter tix chapter of doc -> Remove tix install information in tkinter tix chapter of doc versions: +Python 3.7 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue23156> _______________________________________
participants (5)
-
Cheryl Sabella
-
Mike Basca
-
miss-islington
-
Ned Deily
-
Terry J. Reedy