nomad-software / tkd

GUI toolkit for the D programming language based on Tcl/Tk
MIT License
117 stars 16 forks source link

Segmentaiton Fault after Choosing a File via OpenFileDialog #61

Closed ghost closed 4 years ago

ghost commented 4 years ago

OS: Windows 10 Arch: x64 tkd: 1.1.13 tcl86t.dll: Retrieved from nomad-software/tcltk/dist/x86_64/ tk86t.dll: Retrieved from nomad-software/tcltk/dist/x86_64/

The following code produces a segmentation fault iff one chooses a file in the dialog using its "Open" button. Closing the dialog by clicking the "Cancel" button or closing its window will not trigger anything untoward.

auto ofd = new OpenFileDialog("Open file")
        .show();

Below is the output from gdb.

Thread 1 received signal SIGSEGV, Segmentation fault.
0x0000000068f51ef8 in tk86t!TkGetCursorByName () from path/to/project/tk86t.dll

Hopefully the referenced function will give you an idea, because I haven't been able to do much with it. I've also tried using 8.6.>6 binaries, but then, while the OpenFileDialog doesn't produce issues, merely exiting the application will precipitate a segmentation fault. I have no idea if you can do anything, but I'm at a loss.

Kind regards, Dan

nomad-software commented 4 years ago

To be honest this library hasn't had a lot of testing on Windows 10 as I rarely use it and it was tested against Windows 7. That error looks like it's internal to Tk itself which I don't think there's a lot I can do about. Maybe try and find updated DLLs which I think by your comments you have tried. Other than that, compile the DLLs yourself? Also, make sure that if you are using updated DLLs that you are also using updated tcltk library files too. I don't really update this project now as I've moved away from using D. Good luck!

ghost commented 4 years ago

Thank you for responding.

Unfortunately, I have compiled several versions of 8.6.x but to no avail, and I have ensured that the library scripts matched each version. With that said, I'm thankful that you took the time to respond, especially since this problem is, as you've mentioned, seemingly one from the tk itself. Hopefully I'll have an epiphany that'll fix my issue.

Happy trails, Dan

P.S. I'm saddened to hear you no longer use D. Your libraries and their documentation are good, and any language ecosystem will be lucky to have them and you.