You are not logged in.

#1 2016-12-13 12:45:25

eastballz
Member
Registered: 2016-12-10
Posts: 8

Urxvt disable internal border for vim

Hi, so I have Urxvt set to have an internal border of 10 pixels in my Xresources, is there a way I can tell it to disable it when I'm using vim? I want to have something like:

URxvt.internalBorder: 10
vim.internalBorder: 0

I believe this can be done with emacs, but I can't figure out how to do it with vim

Offline

#2 2016-12-13 12:48:59

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,530
Website

Re: Urxvt disable internal border for vim

How is it done with emacs?  Certainly not with Xresources.  That file is parsed once into the X resource database.  Urxvt then pulls values from the resource database only once at startup.   So anything emacs does to change the border is not via xresource changes, but - most likely - some escape code sent to the terminal.

I've found documentation for emacs to *add* more internal border.  I don't know if there is an option to do this in vim, but this is entirely different from removing the padding that the terminal itself has already set.  So I'm curious whether emacs really can disable the terminals own padding (I'm highly skeptical).

EDIT: Perhaps I misunderstood.  Do you want to change this setting "on the fly"?  If so, I'm skeptical that it's possible, but if it is, it would only be through an escape code sent to the terminal.  On the other hand, if you just want regular urxvt windows to have the internal border, but urxvt windows opened specifically for vim not to, that is *very* easy.  Basically the xresources excerpt you have would work, you'd just need to set the resource name for the urxvt window in which you were running vim (this is a command line parameter for urxvt).  Or instead of the xresources, just use the '-b' flag:

urxvt -b 0 -e vim

Last edited by Trilby (2016-12-13 12:54:22)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2016-12-13 12:57:22

eastballz
Member
Registered: 2016-12-10
Posts: 8

Re: Urxvt disable internal border for vim

You're probably right, I just saw this file (https://github.com/fullsalvo/zenbu-them … Xresources) where he just had the line emacs.internalBorder, and thought maybe it can be done with vim as well. In any case, would there be another way to accomplish it?

Offline

#4 2016-12-13 13:00:44

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,530
Website

Re: Urxvt disable internal border for vim

That is not an emacs setting, that is a urxvt setting for urxvt windows with the resource name 'emacs'.  That will work just as well with vim or any other program.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#5 2016-12-13 13:06:09

eastballz
Member
Registered: 2016-12-10
Posts: 8

Re: Urxvt disable internal border for vim

So if I understand you, adding vim.internalBorder: 0 should disable the border in vim? I've tried it but doesn't seem to work.

Offline

#6 2016-12-13 13:08:40

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,530
Website

Re: Urxvt disable internal border for vim

Please read my first post.  I may have edited it while you were replying the first time.

You can call it 'vim.internalBorder' 'no.internalBorder' 'whateveryouwant.internalBorder', but if you don't set the terminal resource name to match, that setting will not have any effect.  The name is entirely arbitrary.  It makes sense to give it a label representing the use (hence the other user calling it 'emacs') but it is just an arbitrary label.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#7 2016-12-13 13:12:01

eastballz
Member
Registered: 2016-12-10
Posts: 8

Re: Urxvt disable internal border for vim

Oh sorry, I didn't see your edit before. Thanks you very much, disabling it for vim-specific windows is enough for me.

Offline

Board footer

Powered by FluxBB