unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Herman <mahlamytsike@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: 'x-create-frame' succeeds, but 'x-open-connection' fails with same display argument
Date: Mon, 4 Dec 2023 02:11:12 +0200	[thread overview]
Message-ID: <20231204021112.07410c13@Elitebook> (raw)

Hi !

$ emacs --fg-daemon
$ emacsclient --eval "(terminal-list)"
(#<terminal 0 on initial_terminal>)
$ emacsclient --eval "(get-device-terminal nil)"
#<terminal 0 on initial_terminal>
$ emacsclient --eval "(x-display-list)"
nil
$ emacsclient --eval "(x-create-frame \`((display . ,(getenv \"DISPLAY\"))))"
#<frame *scratch* - GNU Emacs 0x55db73fd9c30>
$ emacsclient --eval "(terminal-list)"
(#<terminal 0 on initial_terminal> #<terminal 1 on :0.0>)
$ emacsclient --eval "(get-device-terminal nil)"
#<terminal 1 on :0.0>
$ emacsclient --eval "(x-display-list)"
(":0.0")
$ emacsclient --eval "(kill-emacs)"
$ emacs --fg-daemon
$ emacsclient --eval "(x-open-connection (getenv \"DISPLAY\"))"
nil
...
Debugger entered--Lisp error: (error "Display :0.0 does not exist")
  signal(error ("Display :0.0 does not exist"))
  error("Display %s does not exist" ":0.0")
  get-device-terminal(":0.0")
  frames-on-display-list(":0.0")
  font-setting-change-default-font(":0.0" nil)
  dynamic-setting-handle-config-changed-event((config-changed-event font-render ":0.0"))
  funcall-interactively(dynamic-setting-handle-config-changed-event (config-changed-event font-render ":0.0"))
  call-interactively(dynamic-setting-handle-config-changed-event nil [(config-changed-event font-render ":0.0")])
  command-execute(dynamic-setting-handle-config-changed-event nil [(config-changed-event font-render ":0.0")] t)

Emacs 29.1.

/---
30.2 Multiple Terminals topic in Elisp manual says, 'x-open-connection' can be tested for communication with a given X display. What I have missed ?

Thank you in advance for your help !



             reply	other threads:[~2023-12-04  0:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-04  0:11 Herman [this message]
2023-12-04  0:31 ` 'x-create-frame' succeeds, but 'x-open-connection' fails with same display argument Po Lu
2023-12-04  3:31   ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231204021112.07410c13@Elitebook \
    --to=mahlamytsike@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).