[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v5] Enable xwidgets on macOS
From: |
조성빈 |
Subject: |
Re: [PATCH v5] Enable xwidgets on macOS |
Date: |
Sat, 3 Aug 2019 19:52:39 +0900 |
2019. 8. 3. 오후 7:03, Eli Zaretskii <address@hidden> 작성:
>> From: 조성빈 <address@hidden>
>> Date: Tue, 30 Jul 2019 02:08:40 +0900
>> Cc: address@hidden,
>> address@hidden
>>
>>>>>> +(defun xwidget-webkit-save-as-file (url mime-type file-name)
>>>>>> + "For XWIDGET webkit, save URL of MIME-TYPE to location specified by
>>>>>> user.
>>>>>> +FILE-NAME combined with `xwidget-webkit-download-dir' is the default
>>>>>> file name
>>>>>> +of the prompt when reading. When the file name the user specified is a
>>>>>> +directory, URL is saved at the specified directory as FILE-NAME."
>>>>>
>>>>> The last sentence is unclear: what will be the directory where the URL
>>>>> will be saved, and what will be the name of the saved file in that
>>>>> directory?
>>>>
>>>> Well, it was meaning that the URL will be saved at the directory the user
>>>> specified in the prompt with the name FILE-NAME.
>>>>
>>>> I’m not sure how I should reword it due to my poor English skills; can
>>>> you give me some suggestions?
>>>
>>> If you show me an example of using this command, and the results -- in
>>> what directory and under what base name will the URL be saved -- then
>>> I will be able to suggest a better wording.
>>
>> Sorry for the delay; I was busy for a few days that I couldn't open my
>> mailbox.
>>
>> Well, while I was trying to give examples, I think I wrote a clearer version
>> of the docstring:
>> "Save URL of MIME-TYPE as file specified by user.
>> When the user specifies a directory, URL is saved with the name FILE-NAME in
>> the
>> specified directory. The default file name when reading is FILE-NAME
>> expanded
>> with `xwidget-webkit-download-dir'."
>>
>> May I ask if this is more clear than before?
>
> I don't think I understand what happens well enough yet. The command
> asks for FILE-NAME, right?
It’s not an interactive command, more of an helper function.
FILE-NAME isn’t provided by the user; it’s provided by the internal callsite.
Maybe embedding the logic instead of making a separate function (which the
original patch did) might be better?
> So when the FILE-NAME provided by the user
> is actually a directory, the URL will be saved in the directory named
> FILE-NAME, but under what basename?
If the user provided directory (which has no relationship with FILE-NAME and is
read by the `read-file-name' call inside the function) is a directory, the
basename becomes FILE-NAME. The function assumes FILE-NAME provided by the
callsite is not a directory.