Subject: RE: bug#41097: 28.0.50; (dired-toggle-marks) not working after copy

From: Drew Adams <[email-masked]>
Date: Sun, 10 May 2020 14:13:17 -0700 (PDT)

> > Words matter.  I gave a reason why I think
> > Emacs chose to use "flag" for `D' - and only
> > for `D':
> > to flag something is to draw special attention
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> > to it.
> 
> Your are rights that word matters. Then if I may ask, why is then
> "flag" introduced instead of "Delete mark"?

I said what I _think_ is the reason "flag" was
used for `D' (and ONLY for `D') - see above.

https://en.wiktionary.org/wiki/flag#Verb:

 "To mark with a flag, especially to indicate the
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^
  importance of something."
  ^^^^^^^^^^

Not just to indicate something - to point it out -
but to point it out as being of special importance.

In this sense, and especially when used in contrast
to "mark", it means to mark _specially_, i.e., more
than the way other Dired marks mark.

Emacs has always treated `D' _uniquely_, by giving
it a different term ("flag").  And my _hypothesis_
(which I expressed) is that this is because `D' can
cause problems - data loss - if you don't pay
special attention to it.  

I can't speak authoritatively about the reason this
was done - I didn't decide it.  It was done decades
ago.

> How "flag" makes the deleting action more clear? It does not, if you
> ask me.

Ask whomever wrote Dired and maintained it for 35
years.

It may not make "the deleting action" more clear,
especially to someone for whom English is not the
first language.  Both "mark" and "flag" point
something out - that's true.

But the fact that ONLY `D' is referred to as a
"flag", and only it (not `C' or any other mark)
is referred to as "flagging" the file for the
given action, should draw _special_ attention to
it  - should flag it (!) as being of particular
importance or meriting special attention.

Maybe this will help a bit (maybe not): the
English verb "flag" translates to French as
"signaler".  The verb "mark" translates as
"indiquer" or "marquer".  Now do you see the
difference?

They're related, but signaler is generally more
active, more important, more urgent.  Signaler
means you're really trying to get someone's
attention; you're not just indicating something.

> 2. (4) marker, marking, mark -- (a distinguishing symbol; "the owner's
> mark was on all the sheep")
> 
> flag on the other hand is not so clear. It does not provide definition
> for your intended action to draw special attention to it.

Yes, it does.  See above, or try another dictionary.

> In fact, marking something is drawing special attention to it
> already.

Yes, it's true that marking and flagging both
draw attention to something.  But "flag" is a
bit stronger, especially if both are used in
the same context (e.g. Dired), but for different
things, and especially if the thing "flag" is
used for (file deletion) is more serious.

In any case, your argument is not with me.  It's
not I who chose "flag".  My point is only that
that's what Emacs does and has always done, and
Emacs is quite consistent about it.

See my previous mail.  If someone (e.g. you)
proposed to use only "mark" and never "flag", that
would be OK.

What's not OK, IMO, is to use both, but not use
them in a consistent way.  After Eli's change, we
now have 2, and only 2, marks (`D' and `C') which
we are calling "flags".

It could be argued that there's something special
about deleting.  It's hard to argue that there's
something special about copying and deleting (as
opposed to renaming/moving and linking).

> So "flag" is for me less clear. Why should "flag" be used for
> "delete", why not "Delete" or "Mark delete"?

See above.

> Now note that the option "flag" is under the menu "Mark", so flag is a
> mark, it is adding to confusion.

It's in menu `Mark' because it is about marking,
in general - flagging is a kind of marking.  But
`Flag' is a separate menu item from `Mark'.

That item could have been called `Mark for
Deletion'.  But it wasn't.  Emacs consistently
uses "flag" for deletion - and only for deletion.

In the case of the `Mark' menu, that makes each
of the `Flag' items stand out from the `Mark'
items.  And rightfully so, as they all use `D'.
They're all for deleting files - something to
pay attention to.

Would you have preferred this?

 Mark
 Unmark
 Mark for Deletion
 Mark Auto-save Files for Deletion
 Mark Backup Files for Deletion
 Mark Garbage Files for Deletion
 Mark Executables
 Mark Old Backups
 Mark Directories
 Mark Symlinks
 Unmark All
 Change Marks...

That would have been OK, if a bit noisier and
less readable.  Again, I'm not the one who
decided such things (long, long ago).

> In my opinion, the Menu "Mark" should not have "flag", but rather
> "Delete" or "Delete mark":
> 
> - Delete auto-save files
> - Delete backup files
> - Delete garbage files
> - Delete by extension

Not good.  The action is NOT to delete
anything.  That's part of the point.  This
menu is only about marking various things
in various ways.  It makes no changes to
files or the file system.  The "flag" items
are about deleting, but deleting is not
their action.

> or
> 
> - Mark to delete auto-save files
> - Mark to delete backup files
> - Mark to delete garbage files
> - Mark to delete by extension
> 
> Those are clear to me in that sense.

OK.  Maybe file an enhancement request for
that.  I disagree that that's better, but
I'm just one (other) user. 

> Now these are not clear to me:
> 
> - Flag extension -- how that can be clear what it does? Sure that I
>   will find after some time what is meant, but I am saying, it is
>   confusing and not user friendly.
> 
> The Wordnet does not indicate that "flag" has the definition that you
> want, in the manner to distinguish it from "mark". It says "provide
> with a flag" and flag would be what?

See above.  It's English.  If it's not
understandable to some people then that's
not great.  But keep in mind that it is a
common verb, and Dired has used it this way
for decades (and Emacs has had lots of users
for whom English is not the first language).

> I will just put those definitions here down that could apply for some
> user...

I know what "flag" means.

> So to flag in the meaning to provide with a flag, the Wordnet
> definition gives me only that

Try another dictionary.  Ask (another) native
English speaker.

But the point is not that "flag" means what I
pointed out.  It's important that users can
understand what's meant.  So maybe someone
(else) will agree to make a _wholesale_ change
to all of the Dired descriptions, to never use
"flag".

Unless/until that happens, with Eli's change
we have now moved from something consistent to
something inconsistent.

> I am just saying is not so easy to understand
> with "flag".
> With "mark" it is very easy to understand it:
> 
> Now the definition you wanted to squeeze out of the "flag" to draw
> special attention to it, is actually under "mark" -- I speak only for
> Wordnet. ...
> 
> to flag vs. to mark, those are synonyms.

They are synonyms to some extent, in some
contexts.

Two different words are never completely
synonymous. There are always some different
connotations - nuances.

> It is only in Emacs terminology that "flag" became something extra,

No, it is not only in Emacs.  Please look
beyond Wordnet or, as I say, talk to another
native English speaker about it.

> however, it does not help the user to understand by reading from the
> menu that "flag" means "to mark for deletion".

I hear you.  Someone else can decide whether to
remove all use of "flag" from Dired because this
was unclear to you.  I have no problem with that,
even though I think it would be ill-advised.

What is not good is the inconsistency that was
just introduced.  But that's not the end of the
world - it's just one small step backward.