From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Brian Adkins Newsgroups: gmane.emacs.help Subject: Re: Buffer specific hide-list in ERC Date: Mon, 03 Aug 2009 15:54:52 -0400 Organization: A noiseless patient Spider Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1249344684 7448 80.91.229.12 (4 Aug 2009 00:11:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 4 Aug 2009 00:11:24 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Aug 04 02:11:17 2009 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.50) id 1MY7ca-0002dv-W7 for geh-help-gnu-emacs@m.gmane.org; Tue, 04 Aug 2009 02:11:17 +0200 Original-Received: from localhost ([127.0.0.1]:39749 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MY7cZ-0003i8-T2 for geh-help-gnu-emacs@m.gmane.org; Mon, 03 Aug 2009 20:11:16 -0400 Original-Path: news.stanford.edu!headwall.stanford.edu!news.glorb.com!news2.glorb.com!de-l.enfer-du-nord.net!feeder.erje.net!feeder.eternal-september.org!eternal-september.org!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 32 Original-X-Trace: news.eternal-september.org U2FsdGVkX1/TtKlElDMvwFiV6n6+kKJ5/4zzwwpQzgIwUU3u8z26FDpINbtq1WvOg4LB/BDb27xG9s1HAszRzBBTFwCthvQmauL4K4d5pxH8xlXDA8GclsLOgBr0zZ4th7EYw94pypyenqkzL2oU/A== Original-X-Complaints-To: abuse@eternal-september.org Original-NNTP-Posting-Date: Mon, 3 Aug 2009 20:02:33 +0000 (UTC) X-Auth-Sender: U2FsdGVkX1/89RP9QjbQhzDc1XQBYjHcE0gaBxrHNug= Cancel-Lock: sha1:KHGZWlIt9ErbYn2jB3q38HVbdPo= sha1:rbYAbGQhrl3dlre3yXBZd5y/ApA= User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (darwin) Original-Xref: news.stanford.edu gnu.emacs.help:171527 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:66710 Archived-At: "Edward O'Connor" writes: >> I just discovered the way to hide certain IRC messages in the Emacs >> ERC client via erc-hide-list; however, I've been unable to find a way >> to do this for specific channels/buffers. >> >> In other words, I'd like to hide 'join', 'part', 'quit', etc. in my >> higher traffic channels, but I'm in a few low traffic channels where >> it would be handy to see that a person has joined. > > You could make the variables be buffer-local, and set them to > different values via a hook. Thanks. The help for make-variable-buffer-local recommends using make-local-variable. The latter accepts one argument - the name of the variable, so it appears to depend on some sort of context to determine which buffer in which to make the variable local i.e. I can't pass in a reference to a buffer. The ERC doc shows a erc-join-hook which states the function is called w/o arguments and the current buffer is set to the buffer of the new channel. So if I can just figure out how to determine which channel is associated with the current buffer, the rest should be easy :) buffer-name might be sufficient since it looks like the buffer name begins with the name of the channel. -- Brian Adkins http://lojic.com/