Lugaru's Epsilon
Programmer's
Editor

Context:
Epsilon User's Manual and Reference
   Commands by Topic
      Starting and Stopping Epsilon
         . . .
         Sending Files to a Prior Instance
         MS-Windows Integration Features
            Running Epsilon via a Shortcut
            The Open With Epsilon Shell Extension

Previous   Up    Next
MS-Windows Integration Features  Commands by Topic   The Open With Epsilon Shell Extension


Epsilon User's Manual and Reference > Commands by Topic > Starting and Stopping Epsilon > MS-Windows Integration Features >

Running Epsilon via a Shortcut

Epsilon comes with a program, sendeps.exe, that's installed in the directory containing Epsilon's main executable. It provides some flexibility when you create a desktop icon for Epsilon, or use the Send To feature (both of which involve creating a Windows shortcut).

If you create a desktop shortcut for Epsilon, or use the Send To feature in Windows, have it refer to this sendeps.exe program instead of Epsilon's main executable. Sendeps will start Epsilon if necessary, or locate an existing copy of Epsilon, and load the files named on its command line.

This is useful because Windows ignores a shortcut's flags (command line settings) when you drop a document on a shortcut, or when you use the Send To feature. (If it used the flags, you could simply create a shortcut to Epsilon's main executable and pass its -add flag. Since it doesn't, sending a file requires a separate program.) Also, Windows sends long file names without quoting them in these cases, which would cause problems if sent directly to Epsilon.

Sendeps may be configured through entries in a lugeps.ini file located in your Windows directory. It will use a lugeps.ini in the directory containing sendeps.exe in preference to one in the Windows directory. The section name it uses is the same as the base name of its executable (so making copies of the executable under different names lets you have multiple Send To entries that behave differently, for instance).

These are its default settings:

[SendEps]
server=Epsilon
topic=Open
ddeflags=
executable=epsilon.exe
runflags=-add -w1
nofilestartnew=1
nofileflags=-w1
usedde=0
senddir=1

Here's how Sendeps uses the above settings. It first looks for an Epsilon server named server using Epsilon's -add protocol. If found, it sends the server a command line consisting of the ddeflags setting, followed by the file name passed on its command line (inside double quotes). If there's no such server running, Sendeps executes a command line built by concatenating the executable name, the runflags, and the quoted file name. If the executable name is a relative pathname, Epsilon searches for it first in the directory containing sendeps.exe, then along your PATH environment variable.

Normally relative file names on the sendeps command line are sent to Epsilon as-is, along with a -dir flag indicating Sendeps's current directory. Set senddir to zero and Sendeps will convert each file name to absolute form itself and omit -dir.

You can tell Sendeps to use DDE instead of its usual -add protocol by setting usedde to 1. In that case it will use the specified topic name.

When you invoke Sendeps without specifying a file name on its command line, its behavior is controlled by the nofilestartnew setting. If nonzero it starts a new instance of Epsilon. If zero, it brings an existing instance to the top, if there is one, and starts a new instance otherwise. In either case, if it needs to start a new instance it uses nofileflags on the command line.



Previous   Up    Next
MS-Windows Integration Features  Commands by Topic   The Open With Epsilon Shell Extension


Lugaru Copyright (C) 1984, 2020 by Lugaru Software Ltd. All rights reserved.