Subject: bug#41719: 28.0.50; [FR] emacsclient should provide '--name' option as emacs

From: Vladimir Lomov <[email-masked]>
Date: Fri, 05 Jun 2020 11:09:49 +0800

The 'emacs' allows to set the so-called 'instance' when run in X window
system using '--name' option. The same time the 'emacsclient' doesn't
have such option and if 'emacs' is run in daemon mode ('emacs
--daemon=...') it is impossible (?) to change the 'instance' of emacs
window (frame in Emacs terminology) created by 'emacsclient'.

I tried to use '-F' option of 'emacsclient' but I didn't get desire
result, WM_CLASS isn't changed, only WM_ICON_NAME. It is possible that I
do things wrong,

  $ emacsclient -s /run/user/1000/emacs-default -F '((name . "default") (title . "USER@HOST"))'

but this topic is covered by manual (Emacs, 21.11 "Frame Parameters" and
Emacs Lisp 29.4.3 "Window Frame Parameters") very unclear.

Even if it is possible to change the 'instance' of Emacs window created
by 'emacsclient' using the '-F' option it would be nice to have more
simple way to achieve this. On the other hand, if Emacs is run in daemon
mode it is the purpose of emacsclient to (allow to) set the 'instance'
and 'title' of created window.

In GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.20, cairo version 1.17.3)
 of 2020-06-04 built on node2-smoon7.bkoty.ru
Repository revision: 638ef457876c14b9d713e2fa991f5db3ad53c4f9
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12008000
System Description: Arch Linux

Recent messages:
Entering debugger...
Back to top level
Entering debugger...
Back to top level
Entering debugger...
Back to top level
When done with this frame, type C-x 5 0
kill-line: End of buffer
When done with this frame, type C-x 5 0 [2 times]
Making completion list...

Configured using:
 'configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
 --libexecdir=/usr/lib --with-x-toolkit=gtk3 --with-cairo --with-xft
 --with-modules --with-xml2 --enable-link-time-optimization
 --without-imagemagick --without-gconf 'CFLAGS=-march=x86-64
 -mtune=generic -O2 -pipe -fno-plt'
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now
 CPPFLAGS=-D_FORTIFY_SOURCE=2'

Configured features:
XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND GPM DBUS GSETTINGS GLIB NOTIFY
INOTIFY ACL GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11 XDBE XIM MODULES THREADS LIBSYSTEMD PDUMPER
LCMS2 GMP

Important settings:
  value of $LC_COLLATE: en_US.UTF-8
  value of $LANG: ru_RU.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  recentf-mode: t
  pdf-occur-global-minor-mode: t
  shell-dirtrack-mode: t
  global-undo-tree-mode: t
  show-paren-mode: t
  savehist-mode: t
  ido-everywhere: t
  display-time-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
/usr/share/emacs/site-lisp/org/ox hides /usr/share/emacs/28.0.50/lisp/org/ox
/usr/share/emacs/site-lisp/org/ox-texinfo hides /usr/share/emacs/28.0.50/lisp/org/ox-texinfo
/usr/share/emacs/site-lisp/org/ox-publish hides /usr/share/emacs/28.0.50/lisp/org/ox-publish
/usr/share/emacs/site-lisp/org/ox-org hides /usr/share/emacs/28.0.50/lisp/org/ox-org
/usr/share/emacs/site-lisp/org/ox-odt hides /usr/share/emacs/28.0.50/lisp/org/ox-odt
/usr/share/emacs/site-lisp/org/ox-md hides /usr/share/emacs/28.0.50/lisp/org/ox-md
/usr/share/emacs/site-lisp/org/ox-man hides /usr/share/emacs/28.0.50/lisp/org/ox-man
/usr/share/emacs/site-lisp/org/ox-latex hides /usr/share/emacs/28.0.50/lisp/org/ox-latex
/usr/share/emacs/site-lisp/org/ox-icalendar hides /usr/share/emacs/28.0.50/lisp/org/ox-icalendar
/usr/share/emacs/site-lisp/org/ox-html hides /usr/share/emacs/28.0.50/lisp/org/ox-html
/usr/share/emacs/site-lisp/org/ox-beamer hides /usr/share/emacs/28.0.50/lisp/org/ox-beamer
/usr/share/emacs/site-lisp/org/ox-ascii hides /usr/share/emacs/28.0.50/lisp/org/ox-ascii
/usr/share/emacs/site-lisp/org/org hides /usr/share/emacs/28.0.50/lisp/org/org
/usr/share/emacs/site-lisp/org/org-version hides /usr/share/emacs/28.0.50/lisp/org/org-version
/usr/share/emacs/site-lisp/org/org-timer hides /usr/share/emacs/28.0.50/lisp/org/org-timer
/usr/share/emacs/site-lisp/org/org-tempo hides /usr/share/emacs/28.0.50/lisp/org/org-tempo
/usr/share/emacs/site-lisp/org/org-table hides /usr/share/emacs/28.0.50/lisp/org/org-table
/usr/share/emacs/site-lisp/org/org-src hides /usr/share/emacs/28.0.50/lisp/org/org-src
/usr/share/emacs/site-lisp/org/org-protocol hides /usr/share/emacs/28.0.50/lisp/org/org-protocol
/usr/share/emacs/site-lisp/org/org-plot hides /usr/share/emacs/28.0.50/lisp/org/org-plot
/usr/share/emacs/site-lisp/org/org-pcomplete hides /usr/share/emacs/28.0.50/lisp/org/org-pcomplete
/usr/share/emacs/site-lisp/org/org-num hides /usr/share/emacs/28.0.50/lisp/org/org-num
/usr/share/emacs/site-lisp/org/org-mouse hides /usr/share/emacs/28.0.50/lisp/org/org-mouse
/usr/share/emacs/site-lisp/org/org-mobile hides /usr/share/emacs/28.0.50/lisp/org/org-mobile
/usr/share/emacs/site-lisp/org/org-macs hides /usr/share/emacs/28.0.50/lisp/org/org-macs
/usr/share/emacs/site-lisp/org/org-macro hides /usr/share/emacs/28.0.50/lisp/org/org-macro
/usr/share/emacs/site-lisp/org/org-loaddefs hides /usr/share/emacs/28.0.50/lisp/org/org-loaddefs
/usr/share/emacs/site-lisp/org/org-list hides /usr/share/emacs/28.0.50/lisp/org/org-list
/usr/share/emacs/site-lisp/org/org-lint hides /usr/share/emacs/28.0.50/lisp/org/org-lint
/usr/share/emacs/site-lisp/org/org-keys hides /usr/share/emacs/28.0.50/lisp/org/org-keys
/usr/share/emacs/site-lisp/org/org-install hides /usr/share/emacs/28.0.50/lisp/org/org-install
/usr/share/emacs/site-lisp/org/org-inlinetask hides /usr/share/emacs/28.0.50/lisp/org/org-inlinetask
/usr/share/emacs/site-lisp/org/org-indent hides /usr/share/emacs/28.0.50/lisp/org/org-indent
/usr/share/emacs/site-lisp/org/org-id hides /usr/share/emacs/28.0.50/lisp/org/org-id
/usr/share/emacs/site-lisp/org/org-habit hides /usr/share/emacs/28.0.50/lisp/org/org-habit
/usr/share/emacs/site-lisp/org/org-goto hides /usr/share/emacs/28.0.50/lisp/org/org-goto
/usr/share/emacs/site-lisp/org/org-footnote hides /usr/share/emacs/28.0.50/lisp/org/org-footnote
/usr/share/emacs/site-lisp/org/org-feed hides /usr/share/emacs/28.0.50/lisp/org/org-feed
/usr/share/emacs/site-lisp/org/org-faces hides /usr/share/emacs/28.0.50/lisp/org/org-faces
/usr/share/emacs/site-lisp/org/org-entities hides /usr/share/emacs/28.0.50/lisp/org/org-entities
/usr/share/emacs/site-lisp/org/org-element hides /usr/share/emacs/28.0.50/lisp/org/org-element
/usr/share/emacs/site-lisp/org/org-duration hides /usr/share/emacs/28.0.50/lisp/org/org-duration
/usr/share/emacs/site-lisp/org/org-datetree hides /usr/share/emacs/28.0.50/lisp/org/org-datetree
/usr/share/emacs/site-lisp/org/org-ctags hides /usr/share/emacs/28.0.50/lisp/org/org-ctags
/usr/share/emacs/site-lisp/org/org-crypt hides /usr/share/emacs/28.0.50/lisp/org/org-crypt
/usr/share/emacs/site-lisp/org/org-compat hides /usr/share/emacs/28.0.50/lisp/org/org-compat
/usr/share/emacs/site-lisp/org/org-colview hides /usr/share/emacs/28.0.50/lisp/org/org-colview
/usr/share/emacs/site-lisp/org/org-clock hides /usr/share/emacs/28.0.50/lisp/org/org-clock
/usr/share/emacs/site-lisp/org/org-capture hides /usr/share/emacs/28.0.50/lisp/org/org-capture
/usr/share/emacs/site-lisp/org/org-attach hides /usr/share/emacs/28.0.50/lisp/org/org-attach
/usr/share/emacs/site-lisp/org/org-attach-git hides /usr/share/emacs/28.0.50/lisp/org/org-attach-git
/usr/share/emacs/site-lisp/org/org-archive hides /usr/share/emacs/28.0.50/lisp/org/org-archive
/usr/share/emacs/site-lisp/org/org-agenda hides /usr/share/emacs/28.0.50/lisp/org/org-agenda
/usr/share/emacs/site-lisp/org/ol hides /usr/share/emacs/28.0.50/lisp/org/ol
/usr/share/emacs/site-lisp/org/ol-w3m hides /usr/share/emacs/28.0.50/lisp/org/ol-w3m
/usr/share/emacs/site-lisp/org/ol-rmail hides /usr/share/emacs/28.0.50/lisp/org/ol-rmail
/usr/share/emacs/site-lisp/org/ol-mhe hides /usr/share/emacs/28.0.50/lisp/org/ol-mhe
/usr/share/emacs/site-lisp/org/ol-irc hides /usr/share/emacs/28.0.50/lisp/org/ol-irc
/usr/share/emacs/site-lisp/org/ol-info hides /usr/share/emacs/28.0.50/lisp/org/ol-info
/usr/share/emacs/site-lisp/org/ol-gnus hides /usr/share/emacs/28.0.50/lisp/org/ol-gnus
/usr/share/emacs/site-lisp/org/ol-eww hides /usr/share/emacs/28.0.50/lisp/org/ol-eww
/usr/share/emacs/site-lisp/org/ol-eshell hides /usr/share/emacs/28.0.50/lisp/org/ol-eshell
/usr/share/emacs/site-lisp/org/ol-docview hides /usr/share/emacs/28.0.50/lisp/org/ol-docview
/usr/share/emacs/site-lisp/org/ol-bibtex hides /usr/share/emacs/28.0.50/lisp/org/ol-bibtex
/usr/share/emacs/site-lisp/org/ol-bbdb hides /usr/share/emacs/28.0.50/lisp/org/ol-bbdb
/usr/share/emacs/site-lisp/org/ob hides /usr/share/emacs/28.0.50/lisp/org/ob
/usr/share/emacs/site-lisp/org/ob-vala hides /usr/share/emacs/28.0.50/lisp/org/ob-vala
/usr/share/emacs/site-lisp/org/ob-tangle hides /usr/share/emacs/28.0.50/lisp/org/ob-tangle
/usr/share/emacs/site-lisp/org/ob-table hides /usr/share/emacs/28.0.50/lisp/org/ob-table
/usr/share/emacs/site-lisp/org/ob-stan hides /usr/share/emacs/28.0.50/lisp/org/ob-stan
/usr/share/emacs/site-lisp/org/ob-sqlite hides /usr/share/emacs/28.0.50/lisp/org/ob-sqlite
/usr/share/emacs/site-lisp/org/ob-sql hides /usr/share/emacs/28.0.50/lisp/org/ob-sql
/usr/share/emacs/site-lisp/org/ob-shen hides /usr/share/emacs/28.0.50/lisp/org/ob-shen
/usr/share/emacs/site-lisp/org/ob-shell hides /usr/share/emacs/28.0.50/lisp/org/ob-shell
/usr/share/emacs/site-lisp/org/ob-sed hides /usr/share/emacs/28.0.50/lisp/org/ob-sed
/usr/share/emacs/site-lisp/org/ob-screen hides /usr/share/emacs/28.0.50/lisp/org/ob-screen
/usr/share/emacs/site-lisp/org/ob-scheme hides /usr/share/emacs/28.0.50/lisp/org/ob-scheme
/usr/share/emacs/site-lisp/org/ob-sass hides /usr/share/emacs/28.0.50/lisp/org/ob-sass
/usr/share/emacs/site-lisp/org/ob-ruby hides /usr/share/emacs/28.0.50/lisp/org/ob-ruby
/usr/share/emacs/site-lisp/org/ob-ref hides /usr/share/emacs/28.0.50/lisp/org/ob-ref
/usr/share/emacs/site-lisp/org/ob-python hides /usr/share/emacs/28.0.50/lisp/org/ob-python
/usr/share/emacs/site-lisp/org/ob-processing hides /usr/share/emacs/28.0.50/lisp/org/ob-processing
/usr/share/emacs/site-lisp/org/ob-plantuml hides /usr/share/emacs/28.0.50/lisp/org/ob-plantuml
/usr/share/emacs/site-lisp/org/ob-picolisp hides /usr/share/emacs/28.0.50/lisp/org/ob-picolisp
/usr/share/emacs/site-lisp/org/ob-perl hides /usr/share/emacs/28.0.50/lisp/org/ob-perl
/usr/share/emacs/site-lisp/org/ob-org hides /usr/share/emacs/28.0.50/lisp/org/ob-org
/usr/share/emacs/site-lisp/org/ob-octave hides /usr/share/emacs/28.0.50/lisp/org/ob-octave
/usr/share/emacs/site-lisp/org/ob-ocaml hides /usr/share/emacs/28.0.50/lisp/org/ob-ocaml
/usr/share/emacs/site-lisp/org/ob-mscgen hides /usr/share/emacs/28.0.50/lisp/org/ob-mscgen
/usr/share/emacs/site-lisp/org/ob-maxima hides /usr/share/emacs/28.0.50/lisp/org/ob-maxima
/usr/share/emacs/site-lisp/org/ob-matlab hides /usr/share/emacs/28.0.50/lisp/org/ob-matlab
/usr/share/emacs/site-lisp/org/ob-makefile hides /usr/share/emacs/28.0.50/lisp/org/ob-makefile
/usr/share/emacs/site-lisp/org/ob-lua hides /usr/share/emacs/28.0.50/lisp/org/ob-lua
/usr/share/emacs/site-lisp/org/ob-lob hides /usr/share/emacs/28.0.50/lisp/org/ob-lob
/usr/share/emacs/site-lisp/org/ob-lisp hides /usr/share/emacs/28.0.50/lisp/org/ob-lisp
/usr/share/emacs/site-lisp/org/ob-lilypond hides /usr/share/emacs/28.0.50/lisp/org/ob-lilypond
/usr/share/emacs/site-lisp/org/ob-ledger hides /usr/share/emacs/28.0.50/lisp/org/ob-ledger
/usr/share/emacs/site-lisp/org/ob-latex hides /usr/share/emacs/28.0.50/lisp/org/ob-latex
/usr/share/emacs/site-lisp/org/ob-js hides /usr/share/emacs/28.0.50/lisp/org/ob-js
/usr/share/emacs/site-lisp/org/ob-java hides /usr/share/emacs/28.0.50/lisp/org/ob-java
/usr/share/emacs/site-lisp/org/ob-io hides /usr/share/emacs/28.0.50/lisp/org/ob-io
/usr/share/emacs/site-lisp/org/ob-hledger hides /usr/share/emacs/28.0.50/lisp/org/ob-hledger
/usr/share/emacs/site-lisp/org/ob-haskell hides /usr/share/emacs/28.0.50/lisp/org/ob-haskell
/usr/share/emacs/site-lisp/org/ob-groovy hides /usr/share/emacs/28.0.50/lisp/org/ob-groovy
/usr/share/emacs/site-lisp/org/ob-gnuplot hides /usr/share/emacs/28.0.50/lisp/org/ob-gnuplot
/usr/share/emacs/site-lisp/org/ob-fortran hides /usr/share/emacs/28.0.50/lisp/org/ob-fortran
/usr/share/emacs/site-lisp/org/ob-forth hides /usr/share/emacs/28.0.50/lisp/org/ob-forth
/usr/share/emacs/site-lisp/org/ob-exp hides /usr/share/emacs/28.0.50/lisp/org/ob-exp
/usr/share/emacs/site-lisp/org/ob-eval hides /usr/share/emacs/28.0.50/lisp/org/ob-eval
/usr/share/emacs/site-lisp/org/ob-eshell hides /usr/share/emacs/28.0.50/lisp/org/ob-eshell
/usr/share/emacs/site-lisp/org/ob-emacs-lisp hides /usr/share/emacs/28.0.50/lisp/org/ob-emacs-lisp
/usr/share/emacs/site-lisp/org/ob-ebnf hides /usr/share/emacs/28.0.50/lisp/org/ob-ebnf
/usr/share/emacs/site-lisp/org/ob-dot hides /usr/share/emacs/28.0.50/lisp/org/ob-dot
/usr/share/emacs/site-lisp/org/ob-ditaa hides /usr/share/emacs/28.0.50/lisp/org/ob-ditaa
/usr/share/emacs/site-lisp/org/ob-css hides /usr/share/emacs/28.0.50/lisp/org/ob-css
/usr/share/emacs/site-lisp/org/ob-core hides /usr/share/emacs/28.0.50/lisp/org/ob-core
/usr/share/emacs/site-lisp/org/ob-coq hides /usr/share/emacs/28.0.50/lisp/org/ob-coq
/usr/share/emacs/site-lisp/org/ob-comint hides /usr/share/emacs/28.0.50/lisp/org/ob-comint
/usr/share/emacs/site-lisp/org/ob-clojure hides /usr/share/emacs/28.0.50/lisp/org/ob-clojure
/usr/share/emacs/site-lisp/org/ob-calc hides /usr/share/emacs/28.0.50/lisp/org/ob-calc
/usr/share/emacs/site-lisp/org/ob-awk hides /usr/share/emacs/28.0.50/lisp/org/ob-awk
/usr/share/emacs/site-lisp/org/ob-asymptote hides /usr/share/emacs/28.0.50/lisp/org/ob-asymptote
/usr/share/emacs/site-lisp/org/ob-abc hides /usr/share/emacs/28.0.50/lisp/org/ob-abc
/usr/share/emacs/site-lisp/org/ob-R hides /usr/share/emacs/28.0.50/lisp/org/ob-R
/usr/share/emacs/site-lisp/org/ob-J hides /usr/share/emacs/28.0.50/lisp/org/ob-J
/usr/share/emacs/site-lisp/org/ob-C hides /usr/share/emacs/28.0.50/lisp/org/ob-C

Features:
(shadow sort spook cookie1 mail-extr emacsbug message rmc rfc822 mml
mml-sec epa epg epg-config mm-decode mm-bodies mm-encode mail-parse
rfc2231 mailabbrev gmm-utils mailheader sendmail recentf tree-widget
help-fns radix-tree cl-print debug backtrace mhtml-mode css-mode eww
mm-url url-queue shr puny svg xml color js cc-mode cc-fonts cc-guess
cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs sgml-mode
dom htmlize ox-org ox-odt rng-loc rng-uri rng-parse rng-match rng-dt
rng-util rng-pttrn nxml-parse nxml-ns nxml-enc xmltok nxml-util ox-latex
ox-html table ox-ascii ox-publish ox sh-script smie executable rx vc-git
diff-mode cl-extra org-protocol ol-info org-id org-habit ol-docview
doc-view ol-bibtex bibtex ol-bbdb ffap thingatpt server calfw-ical url
url-proxy url-privacy url-expand url-methods url-history url-cookie
url-domsuf url-util mailcap icalendar diary-lib diary-loaddefs calfw-org
org-capture org-element avl-tree generator org-agenda org-refile calfw
holidays hol-loaddefs cl auto-loads tex-site pdf-sync pdf-outline
pdf-occur ibuf-ext ibuffer ibuffer-loaddefs pdf-links pdf-isearch
let-alist pdf-history pdf-annot tablist tablist-filter
semantic/wisent/comp semantic/wisent semantic/wisent/wisent
semantic/util-modes semantic/util semantic semantic/tag semantic/lex
semantic/fw mode-local cedet org org-macro org-footnote org-pcomplete
org-list org-faces org-entities noutline outline org-version ob-shell
shell pcomplete ob-R ob-perl ob-asymptote ob-gnuplot ob ob-tangle
org-src ob-ref ob-lob ob-table ob-exp ob-comint ob-emacs-lisp ob-core
ob-eval org-table ol org-keys org-compat org-macs org-loaddefs find-func
cal-menu calendar cal-loaddefs pdf-misc imenu pdf-tools package
browse-url url-handlers url-parse auth-source cl-seq eieio eieio-core
cl-macs eieio-loaddefs json map url-vars compile comint ansi-color
cus-edit pdf-view password-cache jka-compr pdf-cache pdf-info tq
pdf-util dired+ image-dired image-mode exif format-spec image-file
dired-aux bookmark+ bookmark+-key easy-mmode derived dired-x dired
dired-loaddefs bookmark+-1 bookmark+-bmu bookmark+-lit bookmark pp
advice undo-tree diff ace-window avy ring company edmacro kmacro pcase
quail help-mode easymenu paren savehist ido gnus nnheader gnus-util
rmail rmail-loaddefs rfc2047 rfc2045 ietf-drums text-property-search
time-date subr-x seq byte-opt gv bytecomp byte-compile cconv mail-utils
mm-util mail-prsvr wid-edit cl-loaddefs cl-lib time cus-start cus-load
cyril-util tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar
dnd fontset image regexp-opt fringe tabulated-list replace newcomment
text-mode elisp-mode lisp-mode prog-mode register page tab-bar menu-bar
rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core term/tty-colors frame minibuffer cl-generic
cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice loaddefs button faces cus-face macroexp files
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote threads dbusbind
inotify lcms2 dynamic-setting system-font-setting font-render-setting
cairo move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)

Memory information:
((conses 16 339893 26002)
 (symbols 48 35688 2)
 (strings 32 120824 5563)
 (string-bytes 1 3997014)
 (vectors 16 59972)
 (vector-slots 8 1396971 132706)
 (floats 8 306 136)
 (intervals 56 669 185)
 (buffers 992 18))

--
WBR, Vladimir Lomov

Content:  80% POLYESTER, 20% DACRONi ... The waitress's UNIFORM sheds
TARTAR SAUCE like an 8" by 10" GLOSSY ...

Hamas H.N.P. National laboratory Cartel sweep Homeland security Cohiba
Hugo Chavez SGDN Colombia market Magnitude Rapid Reaction SGI warfare

--