[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] defcustom ':size'
In [emacs-w3m : No.12710]
On Sun, 25 Jun 2017 10:28:12 -0400, Boruch Baum wrote:
> On 2017-06-23 10:00, Katsumi Yamaoka wrote:
>>> +(defcustom w3m-external-view-temp-directory
>>> + w3m-profile-directory
>>> + "*Directory where files are saved for the external file viewer."
>>> + :group 'w3m
>>> + :type '(directory :size 0))
>> I removed "*" and the `:size 0' portion. Though I don't recall
>> clearly why I added `:size 0' to defcustoms in the past, it
>> might have been useful for old Emacsen (or XEmacs?; I used to be
>> an XEmacs user). However, I find no particular advantage with
>> it now. If anything, this makes a user be hard to find the
>> place of the input form if the value is an empty string. So,
>> I'd like to remove all such ones some day.
> I couldn't find any documentation for the ":size" option,
,---- (info "(editable-field)Widget") <- Type `C-x C-e' here
| `:size'
| The width of the editable field.
| By default the field will reach to the end of the line.
`----
If the :size is specified, the width of the editable field will
be extended if a user writes something longer than the specified
width. So, always only the value is highlighted if :size is 0.
If the :size is not specified, the highlighted field always ends
at the window edge. It's often too long and I felt it unsightly.
The only problem of `:size 0' is that the editable field will
disappear if it is empty.
> so here's a
> patch to remove all ocurrences of it, if that's okay. The work was
> done using 'sed -i 's/[ \t]\+:size [0-9]\+//' *.el'. As for updating
> the Changelog, 'grep ":size" *.el |wc -l' indicated to me 152
> instances in many files, so I took a lazy route which I hope is
> acceptable in this unusual case.
Thank you for listing them all up.