3 * \brief Header: editor constants
9 /** \todo In the distant future, keyboards will be invented with a
10 * separate key for each one of these commands *sigh*
13 /* special commands */
14 #define CK_Insert_Char -1
15 #define CK_Ignore_Key 0
17 /* cursor movements */
18 #define CK_BackSpace 1
22 #define CK_Page_Down 5
25 #define CK_Word_Left 8
26 #define CK_Word_Right 9
33 #define CK_Beginning_Of_Text 16
34 #define CK_End_Of_Text 17
35 #define CK_Scroll_Up 18
36 #define CK_Scroll_Down 19
38 #define CK_Begin_Page 21
39 #define CK_End_Page 22
40 #define CK_Delete_Word_Left 23
41 #define CK_Delete_Word_Right 24
42 #define CK_Paragraph_Up 25
43 #define CK_Paragraph_Down 26
49 #define CK_Save_As 104
50 #define CK_Load_Prev_File 111
51 #define CK_Load_Next_File 112
52 #define CK_Load_Syntax_File 121
53 #define CK_Load_Menu_File 122
61 #define CK_Save_Block 207
62 #define CK_Column_Mark 208
64 /* search and replace */
66 #define CK_Find_Again 302
67 #define CK_Replace 303
68 #define CK_Replace_Again 304
69 #define CK_Complete_Word 305
71 /* debugger commands */
72 #define CK_Debug_Start 350
73 #define CK_Debug_Stop 351
74 #define CK_Debug_Toggle_Break 352
75 #define CK_Debug_Clear 353
76 #define CK_Debug_Next 354
77 #define CK_Debug_Step 355
78 #define CK_Debug_Back_Trace 356
79 #define CK_Debug_Continue 357
80 #define CK_Debug_Enter_Command 358
81 #define CK_Debug_Until_Curser 359
84 #define CK_Insert_File 401
86 #define CK_Toggle_Insert 403
89 #define CK_Refresh 406
91 #define CK_Delete_Line 408
92 #define CK_Delete_To_Line_End 409
93 #define CK_Delete_To_Line_Begin 410
94 #define CK_Man_Page 411
98 #define CK_Complete 415
99 #define CK_Paragraph_Format 416
101 #define CK_Type_Load_Python 418
102 #define CK_Find_File 419
104 #define CK_Match_Bracket 421
105 #define CK_Terminal 422
106 #define CK_Terminal_App 423
107 #define CK_ExtCmd 424
108 #define CK_User_Menu 425
109 #define CK_Find_Definition 426
111 /* application control */
112 #define CK_Save_Desktop 451
113 #define CK_New_Window 452
116 #define CK_Save_And_Quit 455
117 #define CK_Run_Another 456
118 #define CK_Check_Save_And_Quit 457
119 #define CK_Maximize 458
121 #define CK_Toggle_Tab_TWS 470
122 #define CK_Toggle_Syntax 480
123 #define CK_Toggle_Line_State 490
126 #define CK_Begin_Record_Macro 501
127 #define CK_End_Record_Macro 502
128 #define CK_Delete_Macro 503
131 #define CK_Toggle_Bookmark 550
132 #define CK_Flush_Bookmarks 551
133 #define CK_Next_Bookmark 552
134 #define CK_Prev_Bookmark 553
136 /* highlight commands */
137 #define CK_Page_Up_Highlight 604
138 #define CK_Page_Down_Highlight 605
139 #define CK_Left_Highlight 606
140 #define CK_Right_Highlight 607
141 #define CK_Word_Left_Highlight 608
142 #define CK_Word_Right_Highlight 609
143 #define CK_Up_Highlight 610
144 #define CK_Down_Highlight 611
145 #define CK_Home_Highlight 612
146 #define CK_End_Highlight 613
147 #define CK_Beginning_Of_Text_Highlight 614
148 #define CK_End_Of_Text_Highlight 615
149 #define CK_Begin_Page_Highlight 616
150 #define CK_End_Page_Highlight 617
151 #define CK_Scroll_Up_Highlight 618
152 #define CK_Scroll_Down_Highlight 619
153 #define CK_Paragraph_Up_Highlight 620
154 #define CK_Paragraph_Down_Highlight 621
156 /* alt highlight commands */
157 #define CK_Page_Up_Alt_Highlight 654
158 #define CK_Page_Down_Alt_Highlight 655
159 #define CK_Left_Alt_Highlight 656
160 #define CK_Right_Alt_Highlight 657
161 #define CK_Word_Left_Alt_Highlight 658
162 #define CK_Word_Right_Alt_Highlight 659
163 #define CK_Up_Alt_Highlight 660
164 #define CK_Down_Alt_Highlight 661
165 #define CK_Home_Alt_Highlight 662
166 #define CK_End_Alt_Highlight 663
167 #define CK_Beginning_Of_Text_Alt_Highlight 664
168 #define CK_End_Of_Text_Alt_Highlight 665
169 #define CK_Begin_Page_Alt_Highlight 666
170 #define CK_End_Page_Alt_Highlight 667
171 #define CK_Scroll_Up_Alt_Highlight 668
172 #define CK_Scroll_Down_Alt_Highlight 669
173 #define CK_Paragraph_Up_Alt_Highlight 670
174 #define CK_Paragraph_Down_Alt_Highlight 671
176 /* X clipboard operations */
177 #define CK_XStore 701
179 #define CK_XPaste 703
180 #define CK_Selection_History 704
186 #define CK_Ext_Mode 820
189 #define CK_Insert_Literal 851
190 #define CK_Execute_Macro 852
191 #define CK_Begin_End_Macro 853
195 #define CK_ShowCommandLine 2001
196 #define CK_SelectCodepage 2002
197 #define CK_StartExtMap1 2021
198 #define CK_StartExtMap2 2022
201 #define CK_InputBol 4001
202 #define CK_InputEol 4002
203 #define CK_InputMoveLeft 4003
204 #define CK_InputWordLeft 4004
205 #define CK_InputBackwardChar 4005
206 #define CK_InputBackwardWord 4006
207 #define CK_InputMoveRight 4007
208 #define CK_InputWordRight 4008
209 #define CK_InputForwardChar 4009
210 #define CK_InputForwardWord 4010
211 #define CK_InputBackwardDelete 4011
212 #define CK_InputDeleteChar 4012
213 #define CK_InputKillWord 4013
214 #define CK_InputBackwardKillWord 4014
215 #define CK_InputSetMark 4015
216 #define CK_InputKillRegion 4016
217 #define CK_InputKillSave 4017
218 #define CK_InputYank 4018
219 #define CK_InputKillLine 4020
220 #define CK_InputHistoryPrev 4021
221 #define CK_InputHistoryNext 4022
222 #define CK_InputHistoryShow 4023
223 #define CK_InputComplete 4024
226 #define CK_ViewSearch 5001
227 #define CK_ViewContinueSearch 5002
228 #define CK_ViewGotoBookmark 5003
229 #define CK_ViewNewBookmark 5004
230 #define CK_ViewMoveUp 5005
231 #define CK_ViewMoveDown 5006
232 #define CK_ViewMoveLeft 5007
233 #define CK_ViewMoveRight 5008
234 #define CK_ViewMovePgDn 5009
235 #define CK_ViewMovePgUp 5010
236 #define CK_ViewMoveHalfPgDn 5011
237 #define CK_ViewMoveHalfPgUp 5012
238 #define CK_ViewMoveToBol 5013
239 #define CK_ViewMoveToEol 5014
240 #define CK_ViewNextFile 5015
241 #define CK_ViewPrevFile 5016
242 #define CK_ViewToggleRuler 5017
243 #define CK_HexViewToggleNavigationMode 5018
244 #define CK_ViewQuit 5020
247 #define CK_ChmodCmd 7001
248 #define CK_ChownAdvancedCmd 7002
249 #define CK_ChownCmd 7003
250 #define CK_CompareDirsCmd 7004
251 #define CK_ConfigureBox 7005
252 #define CK_ConfigureVfs 7006
253 #define CK_ConfirmBox 7007
254 #define CK_CopyCmd 7008
255 #define CK_CopyCurrentPathname 7009
256 #define CK_CopyOtherPathname 7010
257 #define CK_DeleteCmd 7011
258 #define CK_DirsizesCmd 7012
259 #define CK_DisplayBitsBox 7013
260 #define CK_EditCmd 7014
261 #define CK_EditMcMenuCmd 7015
262 #define CK_EditSymlinkCmd 7016
263 #define CK_EditSyntaxCmd 7017
264 #define CK_EditUserMenuCmd 7018
265 #define CK_ExternalPanelize 7020
266 #define CK_FilterCmd 7021
267 #define CK_FilteredViewCmd 7022
268 #define CK_FindCmd 7023
269 #define CK_FishlinkCmd 7024
270 #define CK_FtplinkCmd 7025
271 #define CK_HistoryCmd 7026
272 #define CK_InfoCmd 7027
273 #define CK_JobsCmd 7028
274 #define CK_LayoutCmd 7029
275 #define CK_LearnKeys 7030
276 #define CK_LinkCmd 7031
277 #define CK_ListingCmd 7033
278 #define CK_MenuLastSelectedCmd 7034
279 #define CK_MkdirCmd 7035
280 #define CK_QuickCdCmd 7036
281 #define CK_QuickChdirCmd 7037
282 #define CK_QuickViewCmd 7038
283 #define CK_RenCmd 7039
284 #define CK_RereadCmd 7040
285 #define CK_ReselectVfs 7041
286 #define CK_ReverseSelectionCmd 7043
287 #define CK_SaveSetupCmd 7044
288 #define CK_SelectCmd 7045
289 #define CK_SingleDirsizeCmd 7046
290 #define CK_SuspendCmd 7047
291 #define CK_SwapCmd 7048
292 #define CK_SymlinkCmd 7049
293 #define CK_ToggleListingCmd 7050
294 #define CK_TreeCmd 7051
295 #define CK_UndeleteCmd 7052
296 #define CK_UnselectCmd 7053
297 #define CK_UserFileMenuCmd 7054
298 #define CK_ViewCmd 7055
299 #define CK_ViewFileCmd 7056
300 #define CK_QuietQuitCmd 7058
301 #define CK_CopyCurrentTagged 7059
302 #define CK_CopyCurrentReadlink 7060
303 #define CK_CopyOtherReadlink 7061
304 #define CK_AddHotlist 7062
305 #define CK_QuitCmd 7064
306 #define CK_CopyOtherTarget 7065
307 #define CK_ToggleShowHidden 7066
310 #define CK_PanelChdirOtherPanel 8001
311 #define CK_PanelChdirToReadlink 8002
312 #define CK_PanelCmdCopyLocal 8003
313 #define CK_PanelCmdDeleteLocal 8004
314 #define CK_PanelCmdDoEnter 8005
315 #define CK_PanelCmdEditNew 8006
316 #define CK_PanelCmdRenameLocal 8007
317 #define CK_PanelCmdReverseSelection 8008
318 #define CK_PanelCmdSelect 8009
319 #define CK_PanelCmdUnselect 8010
320 #define CK_PanelCmdViewSimple 8011
321 #define CK_PanelCtrlNextPage 8012
322 #define CK_PanelCtrlPrevPage 8013
323 #define CK_PanelDirectoryHistoryList 8014
324 #define CK_PanelDirectoryHistoryNext 8015
325 #define CK_PanelDirectoryHistoryPrev 8016
326 #define CK_PanelGotoBottomFile 8017
327 #define CK_PanelGotoMiddleFile 8018
328 #define CK_PanelGotoTopFile 8019
329 #define CK_PanelMarkFile 8020
330 #define CK_PanelMoveDown 8021
331 #define CK_PanelMoveEnd 8022
332 #define CK_PanelMoveHome 8023
333 #define CK_PanelMoveUp 8024
334 #define CK_PanelMoveLeft 8025
335 #define CK_PanelMoveRight 8026
336 #define CK_PanelNextPage 8027
337 #define CK_PanelPrevPage 8028
338 #define CK_PanelSetPanelEncoding 8029
339 #define CK_PanelStartSearch 8030
340 #define CK_PanelSyncOtherPanel 8031
341 #define CK_PanelToggleSortOrderNext 8032
342 #define CK_PanelToggleSortOrderPrev 8033
343 #define CK_PanelSelectSortOrder 8034
344 #define CK_PanelReverseSort 8035
345 #define CK_PanelSortOrderByName 8036
346 #define CK_PanelSortOrderByExt 8037
347 #define CK_PanelSortOrderBySize 8038
348 #define CK_PanelSortOrderByMTime 8039
351 Process a block through a shell command: CK_Pipe_Block(i) executes shell_cmd[i].
352 shell_cmd[i] must process the file ~/cooledit.block and output ~/cooledit.block
353 which is then inserted into the text in place of the original block. shell_cmd[i] must
354 also produce a file homedir/cooledit.error . If this file is not empty an error will
355 have been assumed to have occured, and the block will not be replaced.
356 TODO: bring up a viewer to display the error message instead of inserting
357 it into the text, which is annoying.
359 #define CK_Pipe_Block(i) (1000+(i))
360 #define SHELL_COMMANDS_i {"/edit.indent.rc", "/edit.spell.rc", /* and so on */ 0 }
361 #define CK_Macro(i) (2000+(i))
362 #define CK_Last_Macro CK_Macro(0x7FFF)
365 #define CK_User_Command(i) ((i) | (1 << 16))
366 #define IS_USER_COMMAND(i) ((i) & (1 << 16))
367 #define CK_Macro(i) ((i) | (1 << 17))
368 #define IS_MACRO_COMMAND(i) ((i) & (1 << 17))
370 #endif /* MC_CMD_DEF_H */