summaryrefslogtreecommitdiff
path: root/data/vim/patches/8.1.0763
blob: 8c4c6109f8cd762e0e4e2ce94d6cbdb799d31b6c (plain)
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
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676
4677
4678
4679
4680
4681
4682
4683
4684
4685
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
To: vim_dev@googlegroups.com
Subject: Patch 8.1.0763
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------

Patch 8.1.0763
Problem:    Nobody is using the Sun Workshop support.
Solution:   Remove the Workshop support.
Files:	    runtime/doc/workshop.txt, runtime/doc/help.txt,
            runtime/doc/netbeans.txt, src/Makefile, src/auto/configure,
            src/beval.c, src/buffer.c, src/config.h.in, src/config.mk.in,
            src/configure.ac, src/evalfunc.c, src/ex_cmds.c, src/ex_cmds.h,
            src/ex_docmd.c, src/feature.h, src/fileio.c, src/globals.h,
            src/gui.c, src/gui_beval.c, src/gui_motif.c, src/gui_x11.c,
            src/integration.c, src/integration.h, src/main.c, src/misc2.c,
            src/nbdebug.c, src/netbeans.c, src/proto.h,
            src/proto/workshop.pro, src/ui.c, src/version.c, src/vim.h,
            src/workshop.c, src/workshop.h, src/wsdebug.c, src/wsdebug.h,
            src/ex_cmdidxs.h


*** ../vim-8.1.0762/runtime/doc/workshop.txt	2018-05-17 13:42:04.000000000 +0200
--- runtime/doc/workshop.txt	2019-01-17 14:47:16.643795105 +0100
***************
*** 1,4 ****
! *workshop.txt*  For Vim version 8.1.  Last change: 2013 Jul 06
  
  
  		  VIM REFERENCE MANUAL    by Gordon Prieur
--- 1,4 ----
! *workshop.txt*  For Vim version 8.1.  Last change: 2019 Jan 17
  
  
  		  VIM REFERENCE MANUAL    by Gordon Prieur
***************
*** 6,98 ****
  
  Sun Visual WorkShop Features			*workshop* *workshop-support*
  
! 1. Introduction						|workshop-intro|
! 2. Commands						|workshop-commands|
! 3. Compiling vim/gvim for WorkShop			|workshop-compiling|
! 4. Configuring gvim for a WorkShop release tree		|workshop-configure|
! 5. Obtaining the latest version of the XPM library	|workshop-xpm|
! 
! {Vi does not have any of these features}
! {only available when compiled with the |+sun_workshop| feature}
! 
! ==============================================================================
! 1. Introduction						*workshop-intro*
! 
! Sun Visual WorkShop has an "Editor of Choice" feature designed to let users
! debug using their favorite editors.  For the 6.0 release we have added support
! for gvim.  A workshop debug session will have a debugging window and an editor
! window (possibly others as well).  The user can do many debugging operations
! from the editor window, minimizing the need to switch from window to window.
! 
! The version of vim shipped with Sun Visual WorkShop 6 (also called Forte
! Developer 6) is vim 5.3.  The features in this release are much more reliable
! than the vim/gvim shipped with Visual WorkShop.  VWS users wishing to use vim
! as their editor should compile these sources and install them in their
! workshop release tree.
! 
! ==============================================================================
! 2. Commands						*workshop-commands*
! 
! 						*:ws* *:wsverb*
! :ws[verb] verb			Pass the verb to the verb executor
! 
! Pass the verb to a workshop function which gathers some arguments and
! sends the verb and data to workshop over an IPC connection.
! 
! ==============================================================================
! 3. Compiling vim/gvim for WorkShop			*workshop-compiling*
! 
! Compiling vim with FEAT_SUN_WORKSHOP turns on all compile time flags necessary
! for building a vim to work with Visual WorkShop.  The features required for VWS
! have been built and tested using the Sun compilers from the VWS release.  They
! have not been built or tested using Gnu compilers.  This does not mean the
! features won't build and run if compiled with gcc, just that nothing is
! guaranteed with gcc!
! 
! ==============================================================================
! 4. Configuring gvim for a WorkShop release tree		*workshop-configure*
! 
! There are several assumptions which must be met in order to compile a gvim for
! use with Sun Visual WorkShop 6.
! 
!     o You should use the compiler in VWS rather than gcc.  We have neither
!       built nor tested with gcc and cannot guarantee it will build properly.
! 
!     o You must supply your own XPM library.  See |workshop-xpm| below for
!       details on obtaining the latest version of XPM.
! 
!     o Edit the Makefile in the src directory and uncomment the lines for Sun
!       Visual WorkShop.  You can easily find these by searching for the string
!       FEAT_SUN_WORKSHOP
! 
!     o We also suggest you use Motif for your gui.  This will provide gvim with
!       the same look-and-feel as the rest of Sun Visual WorkShop.
! 
! The following configuration line can be used to configure vim to build for use
! with Sun Visual WorkShop:
! 
!     $ CC=cc configure --enable-workshop --enable-gui=motif \
! 	-prefix=<VWS-install-dir>/contrib/contrib6/<vim-version>
! 
! The VWS-install-dir should be the base directory where your Sun Visual WorkShop
! was installed.  By default this is /opt/SUNWspro.  It will normally require
! root permissions to install the vim release.  You will also need to change the
! symlink <VWS-install-dir>/bin/gvim to point to the vim in your newly installed
! directory.  The <vim-version> should be a unique version string.  I use "vim"
! concatenated with the equivalent of version.h's VIM_VERSION_SHORT.
! 
! ==============================================================================
! 5. Obtaining the latest version of the XPM library	*workshop-xpm*
! 
! The XPM library is required to show images within Vim with Motif or Athena.
! Without it the toolbar and signs will be disabled.
! 
! The XPM library is provided by Arnaud Le Hors of the French National Institute
! for Research in Computer Science and Control.  It can be downloaded from
! http://cgit.freedesktop.org/xorg/lib/libXpm.  The current release, as of this
! writing, is xpm-3.4k-solaris.tgz, which is a gzip'ed tar file.  If you create
! the directory /usr/local/xpm and untar the file there you can use the
! uncommented lines in the Makefile without changing them.  If you use another
! xpm directory you will need to change the XPM_DIR in src/Makefile.
  
!  vim:tw=78:ts=8:ft=help:norl:
--- 6,14 ----
  
  Sun Visual WorkShop Features			*workshop* *workshop-support*
  
! The support for WorkShop was removed in patch 8.1.0763 in January 2019.
! The product has not been available for a long time and has been replaced by
! |NetBeans|.
  
! 
!  vim:tw=78:ts=8:noet:ft=help:norl:
*** ../vim-8.1.0762/runtime/doc/help.txt	2018-05-17 13:41:40.000000000 +0200
--- runtime/doc/help.txt	2019-01-17 14:55:00.628054659 +0100
***************
*** 171,177 ****
  |if_ole.txt|	OLE automation interface for Win32
  |if_ruby.txt|	Ruby interface
  |debugger.txt|	Interface with a debugger
- |workshop.txt|	Sun Visual Workshop interface
  |netbeans.txt|	NetBeans External Editor interface
  |sign.txt|	debugging signs
  
--- 180,185 ----
*** ../vim-8.1.0762/runtime/doc/netbeans.txt	2018-05-17 13:41:41.000000000 +0200
--- runtime/doc/netbeans.txt	2019-01-17 14:53:47.956614503 +0100
***************
*** 1,10 ****
! *netbeans.txt*  For Vim version 8.1.  Last change: 2016 Jul 15
  
  
  		  VIM REFERENCE MANUAL    by Gordon Prieur et al.
  
  
! 					*netbeans* *netbeans-support*
  
  Vim NetBeans Protocol: a socket interface for Vim integration into an IDE.
  
--- 1,10 ----
! *netbeans.txt*  For Vim version 8.1.  Last change: 2019 Jan 17
  
  
  		  VIM REFERENCE MANUAL    by Gordon Prieur et al.
  
  
! 					*netbeans* *NetBeans* *netbeans-support*
  
  Vim NetBeans Protocol: a socket interface for Vim integration into an IDE.
  
***************
*** 123,130 ****
  by gvim when it is run with one of the following GUIs: GTK, GNOME, Windows,
  Athena and Motif.
  
! If Motif support is required the user must supply XPM libraries.  See
! |workshop-xpm| for details on obtaining the latest version of XPM.
  
  
  On MS-Windows:
--- 123,140 ----
  by gvim when it is run with one of the following GUIs: GTK, GNOME, Windows,
  Athena and Motif.
  
! 							*netbeans-xpm*
! If Motif support is required the user must supply XPM libraries.
! The XPM library is required to show images within Vim with Motif or Athena.
! Without it the toolbar and signs will be disabled.
! 
! The XPM library is provided by Arnaud Le Hors of the French National Institute
! for Research in Computer Science and Control.  It can be downloaded from
! http://cgit.freedesktop.org/xorg/lib/libXpm.  The current release, as of this
! writing, is xpm-3.4k-solaris.tgz, which is a gzip'ed tar file.  If you create
! the directory /usr/local/xpm and untar the file there you can use the
! uncommented lines in the Makefile without changing them.  If you use another
! xpm directory you will need to change the XPM_DIR in src/Makefile.
  
  
  On MS-Windows:
***************
*** 409,417 ****
  		Vim will define a sign for the annotation.
  		When color is a number, this is the "#rrggbb" Red, Green and
  		Blue values of the color (see |gui-colors|) and the
! 		highlighting is only defined for GVim.
  		When color is a name, this color is defined both for Vim
! 		running in a color terminal and for GVim.
  		When both "fg" and "bg" are "none" no line highlighting is
  		used (new in version 2.1).
  		When "glyphFile" is empty, no text sign is used (new in
--- 419,427 ----
  		Vim will define a sign for the annotation.
  		When color is a number, this is the "#rrggbb" Red, Green and
  		Blue values of the color (see |gui-colors|) and the
! 		highlighting is only defined for gVim.
  		When color is a name, this color is defined both for Vim
! 		running in a color terminal and for gVim.
  		When both "fg" and "bg" are "none" no line highlighting is
  		used (new in version 2.1).
  		When "glyphFile" is empty, no text sign is used (new in
*** ../vim-8.1.0762/src/Makefile	2019-01-12 22:47:01.256088105 +0100
--- src/Makefile	2019-01-17 15:04:39.151775617 +0100
***************
*** 317,323 ****
  # You can give a lot of options to configure.
  # Change this to your desire and do 'make config' afterwards
  
! # examples:
  #CONF_ARGS1 = --exec-prefix=/usr
  #CONF_ARGS2 = --with-vim-name=vim8 --with-ex-name=ex8 --with-view-name=view8
  #CONF_ARGS3 = --with-global-runtime=/etc/vim,/usr/share/vim
--- 317,323 ----
  # You can give a lot of options to configure.
  # Change this to your desire and do 'make config' afterwards
  
! # examples you can uncomment:
  #CONF_ARGS1 = --exec-prefix=/usr
  #CONF_ARGS2 = --with-vim-name=vim8 --with-ex-name=ex8 --with-view-name=view8
  #CONF_ARGS3 = --with-global-runtime=/etc/vim,/usr/share/vim
***************
*** 464,482 ****
  # TCL
  # Uncomment this when you want to include the Tcl interface.
  # First one is for static linking, second one for dynamic loading.
  #CONF_OPT_TCL = --enable-tclinterp
  #CONF_OPT_TCL = --enable-tclinterp=dynamic
  #CONF_OPT_TCL = --enable-tclinterp --with-tclsh=tclsh8.4
  
  # CSCOPE
  # Uncomment this when you want to include the Cscope interface.
  #CONF_OPT_CSCOPE = --enable-cscope
! 
! # WORKSHOP - Sun Visual Workshop interface.  Only works with Motif!
! #CONF_OPT_WORKSHOP = --enable-workshop
  
  # NETBEANS - NetBeans interface. Only works with Motif, GTK, and gnome.
! # Motif version must have XPM libraries (see |workshop-xpm|).
  # Uncomment this when you do not want the netbeans interface.
  #CONF_OPT_NETBEANS = --disable-netbeans
  
--- 464,479 ----
  # TCL
  # Uncomment this when you want to include the Tcl interface.
  # First one is for static linking, second one for dynamic loading.
  #CONF_OPT_TCL = --enable-tclinterp
  #CONF_OPT_TCL = --enable-tclinterp=dynamic
  #CONF_OPT_TCL = --enable-tclinterp --with-tclsh=tclsh8.4
  
  # CSCOPE
  # Uncomment this when you want to include the Cscope interface.
  #CONF_OPT_CSCOPE = --enable-cscope
  
  # NETBEANS - NetBeans interface. Only works with Motif, GTK, and gnome.
! # Motif version must have XPM libraries (see |netbeans-xpm|).
  # Uncomment this when you do not want the netbeans interface.
  #CONF_OPT_NETBEANS = --disable-netbeans
  
***************
*** 781,787 ****
  #CC	    = /usr/ucb/cc
  #EXTRA_LIBS = -R/usr/ucblib
  
! ### Solaris with Forte Developer and FEAT_SUN_WORKSHOP
  # The Xpm library is available from http://koala.ilog.fr/ftp/pub/xpm.
  #CC		= cc
  #XPM_DIR		= /usr/local/xpm/xpm-3.4k-solaris
--- 780,786 ----
  #CC	    = /usr/ucb/cc
  #EXTRA_LIBS = -R/usr/ucblib
  
! ### Solaris with Forte Developer and NetBeans.
  # The Xpm library is available from http://koala.ilog.fr/ftp/pub/xpm.
  #CC		= cc
  #XPM_DIR		= /usr/local/xpm/xpm-3.4k-solaris
***************
*** 791,800 ****
  #EXTRA_IPATHS	= $(XPM_IPATH)
  #EXTRA_DEFS	= -xCC -DHAVE_X11_XPM_H
  
- ### Solaris with workshop compilers: Vim is unstable when compiled with
- # "-fast".  Use this instead. (Shea Martin)
- #CFLAGS = -x02 -xtarget=ultra
- 
  ### (R) for Solaris 2.5 (or 2.5.1) with gcc > 2.5.6 you might need this:
  #LDFLAGS = -lw -ldl -lXmu
  #GUI_LIB_LOC = -L/usr/local/lib
--- 790,795 ----
***************
*** 1651,1664 ****
  	$(PERL_SRC) \
  	$(PYTHON_SRC) $(PYTHON3_SRC) \
  	$(TCL_SRC) \
! 	$(RUBY_SRC) \
! 	$(WORKSHOP_SRC) \
! 	$(WSDEBUG_SRC)
  
  EXTRA_SRC = hangulin.c if_lua.c if_mzsch.c auto/if_perl.c if_perlsfio.c \
  	    if_python.c if_python3.c if_tcl.c if_ruby.c \
! 	    gui_beval.c workshop.c wsdebug.c integration.c \
! 	    netbeans.c channel.c \
  	    $(GRESOURCE_SRC)
  
  # Unittest files
--- 1646,1656 ----
  	$(PERL_SRC) \
  	$(PYTHON_SRC) $(PYTHON3_SRC) \
  	$(TCL_SRC) \
! 	$(RUBY_SRC)
  
  EXTRA_SRC = hangulin.c if_lua.c if_mzsch.c auto/if_perl.c if_perlsfio.c \
  	    if_python.c if_python3.c if_tcl.c if_ruby.c \
! 	    gui_beval.c netbeans.c channel.c \
  	    $(GRESOURCE_SRC)
  
  # Unittest files
***************
*** 1684,1690 ****
  # The perl sources also don't work well with lint.
  LINT_SRC = $(BASIC_SRC) $(GUI_SRC) $(HANGULIN_SRC) \
  	   $(PYTHON_SRC) $(PYTHON3_SRC) $(TCL_SRC) \
- 	   $(WORKSHOP_SRC) $(WSDEBUG_SRC) \
  	   $(NETBEANS_SRC) $(CHANNEL_SRC) $(TERM_SRC)
  #LINT_SRC = $(SRC)
  #LINT_SRC = $(ALL_SRC)
--- 1676,1681 ----
***************
*** 1761,1771 ****
  	$(TCL_OBJ) \
  	$(RUBY_OBJ) \
  	$(OS_EXTRA_OBJ) \
- 	$(WORKSHOP_OBJ) \
  	$(NETBEANS_OBJ) \
  	$(CHANNEL_OBJ) \
! 	$(XDIFF_OBJS) \
! 	$(WSDEBUG_OBJ)
  
  # The files included by tests are not in OBJ_COMMON.
  OBJ_MAIN = \
--- 1752,1760 ----
  	$(TCL_OBJ) \
  	$(RUBY_OBJ) \
  	$(OS_EXTRA_OBJ) \
  	$(NETBEANS_OBJ) \
  	$(CHANNEL_OBJ) \
! 	$(XDIFF_OBJS)
  
  # The files included by tests are not in OBJ_COMMON.
  OBJ_MAIN = \
***************
*** 1889,1895 ****
  	window.pro \
  	beval.pro \
  	gui_beval.pro \
- 	workshop.pro \
  	netbeans.pro \
  	channel.pro \
  	$(ALL_GUI_PRO) \
--- 1878,1883 ----
***************
*** 1932,1938 ****
  		$(CONF_OPT_PERL) $(CONF_OPT_PYTHON) $(CONF_OPT_PYTHON3) \
  		$(CONF_OPT_TCL) $(CONF_OPT_RUBY) $(CONF_OPT_NLS) \
  		$(CONF_OPT_CSCOPE) $(CONF_OPT_MULTIBYTE) $(CONF_OPT_INPUT) \
! 		$(CONF_OPT_OUTPUT) $(CONF_OPT_GPM) $(CONF_OPT_WORKSHOP) \
  		$(CONF_OPT_FEAT) $(CONF_TERM_LIB) \
  		$(CONF_OPT_COMPBY) $(CONF_OPT_ACL) $(CONF_OPT_NETBEANS) \
  		$(CONF_OPT_CHANNEL) $(CONF_OPT_TERMINAL) \
--- 1920,1926 ----
  		$(CONF_OPT_PERL) $(CONF_OPT_PYTHON) $(CONF_OPT_PYTHON3) \
  		$(CONF_OPT_TCL) $(CONF_OPT_RUBY) $(CONF_OPT_NLS) \
  		$(CONF_OPT_CSCOPE) $(CONF_OPT_MULTIBYTE) $(CONF_OPT_INPUT) \
! 		$(CONF_OPT_OUTPUT) $(CONF_OPT_GPM) \
  		$(CONF_OPT_FEAT) $(CONF_TERM_LIB) \
  		$(CONF_OPT_COMPBY) $(CONF_OPT_ACL) $(CONF_OPT_NETBEANS) \
  		$(CONF_OPT_CHANNEL) $(CONF_OPT_TERMINAL) \
***************
*** 3098,3106 ****
  objects/if_tcl.o: if_tcl.c
  	$(CCC_NF) $(TCL_CFLAGS) $(ALL_CFLAGS) -o $@ if_tcl.c
  
- objects/integration.o: integration.c
- 	$(CCC) -o $@ integration.c
- 
  objects/json.o: json.c
  	$(CCC) -o $@ json.c
  
--- 3086,3091 ----
***************
*** 3239,3250 ****
  objects/window.o: window.c
  	$(CCC) -o $@ window.c
  
- objects/workshop.o: workshop.c
- 	$(CCC) -o $@ workshop.c
- 
- objects/wsdebug.o: wsdebug.c
- 	$(CCC) -o $@ wsdebug.c
- 
  objects/netbeans.o: netbeans.c
  	$(CCC) -o $@ netbeans.c
  
--- 3224,3229 ----
***************
*** 3784,3799 ****
   os_unix.h auto/osdef.h ascii.h keymap.h term.h macros.h option.h beval.h \
   proto/gui_beval.pro structs.h regexp.h gui.h alloc.h ex_cmds.h spell.h \
   proto.h globals.h farsi.h arabic.h
- objects/workshop.o: workshop.c protodef.h auto/config.h integration.h vim.h \
-  feature.h os_unix.h auto/osdef.h ascii.h keymap.h term.h macros.h \
-  option.h beval.h proto/gui_beval.pro structs.h regexp.h gui.h alloc.h \
-  ex_cmds.h spell.h proto.h globals.h farsi.h arabic.h version.h \
-  workshop.h
- objects/wsdebug.o: wsdebug.c
- objects/integration.o: integration.c vim.h protodef.h auto/config.h feature.h \
-  os_unix.h auto/osdef.h ascii.h keymap.h term.h macros.h option.h beval.h \
-  proto/gui_beval.pro structs.h regexp.h gui.h alloc.h ex_cmds.h spell.h \
-  proto.h globals.h farsi.h arabic.h integration.h
  objects/netbeans.o: netbeans.c vim.h protodef.h auto/config.h feature.h os_unix.h \
   auto/osdef.h ascii.h keymap.h term.h macros.h option.h beval.h \
   proto/gui_beval.pro structs.h regexp.h gui.h alloc.h ex_cmds.h spell.h \
--- 3763,3768 ----
*** ../vim-8.1.0762/src/auto/configure	2019-01-12 16:10:47.415360504 +0100
--- src/auto/configure	2019-01-17 14:58:28.142489864 +0100
***************
*** 661,668 ****
  CHANNEL_SRC
  NETBEANS_OBJ
  NETBEANS_SRC
- WORKSHOP_OBJ
- WORKSHOP_SRC
  RUBY_LIBS
  RUBY_CFLAGS
  RUBY_PRO
--- 661,666 ----
***************
*** 812,818 ****
  enable_rubyinterp
  with_ruby_command
  enable_cscope
- enable_workshop
  enable_netbeans
  enable_channel
  enable_terminal
--- 810,815 ----
***************
*** 1494,1500 ****
    --enable-tclinterp=OPTS      Include Tcl interpreter. default=no OPTS=no/yes/dynamic
    --enable-rubyinterp=OPTS     Include Ruby interpreter.  default=no OPTS=no/yes/dynamic
    --enable-cscope         Include cscope interface.
-   --enable-workshop       Include Sun Visual Workshop support.
    --disable-netbeans      Disable NetBeans integration support.
    --disable-channel       Disable process communication support.
    --enable-terminal       Enable terminal emulation support.
--- 1491,1496 ----
***************
*** 7665,7693 ****
  
  fi
  
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-workshop argument" >&5
- $as_echo_n "checking --enable-workshop argument... " >&6; }
- # Check whether --enable-workshop was given.
- if test "${enable_workshop+set}" = set; then :
-   enableval=$enable_workshop;
- else
-   enable_workshop="no"
- fi
- 
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_workshop" >&5
- $as_echo "$enable_workshop" >&6; }
- if test "$enable_workshop" = "yes"; then
-   $as_echo "#define FEAT_SUN_WORKSHOP 1" >>confdefs.h
- 
-   WORKSHOP_SRC="workshop.c integration.c"
- 
-   WORKSHOP_OBJ="objects/workshop.o objects/integration.o"
- 
-   if test "${enable_gui-xxx}" = xxx; then
-     enable_gui=motif
-   fi
- fi
- 
  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --disable-netbeans argument" >&5
  $as_echo_n "checking --disable-netbeans argument... " >&6; }
  # Check whether --enable-netbeans was given.
--- 7661,7666 ----
*** ../vim-8.1.0762/src/beval.c	2018-10-02 14:15:08.991376909 +0200
--- src/beval.c	2019-01-17 15:16:25.906741669 +0100
***************
*** 273,282 ****
      if (bevalServers & BEVAL_NETBEANS)
  	netbeans_beval_cb(beval, state);
  #endif
- #ifdef FEAT_SUN_WORKSHOP
-     if (bevalServers & BEVAL_WORKSHOP)
- 	workshop_beval_cb(beval, state);
- #endif
  
      recursive = FALSE;
  }
--- 273,278 ----
*** ../vim-8.1.0762/src/buffer.c	2019-01-15 20:19:36.739904461 +0100
--- src/buffer.c	2019-01-17 15:19:25.237997004 +0100
***************
*** 658,668 ****
       */
      if (wipe_buf)
      {
- #ifdef FEAT_SUN_WORKSHOP
- 	if (usingSunWorkShop)
- 	    workshop_file_closed_lineno((char *)buf->b_ffname,
- 			(int)buf->b_last_cursor.lnum);
- #endif
  	if (buf->b_sfname != buf->b_ffname)
  	    VIM_CLEAR(buf->b_sfname);
  	else
--- 658,663 ----
*** ../vim-8.1.0762/src/config.h.in	2018-12-21 11:48:48.320680492 +0100
--- src/config.h.in	2019-01-17 14:58:51.046319671 +0100
***************
*** 441,449 ****
  /* Define if we have shl_load() */
  #undef HAVE_SHL_LOAD
  
- /* Define if you want to include Sun Visual Workshop support. */
- #undef FEAT_SUN_WORKSHOP
- 
  /* Define if you want to include NetBeans integration. */
  #undef FEAT_NETBEANS_INTG
  
--- 441,446 ----
*** ../vim-8.1.0762/src/config.mk.in	2018-04-11 22:14:38.000000000 +0200
--- src/config.mk.in	2019-01-17 14:59:00.314250926 +0100
***************
*** 81,89 ****
  HANGULIN_SRC	= @HANGULIN_SRC@
  HANGULIN_OBJ	= @HANGULIN_OBJ@
  
- WORKSHOP_SRC	= @WORKSHOP_SRC@
- WORKSHOP_OBJ	= @WORKSHOP_OBJ@
- 
  NETBEANS_SRC	= @NETBEANS_SRC@
  NETBEANS_OBJ	= @NETBEANS_OBJ@
  CHANNEL_SRC	= @CHANNEL_SRC@
--- 81,86 ----
*** ../vim-8.1.0762/src/configure.ac	2019-01-12 16:10:47.411360533 +0100
--- src/configure.ac	2019-01-17 14:58:24.194519245 +0100
***************
*** 1996,2017 ****
    AC_DEFINE(FEAT_CSCOPE)
  fi
  
- AC_MSG_CHECKING(--enable-workshop argument)
- AC_ARG_ENABLE(workshop,
- 	[  --enable-workshop       Include Sun Visual Workshop support.], ,
- 	[enable_workshop="no"])
- AC_MSG_RESULT($enable_workshop)
- if test "$enable_workshop" = "yes"; then
-   AC_DEFINE(FEAT_SUN_WORKSHOP)
-   WORKSHOP_SRC="workshop.c integration.c"
-   AC_SUBST(WORKSHOP_SRC)
-   WORKSHOP_OBJ="objects/workshop.o objects/integration.o"
-   AC_SUBST(WORKSHOP_OBJ)
-   if test "${enable_gui-xxx}" = xxx; then
-     enable_gui=motif
-   fi
- fi
- 
  AC_MSG_CHECKING(--disable-netbeans argument)
  AC_ARG_ENABLE(netbeans,
  	[  --disable-netbeans      Disable NetBeans integration support.],
--- 1996,2001 ----
*** ../vim-8.1.0762/src/evalfunc.c	2019-01-15 22:16:37.414340200 +0100
--- src/evalfunc.c	2019-01-17 14:50:04.854386619 +0100
***************
*** 6512,6520 ****
  #ifdef FEAT_STL_OPT
  	"statusline",
  #endif
- #ifdef FEAT_SUN_WORKSHOP
- 	"sun_workshop",
- #endif
  #ifdef FEAT_NETBEANS_INTG
  	"netbeans_intg",
  #endif
--- 6512,6517 ----
*** ../vim-8.1.0762/src/ex_cmds.c	2019-01-13 23:38:33.387773334 +0100
--- src/ex_cmds.c	2019-01-17 15:20:04.497831990 +0100
***************
*** 3805,3813 ****
      int		newcol = -1;
      int		solcol = -1;
      pos_T	*pos;
- #ifdef FEAT_SUN_WORKSHOP
-     char_u	*cp;
- #endif
      char_u	*command = NULL;
  #ifdef FEAT_SPELL
      int		did_get_winopts = FALSE;
--- 3805,3810 ----
***************
*** 3881,3891 ****
  	    if (free_fname != NULL)
  		ffname = free_fname;
  	    other_file = otherfile(ffname);
- #ifdef FEAT_SUN_WORKSHOP
- 	    if (usingSunWorkShop && p_acd
- 				   && (cp = vim_strrchr(sfname, '/')) != NULL)
- 		sfname = ++cp;
- #endif
  	}
      }
  
--- 3878,3883 ----
***************
*** 4457,4469 ****
      }
  #endif
  
! #if defined(FEAT_SUN_WORKSHOP) || defined(FEAT_NETBEANS_INTG)
      if (curbuf->b_ffname != NULL)
      {
- # ifdef FEAT_SUN_WORKSHOP
- 	if (gui.in_use && usingSunWorkShop)
- 	    workshop_file_opened((char *)curbuf->b_ffname, curbuf->b_p_ro);
- # endif
  # ifdef FEAT_NETBEANS_INTG
  	if ((flags & ECMD_SET_HELP) != ECMD_SET_HELP)
  	    netbeans_file_opened(curbuf);
--- 4449,4457 ----
      }
  #endif
  
! #if defined(FEAT_NETBEANS_INTG)
      if (curbuf->b_ffname != NULL)
      {
  # ifdef FEAT_NETBEANS_INTG
  	if ((flags & ECMD_SET_HELP) != ECMD_SET_HELP)
  	    netbeans_file_opened(curbuf);
*** ../vim-8.1.0762/src/ex_cmds.h	2019-01-13 23:38:33.387773334 +0100
--- src/ex_cmds.h	2019-01-17 14:56:18.839459572 +0100
***************
*** 1670,1678 ****
  EX(CMD_wqall,		"wqall",	do_wqall,
  			BANG|FILE1|ARGOPT|DFLALL|TRLBAR,
  			ADDR_LINES),
- EX(CMD_wsverb,		"wsverb",	ex_wsverb,
- 			EXTRA|NOTADR|NEEDARG,
- 			ADDR_LINES),
  EX(CMD_wundo,		"wundo",	ex_wundo,
  			BANG|NEEDARG|FILE1,
  			ADDR_LINES),
--- 1670,1675 ----
*** ../vim-8.1.0762/src/ex_docmd.c	2019-01-15 20:19:36.743904434 +0100
--- src/ex_docmd.c	2019-01-17 15:20:26.561736397 +0100
***************
*** 411,419 ****
  #ifndef FEAT_SIGNS
  # define ex_sign		ex_ni
  #endif
- #ifndef FEAT_SUN_WORKSHOP
- # define ex_wsverb		ex_ni
- #endif
  #ifndef FEAT_NETBEANS_INTG
  # define ex_nbclose		ex_ni
  # define ex_nbkey		ex_ni
--- 411,416 ----
*** ../vim-8.1.0762/src/feature.h	2019-01-12 16:10:47.415360504 +0100
--- src/feature.h	2019-01-17 15:11:32.124821752 +0100
***************
*** 1232,1238 ****
   * +perl		Perl interface: "--enable-perlinterp"
   * +python		Python interface: "--enable-pythoninterp"
   * +tcl			TCL interface: "--enable-tclinterp"
-  * +sun_workshop	Sun Workshop integration
   * +netbeans_intg	Netbeans integration
   * +channel		Inter process communication
   */
--- 1232,1237 ----
***************
*** 1244,1256 ****
   */
  
  /*
-  * The Sun Workshop features currently only work with Motif.
-  */
- #if !defined(FEAT_GUI_MOTIF) && defined(FEAT_SUN_WORKSHOP)
- # undef FEAT_SUN_WORKSHOP
- #endif
- 
- /*
   * The Netbeans feature requires +eval.
   */
  #if !defined(FEAT_EVAL) && defined(FEAT_NETBEANS_INTG)
--- 1243,1248 ----
***************
*** 1279,1286 ****
   * +signs		Allow signs to be displayed to the left of text lines.
   *			Adds the ":sign" command.
   */
! #if defined(FEAT_BIG) || defined(FEAT_SUN_WORKSHOP) \
! 	    || defined(FEAT_NETBEANS_INTG)
  # define FEAT_SIGNS
  # if ((defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) \
  		&& defined(HAVE_X11_XPM_H)) \
--- 1271,1277 ----
   * +signs		Allow signs to be displayed to the left of text lines.
   *			Adds the ":sign" command.
   */
! #if defined(FEAT_BIG) || defined(FEAT_NETBEANS_INTG)
  # define FEAT_SIGNS
  # if ((defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) \
  		&& defined(HAVE_X11_XPM_H)) \
***************
*** 1299,1305 ****
  	|| defined(FEAT_GUI_GTK) || defined(FEAT_GUI_W32)) \
  	&& (   ((defined(FEAT_TOOLBAR) || defined(FEAT_GUI_TABLINE)) \
  		&& !defined(FEAT_GUI_GTK) && !defined(FEAT_GUI_W32)) \
- 	    || defined(FEAT_SUN_WORKSHOP) \
  	    || defined(FEAT_NETBEANS_INTG) || defined(FEAT_EVAL))
  # define FEAT_BEVAL_GUI
  # if !defined(FEAT_XFONTSET) && !defined(FEAT_GUI_GTK) \
--- 1290,1295 ----
***************
*** 1329,1365 ****
  # define FEAT_GUI_X11
  #endif
  
! #if defined(FEAT_SUN_WORKSHOP) || defined(FEAT_NETBEANS_INTG)
! /*
!  * The following features are (currently) only used by Sun Visual WorkShop 6
!  * and NetBeans. These features could be used with other integrations with
!  * debuggers so I've used separate feature defines.
!  */
  # if !defined(FEAT_MENU)
  #  define FEAT_MENU
  # endif
  #endif
  
! #if defined(FEAT_SUN_WORKSHOP)
! /*
!  *			Use an alternative method of X input for a secondary
!  *			command input.
!  */
! # define ALT_X_INPUT
! 
  /*
   * +footer		Motif only: Add a message area at the bottom of the
   *			main window area.
   */
  # define FEAT_FOOTER
- 
  #endif
  
  /*
   * +autochdir		'autochdir' option.
   */
! #if defined(FEAT_SUN_WORKSHOP) || defined(FEAT_NETBEANS_INTG) \
! 	    || defined(FEAT_BIG)
  # define FEAT_AUTOCHDIR
  #endif
  
--- 1319,1343 ----
  # define FEAT_GUI_X11
  #endif
  
! #if defined(FEAT_NETBEANS_INTG)
! // NetBeans uses menus.
  # if !defined(FEAT_MENU)
  #  define FEAT_MENU
  # endif
  #endif
  
! #if 0
  /*
   * +footer		Motif only: Add a message area at the bottom of the
   *			main window area.
   */
  # define FEAT_FOOTER
  #endif
  
  /*
   * +autochdir		'autochdir' option.
   */
! #if defined(FEAT_NETBEANS_INTG) || defined(FEAT_BIG)
  # define FEAT_AUTOCHDIR
  #endif
  
*** ../vim-8.1.0762/src/fileio.c	2019-01-13 23:38:33.391773303 +0100
--- src/fileio.c	2019-01-17 15:20:35.345697789 +0100
***************
*** 5094,5104 ****
      if (!p_bk && backup != NULL && mch_remove(backup) != 0)
  	emsg(_("E207: Can't delete backup file"));
  
- #ifdef FEAT_SUN_WORKSHOP
-     if (usingSunWorkShop)
- 	workshop_file_saved((char *) ffname);
- #endif
- 
      goto nofail;
  
      /*
--- 5094,5099 ----
*** ../vim-8.1.0762/src/globals.h	2019-01-16 22:41:50.091917818 +0100
--- src/globals.h	2019-01-17 15:26:00.420093561 +0100
***************
*** 1218,1227 ****
  #if defined(FEAT_BEVAL) && !defined(NO_X11_INCLUDES)
  EXTERN BalloonEval	*balloonEval INIT(= NULL);
  EXTERN int		balloonEvalForTerm INIT(= FALSE);
! # if defined(FEAT_NETBEANS_INTG) || defined(FEAT_SUN_WORKSHOP)
  EXTERN int bevalServers INIT(= 0);
  #  define BEVAL_NETBEANS		0x01
- #  define BEVAL_WORKSHOP		0x02
  # endif
  #endif
  
--- 1218,1226 ----
  #if defined(FEAT_BEVAL) && !defined(NO_X11_INCLUDES)
  EXTERN BalloonEval	*balloonEval INIT(= NULL);
  EXTERN int		balloonEvalForTerm INIT(= FALSE);
! # if defined(FEAT_NETBEANS_INTG)
  EXTERN int bevalServers INIT(= 0);
  #  define BEVAL_NETBEANS		0x01
  # endif
  #endif
  
***************
*** 1363,1376 ****
  EXTERN int		need_cursor_line_redraw INIT(= FALSE);
  #endif
  
- #ifdef ALT_X_INPUT
- /* we need to be able to go into the dispatch loop while processing a command
-  * received via alternate input. However, we don't want to process another
-  * command until the first is completed.
-  */
- EXTERN int	suppress_alternate_input INIT(= FALSE);
- #endif
- 
  #ifdef USE_MCH_ERRMSG
  /* Grow array to collect error messages in until they can be displayed. */
  EXTERN garray_T error_ga
--- 1362,1367 ----
*** ../vim-8.1.0762/src/gui.c	2019-01-13 23:38:33.391773303 +0100
--- src/gui.c	2019-01-17 15:21:11.121537479 +0100
***************
*** 672,681 ****
  #ifdef FEAT_MENU
      gui_create_initial_menus(root_menu);
  #endif
- #ifdef FEAT_SUN_WORKSHOP
-     if (usingSunWorkShop)
- 	workshop_init();
- #endif
  #ifdef FEAT_SIGN_ICONS
      sign_gui_started();
  #endif
--- 672,677 ----
***************
*** 1604,1622 ****
  	/* Remember the original window position. */
  	(void)gui_mch_get_winpos(&x, &y);
  
! #ifdef USE_SUN_WORKSHOP
!     if (!mustset && usingSunWorkShop
! 				&& workshop_get_width_height(&width, &height))
!     {
! 	Columns = (width - base_width + gui.char_width - 1) / gui.char_width;
! 	Rows = (height - base_height + gui.char_height - 1) / gui.char_height;
!     }
!     else
! #endif
!     {
! 	width = Columns * gui.char_width + base_width;
! 	height = Rows * gui.char_height + base_height;
!     }
  
      if (fit_to_display)
      {
--- 1600,1607 ----
  	/* Remember the original window position. */
  	(void)gui_mch_get_winpos(&x, &y);
  
!     width = Columns * gui.char_width + base_width;
!     height = Rows * gui.char_height + base_height;
  
      if (fit_to_display)
      {
***************
*** 5128,5134 ****
  }
  #endif
  
! #if defined(FIND_REPLACE_DIALOG) || defined(FEAT_SUN_WORKSHOP) \
  	|| defined(NEED_GUI_UPDATE_SCREEN) \
  	|| defined(PROTO)
  /*
--- 5113,5119 ----
  }
  #endif
  
! #if defined(FIND_REPLACE_DIALOG) \
  	|| defined(NEED_GUI_UPDATE_SCREEN) \
  	|| defined(PROTO)
  /*
*** ../vim-8.1.0762/src/gui_beval.c	2019-01-13 23:38:33.391773303 +0100
--- src/gui_beval.c	2019-01-17 15:21:35.733424452 +0100
***************
*** 199,206 ****
  #endif
  #endif /* !FEAT_GUI_W32 */
  
! #if defined(FEAT_SUN_WORKSHOP) || defined(FEAT_NETBEANS_INTG) \
!     || defined(FEAT_EVAL) || defined(PROTO)
  # if !defined(FEAT_GUI_W32) || defined(PROTO)
  
  /*
--- 199,205 ----
  #endif
  #endif /* !FEAT_GUI_W32 */
  
! #if defined(FEAT_NETBEANS_INTG) || defined(FEAT_EVAL) || defined(PROTO)
  # if !defined(FEAT_GUI_W32) || defined(PROTO)
  
  /*
***************
*** 216,222 ****
  	undrawBalloon(beval);
  }
  # endif /* !FEAT_GUI_W32 */
! #endif /* FEAT_SUN_WORKSHOP || FEAT_NETBEANS_INTG || PROTO */
  
  #if !defined(FEAT_GUI_W32) || defined(PROTO)
  #if defined(FEAT_BEVAL_TIP) || defined(PROTO)
--- 215,221 ----
  	undrawBalloon(beval);
  }
  # endif /* !FEAT_GUI_W32 */
! #endif /* FEAT_NETBEANS_INTG || PROTO */
  
  #if !defined(FEAT_GUI_W32) || defined(PROTO)
  #if defined(FEAT_BEVAL_TIP) || defined(PROTO)
*** ../vim-8.1.0762/src/gui_motif.c	2018-12-11 20:39:15.442937076 +0100
--- src/gui_motif.c	2019-01-17 15:21:49.653359579 +0100
***************
*** 698,705 ****
      XtVaSetValues(shell, XmNmappedWhenManaged, mappedWhenManaged, NULL);
  }
  
! #if defined(FEAT_MENU) || defined(FEAT_SUN_WORKSHOP) \
! 	|| defined(FEAT_GUI_DIALOG) || defined(PROTO)
  
  /*
   * Encapsulate the way an XmFontList is created.
--- 698,704 ----
      XtVaSetValues(shell, XmNmappedWhenManaged, mappedWhenManaged, NULL);
  }
  
! #if defined(FEAT_MENU) || defined(FEAT_GUI_DIALOG) || defined(PROTO)
  
  /*
   * Encapsulate the way an XmFontList is created.
*** ../vim-8.1.0762/src/gui_x11.c	2019-01-16 22:15:07.872962363 +0100
--- src/gui_x11.c	2019-01-17 15:23:32.516860907 +0100
***************
*** 22,32 ****
  #include <X11/cursorfont.h>
  
  /*
!  * For Workshop XpmP.h is preferred, because it makes the signs drawn with a
!  * transparent background instead of black.
   */
  #if defined(HAVE_XM_XPMP_H) && defined(FEAT_GUI_MOTIF) \
! 	&& (!defined(HAVE_X11_XPM_H) || defined(FEAT_SUN_WORKSHOP))
  # include <Xm/XpmP.h>
  #else
  # ifdef HAVE_X11_XPM_H
--- 22,32 ----
  #include <X11/cursorfont.h>
  
  /*
!  * XpmP.h is preferred, because it makes the signs drawn with a transparent
!  * background instead of black.
   */
  #if defined(HAVE_XM_XPMP_H) && defined(FEAT_GUI_MOTIF) \
! 	&& !defined(HAVE_X11_XPM_H)
  # include <Xm/XpmP.h>
  #else
  # ifdef HAVE_X11_XPM_H
***************
*** 469,475 ****
  	XtRString,
  	DFLT_TOOLTIP_FONT
      },
!     /* This one isn't really needed, keep for Sun Workshop? */
      {
  	"balloonEvalFontSet",
  	XtCFontSet,
--- 469,475 ----
  	XtRString,
  	DFLT_TOOLTIP_FONT
      },
!     /* This one may not be really needed? */
      {
  	"balloonEvalFontSet",
  	XtCFontSet,
***************
*** 636,643 ****
      gui_mch_update();
  }
  
! #if ((defined(FEAT_NETBEANS_INTG) || defined(FEAT_SUN_WORKSHOP)) \
! 	&& defined(FEAT_GUI_MOTIF)) || defined(PROTO)
  /*
   * This function fills in the XRectangle object with the current x,y
   * coordinates and height, width so that an XtVaSetValues to the same shell of
--- 636,642 ----
      gui_mch_update();
  }
  
! #if (defined(FEAT_NETBEANS_INTG) && defined(FEAT_GUI_MOTIF)) || defined(PROTO)
  /*
   * This function fills in the XRectangle object with the current x,y
   * coordinates and height, width so that an XtVaSetValues to the same shell of
***************
*** 701,715 ****
  #endif
  		     );
      }
- #ifdef FEAT_SUN_WORKSHOP
-     if (usingSunWorkShop)
-     {
- 	XRectangle  rec;
- 
- 	shellRectangle(w, &rec);
- 	workshop_frame_moved(rec.x, rec.y, rec.width, rec.height);
-     }
- #endif
  #if defined(FEAT_NETBEANS_INTG) && defined(FEAT_GUI_MOTIF)
      if (netbeans_active())
      {
--- 700,705 ----
***************
*** 1224,1245 ****
  	    argv[*argc] = NULL;
  	}
  	else
- #ifdef FEAT_SUN_WORKSHOP
- 	    if (strcmp("-ws", argv[arg]) == 0)
- 	{
- 	    usingSunWorkShop++;
- 	    p_acd = TRUE;
- 	    gui.dofork = FALSE;	/* don't fork() when starting GUI */
- 	    mch_memmove(&argv[arg], &argv[arg + 1],
- 					    (--*argc - arg) * sizeof(char *));
- 	    argv[*argc] = NULL;
- # ifdef WSDEBUG
- 	    wsdebug_wait(WT_ENV | WT_WAIT | WT_STOP, "SPRO_GVIM_WAIT", 20);
- 	    wsdebug_log_init("SPRO_GVIM_DEBUG", "SPRO_GVIM_DLEVEL");
- # endif
- 	}
- 	else
- #endif
  #ifdef FEAT_NETBEANS_INTG
  	    if (strncmp("-nb", argv[arg], 3) == 0)
  	{
--- 1214,1219 ----
***************
*** 1543,1553 ****
      if (gui.color_approx)
  	emsg(_("Vim E458: Cannot allocate colormap entry, some colors may be incorrect"));
  
- #ifdef FEAT_SUN_WORKSHOP
-     if (usingSunWorkShop)
- 	workshop_connect(app_context);
- #endif
- 
  #ifdef FEAT_BEVAL_GUI
      gui_init_tooltip_font();
  #endif
--- 1517,1522 ----
***************
*** 1681,1689 ****
  #ifdef FEAT_XIM
      xim_init();
  #endif
- #ifdef FEAT_SUN_WORKSHOP
-     workshop_postinit();
- #endif
  
      return OK;
  }
--- 1650,1655 ----
***************
*** 2748,2759 ****
  #endif
  
      focus = gui.in_focus;
! #ifdef ALT_X_INPUT
!     if (suppress_alternate_input)
! 	desired = (XtIMXEvent | XtIMTimer);
!     else
! #endif
! 	desired = (XtIMAll);
      while (!timed_out)
      {
  	/* Stop or start blinking when focus changes */
--- 2714,2720 ----
  #endif
  
      focus = gui.in_focus;
!     desired = (XtIMAll);
      while (!timed_out)
      {
  	/* Stop or start blinking when focus changes */
*** ../vim-8.1.0762/src/integration.c	2019-01-13 23:50:56.358162250 +0100
--- src/integration.c	1970-01-01 01:00:00.000000000 +0100
***************
*** 1,1112 ****
- /* vi:set ts=8 sw=8 noet:
-  *
-  * VIM - Vi IMproved	by Bram Moolenaar
-  *			Visual Workshop integration by Gordon Prieur
-  *
-  * Do ":help uganda"  in Vim to read copying and usage conditions.
-  * Do ":help credits" in Vim to see a list of people who contributed.
-  * See README.txt for an overview of the Vim source code.
-  */
- 
- /*
-  * Integration with Sun Workshop.
-  *
-  * This file should not change much, it's also used by other editors that
-  * connect to Workshop.  Consider changing workshop.c instead.
-  */
- /*
- -> consider using MakeSelectionVisible instead of gotoLine hacks
-    to show the line properly
-      -> consider using glue instead of our own message wrapping functions
- 	(but can only use glue if we don't have to distribute source)
- */
- 
- #include "vim.h"
- 
- #include <stdio.h>
- #include <stdlib.h>
- 
- #ifdef INET_SOCKETS
- #include <netdb.h>
- #include <netinet/in.h>
- #else
- #include <sys/un.h>
- #endif
- 
- #include <sys/types.h>
- #include <sys/socket.h>
- #include <sys/param.h>
- #ifdef HAVE_LIBGEN_H
- # include <libgen.h>
- #endif
- #include <unistd.h>
- #include <string.h>
- 
- #include <X11/Intrinsic.h>
- #include <Xm/Xm.h>
- #include <Xm/AtomMgr.h>
- #include <Xm/PushB.h>
- 
- #ifdef HAVE_X11_XPM_H
- # include <X11/xpm.h>
- #else
- # ifdef HAVE_XM_XPMP_H
- #  include <Xm/XpmP.h>
- # endif
- #endif
- 
- #ifdef HAVE_UTIL_DEBUG_H
- # include <util/debug.h>
- #endif
- #ifdef HAVE_UTIL_MSGI18N_H
- # include <util/msgi18n.h>
- #endif
- 
- #include "integration.h"	/* <EditPlugin/integration.h> */
- #ifdef HAVE_FRAME_H
- # include <frame.h>
- #endif
- 
- #ifndef MAX
- # define MAX(a, b)    (a) > (b) ? (a) : (b)
- #endif
- 
- #ifndef NOCATGETS
- # define NOCATGETS(x) x
- #endif
- 
- /* Functions private to this file */
- static void workshop_disconnect(void);
- static void workshop_sensitivity(int num, char *table);
- static void adjust_sign_name(char *filename);
- static void process_menuItem(char *);
- static void process_toolbarButton(char *);
- static void workshop_set_option_first(char *name, char *value);
- 
- static size_t dummy;  /* to ignore return value of write() */
- 
- #define CMDBUFSIZ	2048
- 
- #ifdef DEBUG
- static FILE *dfd;
- static void pldebug(char *, ...);
- static void unrecognised_message(char *);
- 
- #define HANDLE_ERRORS(cmd)	else unrecognised_message(cmd);
- #else
- #define HANDLE_ERRORS(cmd)
- #endif
- 
- /*
-  * Version number of the protocol between an editor and eserve.
-  * This number should be incremented when the protocol
-  * is changed.
-  */
- #define	PROTOCOL_VERSION	"4.0.0"
- 
- static int sd = -1;
- static XtInputId inputHandler;		/* Cookie for input */
- 
- Boolean save_files = True;		/* When true, save all files before build actions */
- 
- 	static void
- workshop_connection_closed(void)
- {
- 	/*
- 	 * socket closed on other end
- 	 */
- 	XtRemoveInput(inputHandler);
- 	inputHandler = 0;
- 	sd = -1;
- }
- 
- 	static char *
- getCommand(void)
- {
- 	int	 len;		/* length of this command */
- 	char	 lenbuf[7];	/* get the length string here */
- 	char	*newcb;		/* used to realloc cmdbuf */
- 	static char	*cmdbuf;/* get the command string here */
- 	static int	 cbsize;/* size of cmdbuf */
- 
- 	if ((len = read(sd, &lenbuf, 6)) == 6) {
- 		lenbuf[6] = 0; /* Terminate buffer such that atoi() works right */
- 		len = atoi(lenbuf);
- 		if (cbsize < (len + 1)) {
- 			newcb = (char *) realloc(cmdbuf,
- 			    MAX((len + 256), CMDBUFSIZ));
- 			if (newcb != NULL) {
- 				cmdbuf = newcb;
- 				cbsize = MAX((len + 256), CMDBUFSIZ);
- 			}
- 		}
- 		if (cbsize >= len && (len = read(sd, cmdbuf, len)) > 0) {
- 			cmdbuf[len] = 0;
- 			return cmdbuf;
- 		} else {
- 			return NULL;
- 		}
- 	} else {
- 		if (len == 0) { /* EOF */
- 			workshop_connection_closed();
- 		}
- 		return NULL;
- 	}
- 
- }
- 
- 	static void
- messageFromEserve(XtPointer clientData UNUSED,
- 		  int *dum1 UNUSED,
- 		  XtInputId *dum2 UNUSED)
- {
- 	char	*cmd;		/* the 1st word of the command */
- 
- 	cmd = getCommand();
- 	if (cmd == NULL) {
- 		/* We're being shut down by eserve and the "quit" message
- 		 * didn't arrive before the socket connection got closed */
- 		return;
- 	}
- #ifdef DEBUG
- 	pldebug("%s\n", cmd);
- #endif
- 	switch (*cmd) {
- 	case 'a':
- 		if (cmd[1] == 'c' &&
- 		    strncmp(cmd, NOCATGETS("ack "), 4) == 0) {
- 			int ackNum;
- 			char buf[20];
- 
- 			ackNum = atoi(&cmd[4]);
- 			vim_snprintf(buf, sizeof(buf),
- 					       NOCATGETS("ack %d\n"), ackNum);
- 			dummy = write(sd, buf, strlen(buf));
- 		} else if (strncmp(cmd,
- 		    NOCATGETS("addMarkType "), 12) == 0) {
- 			int idx;
- 			char *color;
- 			char *sign;
- 
- 			idx = atoi(strtok(&cmd[12], " "));
- 			color  = strtok(NULL, NOCATGETS("\001"));
- 			sign  = strtok(NULL, NOCATGETS("\001"));
- 			/* Skip space that separates names */
- 			if (color) {
- 				color++;
- 			}
- 			if (sign) {
- 				sign++;
- 			}
- 			/* Change sign name to accommodate a different size? */
- 			adjust_sign_name(sign);
- 			workshop_add_mark_type(idx, color, sign);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'b':
- 		if (strncmp(cmd,
- 		    NOCATGETS("balloon "), 8) == 0) {
- 			char *tip;
- 
- 			tip  = strtok(&cmd[8], NOCATGETS("\001"));
- 			workshop_show_balloon_tip(tip);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'c':
- 		if (strncmp(cmd,
- 		    NOCATGETS("changeMarkType "), 15) == 0) {
- 			char *file;
- 			int markId;
- 			int type;
- 
- 			file  = strtok(&cmd[15], " ");
- 			markId = atoi(strtok(NULL, " "));
- 			type = atoi(strtok(NULL, " "));
- 			workshop_change_mark_type(file, markId, type);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'd':
- 		if (strncmp(cmd, NOCATGETS("deleteMark "), 11) == 0) {
- 			char *file;
- 			int markId;
- 
- 			file  = strtok(&cmd[11], " ");
- 			markId = atoi(strtok(NULL, " "));
- 			workshop_delete_mark(file, markId);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'f':
- 		if (cmd[1] == 'o' &&
- 		    strncmp(cmd, NOCATGETS("footerMsg "), 10) == 0) {
- 			int severity;
- 			char *message;
- 
- 			severity =
- 			    atoi(strtok(&cmd[10], " "));
- 			message = strtok(NULL, NOCATGETS("\001"));
- 
- 			workshop_footer_message(message, severity);
- 		} else if (strncmp(cmd,
- 		    NOCATGETS("frontFile "), 10) == 0) {
- 			char *file;
- 
- 			file  = strtok(&cmd[10], " ");
- 			workshop_front_file(file);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'g':
- 		if (cmd[1] == 'e' &&
- 		    strncmp(cmd, NOCATGETS("getMarkLine "), 12) == 0) {
- 			char *file;
- 			int markid;
- 			int line;
- 			char buf[100];
- 
- 			file  = strtok(&cmd[12], " ");
- 			markid = atoi(strtok(NULL, " "));
- 			line = workshop_get_mark_lineno(file, markid);
- 			vim_snprintf(buf, sizeof(buf),
- 					     NOCATGETS("markLine %s %d %d\n"),
- 			    file, markid, line);
- 			dummy = write(sd, buf, strlen(buf));
- 		} else if (cmd[1] == 'o' && cmd[4] == 'L' &&
- 		    strncmp(cmd, NOCATGETS("gotoLine "), 9) == 0) {
- 			char *file;
- 			int lineno;
- 
- 			file  = strtok(&cmd[9], " ");
- 			lineno = atoi(strtok(NULL, " "));
- 			workshop_goto_line(file, lineno);
- 		} else if (strncmp(cmd,
- 		    NOCATGETS("gotoMark "), 9) == 0) {
- 			char *file;
- 			int markId;
- 			char *message;
- 
- 			file  = strtok(&cmd[9], " ");
- 			markId = atoi(strtok(NULL, " "));
- 			message = strtok(NULL, NOCATGETS("\001"));
- 			workshop_goto_mark(file, markId, message);
- #ifdef NOHANDS_SUPPORT_FUNCTIONS
- 		} else if (strcmp(cmd, NOCATGETS("getCurrentFile")) == 0) {
- 			char *f = workshop_test_getcurrentfile();
- 			char buffer[2*MAXPATHLEN];
- 			vim_snprintf(buffer, sizeof(buffer),
- 					NOCATGETS("currentFile %d %s"),
- 				f ? (int)strlen(f) : 0, f ? f : "");
- 			workshop_send_message(buffer);
- 		} else if (strcmp(cmd, NOCATGETS("getCursorRow")) == 0) {
- 			int row = workshop_test_getcursorrow();
- 			char buffer[2*MAXPATHLEN];
- 			vim_snprintf(buffer, sizeof(buffer),
- 					NOCATGETS("cursorRow %d"), row);
- 			workshop_send_message(buffer);
- 		} else if (strcmp(cmd, NOCATGETS("getCursorCol")) == 0) {
- 			int col = workshop_test_getcursorcol();
- 			char buffer[2*MAXPATHLEN];
- 			vim_snprintf(buffer, sizeof(buffer),
- 					NOCATGETS("cursorCol %d"), col);
- 			workshop_send_message(buffer);
- 		} else if (strcmp(cmd, NOCATGETS("getCursorRowText")) == 0) {
- 			char *t = workshop_test_getcursorrowtext();
- 			char buffer[2*MAXPATHLEN];
- 			vim_snprintf(buffer, sizeof(buffer),
- 					NOCATGETS("cursorRowText %d %s"),
- 				t ? (int)strlen(t) : 0, t ? t : "");
- 			workshop_send_message(buffer);
- 		} else if (strcmp(cmd, NOCATGETS("getSelectedText")) == 0) {
- 			char *t = workshop_test_getselectedtext();
- 			char buffer[2*MAXPATHLEN];
- 			vim_snprintf(buffer, sizeof(buffer),
- 					NOCATGETS("selectedText %d %s"),
- 				t ? (int)strlen(t) : 0, t ? t : "");
- 			workshop_send_message(buffer);
- #endif
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'l':
- 		if (strncmp(cmd, NOCATGETS("loadFile "), 9) == 0) {
- 			char *file;
- 			int line;
- 			char *frameid;
- 
- 			file  = strtok(&cmd[9], " ");
- 			line = atoi(strtok(NULL, " "));
- 			frameid = strtok(NULL, " ");
- 			workshop_load_file(file, line, frameid);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'm':			/* Menu, minimize, maximize */
- 		if (cmd[1] == 'e' && cmd[4] == 'B' &&
- 		    strncmp(cmd, NOCATGETS("menuBegin "), 10) == 0) {
- 			workshop_menu_begin(&cmd[10]);
- 		} else if (cmd[1] == 'e' && cmd[4] == 'I' &&
- 		    strncmp(cmd, NOCATGETS("menuItem "), 9) == 0) {
- 			process_menuItem(cmd);
- 		} else if (cmd[1] == 'e' && cmd[4] == 'E' &&
- 		    strcmp(cmd, NOCATGETS("menuEnd")) == 0) {
- 			workshop_menu_end();
- 		} else if (cmd[1] == 'a' &&
- 		    strcmp(cmd, NOCATGETS("maximize")) == 0) {
- 			workshop_maximize();
- 		} else if (strcmp(cmd, NOCATGETS("minimize")) == 0) {
- 			workshop_minimize();
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'o':
- 		if (cmd[1] == 'p' &&
- 		    strcmp(cmd, NOCATGETS("option"))) {
- 			char *name;
- 			char *value;
- 
- 			name  = strtok(&cmd[7], " ");
- 			value = strtok(NULL, " ");
- 			workshop_set_option_first(name, value);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'p':
- 		if (strcmp(cmd, NOCATGETS("ping")) == 0) {
- #if 0
- 			int pingNum;
- 
- 			pingNum = atoi(&cmd[5]);
- 			workshop_send_ack(ackNum);
- 			/* WHAT DO I DO HERE? */
- #endif
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'q':
- 		if (strncmp(cmd, NOCATGETS("quit"), 4) == 0) {
- 
- 			/* Close the connection. It's important to do
- 			 * that now, since workshop_quit might be
- 			 * looking at open files.  For example, if you
- 			 * have modified one of the files without
- 			 * saving, NEdit will ask you what you want to
- 			 * do, and spin loop by calling
- 			 * XtAppProcessEvent while waiting for your
- 			 * reply. In this case, if we still have an
- 			 * input handler and the socket has been
- 			 * closed on the other side when eserve
- 			 * expired, we will hang in IoWait.
- 			 */
- 			workshop_disconnect();
- 
- 			workshop_quit();
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 'r':
- 		if (cmd[1] == 'e' &&
- 		    strncmp(cmd, NOCATGETS("reloadFile "), 11) == 0) {
- 			char *file;
- 			int line;
- 
- 			file  = strtok(&cmd[11], " ");
- 			line = atoi(strtok(NULL, " "));
- 			workshop_reload_file(file, line);
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 's':
- 		if (cmd[1] == 'e' && cmd[2] == 't' &&
- 		    strncmp(cmd, NOCATGETS("setMark "), 8) == 0) {
- 			char *file;
- 			int line;
- 			int markId;
- 			int type;
- 
- 			file  = strtok(&cmd[8], " ");
- 			line = atoi(strtok(NULL, " "));
- 			markId = atoi(strtok(NULL, " "));
- 			type = atoi(strtok(NULL, " "));
- 			workshop_set_mark(file, line, markId, type);
- 		} else if (cmd[1] == 'h' &&
- 		    strncmp(cmd, NOCATGETS("showFile "), 9) == 0) {
- 			workshop_show_file(&cmd[9]);
- 		} else if (cmd[1] == 'u' &&
- 		    strncmp(cmd, NOCATGETS("subMenu "), 8) == 0) {
- 			char *label;
- 
- 			label  = strtok(&cmd[8], NOCATGETS("\001"));
- 			workshop_submenu_begin(label);
- 		} else if (cmd[1] == 'u' &&
- 		    strcmp(cmd, NOCATGETS("subMenuEnd")) == 0) {
- 			workshop_submenu_end();
- 		} else if (cmd[1] == 'e' && cmd[2] == 'n' &&
- 		    strncmp(cmd, NOCATGETS("sensitivity "), 12) == 0) {
- 			int num;
- 			char *bracket;
- 			char *table;
- 
- 			num = atoi(strtok(&cmd[12], " "));
- 			bracket = strtok(NULL, " ");
- 			if (*bracket != '[') {
- 				fprintf(stderr, NOCATGETS("Parsing "
- 				    "error for sensitivity\n"));
- 			} else {
- 				table = strtok(NULL, NOCATGETS("]"));
- 				workshop_sensitivity(num, table);
- 			}
- 		} else if (cmd[1] == 'e' && cmd[2] == 'n' && cmd[3] == 'd' &&
- 			   strncmp(cmd, NOCATGETS("sendVerb "), 9) == 0) {
- 			/* Send the given verb back (used for the
- 			 * debug.lineno callback (such that other tools
- 			 * can obtain the position coordinates or the
- 			 * selection) */
- 			char *verb;
- 
- 			verb = strtok(&cmd[9], " ");
- 			workshop_perform_verb(verb, NULL);
- 		} else if (cmd[1] == 'a' &&
- 		    strncmp(cmd, NOCATGETS("saveFile "), 9) == 0) {
- 			workshop_save_file(&cmd[9]);
- #ifdef NOHANDS_SUPPORT_FUNCTIONS
- 		} else if (strncmp(cmd, NOCATGETS("saveSensitivity "), 16) == 0) {
- 			char *file;
- 
- 			file  = strtok(&cmd[16], " ");
- 			workshop_save_sensitivity(file);
- #endif
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- 	case 't':			/* Toolbar */
- 		if (cmd[8] == 'e' &&
- 		    strncmp(cmd, NOCATGETS("toolbarBegin"), 12) == 0) {
- 			workshop_toolbar_begin();
- 		} else if (cmd[8] == 'u' &&
- 		    strncmp(cmd, NOCATGETS("toolbarButton"), 13) == 0) {
- 			process_toolbarButton(cmd);
- 		} else if (cmd[7] == 'E' &&
- 		    strcmp(cmd, NOCATGETS("toolbarEnd")) == 0) {
- 			workshop_toolbar_end();
- 		}
- 		HANDLE_ERRORS(cmd);
- 		break;
- 
- #ifdef DEBUG
- 	default:
- 		unrecognised_message(cmd);
- 		break;
- #endif
- 	}
- }
- 
- 	static void
- process_menuItem(
- 	char	*cmd)
- {
- 	char *label  = strtok(&cmd[9], NOCATGETS("\001"));
- 	char *verb  = strtok(NULL, NOCATGETS("\001"));
- 	char *acc = strtok(NULL, NOCATGETS("\001"));
- 	char *accText  = strtok(NULL, NOCATGETS("\001"));
- 	char *name  = strtok(NULL, NOCATGETS("\001"));
- 	char *sense  = strtok(NULL, NOCATGETS("\n"));
- 	char *filepos  = strtok(NULL, NOCATGETS("\n"));
- 	if (*acc == '-') {
- 		acc = NULL;
- 	}
- 	if (*accText == '-') {
- 		accText = NULL;
- 	}
- 	workshop_menu_item(label, verb, acc, accText, name, filepos, sense);
- 
- }
- 
- 
- 	static void
- process_toolbarButton(
- 	char	*cmd)			/* button definition */
- {
- 	char *label  = strtok(&cmd[14], NOCATGETS("\001"));
- 	char *verb  = strtok(NULL, NOCATGETS("\001"));
- 	char *senseVerb  = strtok(NULL, NOCATGETS("\001"));
- 	char *filepos  = strtok(NULL, NOCATGETS("\001"));
- 	char *help  = strtok(NULL, NOCATGETS("\001"));
- 	char *sense  = strtok(NULL, NOCATGETS("\001"));
- 	char *file  = strtok(NULL, NOCATGETS("\001"));
- 	char *left  = strtok(NULL, NOCATGETS("\n"));
- 
- 	if (!strcmp(label, NOCATGETS("-"))) {
- 		label = NULL;
- 	}
- 	if (!strcmp(help, NOCATGETS("-"))) {
- 		help = NULL;
- 	}
- 	if (!strcmp(file, NOCATGETS("-"))) {
- 		file = NULL;
- 	}
- 	if (!strcmp(senseVerb, NOCATGETS("-"))) {
- 		senseVerb = NULL;
- 	}
- 	workshop_toolbar_button(label, verb, senseVerb, filepos, help,
- 				sense, file, left);
- }
- 
- 
- #ifdef DEBUG
- 	static void
- unrecognised_message(
- 	char	*cmd)
- {
- 	pldebug("Unrecognised eserve message:\n\t%s\n", cmd);
- 	/* abort(); */
- }
- #endif
- 
- 
- /* Change sign name to accommodate a different size:
-  * Create the filename based on the height. The filename format
-  * of multisize icons are:
-  *    x.xpm   : largest icon
-  *    x1.xpm  : smaller icon
-  *    x2.xpm  : smallest icon */
- 	static void
- adjust_sign_name(char *filename)
- {
- 	char *s;
- 	static int fontSize = -1;
- 
- 	if (fontSize == -1)
- 		fontSize = workshop_get_font_height();
- 	if (fontSize == 0)
- 		return;
- 	if (filename[0] == '-')
- 		return;
- 
- 	/* This is ugly: later we should instead pass the fontheight over
- 	 * to eserve on startup and let eserve just send the right filenames
- 	 * to us in the first place
- 
- 	 * I know that the filename will end with 1.xpm (see
- 	 * GuiEditor.cc`LispPrintSign if you wonder why) */
- 	s = filename+strlen(filename)-5;
- 	if (fontSize <= 11)
- 		strcpy(s, "2.xpm");
- 	else if (fontSize <= 15)
- 		strcpy(s, "1.xpm");
- 	else
- 		strcpy(s, ".xpm");
- }
- 
- #if 0
- /* Were we invoked by WorkShop? This function can be used early during startup
-    if you want to do things differently if the editor is started standalone
-    or in WorkShop mode. For example, in standalone mode you may not want to
-    add a footer/message area or a sign gutter. */
- 	int
- workshop_invoked(void)
- {
- 	static int result = -1;
- 	if (result == -1) {
- 		result = (getenv(NOCATGETS("SPRO_EDITOR_SOCKET")) != NULL);
- 	}
- 	return result;
- }
- #endif
- 
- /* Connect back to eserve */
- void	workshop_connect(XtAppContext context)
- {
- #ifdef INET_SOCKETS
- 	struct sockaddr_in	server;
- 	struct hostent *	host;
- 	int			port;
- #else
- 	struct sockaddr_un	server;
- #endif
- 	char			buf[32];
- 	char *			address;
- #ifdef DEBUG
- 	char			*file;
- #endif
- 
- 	address = getenv(NOCATGETS("SPRO_EDITOR_SOCKET"));
- 	if (address == NULL) {
- 		return;
- 	}
- 
- #ifdef INET_SOCKETS
- 	port = atoi(address);
- 
- 	if ((sd = socket(AF_INET, SOCK_STREAM, 0)) == -1) {
- 		PERROR(NOCATGETS("workshop_connect"));
- 		return;
- 	}
- 
- 	/* Get the server internet address and put into addr structure */
- 	/* fill in the socket address structure and connect to server */
- 	vim_memset((char *)&server, '\0', sizeof(server));
- 	server.sin_family = AF_INET;
- 	server.sin_port = port;
- 	if ((host = gethostbyname(NOCATGETS("localhost"))) == NULL) {
- 		PERROR(NOCATGETS("gethostbyname"));
- 		sd = -1;
- 		return;
- 	}
- 	memcpy((char *)&server.sin_addr, host->h_addr, host->h_length);
- #else
- 	if ((sd = socket(AF_UNIX, SOCK_STREAM, 0)) == -1) {
- 		PERROR(NOCATGETS("workshop_connect"));
- 		return;
- 	}
- 
- 	server.sun_family = AF_UNIX;
- 	strcpy(server.sun_path, address);
- #endif
- 	/* Connect to server */
- 	if (connect(sd, (struct sockaddr *)&server, sizeof(server))) {
- 		if (errno == ECONNREFUSED) {
- 			close(sd);
- #ifdef INET_SOCKETS
- 			if ((sd = socket(AF_INET, SOCK_STREAM, 0)) == -1) {
- 				PERROR(NOCATGETS("workshop_connect"));
- 				return;
- 			}
- #else
- 			if ((sd = socket(AF_UNIX, SOCK_STREAM, 0)) == -1) {
- 				PERROR(NOCATGETS("workshop_connect"));
- 				return;
- 			}
- #endif
- 			if (connect(sd, (struct sockaddr *)&server,
- 						sizeof(server))) {
- 				PERROR(NOCATGETS("workshop_connect"));
- 				return;
- 			}
- 
- 		} else {
- 			PERROR(NOCATGETS("workshop_connect"));
- 			return;
- 		}
- 	}
- 
- 	/* tell notifier we are interested in being called
- 	 * when there is input on the editor connection socket
- 	 */
- 	inputHandler = XtAppAddInput(context, sd, (XtPointer) XtInputReadMask,
- 				     messageFromEserve, NULL);
- #ifdef DEBUG
- 	if ((file = getenv(NOCATGETS("SPRO_PLUGIN_DEBUG"))) != NULL) {
- 		char buf[BUFSIZ];
- 
- 		unlink(file);
- 		vim_snprintf(buf, sizeof(buf), "date > %s", file);
- 		system(buf);
- 		dfd = fopen(file, "a");
- 	} else {
- 		dfd = NULL;
- 	}
- #endif
- 
- 	vim_snprintf(buf, sizeof(buf), NOCATGETS("connected %s %s %s\n"),
- 		workshop_get_editor_name(),
- 		PROTOCOL_VERSION,
- 		workshop_get_editor_version());
- 	dummy = write(sd, buf, strlen(buf));
- 
- 	vim_snprintf(buf, sizeof(buf), NOCATGETS("ack 1\n"));
- 	dummy = write(sd, buf, strlen(buf));
- }
- 
- 	static void
- workshop_disconnect(void)
- {
- 	/* Probably need to send some message here */
- 
- 	/*
- 	 * socket closed on other end
- 	 */
- 	XtRemoveInput(inputHandler);
- 	close(sd);
- 	inputHandler = 0;
- 	sd = -1;
- 
- }
- 
- /*
-  * Utility functions
-  */
- 
- 
- /* Minimize and maximize shells. From libutil's shell.cc. */
- 
- /* utility functions from libutil's shell.cc */
- static Boolean
- isWindowMapped(Display *display, Window win)
- {
- 	XWindowAttributes winAttrs;
- 	XGetWindowAttributes(display,
- 			     win,
- 			     &winAttrs);
- 	if (winAttrs.map_state == IsViewable) {
- 		return(True);
- 	} else {
- 		return(False);
- 	}
- }
- 
- static Boolean
- isMapped(Widget widget)
- {
- 	if (widget == NULL) {
- 		return(False);
- 	}
- 
- 	if (XtIsRealized(widget) == False) {
- 		return(False);
- 	}
- 
- 	return(isWindowMapped(XtDisplay(widget), XtWindow(widget)));
- }
- 
- static Boolean
- widgetIsIconified(
- 	Widget		 w)
- {
- 	Atom		 wm_state;
- 	Atom		 act_type;		/* actual Atom type returned */
- 	int		 act_fmt;		/* actual format returned */
- 	u_long		 nitems_ret;		/* number of items returned */
- 	u_long		 bytes_after;		/* number of bytes remaining */
- 	u_long		*property;		/* actual property returned */
- 
- 	/*
- 	 * If a window is iconified its WM_STATE is set to IconicState. See
- 	 * ICCCM Version 2.0, section 4.1.3.1 for more details.
- 	 */
- 
- 	wm_state = XmInternAtom(XtDisplay(w), NOCATGETS("WM_STATE"), False);
- 	if (XtWindow(w) != 0) {			/* only check if window exists! */
- 		XGetWindowProperty(XtDisplay(w), XtWindow(w), wm_state, 0L, 2L,
- 		    False, AnyPropertyType, &act_type, &act_fmt, &nitems_ret,
- 		    &bytes_after, (char_u **) &property);
- 		if (nitems_ret == 2 && property[0] == IconicState) {
- 			return True;
- 		}
- 	}
- 
- 	return False;
- 
- }    /* end widgetIsIconified */
- 
- void
- workshop_minimize_shell(Widget shell)
- {
- 	if (shell != NULL &&
- 	    XtIsObject(shell) &&
- 	    XtIsRealized(shell) == True) {
- 		if (isMapped(shell) == True) {
- 			XIconifyWindow(XtDisplay(shell), XtWindow(shell),
- 			       XScreenNumberOfScreen(XtScreen(shell)));
- 		}
- 		XtVaSetValues(shell,
- 			      XmNiconic, True,
- 			      NULL);
- 	}
- }
- 
- void workshop_maximize_shell(Widget shell)
- {
- 	if (shell != NULL &&
- 	    XtIsRealized(shell) == True &&
- 	    widgetIsIconified(shell) == True &&
- 	    isMapped(shell) == False) {
- 		XtMapWidget(shell);
- 		/* This used to be
- 		     XtPopdown(shell);
- 		     XtPopup(shell, XtGrabNone);
- 		   However, I found that that would drop any transient
- 		   windows that had been iconified with the window.
- 		   According to the ICCCM, XtMapWidget should be used
- 		   to bring a window from Iconic to Normal state.
- 		   However, Rich Mauri did a lot of work on this during
- 		   Bart, and found that XtPopDown,XtPopup was required
- 		   to fix several bugs involving multiple CDE workspaces.
- 		   I've tested it now and things seem to work fine but
- 		   I'm leaving this note for history in case this needs
- 		   to be revisited.
- 		*/
- 	}
- }
- 
- 
- Boolean workshop_get_width_height(int *width, int *height)
- {
- 	static int	wid = 0;
- 	static int	hgt = 0;
- 	static Boolean	firstTime = True;
- 	static Boolean	success = False;
- 
- 	if (firstTime) {
- 		char	*settings;
- 
- 		settings = getenv(NOCATGETS("SPRO_GUI_WIDTH_HEIGHT"));
- 		if (settings != NULL) {
- 			wid = atoi(settings);
- 			settings = strrchr(settings, ':');
- 			if (settings++ != NULL) {
- 				hgt = atoi(settings);
- 			}
- 			if (wid > 0 && hgt > 0) {
- 				success = True;
- 			}
- 			firstTime = False;
- 		}
- 	}
- 
- 	if (success) {
- 		*width = wid;
- 		*height = hgt;
- 	}
- 	return success;
- }
- 
- /*
-  * Toolbar code
-  */
- 
- 	static void
- workshop_sensitivity(int num, char *table)
- {
- 	/* build up a verb table */
- 	VerbSense *vs;
- 	int i;
- 	char *s;
- 	if ((num < 1) || (num > 500)) {
- 		return;
- 	}
- 
- 	vs = (VerbSense *)malloc((num+1)*sizeof(VerbSense));
- 
- 	/* Point to the individual names (destroys the table string, but
- 	 * that's okay -- this is more efficient than duplicating strings) */
- 	s = table;
- 	for (i = 0; i < num; i++) {
- 		while (*s == ' ') {
- 			s++;
- 		}
- 		vs[i].verb = s;
- 		while (*s && (*s != ' ') && (*s != '\001')) {
- 			s++;
- 		}
- 		if (*s == 0) {
- 			vs[i].verb = NULL;
- 			break;
- 		}
- 		if (*s == '\001') {
- 			*s = 0;
- 			s++;
- 		}
- 		*s = 0;
- 		s++;
- 		while (*s == ' ') {
- 			s++;
- 		}
- 		if (*s == '1') {
- 			vs[i].sense = 1;
- 		} else {
- 			vs[i].sense = 0;
- 		}
- 		s++;
- 	}
- 	vs[i].verb = NULL;
- 
- 	workshop_frame_sensitivities(vs);
- 
- 	free(vs);
- }
- 
- /*
-  * Options code
-  */
- /* Set an editor option.
-  * IGNORE an option if you do not recognize it.
-  */
- 	static void
- workshop_set_option_first(char *name, char *value)
- {
- 	/* Currently value can only be on/off. This may change later (for
- 	 * example to set an option like "balloon evaluate delay", but
- 	 * for now just convert it into a boolean */
- 	Boolean on = !strcmp(value, "on");
- 
- 	if (!strcmp(name, "workshopkeys")) {
- 		workshop_hotkeys(on);
- 	} else if (!strcmp(name, "savefiles")) {
- 		save_files = on;
- 	} else if (!strcmp(name, "balloon")) {
- 		workshop_balloon_mode(on);
- 	} else if (!strcmp(name, "balloondelay")) {
- 		int delay = atoi(value);
- 		/* Should I validate the number here?? */
- 		workshop_balloon_delay(delay);
- 	} else {
- 		/* Let editor interpret it */
- 		workshop_set_option(name, value);
- 	}
- }
- 
- 
- void workshop_file_closed_lineno(char *filename, int lineno)
- {
- 	char buffer[2*MAXPATHLEN];
- 	vim_snprintf(buffer, sizeof(buffer),
- 			NOCATGETS("deletedFile %s %d\n"), filename, lineno);
- 	dummy = write(sd, buffer, strlen(buffer));
- }
- 
- void workshop_file_opened(char *filename, int readOnly)
- {
- 	char buffer[2*MAXPATHLEN];
- 	vim_snprintf(buffer, sizeof(buffer),
- 			NOCATGETS("loadedFile %s %d\n"), filename, readOnly);
- 	dummy = write(sd, buffer, strlen(buffer));
- }
- 
- 
- void workshop_file_saved(char *filename)
- {
- 	char buffer[2*MAXPATHLEN];
- 	vim_snprintf(buffer, sizeof(buffer),
- 			NOCATGETS("savedFile %s\n"), filename);
- 	dummy = write(sd, buffer, strlen(buffer));
- 
- 	/* Let editor report any moved marks that the eserve client
- 	 * should deal with (for example, moving location-based breakpoints) */
- 	workshop_moved_marks(filename);
- }
- 
- void workshop_frame_moved(int new_x, int new_y, int new_w, int new_h)
- {
- 	char buffer[200];
- 
- 	if (sd >= 0)
- 	{
- 		vim_snprintf(buffer, sizeof(buffer),
- 				NOCATGETS("frameAt %d %d %d %d\n"),
- 				new_x, new_y, new_w, new_h);
- 		dummy = write(sd, buffer, strlen(buffer));
- 	}
- }
- 
- /* A button in the toolbar has been pushed.
-  * Clientdata is a pointer used by the editor code to figure out the
-  * positions for this toolbar (probably by storing a window pointer,
-  * and then fetching the current buffer for that window and looking up
-  * cursor and selection positions etc.) */
- void workshop_perform_verb(char *verb, void *clientData)
- {
- 	char *filename;
- 	int curLine;
- 	int curCol;
- 	int selStartLine;
- 	int selStartCol;
- 	int selEndLine;
- 	int selEndCol;
- 	int selLength;
- 	char *selection;
- 
- 	char buf[2*MAXPATHLEN];
- /* Later: needsFilePos indicates whether or not we need to fetch all this
-  * info for this verb... for now, however, it looks as if
-  * eserve parsing routines depend on it always being present */
- 
- 	if (workshop_get_positions(clientData,
- 				   &filename,
- 				   &curLine,
- 				   &curCol,
- 				   &selStartLine,
- 				   &selStartCol,
- 				   &selEndLine,
- 				   &selEndCol,
- 				   &selLength,
- 				   &selection)) {
- 		if (selection == NULL) {
- 			selection = NOCATGETS("");
- 		}
- 
- 		/* Should I save the files??? This is currently done by checking
- 		   if the verb is one of a few recognized ones. Later we can pass
- 		   this list from eserve to the editor (it's currently hardcoded in
- 		   vi and emacs as well). */
- 		if (save_files) {
- 			if (!strcmp(verb, "build.build") || !strcmp(verb, "build.build-file") ||
- 			    !strcmp(verb, "debug.fix") || !strcmp(verb, "debug.fix-all")) {
- 				workshop_save_files();
- 			}
- 		}
- 
- 		vim_snprintf(buf, sizeof(buf),
- 			NOCATGETS("toolVerb %s %s %d,%d %d,%d %d,%d %d %s\n"),
- 			verb,
- 			filename,
- 			curLine, curCol,
- 			selStartLine, selStartCol,
- 			selEndLine, selEndCol,
- 			selLength,
- 			selection);
- 		dummy = write(sd, buf, strlen(buf));
- 		if (*selection) {
- 			free(selection);
- 		}
- 	}
- }
- 
- /* Send a message to eserve */
- #if defined(NOHANDS_SUPPORT_FUNCTIONS) || defined(FEAT_BEVAL_GUI)
- void workshop_send_message(char *buf)
- {
- 	dummy = write(sd, buf, strlen(buf));
- }
- #endif
- 
- /* Some methods, like currentFile, cursorPos, etc. are missing here.
-  * But it looks like these are used for NoHands testing only so we
-  * won't bother requiring editors to implement these
-  */
- 
- 
- #ifdef DEBUG
- 
- 	static void
- pldebug(
- 	char		*fmt,	/* a printf style format line */
- 	...)
- {
- 	va_list		 ap;
- 
- 	if (dfd != NULL) {
- 		va_start(ap, fmt);
- 		vfprintf(dfd, fmt, ap);
- 		va_end(ap);
- 		fflush(dfd);
- 	}
- 
- }    /* end pldebug */
- 
- #endif
--- 0 ----
*** ../vim-8.1.0762/src/integration.h	2016-08-29 22:42:20.000000000 +0200
--- src/integration.h	1970-01-01 01:00:00.000000000 +0100
***************
*** 1,452 ****
- /* vi:set ts=8 sts=4 sw=4 noet:
-  *
-  * VIM - Vi IMproved	by Bram Moolenaar
-  *			Visual Workshop integration by Gordon Prieur
-  *
-  * Do ":help uganda"  in Vim to read copying and usage conditions.
-  * Do ":help credits" in Vim to see a list of people who contributed.
-  */
- /*
-   THIS IS AN UNSTABLE INTERFACE! It is unsupported and will likely
-   change in future releases, possibly breaking compatibility!
- */
- 
- #ifndef _INTEGRATION_H
- #define _INTEGRATION_H
- 
- #include <X11/Intrinsic.h>
- #include <Xm/Xm.h>
- 
- #ifdef  __cplusplus
- extern "C" {
- #endif
- 
- /* Enable NoHands test support functions. Define this only if you want to
-    compile in support in the editor such that it can be run under
-    the WorkShop test suite. */
- #ifndef NOHANDS_SUPPORT_FUNCTIONS
- #define NOHANDS_SUPPORT_FUNCTIONS
- #endif
- 
- 
- /* This header file has three parts.
-  * 1. Functions you need to implement; these are called by the integration
-  *    library
-  * 2. Functions you need to call when certain events happen in the editor;
-  *    these are implemented by the integration library
-  * 3. Utility functions provided by the integration library; these make
-  *	  task 1 a bit easier.
-  */
- 
- /*
-  * The following functions need to be implemented by the editor
-  * integration code (and will be editor-specific). Please see the
-  * sample workshop.c file for comments explaining what each functions
-  * needs to do, what the arguments mean, etc.
-  */
- 
- /*
-  * This string is recognized by eserve and should be all lower case.
-  * This is how the editor detects that it is talking to NEdit instead
-  * of Vim, for example, when the connection is initiated from the editor.
-  * Examples: "nedit", "gvim"
-  */
- char *workshop_get_editor_name();
- 
- /*
-  * Version number of the editor.
-  * This number is communicated along with the protocol
-  * version to the application.
-  * Examples: "5.0.2", "19.3"
-  */
- char *workshop_get_editor_version();
- 
- 
- /* Goto a given line in a given file */
- void workshop_goto_line(char *filename, int lineno);
- 
- 
- /* Set mark in a given file */
- void workshop_set_mark(char *filename, int lineno, int markId, int type);
- 
- 
- /* Change mark type (for example from current-pc to pc-and-breakpoint) */
- void workshop_change_mark_type(char *filename, int markId, int type);
- 
- /*
-  * Goto the given mark in a file (e.g. show it).
-  * If message is not null, display it in the footer.
-  */
- 
- void workshop_goto_mark(char *filename, int markId, char *message);
- 
- 
- /* Delete mark */
- void workshop_delete_mark(char *filename, int markId);
- 
- /* Begin/end pair of messages indicating that a series of _set_mark and
-  * _delete_mark messages will be sent. This can/should be used to suppress gui
-  * redraws between the begin and end messages. For example, if you switch
-  * to a headerfile that has a class breakpoint set, there may be hundreds
-  * of marks that need to be added. You don't want to refresh the gui for each
-  * added sign, you want to wait until the final end message.
-  */
- void workshop_mark_batch_begin();
- void workshop_mark_batch_end();
- 
- 
- /* Load a given file into the WorkShop buffer. "frameid" is a token string
-  * that identifies which frame the file would like to be loaded into. This
-  * will usually be null, in which case you should use the default frame.
-  * However, if frameid is not null, you need to find a frame that has this
-  * frameid, and replace the file in that frame. Finally, if the frameid is
-  * one you haven't seen before, you should create a new frame for this file.
-  * Note that "frameid" is a string value, not just an opaque pointer, so
-  * you should use strcmp rather than == when testing for equality.
-  */
- void workshop_load_file(char *filename, int line, char *frameid);
- 
- 
- /* Reload the WorkShop buffer */
- void workshop_reload_file(char *filename, int line);
- 
- 
- /* Show the given file */
- void workshop_show_file(char *filename);
- 
- 
- /* Front the given file */
- void workshop_front_file(char *filename);
- 
- 
- /* Save the given file  */
- void workshop_save_file(char *filename);
- 
- /* Save all WorkShop edited files. You can ask user about modified files
-  * and skip saving any files the user doesn't want to save.
-  * This function is typically called when the user issues a build, a fix,
-  * etc. (and also if you select "Save All" from the File menu :-)
-  */
- void workshop_save_files();
- 
- /* Show a message in all footers.
-    Severity currently is not defined. */
- void workshop_footer_message(char *message, int severity);
- 
- /* Minimize all windows */
- void workshop_minimize();
- 
- 
- /* Maximize all windows */
- void workshop_maximize();
- 
- 
- /*
-  * Create a new mark type, assign it a given index, a given textbackground
-  * color, and a given left-margin sign (where sign is a filename to an
-  * .xpm file)
-  */
- void workshop_add_mark_type(int idx, char *colorspec, char *sign);
- 
- 
- /* Get mark line number */
- int workshop_get_mark_lineno(char *filename, int markId);
- 
- 
- /* Exit editor; save confirmation dialogs are okay */
- void workshop_quit();
- 
- /* Set an editor option.
-  * For example, name="syntax",value="on" would enable syntax highlighting.
-  * The currently defined options are:
-  *    lineno		{on,off}	show line numbers
-  *    syntax		{on,off}	highlight syntax
-  *    parentheses	{on,off}	show matching parentheses
-  * The following options are interpreted by the library for you (so you
-  * will never see the message. However, the implementation requires you
-  * to provide certain callbacks, like restore hotkeys or save all files.
-  * These are documented separately).
-  *    workshopkeys	{on,off}	set workshop hotkeys
-  *    savefiles		{on,off}	save all files before issuing a build
-  *    balloon		{on,off}	enable/disable balloon evaluate
-  *
-  * IGNORE an option if you do not recognize it.
-  */
- void workshop_set_option(char *name, char *value);
- 
- /*
-  * (See workshop_add_frame first.) This function notifies the editor
-  * that the frame for the given window (indicated by "frame", which
-  * was supplied by the editor in workshop_add_frame) has been created.
-  * This can happen much later than the workshop_add_frame message, since
-  * often a window is created on editor startup, while the frame description
-  * is passed over from eserve much later, when the connection is complete.
-  * This gives the editor a chance to kick its GUI to show the frame
-  * properly; typically you'll unmanage and remanage the parent widget to
-  * force a geometry recalculation.
-  */
- 
- void workshop_reconfigure_frame(void *frame);
- 
- 
- /* Are there any moved marks? If so, call workshop_move_mark on
-  * each of them now. This is how eserve can find out if for example
-  * breakpoints have moved when a program has been recompiled and
-  * reloaded into dbx.
-  */
- void workshop_moved_marks(char *filename);
- 
- 
- /* A button in the toolbar has been pushed. "frame" is provided
-  * which should let you determine which toolbar had a button pushed
-  * (you supplied this clientData when you created a toolbar). From
-  * this you should be able to figure out which file the operation
-  * applies to, and for that window the cursor line and column,
-  * selection begin line and column, selection end line and column,
-  * selection text and selection text length. The column numbers are
-  * currently unused but implement it anyway in case we decide to use
-  * them in the future.
-  * Note that frame can be NULL. In this case, you should pick
-  * a default window to translate coordinates for (ideally, the
-  * last window the user has operated on.) This will be the case when
-  * the user clicks on a Custom Button programmed to take the current
-  * line number as an argument. Here it's ambiguous which buffer
-  * to use, so you need to pick one.
-  * (Interface consideration: Perhaps we instead should add smarts
-  * into the library such that we remember which frame pointer
-  * we last noticed (e.g. last call to get_positions, or perhaps
-  * last add_frame) and then pass that instead? For example, we could
-  * have all workshop operations return the clientData when passed
-  * the filename (or add a filename-to-clientData converter?) and then
-  * remember the last filename/clientData used.
-  */
- int workshop_get_positions(void *frame,
- 			   char **filename,
- 			   int *curLine,
- 			   int *curCol,
- 			   int *selStartLine,
- 			   int *selStartCol,
- 			   int *selEndLine,
- 			   int *selEndCol,
- 			   int *selLength,
- 			   char **selection);
- 
- /* The following function should return the height of a character
-  * in the text display. This is used to pick out a suitable size
-  * for the signs to match the text (currently available in three
-  * sizes). If you just return 0, WorkShop will use the default
-  * sign size. (Use XmStringExtent on character "A" to get the height.)
-  */
- 
- int workshop_get_font_height(void);
- 
- /* The following function requests that you register the given
-  * hotkey as a keyboard accelerator for all frames. Whenever the
-  * hotkey is pressed, you should invoke  workshop_hotkey_pressed
-  * and pass the current frame pointer as an argument as well as
-  * the clientData pointer passed in to this function.
-  * The remove function unregisters the hotkey.
-  */
- void workshop_register_hotkey(Modifiers modifiers, KeySym keysym,
- 			      void *clientData);
- void workshop_unregister_hotkey(Modifiers modifiers, KeySym keysym,
- 				void *clientData);
- 
- 
- 
- 
- /*
-  *
-  * The following functions notify eserve of important editor events,
-  * such as files being modified, files being saved, etc. You must
-  * sprinkle your editor code with calls to these. For example, whenever
-  * a file is modified (well, when its read-only status changes to modified),
-  * call workshop_file_modified().
-  *
-  */
- 
- 
- 
- /* Connect with eserve. Add this call after you editor initialization
-  * is done, right before entering the event loop or blocking on input.
-  * This will set up a socket connection with eserve.
-  */
- void workshop_connect(XtAppContext context);
- 
- /* A file has been opened. */
- void workshop_file_opened(char *filename, int readOnly);
- 
- 
- /* A file has been saved. Despite its name, eserve also uses this
-  * message to mean a file has been reverted or unmodified.
-  */
- void workshop_file_saved(char *filename);
- 
- 
- #if 0
- /* A file has been closed */
- void workshop_file_closed(char *filename);
- #endif
- 
- /* Like workshop_file_closed, but also inform eserve what line the
-    cursor was on when you left the file. That way eserve can put you
-    back where you left off when you return to this file. */
- void workshop_file_closed_lineno(char *filename, int line);
- 
- #if 0
- /* A file has been modified */
- void workshop_file_modified(char *filename);
- 
- /*
-  * A mark has been moved. Only call this as a response to
-  * a workshop_moved_marks request call.
-  */
- void workshop_move_mark(char *filename, int markId, int newLineno);
- #endif
- 
- /* Tell the integration library about a new frame being added.
-  * Supply a form for the toolbar, a label for the footer, and an
-  * XmPulldown menu for the WorkShop menu to attach to. Top and bottom
-  * are the widgets above and below the toolbar form widget, if
-  * any. Call this function when you create a new window. It returns a
-  * void *, a handle which you should keep and return when you delete
-  * the window with workshop_delete_toolbar.  The "footer" argument
-  * points to a Label widget that is going to be used as a status
-  * message area, and "menu" (if any) points to an Menu widget that
-  * should contain a WorkShop menu.  Clientdata is a pointer which is
-  * only used by the editor. It will typically be a pointer to the
-  * window object that the toolbar is placed in. If you have multiple
-  * windows, you need to use this pointer to figure out which window
-  * (and thus corresponding buffer) the user has clicked on to respond
-  * to the workshop_get_positions message.
-  * Each frame's clientData ("frame") should be unique.
-  */
- void *workshop_add_frame(void *frame, Widget form,
- 			   Widget top, Widget bottom, Widget footer,
- 			   Widget menu);
- 
- /* Delete a window/frame. Call this when an editor window is being deleted. */
- void workshop_delete_frame(void *handle);
- 
- /* Add a balloon evaluate text area. "frame" is used the same way
-  * as in workshop_add_frame. This call is not part of workshop_add_frame because
-  * a frame can have multiple tooltip areas (typically, an editor frame that
-  * is split showing multiple buffers will have a separate tooltip area for
-  * each text widget. Each such area is called a "window" (consistent with
-  * XEmacs terminology). Separate these by the window argument if necessary.
-  * You will need to implement workshop_get_balloon_text such that it uses
-  * these two arguments to derive the file, line etc. for the tip.
-  * Call the remove function if you delete this area such that the integration
-  * library can update itself. You must call workshop_add_frame before you
-  * call add_balloon_eval_area, and you must pass the same frame pointer.
-  */
- void workshop_add_balloon_eval_area(void *frame, void *window, Widget widget);
- void workshop_remove_balloon_eval_area(void *frame, void *window, Widget widget);
- 
- 
- /* For a given mouse position inside the balloon area (passed as x,y),
-  * return the balloon text to be evaluated. There are two scenarios:
-  * If the position is inside the selection, return the selection
-  * string.  Else, return the full line (or possibly the full line up
-  * to the last semicolon (that's TBD), along with an index pointing to
-  * where which character the mouse is over.
-  * If we have the selection-scenario, set mouseIndex to -1 to indicate
-  * that no autoexpansion should occur but that the selection should
-  * be evaluated as is.
-  *
-  * XXX Does dbx need more information here, like the filename and line
-  * number in order to determine the correct language and scope to be
-  * used during evaluation?? Or should it just work like the p= button
-  * (where the current scope and language is used, even if you are
-  * pointing at a different file with a different scope) ?
-  */
- int workshop_get_balloon_text(Position x, Position y,
- 			      void *frame,
- 			      void *window,
- 			      char **filename,
- 			      int *line,
- 			      char **text,
- 			      int *mouseIndex);
- 
- 
- /* Window size and location
-  * WorkShop will attempt to restore the size and location of a single
-  * editor frame. For vi, this window is designated as the "reusable" one.
-  * You can implement your own scheme for determining which window you
-  * want to associate with WorkShop. Whenever the size and location of
-  * this window is changed, call the following function to notify eserve.
-  * Like workshop_invoked, this can be called before the workshop_connect()
-  * call.
-  */
- void workshop_frame_moved(int new_x, int new_y, int new_w, int new_h);
- Boolean workshop_get_width_height(int *, int *);
- #if 0
- Boolean workshop_get_rows_cols(int *, int *);
- #endif
- 
- /* This function should be invoked when you press a hotkey
-  * set up by workshop_register_hotkey. Pass the clientData
-  * to it that was given to you with workshop_register_hotkey.
- */
- void workshop_hotkey_pressed(void *frame, void *clientData);
- 
- 
- 
- 
- 
- /*
-  * Utility functions
-  * These provide convenience functions to simplify implementing some
-  * of the above functions.
-  *
-  */
- 
- #if 0
- /* Were we invoked by WorkShop? This function can be used early during startup
-  * if you want to do things differently if the editor is started standalone
-  * or in WorkShop mode. For example, in standalone mode you may not want to
-  * add a footer/message area or a sign gutter.
-  */
- int workshop_invoked(void);
- #endif
- 
- 
- /* Minimize (iconify) the given shell */
- void workshop_minimize_shell(Widget shell);
- 
- /* Maximize (deiconify) the given shell */
- void workshop_maximize_shell(Widget shell);
- 
- /* Called by frame.cc -- editor shouldn't call this directly.
-  * Perhaps we need an integrationP.h file ? */
- void workshop_perform_verb(char *verb, void *clientData);
- void workshop_send_message(char *buf);
- 
- 
- #ifdef NOHANDS_SUPPORT_FUNCTIONS
- /* The following functions are needed to run the WorkShop testsuite
-  * with this editor. You don't need to implement these unless you
-  * intend for your editor to be run by Workshop's testsuite.
-  * getcursorrow should return the number of lines from the top of
-  * the window the cursor is; similarly for getcursorcol.
-  */
- char *workshop_test_getcurrentfile();
- int workshop_test_getcursorrow();
- int workshop_test_getcursorcol();
- char *workshop_test_getcursorrowtext();
- char *workshop_test_getselectedtext();
- #endif
- 
- /*
-  * Struct used to set/unset the sensitivity of verbs.
-  */
- typedef struct {
- 	char		*verb;
- 	Boolean		sense;
- } VerbSense;
- 
- #ifdef  __cplusplus
- }
- #endif
- 
- #endif /* _INTEGRATION_H */
--- 0 ----
*** ../vim-8.1.0762/src/main.c	2019-01-14 21:51:17.987461933 +0100
--- src/main.c	2019-01-17 15:23:50.756769234 +0100
***************
*** 628,637 ****
       */
      if (gui.in_use)
      {
! # ifdef FEAT_SUN_WORKSHOP
! 	if (!usingSunWorkShop)
! # endif
! 	    gui_wait_for_chars(50L, typebuf.tb_change_cnt);
  	TIME_MSG("GUI delay");
      }
  #endif
--- 628,634 ----
       */
      if (gui.in_use)
      {
! 	gui_wait_for_chars(50L, typebuf.tb_change_cnt);
  	TIME_MSG("GUI delay");
      }
  #endif
***************
*** 983,991 ****
       */
      early_arg_scan(paramp);
  
- #ifdef FEAT_SUN_WORKSHOP
-     findYourself(paramp->argv[0]);
- #endif
  #if defined(FEAT_GUI)
      /* Prepare for possibly starting GUI sometime */
      gui_prepare(&paramp->argc, paramp->argv);
--- 980,985 ----
*** ../vim-8.1.0762/src/misc2.c	2019-01-13 23:38:33.403773217 +0100
--- src/misc2.c	2019-01-17 15:24:05.616693884 +0100
***************
*** 3411,3417 ****
  
  #if defined(FEAT_SESSION) || defined(FEAT_AUTOCHDIR) \
  	|| defined(MSWIN) || defined(FEAT_GUI_MAC) || defined(FEAT_GUI_GTK) \
! 	|| defined(FEAT_SUN_WORKSHOP) || defined(FEAT_NETBEANS_INTG) \
  	|| defined(PROTO)
  /*
   * Change to a file's directory.
--- 3411,3417 ----
  
  #if defined(FEAT_SESSION) || defined(FEAT_AUTOCHDIR) \
  	|| defined(MSWIN) || defined(FEAT_GUI_MAC) || defined(FEAT_GUI_GTK) \
! 	|| defined(FEAT_NETBEANS_INTG) \
  	|| defined(PROTO)
  /*
   * Change to a file's directory.
*** ../vim-8.1.0762/src/nbdebug.c	2016-09-25 21:41:24.000000000 +0200
--- src/nbdebug.c	2019-01-17 15:24:41.628508930 +0100
***************
*** 42,48 ****
  /*
   * nbdebug_wait	-   This function can be used to delay or stop execution of vim.
   *		    It's normally used to delay startup while attaching a
!  *		    debugger to a running process. Since workshop starts gvim
   *		    from a background process this is the only way to debug
   *		    startup problems.
   */
--- 42,48 ----
  /*
   * nbdebug_wait	-   This function can be used to delay or stop execution of vim.
   *		    It's normally used to delay startup while attaching a
!  *		    debugger to a running process. Since NetBeans starts gvim
   *		    from a background process this is the only way to debug
   *		    startup problems.
   */
*** ../vim-8.1.0762/src/netbeans.c	2019-01-15 20:19:36.743904434 +0100
--- src/netbeans.c	2019-01-17 15:09:18.877769920 +0100
***************
*** 2273,2281 ****
  
      nbdebug(("    COLONCMD %s\n", buf));
  
- /*     ALT_INPUT_LOCK_ON; */
      do_cmdline((char_u *)buf, NULL, NULL, DOCMD_NOWAIT | DOCMD_KEYTYPED);
- /*     ALT_INPUT_LOCK_OFF; */
  
      setcursor();		/* restore the cursor position */
      out_flush_cursor(TRUE, FALSE);
--- 2273,2279 ----
*** ../vim-8.1.0762/src/proto.h	2019-01-15 20:19:36.743904434 +0100
--- src/proto.h	2019-01-17 15:26:51.439817568 +0100
***************
*** 295,303 ****
  #  ifdef FEAT_GUI_PHOTON
  #   include "gui_photon.pro"
  #  endif
- #  ifdef FEAT_SUN_WORKSHOP
- #   include "workshop.pro"
- #  endif
  # endif	/* FEAT_GUI */
  
  # ifdef FEAT_OLE
--- 295,300 ----
*** ../vim-8.1.0762/src/proto/workshop.pro	2018-05-17 13:52:57.000000000 +0200
--- src/proto/workshop.pro	1970-01-01 01:00:00.000000000 +0100
***************
*** 1,49 ****
- /* workshop.c */
- void workshop_init(void);
- void workshop_postinit(void);
- void ex_wsverb(exarg_T *eap);
- char *workshop_get_editor_name(void);
- char *workshop_get_editor_version(void);
- void workshop_load_file(char *filename, int line, char *frameid);
- void workshop_reload_file(char *filename, int line);
- void workshop_show_file(char *filename);
- void workshop_goto_line(char *filename, int lineno);
- void workshop_front_file(char *filename);
- void workshop_save_file(char *filename);
- void workshop_save_files(void);
- void workshop_quit(void);
- void workshop_minimize(void);
- void workshop_maximize(void);
- void workshop_add_mark_type(int idx, char *colorspec, char *sign);
- void workshop_set_mark(char *filename, int lineno, int markId, int idx);
- void workshop_change_mark_type(char *filename, int markId, int idx);
- void workshop_goto_mark(char *filename, int markId, char *message);
- void workshop_delete_mark(char *filename, int markId);
- int workshop_get_mark_lineno(char *filename, int markId);
- void workshop_moved_marks(char *filename);
- int workshop_get_font_height(void);
- void workshop_footer_message(char *message, int severity);
- void workshop_menu_begin(char *label);
- void workshop_submenu_begin(char *label);
- void workshop_submenu_end(void);
- void workshop_menu_item(char *label, char *verb, char *accelerator, char *acceleratorText, char *name, char *filepos, char *sensitive);
- void workshop_menu_end(void);
- void workshop_toolbar_begin(void);
- void workshop_toolbar_end(void);
- void workshop_toolbar_button(char *label, char *verb, char *senseVerb, char *filepos, char *help, char *sense, char *file, char *left);
- void workshop_frame_sensitivities(VerbSense *vs);
- void workshop_set_option(char *option, char *value);
- void workshop_balloon_mode(Boolean on);
- void workshop_balloon_delay(int delay);
- void workshop_show_balloon_tip(char *tip);
- void workshop_hotkeys(Boolean on);
- int workshop_get_positions(void *clientData, char **filename, int *curLine, int *curCol, int *selStartLine, int *selStartCol, int *selEndLine, int *selEndCol, int *selLength, char **selection);
- char *workshop_test_getcurrentfile(void);
- int workshop_test_getcursorrow(void);
- int workshop_test_getcursorcol(void);
- char *workshop_test_getcursorrowtext(void);
- char *workshop_test_getselectedtext(void);
- void workshop_save_sensitivity(char *filename);
- void workshop_beval_cb(BalloonEval *beval, int state);
- void findYourself(char *argv0);
- /* vim: set ft=c : */
--- 0 ----
*** ../vim-8.1.0762/src/ui.c	2019-01-17 14:11:56.434600704 +0100
--- src/ui.c	2019-01-17 15:25:20.972303268 +0100
***************
*** 1625,1634 ****
   * descriptions which would otherwise overflow.  The buffer is considered full
   * when only this extra space (or part of it) remains.
   */
! #if defined(FEAT_SUN_WORKSHOP) || defined(FEAT_JOB_CHANNEL) \
! 	|| defined(FEAT_CLIENTSERVER)
     /*
!     * Sun WorkShop and NetBeans stuff debugger commands into the input buffer.
      * This requires a larger buffer...
      * (Madsen) Go with this for remote input as well ...
      */
--- 1625,1633 ----
   * descriptions which would otherwise overflow.  The buffer is considered full
   * when only this extra space (or part of it) remains.
   */
! #if defined(FEAT_JOB_CHANNEL) || defined(FEAT_CLIENTSERVER)
     /*
!     * NetBeans stuffs debugger commands into the input buffer.
      * This requires a larger buffer...
      * (Madsen) Go with this for remote input as well ...
      */
*** ../vim-8.1.0762/src/version.c	2019-01-17 14:31:10.190919265 +0100
--- src/version.c	2019-01-17 15:39:12.143436999 +0100
***************
*** 598,608 ****
  #else
  	"-statusline",
  #endif
- #ifdef FEAT_SUN_WORKSHOP
- 	"+sun_workshop",
- #else
  	"-sun_workshop",
- #endif
  #ifdef FEAT_SYN_HL
  	"+syntax",
  #else
--- 598,604 ----
*** ../vim-8.1.0762/src/vim.h	2019-01-13 23:38:33.415773131 +0100
--- src/vim.h	2019-01-17 15:27:00.275769256 +0100
***************
*** 288,297 ****
  # include "os_qnx.h"
  #endif
  
- #ifdef FEAT_SUN_WORKSHOP
- # include "workshop.h"
- #endif
- 
  #ifdef X_LOCALE
  # include <X11/Xlocale.h>
  #else
--- 288,293 ----
***************
*** 2236,2249 ****
  # define vim_realloc(ptr, size)  realloc((ptr), (size))
  #endif
  
- /*
-  * The following macros stop display/event loop nesting at the wrong time.
-  */
- #ifdef ALT_X_INPUT
- # define ALT_INPUT_LOCK_OFF	suppress_alternate_input = FALSE
- # define ALT_INPUT_LOCK_ON	suppress_alternate_input = TRUE
- #endif
- 
  #ifdef FEAT_MBYTE
  /*
   * Return byte length of character that starts with byte "b".
--- 2232,2237 ----
*** ../vim-8.1.0762/src/workshop.c	2018-12-21 15:16:57.483579762 +0100
--- src/workshop.c	1970-01-01 01:00:00.000000000 +0100
***************
*** 1,1830 ****
- /* vi:set ts=8 sts=4 sw=4 noet:
-  *
-  * VIM - Vi IMproved	by Bram Moolenaar
-  *			Visual Workshop integration by Gordon Prieur
-  *
-  * Do ":help uganda"  in Vim to read copying and usage conditions.
-  * Do ":help credits" in Vim to see a list of people who contributed.
-  * See README.txt for an overview of the Vim source code.
-  */
- 
- #include "protodef.h"
- #ifdef HAVE_CONFIG_H
- # include "auto/config.h"
- #endif
- #include <stdio.h>
- #include <stdlib.h>
- #include <sys/types.h>
- #include <netdb.h>
- #include <netinet/in.h>
- #include <sys/socket.h>
- #ifdef HAVE_LIBGEN_H
- # include <libgen.h>
- #endif
- #include <unistd.h>
- #include <string.h>
- #include <stdlib.h>
- #include <ctype.h>
- 
- #include <X11/Intrinsic.h>
- #include <Xm/Xm.h>
- #include <Xm/PushB.h>
- 
- #include "integration.h"	/* <EditPlugin/integration.h> */
- 
- #include "vim.h"
- #include "version.h"
- #include "workshop.h"
- 
- void		 workshop_hotkeys(Boolean);
- 
- static Boolean	 isShowing(int);
- static win_T	*get_window(buf_T *);
- static void	 updatePriority(Boolean);
- static char	*addUniqueMnemonic(char *, char *);
- static char	*fixup(char *);
- static char	*get_selection(buf_T *);
- static char	*append_selection(int, char *, int *, int *);
- static void	 load_window(char *, int lnum);
- static void	 warp_to_pc(int);
- #ifdef FEAT_BEVAL_GUI
- void		 workshop_beval_cb(BalloonEval *, int);
- # ifdef FEAT_VARTABS
- static int	 computeIndex(int, char_u *, int, int *);
- # else
- static int	 computeIndex(int, char_u *, int);
- # endif
- #endif
- static char	*fixAccelText(char *);
- static void	 addMenu(char *, char *, char *);
- static char	*lookupVerb(char *, int);
- static void	 coloncmd(char *, Boolean);
- 
- extern Widget	 vimShell;
- extern Widget	 textArea;
- extern XtAppContext app_context;
- 
- static int	 tbpri;			/* ToolBar priority */
- int		 usingSunWorkShop = 0;	/* set if -ws flag is used */
- char		 curMenuName[BUFSIZ];
- char		 curMenuPriority[BUFSIZ];
- 
- static Boolean	 workshopInitDone = False;
- static Boolean	 workshopHotKeysEnabled = False;
- 
- /*
-  * The following enum is from <gp_dbx/gp_dbx_common.h>. We can't include it
-  * here because it's C++.
-  */
- enum
- {
-     GPLineEval_EVALUATE,		/* evaluate expression */
-     GPLineEval_INDIRECT,		/* evaluate *<expression> */
-     GPLineEval_TYPE			/* type of expression */
- };
- 
- /*
-  * Store each verb in the MenuMap. This lets us map from a verb to a menu.
-  * There may be multiple matches for a single verb in this table.
-  */
- #define MENU_INC	50		/* menuMap incremental size increases */
- typedef struct
- {
-     char	*name;			/* name of the menu */
-     char	*accel;			/* optional accelerator key */
-     char	*verb;			/* menu verb */
- } MenuMap;
- static MenuMap	*menuMap;		/* list of verb/menu mappings */
- static int	 menuMapSize;		/* current size of menuMap */
- static int	 menuMapMax;		/* allocated size of menuMap */
- static char	*initialFileCmd;	/* save command but defer doing it */
- 
- 
-     void
- workshop_init(void)
- {
-     char_u	 buf[64];
-     int		 is_dirty = FALSE;
-     int		 width, height;
-     XtInputMask	 mask;
- 
-     /*
-      * Turn on MenuBar, ToolBar, and Footer.
-      */
-     STRCPY(buf, p_go);
-     if (vim_strchr(p_go, GO_MENUS) == NULL)
-     {
- 	STRCAT(buf, "m");
- 	is_dirty = TRUE;
-     }
-     if (vim_strchr(p_go, GO_TOOLBAR) == NULL)
-     {
- 	STRCAT(buf, "T");
- 	is_dirty = TRUE;
-     }
-     if (vim_strchr(p_go, GO_FOOTER) == NULL)
-     {
- 	STRCAT(buf, "F");
- 	is_dirty = TRUE;
-     }
-     if (is_dirty)
- 	set_option_value((char_u *)"go", 0L, buf, 0);
- 
-     /*
-      * Set size from workshop_get_width_height().
-      */
-     width = height = 0;
-     if (workshop_get_width_height(&width, &height))
-     {
- 	XtVaSetValues(vimShell,
- 		XmNwidth, width,
- 		XmNheight, height,
- 		NULL);
-     }
- 
-     /*
-      * Now read in the initial messages from eserve.
-      */
-     while ((mask = XtAppPending(app_context))
- 	    && (mask & XtIMAlternateInput) && !workshopInitDone)
- 	XtAppProcessEvent(app_context, (XtInputMask)XtIMAlternateInput);
- }
- 
-     void
- workshop_postinit(void)
- {
-     do_cmdline_cmd((char_u *)initialFileCmd);
-     ALT_INPUT_LOCK_OFF;
-     free(initialFileCmd);
-     initialFileCmd = NULL;
- }
- 
-     void
- ex_wsverb(exarg_T *eap)
- {
-     msg_clr_cmdline();
-     workshop_perform_verb((char *) eap->arg, NULL);
- }
- 
- /*
-  * Editor name
-  * This string is recognized by eserve and should be all lower case.
-  * This is how the editor detects that it is talking to gvim instead
-  * of NEdit, for example, when the connection is initiated from the editor.
-  */
-     char *
- workshop_get_editor_name(void)
- {
-     return "gvim";
- }
- 
- /*
-  * Version number of the editor.
-  * This number is communicated along with the protocol
-  * version to the application.
-  */
-     char *
- workshop_get_editor_version(void)
- {
-     return Version;
- }
- 
- /*
-  * Answer functions: called by eserve
-  */
- 
- /*
-  * Name:
-  *	workshop_load_file
-  *
-  * Function:
-  *	Load a given file into the WorkShop buffer.
-  */
-     void
- workshop_load_file(
- 	char	*filename,		/* the file to load */
- 	int	 line,			/* an optional line number (or 0) */
- 	char	*frameid UNUSED)	/* used for multi-frame support */
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_load_file(%s, %d)\n", filename, line);
- #endif
- 
- #ifdef FEAT_BEVAL_GUI
-     bevalServers |= BEVAL_WORKSHOP;
- #endif
- 
-     load_window(filename, line);
- }
- 
- /*
-  * Reload the WorkShop buffer
-  */
-     void
- workshop_reload_file(
- 	char	*filename,
- 	int	 line)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_reload_file(%s, %d)\n", filename, line);
- #endif
-     load_window(filename, line);
- }
- 
-     void
- workshop_show_file(
-     char	*filename)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_show_file(%s)\n", filename);
- #endif
- 
-     load_window(filename, 0);
- }
- 
-     void
- workshop_goto_line(
-     char	*filename,
-     int		 lineno)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_goto_line(%s, %d)\n", filename, lineno);
- #endif
- 
-     load_window(filename, lineno);
- }
- 
-     void
- workshop_front_file(
- 	char	*filename UNUSED)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_front_file()\n");
- #endif
-     /*
-      * Assumption: This function will always be called after a call to
-      * workshop_show_file(), so the file is always showing.
-      */
-     if (vimShell != NULL)
- 	XRaiseWindow(gui.dpy, XtWindow(vimShell));
- }
- 
-     void
- workshop_save_file(
- 	    char	*filename)
- {
-     char	 cbuf[BUFSIZ];		/* build vim command here */
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_save_file(%s)\n", filename);
- #endif
- 
-     /* Save the given file */
-     vim_snprintf(cbuf, sizeof(cbuf), "w %s", filename);
-     coloncmd(cbuf, TRUE);
- }
- 
-     void
- workshop_save_files(void)
- {
-     /* Save the given file */
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_save_files()\n");
- #endif
- 
-     add_to_input_buf((char_u *) ":wall\n", 6);
- }
- 
-     void
- workshop_quit(void)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_quit()\n");
- #endif
- 
-     add_to_input_buf((char_u *) ":qall\n", 6);
- }
- 
-     void
- workshop_minimize(void)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_minimize()\n");
- #endif
-     workshop_minimize_shell(vimShell);
- }
-     void
- workshop_maximize(void)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_maximize()\n");
- #endif
- 
-     workshop_maximize_shell(vimShell);
- }
- 
-     void
- workshop_add_mark_type(
- 	int		 idx,
- 	char		*colorspec,
- 	char		*sign)
- {
-     char	 gbuf[BUFSIZ];	/* buffer for sign name */
-     char	 cibuf[BUFSIZ];	/* color information */
-     char	 cbuf[BUFSIZ];	/* command buffer */
-     char	*bp;
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
-     {
- 	char *cp;
- 
- 	cp = strrchr(sign, '/');
- 	if (cp == NULL)
- 	    cp = sign;
- 	else
- 	    cp++;		/* skip '/' character */
- 	wstrace("workshop_add_mark_type(%d, \"%s\", \"%s\")\n", idx,
- 		colorspec && *colorspec ? colorspec : "<None>", cp);
-     }
- #endif
- 
-     /*
-      * Isolate the basename of sign in gbuf. We will use this for the
-      * GroupName in the highlight command sent to vim.
-      */
-     STRCPY(gbuf, gettail((char_u *)sign));
-     bp = strrchr(gbuf, '.');
-     if (bp != NULL)
- 	*bp = NUL;
- 
-     if (gbuf[0] != '-' && gbuf[1] != NUL)
-     {
- 	if (colorspec != NULL && *colorspec)
- 	{
- 	    vim_snprintf(cbuf, sizeof(cbuf),
- 				  "highlight WS%s guibg=%s", gbuf, colorspec);
- 	    coloncmd(cbuf, FALSE);
- 	    vim_snprintf(cibuf, sizeof(cibuf), "linehl=WS%s", gbuf);
- 	}
- 	else
- 	    cibuf[0] = NUL;
- 
- 	vim_snprintf(cbuf, sizeof(cbuf),
- 			       "sign define %d %s icon=%s", idx, cibuf, sign);
- 	coloncmd(cbuf, TRUE);
-     }
- }
- 
-     void
- workshop_set_mark(
- 	char		*filename,	/* filename which gets the mark */
- 	int		 lineno,	/* line number which gets the mark */
- 	int		 markId,	/* unique mark identifier */
- 	int		 idx)		/* which mark to use */
- {
-     char	cbuf[BUFSIZ];	/* command buffer */
- 
-     /* Set mark in a given file */
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_set_mark(%s, %d (ln), %d (id), %d (idx))\n",
- 		filename, lineno, markId, idx);
- #endif
- 
-     vim_snprintf(cbuf, sizeof(cbuf), "sign place %d line=%d name=%d file=%s",
- 					       markId, lineno, idx, filename);
-     coloncmd(cbuf, TRUE);
- }
- 
-     void
- workshop_change_mark_type(
- 	char		*filename,	/* filename which gets the mark */
- 	int		 markId,	/* unique mark identifier */
- 	int		 idx)		/* which mark to use */
- {
-     char	cbuf[BUFSIZ];	/* command buffer */
- 
-     /* Change mark type */
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_change_mark_type(%s, %d, %d)\n",
- 		filename, markId, idx);
- #endif
- 
-     vim_snprintf(cbuf, sizeof(cbuf),
- 		      "sign place %d name=%d file=%s", markId, idx, filename);
-     coloncmd(cbuf, TRUE);
- }
- 
- /*
-  * Goto the given mark in a file (e.g. show it).
-  * If message is not null, display it in the footer.
-  */
-     void
- workshop_goto_mark(
- 	char		*filename,
- 	int		 markId,
- 	char		*message)
- {
-     char	cbuf[BUFSIZ];	/* command buffer */
- 
-     /* Goto mark */
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_goto_mark(%s, %d (id), %s)\n",
- 		filename, markId, message && *message &&
- 		!(*message == ' ' && message[1] == NULL) ?
- 		message : "<None>");
- #endif
- 
-     vim_snprintf(cbuf, sizeof(cbuf), "sign jump %d file=%s", markId, filename);
-     coloncmd(cbuf, TRUE);
-     if (message != NULL && *message != NUL)
- 	gui_mch_set_footer((char_u *)message);
- }
- 
-     void
- workshop_delete_mark(
- 	char		*filename,
- 	int		 markId)
- {
-     char	cbuf[BUFSIZ];	/* command buffer */
- 
-     /* Delete mark */
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_delete_mark(%s, %d (id))\n",
- 		filename, markId);
- #endif
- 
-     vim_snprintf(cbuf, sizeof(cbuf),
- 				 "sign unplace %d file=%s", markId, filename);
-     coloncmd(cbuf, TRUE);
- }
- 
-     int
- workshop_get_mark_lineno(
- 	char	*filename,
- 	int	 markId)
- {
-     buf_T	*buf;		/* buffer containing filename */
-     int		lineno;		/* line number of filename in buf */
- 
-     /* Get mark line number */
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_get_mark_lineno(%s, %d)\n",
- 		filename, markId);
- #endif
- 
-     lineno = 0;
-     buf = buflist_findname((char_u *)filename);
-     if (buf != NULL)
- 	lineno = buf_findsign(buf, markId, NULL);
- 
-     return lineno;
- }
- 
- 
- /*
-  * Are there any moved marks? If so, call workshop_move_mark on
-  * each of them now. This is how eserve can find out if for example
-  * breakpoints have moved when a program has been recompiled and
-  * reloaded into dbx.
-  */
-     void
- workshop_moved_marks(char *filename UNUSED)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("XXXworkshop_moved_marks(%s)\n", filename);
- #endif
- }
- 
-     int
- workshop_get_font_height(void)
- {
-     XmFontList	 fontList;	/* fontList made from gui.norm_font */
-     XmString	 str;
-     Dimension	 w;
-     Dimension	 h;
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_get_font_height()\n");
- #endif
- 
-     /* Pick the proper signs for this font size */
-     fontList = gui_motif_create_fontlist((XFontStruct *)gui.norm_font);
-     h = 0;
-     if (fontList != NULL)
-     {
- 	str = XmStringCreateLocalized("A");
- 	XmStringExtent(fontList, str, &w, &h);
- 	XmStringFree(str);
- 	XmFontListFree(fontList);
-     }
- 
-     return (int)h;
- }
- 
-     void
- workshop_footer_message(
- 	char	*message,
- 	int	severity UNUSED)	/* severity is currently unused */
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_footer_message(%s, %d)\n", message, severity);
- #endif
- 
-     gui_mch_set_footer((char_u *) message);
- }
- 
- /*
-  * workshop_menu_begin() is passed the menu name. We determine its mnemonic
-  * here and store its name and priority.
-  */
-     void
- workshop_menu_begin(
- 	char		*label)
- {
-     vimmenu_T	*menu;			/* pointer to last menu */
-     int		menuPriority = 0;	/* priority of new menu */
-     char	mnembuf[64];		/* store menubar mnemonics here */
-     char	*name;			/* label with a mnemonic */
-     char	*p;			/* used to find mnemonics */
-     int		idx;			/* index into mnembuf */
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_menu_begin()\n");
- #endif
- 
-     /*
-      * Look through all existing (non-PopUp and non-Toolbar) menus
-      * and gather their mnemonics. Use this list to decide what
-      * mnemonic should be used for label.
-      */
- 
-     idx = 0;
-     mnembuf[idx++] = 'H';		/* H is mnemonic for Help */
-     for (menu = root_menu; menu != NULL; menu = menu->next)
-     {
- 	if (menu_is_menubar(menu->name))
- 	{
- 	    p = strchr((char *)menu->name, '&');
- 	    if (p != NULL)
- 		mnembuf[idx++] = *++p;
- 	}
- 	if (menu->next != NULL
- 		&& strcmp((char *) menu->next->dname, "Help") == 0)
- 	{
- 	    menuPriority = menu->priority + 10;
- 	    break;
- 	}
-     }
-     mnembuf[idx++] = NUL;
-     name = addUniqueMnemonic(mnembuf, label);
- 
-     vim_snprintf(curMenuName, sizeof(curMenuName), "%s", name);
-     sprintf(curMenuPriority, "%d.0", menuPriority);
- }
- 
- /*
-  * Append the name and priority to strings to be used in vim menu commands.
-  */
-     void
- workshop_submenu_begin(
- 	char		*label)
- {
- #ifdef WSDEBUG_TRACE
-     if (ws_debug  && ws_dlevel & WS_TRACE
- 	    && strncmp(curMenuName, "ToolBar", 7) != 0)
- 	wstrace("workshop_submenu_begin(%s)\n", label);
- #endif
- 
-     strcat(curMenuName, ".");
-     strcat(curMenuName, fixup(label));
- 
-     updatePriority(True);
- }
- 
- /*
-  * Remove the submenu name and priority from curMenu*.
-  */
- 
-     void
- workshop_submenu_end(void)
- {
-     char		*p;
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE)
- 	    && strncmp(curMenuName, "ToolBar", 7) != 0)
- 	wstrace("workshop_submenu_end()\n");
- #endif
- 
-     p = strrchr(curMenuPriority, '.');
-     ASSERT(p != NULL);
-     *p = NUL;
- 
-     p = strrchr(curMenuName, '.');
-     ASSERT(p != NULL);
-     *p = NUL;
- }
- 
- /*
-  * This is where menus are really made. Each item will generate an amenu vim
-  * command. The globals curMenuName and curMenuPriority contain the name and
-  * priority of the parent menu tree.
-  */
-     void
- workshop_menu_item(
- 	char		*label,
- 	char		*verb,
- 	char		*accelerator UNUSED,
- 	char		*acceleratorText,
- 	char		*name UNUSED,
- 	char		*filepos UNUSED,
- 	char		*sensitive)
- {
-     char		 cbuf[BUFSIZ];
-     char		 namebuf[BUFSIZ];
-     char		 accText[BUFSIZ];
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE)
- 	    && strncmp(curMenuName, "ToolBar", 7) != 0)
-     {
- 	if (ws_dlevel & WS_TRACE_VERBOSE)
- 	    wsdebug("workshop_menu_item(\n"
- 		    "\tlabel = \"%s\",\n"
- 		    "\tverb = %s,\n"
- 		    "\taccelerator = %s,\n"
- 		    "\tacceleratorText = \"%s\",\n"
- 		    "\tname = %s,\n"
- 		    "\tfilepos = %s,\n"
- 		    "\tsensitive = %s)\n",
- 		    label && *label ? label : "<None>",
- 		    verb && *verb ? verb : "<None>",
- 		    accelerator && *accelerator ?
- 		    accelerator : "<None>",
- 		    acceleratorText && *acceleratorText ?
- 		    acceleratorText : "<None>",
- 		    name && *name ? name : "<None>",
- 		    filepos && *filepos ? filepos : "<None>",
- 		    sensitive);
- 	else if (ws_dlevel & WS_TRACE)
- 	    wstrace("workshop_menu_item(\"%s\", %s)\n",
- 		    label && *label ? label : "<None>",
- 		    verb && *verb ? verb : "<None>", sensitive);
-     }
- #endif
- #ifdef WSDEBUG_SENSE
-     if (ws_debug)
- 	wstrace("menu:   %-21.20s%-21.20s(%s)\n", label, verb,
- 		*sensitive == '1' ? "Sensitive" : "Insensitive");
- #endif
- 
-     if (acceleratorText != NULL)
- 	vim_snprintf(accText, sizeof(accText), "<Tab>%s", acceleratorText);
-     else
- 	accText[0] = NUL;
-     updatePriority(False);
-     vim_snprintf(namebuf, sizeof(namebuf), "%s.%s", curMenuName, fixup(label));
-     vim_snprintf(cbuf, sizeof(cbuf), "amenu %s %s%s\t:wsverb %s<CR>",
- 	    curMenuPriority, namebuf, accText, verb);
- 
-     coloncmd(cbuf, TRUE);
-     addMenu(namebuf, fixAccelText(acceleratorText), verb);
- 
-     if (*sensitive == '0')
-     {
- 	vim_snprintf(cbuf, sizeof(cbuf), "amenu disable %s", namebuf);
- 	coloncmd(cbuf, TRUE);
-     }
- }
- 
- /*
-  * This function is called when a complete WorkShop menu description has been
-  * sent over from eserve. We do some menu cleanup.
-  */
- 
-     void
- workshop_menu_end(void)
- {
-     Boolean		 using_tearoff;	/* set per current option setting */
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_menu_end()\n");
- #endif
- 
-     using_tearoff = vim_strchr(p_go, GO_TEAROFF) != NULL;
-     gui_mch_toggle_tearoffs(using_tearoff);
- }
- 
-     void
- workshop_toolbar_begin(void)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_toolbar_begin()\n");
- #endif
- 
-     coloncmd("aunmenu ToolBar", True);
-     tbpri = 10;
- }
- 
-     void
- workshop_toolbar_end(void)
- {
-     char_u	buf[64];
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
-     {
- 	wstrace("workshop_toolbar_end()\n");
-     }
- #endif
- 
-     /*
-      * Turn on ToolBar.
-      */
-     STRCPY(buf, p_go);
-     if (vim_strchr(p_go, 'T') == NULL)
-     {
- 	STRCAT(buf, "T");
- 	set_option_value((char_u *)"go", 0L, buf, 0);
-     }
-     workshopInitDone = True;
- }
- 
-     void
- workshop_toolbar_button(
- 	char	*label,
- 	char	*verb,
- 	char	*senseVerb UNUSED,
- 	char	*filepos UNUSED,
- 	char	*help,
- 	char	*sense,
- 	char	*file,
- 	char	*left)
- {
-     char	cbuf[BUFSIZ + MAXPATHLEN];
-     char	namebuf[BUFSIZ];
-     static int	tbid = 1;
-     char_u	*p;
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE))
- 	wsdebug("workshop_toolbar_button(\"%s\", %s, %s,\n"
- 		"\t%s, \"%s\", %s,\n\t\"%s\",\n\t<%s>)\n",
- 		label   && *label   ? label   : "<None>",
- 		verb    && *verb    ? verb    : "<None>",
- 		senseVerb && *senseVerb    ? senseVerb    : "<None>",
- 		filepos && *filepos ? filepos : "<None>",
- 		help    && *help    ? help    : "<None>",
- 		sense   && *sense   ? sense   : "<None>",
- 		file    && *file    ? file    : "<None>",
- 		left    && *left    ? left    : "<None>");
-     else if (WSDLEVEL(WS_TRACE))
- 	wstrace("workshop_toolbar_button(\"%s\", %s)\n",
- 		label   && *label   ? label   : "<None>",
- 		verb    && *verb    ? verb    : "<None>");
- #endif
- #ifdef WSDEBUG_SENSE
-     if (ws_debug)
- 	wsdebug("button: %-21.20s%-21.20s(%s)\n", label, verb,
- 		*sense == '1' ? "Sensitive" : "Insensitive");
- #endif
- 
-     if (left && *left && atoi(left) > 0)
-     {
- 	/* Add a separator (but pass the width passed after the ':') */
- 	sprintf(cbuf, "amenu 1.%d ToolBar.-sep%d:%s- <nul>",
- 		tbpri - 5, tbid++, left);
- 
- 	coloncmd(cbuf, True);
-     }
- 
-     p = vim_strsave_escaped((char_u *)label, (char_u *)"\\. ");
-     vim_snprintf(namebuf, sizeof(namebuf), "ToolBar.%s", p);
-     vim_free(p);
-     STRCPY(cbuf, "amenu <silent> ");
-     if (file != NULL && *file != NUL)
-     {
- 	p = vim_strsave_escaped((char_u *)file, (char_u *)" ");
- 	vim_snprintf_add(cbuf, sizeof(cbuf), "icon=%s ", p);
- 	vim_free(p);
-     }
-     vim_snprintf_add(cbuf, sizeof(cbuf),"1.%d %s :wsverb %s<CR>",
- 							tbpri, namebuf, verb);
- 
-     /* Define the menu item */
-     coloncmd(cbuf, True);
- 
-     if (*sense == '0')
-     {
- 	/* If menu isn't sensitive at startup... */
- 	vim_snprintf(cbuf, sizeof(cbuf), "amenu disable %s", namebuf);
- 	coloncmd(cbuf, True);
-     }
- 
-     if (help && *help)
-     {
- 	/* Do the tooltip */
- 	vim_snprintf(cbuf, sizeof(cbuf), "tmenu %s %s", namebuf, help);
- 	coloncmd(cbuf, True);
-     }
- 
-     addMenu(namebuf, NULL, verb);
-     tbpri += 10;
- }
- 
-     void
- workshop_frame_sensitivities(
- 	VerbSense	*vs)		/* list of verbs to (de)sensitize */
- {
-     VerbSense	*vp;		/* iterate through vs */
-     char	*menu_name;	/* used in menu lookup */
-     int		 cnt;		/* count of verbs to skip */
-     int		 len;		/* length of nonvariant part of command */
-     char	 cbuf[4096];
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE) || WSDLEVEL(4))
-     {
- 	wsdebug("workshop_frame_sensitivities(\n");
- 	for (vp = vs; vp->verb != NULL; vp++)
- 	    wsdebug("\t%-25s%d\n", vp->verb, vp->sense);
- 	wsdebug(")\n");
-     }
-     else if (WSDLEVEL(WS_TRACE))
- 	wstrace("workshop_frame_sensitivities()\n");
- #endif
- #ifdef WSDEBUG_SENSE
-     if (ws_debug)
- 	for (vp = vs; vp->verb != NULL; vp++)
- 	    wsdebug("change: %-21.20s%-21.20s(%s)\n",
- 		    "", vp->verb, vp->sense == 1 ?
- 		    "Sensitive" : "Insensitive");
- #endif
- 
-     /*
-      * Look for all matching menu entries for the verb. There may be more
-      * than one if the verb has both a menu and toolbar entry.
-      */
-     for (vp = vs; vp->verb != NULL; vp++)
-     {
- 	cnt = 0;
- 	strcpy(cbuf, "amenu");
- 	strcat(cbuf, " ");
- 	strcat(cbuf, vp->sense ? "enable" : "disable");
- 	strcat(cbuf, " ");
- 	len = strlen(cbuf);
- 	while ((menu_name = lookupVerb(vp->verb, cnt++)) != NULL)
- 	{
- 	    strcpy(&cbuf[len], menu_name);
- 	    coloncmd(cbuf, FALSE);
- 	}
-     }
-     gui_update_menus(0);
-     gui_mch_flush();
- }
- 
-     void
- workshop_set_option(
- 	char	*option,		/* name of a supported option */
- 	char	*value)			/* value to set option to */
- {
-     char	 cbuf[BUFSIZ];		/* command buffer */
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
-     {
- 	wstrace("workshop_set_option(%s, %s)\n", option, value);
-     }
- #endif
- 
-     cbuf[0] = NUL;
-     switch (*option)		/* switch on 1st letter */
-     {
- 	case 's':
- 	    if (strcmp(option, "syntax") == 0)
- 		vim_snprintf(cbuf, sizeof(cbuf), "syntax %s", value);
- 	    else if (strcmp(option, "savefiles") == 0)
- 	    {
- 		/* XXX - Not yet implemented */
- 	    }
- 	    break;
- 
- 	case 'l':
- 	    if (strcmp(option, "lineno") == 0)
- 		sprintf(cbuf, "set %snu",
- 			(strcmp(value, "on") == 0) ? "" : "no");
- 	    break;
- 
- 	case 'p':
- 	    if (strcmp(option, "parentheses") == 0)
- 		sprintf(cbuf, "set %ssm",
- 			(strcmp(value, "on") == 0) ? "" : "no");
- 	    break;
- 
- 	case 'w':
- 	    /* this option is set by a direct call */
- #ifdef WSDEBUG
- 	    wsdebug("workshop_set_option: "
- 		    "Got unexpected workshopkeys option");
- #endif
- 	    break;
- 
- 	case 'b':	/* these options are set from direct calls */
- 	    if (option[7] == NUL && strcmp(option, "balloon") == 0)
- 	    {
- #ifdef WSDEBUG
- 		/* set by direct call to workshop_balloon_mode */
- 		wsdebug("workshop_set_option: "
- 			"Got unexpected ballooneval option");
- #endif
- 	    }
- 	    else if (strcmp(option, "balloondelay") == 0)
- 	    {
- #ifdef WSDEBUG
- 		/* set by direct call to workshop_balloon_delay */
- 		wsdebug("workshop_set_option: "
- 			"Got unexpected balloondelay option");
- #endif
- 	    }
- 	    break;
-     }
-     if (cbuf[0] != NUL)
- 	coloncmd(cbuf, TRUE);
- }
- 
- 
-     void
- workshop_balloon_mode(
- 	Boolean	 on)
- {
-     char	 cbuf[BUFSIZ];		/* command buffer */
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_balloon_mode(%s)\n", on ? "True" : "False");
- #endif
- 
-     sprintf(cbuf, "set %sbeval", on ? "" : "no");
-     coloncmd(cbuf, TRUE);
- }
- 
- 
-     void
- workshop_balloon_delay(
- 	int	 delay)
- {
-     char	 cbuf[BUFSIZ];		/* command buffer */
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_balloon_delay(%d)\n", delay);
- #endif
- 
-     sprintf(cbuf, "set bdlay=%d", delay);
-     coloncmd(cbuf, TRUE);
- }
- 
- 
-     void
- workshop_show_balloon_tip(
- 	char	*tip)
- {
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_show_balloon_tip(%s)\n", tip);
- #endif
- 
-     if (balloonEval != NULL)
- 	gui_mch_post_balloon(balloonEval, (char_u *)tip);
- }
- 
- 
-     void
- workshop_hotkeys(
- 	Boolean	on)
- {
-     char	 cbuf[BUFSIZ];		/* command buffer */
-     MenuMap	*mp;			/* iterate over menuMap entries */
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_hotkeys(%s)\n", on ? "True" : "False");
- #endif
- 
-     workshopHotKeysEnabled = on;
-     if (workshopHotKeysEnabled)
- 	for (mp = menuMap; mp < &menuMap[menuMapSize]; mp++)
- 	{
- 	    if (mp->accel != NULL)
- 	    {
- 		vim_snprintf(cbuf, sizeof(cbuf),
- 			"map %s :wsverb %s<CR>", mp->accel, mp->verb);
- 		coloncmd(cbuf, TRUE);
- 	    }
- 	}
-     else
- 	for (mp = menuMap; mp < &menuMap[menuMapSize]; mp++)
- 	{
- 	    if (mp->accel != NULL)
- 	    {
- 		vim_snprintf(cbuf, sizeof(cbuf), "unmap %s", mp->accel);
- 		coloncmd(cbuf, TRUE);
- 	    }
- 	}
- }
- 
- /*
-  * A button in the toolbar has been pushed.
-  */
-     int
- workshop_get_positions(
- 	void		*clientData UNUSED,
- 	char	       **filename,	/* output data */
- 	int		*curLine,	/* output data */
- 	int		*curCol,	/* output data */
- 	int		*selStartLine,	/* output data */
- 	int		*selStartCol,	/* output data */
- 	int		*selEndLine,	/* output data */
- 	int		*selEndCol,	/* output data */
- 	int		*selLength,	/* output data */
- 	char	       **selection)	/* output data */
- {
-     static char	 ffname[MAXPATHLEN];
- 
- #ifdef WSDEBUG_TRACE
-     if (WSDLEVEL(WS_TRACE_VERBOSE | WS_TRACE))
- 	wstrace("workshop_get_positions(%#x, \"%s\", ...)\n",
- 		clientData, (curbuf && curbuf->b_sfname != NULL)
- 				      ? (char *)curbuf->b_sfname : "<None>");
- #endif
- 
-     if (curbuf->b_ffname == NULL)
- 	ffname[0] = NUL;
-     else
- 	/* copy so nobody can change b_ffname */
- 	strcpy(ffname, (char *) curbuf->b_ffname);
-     *filename = ffname;
-     *curLine = curwin->w_cursor.lnum;
-     *curCol = curwin->w_cursor.col;
- 
-     if (curbuf->b_visual.vi_mode == 'v' &&
- 	    EQUAL_POS(curwin->w_cursor, curbuf->b_visual.vi_end))
-     {
- 	*selStartLine = curbuf->b_visual.vi_start.lnum;
- 	*selStartCol = curbuf->b_visual.vi_start.col;
- 	*selEndLine = curbuf->b_visual.vi_end.lnum;
- 	*selEndCol = curbuf->b_visual.vi_end.col;
- 	*selection = get_selection(curbuf);
- 	if (*selection)
- 	    *selLength = strlen(*selection);
- 	else
- 	    *selLength = 0;
-     }
-     else
-     {
- 	*selStartLine = *selEndLine = -1;
- 	*selStartCol = *selEndCol = -1;
- 	*selLength = 0;
- 	*selection = "";
-     }
- 
-     return True;
- }
- 
- 
- 
- /************************************************************************
-  * Utility functions
-  ************************************************************************/
- 
-     static char *
- get_selection(
- 	buf_T		*buf)		/* buffer whose selection we want */
- {
-     pos_T	*start;		/* start of the selection */
-     pos_T	*end;		/* end of the selection */
-     char	*lp;		/* pointer to actual line data */
-     int		 llen;		/* length of actual line data */
-     char	*sp;		/* pointer to selection  buffer */
-     int		 slen;		/* string length in selection buffer */
-     int		 size;		/* size of selection buffer */
-     char	*new_sp;	/* temp pointer to new sp */
-     int		 lnum;		/* line number we are appending */
- 
-     if (buf->b_visual.vi_mode == 'v')
-     {
- 	start = &buf->b_visual.vi_start;
- 	end = &buf->b_visual.vi_end;
- 	if (start->lnum == end->lnum)
- 	{
- 	    /* selection is all on one line */
- 	    lp = (char *) ml_get_pos(start);
- 	    llen = end->col - start->col + 1;
- 	    sp = (char *) malloc(llen + 1);
- 	    if (sp != NULL)
- 	    {
- 		strncpy(sp, lp, llen);
- 		sp[llen] = NUL;
- 	    }
- 	}
- 	else
- 	{
- 	    /* multi-line selection */
- 	    lp = (char *) ml_get_pos(start);
- 	    llen = strlen(lp);
- 	    sp = (char *) malloc(BUFSIZ + llen);
- 	    if (sp != NULL)
- 	    {
- 		size = BUFSIZ + llen;
- 		strcpy(sp, lp);
- 		sp[llen] = '\n';
- 		slen = llen + 1;
- 
- 		lnum = start->lnum + 1;
- 		while (lnum < end->lnum)
- 		    sp = append_selection(lnum++, sp, &size, &slen);
- 
- 		lp = (char *) ml_get(end->lnum);
- 		llen = end->col + 1;
- 		if ((slen + llen) >= size)
- 		{
- 		    new_sp = (char *)
- 			realloc(sp, slen + llen + 1);
- 		    if (new_sp != NULL)
- 		    {
- 			size += llen + 1;
- 			sp = new_sp;
- 		    }
- 		}
- 		if ((slen + llen) < size)
- 		{
- 		    strncpy(&sp[slen], lp, llen);
- 		    sp[slen + llen] = NUL;
- 		}
- 
- 	    }
- 	}
-     }
-     else
- 	sp = NULL;
- 
-     return sp;
- }
- 
-     static char *
- append_selection(
- 	int		 lnum,		/* line number to append */
- 	char		*sp,		/* pointer to selection buffer */
- 	int		*size,		/* ptr to size of sp */
- 	int		*slen)		/* ptr to length of selection string */
- {
-     char	*lp;		/* line of data from buffer */
-     int		 llen;		/* strlen of lp */
-     char	*new_sp;	/* temp pointer to new sp */
- 
-     lp = (char *)ml_get((linenr_T)lnum);
-     llen = strlen(lp);
- 
-     if ((*slen + llen) <= *size)
-     {
- 	new_sp = (char *) realloc((void *) sp, BUFSIZ + *slen + llen);
- 	if (*new_sp != NUL)
- 	{
- 	    *size = BUFSIZ + *slen + llen;
- 	    sp = new_sp;
- 	}
-     }
-     if ((*slen + llen) > *size)
-     {
- 	strcat(&sp[*slen], lp);
- 	*slen += llen;
- 	sp[*slen++] = '\n';
-     }
- 
-     return sp;
- }
- 
- 
-     static void
- load_buffer_by_name(
- 	char	*filename,		/* the file to load */
- 	int	 lnum)			/* an optional line number (or 0) */
- {
-     char	 lnumbuf[16];		/* make line number option for :e */
-     char	 cbuf[BUFSIZ];		/* command buffer */
- 
-     if (lnum > 0)
- 	sprintf(lnumbuf, "+%d", lnum);
-     else
- 	lnumbuf[0] = NUL;
- 
-     vim_snprintf(cbuf, sizeof(cbuf), "e %s %s", lnumbuf, filename);
-     coloncmd(cbuf, False);
- }
- 
- 
-     static void
- load_window(
- 	char	*filename,		/* filename to load */
- 	int	 lnum)			/* linenumber to go to */
- {
-     buf_T	*buf;		/* buffer filename is stored in */
-     win_T	*win;		/* window filenme is displayed in */
- 
-     /*
-      * Make sure filename is displayed and is the current window.
-      */
- 
-     buf = buflist_findname((char_u *)filename);
-     if (buf == NULL || (win = get_window(buf)) == NULL)
-     {
- 	/* No buffer or buffer is not in current window */
- 	/* wsdebug("load_window: load_buffer_by_name(\"%s\", %d)\n",
- 		filename, lnum); */
- 	load_buffer_by_name(filename, lnum);
-     }
-     else
-     {
- 	/* buf is in a window */
- 	if (win != curwin)
- 	{
- 	    win_enter(win, False);
- 	    /* wsdebug("load_window: window enter %s\n",
- 		    win->w_buffer->b_sfname); */
- 	}
- 	if (lnum > 0 && win->w_cursor.lnum != lnum)
- 	{
- 	    warp_to_pc(lnum);
- 	    /* wsdebug("load_window: warp to %s[%d]\n",
- 		    win->w_buffer->b_sfname, lnum); */
- 	}
-     }
-     out_flush();
- }
- 
- 
- 
-     static void
- warp_to_pc(
- 	int	 lnum)			/* line number to warp to */
- {
-     char	 lbuf[256];		/* build line command here */
- 
-     if (lnum > 0)
-     {
- 	if (State & INSERT)
- 	    add_to_input_buf((char_u *) "\033", 1);
- 	if (isShowing(lnum))
- 	    sprintf(lbuf, "%dG", lnum);
- 	else
- 	    sprintf(lbuf, "%dz.", lnum);
- 	add_to_input_buf((char_u *) lbuf, strlen(lbuf));
-     }
- }
- 
-     static Boolean
- isShowing(
- 	int	 lnum)			/* tell if line number is showing */
- {
-     return lnum >= curwin->w_topline && lnum < curwin->w_botline;
- }
- 
- 
- 
-     static win_T *
- get_window(
- 	buf_T	*buf)		/* buffer to find window for */
- {
-     win_T	*wp = NULL;	/* window filename is in */
- 
-     FOR_ALL_WINDOWS(wp)
- 	if (buf == wp->w_buffer)
- 	    break;
-     return wp;
- }
- 
- 
-     static void
- updatePriority(
- 	Boolean		 subMenu)	/* if True then start new submenu pri */
- {
-     int		 pri;		/* priority of this menu/item */
-     char	*p;
- 
-     p = strrchr(curMenuPriority, '.');
-     ASSERT(p != NULL);
-     *p++ = NUL;
- 
-     pri = atoi(p) + 10;		/* our new priority */
- 
-     if (subMenu)
- 	vim_snprintf(curMenuPriority, sizeof(curMenuPriority),
- 					     "%s.%d.0", curMenuPriority, pri);
-     else
- 	vim_snprintf(curMenuPriority, sizeof(curMenuPriority),
- 					       "%s.%d", curMenuPriority, pri);
- }
- 
-     static char *
- addUniqueMnemonic(
- 	char		*mnemonics,	/* currently used mnemonics */
- 	char		*label)		/* label of menu needing mnemonic */
- {
-     static char	 name[BUFSIZ];	/* buffer for the updated name */
-     char	*p;		/* pointer into label */
-     char	*found;		/* pointer to possible mnemonic */
- 
-     found = NULL;
-     for (p = label; *p != NUL; p++)
- 	if (strchr(mnemonics, *p) == 0)
- 	    if (found == NULL || (isupper((int)*p) && islower((int)*found)))
- 		found = p;
- 
-     if (found != NULL)
-     {
- 	strncpy(name, label, (found - label));
- 	strcat(name, "&");
- 	strcat(name, found);
-     }
-     else
- 	strcpy(name, label);
- 
-     return name;
- }
- 
- /*
-  * Some characters in a menu name must be escaped in vim. Since this is vim
-  * specific, it must be done on this side.
-  */
-     static char *
- fixup(
- 	char		*label)
- {
-     static char	 buf[BUFSIZ];
-     char		*bp;		/* pointer into buf */
-     char		*lp;		/* pointer into label */
- 
-     lp = label;
-     bp = buf;
-     while (*lp != NUL)
-     {
- 	if (*lp == ' ' || *lp == '.')
- 	    *bp++ = '\\';
- 	*bp++ = *lp++;
-     }
-     *bp = NUL;
- 
-     return buf;
- }
- 
- 
- #ifdef NOHANDS_SUPPORT_FUNCTIONS
- 
- /* For the NoHands test suite */
- 
-     char *
- workshop_test_getcurrentfile(void)
- {
-     char	*filename, *selection;
-     int		curLine, curCol, selStartLine, selStartCol, selEndLine;
-     int		selEndCol, selLength;
- 
-     if (workshop_get_positions(
- 		NULL, &filename, &curLine, &curCol, &selStartLine,
- 		&selStartCol, &selEndLine, &selEndCol, &selLength,
- 		&selection))
- 	return filename;
-     else
- 	return NULL;
- }
- 
-     int
- workshop_test_getcursorrow(void)
- {
-     return 0;
- }
- 
-     int
- workshop_test_getcursorcol(void)
- {
-     char	*filename, *selection;
-     int		curLine, curCol, selStartLine, selStartCol, selEndLine;
-     int		selEndCol, selLength;
- 
-     if (workshop_get_positions(
- 		NULL, &filename, &curLine, &curCol, &selStartLine,
- 		&selStartCol, &selEndLine, &selEndCol, &selLength,
- 		&selection))
- 	return curCol;
-     else
- 	return -1;
- }
- 
-     char *
- workshop_test_getcursorrowtext(void)
- {
-     return NULL;
- }
- 
-     char *
- workshop_test_getselectedtext(void)
- {
-     char	*filename, *selection;
-     int		curLine, curCol, selStartLine, selStartCol, selEndLine;
-     int		selEndCol, selLength;
- 
-     if (workshop_get_positions(
- 		NULL, &filename, &curLine, &curCol, &selStartLine,
- 		&selStartCol, &selEndLine, &selEndCol, &selLength,
- 		&selection))
- 	return selection;
-     else
- 	return NULL;
- }
- 
-     void
- workshop_save_sensitivity(char *filename UNUSED)
- {
- }
- 
- #endif
- 
-     static char *
- fixAccelText(
- 	char		*ap)		/* original acceleratorText */
- {
-     char	buf[256];	/* build in temp buffer */
-     char	*shift;		/* shift string of "" */
- 
-     if (ap == NULL)
- 	return NULL;
- 
-     /* If the accelerator is shifted use the vim form */
-     if (strncmp("Shift+", ap, 6) == 0)
-     {
- 	shift = "S-";
- 	ap += 6;
-     }
-     else
- 	shift = "";
- 
-     if (*ap == 'F' && atoi(&ap[1]) > 0)
-     {
- 	vim_snprintf(buf, sizeof(buf), "<%s%s>", shift, ap);
- 	return strdup(buf);
-     }
-     else
- 	return NULL;
- }
- 
- #ifdef FEAT_BEVAL_GUI
-     void
- workshop_beval_cb(
- 	BalloonEval	*beval,
- 	int		 state)
- {
-     win_T	*wp;
-     char_u	*text;
-     int		 type;
-     linenr_T	 lnum;
-     int		 col;
-     int		 idx;
-     char	 buf[MAXPATHLEN * 2];
-     static int	 serialNo = -1;
- 
-     if (!p_beval)
- 	return;
- 
-     if (get_beval_info(beval, FALSE, &wp, &lnum, &text, &col) == OK)
-     {
- 	if (text && text[0])
- 	{
- 	    /* Send debugger request */
- 	    if (strlen((char *) text) > (MAXPATHLEN/2))
- 	    {
- 		/*
- 		 * The user has probably selected the entire
- 		 * buffer or something like that - don't attempt
- 		 * to evaluate it
- 		 */
- 		return;
- 	    }
- 
- 	    /*
- 	     * WorkShop expects the col to be a character index, not
- 	     * a column number. Compute the index from col. Also set
- 	     * line to 0 because thats what dbx expects.
- 	     */
- #ifdef FEAT_VARTABS
- 	    idx = computeIndex(col, text, beval->ts, beval->vts);
- #else
- 	    idx = computeIndex(col, text, beval->ts, 0);
- #endif
- 	    if (idx > 0)
- 	    {
- 		lnum = 0;
- 
- 		/*
- 		 * If successful, it will respond with a balloon cmd.
- 		 */
- 		if (state & ControlMask)
- 		    /* Evaluate *(expression) */
- 		    type = (int)GPLineEval_INDIRECT;
- 		else if (state & ShiftMask)
- 		    /* Evaluate type(expression) */
- 		    type = (int)GPLineEval_TYPE;
- 		else
- 		    /* Evaluate value(expression) */
- 		    type = (int)GPLineEval_EVALUATE;
- 
- 		/* Send request to dbx */
- 		vim_snprintf(buf, sizeof(buf), "toolVerb debug.balloonEval "
- 			"%s %ld,0 %d,0 %d,%d %ld %s\n",
- 			(char *)wp->w_buffer->b_ffname,
- 			(long)lnum, idx, type, serialNo++,
- 			(long)strlen((char *)text), (char *)text);
- 		balloonEval = beval;
- 		workshop_send_message(buf);
- 	    }
- 	}
-     }
- }
- 
-     static int
- computeIndex(
- 	int		 wantedCol,
- 	char_u		*line,
- 	int		 ts,
- 	int		*vts UNUSED)
- {
-     int		 col = 0;
-     int		 idx = 0;
- 
-     while (line[idx])
-     {
- 	if (line[idx] == '\t')
- #ifdef FEAT_VARTABS
- 	    col += tabstop_padding(col, ts, vts);
- #else
- 	    col += ts - (col % ts);
- #endif
- 	else
- 	    col++;
- 	idx++;
- 	if (col >= wantedCol)
- 	    return idx;
-     }
- 
-     return -1;
- }
- #endif
- 
-     static void
- addMenu(
- 	char		*menu,		/* menu name */
- 	char		*accel,		/* accelerator text (optional) */
- 	char		*verb)		/* WorkShop action-verb */
- {
-     MenuMap		*newMap;
-     char		 cbuf[BUFSIZ];
- 
-     if (menuMapSize >= menuMapMax)
-     {
- 	newMap = realloc(menuMap,
- 		sizeof(MenuMap) * (menuMapMax + MENU_INC));
- 	if (newMap != NULL)
- 	{
- 	    menuMap = newMap;
- 	    menuMapMax += MENU_INC;
- 	}
-     }
-     if (menuMapSize < menuMapMax)
-     {
- 	menuMap[menuMapSize].name = strdup(menu);
- 	menuMap[menuMapSize].accel = accel && *accel ? strdup(accel) : NULL;
- 	menuMap[menuMapSize++].verb = strdup(verb);
- 	if (accel && workshopHotKeysEnabled)
- 	{
- 	    vim_snprintf(cbuf, sizeof(cbuf),
- 					"map %s :wsverb %s<CR>", accel, verb);
- 	    coloncmd(cbuf, TRUE);
- 	}
-     }
- }
- 
-     static char *
- nameStrip(
- 	char		*raw)		/* menu name, possibly with & chars */
- {
-     static char		buf[BUFSIZ];	/* build stripped name here */
-     char		*bp = buf;
- 
-     while (*raw)
-     {
- 	if (*raw != '&')
- 	    *bp++ = *raw;
- 	raw++;
-     }
-     *bp = NUL;
-     return buf;
- }
- 
- 
-     static char *
- lookupVerb(
- 	char	*verb,
- 	int	skip)		/* number of matches to skip */
- {
-     int		i;		/* loop iterator */
- 
-     for (i = 0; i < menuMapSize; i++)
- 	if (strcmp(menuMap[i].verb, verb) == 0 && skip-- == 0)
- 	    return nameStrip(menuMap[i].name);
- 
-     return NULL;
- }
- 
- 
-     static void
- coloncmd(
- 	char	*cmd,		/* the command to print */
- 	Boolean	force)		/* force cursor update */
- {
-     char_u	*cpo_save = p_cpo;
- 
- #ifdef WSDEBUG
-     if (WSDLEVEL(WS_TRACE_COLONCMD))
- 	wsdebug("Cmd: %s\n", cmd);
- #endif
- 
-     p_cpo = empty_option;
- 
-     ALT_INPUT_LOCK_ON;
-     do_cmdline_cmd((char_u *)cmd);
-     ALT_INPUT_LOCK_OFF;
- 
-     p_cpo = cpo_save;
- 
-     if (force)
- 	gui_update_screen();
- }
- 
- /*
-  * setDollarVim -	Given the run directory, search for the vim install
-  *			directory and set $VIM.
-  *
-  *			We can be running out of SUNWspro/bin or out of
-  *			SUNWspro/contrib/contrib6/vim5.6/bin so we check
-  *			relative to both of these directories.
-  */
-     static void
- setDollarVim(
- 	char	*rundir)
- {
-     char	 buf[MAXPATHLEN];
-     char	*cp;
- 
-     /*
-      * First case: Running from <install-dir>/SUNWspro/bin
-      */
-     strcpy(buf, rundir);
-     strcat(buf, "/../contrib/contrib6/vim" VIM_VERSION_SHORT "/share/vim/"
- 	    VIM_VERSION_NODOT "/syntax/syntax.vim");
-     if (access(buf, R_OK) == 0)
-     {
- 	strcpy(buf, "SPRO_WSDIR=");
- 	strcat(buf, rundir);
- 	cp = strrchr(buf, '/');
- 	if (cp != NULL)
- 	    strcpy(cp, "/WS6U2");
- 	putenv(strdup(buf));
- 
- 	strcpy(buf, "VIM=");
- 	strcat(buf, rundir);
- 	strcat(buf, "/../contrib/contrib6/vim" VIM_VERSION_SHORT "/share/vim/"
- 		VIM_VERSION_NODOT);
- 	putenv(strdup(buf));
- 	return;
-     }
- 
-     /*
-      * Second case: Probably running from
-      *		<install-dir>/SUNWspro/contrib/contrib6/vim5.6/bin
-      */
-     strcpy(buf, rundir);
-     strcat(buf, "/../../../contrib/contrib6/vim" VIM_VERSION_SHORT
- 	    "/share/vim/" VIM_VERSION_NODOT "/syntax/syntax.vim");
-     if (access(buf, R_OK) == 0)
-     {
- 	strcpy(buf, "SPRO_WSDIR=");
- 	strcat(buf, rundir);
- 	cp = strrchr(buf, '/');
- 	if (cp != NULL)
- 	    strcpy(cp, "../../../../WS6U2");
- 	putenv(strdup(buf));
- 
- 	strcpy(buf, "VIM=");
- 	strcat(buf, rundir);
- 	strcat(buf, "/../../../contrib/contrib6/vim" VIM_VERSION_SHORT
- 		"/share/vim/" VIM_VERSION_NODOT);
- 	putenv(strdup(buf));
- 	return;
-     }
- }
- 
- /*
-  * findYourself -	Find the directory we are running from. This is used to
-  *			set $VIM. We need to set this because users can install
-  *			the package in a different directory than the compiled
-  *			directory. This is a Sun Visual WorkShop requirement!
-  *
-  * Note:		We override a user's $VIM because it won't have the
-  *			WorkShop specific files. S/he may not like this but it's
-  *			better than getting the wrong files (especially as the
-  *			user is likely to have $VIM set to 5.4 or later).
-  */
-     void
- findYourself(
-     char	*argv0)
- {
-     char	*runpath = NULL;
-     char	*path;
-     char	*pathbuf;
- 
-     if (*argv0 == '/')
- 	runpath = strdup(argv0);
-     else if (*argv0 == '.' || strchr(argv0, '/'))
-     {
- 	runpath = (char *) malloc(MAXPATHLEN);
- 	if (getcwd(runpath, MAXPATHLEN) == NULL)
- 	    runpath[0] = NUL;
- 	strcat(runpath, "/");
- 	strcat(runpath, argv0);
-     }
-     else
-     {
- 	path = getenv("PATH");
- 	if (path != NULL)
- 	{
- 	    runpath = (char *) malloc(MAXPATHLEN);
- 	    pathbuf = strdup(path);
- 	    path = strtok(pathbuf, ":");
- 	    do
- 	    {
- 		strcpy(runpath, path);
- 		strcat(runpath, "/");
- 		strcat(runpath, argv0);
- 		if (access(runpath, X_OK) == 0)
- 		    break;
- 	    } while ((path = strtok(NULL, ":")) != NULL);
- 	    free(pathbuf);
- 	}
-     }
- 
-     if (runpath != NULL)
-     {
- 	char runbuf[MAXPATHLEN];
- 
- 	/*
- 	 * We found the run directory. Now find the install dir.
- 	 */
- 	(void)vim_FullName((char_u *)runpath, (char_u *)runbuf, MAXPATHLEN, 1);
- 	path = strrchr(runbuf, '/');
- 	if (path != NULL)
- 	    *path = NUL;		/* remove the vim/gvim name */
- 	path = strrchr(runbuf, '/');
- 	if (path != NULL)
- 	{
- 	    if (strncmp(path, "/bin", 4) == 0)
- 		setDollarVim(runbuf);
- 	    else if (strncmp(path, "/src", 4) == 0)
- 	    {
- 		*path = NUL;	/* development tree */
- 		setDollarVim(runbuf);
- 	    }
- 	}
- 	free(runpath);
-     }
- }
--- 0 ----
*** ../vim-8.1.0762/src/workshop.h	2016-08-29 22:42:21.000000000 +0200
--- src/workshop.h	1970-01-01 01:00:00.000000000 +0100
***************
*** 1,28 ****
- /* vi:set ts=8 sts=4 sw=4 noet:
-  *
-  * VIM - Vi IMproved	by Bram Moolenaar
-  *			Visual Workshop integration by Gordon Prieur
-  *
-  * Do ":help uganda"  in Vim to read copying and usage conditions.
-  * Do ":help credits" in Vim to see a list of people who contributed.
-  */
- 
- #if !defined(WORKSHOP_H) && defined(FEAT_SUN_WORKSHOP)
- #define WORKSHOP_H
- 
- #include <X11/Intrinsic.h>
- #include <Xm/Xm.h>
- 
- #include "integration.h"
- 
- #ifdef WSDEBUG
- # include "wsdebug.h"
- #else
- # ifndef ASSERT
- #  define ASSERT(c)
- # endif
- #endif
- 
- extern int		usingSunWorkShop;	/* set if -ws flag is used */
- 
- #endif
--- 0 ----
*** ../vim-8.1.0762/src/wsdebug.c	2016-09-25 21:41:24.000000000 +0200
--- src/wsdebug.c	1970-01-01 01:00:00.000000000 +0100
***************
*** 1,184 ****
- /* vi:set ts=8 sw=8 noet:
-  *
-  * VIM - Vi IMproved	by Bram Moolenaar
-  *			Visual Workshop integration by Gordon Prieur
-  *
-  * Do ":help uganda"  in Vim to read copying and usage conditions.
-  * Do ":help credits" in Vim to see a list of people who contributed.
-  * See README.txt for an overview of the Vim source code.
-  */
- 
- /*
-  * WorkShop Debugging Tools. What are these tools and why are they important?
-  * There are two main tools here. The first tool is a tool for delaying or
-  * stopping gvim during startup.  The second tool is a protocol log tool.
-  *
-  * The startup delay tool is called wsdebug_wait(). This is very important for
-  * debugging startup problems because gvim will be started automatically from
-  * workshop and cannot be run directly from a debugger. The only way to debug
-  * a gvim started by workshop is by attaching a debugger to it. Without this
-  * tool all starup code will have completed before you can get the pid and
-  * attach.
-  *
-  * The second tool is a protocol log tool. The workshop editor server and gvim
-  * pass information back and forth during a workshop session. Sometimes it is
-  * very important to peruse this conversation in order to understand what is
-  * happening. The wsdebug_log_init() call sets up this protocol log tool and
-  * wsdebug() and wstrace() calls output the information to the log.
-  *
-  * This code must have WSDEBUG defined for it to be compiled into vim/gvim.
-  */
- 
- #ifdef WSDEBUG
- 
- #include "vim.h"
- 
- FILE		*ws_debug = NULL;
- u_int		 ws_dlevel = 0;		/* ws_debug verbosity level */
- 
- void		 wsdebug(char *, ...);
- void		 wstrace(char *, ...);
- 
- static int	 lookup(char *);
- #ifdef USE_WS_ERRORHANDLER
- static int	 errorHandler(Display *, XErrorEvent *);
- #endif
- 
- 
- /*
-  * wsdebug_wait	-   This function can be used to delay or stop execution of vim.
-  *		    It's normally used to delay startup while attaching a
-  *		    debugger to a running process. Since workshop starts gvim
-  *		    from a background process this is the only way to debug
-  *		    startup problems.
-  */
- 
- void wsdebug_wait(
- 	u_int		 wait_flags,	/* tells what to do */
- 	char		*wait_var,	/* wait environment variable */
- 	u_int		 wait_secs)	/* how many seconds to wait */
- {
- 
- 	init_homedir();			/* not inited yet */
- #ifdef USE_WDDUMP
- 	WDDump(0, 0, 0);
- #endif
- 
- 	/* for debugging purposes only */
- 	if (wait_flags & WT_ENV && wait_var && getenv(wait_var) != NULL) {
- 		sleep(atoi(getenv(wait_var)));
- 	} else if (wait_flags & WT_WAIT && lookup("~/.gvimwait")) {
- 		sleep(wait_secs > 0 && wait_secs < 120 ? wait_secs : 20);
- 	} else if (wait_flags & WT_STOP && lookup("~/.gvimstop")) {
- 		int w = 1;
- 		while (w) {
- 			;
- 		}
- 	}
- }    /* end wsdebug_wait */
- 
- 
- void
- wsdebug_log_init(
- 	char		*log_var,	/* env var with log file */
- 	char		*level_var)	/* env var with ws_debug level */
- {
- 	char		*file;		/* possible ws_debug output file */
- 	char		*cp;		/* ws_dlevel pointer */
- 
- 	if (log_var && (file = getenv(log_var)) != NULL)
- 	{
- 		char buf[BUFSIZ];
- 
- 		vim_snprintf(buf, sizeof(buf), "date > %s", file);
- 		system(buf);
- 		ws_debug = fopen(file, "a");
- 		if (level_var && (cp = getenv(level_var)) != NULL) {
- 			ws_dlevel = strtoul(cp, NULL, 0);
- 		} else {
- 			ws_dlevel = WS_TRACE;	/* default level */
- 		}
- #ifdef USE_WS_ERRORHANDLER
- 		XSetErrorHandler(errorHandler);
- #endif
- 	}
- 
- }    /* end wsdebug_log_init */
- 
- 
- 
- 
- void
- wstrace(
- 	char		*fmt,
- 	...)
- {
- 	va_list		 ap;
- 
- 	if (ws_debug!= NULL && (ws_dlevel & (WS_TRACE | WS_TRACE_VERBOSE))) {
- 		va_start(ap, fmt);
- 		vfprintf(ws_debug, fmt, ap);
- 		va_end(ap);
- 		fflush(ws_debug);
- 	}
- 
- }    /* end wstrace */
- 
- 
- void
- wsdebug(
- 	char		*fmt,
- 	...)
- {
- 	va_list		 ap;
- 
- 	if (ws_debug != NULL) {
- 		va_start(ap, fmt);
- 		vfprintf(ws_debug, fmt, ap);
- 		va_end(ap);
- 		fflush(ws_debug);
- 	}
- 
- }    /* end wsdebug */
- 
- 
- static int
- lookup(
- 	char		*file)
- {
- 	char		 buf[BUFSIZ];
- 
- 	expand_env((char_u *) file, (char_u *) buf, BUFSIZ);
- 	return (access(buf, F_OK) == 0);
- 
- }    /* end lookup */
- 
- #ifdef USE_WS_ERRORHANDLER
- static int
- errorHandler(
- 	Display		*dpy,
- 	XErrorEvent	*err)
- {
- 	char		 msg[256];
- 	char		 buf[256];
- 
- 	XGetErrorText(dpy, err->error_code, msg, sizeof(msg));
- 	wsdebug("\n\nWSDEBUG Vim: X Error of failed request: %s\n", msg);
- 
- 	sprintf(buf, "%d", err->request_code);
- 	XGetErrorDatabaseText(dpy,
- 	    "XRequest", buf, "Unknown", msg, sizeof(msg));
- 	wsdebug("\tMajor opcode of failed request: %d (%s)\n",
- 	    err->request_code, msg);
- 	if (err->request_code > 128) {
- 		wsdebug("\tMinor opcode of failed request: %d\n",
- 		    err->minor_code);
- 	}
- 
- 	return 0;
- }
- #endif
- 
- 
- 
- #endif /* WSDEBUG */
--- 0 ----
*** ../vim-8.1.0762/src/wsdebug.h	2016-08-29 22:42:21.000000000 +0200
--- src/wsdebug.h	1970-01-01 01:00:00.000000000 +0100
***************
*** 1,81 ****
- /* vi:set ts=8 sw=8 noet:
-  *
-  * VIM - Vi IMproved	by Bram Moolenaar
-  *			Visual Workshop integration by Gordon Prieur
-  *
-  * Do ":help uganda"  in Vim to read copying and usage conditions.
-  * Do ":help credits" in Vim to see a list of people who contributed.
-  */
- 
- 
- #ifndef WSDEBUG_H
- #define WSDEBUG_H
- 
- #ifdef WSDEBUG
- 
- #ifndef ASSERT
- #define ASSERT(c) \
-     if (!(c)) { \
- 	fprintf(stderr, "Assertion failed: line %d, file %s\n", \
- 		__LINE__, __FILE__); \
- 	fflush(stderr); \
- 	abort(); \
-     }
- #endif
- 
- #define WS_TRACE		0x00000001
- #define WS_TRACE_VERBOSE	0x00000002
- #define WS_TRACE_COLONCMD	0x00000004
- #define WS_DEBUG_ALL		0xffffffff
- 
- #define WSDLEVEL(flags)		(ws_debug != NULL && (ws_dlevel & (flags)))
- 
- #ifdef USE_WDDUMP
- #include "wdump.h"
- #endif
- 
- #define WSDEBUG_TRACE	1
- //#define WSDEBUG_SENSE	2
- 
- typedef enum {
- 		WT_ENV = 1,		/* look for env var if set */
- 		WT_WAIT,		/* look for ~/.gvimwait if set */
- 		WT_STOP			/* look for ~/.gvimstop if set */
- } WtWait;
- 
- 
- void		 wsdebug(char *, ...);
- void		 wstrace(char *, ...);
- 
- 
- extern FILE	*ws_debug;
- extern u_int	 ws_dlevel;		/* ws_debug verbosity level */
- 
- # else		/* not WSDEBUG */
- 
- #ifndef ASSERT
- # define ASSERT(c)
- #endif
- 
- /*
-  * The following 2 stubs are needed because a macro cannot be used because of
-  * the variable number of arguments.
-  */
- 
- void
- wsdebug(
- 	char		*fmt,
- 	...)
- {
- }
- 
- 
- void
- wstrace(
- 	char		*fmt,
- 	...)
- {
- }
- 
- #endif /* WSDEBUG */
- #endif /* WSDEBUG_H */
--- 0 ----
*** ../vim-8.1.0762/src/ex_cmdidxs.h	2019-01-08 22:02:36.044297306 +0100
--- src/ex_cmdidxs.h	2019-01-17 15:31:43.054158710 +0100
***************
*** 28,36 ****
    /* u */ 481,
    /* v */ 492,
    /* w */ 510,
!   /* x */ 525,
!   /* y */ 534,
!   /* z */ 535
  };
  
  /*
--- 28,36 ----
    /* u */ 481,
    /* v */ 492,
    /* w */ 510,
!   /* x */ 524,
!   /* y */ 533,
!   /* z */ 534
  };
  
  /*
***************
*** 63,72 ****
    /* t */ {  2,  0, 19,  0, 22, 24,  0, 25,  0, 26,  0, 27, 31, 34, 36, 37,  0, 38, 40,  0, 41,  0,  0,  0,  0,  0 },
    /* u */ {  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0, 10,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0 },
    /* v */ {  0,  0,  0,  0,  1,  0,  0,  0,  4,  0,  0,  0,  9, 12,  0,  0,  0,  0, 15,  0, 16,  0,  0,  0,  0,  0 },
!   /* w */ {  2,  0,  0,  0,  0,  0,  0,  3,  4,  0,  0,  0,  0,  8,  0,  9, 10,  0, 12,  0, 13, 14,  0,  0,  0,  0 },
    /* x */ {  1,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  2,  5,  0,  0,  0,  0,  0,  0,  7,  0,  0,  0,  0,  0 },
    /* y */ {  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0 },
    /* z */ {  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0 }
  };
  
! static const int command_count = 548;
--- 63,72 ----
    /* t */ {  2,  0, 19,  0, 22, 24,  0, 25,  0, 26,  0, 27, 31, 34, 36, 37,  0, 38, 40,  0, 41,  0,  0,  0,  0,  0 },
    /* u */ {  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0, 10,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0 },
    /* v */ {  0,  0,  0,  0,  1,  0,  0,  0,  4,  0,  0,  0,  9, 12,  0,  0,  0,  0, 15,  0, 16,  0,  0,  0,  0,  0 },
!   /* w */ {  2,  0,  0,  0,  0,  0,  0,  3,  4,  0,  0,  0,  0,  8,  0,  9, 10,  0,  0,  0, 12, 13,  0,  0,  0,  0 },
    /* x */ {  1,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  2,  5,  0,  0,  0,  0,  0,  0,  7,  0,  0,  0,  0,  0 },
    /* y */ {  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0 },
    /* z */ {  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0 }
  };
  
! static const int command_count = 547;
*** ../vim-8.1.0762/src/version.c	2019-01-17 14:31:10.190919265 +0100
--- src/version.c	2019-01-17 15:39:12.143436999 +0100
***************
*** 797,798 ****
--- 793,796 ----
  {   /* Add new patch number below this line */
+ /**/
+     763,
  /**/

-- 
You are Dead.  Do you wish to restart, load, or quit?

 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///