File: jedmenu.sl

package info (click to toggle)
aterm 1.0.0-4
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 1,432 kB
  • ctags: 1,431
  • sloc: ansic: 14,688; sh: 3,391; makefile: 250
file content (136 lines) | stat: -rw-r--r-- 3,000 bytes parent folder | download | duplicates (26)
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
%--------------------------------*-SLang-*--------------------------------
% An example of using the rxvt menuBar for the JED editor
#if$TERM xterm*
%!% provide a hook to imitated the S-Lang> prompt
%!% use ESC[m to shadow the ESC[M used by mouse reporting
define menuFn ()
{
   variable ch, cmd;

   cmd = Null_String;
   forever
     {
	ch = getkey ();
	if (ch == '\r') break;
	cmd = strcat (cmd, char (ch));
     }
   eval (cmd);
}
local_setkey ("menuFn", "\e[m");	% menu

%!% allow the user to bind their owm commands
define menucmd (str) { tt_send (Sprintf ("\e]10;%s\a", str, 1)); }
%-------------------------------------------------------------------------
% integrate these with any existing suspend/resume/exit hooks
% the suspend hook works best if there was already a menu defined
% before invoking JED

define suspend_hook () { menucmd ("[prev]"); }
define resume_hook () { menucmd ("[next]"); }
define exit_hook () { menucmd ("[rm]"); exit_jed (); }

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
menucmd ("[read:jedmenu.sl]");		% read this file

% format _jed_version xyyzz into x.yy-zz
menucmd (Sprintf ("[:[title:Jed%d.%d-%d (%%n-%%v)]:]",
		  (_jed_version/10000),
		  ((_jed_version mod 10000)/100),
		  (_jed_version mod 100),
		  3));

% get rid off pixmap stuff
if (strcmp (getenv ("COLORTERM"), "rxvt-xpm"))
{
   menucmd ("[menu][:-/Terminal/Pixmap:][show]");
}
#endif	% xterm*
%%%%%%%%%%%%%%%%%%%%%%%%%%% end-of-file (SLang) %%%%%%%%%%%%%%%%%%%%%%%%%%
% rxvt menu database
#iffalse
% An example of using the rxvt menuBar for the JED editor
% possibly useful things for the JED editor -- assuming Emacs bindings

[menu:jed]

[title:Jed menu (%n-%v)]
% some convenient arrows
<b>\E[m<l>bskip_word<u>backward_paragraph<d>forward_paragraph<r>skip_word<e>\r

/File/*
{Open}{^X^F}
{Save}{^X^W}
{Save Buffers}{^Xs}
{Insert File}{^Xi}
{-}
{Shell Cmd}{M-!}
{-}
{Exit}{^X^C}

/Edit/*
{Undo}{^_}
{-}
{Cut}{^W}
{Copy}{M-W}
{Paste}{^Y}

/Search/*
{Forward}{^S}
{Backward}{^R}
{Replace}{M-%}
{-}
./Regexp/*
{Forward}{M-^S}
{Backward}{M-^R}
{Replace}	\E[mquery_replace_match\r

/Buffers/*
{Kill}{^Xk}
{List}{^X^B}
{Switch}{^Xb}
{-}
./Modes/*
{C}		\E[mc_mode\r
{SLang}	\E[mslang_mode\r
{None}		\E[mno_mode\r
{LaTeX}	\E[mlatex_mode\r
{Text}		\E[mtext_mode\r
{Fortran}	\E[mfortran_mode\r

/Window/*
{Delete}{^X0}
{One}{^X1}
{Split}{^X2}
{Other}{^Xo}
{-}
{Recenter}{^L}
{-}
./Color Schemes/*
{White-on-Black}	\E[mset_color_scheme("15;0")\r
{Black-on-White}	\E[mset_color_scheme("0;15")\r
{White-on-default-Black}\E[mset_color_scheme("15;default;0")\r
{Black-on-default-White}\E[mset_color_scheme("0;default;15")\r

/Utils/*
{Bufed}	\E[mbufed\r
{Dired}	\E[mdired\r
{Mail}	\E[mmail\r
{Rmail}	\E[mrmail\r
{-}
{EvalBuffer}	\E[mevalbuffer\r
{Trim-Buffer}	\E[mtrim_buffer\r

[read:terminal]

/?/*
{Info}{^X?i}
{Man}{^X?m}
{-}
{Apropos}{^X?a}
{Show Key}{^X?k}
{Where Is}{^X?w}

[show]
[done]
#endif
%%%%%%%%%%%%%%%%%%%%%%%%%%% end-of-file (SLang) %%%%%%%%%%%%%%%%%%%%%%%%%%