From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Decebal Newsgroups: gmane.emacs.help Subject: Re: Refill mode for text-mode, but not for org-mode Date: Sat, 25 Oct 2008 00:45:59 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <55ca2c0c-90ed-4b57-9ff6-01b43886e844@c60g2000hsf.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1224924114 6206 80.91.229.12 (25 Oct 2008 08:41:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 25 Oct 2008 08:41:54 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Oct 25 10:42:54 2008 connect(): Connection refused 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 1KtejJ-00051N-8V for geh-help-gnu-emacs@m.gmane.org; Sat, 25 Oct 2008 10:42:41 +0200 Original-Received: from localhost ([127.0.0.1]:47835 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KteiD-0007Jq-AX for geh-help-gnu-emacs@m.gmane.org; Sat, 25 Oct 2008 04:41:33 -0400 Original-Path: news.stanford.edu!newsfeed.stanford.edu!postnews.google.com!y29g2000hsf.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 29 Original-NNTP-Posting-Host: 84.53.123.169 Original-X-Trace: posting.google.com 1224920760 30650 127.0.0.1 (25 Oct 2008 07:46:00 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Sat, 25 Oct 2008 07:46:00 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: y29g2000hsf.googlegroups.com; posting-host=84.53.123.169; posting-account=K-cdeAoAAAD_0d505kUtHXJaT5LFIu-3 User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; nl; rv:1.9.0.1) Gecko/2008070206 Firefox/3.0.1,gzip(gfe),gzip(gfe) Original-Xref: news.stanford.edu gnu.emacs.help:163811 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:59147 Archived-At: On Oct 24, 8:36=A0pm, bojohan+n...@dd.chalmers.se (Johan Bockg=E5rd) wrote: > > I have the following in my .emacs: > > =A0 =A0 (add-hook 'text-mode-hook > > =A0 =A0 =A0 (lambda () (refill-mode 1) > > =A0 =A0 =A0 ) > > > This sets refill-mode for text-mode -what I want-, but also for org- > > mode -what I do not want-. How can I set it for text-mode without also > > setting it for org-mode? > > (add-hook 'text-mode-hook > =A0 =A0 =A0 =A0 =A0 (lambda () > =A0 =A0 =A0 =A0 =A0 =A0 ;; List exceptions here > =A0 =A0 =A0 =A0 =A0 =A0 (unless (memq major-mode '(org-mode)) > =A0 =A0 =A0 =A0 =A0 =A0 =A0 (refill-mode 1)))) This works partly (as explained in another thread). I want a little more and I have: (add-hook 'text-mode-hook (lambda () (unless (memq major-mode '(org-mode)) (refill-mode 1) (setq-default default-justification 'full) ) ) ) This does not set refill-mode for org-mode, but it does set default- justification for org-mode. A bit strange.