On Aug 1, 2006, at 8:07 AM, Bennett Helm wrote:
On Jul 28, 2006, at 5:46 PM, Jens Noeckel wrote:
Hi,
I've got some small suggestions for the LyX-Mac version of
lyxrc.dist in the LyX 1.4.2 Application bundle.
Prompted by a problem with imagemagick's convert utility (which
wasn't working out of the box for me), Bennett told me that the
definition of PATH had changed from what it was in 1.4.1.
(Actually, it's the mechanism by which default preference settings
(including PATH prefix) are defined that has changed.)
Looking at lyxrc.dist for LyX 1.4.2, I think one should set the
order of directories differently. People will currently be getting
their tex (tetex) distributions from different places - mainly
gwTeX, darwinports and fink. Imagemagick, on the other hand, could
come from even more different sources (could be installed into /
usr/local/bin by some third-party installer having nothing to do
with TeX). Ultimately, it will have to be up to the user to set
the PATH correctly in the Preferences, but to make it more
_likely_ to work out of the box I think the following sequence
would be better in PATH:
\path_prefix "/usr/local/teTeX/bin/i386-apple-darwin-current:/usr/
local/teTeX/bin/powerpc-apple-darwin-current:/sw/bin:/opt/local/
teTeX/bin:/opt/local/bin:/\
usr/local/bin:/usr/bin:/usr/X11R6/bin"
I agree. I've added /sw/sbin as well (just after /sw/bin), and will
submit a patch later.
Essentially this looks first in the directories that are most
likely to have the most up-to-date installations of a given tex-
related or imagemagick executable.
Also, in lyxrc.dist, I saw that the FORMATS section could be
improved. Here is what it says now:
#
# FORMATS SECTION ##########################
#
\format "fig" "fig" "FIG" "" "open /Applications/Utilities/X11.app
&& export DISPLAY=:0.0 && xfig" "open /Applications/Utilities/
X11.app && export DISPLAY=:0.0 && xf\
ig"
\format "rtf" "rtf" "Rich Text Format" "" "auto" "auto"
It may not be wise to specify the absolute path and application
name of X11.app for the "fig" format. Instead, it seems to be
better to simply replace this by
"open-x11 xfig"
This is a command that is present on OSX 10.3 and up, and I think
10.3 is the system requirement for lyx 1.4.2 anyway. So there's no
compatibility problem if one uses this command.
I didn't realize there was such a command. It works to open an
instance of xfig in X11, but I cannot get it to open a designated
file, which the previous version does. Does opening .fig files from
within LyX work for you?
Bennett
Bennett, you're right, the open-x11 script doesn't seem to accept a
file argument; I forgot that LyX needs to append that file name after
the opening commands. It does still lead to a simplification if you
write
open-x11 && xfig
but I'm now a bit more doubtful that it's worth trying to fix
something that's not really broken... E.g., it's probably good that
you're explicitly setting DISPLAY to be safe, while open-x11 doesn't
seem to be doing that.
Jens