Skip to content

Conversation

@sunwukonga
Copy link
Contributor

@sunwukonga sunwukonga commented Mar 3, 2020

Add main English file runtime/tutor/tutor02

  • Lesson 8.1 The Named Registers
  • Lesson 8.2 The Expression Register
  • Lesson 8.3 The Numbered Registers
  • Lesson 8.4 The Beauty of Marks
  • Lesson 8 Summary

Add copy of tutor02 at tutor02.utf-8
Add source file tutor02.vim

  • coordinates translations
  • coordinates source for tmp copy

Edit man page

  • add arguments
  • add Options
  • add Examples
  • trim description

Edit main script src/vimtutor

  • add --list option
  • add --gui option
  • add -h, --help options
  • add -c, --chapter options
  • add -l, --language switches
  • add validations for languages and chapters
  • aimed at POSIX compliance

Add main English file `runtime/tutor/tutor02`
 - Lesson 8.1 The Named Registers
 - Lesson 8.2 The Expression Register
 - Lesson 8.3 The Numbered Registers
 - Lesson 8.4 The Beauty of Marks
 - Lesson 8 Summary
Add copy of `tutor02` at `tutor02.utf-8`
Add source file `tutor02.vim`
 - coordinates translations
 - coordinates source for tmp copy
Edit man page
 - add arguments
 - add Options
 - add Examples
 - trim description
Edit main script `src/vimtutor`
 - add --list option
 - add --gui option
 - add -h, --help options
 - add -c, --chapter options
 - add -l, --language switches
 - add validations for languages and chapters
 - aimed at POSIX compliance
@sunwukonga
Copy link
Contributor Author

I made no attempt to modify vimtutor.bat to handle the second chapter. I could have copied to vimtutor2.bat and changed it trivially to work with chapter two; but... lipstick on a pig. It'll be better if someone familiar with dos bat files modifies vimtutor.bat to handle another cmdline argument.

 - Update publication date
 - Mention "The Vi Tutorial" by name
 - Clean description
 - Clean some prose
 - Fix some formatting mistakes
Update Chapter 02
 - Remove some unnecessary words
 - Change :r !date -> :r!date
@brammool
Copy link
Contributor

brammool commented Mar 4, 2020

Comments are welcome.

@nickspoons
Copy link
Contributor

Lesson 8.2 does not work in Windows, where date by itself will expect input. However system('date /t') works to just output the date (on Windows 10 at least)

@nickspoons
Copy link
Contributor

Lesson 8.3 includes a line that presumably should not be there, after point 5:

4. As each error is fixed press <ESC> to return to Normal mode

Also: NOTE: A whole line deletion stored in a named register is NOT also stored in the numbered registers. This is incorrect.

@sunwukonga
Copy link
Contributor Author

Lesson 8.2 does not work in Windows, where date by itself will expect input. However system('date /t') works to just output the date (on Windows 10 at least)

Any suggestions for a system agnostic alternative, or just a NOTE: specifying the Windows specific behaviour?

@sunwukonga
Copy link
Contributor Author

  1. As each error is fixed press to return to Normal mode
    [DELETING]

Also: NOTE: A whole line deletion stored in a named register is NOT also stored in the numbered registers. This is incorrect.
Oops. [DELETING]

@sunwukonga
Copy link
Contributor Author

Also: NOTE: A whole line deletion stored in a named register is NOT also stored in the numbered registers. This is incorrect.

I didn't test this, but I also didn't guess at it either, my misapprehension came from this sentence under :h quote0

Numbered register 1 contains the text deleted by the most recent delete or
change command, unless the command specified another register or the text is
less than one line (the small delete register is used then).

@nickspoons
Copy link
Contributor

Lesson 8.2 does not work in Windows, where date by itself will expect input. However system('date /t') works to just output the date (on Windows 10 at least)

Any suggestions for a system agnostic alternative, or just a NOTE: specifying the Windows specific behaviour?

I think making a NOTE: about the Windows behaviour would make sense. In this situtation users are presumably being exposed to Vim's integration with external tools for the first time, which will almost always require OS-specific tweaks. So a simple note to point out that system() and :r !... etc. are calling outside Vim seems like a good idea to me.

@sunwukonga
Copy link
Contributor Author

sunwukonga commented Mar 4, 2020

[Question] Should I change the lesson numbering from 8.1 to 2.1.1 i.e. chapter.lesson.part. It would no longer be consistent with the original vimtutor numbering, but it would allow for much more flexibility in the future if there are multiple mutable chapters going forward, or if a lesson 8 is added to vimtutor chapter 1.

EDIT: Just realized this causes some ugliness when doing the summary, i.e. Summary 2.1 looks strange. Propose direct numbering of lessons, i.e. Lesson 1.1, 1.2, ..., 2.1, 2.2 under chapter 2. Ergo, summary becomes simply Summary 1.

EDIT 'o EDIT: I'm still going back and forward on this. Should lesson and summary headings be globally unique (Lesson 2.1.1, Summary 2.1) or locally unique (Chapter 2 contains Lesson 1.1, Summary 1), OR globally unique but interdependent and inflexible (Chapter 2 contains Lesson 8.1, Summary 8).

EDIT 'o EDIT 'o EDIT: Went with the globally unique and flexible version.

Remove detritus from another lesson left in 8.3
Add system specific NOTE: in 8.2
Change lesson numbering system to `chapter.lesson.part`
@codecov-io
Copy link

Codecov Report

Merging #5729 into master will increase coverage by 0.05%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5729      +/-   ##
==========================================
+ Coverage   84.06%   84.11%   +0.05%     
==========================================
  Files         138      138              
  Lines      152376   152435      +59     
==========================================
+ Hits       128088   128225     +137     
+ Misses      24288    24210      -78
Impacted Files Coverage Δ
src/if_xcmdsrv.c 85.99% <0%> (-0.36%) ⬇️
src/gui_gtk_x11.c 58.06% <0%> (-0.25%) ⬇️
src/window.c 88.66% <0%> (-0.07%) ⬇️
src/term.c 81.34% <0%> (-0.06%) ⬇️
src/ops.c 89.65% <0%> (-0.05%) ⬇️
src/getchar.c 84.42% <0%> (-0.03%) ⬇️
src/if_python3.c 83.82% <0%> (ø) ⬆️
src/version.c 92.1% <0%> (ø) ⬆️
src/terminal.c 82.61% <0%> (+0.03%) ⬆️
src/gui.c 63.63% <0%> (+0.05%) ⬆️
... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5381c7a...3c47900. Read the comment docs.

@brammool
Copy link
Contributor

brammool commented Mar 5, 2020 via email

@sunwukonga
Copy link
Contributor Author

sunwukonga commented Mar 5, 2020

A higher level comment: Would it be possible to make multiple of these tutor parts, and have a menu to select which one to take?

Yes, the main tutor02 file could be spliced into sections along the lines of lesson parts with a generic version of each part (linux) and then any number of variations (Windows, Plan9, etc), I imagine most sections would only need the generic section as they wouldn't touch anything system related. E.g. [tutor02-1, tutor_win02-1, tutor_osx2-1, etc]. The tutor02.vim script could select the appropriate sections based on the environment, concatenate, and copy to the temp file. It's not my place to be opinionated on this, but overall I feel it might a bridge too far UNLESS there is a serious intent to introduce content that is heavy on system calls or scripting.

We could also have one for specific subjects, e.g. how to record and play back a macro.

I already have lessons planned for macros, is there a system environment dependency I'm ignorant of?

The user would first do the main tutor, and then gets a menu to select one of the advanced subjects. Keep in mind that the tutor is interactive and is intended to "get things in your fingers". Thus a section on writing Vim script is not a good idea.

I agree.

@brammool
Copy link
Contributor

brammool commented Jun 7, 2020

I guess we are not going to have several parts. Even the second chapter may not grow much.
Therefore, to keep things simple, I propose to add the sections to the existing vimtutor, and use a kind of separator in between the parts. It would say something like "now you know the basics, you can quit and start using Vim, or you can continue and learn about some more advanced features".
We can even add a list of subjects, telling the user to use a search command to jump there. Hmm, this might be difficult to find, and we don't want to put at it the top. We could put the index at the bottom, so "G" takes the user there.

About the man page: the list of options at the top is hard to read. Why not just add [options] and mention them in a table further down.

@sheerun
Copy link

sheerun commented Jul 3, 2020

How about embedding vimtutor within vim and introducing :tutor command? This command could be mentioned on welcome screen of vim (e.g. Type :tutor to see Vim tutorial)

@brammool
Copy link
Contributor

brammool commented Jul 3, 2020

Moving the tutor-specific stuff into Vim would avoid the shell script and batch file - that helps.
The extra code won't be much. So that looks like a good direction to go in.
It would still be good to start the tutor from the command line. how about "vim --tutor" ?

@vim-ml
Copy link

vim-ml commented Jul 3, 2020 via email

@yegappan yegappan added this to the backlog milestone Aug 14, 2023
@chrisbra
Copy link
Member

chrisbra commented Nov 3, 2024

I am including this. It's a bit sad, that the new vimtutor shell script is no longer portable, but requires bash (so I changed that). I also made a few further enhancements so that we do not need a separate tutor02.vim file and made vimtutor.bat on Windows aware of a seperate chapter.

I hope I didn't brake anything. Please check it.

@chrisbra chrisbra closed this in 17c71da Nov 3, 2024
@zzzyxwvut
Copy link
Contributor

Would you like a POSIX shell port of vimtutor?

diff --git a/src/vimtutor b/src/vimtutor
index 3faf100b4..6e29a7602 100755
--- a/src/vimtutor
+++ b/src/vimtutor
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/sh
 
 # Start Vim on a copy of the tutor file.
 
@@ -11,8 +11,7 @@
 
 # Vim could be called "vim" or "vi".  Also check for "vimN", for people who
 # have Vim installed with its version number.
-# We anticipate up to a future Vim 8.1 version :-).
-seq="vim vim81 vim80 vim8 vim74 vim73 vim72 vim71 vim70 vim7 vim6 vi"
+seq="vim vim91 vim90 vim81 vim80 vim8 vim74 vim73 vim72 vim71 vim70 vim7 vim6 vi"
 
 usage()
 {
@@ -31,94 +30,104 @@ usage()
 
 listOptions()
 {
-  declare -A language
-  language[bar]=Bavarian
-  language[bg]=Bulgarian
-  language[ca]=Catalan
-  language[cs]=Czech
-  language[da]=Danish
-  language[de]=German
-  language[el]=Greek
-  language[en]=English\(default\)
-  language[eo]=Esperanto
-  language[es]=Spanish
-  language[fr]=French
-  language[hr]=Croatian
-  language[hu]=Hungarian
-  language[it]=Italian
-  language[ja]=Japanese
-  language[ko]=Korean
-  language[lv]=Latvian
-  language[nb]=Bokmål
-  language[nl]=Dutch
-  language[no]=Norwegian
-  language[pl]=Polish
-  language[pt]=Portuguese
-  language[ru]=Russian
-  language[sk]=Slovak
-  language[sr]=Serbian
-  language[sv]=Swedish
-  language[tr]=Turkish
-  language[uk]=English
-  language[vi]=Vietnamese
-  language[zh]=Chinese
-
-  echo "==OPTIONS======================================================================================="
-  echo "Chapter: 1"
-  for code in bar bg ca cs da de el en eo es fr hr hu it ja ko lv nb nl no pl pt ru sk sr sv tr uk vi zh
-  do
-    printf "\tLang: %s => %s\n" ${code} ${language[${code}]}
-  done
-  echo "Chapter: 2"
-  for code in en
-  do
-    printf "\tLang: %s => %s\n" ${code} ${language[${code}]}
-  done
-  echo "================================================================================================"
+    echo "==OPTIONS======================================================================================="
+    echo "Chapter: 1"
+    printf "\tLang: %-3s => %s\n" \
+bar Bavarian \
+bg Bulgarian \
+ca Catalan \
+cs Czech \
+da Danish \
+de German \
+el Greek \
+en English\(default\) \
+eo Esperanto \
+es Spanish \
+fr French \
+hr Croatian \
+hu Hungarian \
+it Italian \
+ja Japanese \
+ko Korean \
+lv Latvian \
+nb Bokmål \
+nl Dutch \
+no Norwegian \
+pl Polish \
+pt Portuguese \
+ru Russian \
+sk Slovak \
+sr Serbian \
+sv Swedish \
+tr Turkish \
+uk English \
+vi Vietnamese \
+zh Chinese
+
+    echo "Chapter: 2"
+    printf "\tLang: %-3s => %s\n" \
+en English\(default\)
+    echo "================================================================================================"
 }
 
 validateLang()
 {
-  if [[ $xx =~ ^[^a-z]*$ ]]; then echo "Error: iso639 code must contain only [a-z]" && exit 1; fi
-  if [ ${#xx} == 2 ] || [ ${#xx} == 3 ]; then :; else echo "Error: iso639 code must be 2 or 3 characters only" && exit 1; fi
+  case "$xx" in
+    '' | *[!a-z]* )
+      echo "Error: iso639 code must contain only [a-z]"
+      exit 1
+  esac
+
+  case "${#xx}" in
+    [23] )
+      ;;
+    * )
+      echo "Error: iso639 code must be 2 or 3 characters only"
+      exit 1
+  esac
+
   export xx
 }
 
 validateChapter()
 {
-  if [[ $cc =~ ^[0-9]*$ ]]; then :; else echo "Error: chapter argument must contain digits only" && exit 1; fi
-  if [ $cc == "0" ]; then echo "Error: chapter must be non-zero" && exit 1; fi
-  if [ $cc == "00" ]; then echo "Error: chapter must be non-zero" && exit 1; fi
+  case "$cc" in
+    '' | *[!0-9]* )
+      echo "Error: chapter argument must contain digits only"
+      exit 1
+      ;;
+    0 | 00 )
+      echo "Error: chapter must be non-zero"
+      exit 1
+  esac
+
   export CHAPTER="$cc"
 }
 
-shopt -s extglob
 while [ "$1" != "" ]; do
-  case $1 in
+  case "$1" in
     -g | --gui )                    seq="gvim gvim91 gvim90 gvim81 gvim80 gvim8 gvim74 gvim73 gvim72 gvim71 gvim70 gvim7 gvim6 $seq"
                                     ;;
     -l | --language )               shift
-                                    xx=$1
+                                    xx="$1"
                                     validateLang
                                     ;;
-    -l[a-z][a-z]?([a-z]) )          xx=${1#*l}
-                                    validateLang
+    -l[a-z][a-z][a-z] | -l[a-z][a-z] )
+                                    export xx="${1#*l}"
                                     ;;
-    --language[a-z][a-z]?([a-z]) )  xx=${1#*e}
-                                    validateLang
+    --language[a-z][a-z][a-z] | --language[a-z][a-z] )
+                                    export xx="${1#*e}"
                                     ;;
-    [a-z][a-z]?([a-z]) )            xx=$1
-                                    validateLang
+    [a-z][a-z][a-z] | [a-z][a-z] )  export xx="$1"
                                     ;;
     -c | --chapter )                shift
-                                    cc=$1
+                                    cc="$1"
                                     validateChapter
                                     ;;
-    -c[0-9]?([0-9]) )               cc=${1#*c}
-                                    validateChapter
+    -c[1-9][0-9] | -c[1-9] )        export CHAPTER="${1#*c}"
                                     ;;
-    --chapter[0-9]?([0-9]) )        cc=${1#*r}
-                                    validateChapter
+    --chapter[1-9][0-9] | --chapter[1-9] )
+                                    export CHAPTER="${1#*r}"
                                     ;;
     -h | --help )                   usage
                                     exit
@@ -129,8 +138,8 @@ while [ "$1" != "" ]; do
     "" )                            ;;
     * )                             usage
                                     exit 1
-    esac
-    shift
+  esac
+  shift
 done
 
 
@@ -161,10 +170,10 @@ fi
 export TUTORCOPY
 
 # remove the copy of the tutor on exit
-trap "rm -rf $TODELETE" 0 1 2 3 9 11 13 15
+trap "rm -rf $TODELETE" EXIT HUP INT QUIT SEGV PIPE TERM
 
 for i in $seq; do
-    testvim=$(which $i 2>/dev/null)
+    testvim=$(command -v "$i" 2>/dev/null)
     if test -f "$testvim"; then
         VIM=$i
         break

@chrisbra
Copy link
Member

chrisbra commented Nov 4, 2024

@zzzyxwvut nice, thanks for this. I'll check it later today

@benknoble
Copy link
Contributor

shellcheck will also warn for non-POSIX-portable constructs if the shebang line starts uses sh

@zzzyxwvut
Copy link
Contributor

There will likely be other suggestions, let me draft a PR
then.

@zzzyxwvut
Copy link
Contributor

The patch is in the master branch. #15992 is a follow-up
PR draft.

ychin added a commit to macvim-dev/macvim that referenced this pull request Feb 20, 2025
Updated to Vim 9.1.1128

This update contains a completely new GUI tabs implementation by @sfsam!
It also contains lots of small fixes for window resizing and full screen
mode that aims to make using MacVim feel rock solid and stable.

Defaults Change
====================

New settings defaults related to window sizing #1528:

- "Smoothly resizes window" is now on by default. MacVim's window will
  now resize smoothly instead of snapped to the size of the character
  grid.
- Vim's `guioption` now has `k` set by default (`:h go-k`). This
  prevents MacVim's window size from changing unnecessarily when
  showing/hiding tabs or changing font size.

These should align MacVim better with how other apps work and integrate
better with OS window management, including macOS 15 Sequoia's window
tiling feature.

Features
====================

Tabs
--------------------

MacVim has a new tabs implementation! The old version (PSMTabBarControl)
is not maintained and lacks features such as overflowing tabs and
customizable colors. The new tabs will overflow horizontally and are
scrollable. They also animate when tabs are closed or moved, respect
system settings such as right-to-left locales and high-contrast modes,
and are designed to fit within the currently selected Vim colors.

There are a few ways to customize the colors of the new tabs, under the
"Appearance" settings pane. MacVim defaults to an "Automatic colors"
mode which tries to pick sensible colors automatically based on the
current foreground/background colors. However, you can also configure it
to simply use the tab colors specified by the Vim color scheme (some
color schemes will work better than others depending on their choice of
colors). Another new option is "Use tabs background color" which when
combined with "Transparent title bar" allows the title bar and tabs to
look like a single cohesive whole.

Relevant work:

- #1120 (by @sfsam)
- Also: #1535 / #1536 / #1537 / #1538 / #1539 / #1557 / #1558 / #1560

New Vim features
--------------------

- new bundled color scheme:
    - unokai (vim/vim#16443)
- new bundled optional plugins (use `packadd` to enable them):
    - helptoc: Use `:HelpToc` to show an interactive table of contents
      for Vim help, man pages, Markdown files, and terminal.
      vim/vim#10446
- new options:
    - `set diffopt+=linematch:{n}`. Matches lines better when in diff
      mode. v9.1.1099
    - `findfunc`. Customizes `:find` and other commands. v9.1.0831
    - `set completeopt+=preinsert`. Preview inserted text in completion.
      v9.1.1056
    - `messagesopt`. Allows customizing hit-enter behavior. v9.1.0908
- new functions:
    - `getcellpixels()`. Query the pixel size of a character cell in the
      grid. v9.1.0854 / #1554 / #1555
- Vim tutor has a new interactive plugin (v9.1.0836). There is also now
  a chapter 2 (vim/vim#5729).

Misc New Settings
--------------------

- "Open untitled window" (General) has a new option to only open on
  MacVim re-activation. #1509
- "Show document icon at title bar" (Appearance). Previously MacVim
  implicitly hid the document icon when using transparent title bar.
  This is now customizable. #1510

General
====================

- The MacVim dmg installer has a new design. Courtesy of @jasonlong.
  #1540 #1545
- Legacy builds (macOS 10.9 - 10.12) are no longer built by GitHub
  hosted runners, due to GitHub's deprecation of old runners. They are
  now built by a custom self-hosted VM instead. In the future we hope to
  set up reproducible builds (#1506) so it will not matter who's
  building the app as it would be verifiable. #1559
- "Nightly" build: We now build a dmg installer for every commit. This
  allows for trying out the latest developmental version of MacVim, but
  note that the app will not be signed / notarized, and it will not be
  as polished as official release/pre-release builds. See
  [wiki](https://github.com/macvim-dev/macvim/wiki/Installing) for
  instructions. #1532

Fixes
====================

Apple "Intelligence" Writing Tools
--------------------

macOS 15 Sequoia's Apple "Intelligence" Writing Tools should work
correctly with MacVim now. To use it, select some text, right click to
show menu, and then select the "Writing Tools" sub-menu. As part of this
fix, the integration with the "Services" menu now works more reliably as
well. You can select texts in blockwise visual mode and select a service
and MacVim will try to place the new texts back to the blockwise
selection if possible. #1552

Window resizing and full screen
--------------------

- Flicker begone: Changing font size, showing/hiding tabs or scroll
  bars, or entering non-native full screen should no longer cause MacVim
  to flicker. Previously there could be a momentary but
  distracting/annoying stale image that flashes briefly. #1547 #1549
- Fixed issue where resizing MacVim window would occasionally cause Vim
  to be stuck in a stale wrong size. #1518
- Non-native full screen now supports `blurradius` option. #1546
- Fixed window size not always restoring correctly when exiting full
  screen. Non-native full screen also works more reliably in
  multi-monitor setup. #1525
- Fixed non-native full screen mode when using an external monitor with
  a MacBook with a notch, and having the "Show menu bar in non-native
  mode" option set. Previously MacVim would sometimes miscalculate the
  menu bar height in the second screen. #1548
- Fixed misc issues with non-native full screen's interaction with
  `fuoptions` and also the `transparency` setting, and rare crash. #1521

Other Fixes
--------------------

- Fixed issue where changing font size (using Cmd =/-) with guifont set
  to "-monospace-" would result in guifont being changed to a confusing
  name like ".AppleSystemUIFontMonospaced-Regular". #1544
- "MacVim Website" menu item now goes to the updated URL. #1524
- What's New page now allows changing font size (using Cmd =/-), and
  showing table of contents. #1561 #1562
- Dark mode documentation is now a bit clearer on `v:os_appearance`.
  #1511
- Using dictionary look up on selected texts (by right clicking and then
  selecting "Look Up" in the pop-up menu) is now more resilient as it
  uses Vim's native `getregion()` to determine the selected texts. #1508

Scripting
====================

- Scripting languages versions:
    - Ruby is now built against 3.4, up from 3.3.
    - Perl is now built against 5.34, up from 5.30.

Compatibility
====================

Requires macOS 10.9 or above. (10.9 - 10.12 requires downloading a
separate legacy build)

Script interfaces have compatibility with these versions:

- Lua 5.4
- Perl 5.34
- Python2 2.7
- Python3 3.9 or above
- Ruby 3.4
ychin added a commit to macvim-dev/macvim that referenced this pull request Feb 21, 2025
Updated to Vim 9.1.1128

This update contains a completely new GUI tabs implementation by @sfsam!
It also contains lots of small fixes for window resizing and full screen
mode that aims to make using MacVim feel rock solid and stable.

Defaults Change
====================

New settings defaults related to window sizing #1528:

- "Smoothly resizes window" is now on by default. MacVim's window will
  now resize smoothly instead of snapped to the size of the character
  grid.
- Vim's `guioption` now has `k` set by default (`:h go-k`). This
  prevents MacVim's window size from changing unnecessarily when
  showing/hiding tabs or changing font size.

These should align MacVim better with how other apps work and integrate
better with OS window management, including macOS 15 Sequoia's window
tiling feature.

Features
====================

Tabs
--------------------

MacVim has a new tabs implementation! The old version (PSMTabBarControl)
is not maintained and lacks features such as overflowing tabs and
customizable colors. The new tabs will overflow horizontally and are
scrollable. They also animate when tabs are closed or moved, respect
system settings such as right-to-left locales and high-contrast modes,
and are designed to fit within the currently selected Vim colors.

There are a few ways to customize the colors of the new tabs, under the
"Appearance" settings pane. MacVim defaults to an "Automatic colors"
mode which tries to pick sensible colors automatically based on the
current foreground/background colors. However, you can also configure it
to simply use the tab colors specified by the Vim color scheme (some
color schemes will work better than others depending on their choice of
colors). Another new option is "Use tabs background color" which when
combined with "Transparent title bar" allows the title bar and tabs to
look like a single cohesive whole.

Relevant work:

- #1120 (by @sfsam)
- Also: #1535 / #1536 / #1537 / #1538 / #1539 / #1557 / #1558 / #1560

New Vim features
--------------------

- new bundled color scheme:
    - unokai (vim/vim#16443)
- new bundled optional plugins (use `packadd` to enable them):
    - helptoc: Use `:HelpToc` to show an interactive table of contents
      for Vim help, man pages, Markdown files, and terminal.
      vim/vim#10446
- new options:
    - `set diffopt+=linematch:{n}`. Matches lines better when in diff
      mode. v9.1.1099
    - `findfunc`. Customizes `:find` and other commands. v9.1.0831
    - `set completeopt+=preinsert`. Preview inserted text in completion.
      v9.1.1056
    - `messagesopt`. Allows customizing hit-enter behavior. v9.1.0908
- new functions:
    - `getcellpixels()`. Query the pixel size of a character cell in the
      grid. v9.1.0854 / #1554 / #1555
- Vim tutor has a new interactive plugin (v9.1.0836). There is also now
  a chapter 2 (vim/vim#5729).

Misc New Settings
--------------------

- "Open untitled window" (General) has a new option to only open on
  MacVim re-activation. #1509
- "Show document icon at title bar" (Appearance). Previously MacVim
  implicitly hid the document icon when using transparent title bar.
  This is now customizable. #1510

General
====================

- The MacVim dmg installer has a new design. Courtesy of @jasonlong.
  #1540 #1545
- Legacy builds (macOS 10.9 - 10.12) are no longer built by GitHub
  hosted runners, due to GitHub's deprecation of old runners. They are
  now built by a custom self-hosted VM instead. In the future we hope to
  set up reproducible builds (#1506) so it will not matter who's
  building the app as it would be verifiable. #1559
- "Nightly" build: We now build a dmg installer for every commit. This
  allows for trying out the latest developmental version of MacVim, but
  note that the app will not be signed / notarized, and it will not be
  as polished as official release/pre-release builds. See
  [wiki](https://github.com/macvim-dev/macvim/wiki/Installing) for
  instructions. #1532

Fixes
====================

Apple "Intelligence" Writing Tools
--------------------

macOS 15 Sequoia's Apple "Intelligence" Writing Tools should work
correctly with MacVim now. To use it, select some text, right click to
show menu, and then select the "Writing Tools" sub-menu. As part of this
fix, the integration with the "Services" menu now works more reliably as
well. You can select texts in blockwise visual mode and select a service
and MacVim will try to place the new texts back to the blockwise
selection if possible. #1552

Window resizing and full screen
--------------------

- Flicker begone: Changing font size, showing/hiding tabs or scroll
  bars, or entering non-native full screen should no longer cause MacVim
  to flicker. Previously there could be a momentary but
  distracting/annoying stale image that flashes briefly. #1547 #1549
- Fixed issue where resizing MacVim window would occasionally cause Vim
  to be stuck in a stale wrong size. #1518
- Non-native full screen now supports `blurradius` option. #1546
- Fixed window size not always restoring correctly when exiting full
  screen. Non-native full screen also works more reliably in
  multi-monitor setup. #1525
- Fixed non-native full screen mode when using an external monitor with
  a MacBook with a notch, and having the "Show menu bar in non-native
  mode" option set. Previously MacVim would sometimes miscalculate the
  menu bar height in the second screen. #1548
- Fixed misc issues with non-native full screen's interaction with
  `fuoptions` and also the `transparency` setting, and rare crash. #1521

Other Fixes
--------------------

- Fixed issue where changing font size (using Cmd =/-) with guifont set
  to "-monospace-" would result in guifont being changed to a confusing
  name like ".AppleSystemUIFontMonospaced-Regular". #1544
- "MacVim Website" menu item now goes to the updated URL. #1524
- What's New page now allows changing font size (using Cmd =/-), and
  showing table of contents. #1561 #1562
- Dark mode documentation is now a bit clearer on `v:os_appearance`.
  #1511
- Using dictionary look up on selected texts (by right clicking and then
  selecting "Look Up" in the pop-up menu) is now more resilient as it
  uses Vim's native `getregion()` to determine the selected texts. #1508

Scripting
====================

- Scripting languages versions:
    - Ruby is now built against 3.4, up from 3.3.
    - Perl is now built against 5.34, up from 5.30.

Compatibility
====================

Requires macOS 10.9 or above. (10.9 - 10.12 requires downloading a
separate legacy build)

Script interfaces have compatibility with these versions:

- Lua 5.4
- Perl 5.34
- Python2 2.7
- Python3 3.9 or above
- Ruby 3.4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants