ghisler(Author) wrote:Even the AI has clearly understood that %Q prevents the addition of double quotes, it doesn't remove them.
I've already made it clear why you shouldn't trust AI. I have provided a link to my request, where
suppression, not prevention, is stated directly in the title.
In other words, the current implementation does not fully satisfy the purpose of my suggestion.
ghisler(Author) wrote:It even gave an example where the user entered em_test "bla bla" manually, with the double quotes.
You know that this user is me. And with this example, I made it clear that there is no direct connection here with %N or a similar parameter, i.e., it can also be a matter of manually specifying quotation marks. The AI is not unable of correctly assessing the context here; it lacks the depth of analysis of the hidden details of the initial goal setting. It considers the extracted text superficially.
ghisler(Author) wrote:Here, %A now contains the string with the double quotes, and using %A does not magically remove these double quotes.
This should be done by %Q in front of it, not by %A.
Let's look at the logic of the suppression (not prevention) I requested:
Parameter where quotes for spaces are added
automatically → parameter that suppresses quotes before it → result: returned text without quotes
Parameter where quotes for spaces are added
manually → parameter that suppresses quotes before it -> result: returned text without quotes
That is, the difference here is only in the words "automatically" and "manually". What's the point of complicating a program's algorithm by checking for automation, which does more harm than good? Wasn't it logical to do it this way initially?" →
Parameter where quotes for spaces are added
automatically or manually → parameter that suppresses quotes before it → result: returned text without quotes
This would immediately give the desired result, and we wouldn’t have to return to this task now.
white wrote:But the compatibility issue is of course when %Q is already being used in combination with %A (and other placeholders). A parameter can be anything and people may need the quotes being there. ... When %Q starts removing quotes, their commands will stop working correctly.
You've fallen into theory again. These are all purely hypothetical things that you, I'm sure, will not find in practice anywhere or from anyone. You are trying to dig in a very solid place where the shovel rests against common sense.
The very need to suppress quotes for %An is related to the command syntax of other programs, where double quotes are needed only to enclose the entire entry. This was reflected in the examples of the original post of my proposal. I don't see any practical logic in the fact that, with such syntax, it's necessary to keep double quotes for parameters located, for example, after "%Q'%A1' %A2' %A3'".
However, I have already raised the issue of applying %Q only to the conjugate parameter (like %X) or adding one that would stop its action. Nothing has been done so far.
white wrote:And people may be stripping the quotes themselves by removing first and last character (because their parameter is always quoted and unwanted).
Unfortunately, I cannot assess the depth of this thought without a working example.
white wrote:It's not clear if he thinks the Help text then needs to be adjusted as well, and to what.
I would insist that the word "automatic" be removed from there after bringing the work into proper form.
As a last resort, it could be %q, which does what is required. But only in the current version, so as not to wait a long time for such em commands to finally work.
white wrote:It is also not clear whether he feels this new stripping behavior should apply only to %A, or to all placeholders and possibly environment variables.
%|EnVar|? This would be logical, although much less in demand.
Please return the topic to the original section.