Skip to content

Commit 4b4a40e

Browse files
committed
Fixed autocompletions for DocFind
1 parent 731b9f3 commit 4b4a40e

File tree

1 file changed

+24
-6
lines changed

1 file changed

+24
-6
lines changed

DocFind.wl

+24-6
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ OpsFind::usage=
1717
MsgFind::usage="Finds all the messages for a given object and MessageName pattern";
1818

1919

20-
(* ::Subsection:: *)
20+
(* ::Subsection::Closed:: *)
2121
(*Package Scope*)
2222

2323

@@ -47,6 +47,22 @@ EndPackage[]
4747
Begin["`Private`"];
4848

4949

50+
(* ::Subsubsection::Closed:: *)
51+
(*packageAddAutocompletions*)
52+
53+
54+
(* ::Text:: *)
55+
(*Lazy dupe of the way my packages implement this*)
56+
57+
58+
packageAddAutocompletions[s_, l_]:=
59+
If[$Notebooks&&
60+
Internal`CachedSystemInformation["FrontEnd","VersionNumber"]>10.0,
61+
FE`Evaluate[FEPrivate`AddSpecialArgCompletion[s->l]],
62+
$Failed
63+
];
64+
65+
5066
(* ::Subsubsection::Closed:: *)
5167
(*PaneColumn*)
5268

@@ -358,7 +374,7 @@ SymbolDetermineType[{},___]:=
358374
SymbolDetermineType~SetAttributes~HoldFirst;
359375

360376

361-
(* ::Subsubsection::Closed:: *)
377+
(* ::Subsubsection:: *)
362378
(*DocFind*)
363379

364380

@@ -572,11 +588,13 @@ $DocFindInterestingContexts=
572588
};
573589

574590

575-
PackageAddAutocompletions[
576-
"DocFind",
591+
packageAddAutocompletions[
577592
{
578-
None,
579-
$DocFindInterestingContexts
593+
"DocFind"->
594+
{
595+
0,
596+
$DocFindInterestingContexts
597+
}
580598
}
581599
]
582600

0 commit comments

Comments
 (0)