- [X] C config module that reads an ini-style file to set attributes
based on path
- [ ] configure "initial_panes"
-- [ ] discard old auto-load??
+- [X] discard old auto-load??
- [ ] file patterns for "complete" to (optionally) ignore
- [ ] read .gitignore and add to "ignore" list
- [ ] top/bottom margin - "render-vmargin" set on view or doc??
return Efail;
}
-DEF_CMD(editor_auto_load)
-{
- int ret;
- struct ed_info *ei = ci->home->data;
- struct map *map = ei->map;
- const char *mod = ksuffix(ci, "attach-");
- char *mod2 = NULL;
-
- /* Check the key really doesn't exist, rather than
- * it fails
- */
- if (key_lookup_cmd(map, ci->key))
- return Efallthrough;
-
- if (strstarts(mod, "doc-") ||
- strstarts(mod, "render-") ||
- strstarts(mod, "mode-") ||
- strstarts(mod, "display-"))
- ;
- else {
- const char *m = strrchr(ci->key, '-');
- if (m) {
- m += 1;
- mod2 = malloc(4+strlen(m)+1);
- strcpy(mod2, "lib-");
- strcpy(mod2+4, m);
- mod = mod2;
- }
- }
-
- ret = call("global-load-module", ci->home, 0, NULL,
- mod, 0);
- free(mod2);
-
- if (ret > 0)
- /* auto-load succeeded */
- return key_lookup(map, ci);
- return Efallthrough;
-}
-
DEF_CMD(editor_auto_event)
{
/* Event handlers register under a private name so we
key_add(ed_map, "global-get-command", &global_get_command);
key_add(ed_map, "global-load-module", &editor_load_module);
key_add(ed_map, "global-config-dir", &global_config_dir);
- key_add_prefix(ed_map, "attach-", &editor_auto_load);
key_add_prefix(ed_map, "event:", &editor_auto_event);
key_add_prefix(ed_map, "global-multicall-", &editor_multicall);
key_add_prefix(ed_map, "editor:request:",
PREFIX charset-to-utf8-windows-
PREFIX charset-to-utf8-iso-8859-
+
+doc-docs = attach-doc-docs
+doc-list = attach-doc-list
+doc-multipart = attach-doc-multipart
+render-complete = attach-render-complete
+mode-emacs = attach-mode-emacs
+display-ncurses = attach-display-ncurses
+lib-abbrev = attach-abbrev
+lib-base64 = attach-base64
+lib-crop = attach-crop
+lib-history = attach-history
+lib-input = attach-input
+lib-keymap = attach-keymap
+lib-libevent = attach-libevent
+lib-linefilter = attach-linefilter
+lib-markup = attach-markup
+lib-menu = attach-menu
+lib-messageline = attach-messageline
+lib-renderline = attach-renderline
+lib-rfc822header = attach-rfc822header
+lib-tile = attach-tile
+lib-view = attach-view
+lib-keymap = attach-global-keymap
+lib-glibevents = attach-glibevents
+lib-shellcmd = attach-shellcmd
+
[file:COMMIT_EDITMSG*]
APPEND view-default = ,textfill,whitespace,autospell
fill-width = 72