- the quoted string is the first expression (possibly after whitespace) after the beginning of the line, or after a comma (",") or semi-colon (";") that marks the end of anything previous on the line
- the quoted string immediately follows (no whitespace) a non-quoted underscore ('_') or period ('.')
- the quoted string immediately follows (no whitespace) a latin letter or latin digit
Why does tab complete not work for user written functions that except filenames?
1 次查看(过去 30 天)
显示 更早的评论
Why does tab complete not work for user written functions that except filenames?
function testFunction(file)
disp(file)
end %end function
Call the above function with a file. While entering the file name, try to tab complete it. It won't work. Why not?
0 个评论
采纳的回答
Walter Roberson
2013-8-14
编辑:Walter Roberson
2013-8-14
The rules for tab completion are not well defined, and do not always make sense.
Tab completion for a quoted string takes place if:
In addition, there are circumstances under which a quoted string that follows an exclamation mark ('!') may lead to a flawed tab completion, in which the resulting word is missing one or more characters from the file name.
None of the above situations match attempting to enter a valid quoted string as the argument to a function. :(
2 个评论
更多回答(1 个)
David Sanchez
2013-8-14
The user defined function has to be saved on the current directory or its path set on matlab paths. Matlab will not autocomplete a function name of a function located in a directory different to the working directory.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Environment and Settings 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!