[vim/vim] Distinguish between zg and zG, and zw and zW (#6140)

28 views
Skip to first unread message

Ned Batchelder

unread,
May 25, 2020, 8:30:23 AM5/25/20
to vim/vim, Subscribed

You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/6140

Commit Summary

  • Distinguish between zg and zG, and zw and zW

File Changes

Patch Links:


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Gary Johnson

unread,
May 25, 2020, 1:42:42 PM5/25/20
to reply+ACY5DGB4GDXUZ2QNER...@reply.github.com, vim...@googlegroups.com
On 2020-05-25, Ned Batchelder wrote:
> -------------------------------------------------------------------------------
>
> You can view, comment on, or merge this pull request online at:
>
> https://github.com/vim/vim/pull/6140
>
> Commit Summary
>
> • Distinguish between zg and zG, and zw and zW
>
> File Changes
>
> • M runtime/doc/index.txt (4)
>
> Patch Links:
>
> • https://github.com/vim/vim/pull/6140.patch
> • https://github.com/vim/vim/pull/6140.diff

> diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt
> index 78d557f51ef..0fa774cd656 100644
> --- a/runtime/doc/index.txt
> +++ b/runtime/doc/index.txt
> @@ -828,7 +828,7 @@ tag char note action in Normal mode ~
> |zD| zD delete folds recursively
> |zE| zE eliminate all folds
> |zF| zF create a fold for N lines
> -|zG| zG mark word as good spelled word
> +|zG| zG internally mark word as good spelled word
> |zH| zH when 'wrap' off scroll half a screenwidth
> to the right
> |zL| zL when 'wrap' off scroll half a screenwidth
> @@ -837,7 +837,7 @@ tag char note action in Normal mode ~
> |zN| zN set 'foldenable'
> |zO| zO open folds recursively
> |zR| zR set 'foldlevel' to the deepest fold
> -|zW| zW mark word as wrong (bad) spelled word
> +|zW| zW internally mark word as bad spelled word
> |zX| zX re-apply 'foldlevel'
> |z^| z^ cursor on line N (default line above
> window), otherwise like "z-"

I don't think "internally" conveys the distinction very clearly.
How about "temporarily"? Or even "for this session only", at the
expense of extra lines?

zG zG mark word as good spelled word for this
session only

zW zW mark word as wrong (bad) spelled word for
this session only

zg zg mark word as good spelled word and save

zw zw mark word as wrong (bad) spelled word and
save

Regards,
Gary

vim-dev ML

unread,
May 25, 2020, 1:43:00 PM5/25/20
to vim/vim, vim-dev ML, Your activity

On 2020-05-25, Ned Batchelder wrote:
> -------------------------------------------------------------------------------
>
> You can view, comment on, or merge this pull request online at:
>
> https://github.com/vim/vim/pull/6140
>
> Commit Summary
>
> • Distinguish between zg and zG, and zw and zW
>
> File Changes
>
> • M runtime/doc/index.txt (4)
>
> Patch Links:
>
> • https://github.com/vim/vim/pull/6140.patch
> • https://github.com/vim/vim/pull/6140.diff

Ned Batchelder

unread,
May 25, 2020, 2:10:40 PM5/25/20
to vim/vim, vim-dev ML, Comment

I wasn't proposing to change the terminology. The help for zG says, "Like "zg" but add the word to the internal word list." My goal here was to differentiate the index entries for zg and zG, which now are identical.

I'm fine with some other wording.


You are receiving this because you commented.

Christian Brabandt

unread,
May 26, 2020, 2:24:18 AM5/26/20
to vim/vim, vim-dev ML, Comment

How about:

diff --git a/runtime/doc/index.txt b/runtime/doc/index.txt
index 78d557f51..dded70d32 100644
--- a/runtime/doc/index.txt
+++ b/runtime/doc/index.txt
@@ -828,7 +828,7 @@ tag         char          note action in Normal mode        ~
 |zD|           zD                 delete folds recursively
 |zE|           zE                 eliminate all folds
 |zF|           zF                 create a fold for N lines
-|zG|           zG                 mark word as good spelled word
+|zG|           zG                 temporarily mark word as good spelled word
 |zH|           zH                 when 'wrap' off scroll half a screenwidth
                                   to the right
 |zL|           zL                 when 'wrap' off scroll half a screenwidth
@@ -837,7 +837,7 @@ tag         char          note action in Normal mode        ~
 |zN|           zN                 set 'foldenable'
 |zO|           zO                 open folds recursively
 |zR|           zR                 set 'foldlevel' to the deepest fold
-|zW|           zW                 mark word as wrong (bad) spelled word
+|zW|           zW                 temporarily mark word as bad spelled word
 |zX|           zX                 re-apply 'foldlevel'
 |z^|           z^                 cursor on line N (default line above
                                   window), otherwise like "z-"
@@ -849,7 +849,7 @@ tag         char          note action in Normal mode        ~
                                   position the cursor at the end (right side)
                                   of the screen
 |zf|           zf{motion}         create a fold for Nmove text
-|zg|           zg                 mark word as good spelled word
+|zg|           zg                 permanently mark word as good spelled word
 |zh|           zh                 when 'wrap' off scroll screen N characters
                                   to the right
 |zi|           zi                 toggle 'foldenable'
@@ -870,7 +870,7 @@ tag         char          note action in Normal mode        ~
 |zuW|          zuW                undo |zW|
 |zuG|          zuG                undo |zG|
 |zv|           zv                 open enough folds to view the cursor line
-|zw|           zw                 mark word as wrong (bad) spelled word
+|zw|           zw                 permanently mark word as bad spelled word
 |zx|           zx                 re-apply 'foldlevel' and do "zv"
 |zz|           zz                 redraw, cursor line at center of window
 |z<Left>|      z<Left>            same as "zh"


You are receiving this because you commented.

Gary Johnson

unread,
May 26, 2020, 2:46:20 AM5/26/20
to reply+ACY5DGDWQ7Y27Y5R5X...@reply.github.com, vim...@googlegroups.com
I like it.

Regards,
Gary

vim-dev ML

unread,
May 26, 2020, 2:46:41 AM5/26/20
to vim/vim, vim-dev ML, Your activity

Bram Moolenaar

unread,
May 26, 2020, 2:26:38 PM5/26/20
to vim/vim, vim-dev ML, Comment

I'll include Christians suggestion.


You are receiving this because you commented.

Bram Moolenaar

unread,
May 26, 2020, 2:26:40 PM5/26/20
to vim/vim, vim-dev ML, Comment

Closed #6140.


You are receiving this because you commented.

Charles Campbell

unread,
May 26, 2020, 5:09:48 PM5/26/20
to vim...@googlegroups.com
As a minor point, it would be better english if it was "mark word as
correctly spelled word" or "mark word as incorrectly spelled word".

Chip Campbell

Bram Moolenaar

unread,
May 27, 2020, 5:19:29 PM5/27/20
to vim...@googlegroups.com, Charles Campbell
It's a bit long, but we can avoid that by dropping "word" at the end.

--
Some of the well known MS-Windows errors:
ESLEEP Operator fell asleep
ENOERR No error yet
EDOLLAR OS too expensive
EWINDOWS MS-Windows loaded, system in danger

/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
Reply all
Reply to author
Forward
0 new messages