[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 31/35: Introduce company-clang-insert-arguments
From: |
Dmitry Gutov |
Subject: |
[elpa] 31/35: Introduce company-clang-insert-arguments |
Date: |
Sat, 19 Apr 2014 10:12:21 +0000 |
dgutov pushed a commit to branch master
in repository elpa.
commit 012887ae4ab7f7fe6fd582e45c8f28ed605e1218
Author: Dmitry Gutov <address@hidden>
Date: Mon Apr 14 05:09:43 2014 +0400
Introduce company-clang-insert-arguments
Closes #102
---
NEWS.md | 1 +
company-clang.el | 5 ++++-
2 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/NEWS.md b/NEWS.md
index 591c9e7..9037b01 100644
--- a/NEWS.md
+++ b/NEWS.md
@@ -2,6 +2,7 @@
## Next
+* New user option `company-clang-insert-arguments`, by default t.
* Default value of `company-idle-delay` lowered to `0.5`.
* New user option `company-tooltip-minimum-width`, by default 0.
* New function `company-grab-symbol-cons`.
diff --git a/company-clang.el b/company-clang.el
index 14b6753..4f0f318 100644
--- a/company-clang.el
+++ b/company-clang.el
@@ -60,6 +60,9 @@ or automatically through a custom
`company-clang-prefix-guesser'."
(defvar company-clang-modes '(c-mode c++-mode objc-mode)
"Major modes which clang may complete.")
+(defcustom company-clang-insert-arguments t
+ "When non-nil, insert function arguments as a template after completion.")
+
;; prefix
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defvar company-clang--prefix nil)
@@ -311,7 +314,7 @@ passed via standard input."
(meta (company-clang--meta arg))
(annotation (company-clang--annotation arg))
(post-completion (let ((anno (company-clang--annotation arg)))
- (when anno
+ (when (and company-clang-insert-arguments anno)
(insert anno)
(if (string-match ":" anno)
(company-clang-objc-templatify anno)
- [elpa] 23/35: Introduce `company-tooltip-minimum-width', (continued)
- [elpa] 23/35: Introduce `company-tooltip-minimum-width', Dmitry Gutov, 2014/04/19
- [elpa] 25/35: Make version string compatible with Emacs < 24.4, Dmitry Gutov, 2014/04/19
- [elpa] 24/35: Lower company-idle-delay, Dmitry Gutov, 2014/04/19
- [elpa] 06/35: Drop Emacs 23 compatibility, Dmitry Gutov, 2014/04/19
- [elpa] 11/35: Initial support for asynchonous backends (#62), Dmitry Gutov, 2014/04/19
- [elpa] 26/35: Merge pull request #100 from bbatsov/version-fix, Dmitry Gutov, 2014/04/19
- [elpa] 27/35: Try to use the more up-to-date snapshot packages, Dmitry Gutov, 2014/04/19
- [elpa] 29/35: Merge pull request #101 from bbatsov/master, Dmitry Gutov, 2014/04/19
- [elpa] 15/35: Merge branch 'clang-async', Dmitry Gutov, 2014/04/19
- [elpa] 30/35: Fix the test breakage (probably), Dmitry Gutov, 2014/04/19
- [elpa] 31/35: Introduce company-clang-insert-arguments,
Dmitry Gutov <=
- [elpa] 05/35: Update NEWS, Dmitry Gutov, 2014/04/19
- [elpa] 34/35: Release 0.8.0, Dmitry Gutov, 2014/04/19
- [elpa] 33/35: Always include company-capf in the backends, Dmitry Gutov, 2014/04/19
- [elpa] 35/35: Merge commit '51c140ca9ee32d27cacc7b2b07d4539bf98ae575' from company-master, Dmitry Gutov, 2014/04/19
- [elpa] 28/35: Use cl-lib, Dmitry Gutov, 2014/04/19
- [elpa] 32/35: `company-other-backend': don't use `company-manual-begin', Dmitry Gutov, 2014/04/19
- [elpa] 01/35: New option company-abort-manual-when-too-short, Dmitry Gutov, 2014/04/19