Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
'browse' in [pdcontrol] is not only for 'browsing' as you can open any file. #862
'browse' in [pdcontrol] lets you open any file in your computer with the default software. If you give it a link, it only opens that as a file in your default browser software.
The name method and help file indicates it can only open links, but it's more powerful than that.
I'd suggest change that method name to 'open' and say you can open anything in the documentation with an example of opening a Pd patch.
alternatively, don't document it, and handle the current behavior as an implementation detail that can change anytime.
the actual implementation of the underlying tcl-proc is pretty clear that it is about:
the notion of opening a (HTML) file with some default application is not very consistent across platforms, and as a result the tcl-proc falls back to explicitely listed web-browsers, including
so adding documentation that you can open some random filetype via
Is there something in the tcl-proc which says that it only works with html files? If the documentation is changed to
open[ing] files from the menu using the OS-default software for that file type
then the function is defined in more general terms (which are true), and the responsability to have the adequate software falls on the user - e.g. if a user doesn't have a html viewer installed, 'browse' as it is now will be useless and no bug report will help, because the issue is not for Pd to solve.
as i said above:
with this i tried to say: not all platforms support "opening files with some default application" (regardless of whether an application capable of handling a given filetype).
because there is no way (for all supported platforms) to ask the OS to open a file, the tcl-proc eventually falls back to explicitely trying to open the file with a web-browser.
this i consider as "something in the tcl-proc which says that it only works with html files" - at least "in the end".