mhulden / foma

Automatically exported from code.google.com/p/foma
117 stars 90 forks source link

Do not rely on Graphviz application for MacOS #81

Open simon-clematide opened 5 years ago

simon-clematide commented 5 years ago

The OS X application Graphviz is not supported for MacOS Mojave (https://www.graphviz.org/download/) and the command view net does not work anymore on recent systems. It is a better longterm strategy to rely on standard Linux-style pipeline, using dot (easily installable via Homebrew) and the standard MacOS PNG viewer that the user has set (called via command /usr/bin/open).

mhulden commented 5 years ago

Maybe the original native Graphviz call could be left as an compiler option so the user could choose which to compile?

simon-clematide commented 5 years ago

I don't see any benefits from Graphviz. The proposed method only requires the user to install dot via brew. If they are capable of installing foma they for sure will be able to handle that. The images immediately open up in Preview in the default settings.

dowobeha commented 4 years ago

Make sure not to assume Homebrew. There are other package managers (I use fink, for example).

reynoldsnlp commented 3 years ago

Are there any major Mac package managers that don't have graphviz? Homebrew, MacPorts, and Fink all do....

simon-clematide commented 3 years ago

Are there any major Mac package managers that don't have graphviz? Homebrew, MacPorts, and Fink all do....

I was talking about the macOS gui application GraphViz. According to my knowledge , it is not part of homebrew. The package graphviz and the dot command is available everywhere, for sure. But foma tries to launch the application graphviz via open -a GraphViz

umutozge commented 8 months ago

Hi, is there a way to make foma use the command-line dot instead of attempting open -a Graphviz

umutozge commented 8 months ago

Hi again, I think the way to go is doing print dot > file.dot in foma and proceeding there on.. thanks anyway.

simon-clematide commented 8 months ago

I still think that it is a two step procedure: (1) Generating an image (PNG) from the dot file. (2) Launching an image viewer for the image file. My patch suggested this more linux-like behaviour on MacOS.

mhulden commented 8 months ago

Maybe the default behavior on OSXcould be the dot > viewer call, but we could also introduce an alternate way to call the native GraphViz on OSX - it's really nice for those who have it?

simon-clematide commented 8 months ago

Ok, just to be sure: the only way to get GraphViz is by MacPorts. Correct? https://ports.macports.org/port/graphviz-gui/details/

umutozge commented 8 months ago

Ok, just to be sure: the only way to get GraphViz is by MacPorts. Correct? https://ports.macports.org/port/graphviz-gui/details/

Yes, the only way to get Graphviz.app; brew can only get command-line tools like dot, and others.