From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lorenzo Isella Newsgroups: gmane.emacs.help Subject: Re: How to go to next line on the screen instead of going to, next line in the text? Date: Mon, 02 Jun 2008 18:41:15 +0200 Message-ID: <484422AB.8020204@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1212424978 18855 80.91.229.12 (2 Jun 2008 16:42:58 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 2 Jun 2008 16:42:58 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: zthjwsqqafhv@spammotel.com Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jun 02 18:43:37 2008 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 1K3D7x-0001xX-Ha for geh-help-gnu-emacs@m.gmane.org; Mon, 02 Jun 2008 18:43:21 +0200 Original-Received: from localhost ([127.0.0.1]:47352 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K3D7B-0000DO-0Z for geh-help-gnu-emacs@m.gmane.org; Mon, 02 Jun 2008 12:42:33 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K3D63-0007tS-4h for help-gnu-emacs@gnu.org; Mon, 02 Jun 2008 12:41:23 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K3D61-0007qi-HJ for help-gnu-emacs@gnu.org; Mon, 02 Jun 2008 12:41:21 -0400 Original-Received: from [199.232.76.173] (port=50878 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K3D60-0007qQ-Uo for help-gnu-emacs@gnu.org; Mon, 02 Jun 2008 12:41:21 -0400 Original-Received: from mu-out-0910.google.com ([209.85.134.186]:42658) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1K3D60-0000k4-O9 for help-gnu-emacs@gnu.org; Mon, 02 Jun 2008 12:41:21 -0400 Original-Received: by mu-out-0910.google.com with SMTP id i2so1504387mue.6 for ; Mon, 02 Jun 2008 09:41:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:cc:subject:content-type:content-transfer-encoding:sender; bh=94tammVU04mmpiAjNP2/WEsawMnaCb2ncHLDlCB0kQo=; b=SJjKTjlITjudJfd3rkoIPXCeD3ojzMG6tN05sUjxChvdQsp+cDoUKK8U6AIkRhgocGeIdQP0Q1KtkKwqXLIq+VxTYtVYrkNEjwSXIb2ConlEabBrybP/SZSFsfeJNu2vcp7dpkqakHGsrdQGrn8Rar5FZ3zEwlwq43wuTMdHTh8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject:content-type:content-transfer-encoding:sender; b=D6IOISJPU/Vqy/boaCnHCoh823FsidOyg4XHti3/aS1PeAkqwhT6Alda9wiarZsCisB4NWVhMmJh4mnvPhuO0qiOSQk4DOqUxXISBdJykX2HvHz0GV90OR9yoaA6oUKOFcSHSlP/jxE28/Ui165gcSjVSjvimLe7WKokg0yYeHM= Original-Received: by 10.103.224.17 with SMTP id b17mr5216544mur.16.1212424877978; Mon, 02 Jun 2008 09:41:17 -0700 (PDT) Original-Received: from cappero.jrc.it ( [151.59.220.166]) by mx.google.com with ESMTPS id g1sm19831274muf.7.2008.06.02.09.41.16 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 02 Jun 2008 09:41:17 -0700 (PDT) User-Agent: Mozilla-Thunderbird 2.0.0.14 (X11/20080509) X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 2) 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:54425 Archived-At: Message: 4 Date: Mon, 02 Jun 2008 13:16:02 +0200 From: S?bastien Vauban Subject: Re: How to go to next line on the screen instead of going to next line in the text? To: help-gnu-emacs@gnu.org Message-ID: <87k5h8ytn1.fsf@mundaneum.com> Content-Type: text/plain; charset=utf-8 Hi, > > In emacs, if you hit the down arrow key, the cursor will go to next > > line in the text, i.e., the part after the first next '\n'. > > > > However, sometimes when the line is long and is wrapped into several > > lines on the screen, I wanna move between the screen lines, instead of > > the text lines. > > > > How to do that? > --8<---------------cut here---------------start------------->8--- ;; point motion by screen lines (as opposed to text lines) ;; TODO screen lines mode enabled by default for all buffers (when (require 'screen-lines) ;; following lines commented out for keeping the original `kill-line' ;; in `screen-lines' minor mode (add-hook 'screen-lines-load-hook (lambda () (ad-disable-advice 'kill-line 'around 'screen-lines) (ad-activate 'kill-line))) ;; nothing should appear in the mode line, when the `screen-lines' mode ;; is enabled in a buffer (setq screen-lines-minor-mode-string "")) --8<---------------cut here---------------end--------------->8--- Seb -- Sébastien Vauban Hello Sebastien, I tried out your suggestion (I basically cut and pasted your small code into my .emacs file), but there must be something that emacs does not like. First of all, was I supposed to simply introduce those lines in my .emacs file? Any position in the emacs file can do? I installed emacs 22.1 with gtk from the standard Debian testing repositories and I have my own .emacs file for some simple customization. In the following, I report the error message returned by emacs. Cheers Lorenzo ("emacs22-gtk") Loading 00debian-vars...done Loading /etc/emacs/site-start.d/20apel.el (source)...done Loading /etc/emacs22/site-start.d/50auctex.el (source)... Loading /usr/share/emacs/22.2/site-lisp/auctex.el (source)... Loading /usr/share/emacs/22.2/site-lisp/tex-site.el (source)...done Loading /usr/share/emacs/22.2/site-lisp/auctex.el (source)...done Loading /usr/share/emacs/22.2/site-lisp/preview-latex.el (source)...done Loading /etc/emacs22/site-start.d/50auctex.el (source)...done Loading /etc/emacs/site-start.d/50autoconf.el (source)...done Loading /etc/emacs/site-start.d/50dictionaries-common.el (source)... Loading debian-ispell... Loading /var/cache/dictionaries-common/emacsen-ispell-default.el (source)...done Loading debian-ispell...done Loading /var/cache/dictionaries-common/emacsen-ispell-dicts.el (source)...done Loading /etc/emacs/site-start.d/50dictionaries-common.el (source)...done Loading /etc/emacs/site-start.d/50emacs-goodies-el.el (source)...done Loading /etc/emacs/site-start.d/50ess.el (source)... Loading regexp-opt...done Loading /etc/emacs/site-start.d/50ess.el (source)...done Loading /etc/emacs/site-start.d/50flim.el (source)...done Loading /etc/emacs/site-start.d/50maxima-emacs.el (source)...done Loading /etc/emacs/site-start.d/50noweb.el (source)...done Loading /etc/emacs/site-start.d/50nowebm.el (source)...done Loading /etc/emacs/site-start.d/50psvn.el (source)...done Loading /etc/emacs/site-start.d/50pymacs.el (source)...done Loading /etc/emacs/site-start.d/50python-mode.el (source)...done Loading /etc/emacs/site-start.d/50slime.el (source)... Loading /usr/share/emacs22/site-lisp/slime/slime-autoloads...done Loading /etc/emacs/site-start.d/50slime.el (source)...done Loading /etc/emacs/site-start.d/50w3m-el.el (source)...done Loading /etc/emacs/site-start.d/60cltl.el (source)...done Loading advice...done Loading paren...done Loading time...done Loading delsel...done An error has occurred while loading `/home/iselllo/.emacs': File error: Cannot open load file, screen-lines To ensure normal operation, you should investigate and remove the cause of the error in your initialization file. Start Emacs with the `--debug-init' option to view a complete error backtrace. For information about GNU Emacs and the GNU system, type C-h C-a.