Commit graph

121 commits

Author SHA1 Message Date
Henrik Lissner
6d10b9bbdf
Revert to Meta, instead of Super
Using meta is a little more flexible. Since there is no dedicated meta
key on our keyboards (anymore), it can be remapped to another modifier
by changing mac-command-modifier, x-meta-keysym, etc. without
sacrificing super or alt keybinds.
2018-12-31 15:00:05 -05:00
Henrik Lissner
747c040c0e
default/config: explicitly use :states #1084
The 'motion alias didn't appear to be working.
2018-12-29 20:56:12 -05:00
Oleksii Filonenko
9a0da588d9
Add helm to project tasks 2018-12-28 03:31:03 +02:00
Henrik Lissner
869758e8f5
Remove extra parentheses #1075 2018-12-27 15:05:14 -05:00
Oleksii Filonenko
35bf785f75
[config/default] Fix C-S-s in company minibuffer 2018-12-27 17:26:29 +02:00
Henrik Lissner
e58c1ff89d
Fix TAB in modes with their own keybind
Like org-mode
2018-12-26 15:01:28 -05:00
Henrik Lissner
b88c712715
Merge pull request #1057 from ar1a/helm-project-search-bind
Bind SPC-/-p to +helm/project-search if using helm
2018-12-25 04:37:25 -05:00
Henrik Lissner
649d34244a
evil-define-key -> evil-define-key* 2018-12-25 04:36:15 -05:00
Vladyslav M
62f9c9827f
config/default: fix Wrong number of arguments: define-key 2018-12-25 11:18:03 +02:00
Henrik Lissner
9c2a1b1f61
config/default: TAB->[tab] for workspace keys 2018-12-25 02:45:10 -05:00
Henrik Lissner
9f2dff02fa
Rethink config/default & keybindings
+ Added +smartparens flag to config/default for default smartparens
  config.
+ Fixed +tng support for completion/company.
+ Removed super keybinds (for all but MacOS)
+ Moved "keybind fixes" to config/default/config.el (these should be
  universally available).
+ Replaced both +default-repeat-forward-key and +default-repeat-backward-key
  with +default-repeat-keys. If this variable is nil, the universal
  repeat motions won't be bound.
2018-12-24 00:04:50 -05:00
Aria
45bb7256cb Bind SPC-/-d to helm too 2018-12-23 18:43:16 +11:00
Aria
715c189608 Bind SPC-/-p to +helm/project-search if using helm 2018-12-23 16:53:45 +11:00
Henrik Lissner
032bde6aa2
Fix malformed keybind remapping 2018-12-22 19:34:56 -05:00
Henrik Lissner
954b0f9c5d
Minor tweaks to map! calls for correctness
+ :map arguments shouldn't be quoted
+ :localleader keys default to all states in the absence of state
  modifiers. This is preferred, rather than restricting their use to
  normal state.
+ :map* is deprecated (there is no difference between it and :map)
2018-12-22 17:01:00 -05:00
Henrik Lissner
d222327d24
Reformat SPC n keys
Used to be in general-define-key format, now in canonical map! format.
2018-12-22 16:48:42 -05:00
Henrik Lissner
fc24c3bff2
Fix #1056: S key in insert/emacs state
A keybind intended for operator mode was bound globally.
2018-12-22 16:40:46 -05:00
Henrik Lissner
4a69fb5d29
Fix non-prefix key error on MacOS
kbd is necessary for global-set-key, otherwise it reads M-` as three
keys M, - and `, and M is already bound to self-insert-command, so it
cannot be used as a prefix.
2018-12-22 14:23:11 -05:00
Henrik Lissner
43fa39eaf1
config/default: restore q, p, r, s, t leader groups 2018-12-22 05:29:57 -05:00
Henrik Lissner
5e33fefd74
Fix malformed map! yasnippet keybinds
Causing breaking errors.
2018-12-22 05:20:02 -05:00
Henrik Lissner
4daa9271a0
Introduce general.el & rewrite map!
+ Now uses an overriding keymap for leader keys, so that it is always
  available, even outside of normal/visual states. In insert/emacs
  states, or in sessions where evil is absent, an alternative prefix is
  used for leader/localleader keys. See these variables:
  + doom-leader-prefix
  + doom-leader-alt-prefix
  + doom-localleader-prefix
  + doom-localleader-alt-prefix
+ Keybinds now support alternative prefixes through the new :alt-prefix
  property. This is useful for non-evil users and non-normal evil
  states. By default, this is M-SPC (leader) and M-SPC m (localleader).
+ Removed +evil-commands flag from config/default (moved to
  feature/evil/+commands.el).
+ config/default/+bindings.el has been split into
  config/default/+{evil,emacs}-bindings.el, which one is loaded depends
  on whether evil is present or not. The latter is blank, but will soon
  be populated with a keybinding scheme for non-evil users (perhaps
  inspired by #641).
+ The define-key! macro has been replaced; it is now an alias for
  general-def.
+ Added unmap! as an alias for general-unbind.
+ The following modifier key conventions are now enforced for
  consistency, across all OSes:
    alt/option      = meta
    windows/command = super
  It used to be
    alt/option      = alt
    windows/command = meta
  Many of the default keybinds have been updated to reflect this switch,
  but it is likely to affect personal meta/super keybinds!

The map! macro has also been rewritten to use general-define-key. Here
is what has been changed:

+ map! no longer works with characters, e.g. (map! ?x #'do-something) is
  no longer supported. Keys must be kbd-able strings like "C-c x" or
  vectors like [?C-c ?x].
+ The :map and :map* properties are now the same thing. If specified
  keymaps aren't defined when binding keys, it is automatically
  deferred.
+ The way you bind local keybinds has changed:

    ;; Don't do this
    (map! :l "a" #'func-a
          :l "b" #'func-b)
    ;; Do this
    (map! :map 'local "a" #'func-a
                      "b" #'func-b)

+ map! now supports the following new blocks:
  + (:if COND THEN-FORM ELSE-FORM...)
  + (:alt-prefix PREFIX KEYS...) -- this prefix will be used for
    non-normal evil states. Equivalent to :non-normal-prefix in general.
+ The way you declare a which-key label for a prefix key has changed:

    ;; before
    (map! :desc "label" :prefix "a" ...)
    ;; now
    (map! :prefix ("a" . "label") ...)

+ It used to be that map! supported binding a key to a key sequence,
  like so:

    (map! "a" [?x])  ; pressing a is like pressing x

  This functionality was removed *temporarily* while I figure out the
  implementation.

Addresses: #448, #814, #860
Mentioned in: #940
2018-12-22 04:14:43 -05:00