フィルターのクリア

How to remove/omit function from autocomplete?

7 ビュー (過去 30 日間)
Robert Kirkby
Robert Kirkby 2023 年 12 月 7 日
編集済み: Divyanshu 2023 年 12 月 18 日
I have a codebase/toolkit in Matlab that is intended for other users. Some functions are supposed to be user facing, and auto-complete in latest versions of Matlab works like a charm for these (really great, makes things much easier to use). But some functions are intended to be solely for internal use by the toolkit and not something the user would ever want to call directly.
Currently autocomplete lists/works for both the functions that are intended for the end user, and for the functions that are just for internal use by the toolkit. Is there any way I can indicate that a given function is internal and omit/remove it from appearing in autocomplete?
[I want to make the internal functions not appear to the user as that makes it less likely for the user to get confused/makes it more obvious to the user which functions they are wanting to call as the list in autocomplete is shorter and more relevant.]
  2 件のコメント
Walter Roberson
Walter Roberson 2023 年 12 月 7 日
Robert Kirkby
Robert Kirkby 2023 年 12 月 7 日
編集済み: Robert Kirkby 2023 年 12 月 7 日
I have not created/written JSON for any of my functions, Matlab's latest versions can autocomplete without it (doesn't know what variable types the inputs are, but it knows what the function is called, and what all the input names are and their order).

サインインしてコメントする。

回答 (1 件)

Divyanshu
Divyanshu 2023 年 12 月 18 日
編集済み: Divyanshu 2023 年 12 月 18 日
Hi Robert,
I understand that you are facing an issue where the internal functions of the toolkit are getting exposed to end users because of the autocompletion feature of MATLAB.
It is not possible to omit/remove few functions from this autocompletion. However a possible workaround is to turn off this autocompletion feature in MATLAB. Please follow these steps to do the same:
  • Go to the 'Home tab > Preferences'.
  • Click on the 'Editor/Debugger Section' in the left pane.
  • Next Go to 'Automatic Completions' and then under 'Suggestions and Completions' section.
  • Uncheck the options 'Show suggestions automatically' and 'Use tab to show suggestions'.
Hope it helps!

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

製品


リリース

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by