auctex
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [AUCTeX] display of blank lines


From: Tassilo Horn
Subject: Re: [AUCTeX] display of blank lines
Date: Tue, 14 Oct 2014 12:56:03 +0200
User-agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/25.0.50 (gnu/linux)

Tamas Papp <address@hidden> writes:

Hi Tamas,

> I am wondering if there is a way to have blank lines appear shorter
> when I am editing a file in AUCTeX. Eg for
>
> This is a paragraph.
>
> Second paragraph.
>
> it would be very convenient if the empty line between "paragraph." and
> "Second" appeared eg a bit shorter (with a font of reduced/half
> height, etc).

Interesting idea and not specific to AUCTeX at all.  Here's a quick and
dirty minor mode which does what you suggest.

--8<---------------cut here---------------start------------->8---
(defface th/reduced-blank-line-face
  '((t (:inherit default :height 0.5)))
  "Face used for blank lines.")
   
(define-minor-mode th/reduced-blank-line-mode
  (let ((keywords '(("^[[:space:]]*\n" 0 'th/reduced-blank-line-face))))
    (if th/reduced-blank-line-mode
        (font-lock-add-keywords nil keywords)
      (font-lock-remove-keywords nil keywords))
    (font-lock-flush)))
--8<---------------cut here---------------end--------------->8---

Bye,
Tassilo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]