unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Defuns in comint
@ 2024-10-03 23:04 Daniel Colascione
  2024-10-03 23:32 ` Jim Porter
  2024-10-04  4:40 ` Yuri Khan
  0 siblings, 2 replies; 5+ messages in thread
From: Daniel Colascione @ 2024-10-03 23:04 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 437 bytes --]

How would people feel about defining defuns in comint mode as subprocesses outputs? This way, the same navigation keys people already have become more useful in comint mode without breaking anything, because defun navigation in comint is useless today.

If not defuns, then paragraphs? Sentences? I feel like there should be *some* way of using existing sets of movement and marking commands to talk about outputs, and probably inputs.

[-- Attachment #2: Type: text/html, Size: 504 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Defuns in comint
  2024-10-03 23:04 Defuns in comint Daniel Colascione
@ 2024-10-03 23:32 ` Jim Porter
  2024-10-04  0:03   ` Daniel Colascione
  2024-10-04  4:40 ` Yuri Khan
  1 sibling, 1 reply; 5+ messages in thread
From: Jim Porter @ 2024-10-03 23:32 UTC (permalink / raw)
  To: Daniel Colascione, emacs-devel

On 10/3/2024 4:04 PM, Daniel Colascione wrote:
> How would people feel about defining defuns in comint mode as 
> subprocesses outputs? This way, the same navigation keys people already 
> have become more useful in comint mode without breaking anything, 
> because defun navigation in comint is useless today.
> 
> If not defuns, then paragraphs? Sentences? I feel like there should be 
> *some* way of using existing sets of movement and marking commands to 
> talk about outputs, and probably inputs.

You might be interested in lisp/eshell/em-prompt.el, which remaps 
forward/backward-paragraph so that they stop at each empty line *or* prompt.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Defuns in comint
  2024-10-03 23:32 ` Jim Porter
@ 2024-10-04  0:03   ` Daniel Colascione
  0 siblings, 0 replies; 5+ messages in thread
From: Daniel Colascione @ 2024-10-04  0:03 UTC (permalink / raw)
  To: Jim Porter, emacs-devel



On October 3, 2024 4:32:14 PM PDT, Jim Porter <jporterbugs@gmail.com> wrote:
>On 10/3/2024 4:04 PM, Daniel Colascione wrote:
>> How would people feel about defining defuns in comint mode as subprocesses outputs? This way, the same navigation keys people already have become more useful in comint mode without breaking anything, because defun navigation in comint is useless today.
>> 
>> If not defuns, then paragraphs? Sentences? I feel like there should be *some* way of using existing sets of movement and marking commands to talk about outputs, and probably inputs.
>
>You might be interested in lisp/eshell/em-prompt.el, which remaps forward/backward-paragraph so that they stop at each empty line *or* prompt.

Sure, but 1) I don't want to stop at paragraph boundaries, and 2) remapping movement commands is less powerful and consistent than changing the definitions of those movements, which is why we have beginning-of-X-function variables.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Defuns in comint
  2024-10-03 23:04 Defuns in comint Daniel Colascione
  2024-10-03 23:32 ` Jim Porter
@ 2024-10-04  4:40 ` Yuri Khan
  2024-10-04  4:58   ` Daniel Colascione
  1 sibling, 1 reply; 5+ messages in thread
From: Yuri Khan @ 2024-10-04  4:40 UTC (permalink / raw)
  To: Daniel Colascione; +Cc: emacs-devel

On Fri, 4 Oct 2024 at 06:05, Daniel Colascione <dancol@dancol.org> wrote:
>
> How would people feel about defining defuns in comint mode as subprocesses outputs? This way, the same navigation keys people already have become more useful in comint mode without breaking anything, because defun navigation in comint is useless today.
>
> If not defuns, then paragraphs? Sentences? I feel like there should be *some* way of using existing sets of movement and marking commands to talk about outputs, and probably inputs.

Maybe pages? (Might even work out of the box if the prompt contains ^L)



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Defuns in comint
  2024-10-04  4:40 ` Yuri Khan
@ 2024-10-04  4:58   ` Daniel Colascione
  0 siblings, 0 replies; 5+ messages in thread
From: Daniel Colascione @ 2024-10-04  4:58 UTC (permalink / raw)
  To: Yuri Khan; +Cc: emacs-devel



On October 3, 2024 9:40:34 PM PDT, Yuri Khan <yuri.v.khan@gmail.com> wrote:
>On Fri, 4 Oct 2024 at 06:05, Daniel Colascione <dancol@dancol.org> wrote:
>>
>> How would people feel about defining defuns in comint mode as subprocesses outputs? This way, the same navigation keys people already have become more useful in comint mode without breaking anything, because defun navigation in comint is useless today.
>>
>> If not defuns, then paragraphs? Sentences? I feel like there should be *some* way of using existing sets of movement and marking commands to talk about outputs, and probably inputs.
>
>Maybe pages? (Might even work out of the box if the prompt contains ^L)

We'd need to add forward and backward page function hooks. Right now, page boundaries are still regexp-only, as many things were in days of yore.




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-10-04  4:58 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-03 23:04 Defuns in comint Daniel Colascione
2024-10-03 23:32 ` Jim Porter
2024-10-04  0:03   ` Daniel Colascione
2024-10-04  4:40 ` Yuri Khan
2024-10-04  4:58   ` Daniel Colascione

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).