From: roy@panix.com (Roy Smith)
Subject: Re: Narrowing same buffer to different regions in two windows
Date: 20 Oct 2004 13:54:34 -0400 [thread overview]
Message-ID: <cl68oq$4om$1@panix2.panix.com> (raw)
In-Reply-To: mailman.4238.1098288305.2017.help-gnu-emacs@gnu.org
Compare-windows is neat, but it's not quite the same as narrowing.
I'm in one window and see a variable "foo". I want to see if the
function in the other window also has "foo", so I go to the other
window and do "C-S foo". Only with narrowing will I be sure that the
foo I found is in the function of interest.
In article <mailman.4238.1098288305.2017.help-gnu-emacs@gnu.org>,
Drew Adams <drew.adams@oracle.com> wrote:
>Another tool to try: `M-x compare-windows':
>
>"Compare text in current window with text in next window.
>Compares the text starting at point in each window,
>moving over text in each one as far as they match.
>
>This command pushes the mark in each window
>at the prior location of point in that window.
>If both windows display the same buffer,
>the mark is pushed twice in that buffer:
>first in the other window, then in the selected window.
>
>A prefix arg means ignore changes in whitespace.
>The variable `compare-windows-whitespace' controls how whitespace is
>skipped.
>If `compare-ignore-case' is non-nil, changes in case are also ignored."
>
>-----Original Message-----From: Roy Smith
>I've got a file with two large sections of very similar text that I
>want to examine and compare (it's C++, and a previous author did a
>"cut, paste, and modify" job instead of refactoring). What I'd like
>to do is split the screen into two windows, and do narrow-to-region in
>each window, ending up with each window looking at a distinct section
>of the file.
>
>The problem is, narrowing works per-buffer, not per-window. Is there
>anyway to do what I want?
>
>
>
next parent reply other threads:[~2004-10-20 17:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.4238.1098288305.2017.help-gnu-emacs@gnu.org>
2004-10-20 17:54 ` Roy Smith [this message]
2004-10-20 18:21 ` Narrowing same buffer to different regions in two windows Drew Adams
2004-10-20 15:32 Roy Smith
2004-10-20 15:38 ` Stefan Monnier
2004-10-20 15:56 ` Drew Adams
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='cl68oq$4om$1@panix2.panix.com' \
--to=roy@panix.com \
/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.