help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: any way to get white margin around text?


From: Omar Polo
Subject: Re: any way to get white margin around text?
Date: Thu, 24 Dec 2020 19:55:39 +0100
User-agent: mu4e 1.4.13; emacs 27.1

Jean Louis <bugs@gnu.support> writes:

> I would like to get margin around the text, let us say 2 lines from
> top and 4 columns from the left side. The marging should not be
> indentation or something that is part of text, but rather only visual.
>
> The command `set-left-margin' does not do what I mean, it sets margin
> but is part of the text. I just would like it visually separated form
> the window borders to gain better nicer note display.

set-window-margin should do what you're saying.  For instance

    (set-window-margin (get-buffer-window) 4 4)

will set the borders on both sides to 4 columns, without affecting the
buffer content.  The fringe will be between the margin and the buffer
content though.

(I've never used this function directly before, I've found it now by
inspecting the olivetti-mode implementation)

HTH



reply via email to

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