Stories
Slash Boxes
Comments

SoylentNews is people

posted by martyb on Saturday December 14 2019, @02:09AM   Printer-friendly
from the real-programmers-edit-files-using-cat-and-sed dept.

After more than a year of development the new features are now ready for the Vim crowds. Popup windows make it possible to show messages, function prototypes, code snippets and anything else on top of the text being edited. They open and close quickly and can be highlighted in many ways. More about that in the article.

Vim 8.2 released : vim online

Vim 8.2 is available! Vim 8.2 is a minor release, a lot of bugs have been fixed, documentation was updated, test coverage was improved, etc. There are a few interesting new features, see below.

For MS-Windows, download the self installing executable.
Signed MS-Windows files will soon be available on the vim-win32-installer site
For Unix you probably want to get the latest version using git, see the github page
Otherwise see the Download page for options.

Background:

Before I did the keynote at VimConf 2018 I asked plugin developers what they wanted from Vim. The result was a very long list of requested features. The top two items were clear: Popup windows and text properties.

After more than a year of development the new features are now ready for the Vim crowds. Popup windows make it possible to show messages, function prototypes, code snippets and anything else on top of the text being edited. They open and close quickly and can be highlighted in many ways. More about that below.

This was no small effort. Although the existing window support could be used, popup windows are different enough to require a lot of extra logic. Especially to update the screen efficiently. Also to make it easy for plugin writers to use them; you don't need to tell Vim exactly where to show one, just give a reference point and the text to display, Vim will figure out the size and where the popup fits best.

Text properties can be used for something as simple as highlighting a text snippet or something as complicated as using an external parser to locate syntax items and highlight them asynchronously. This can be used instead of the pattern based syntax highlighting. A text property sticks with the text, also when inserting a word before it. And this is done efficiently by storing the properties with the text.

There's much more at the above link.


Original Submission

This discussion has been archived. No new comments can be posted.
Display Options Threshold/Breakthrough Mark All as Read Mark All as Unread
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
(1)
  • (Score: 3, Interesting) by bzipitidoo on Saturday December 14 2019, @02:45AM (2 children)

    by bzipitidoo (4388) on Saturday December 14 2019, @02:45AM (#931918) Journal

    A few years ago, I dug into the details of creating my own custom syntax highlighting for vim. It's like Apache configuration files. They're languages of their own.

    Then I totally changed the language I was trying to highlight :p.

    • (Score: 3, Insightful) by VLM on Saturday December 14 2019, @02:52PM (1 child)

      by VLM (445) on Saturday December 14 2019, @02:52PM (#932046)

      Well, different strokes for different folks, and I'm sure some people like it, and YOUR color scheme is likely stylish and tasteful, but my .vimrc has line like

      syntax off

      to try and kill syntax color highlighting because OTHER people's syntax color schemes are insane.

      Whomever decided git commit messages should be syntax highlighted to the palest possible yellow on blinding white background committed a crime against humanity on the level of systemd.

      • (Score: 0) by Anonymous Coward on Sunday December 15 2019, @01:02AM

        by Anonymous Coward on Sunday December 15 2019, @01:02AM (#932228)

        Yes!!! A thousand times, this!

        At work, a new guy took over most of the puppet duties, and decided to push out colorizing that only could be read on a black background. I had written all of our old rules, and the default was syntax off, dir colorizing off etc. because it is a sensible default that will be readable for everyone. We had a talk.

  • (Score: 2) by bart9h on Saturday December 14 2019, @02:48AM (1 child)

    by bart9h (767) on Saturday December 14 2019, @02:48AM (#931919)

    How easy will it be for NeoVim to merge these new features?

    I wonder which one will be more relevant in the future...

    I applaud the NeoVim effort, but I'm still sticking with the plain Vim that comes with my distro.

  • (Score: 1, Funny) by Anonymous Coward on Saturday December 14 2019, @03:18AM (2 children)

    by Anonymous Coward on Saturday December 14 2019, @03:18AM (#931928)

    For MS-Windows, download the self installing executable.
    Signed MS-Windows files will soon be available on the vim-win32-installer site

    What? Is not edlin good enough for any Windows user?

    • (Score: 2) by barbara hudson on Saturday December 14 2019, @11:04PM (1 child)

      by barbara hudson (6443) <barbara.Jane.hudson@icloud.com> on Saturday December 14 2019, @11:04PM (#932180) Journal

      What? Is not edlin good enough for any Windows user?

      COPY CON > FILENAME.TXT

      If you're going to go old-skule …

      --
      SoylentNews is social media. Says so right in the slogan. Soylentnews is people, not tech.
      • (Score: 2) by coolgopher on Sunday December 15 2019, @01:50AM

        by coolgopher (1157) on Sunday December 15 2019, @01:50AM (#932235)

        Honestly, I've used that a lot more than edlin!

        Edlin was about as much fun as writing assembler directly in debug.exe. Actually, less fun.

  • (Score: 2) by Mojibake Tengu on Saturday December 14 2019, @05:05AM (3 children)

    by Mojibake Tengu (8598) on Saturday December 14 2019, @05:05AM (#931955) Journal

    Thanks for vim, but... I use Emacs for coding. Since forever. Forever.
    And, dte as a system editor. https://github.com/craigbarnes/dte [github.com]. This one contains no backdoors. Unlike vim.

    --
    Respect Authorities. Know your social status. Woke responsibly.
    • (Score: 2) by coolgopher on Saturday December 14 2019, @06:47AM (2 children)

      by coolgopher (1157) on Saturday December 14 2019, @06:47AM (#931969)

      I too would be using emacs for coding, if I could've gotten it to build/install/run as a regular user on SunOS 2.6 back in the day. But I didn't (not in any reasonable time frame at least), so I learned vi instead.
      And when I had to edit text on a 286, I was very thankful I didn't have to wait for emacs to start, since even plain vi (not vim) took a few seconds to launch.

      • (Score: 3, Funny) by VLM on Saturday December 14 2019, @03:14PM (1 child)

        by VLM (445) on Saturday December 14 2019, @03:14PM (#932051)

        Its STILL kinda like that in that emacs has enough nifty addons for IDE/project oriented operations, that just flying off an editing a random line in a random file for 10 seconds is going to be much quicker in vim, but if you are going to be working on a dedicated project for an entire afternoon the higher efficiency of emacs will overall win. So like it or not I "have to" switch back and forth depending on what I'm doing.

        So if I'm deep in project #3 using projectile in emacs, the context switch to changing one line in project #7 for 10 seconds is just too high, fling up a vim for that 10 second task and back to "real work" on emacs.

        Even stranger using sublime text editor for some obscure microcontroller stuff like micropython. Most dedicated microcontroller IDE software is ridiculously weak like using desktop dev IDEs from the 90s, in 2020. STM32 has like a dozen competing IDEs, which is hilarious, although CubeIDE is pretty good. Confusingly its almost, but not quite, eclipse plus the stm32 eclipse plugin, but thats not entirely wrong. Still most microcontroller IDEs are more like the dreaded arduino IDE which unfortunately combines the lack of behind the scenes transparency of an IDE with the rich featureset of MS notepad.

        If someone in the 90s told me we'd all pretty much be using one webbrowser yet still be actively using at least a dozen incompatible different text/code editors, I'd have thought they were kidding...

        • (Score: 2) by coolgopher on Saturday December 14 2019, @03:33PM

          by coolgopher (1157) on Saturday December 14 2019, @03:33PM (#932057)

          like the dreaded arduino IDE which unfortunately combines the lack of behind the scenes transparency of an IDE with the rich featureset of MS notepad.

          Ahahahahahahahahaha!

          ...

          You're not wrong.

  • (Score: 5, Touché) by darkfeline on Saturday December 14 2019, @05:16AM (4 children)

    by darkfeline (1030) on Saturday December 14 2019, @05:16AM (#931959) Homepage

    Popup windows and text properties, features that Emacs has had for years. Maybe in a few more years Vim will finally be a poor implementation of Emacs, not unlike how all other languages become a poor implementation of Lisp.

    I say this as someone who uses Emacs, vi, and ed. I don't see what use case Vim is trying to fill, other than vi users pretending that they don't want the extensibility of Emacs.

    --
    Join the SDF Public Access UNIX System today!
    • (Score: 0) by Anonymous Coward on Saturday December 14 2019, @01:23PM

      by Anonymous Coward on Saturday December 14 2019, @01:23PM (#932029)

      I actively avoid vim these days, thankfully there's a bunch of nice vi implementations available. Text editing should change course in my opinion - back to the unix philosophy. Split up all those different components, and you won't need to invent new languages to let users make extensions because it will be trivial using whatever language they want.

    • (Score: 2) by VLM on Saturday December 14 2019, @03:04PM (2 children)

      by VLM (445) on Saturday December 14 2019, @03:04PM (#932050)

      vi is kinda dead to active development, whereas vim actually adds stuff.

      WRT features vim seems to top down add features that users want and the bottom will take care of itself. So people want "TRAMP mode" from emacs for vim, OK. So they want auto-line ending correction, OK.

      Meanwhile emacs seems to be bottom up, so we got a pretty good LISP with good text handing ability, now what nifty features can we build on top of that, and the top will take care of itself WRT end users will use what they like. So its technically possible to write in LISP a translator for file saving and loading that'll work over SSH/SCP and FTP... OK TRAMP mode is born and if the users like it, they'll use it, or if not, well, who cares emacs lisp is really cool anyway.

      So emacs is likely to innovate the coolest things whereas vim is most likely to implement the features discovered to be coolest. Kinda unix vs windows, in a way. Everything ever added to vim, has emacs users going "yeah I had that back in '91 nice they finally caught up to the civilized world".

      • (Score: 2) by DeVilla on Wednesday December 18 2019, @03:11AM (1 child)

        by DeVilla (5354) on Wednesday December 18 2019, @03:11AM (#933566)

        Vim screws you over when you think you're starting vi to edit a simple file and you try to paste text. Each line gets indented more than the next and if any line starts with a comment, vim decides you meant to comment all the remaining lines.

        And it has great color schemes to prevent you from accidentally reading the file you've opened.

        • (Score: 2) by VLM on Thursday December 19 2019, @08:06PM

          by VLM (445) on Thursday December 19 2019, @08:06PM (#934338)

          There are mystical incantations in my .vimrc that fix those problems but I'm not sure which lines do it.

  • (Score: 1, Funny) by Anonymous Coward on Saturday December 14 2019, @07:48AM (5 children)

    by Anonymous Coward on Saturday December 14 2019, @07:48AM (#931977)

    Methinks this is merely the calm before the vi-emacs storm, for indeed the seeds of a mighty vortex have been sowed. Bring it on. May last as long as the Red Spot on Jupiter, and for the same reasons. But let's leave Microsoft out of this, as they have always been, and still are.

    • (Score: 2) by maxwell demon on Saturday December 14 2019, @02:05PM (4 children)

      by maxwell demon (1608) on Saturday December 14 2019, @02:05PM (#932038) Journal

      Emacs has a vi emulation. Dies vi have an Emacs emulation?

      --
      The Tao of math: The numbers you can count are not the real numbers.
      • (Score: 4, Funny) by VLM on Saturday December 14 2019, @02:54PM (2 children)

        by VLM (445) on Saturday December 14 2019, @02:54PM (#932047)

        Just load up multiple 80 meg core files to slow vim down to emacs speeds and there you go.

        • (Score: 1, Interesting) by Anonymous Coward on Saturday December 14 2019, @05:47PM

          by Anonymous Coward on Saturday December 14 2019, @05:47PM (#932085)

          but vim will never have a way to call the elevator to the 8th floor

          http://www.classiccmp.org/pipermail/cctalk/2015-December/016024.html [classiccmp.org]

        • (Score: 2) by Pino P on Sunday December 15 2019, @12:16AM

          by Pino P (4721) on Sunday December 15 2019, @12:16AM (#932213) Journal

          Just load up multiple 80 meg core files

          We don't need to bring Atom (or other Electron-based editors) into this. Compared to Atom, Emacs is "eight megs and consistently smooth."

      • (Score: 0) by Anonymous Coward on Saturday December 14 2019, @06:58PM

        by Anonymous Coward on Saturday December 14 2019, @06:58PM (#932112)

        Haven't they been replaced by Systemdemacs yet?

(1)