From: Heime <heimeborgia@protonmail.com>
To: Heime via Users list for the GNU Emacs text editor
<help-gnu-emacs@gnu.org>
Subject: Make new buffers into new frames
Date: Sun, 29 Sep 2024 07:40:10 +0000 [thread overview]
Message-ID: <UJaaebfjIypkig3DW5Y6r2EnBJG9PWdDugBVfvtvKCt0OKkzp3KA8YdeTp0qlUEaOb_YPNk-rQGE4g_4kpV3Vc8VgejgSztD1bFIRVAJ_T0=@protonmail.com> (raw)
I want to display the user named buffer when calling buffer-into-frame into
a new frame. The buffer will have a button, which when pressed another buffer
will be made to display my-message, which is some text.
I also want my-message to be displayed in a buffer and in the same new frame.
(defun display-message (my-message &optional bfrn)
"Display textual message into the buffer BFRN."
(let* ( (bfname (or bfrn "Info"))
(dbuffer (get-buffer-create (concat "𒆳 " bfname))) )
(with-current-buffer dbuffer
(erase-buffer)
(insert my-message)
(goto-char (point-min)))
(display-buffer dbuffer)))
;; -------------------------------------------------------
(defun buffer-into-frame (&optional bfrn)
"TODO"
(interactive
(list (let ( (rqmatch nil)
(cseq '("Default" "Torium")) )
(completing-read " Display Name: " cseq nil rqmatch "Selection Buffer"))))
(let* ( (bfname (or bfrn "S_election Buffer"))
(dbuffer (get-buffer-create (concat "𒆳 " bfname))) )
(with-current-buffer dbuffer
(erase-buffer)
;; Insert a button that shows the info when pressed
(insert-button " - "
'action (display-message my-message "Info Buffer")
'follow-link t)
(insert " Running Non-Interactive Commands"))) )
next reply other threads:[~2024-09-29 7:40 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-29 7:40 Heime [this message]
2024-09-29 12:44 ` Make new buffers into new frames Heime
2024-09-29 17:15 ` tomas
2024-09-29 19:16 ` Heime
2024-09-29 19:22 ` tomas
2024-09-29 19:31 ` Heime
2024-09-30 4:41 ` tomas
2024-09-30 6:40 ` Heime
2024-09-30 9:13 ` Stephen Berman
2024-09-30 9:15 ` tomas
2024-09-30 9:29 ` Rudolf Schlatte
2024-09-30 19:32 ` Heime
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='UJaaebfjIypkig3DW5Y6r2EnBJG9PWdDugBVfvtvKCt0OKkzp3KA8YdeTp0qlUEaOb_YPNk-rQGE4g_4kpV3Vc8VgejgSztD1bFIRVAJ_T0=@protonmail.com' \
--to=heimeborgia@protonmail.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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.