[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Launch the most relevant terminal emulator.



On 22/09/06 05:45:51, Charles Plessy wrote:
I will use x-terminal-emulator instead of xterm in my package. The
program invokes xterm the following way:

xterm -T \"%s alignment\" -n %s -sb -sl 2000 -e seaview_align.sh %s

I have a package that uses a terminal in a similar way. There is, unfortunately, no guarantee that a package providing x-terminal-emulator will accept -T, -n and -e the same was as any other package providing x-terminal-emulator. Even if it works now, it's not promised to work in the future.

Is there a sort of standard for terminal emulators which would allow
me
to safely replace xterm by x-terminal-emulator ?

I'm using a GKeyFile in the user home directory (created on-the-fly) to allow configuration of the relevant strings, although I only use -e and leave -T and -n up to the terminal emulator to decide. If a user wants to use an x-terminal-emulator that implements what other terminals do via -e using some other option name, that can be configured on a per-user basis and in the same place as the config option that specifies the name of the replacement application.

It depends how important this functionality is to your program. You may have to depend on:
xterm | x-terminal-emulator
so that the package always works in the default config.

If it's absolutely core to the app, you may need to consider using a system-wide conffile, debconf and a (shortened) list of supported x-terminal-emulator packages which you know support the options you use - at least in the current version.

In my package, the terminal is used in a secondary (preview) role and the main app simply shows an error and carries on if the config settings are wrong.

--

Neil Williams
=============
http://www.data-freedom.org/
http://www.nosoftwarepatents.com/
http://www.linux.codehelp.co.uk/

Attachment: pgpp1aFostpbB.pgp
Description: PGP signature


Reply to: