sponsor Vim development Vim logo Vim Book Ad

gedim : Auto-size Graphical EDitor DIMensions on open.

 script karma  Rating 30/9, Downloaded by 1518  Comments, bugs, improvements  Vim wiki

created by
Eugene Ciurana
 
script type
utility
 
description
My portable computer is my primary workstation. I either use an external, high resolution monitor or its built-in screen, depending on where I am. I often use also someone else's monitors, when I'm working remotely. This forces me to change the graphical Vim editor dimensions for every location where I happen to be. Though not complicated, it's annoying. That's why I wrote this script/Vim auto-command that does the job instead. Just define the desired editor columns and lines for a given resolution, and MacVim will open at that size every time that the same resolution is detected.

Features:

    * User configurable: add as many output device resolutions and editor sizes as desired or needed
    * MacVim and gVim compatible
    * Works on OS X, Linux/Gnome, Linux/KDE, and Windows
    * Unobtrusive; set it up once and forget about it

No more dragging the window corners to resize. No more :set columns=128. Just open Vim and get to work!
 
install details
UNIX-like systems:

cd ~/.vim

unzip /path/to/gedim.zip

vi
:helptags ~/.vim/doc


Windows systems:

Unpack the .zip file and copy the files to your
gvim or vim configuration directory, then:

vi
:helptags /path/to/doc


Caveat Fenestrae emptor:
------------------------
Unfortunately the developers and testers had only limited access to a Windows machine.  Please let me know if you had issues through the URL in the comments section.

Comments, questions, bug reports:
---------------------------------
http://eugeneciurana.com/contact or
http://ciurana.eu/contact for your questions.

Project page:  http://eugeneciurana.com/gedim.vim

IMPORTANT:
:help gedim-configuration

This section tells you how to configure the various editor sizes corresponding to each screen resolution.
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
gedim.zip 1.2b 2014-09-30 7.0 Eugene Ciurana Updated the documentation for Windows support in response to a bug report when running gVim + gedim in Windows Vista; the appropriate course, according to the Windows experts contributors to this project, is to use Windows 7 or later (Windows 8.1 on the date of this update).
gedim.zip 1.2 2010-09-03 7.0 Eugene Ciurana Faster screen detection on OS X - improvement by Ludvig Ericson - thanks!  Also added main display detection on MacVim / gVim running on Macs with multiple displays attached.
gedim.zip 1.1c 2010-08-14 7.0 Eugene Ciurana Fixed a typo in the documentation comments and updated contributors list.  No functional changes if you already have 1.1b.
gedim.zip 1.1b 2010-08-14 7.0 Eugene Ciurana Fixed the EOL detection code for the Windows script that reports the screen resolution; the original author had forgotten that EOL in DOS/Windows == \r\n.  Thanks to Nathan Tenney for pointing that out an for providing a fix.
gedim.zip 1.1 2010-08-11 7.0 Eugene Ciurana Initial upload
ip used for rating: 3.15.219.217

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
Vim at Github