On 25/02/2022 21:19, Visuwesh wrote:
Currently, when asking the user for the description of link,
`org-insert-link' calls `read-string' with a non-nil INITIAL-INPUT but
this argument is discouraged and deprecated; moreover, it is unfriendly.
`org-insert-link' should, ideally, use the DEFAULT argument. If the
user decides that the suggested description is okay, they can type M-n.
Due to lack of experience with emacs I can miss something. If so,
please, correct me.
Are you suggesting replacing
(read-string "rs-initial: " "Some initial")
by
(read-string "rs-default: " nil nil "Some default")
? Is it possible to override provided default description by empty
string in the latter variant? Currently it is possible to erase
description using just backspace or C-S-backspace.
P.S. Many GUI applications pre-select whole value when some input field
is focused, so it is possible to overwrite current value by typing
anything. It may be convenient but is not consistent with emacs
behavior. Moreover it makes uncertain if visually selected text
overwrites X PRIMARY selection.