-
Notifications
You must be signed in to change notification settings - Fork 6
/
vocabhelp.ijs
210 lines (202 loc) · 3.92 KB
/
vocabhelp.ijs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
coclass'jhs'
0 : 0
jhswiki'voc' NB. NuVoc vocabulary
jhswiki'i.' NB. edit i. for others - click Dyad for x i. y
jhswiki'if.' NB. control words
jhswiki'!:' NB. foreigns
jhswiki'12x' NB. constants
jhswiki'a' NB. ancilliary
jhswiki'std' NB. standard library
jhswiki'rel' NB. J release notes
jhswiki'JHS' NB. JHS info
jhswiki'807' NB. 807 legacy html
jhswiki'main' NB. main page
)
NB. add label for each link
wwwlinks=: <;._2 [ 0 : 0
vocabulary https://code.jsoftware.com/wiki/NuVoc
control structures https://code.jsoftware.com/wiki/Vocabulary/ControlStructures
foreigns !: https://code.jsoftware.com/wiki/Vocabulary/Foreigns
constants https://code.jsoftware.com/wiki/Vocabulary/Constants
ancilliary https://code.jsoftware.com/wiki/NuVoc#bottomrefs
standard library https://code.jsoftware.com/wiki/Standard_Library/Overview
release notes https://code.jsoftware.com/wiki/System/ReleaseNotes
JHS https://code.jsoftware.com/wiki/Guides/JHS
807 legacy html https://www.jsoftware.com/help/index.htm
main page https://code.jsoftware.com/wiki/Main_Page
)
links=: 3 : 0
t=. '<div class="transient">Jsoftware www/wiki links:<br>'
for_n. wwwlinks do.
a=. ;n
i=. a i: ' '
b=. deb i}.a
a=. deb i{.a
t=. t,LF,'<div contenteditable="false"><a href="',b,'" target="_blank">',a,'</a></div>'
end.
t=. t,LF,'</div>'
)
NB. borrows from ide/qt/help.ijs
jhsvocab=: 3 : 0
top=. {.;:y
first=. {.;top
last=. {:;top
b=. 'https://code.jsoftware.com/wiki/Vocabulary'
a=. ;top
if. top e. DICTNV_jhs_ do. t=. b,'/',>DICTNVX {~ DICTNV i.top
elseif. (first e. Alpha_j_) *. '.'=last do. t=. b,'/ControlStructures'
elseif. '!:'-:a do. t=. 'https://code.jsoftware.com/wiki/Vocabulary/Foreigns'
elseif. (first='_')+.first e. Num_j_ do. t=. b,'/Constants'
elseif. 'JHS'-:a do. t=. 'https://code.jsoftware.com/wiki/Guides/JHS'
elseif. a-:,'a' do. t=. 'https://code.jsoftware.com/wiki/NuVoc','#bottomrefs'
elseif. a-:'807' do. t=. 'https://www.jsoftware.com/help/index.htm'
elseif. a-:'std' do. t=. 'https://code.jsoftware.com/wiki/Standard_Library/Overview'
elseif. a-:'rel' do. t=. 'https://code.jsoftware.com/wiki/System/ReleaseNotes'
elseif. a-:'main' do. t=. 'https://code.jsoftware.com/wiki/Main_Page'
elseif. 1 do. t=. b
end.
jjs_jhs_ 'urlopen("',t,'");'
i.0 0
)
wiki_z_=: jhsvocab_jhs_
NB. banco replaced by !:
j=. <;._2 (0 : 0)
= eq
=. eqdot
=: eqco
< lt
<. ltdot
<: ltco
> gt
>. gtdot
>: gtco
_ under
_. underdot
_: underco
+ plus
+. plusdot
+: plusco
* star
*. stardot
*: starco
- minus
-. minusdot
-: minusco
% percent
%. percentdot
%: percentco
^ hat
^. hatdot
^: hatco
$ dollar
$. dollardot
$: dollarco
~ tilde
~. tildedot
~: tildeco
| bar
|. bardot
|: barco
. dot
.. dotdot
.: dotco
: co
:. codot
:: coco
, comma
,. commadot
,: commaco
; semi
;. semidot
;: semico
# number
#. numberdot
#: numberco
! bang
!. bangdot
!: Foreigns
/ slash
/. slashdot
/: slashco
\ bslash
\. bslashdot
\: bslashco
[ squarelf
[: squarelfco
] squarert
{ curlylf
{. curlylfdot
{: curlylfco
{:: curlylfcoco
} curlyrt
}. curlyrtdot
}: curlyrtco
" quote
". quotedot
": quoteco
` grave
`: graveco
@ at
@. atdot
@: atco
& ampm
&. ampdot
&.: ampdotco
&: ampco
? query
?. querydot
0: zeroco
1: zeroco
2: zeroco
3: zeroco
4: zeroco
5: zeroco
6: zeroco
7: zeroco
8: zeroco
9: zeroco
_1: zeroco
_2: zeroco
_3: zeroco
_4: zeroco
_5: zeroco
_6: zeroco
_7: zeroco
_8: zeroco
_9: zeroco
a. adot
a: aco
A. acapdot
b. bdot
C. ccapdot
d. ddot
D. dcapdot
D: dcapco
e. edot
E. ecapdot
f. fdot
H. hcapdot
i. idot
i: ico
I. icapdot
j. jdot
L. lcapdot
L: lcapco
M. mcapdot
o. odot
p. pdot
p.. pdotdot
p: pco
q: qco
r. rdot
s: sco
S: scapco
t. tdot
t: tco
T. tcapdot
u: uco
x: xco
)
n=. j i.&> ' '
DICTNV=: n {.each j
DICTNVX=: (n+1) }.each j