# How do I add the infobutton in autocomplete that links to the documentation page for package functions?

When typing the name of a built-in function like Integrate, the button (ℹ︎) appears next to that name in the autocomplete:

But I don't get that (ℹ︎) button for my package functions, even though I have a help page for it that was made with Wolfram Workbench:

How do I add the info button to the autocompletion menu that links to the relevant documentation page for my package functions?

• Something of interest (maybe?). JLink stuff has that but some built in packages e.g. GeneralUtilities do not. And it's not just that documented things have it, since I've definitely clicked the button and gotten a blank search page. E.g. ExportPacket has it but pops up nothing. – b3m2a1 Jul 19 '17 at 5:15
• Look at FileNameJoin@{$InstallationDirectory, "SystemFiles", "Components", "AutoCompletionData", "Main", "documentedContexts.m"}. I found that via TextSearch for "JLink" in the AutoCompletionData directory. Editing it allowed me to add the i for my own package (only works where there are searchable docs I think) but I couldn't get it to work a la specialArgFunctions.tr -- i.e. editable in my own package, not the file itself. – b3m2a1 Jul 19 '17 at 5:46 ## 1 Answer So I mentioned this in a comment but I'll get it out here for the bounty poster too. Searching for the "JLink" in the autocomplete directory gave me this: FileNameJoin@{$InstallationDirectory, "SystemFiles", "Components", "AutoCompletionData", "Main", "documentedContexts.m"}


If we look at what's inside it:

FileNameJoin@{$InstallationDirectory, "SystemFiles", "Components", "AutoCompletionData", "Main", "documentedContexts.m"} // Import // NewlineateInput { "System", "ANOVA", "BlackBodyRadiation", "Compatibility", "ComputerArithmetic", "DatabaseLink", "EquationTrekker", "FiniteFields", "JLink", "NETLink", "CUDALink", "OpenCLLink", "TetGenLink", "RLink", "CCodeGenerator", "SymbolicC", "NonlinearRegression", "PhysicalConstants", "PolyhedronOperations", "Quaternions", "ResonanceAbsorptionLines", "StandardAtmosphere", "VariationalMethods", "LibraryLink", "CCompilerDriver", "Audio", "FunctionApproximations", "GUIKit", "HierarchicalClustering", "HypothesisTesting", "MultivariateStatistics", "Music", "Notation", "NumericalDifferentialEquationAnalysis", "StatisticalPlots" }  I'll add something: FileNameJoin@{$InstallationDirectory, "SystemFiles", "Components",
"AutoCompletionData", "Main", "documentedContexts.m"} //
Import // Last

"ChemTools"


and we can see the i appears on reload:

Haven't figured out how to set this at the paclet level though, or even in $UserBaseDirectory. Note that this is for 11 For 10 it seems the file is FileNameJoin@{$InstallationDirectory, "SystemFiles", "FrontEnd",
"SystemResources", "FunctionalFrequency", "documentedContexts.m"}


Another cool file seems to be obsoleteFunctions.m which turns out to be a list of names to not autocomplete, even though they're in the language. I added Print, restarted, and got this:

Note that Print is no longer completed by the FE.

There is also internalFunctions.m which has a similar effect. That contains things like DeclareKnownSymbols, and AutoStyleOptions which don't get autocompleted either, but I suppose are there because they're still used in the language.

Then there are the developerFunctions.m which are clearly contexts that don't get filled out by autocomplete (think NotebookToolsFlattenCellGroups -- NotebookTools is in there).

• thanks @b3m2a1, this is fantastic! impressive detective work! I will add two bits for anyone who might come this way in the future: – billc Jul 22 '17 at 15:28
• (1) in my case, I needed to add a two-part path to "documentedContexts.m", as in MyAppMyPackage – billc Jul 22 '17 at 15:34
• (2) after I did this and restarted, I had the previously missing info icon, but it took me to a blank result in the documentation center. To get the icon to actually link to my documentation, I had to rerun BuildApplication["MyApp"]. (I'm using jmlopez's ApplicationMaker project. I'm not sure what the equivalent process would be otherwise.) – billc Jul 22 '17 at 15:34
• @billc don't know what BuildApplication does as I have my own docs system, but I bet your docs weren't properly indexed. I'm gonna bet that i button just uses the same Command-F (on Mac) system which I think works via DocumentationHelpLookup which eventually dead ends on DocumentationResolveLink. So if DocumentationResolveLink["MySym"] doesn't work the i button probably won't. – b3m2a1 Jul 22 '17 at 16:27
• It's not currently possible to add to the DocumentedPath variable via paclets, but I have forwarded that suggestion to the relevant developer. It should be relatively straightforward to add. – Itai Seggev Jul 22 '17 at 19:06