From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Maindoor Newsgroups: gmane.emacs.help Subject: RE: simple requirement, so simple don't know how to search Date: Tue, 2 Feb 2010 20:50:14 -0800 (PST) Message-ID: <811914.6715.qm@web63002.mail.re1.yahoo.com> References: <1B4E7CE7DF944EED85A5F6FDD9540773@us.oracle.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0-1634288300-1265172614=:6715" X-Trace: ger.gmane.org 1265172713 18053 80.91.229.12 (3 Feb 2010 04:51:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 3 Feb 2010 04:51:53 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: 'Mario Domenech Goulart' , Drew Adams Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Feb 03 05:51:50 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1NcXDO-0004px-Ne for geh-help-gnu-emacs@m.gmane.org; Wed, 03 Feb 2010 05:51:47 +0100 Original-Received: from localhost ([127.0.0.1]:48718 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NcXDO-0003tZ-08 for geh-help-gnu-emacs@m.gmane.org; Tue, 02 Feb 2010 23:51:46 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NcXC2-0003P6-Ow for help-gnu-emacs@gnu.org; Tue, 02 Feb 2010 23:50:22 -0500 Original-Received: from [199.232.76.173] (port=54132 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NcXC0-0003Nz-44 for help-gnu-emacs@gnu.org; Tue, 02 Feb 2010 23:50:20 -0500 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NcXBv-00048m-Rx for help-gnu-emacs@gnu.org; Tue, 02 Feb 2010 23:50:19 -0500 Original-Received: from web63002.mail.re1.yahoo.com ([69.147.96.213]:35030) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1NcXBv-00048c-FJ for help-gnu-emacs@gnu.org; Tue, 02 Feb 2010 23:50:15 -0500 Original-Received: (qmail 6719 invoked by uid 60001); 3 Feb 2010 04:50:14 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1265172614; bh=okJFgadCOvw9x7lkA32wNgzddu0W3xdPY5DLBKg6NZc=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type; b=ilj161+PtBaXf6ClN2lmP1plGEXKmtJP5blAjhI0pQR1UyUi1mnUuen5JCE1c4x6nFL6XlR5F1qW0ybkKzV1895g+DMkCBZGvhiHjrh0PWMNKJSR7N1rScjg2HyjbEcX8ROZrkZAk8wZXNchBM8weNc4Hcg4colQ8QekbU51uJU= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type; b=bMiAnMXbdjHi3Sdfxpna42my+FCufKg82uw/Xs3oVKNxc6Bh9+bdLh8pmf2FAEi7JTLmDrxnfT9GkUb3bZBNXQ96ya5/YqImvgJyzxR7uDQSTSKMPOlAT5FX9oSgF8glM2AT7ZuQ6Z1j6H8exbZHfCe+WdkeD5rfVluTlM7q2bY=; X-YMail-OSG: jK23epUVM1lYLTOgZctqWiocQ8B8pOnSoPLBnlCAHXuF6xrQdDI4_xHb40lQrqi0MiTdaM5AcC7FnqvmETvJ_MMy5dYSrd.rmCH0tsj6CXbvFLIX5V39H90f0SMAvg_Mdi_Mretnsp9aZMKWWw2D5M7KPX5AeTGNhoWdoMC4y4xdarx7xEc4WTHs7xOFiRYgErQDKJ3_SSvuRnv.vAKVhJsyZDICobAzGGnt0APhvzW0dcixV0Ul1LQRxuj9tMnawN.A5ih_Z8T51N6QrOsgBjJRdeASoe.sQ2ppLHGFFWCDlpDQhUSp8lC1hXMi2zlL25i_FSm.FsovI_.03_1EUl0Ygn_B.bKtzA5eFLy63.JxaVYTxJYjKagcuR1GLmf8SO3Rrp7QCG9ytYmrixilLRuBBx9817yN_qE- Original-Received: from [61.12.14.5] by web63002.mail.re1.yahoo.com via HTTP; Tue, 02 Feb 2010 20:50:14 PST X-Mailer: YahooMailClassic/9.1.10 YahooMailWebService/0.8.100.260964 In-Reply-To: <1B4E7CE7DF944EED85A5F6FDD9540773@us.oracle.com> X-detected-operating-system: by monty-python.gnu.org: FreeBSD 6.x (1) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:71633 Archived-At: --0-1634288300-1265172614=:6715 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Drew, Thank you for the explanation.=20 Richard's mail to this thread earlier was=A0=20 something that I would be interested in. But it has a major feature flaw. Buffer local bookmarks ? It would be great if it were global. Another user wanted global scope too.=20 Maindoor. --- On Tue, 2/2/10, Drew Adams wrote: From: Drew Adams Subject: RE: simple requirement, so simple don't know how to search To: "'Maindoor'" , "'Mario Domenech Goulart'" Cc: help-gnu-emacs@gnu.org Date: Tuesday, February 2, 2010, 9:20 PM > Sorry, I'll be more verbose on my requirements this time. and looking at = your=20 > contributions to emacswiki, I can safely assume that such a thing does no= t exist > if you don't know the answer. Bad assumption - I'm not as knowledgable as you suppose. And it's not about being verbose. It's about making clear what you're looki= ng for. Current session only? Multiple buffers? Multiple positions per buffer? Visual markings? Named positions? The possibilities depend on the answers. > When browsing file1.c i come to 400th line in function fnA(). I want to remember=20 > this particular line. so I press F2.=A0 Then I goto file2.c, look=A0 and = I don't > want to do anything. Then I go to file3.c, and visit line 50 in fnB(). I = want > to remember this, so I press F2. and so on.=20 > Now I want to browse through the marked places so I press F3 and F4 to go= back > and forth in the list that I marked. The list now contains two entries 40= 0th line in=20 > FnA() and 50 the line in FnB(). > I can also limit the total number of entries in the list say to 20 or 50. > So at most I will be able to remember 20 or 50 places after which the old= est > entries will be overwritten.=20 > Now registers and bookmarks will have tags associated with them and I don= 't=20 > want to use tags. I just want to browse through the remembered entries. >=A0=A0=A0=20 > Will things-cmd.el serve the purpose ? or is there some other utility ? No. thing-cmds.el is for selecting things (text). You want to record positi= ons and then move among them. =A0=A0=A0=20 So based on what you just said, it seems: You want to be able to (quickly - single key) set a "marker" (placeholder) of sorts at a location, without ne= eding to provide a name (what you called a "tag"), and later, in the same session= , return to that marker from anywhere else. Even a one-character name (as for= a register) is too much bother. You don't need persistence (cross-session "markers"), and you don't need named "markers". You don't need to record ve= ry many such places. You don't need more than one such "marker" per buffer (ba= sed on your example). Richard R. gave you one possibility: library bm.el offers visible, unnamed = marks that you can cycle through. Another possibility is to use ordinary global marks - see node `Global Mark Ring' in the Emacs manual. If you do need multiple "markers" in the same bu= ffer, then use local marks - see node `Mark Ring' in the manual. You can cycle am= ong the marks in either ring. Using the mark rings, you cannot easily see the possible destinations, and = it can take a moment to see where you've arrived (cursor location) after you m= ove to a mark. Library bm.el helps with that by making marked positions visible= .=20 If you use Icicles, then you can trip around among local and global marks m= ore flexibly, and you can also see easily where you've arrived (cross-hairs). Y= ou can cycle among marks, but you can also move directly to any mark you want.= See http://www.emacswiki.org/emacs/Icicles_-_Tripping (commands `icicle-goto-ma= rker' and `icicle-goto-global-marker'). This direct access is possible because, though you don't name the marks, yo= u can refer to the text (lines) they are in to distinguish them. The text around = each mark is an Icicles completion candidate. When you cycle among candidates, y= ou can simultaneously move to their locations. You can cycle through them all to get to one you want (which is OK if there= are few), or you can type a bit of text to narrow the candidates down, then cyc= le or type some more, etc. Or you can just pick candidates from the *Completions* buffer with the mouse. If you decide you do want persistent "markers", but you still don't want to= name them, you can use Icicles together with Bookmark+ to get what you want. The= same key is used for setting a (book)mark and jumping to (any number of) bookmar= ks. With `-' as prefix arg, you jump. With `0' or any other digit, you set (mar= k). Or bind your own keys. When you define a bookmark this way, it is named automatically, without any interaction. The name is taken from the position's context: the buffer name= plus some text from the line (or the region, if active). You can use Icicles to = trip around among candidate bookmarks the same way as among Emacs marks. HTH. =0A=0A=0A --0-1634288300-1265172614=:6715 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable
Drew,
Thank you for the explanation.
R= ichard's mail to this thread earlier was 
something that I would b= e interested in. But it has a major feature flaw.
Buffer local bookmarks= ? It would be great if it were global. Another
user wanted global scope= too.

Maindoor.

--- On Tue, 2/2/10, Drew Adams <dre= w.adams@oracle.com> wrote:

From:= Drew Adams <drew.adams@oracle.com>
Subject: RE: simple requiremen= t, so simple don't know how to search
To: "'Maindoor'" <sanjeevfiles@= yahoo.com>, "'Mario Domenech Goulart'" <mario.goulart@gmail.com>Cc: help-gnu-emacs@gnu.org
Date: Tuesday, February 2, 2010, 9:20 PM
> Sorry, I'll be more verbose on my requir= ements this time. and looking at your
> contributions to emacswiki, I can = safely assume that such a thing does not
exist
> if you don't know= the answer.

Bad assumption - I'm not as knowledgable as you suppose= .

And it's not about being verbose. It's about making clear what you= 're looking
for. Current session only? Multiple buffers? Multiple positi= ons per buffer?
Visual markings? Named positions? The possibilities depe= nd on the answers.

> When browsing file1.c i come to 400th line i= n function fnA(). I want to
remember
> this particular line. so I= press F2.  Then I goto file2.c, look  and I don't
> want t= o do anything. Then I go to file3.c, and visit line 50 in fnB(). I want
= > to remember this, so I press F2. and so on.
> Now I want to bro= wse through the marked places so I press F3 and F4 to go back

> a= nd forth in the list that I marked. The list now contains two entries 400th
line in
> FnA() and 50 the line in FnB().
> = I can also limit the total number of entries in the list say to 20 or 50.> So at most I will be able to remember 20 or 50 places after which th= e oldest
> entries will be overwritten.
> Now registers and bo= okmarks will have tags associated with them and I don't
> want to us= e tags. I just want to browse through the remembered entries.
> =   
> Will things-cmd.el serve the purpose ? or is there so= me other utility ?

No. thing-cmds.el is for selecting things (text).= You want to record positions
and then move among them.
  &= nbsp;
So based on what you just said, it seems: You want to be able to = (quickly -
single key) set a "marker" (placeholder) of sorts at a locati= on, without needing
to provide a name (what you called a "tag"), and lat= er, in the same session,
return to that marker from anywhere else. Even a one-character name (as for a
register) is too much bother.= You don't need persistence (cross-session
"markers"), and you don't nee= d named "markers". You don't need to record very
many such places. You d= on't need more than one such "marker" per buffer (based
on your example)= .

Richard R. gave you one possibility: library bm.el offers visible,= unnamed marks
that you can cycle through.

Another possibility is= to use ordinary global marks - see node `Global Mark
Ring' in the Emacs= manual. If you do need multiple "markers" in the same buffer,
then use = local marks - see node `Mark Ring' in the manual. You can cycle among
th= e marks in either ring.

Using the mark rings, you cannot easily see = the possible destinations, and it
can take a moment to see where you've = arrived (cursor location) after you move
to a mark. Library bm.el helps = with that by making marked positions visible.

If you use Icicles, then you can trip around among local and global marks more
fle= xibly, and you can also see easily where you've arrived (cross-hairs). You<= br>can cycle among marks, but you can also move directly to any mark you wa= nt. See
http://www.emacswiki.org/emacs/Icicles_-_Tripping (comm= ands `icicle-goto-marker'
and `icicle-goto-global-marker').

This = direct access is possible because, though you don't name the marks, you can=
refer to the text (lines) they are in to distinguish them. The text aro= und each
mark is an Icicles completion candidate. When you cycle among c= andidates, you
can simultaneously move to their locations.

You ca= n cycle through them all to get to one you want (which is OK if there arefew), or you can type a bit of text to narrow the candidates down, then c= ycle or
type some more, etc. Or you can just pick candidates from the *Completions*
buffer with the mouse.

If you decide you do want p= ersistent "markers", but you still don't want to name
them, you can use = Icicles together with Bookmark+ to get what you want. The same
key is us= ed for setting a (book)mark and jumping to (any number of) bookmarks.
Wi= th `-' as prefix arg, you jump. With `0' or any other digit, you set (mark)= .
Or bind your own keys.

When you define a bookmark this way, it = is named automatically, without any
interaction. The name is taken from = the position's context: the buffer name plus
some text from the line (or= the region, if active). You can use Icicles to trip
around among candid= ate bookmarks the same way as among Emacs marks.

HTH.

<= /blockquote>

=0A=0A --0-1634288300-1265172614=:6715--