1

Topic: File dialog box with OSx

In fortran for the Mac, when I want to specify an input file,I have to type in the name, which sometimes can be rather long, leading to typos and such. Is there a way for Simply Fortran to open the standard file selection dialog box for selecting the file? Remember: Mac.

2

Re: File dialog box with OSx

You'll probably be stuck writing a generic, blocking file dialog box interface in Objective-C, then writing a C wrapper around the Objective-C, and finally writing a Fortran interface to the C wrapper.  There will be some issues, though.  Notably, modern macOS APIs mostly are non-blocking if I'm not mistaken.  I'm also not sure if you can even open a dialog box without first creating a true macOS NSApplication.  Windows doesn't care if you open a dialog box without a true application running, but I think macOS might care.

Jeff Armstrong
Approximatrix, LLC