all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* how to collapse a horizontal into vertail
@ 2003-01-11 17:11 Zimmen Gnauh
  2003-01-11 19:27 ` Tim Haynes
  0 siblings, 1 reply; 4+ messages in thread
From: Zimmen Gnauh @ 2003-01-11 17:11 UTC (permalink / raw)



   shell command tr can be used to collapse a sentence "this is a test" into 
this 
is
a 
test
. How can this be done in emacs?

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

* Re: how to collapse a horizontal into vertail
  2003-01-11 17:11 how to collapse a horizontal into vertail Zimmen Gnauh
@ 2003-01-11 19:27 ` Tim Haynes
  2003-01-11 21:37   ` Zimmen Gnauh
  0 siblings, 1 reply; 4+ messages in thread
From: Tim Haynes @ 2003-01-11 19:27 UTC (permalink / raw)


Zimmen Gnauh <yah00204052@yahoo.com> writes:

>    shell command tr can be used to collapse a sentence "this is a test"
> into

> this 
> is
> a 
> test
> . How can this be done in emacs?

(replace-regexp " " "^J")

or M-x replace-regexp, similarly. Use C-q to quote the C-j.

Works t'other way round, too :)

~Tim
-- 
All I see, All I know                       |piglet@stirfried.vegetable.org.uk
Is touching the sacred earth                |http://spodzone.org.uk/
And warming the hallowed ground             |

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

* Re: how to collapse a horizontal into vertail
  2003-01-11 19:27 ` Tim Haynes
@ 2003-01-11 21:37   ` Zimmen Gnauh
  2003-01-12  0:03     ` Tim Haynes
  0 siblings, 1 reply; 4+ messages in thread
From: Zimmen Gnauh @ 2003-01-11 21:37 UTC (permalink / raw)


Tim Haynes <usenet@stirfried.vegetable.org.uk> writes:

> Zimmen Gnauh <yah00204052@yahoo.com> writes:
> 
> >    shell command tr can be used to collapse a sentence "this is a test"
> > into
> 
> > this 
> > is
> > a 
> > test
> > . How can this be done in emacs?
> 
> (replace-regexp " " "^J")
> 
> or M-x replace-regexp, similarly. Use C-q to quote the C-j.
> 
> Works t'other way round, too :)
> 
    this would replace all " " with "^J". However, the text I'd like
to  replace is only part of the buffer. I expect to mark the region
first and then do something to collapse it. 

-- 
Nothing

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

* Re: how to collapse a horizontal into vertail
  2003-01-11 21:37   ` Zimmen Gnauh
@ 2003-01-12  0:03     ` Tim Haynes
  0 siblings, 0 replies; 4+ messages in thread
From: Tim Haynes @ 2003-01-12  0:03 UTC (permalink / raw)


Zimmen Gnauh <yah00204052@yahoo.com> writes:

>> (replace-regexp " " "^J")
>> 
>> or M-x replace-regexp, similarly. Use C-q to quote the C-j.
>> 
>> Works t'other way round, too :)
> 
>
> this would replace all " " with "^J". However, the text I'd like to
> replace is only part of the buffer. I expect to mark the region first and
> then do something to collapse it.

You could use the narrow-to-region function (C-x n n) to shrink the
affected area to a selected region, then widen (C-x n w) to regain view of
the whole buffer.

~Tim
-- 
  00:02:06  up 23 days,  8:49,  8 users,  load average: 0.45, 0.29, 0.11
piglet@stirfried.vegetable.org.uk |I never knew that the 
http://piglet.is.dreaming.org     |light of ages breaks the way before us

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

end of thread, other threads:[~2003-01-12  0:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-01-11 17:11 how to collapse a horizontal into vertail Zimmen Gnauh
2003-01-11 19:27 ` Tim Haynes
2003-01-11 21:37   ` Zimmen Gnauh
2003-01-12  0:03     ` Tim Haynes

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.