emacs-devel
[Top][All Lists]
Advanced

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

Re: How to get DISPLAY of emacsclient?


From: Gregory Heytings
Subject: Re: How to get DISPLAY of emacsclient?
Date: Sun, 27 Nov 2022 16:12:39 +0000


Currently I prefer to concentrate on the case of accessing X selection or getting DISPLAY without creation of visible frames.

Sorry, I don't understand what "getting DISPLAY without creation of visible frames" means.  Is the $DISPLAY environment variable not enough?

I do not see a way to get the value of the DISPLAY environment variable specific to the emacsclient process.


But where do you need that value, and what do you mean by "without creation of visible frames"? Not all emacsclient processes have a corresponding display, e.g. if you just do

emacsclient --eval '(+ 1 1)'

there is no display involved. If you create an emacsclient process with -c or -r, then in Elisp you can get the display on which the frame is displayed with (getenv "DISPLAY"), or (cdr (assq 'display (frame-parameters))).
reply via email to

[Prev in Thread] Current Thread [Next in Thread]