PROPOSAL:
Inside the CTRL Click menu of the Browse Files Pane, add a ”Reveal in
Finder” command and make that command call the following CLI command:
open -R “%F”
“Reveal in Finder” what such commands are typically called in MacOS.
And, to help users understand how it works, it might also be a good idea
to use the long version of the command:
open --reveal “%F”
PROBLEM:
On the Mac, there is very little integreration between XXE and the
MacOS Finder (AKA the file browser). For example:
1. It is not possible to tell the system to open a file in XXE (e.g.
by double clicking the file in Finder or similar commands).
2. And, opposite, XXE does not have a way to let the user
show/select/display a selected or active file in Finder.
I know no solution to the first problem - from Finder to XXE. But, the
“open -R” command seems to be a rather simple solution to the second
problem - displaying a file in the Finder.
SOLUTION:
The solution is a MacOS solution only. However, it ought to be pretty
low hanging fruit, as it makes use of the CLI open command (a command
that we discussed earlier this month):
In MacOS Terminal.app, if we run
open --help
we learn that about the “reveal” option:
-R, --reveal Selects in the Finder instead of opening.
Currently, the 'Default viewer’ command is - by default (sic!) - the
following command:
open "%U"
But if we add the --reveal option, like so:
open --reveal "%U” /* Or: open --reveal “%F” */
Then, selecting the Preview commmand (of XXE’s XHTML menu - for
instance) will display the currently active file in the Finder instead
of sending the file to the default preview program (for XHTML files,
typically to the default Web browser).
The above hack, by way of modifying the command of the Preview menu,
is already possible. However, to make use of the Preview menu option for
this, *is* a hack. Also, it requires that one opens the file in XXE,
before one can run the command. A better solution, would be to add a
submenu called ‘Reveal in Finder’ to the local CTRL Click menu of the
'Browse Files Pane'. Then one can display any file in the Finder,
including files that XXE itself is unable to display.
Leif Halvard Silli
--
XMLmind XML Editor Support List
xmleditor-support@xmlmind.com
http://www.xmlmind.com/mailman/listinfo/xmleditor-support