Skip to content
This repository has been archived by the owner on Jan 31, 2023. It is now read-only.

Include tcl/tk for tkinter support #32

Open
embray opened this issue May 21, 2019 · 2 comments
Open

Include tcl/tk for tkinter support #32

embray opened this issue May 21, 2019 · 2 comments

Comments

@embray
Copy link
Contributor

embray commented May 21, 2019

I've seen one or two people request this before. I don't think it's high priority but it would be worth seeing how much size it adds to the installation. It might be too complicated if it requires an X server and all that which I fear it might...

@slel
Copy link
Member

slel commented Aug 14, 2020

The "topology of 3-manifolds" or "T3M" group provide scripts to
fix Sage on macOS by endowing Sage's Python with tkinter and ssl.

Not claiming this helps do similar things on the Cygwin side...

But if systematically packaging tk makes the installation too large,
the approach of offering a separate script to add tcl/tk and tkinter
for those who want might be a path for Sage-Windows too.

@embray
Copy link
Contributor Author

embray commented Aug 14, 2020

The main difficulty with this is not so much with including tcl/tk which is straightforward and not too onerous.

The problem is that the current tk package for Cygwin is configured to be fully reliant on POSIX APIs, but specifically it uses X11 for rendering, so you have to include and run a full X server for it to work. I've tried it before and it does work, but including an X server is a whole can of worms I don't want to get into.

What I wish is that there were some kind of of "hybrid" build of tk for Cygwin, i.e. that uses POSIX APIs where necessary (e.g. to work with Cygwin's filesystem and process management), but uses native Windows APIs for GUI rendering. It seems I'm not the only one who's given thought to such a hybrid approach: https://wiki.tcl-lang.org/page/Building+Tcl+and+Tk+with+Cygwin But it's not trivial and will likely take a lot of effort.

Using an X server might still not be too bad if I can figure out an unobtrusive way to do it without adding too much overhead, but I'm not sure.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants