It took me quite a few minutes to figure out what the keyword is for controling the logarithmic scale of an axis. Of course, 'logscale' is pretty obvious. However, the keyword doesn't show up anywhere common, and 'help log' displays no list because 'log' is a keyword. However, shouldn't 'logscale' be in the following list?:
gnuplot> help lo Ambiguous request 'lo'; possible matches: load locale log lower
I just noticed another, 'timefmt' doesn't show up:
but
Is it that these have simply been overlooked in the gnuplot.doc file? Or is there something in the 'help' algorithm code that overlooks them because there is another keyword that is a precursor sub word of those longer keywords?
Beats me. Both 'timefmt' and 'logscale' are fully present in gnuplot.doc so far as I can see. So I guess the oddness is in the code rather than in the doc file.
It is probably this hunk of code in help.c that prints out the list:
That comment sort of explains why it is weeding out some ambiguous options, but I think the algorithm isn't quite matching the underlying logic. I haven't investigated, but I suspect that the "log", "logscale" test with strcspn comes out as "sublen" of 0 so that the next strncmp() indicates no difference. I don't think that is the proper thing to do. (BTW, given it is only comparing against the previous, I assume this list of keywords is first sorted alphabetically.)
Last edit: Dan Sebald 2016-02-01
I took a look at this a little while ago. Attached is a one line change where the length to the next whitespace is gotten from the current key, not the previous. I'm assuming these keys are first sorted so that the shorter key comes ahead of the longer key. I don't know quite what the thought was for the way it was programmed, but definitely don't want to rule out so many conceptually unique keys just because there is a key that is a pre-cursor. Perhaps the idea was to catch things like "find" and "find needle".
Anyway, here is the behavior prior to the patch:
and behavior after the patch:
OK. Let's try it. If people run into problems I guess we'll eventually hear about it.