Skip to content
Browse files

Move all defcustoms and faces in their respectives groups and files.

  • Loading branch information...
1 parent a1b8c7b commit ba17f09b4d962f512cd346c9fa971695931d7c00 @thierryvolpiatto thierryvolpiatto committed Mar 23, 2012
Showing with 848 additions and 705 deletions.
  1. +23 −1 helm-adaptative.el
  2. +16 −0 helm-apt.el
  3. +38 −0 helm-bmkext.el
  4. +10 −0 helm-bookmark.el
  5. +42 −1 helm-buffers.el
  6. +20 −0 helm-command.el
  7. +25 −1 helm-config.el
  8. +45 −0 helm-elisp.el
  9. +11 −0 helm-emms.el
  10. +18 −0 helm-eval.el
  11. +31 −0 helm-external.el
  12. +212 −1 helm-files.el
  13. +11 −0 helm-gentoo.el
  14. +46 −0 helm-grep.el
  15. +58 −1 helm-info.el
  16. +36 −0 helm-locate.el
  17. +28 −1 helm-misc.el
  18. +53 −12 helm-net.el
  19. +30 −0 helm-regexp.el
  20. +23 −0 helm-ring.el
  21. +34 −0 helm-tags.el
  22. +26 −3 helm-utils.el
  23. +0 −684 helm-vars.el
  24. +9 −0 helm-w3m.el
  25. +3 −0 helm.el
View
24 helm-adaptative.el
@@ -19,8 +19,30 @@
(require 'cl)
(require 'helm)
-(require 'helm-vars)
+
+(defgroup helm-adapt nil
+ "Adaptative sorting of candidates for Helm."
+ :group 'helm)
+
+(defcustom helm-c-adaptive-history-file
+ "~/.emacs.d/helm-c-adaptive-history"
+ "Path of file where history information is stored."
+ :type 'string
+ :group 'helm-config)
+
+(defcustom helm-c-adaptive-history-length 50
+ "Maximum number of candidates stored for a source."
+ :type 'number
+ :group 'helm-config)
+
+(defcustom helm-c-use-adaptative-sorting nil
+ "Wheter to use or not adaptative sorting.
+Even if a source use it, it will have no effect when set to nil."
+ :type 'boolean
+ :group 'helm-config)
+
+
;; Internal
(defvar helm-c-adaptive-done nil
"nil if history information is not yet stored for the current
View
16 helm-apt.el
@@ -27,6 +27,22 @@
(declare-function term-send-input "term")
(declare-function term-send-eof "term")
+
+(defgroup helm-apt nil
+ "Apt related Applications and libraries for Helm."
+ :group 'helm)
+
+(defface helm-apt-installed
+ '((t (:foreground "green")))
+ "*Face used for apt installed candidates."
+ :group 'helm-apt)
+
+(defface helm-apt-deinstalled
+ '((t (:foreground "DimGray")))
+ "*Face used for apt deinstalled candidates."
+ :group 'helm-apt)
+
+
(defvar helm-c-source-apt
'((name . "APT")
(init . helm-c-apt-init)
View
38 helm-bmkext.el
@@ -20,6 +20,44 @@
(require 'helm)
(require 'helm-bookmark)
+
+;;; Faces
+;;
+;;
+(defgroup helm-bmkext nil
+ "Bmkext related Applications and libraries for Helm."
+ :group 'helm)
+
+(defface helm-bmkext-info
+ '((t (:foreground "green")))
+ "*Face used for W3m Emacs bookmarks (not w3m bookmarks)."
+ :group 'helm-bmkext)
+
+(defface helm-bmkext-w3m
+ '((t (:foreground "yellow")))
+ "*Face used for W3m Emacs bookmarks (not w3m bookmarks)."
+ :group 'helm-bmkext)
+
+(defface helm-bmkext-gnus
+ '((t (:foreground "magenta")))
+ "*Face used for Gnus bookmarks."
+ :group 'helm-bmkext)
+
+(defface helm-bmkext-man
+ '((t (:foreground "Orange4")))
+ "*Face used for Woman/man bookmarks."
+ :group 'helm-bmkext)
+
+(defface helm-bmkext-no--file
+ '((t (:foreground "grey")))
+ "*Face used for non--file bookmarks."
+ :group 'helm-bmkext)
+
+(defface helm-bmkext-file
+ '((t (:foreground "Deepskyblue2")))
+ "*Face used for non--file bookmarks."
+ :group 'helm-bmkext)
+
;; Dependency: http://mercurial.intuxication.org/hg/emacs-bookmark-extension
;; If you want to enable google-maps in addressbook you will need
;; Julien Danjou google-maps-el package available here:
View
10 helm-bookmark.el
@@ -21,6 +21,16 @@
(require 'helm)
(require 'helm-utils)
+
+(defgroup helm-bookmark nil
+ "Predefined configurations for `helm.el'."
+ :group 'helm)
+
+(defface helm-bookmarks-su-face '((t (:foreground "red")))
+ "Face for su/sudo bookmarks."
+ :group 'helm-bookmark)
+
+
(defvar helm-c-bookmarks-face1 'helm-ff-directory)
(defvar helm-c-bookmarks-face2 'helm-ff-file)
View
43 helm-buffers.el
@@ -19,9 +19,50 @@
(require 'cl)
(require 'helm)
-(require 'helm-vars)
(require 'helm-utils)
+(defgroup helm-buffers nil
+ "Buffers related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-boring-buffer-regexp
+ (rx (or
+ (group bos " ")
+ ;; helm-buffers
+ "*helm" "*helm-mode"
+ ;; echo area
+ " *Echo Area" " *Minibuf"))
+ "The regexp that match boring buffers.
+Buffer candidates matching this regular expression will be
+filtered from the list of candidates if the
+`helm-c-skip-boring-buffers' candidate transformer is used, or
+they will be displayed with face `file-name-shadow' if
+`helm-c-shadow-boring-buffers' is used."
+ :type 'string
+ :group 'helm-buffers)
+
+(defcustom helm-allow-skipping-current-buffer nil
+ "Show current buffer or not in helm buffer"
+ :type 'boolean
+ :group 'helm-buffers)
+
+
+;;; Faces
+;;
+;;
+(defface helm-buffer-saved-out
+ '((t (:foreground "red")))
+ "*Face used for buffer files modified outside of emacs."
+ :group 'helm-buffers)
+
+(defface helm-buffer-not-saved
+ '((t (:foreground "Indianred2")))
+ "*Face used for buffer files not already saved on disk."
+ :group 'helm-buffers)
+
+
+;;; Buffers keymap
+;;
(defvar helm-c-buffer-map
(let ((map (make-sparse-keymap)))
(set-keymap-parent map helm-map)
View
20 helm-command.el
@@ -21,6 +21,26 @@
(require 'helm)
(require 'helm-mode)
+
+(defgroup helm-command nil
+ "Emacs command related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-M-x-requires-pattern 2
+ "Value of requires-pattern for `helm-M-x'.
+Set it to 0 to disable requires-pattern in `helm-M-x'."
+ :group 'helm-command
+ :type 'boolean)
+
+
+;;; Faces
+;;
+;;
+(defface helm-M-x-key-face '((t (:foreground "orange" :underline t)))
+ "*Face used in helm-M-x to show keybinding."
+ :group 'helm-command)
+
+
(defvar helm-M-x-input-history nil)
(defun* helm-M-x-get-major-mode-command-alist (mode-map)
View
26 helm-config.el
@@ -23,7 +23,6 @@
;;
(require 'cl)
(require 'helm)
-(require 'helm-vars)
(require 'helm-utils)
(require 'helm-plugin)
(require 'helm-buffers)
@@ -66,6 +65,25 @@
(require 'helm-slime nil t)
+(defgroup helm-config nil
+ "Various configurations for Helm."
+ :group 'helm)
+
+(defcustom helm-command-prefix-key "C-x c"
+ "The key `helm-command-prefix' is bound to in the global map."
+ :type '(choice (string :tag "Key") (const :tag "no binding"))
+ :group 'helm-config
+ :set
+ (lambda (var key)
+ (when (and (boundp var) (symbol-value var))
+ (define-key (current-global-map)
+ (read-kbd-macro (symbol-value var)) nil))
+ (when key
+ (define-key (current-global-map)
+ (read-kbd-macro key) 'helm-command-prefix))
+ (set var key)))
+
+
;;; Helm-command-map
;;
;;
@@ -169,6 +187,12 @@
"----"
["Prefered Options" helm-configuration t]))
+;;;###autoload
+(defun helm-configuration ()
+ "Customize `helm'."
+ (interactive)
+ (customize-group "helm"))
+
;;; Helm map add ons
;;
View
45 helm-elisp.el
@@ -21,6 +21,51 @@
(require 'helm-utils)
(require 'advice)
+
+(defgroup helm-elisp nil
+ "Elisp related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-turn-on-show-completion t
+ "Display candidate in buffer while moving selection when non--nil."
+ :group 'helm-elisp
+ :type 'boolean)
+
+(defcustom helm-c-show-completion-use-special-display t
+ "A special display will be used in lisp completion if non--nil.
+All functions that are wrapped in macro `with-helm-show-completion'
+will be affected."
+ :group 'helm-elisp
+ :type 'boolean)
+
+(defcustom helm-c-show-completion-min-window-height 7
+ "Minimum completion window height used in show completion.
+This is used in macro `with-helm-show-completion'."
+ :group 'helm-elisp
+ :type 'integer)
+
+(defcustom helm-lisp-completion-or-indent-delay 0.6
+ "After this delay `helm-lisp-completion-counter' is reset to 0.
+This allow to indent again without completing lisp symbol after this delay.
+Default is 0.6 seconds."
+ :group 'helm-elisp
+ :type 'number)
+
+
+;;; Faces
+;;
+;;
+(defface helm-lisp-show-completion
+ '((t (:background "DarkSlateGray")))
+ "*Face used for showing candidates in `helm-lisp-completion'."
+ :group 'helm-elisp)
+
+(defface helm-lisp-completion-info
+ '((t (:foreground "red")))
+ "*Face used for showing info in `helm-lisp-completion'."
+ :group 'helm-elisp)
+
+
;;; Show completion.
;;
;; Provide show completion with macro `with-helm-show-completion'.
View
11 helm-emms.el
@@ -30,6 +30,17 @@
(declare-function emms-playlist-first "ext:emms")
(declare-function emms-playlist-mode-play-smart "ext:emms-playlist-mode")
+
+(defgroup helm-emms nil
+ "Predefined configurations for `helm.el'."
+ :group 'helm)
+
+(defface helm-emms-playlist
+ '((t (:foreground "Springgreen4" :underline t)))
+ "*Face used for tracks in current emms playlist."
+ :group 'helm-emms)
+
+
(defun helm-emms-stream-edit-bookmark (elm)
"Change the information of current emms-stream bookmark from helm."
(declare (special emms-stream-list))
View
18 helm-eval.el
@@ -19,6 +19,24 @@
(eval-when-compile (require 'cl))
(require 'helm)
+
+(defgroup helm-eval nil
+ "Eval related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-eldoc-in-minibuffer-show-fn
+ 'helm-c-show-info-in-mode-line
+ "A function to display eldoc info.
+Should take one arg: the string to display."
+ :group 'helm-eval
+ :type 'symbol)
+
+(defcustom helm-c-show-info-in-mode-line-delay 12
+ "Eldoc will show info in mode-line during this delay if user is idle."
+ :type 'integer
+ :group 'helm-eval)
+
+
(declare-function eldoc-current-symbol "eldoc")
(declare-function eldoc-get-fnsym-args-string "eldoc" (sym &optional index))
(declare-function eldoc-get-var-docstring "eldoc" (sym))
View
31 helm-external.el
@@ -20,6 +20,37 @@
(eval-when-compile (require 'cl))
(require 'helm)
+
+(defgroup helm-external nil
+ "External related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-raise-command nil
+ "A shell command to jump to a window running specific program.
+Need external program wmctrl.
+This will be use with `format', so use something like \"wmctrl -xa %s\"."
+ :type 'string
+ :group 'helm-external)
+
+(defcustom helm-c-external-programs-associations nil
+ "Alist to store externals programs associated with file extension.
+This variable overhide setting in .mailcap file.
+e.g : '\(\(\"jpg\" . \"gqview\"\) (\"pdf\" . \"xpdf\"\)\) "
+ :type 'list
+ :group 'helm-external)
+
+(defcustom helm-c-default-external-file-browser "nautilus"
+ "Default external file browser for your system.
+Directories will be opened externally with it when
+opening file externally in `helm-find-files'.
+Set to nil if you do not have external file browser
+or do not want to use it.
+Windows users should set that to \"explorer.exe\"."
+ :group 'helm-external
+ :type 'string)
+
+
+;;; Internals
(defvar helm-external-command-history nil)
(defvar helm-c-external-commands-list nil
"A list of all external commands the user can execute. If this
View
213 helm-files.el
@@ -40,6 +40,217 @@
(declare-function eshell-bol "esh-mode")
+(defgroup helm-files nil
+ "Files applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-boring-file-regexp
+ (rx (or
+ ;; Boring directories
+ (and "/" (or ".svn" "CVS" "_darcs" ".git" ".hg") (or "/" eol))
+ ;; Boring files
+ (and line-start ".#")
+ (and (or ".class" ".la" ".o" "~") eol)))
+ "The regexp that match boring files.
+File candidates matching this regular expression will be
+filtered from the list of candidates if the
+`helm-c-skip-boring-files' candidate transformer is used, or
+they will be displayed with face `file-name-shadow' if
+`helm-c-shadow-boring-files' is used."
+ :type 'string
+ :group 'helm-files)
+
+(defcustom helm-for-files-prefered-list
+ '(helm-c-source-ffap-line
+ helm-c-source-ffap-guesser
+ helm-c-source-buffers-list
+ helm-c-source-recentf
+ helm-c-source-bookmarks
+ helm-c-source-file-cache
+ helm-c-source-files-in-current-dir
+ helm-c-source-locate)
+ "Your prefered sources to find files."
+ :type 'list
+ :group 'helm-files)
+
+(defcustom helm-tramp-verbose 0
+ "Just like `tramp-verbose' but specific to helm.
+When set to 0 don't show tramp messages in helm.
+If you want to have the default tramp messages set it to 3."
+ :type 'integer
+ :group 'helm-files)
+
+(defcustom helm-ff-auto-update-initial-value t
+ "Auto update when only one candidate directory is matched.
+This is the default value when starting `helm-find-files'."
+ :group 'helm-files
+ :type 'boolean)
+
+(defcustom helm-c-copy-async-prefered-emacs "emacs"
+ "Path to the emacs you want to use for copying async.
+Emacs versions < 24 fail to copy directory due to a bug not fixed
+in `copy-directory'."
+ :group 'helm-files
+ :type 'string)
+
+(defcustom helm-ff-lynx-style-map t
+ "Use arrow keys to navigate with `helm-find-files'.
+You will have to restart Emacs or reeval `helm-find-files-map'
+and `helm-c-read-file-map' for this take effect."
+ :group 'helm-files
+ :type 'boolean)
+
+(defcustom helm-ff-history-max-length 100
+ "Number of elements shown in `helm-find-files' history."
+ :group 'helm-files
+ :type 'integer)
+
+(defcustom helm-ff-smart-completion t
+ "Try to complete filenames smarter when non--nil.
+See `helm-ff-transform-fname-for-completion' for more info."
+ :group 'helm-files
+ :type 'boolean)
+
+(defcustom helm-ff-tramp-not-fancy t
+ "No colors when listing remote files when set to non--nil.
+This make listing much faster, specially on slow machines."
+ :group 'helm-files
+ :type 'boolean)
+
+(defcustom helm-ff-exif-data-program "exiftran"
+ "Program used to extract exif data of an image file."
+ :group 'helm-files
+ :type 'string)
+
+(defcustom helm-ff-exif-data-program-args "-d"
+ "*Arguments used for `helm-ff-exif-data-program'."
+ :group 'helm-files
+ :type 'string)
+
+(defcustom helm-ff-newfile-prompt-p t
+ "Whether Prompt or not when creating new file.
+This set `ffap-newfile-prompt'."
+ :type 'boolean
+ :group 'helm-files)
+
+(defcustom helm-ff-avfs-directory nil
+ "The default avfs directory, usually '.avfs'.
+When this is set you will be able to expand archive filenames with `C-z'
+inside an avfs directory mounted with mountavfs.
+See <http://sourceforge.net/projects/avf/>."
+ :type 'boolean
+ :group 'helm-files)
+
+(defcustom helm-ff-file-compressed-list '("gz" "bz2" "zip" "7z")
+ "Minimal list of compressed files extension."
+ :type 'list
+ :group 'helm-files)
+
+(defcustom helm-c-copy-files-async-log-file "/tmp/dired.log"
+ "The file used to communicate with two emacs when copying files async."
+ :type 'string
+ :group 'helm-files)
+
+(defcustom helm-ff-printer-list nil
+ "A list of available printers on your system.
+When non--nil let you choose a printer to print file.
+Otherwise when nil the variable `printer-name' will be used.
+On Unix based systems (lpstat command needed) you don't need to set this,
+`helm-ff-find-printers' will find a list of available printers for you."
+ :type 'list
+ :group 'helm-files)
+
+(defcustom helm-ff-transformer-show-only-basename nil
+ "Show only basename of candidates in `helm-find-files'.
+This can be toggled at anytime from `helm-find-files' with \
+\\<helm-find-files-map>0\\[helm-ff-run-toggle-basename]."
+ :type 'boolean
+ :group 'helm-files)
+
+(defcustom helm-ff-quick-delete-dont-prompt-for-deletion nil
+ "Don't ask in persistent deletion of files when non--nil."
+ :group 'helm-files
+ :type 'boolean)
+
+(defcustom helm-ff-signal-error-on-dot-files t
+ "Signal error when file is `.' or `..' on file deletion when non--nil.
+Default is non--nil.
+WARNING: Setting this to nil is unsafe and can cause deletion of a whole tree."
+ :group 'helm-files
+ :type 'boolean)
+
+(defcustom helm-completing-read-handlers-alist
+ '((describe-function . helm-completing-read-symbols)
+ (describe-variable . helm-completing-read-symbols)
+ (debug-on-entry . helm-completing-read-symbols)
+ (find-function . helm-completing-read-symbols)
+ (trace-function . helm-completing-read-symbols)
+ (trace-function-background . helm-completing-read-symbols)
+ (find-tag . helm-completing-read-with-cands-in-buffer)
+ (ffap-alternate-file . nil))
+ "Alist of handlers to replace `completing-read', `read-file-name' in `helm-mode'.
+Each entry is a cons cell like \(emacs_command . completing-read_handler\)
+where key and value are symbols.
+
+Each key is an Emacs command that use originaly `completing-read'.
+
+Each value maybe an helm function that take same arguments as
+`completing-read' plus NAME and BUFFER, where NAME is the name of the new
+helm source and BUFFER the name of the buffer we will use.
+This function prefix name must start by \"helm\".
+
+See `helm-completing-read-symbols' for example.
+
+If the value of an entry is nil completion will fall back to
+emacs vanilla behavior.
+e.g If you want to disable helm completion for `describe-function':
+\(describe-function . nil\).
+
+Ido is also supported, you can use `ido-completing-read' and
+`ido-read-file-name' as value of an entry or just 'ido.
+e.g ido completion for `find-file':
+\(find-file . ido\)
+same as
+\(find-file . ido-read-file-name\)
+Note that you don't need to enable `ido-mode' for this to work."
+ :group 'helm-files
+ :type '(alist :key-type symbol :value-type symbol))
+
+
+;;; Faces
+;;
+;;
+(defface helm-ff-prefix
+ '((t (:background "yellow" :foreground "black")))
+ "*Face used to prefix new file or url paths in `helm-find-files'."
+ :group 'helm-files)
+
+(defface helm-ff-executable
+ '((t (:foreground "green")))
+ "*Face used for executable files in `helm-find-files'."
+ :group 'helm-files)
+
+(defface helm-ff-directory
+ '((t (:foreground "DarkRed" :background "LightGray")))
+ "*Face used for directories in `helm-find-files'."
+ :group 'helm-files)
+
+(defface helm-ff-symlink
+ '((t (:foreground "DarkOrange")))
+ "*Face used for symlinks in `helm-find-files'."
+ :group 'helm-files)
+
+(defface helm-ff-invalid-symlink
+ '((t (:foreground "black" :background "red")))
+ "*Face used for invalid symlinks in `helm-find-files'."
+ :group 'helm-files)
+
+(defface helm-ff-file
+ '((t (:foreground "CadetBlue" :underline t)))
+ "*Face used for file names in `helm-find-files'."
+ :group 'helm-files)
+
+
;;; Helm-find-files - The helm file browser.
;;
;;
@@ -1926,7 +2137,7 @@ members of FLIST."
"Enable helm completion in Dired functions.
Bindings affected are C, R, S, H.
This is deprecated for Emacs24+ users, use `helm-mode' instead."
- :group 'helm-config
+ :group 'helm-files
:global t
(if helm-dired-mode
(progn
View
11 helm-gentoo.el
@@ -24,6 +24,17 @@
(declare-function term-send-input "term")
(declare-function term-send-eof "term")
+
+(defgroup helm-gentoo nil
+ "Predefined configurations for `helm.el'."
+ :group 'helm)
+
+(defface helm-gentoo-match-face '((t (:foreground "red")))
+ "Face for helm-gentoo installed packages."
+ :group 'traverse-faces)
+
+
+;;; Internals
(defvar helm-c-gentoo-use-flags nil)
(defvar helm-c-gentoo-buffer "*helm-gentoo-output*")
(defvar helm-c-cache-gentoo nil)
View
46 helm-grep.el
@@ -24,6 +24,52 @@
(declare-function helm-elscreen-find-file "helm-elscreen" (file))
+
+(defgroup helm-grep nil
+ "Grep related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-grep-use-ioccur-style-keys t
+ "Use Arrow keys to jump to occurences."
+ :group 'helm-grep
+ :type 'boolean)
+
+(defcustom helm-c-pdfgrep-default-read-command "xpdf '%f' %p"
+ "Default command to read pdf files from pdfgrep.
+Where '%f' format spec is filename and '%p' is page number"
+ :group 'helm-grep
+ :type 'string)
+
+
+;;; Faces
+;;
+;;
+(defface helm-grep-match
+ '((t (:inherit match)))
+ "Face used to highlight grep matches."
+ :group 'helm-grep)
+
+(defface helm-grep-file
+ '((t (:foreground "BlueViolet" :underline t)))
+ "Face used to highlight grep results filenames."
+ :group 'helm-grep)
+
+(defface helm-grep-lineno
+ '((t (:foreground "Darkorange1")))
+ "Face used to highlight grep number lines."
+ :group 'helm-grep)
+
+(defface helm-grep-running
+ '((t (:foreground "Red")))
+ "Face used in mode line when grep is running."
+ :group 'helm-grep)
+
+(defface helm-grep-finish
+ '((t (:foreground "Green")))
+ "Face used in mode line when grep is finish."
+ :group 'helm-grep)
+
+
(defvar helm-c-grep-map
(let ((map (make-sparse-keymap)))
(set-keymap-parent map helm-map)
View
59 helm-info.el
@@ -20,13 +20,70 @@
(eval-when-compile (require 'cl))
(require 'helm)
(require 'helm-plugin)
-(require 'helm-vars)
(require 'helm-net)
(declare-function Info-index-nodes "info" (&optional file))
(declare-function Info-goto-node "info" (&optional fork))
(declare-function Info-find-node "info.el" (filename nodename &optional no-going-back))
+
+(defgroup helm-info nil
+ "Info related Applications and libraries for Helm."
+ :group 'helm)
+
+;;; Build info-index sources with info-index plug-in.
+;;
+;;
+(defun helm-c-build-info-index-command (name doc source buffer)
+ "Define an helm command NAME with documentation DOC.
+Arg SOURCE will be an existing helm source named
+`helm-c-source-info-<NAME>' and BUFFER a string buffer name."
+ (eval (list 'defun name nil doc
+ (list 'interactive)
+ (list 'helm
+ :sources source
+ :buffer buffer
+ :candidate-number-limit 1000))))
+
+(defun helm-c-define-info-index-sources (var-value &optional commands)
+ "Define helm sources named helm-c-source-info-<NAME>.
+Sources are generated for all entries of `helm-c-default-info-index-list'.
+If COMMANDS arg is non--nil build also commands named `helm-info<NAME>'.
+Where NAME is one of `helm-c-default-info-index-list'."
+ (loop with symbols = (loop for str in var-value
+ collect
+ (intern (concat "helm-c-source-info-" str)))
+ for sym in symbols
+ for str in var-value
+ do (set sym (list (cons 'name (format "Info index: %s" str))
+ (cons 'info-index str)))
+ when commands
+ do (let ((com (intern (concat "helm-info-" str))))
+ (helm-c-build-info-index-command
+ com (format "Predefined helm for %s info." str)
+ sym (format "*helm info %s*" str)))))
+
+(defun helm-info-index-set (var value)
+ (set var value)
+ (helm-c-define-info-index-sources value t))
+
+(defcustom helm-c-default-info-index-list
+ '("elisp" "cl" "org" "gnus" "tramp" "ratpoison"
+ "zsh" "bash" "coreutils" "fileutils"
+ "find" "sh-utils" "textutils" "libc"
+ "make" "automake" "autoconf" "emacs-lisp-intro"
+ "emacs" "elib" "eieio" "gauche-refe" "guile"
+ "guile-tut" "goops" "screen" "latex" "gawk"
+ "sed" "m4" "wget" "binutils" "as" "bfd" "gprof"
+ "ld" "diff" "flex" "grep" "gzip" "libtool"
+ "texinfo" "info" "gdb" "stabs" "cvsbook" "cvs"
+ "bison" "id-utils" "global")
+ "Info Manual entries to use for building helm info index commands."
+ :group 'helm-info
+ :type 'list
+ :set 'helm-info-index-set)
+
+
;;; Info pages
(defvar helm-c-info-pages nil
"All info pages on system.
View
36 helm-locate.el
@@ -25,6 +25,42 @@
(require 'helm)
(require 'helm-files)
+
+(defgroup helm-locate nil
+ "Locate related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-locate-db-file-regexp "m?locate\.db$"
+ "Default regexp to match locate database.
+If nil Search in all files."
+ :type 'string
+ :group 'helm-locate)
+
+(defcustom helm-ff-locate-db-filename "locate.db"
+ "The basename of the locatedb file you use locally in your directories.
+When this is set and `helm' find such a file in the directory from
+where you launch locate, it will use this file and will not prompt you
+for a db file.
+Note that this happen only when locate is launched with a prefix arg."
+ :group 'helm-locate
+ :type 'string)
+
+(defcustom helm-c-locate-command nil
+ "A list of arguments for locate program.
+If nil it will be calculated when `helm-locate' startup
+with these default values for different systems:
+
+Gnu/linux: \"locate -i -r %s\"
+berkeley-unix: \"locate -i %s\"
+windows-nt: \"es -i -r %s\"
+Others: \"locate %s\"
+
+This string will be passed to format so it should end with `%s'.
+The \"-r\" option must be the last option."
+ :type 'string
+ :group 'helm-locate)
+
+
(defun helm-ff-find-locatedb (&optional from-ff)
"Try to find if a local locatedb file is available.
The search is done in `helm-ff-default-directory' or
View
29 helm-misc.el
@@ -19,8 +19,35 @@
(eval-when-compile (require 'cl))
(require 'helm)
+
+(defgroup helm-misc nil
+ "Various Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-minibuffer-history-key "C-r"
+ "The key `helm-minibuffer-history' is bound to in minibuffer local maps."
+ :type '(choice (string :tag "Key") (const :tag "no binding"))
+ :group 'helm-config
+ :set
+ (lambda (var key)
+ (dolist (map '(minibuffer-local-completion-map
+ minibuffer-local-filename-completion-map
+ minibuffer-local-filename-must-match-map ; Emacs 23.1.+
+ minibuffer-local-isearch-map
+ minibuffer-local-map
+ minibuffer-local-must-match-filename-map ; Older Emacsen
+ minibuffer-local-must-match-map
+ minibuffer-local-ns-map))
+ (when (and (boundp map) (keymapp (symbol-value map)))
+ (when (and (boundp var) (symbol-value var))
+ (define-key (symbol-value map)
+ (read-kbd-macro (symbol-value var)) nil))
+ (when key
+ (define-key (symbol-value map)
+ (read-kbd-macro key) 'helm-minibuffer-history))))
+ (set var key)))
-;;;; <Search Engine>
+
;;; Tracker desktop search
(defvar helm-c-source-tracker-search
'((name . "Tracker Search")
View
65 helm-net.el
@@ -21,6 +21,59 @@
(require 'helm)
(require 'url)
(require 'xml)
+(require 'browse-url)
+
+(defgroup helm-net nil
+ "Net related applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-google-suggest-default-browser-function nil
+ "The browse url function you prefer to use with google suggest.
+When nil, use the first browser function available
+See `helm-browse-url-default-browser-alist'."
+ :group 'helm-net
+ :type 'symbol)
+
+(defcustom helm-c-home-url "http://www.google.fr"
+ "Default url to use as home url."
+ :group 'helm-net
+ :type 'string)
+
+(defcustom helm-surfraw-default-browser-function nil
+ "The browse url function you prefer to use with surfraw.
+When nil, fallback to `browse-url-browser-function'."
+ :group 'helm-net
+ :type 'symbol)
+
+(defcustom helm-c-google-suggest-url
+ "http://google.com/complete/search?output=toolbar&q="
+ "URL used for looking up Google suggestions."
+ :type 'string
+ :group 'helm-net)
+
+(defcustom helm-c-google-suggest-search-url
+ "http://www.google.com/search?ie=utf-8&oe=utf-8&q="
+ "URL used for Google searching."
+ :type 'string
+ :group 'helm-net)
+
+(defcustom helm-google-suggest-use-curl-p nil
+ "When non--nil use CURL to get info from `helm-c-google-suggest-url'.
+Otherwise `url-retrieve-synchronously' is used."
+ :type 'boolean
+ :group 'helm-net)
+
+(defcustom helm-c-yahoo-suggest-url
+ "http://search.yahooapis.com/WebSearchService/V1/relatedSuggestion?appid=Generic&query="
+ "Url used for looking up Yahoo suggestions."
+ :type 'string
+ :group 'helm-net)
+
+(defcustom helm-c-yahoo-suggest-search-url
+ "http://search.yahoo.com/search?&ei=UTF-8&fr&h=c&p="
+ "Url used for Yahoo searching."
+ :type 'string
+ :group 'helm-net)
;;; Google Suggestions
@@ -121,11 +174,6 @@ Return an alist with elements like (data . number_results)."
"^," "" (mapconcat 'identity (reverse C) ""))))
"?"))
-(defvar helm-c-google-suggest-default-browser-function nil
- "*The browse url function you prefer to use with google suggest.
-When nil, use the first browser function available
-See `helm-browse-url-default-browser-alist'.")
-
(defun helm-c-google-suggest-action (candidate)
"Default action to jump to a google suggested candidate."
(let ((arg (concat helm-c-google-suggest-search-url
@@ -198,13 +246,10 @@ Return an alist with elements like (data . number_results)."
;;; Web browser functions.
;;
;;
-(require 'browse-url)
;; If default setting of `w3m-command' is not
;; what you want you and you modify it, you will have to reeval
;; also `helm-browse-url-default-browser-alist'.
(defvar w3m-command "/usr/bin/w3m")
-(defvar helm-c-home-url "http://www.google.fr"
- "*Default url to use as home url.")
(defvar helm-browse-url-chromium-program "chromium-browser")
(defvar helm-browse-url-uzbl-program "uzbl-browser")
@@ -266,10 +311,6 @@ Return an alist with elements like (data . number_results)."
;; Need external program surfraw.
;; <http://surfraw.alioth.debian.org/>
-(defvar helm-surfraw-default-browser-function nil
- "*The browse url function you prefer to use with surfraw.
-When nil, fallback to `browse-url-browser-function'.")
-
;; Internal
(defvar helm-surfraw-engines-history nil)
(defvar helm-surfraw-input-history nil)
View
30 helm-regexp.el
@@ -19,7 +19,37 @@
(require 'cl)
(require 'helm)
+(require 'helm-utils)
+
+(defgroup helm-regexp nil
+ "Regexp related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-browse-code-regexp-lisp
+ "^ *\(def\\(un\\|subst\\|macro\\|face\\|alias\\|advice\\|struct\\|\
+type\\|theme\\|var\\|group\\|custom\\|const\\|method\\|class\\)"
+ "Regexp used to parse lisp buffer when browsing code."
+ :type 'string
+ :group 'helm-regexp)
+
+(defcustom helm-c-browse-code-regexp-python
+ "\\<def\\>\\|\\<class\\>"
+ "Regexp used to parse python buffer when browsing code."
+ :type 'string
+ :group 'helm-regexp)
+
+(defcustom helm-c-browse-code-regexp-alist
+ `((lisp-interaction-mode . ,helm-c-browse-code-regexp-lisp)
+ (emacs-lisp-mode . ,helm-c-browse-code-regexp-lisp)
+ (lisp-mode . ,helm-c-browse-code-regexp-lisp)
+ (python-mode . ,helm-c-browse-code-regexp-python))
+ "Alist to store regexps for browsing code corresponding \
+to a specific `major-mode'."
+ :type 'list
+ :group 'helm-regexp)
+
+
(defvar helm-occur-map
(let ((map (make-sparse-keymap)))
(set-keymap-parent map helm-map)
View
23 helm-ring.el
@@ -19,9 +19,32 @@
(eval-when-compile (require 'cl))
(require 'helm)
+(require 'helm-utils)
(declare-function undo-tree-restore-state-from-register "ext:undo-tree.el" (register))
+
+(defgroup helm-ring nil
+ "Ring related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-kill-ring-threshold 10
+ "Minimum length to be listed by `helm-c-source-kill-ring'."
+ :type 'integer
+ :group 'helm-ring)
+
+(defcustom helm-c-kill-ring-max-lines-number nil
+ "Max number of lines displayed per candidate in kill-ring browser.
+If nil or zero, don't truncate candidate, show all."
+ :type 'integer
+ :group 'helm-ring)
+
+(defcustom helm-c-register-max-offset 160
+ "Max size of string register entries before truncating."
+ :group 'helm-ring
+ :type 'integer)
+
+
;;; Kill ring
;;
;;
View
34 helm-tags.el
@@ -20,6 +20,40 @@
(eval-when-compile (require 'cl))
(require 'helm)
+
+(defgroup helm-tags nil
+ "Tags related Applications and libraries for Helm."
+ :group 'helm)
+
+(defcustom helm-c-etags-tag-file-name "TAGS"
+ "Etags tag file name."
+ :type 'string
+ :group 'helm-tags)
+
+(defcustom helm-c-etags-tag-file-search-limit 10
+ "The limit level of directory to search tag file.
+Don't search tag file deeply if outside this value."
+ :type 'number
+ :group 'helm-tags)
+
+(defcustom helm-c-etags-use-regexp-search nil
+ "When non--nil search etags candidates by regexp.
+This disable helm-match-plugin when enabled.
+When nil search is performed directly on patter and *match-plugin is used
+if available. You can customize `helm-c-etags-search-regexp'."
+ :group 'helm-tags
+ :type 'boolean)
+
+(defcustom helm-c-etags-search-regexp "^.+: .+ \\<%s"
+ "Regexp that match tags in an helm etags buffer.
+The format spec is replaced by pattern.
+This regexp have no effect when `helm-c-etags-use-regexp-search'
+is nil."
+ :group 'helm-tags
+ :type 'regexp)
+
+
+
(defvar helm-c-etags-map
(let ((map (make-sparse-keymap)))
(set-keymap-parent map helm-map)
View
29 helm-utils.el
@@ -24,6 +24,29 @@
+(defgroup helm-utils nil
+ "Utilities routines for Helm."
+ :group 'helm)
+
+(defcustom helm-su-or-sudo "sudo"
+ "What command to use for root access."
+ :type 'string
+ :group 'helm-utils)
+
+(defcustom helm-c-enable-eval-defun-hack t
+ "If non-nil, execute `helm' using the source at point when C-M-x is pressed.
+This hack is invoked when pressing C-M-x in the form \
+ (defvar helm-c-source-XXX ...) or (setq helm-c-source-XXX ...)."
+ :type 'boolean
+ :group 'helm-utils)
+
+(defcustom helm-default-kbsize 1024.0
+ "Default Kbsize to use for showing files size.
+It is a float, usually 1024.0 but could be 1000.0 on some systems."
+ :group 'helm-utils
+ :type 'float)
+
+
;;; compatibility
;;
;;
@@ -326,9 +349,9 @@ If specified, also remove filename extension EXT."
SIZE can be an integer or a float depending it's value.
`file-attributes' will take care of that to avoid overflow error.
KBSIZE if a floating point number, default value is 1024.0."
- (let ((M (cons "M" (/ size (expt helm-ff-default-kbsize 2))))
- (G (cons "G" (/ size (expt helm-ff-default-kbsize 3))))
- (K (cons "K" (/ size helm-ff-default-kbsize)))
+ (let ((M (cons "M" (/ size (expt helm-default-kbsize 2))))
+ (G (cons "G" (/ size (expt helm-default-kbsize 3))))
+ (K (cons "K" (/ size helm-default-kbsize)))
(B (cons "B" size)))
(loop with result = B
for (a . b) in
View
684 helm-vars.el
@@ -20,691 +20,7 @@
;;; Customize
;;
;;
-(defgroup helm-config nil
- "Predefined configurations for `helm.el'."
- :group 'helm)
-(defcustom helm-c-adaptive-history-file
- "~/.emacs.d/helm-c-adaptive-history"
- "Path of file where history information is stored."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-adaptive-history-length 50
- "Maximum number of candidates stored for a source."
- :type 'number
- :group 'helm-config)
-
-(defcustom helm-c-google-suggest-url
- "http://google.com/complete/search?output=toolbar&q="
- "URL used for looking up Google suggestions."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-google-suggest-search-url
- "http://www.google.com/search?ie=utf-8&oe=utf-8&q="
- "URL used for Google searching."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-google-suggest-use-curl-p nil
- "When non--nil use CURL to get info from `helm-c-google-suggest-url'.
-Otherwise `url-retrieve-synchronously' is used."
- :type 'boolean
- :group 'helm-config)
-
-(defcustom helm-c-yahoo-suggest-url
- "http://search.yahooapis.com/WebSearchService/V1/relatedSuggestion?appid=Generic&query="
- "Url used for looking up Yahoo suggestions."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-yahoo-suggest-search-url
- "http://search.yahoo.com/search?&ei=UTF-8&fr&h=c&p="
- "Url used for Yahoo searching."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-boring-buffer-regexp
- (rx (or
- (group bos " ")
- ;; helm-buffers
- "*helm" "*helm-mode"
- ;; echo area
- " *Echo Area" " *Minibuf"))
- "The regexp that match boring buffers.
-Buffer candidates matching this regular expression will be
-filtered from the list of candidates if the
-`helm-c-skip-boring-buffers' candidate transformer is used, or
-they will be displayed with face `file-name-shadow' if
-`helm-c-shadow-boring-buffers' is used."
- :type 'string
- :group 'helm-config)
-;; (string-match helm-c-boring-buffer-regexp "buf")
-;; (string-match helm-c-boring-buffer-regexp " hidden")
-;; (string-match helm-c-boring-buffer-regexp " *Minibuf-1*")
-
-(defcustom helm-c-boring-file-regexp
- (rx (or
- ;; Boring directories
- (and "/" (or ".svn" "CVS" "_darcs" ".git" ".hg") (or "/" eol))
- ;; Boring files
- (and line-start ".#")
- (and (or ".class" ".la" ".o" "~") eol)))
- "The regexp that match boring files.
-File candidates matching this regular expression will be
-filtered from the list of candidates if the
-`helm-c-skip-boring-files' candidate transformer is used, or
-they will be displayed with face `file-name-shadow' if
-`helm-c-shadow-boring-files' is used."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-kill-ring-threshold 10
- "Minimum length to be listed by `helm-c-source-kill-ring'."
- :type 'integer
- :group 'helm-config)
-
-(defcustom helm-c-kill-ring-max-lines-number nil
- "Max number of lines displayed per candidate in kill-ring browser.
-If nil or zero, don't truncate candidate, show all."
- :type 'integer
- :group 'helm-config)
-
-(defcustom helm-su-or-sudo "su"
- "What command to use for root access."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-for-files-prefered-list
- '(helm-c-source-ffap-line
- helm-c-source-ffap-guesser
- helm-c-source-buffers-list
- helm-c-source-recentf
- helm-c-source-bookmarks
- helm-c-source-file-cache
- helm-c-source-files-in-current-dir
- helm-c-source-locate)
- "Your prefered sources to find files."
- :type 'list
- :group 'helm-config)
-
-(defcustom helm-create--actions-private nil
- "User defined actions for `helm-create' / `helm-c-source-create'.
-It is a list of (DISPLAY . FUNCTION) pairs like `action'
-attribute of `helm-sources'.
-
-It is prepended to predefined pairs."
- :type 'list
- :group 'helm-config)
-
-(defcustom helm-allow-skipping-current-buffer nil
- "Show current buffer or not in helm buffer"
- :type 'boolean
- :group 'helm-config)
-
-(defcustom helm-c-enable-eval-defun-hack t
- "If non-nil, execute `helm' using the source at point when C-M-x is pressed.
-This hack is invoked when pressing C-M-x in the form \
- (defvar helm-c-source-XXX ...) or (setq helm-c-source-XXX ...)."
- :type 'boolean
- :group 'helm-config)
-
-(defcustom helm-tramp-verbose 0
- "Just like `tramp-verbose' but specific to helm.
-When set to 0 don't show tramp messages in helm.
-If you want to have the default tramp messages set it to 3."
- :type 'integer
- :group 'helm-config)
-
-(defcustom helm-raise-command nil
- "A shell command to jump to a window running specific program.
-Need external program wmctrl.
-This will be use with `format', so use something like \"wmctrl -xa %s\"."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-command-prefix-key "C-x c"
- "The key `helm-command-prefix' is bound to in the global map."
- :type '(choice (string :tag "Key") (const :tag "no binding"))
- :group 'helm-config
- :set
- (lambda (var key)
- (when (and (boundp var) (symbol-value var))
- (define-key (current-global-map)
- (read-kbd-macro (symbol-value var)) nil))
- (when key
- (define-key (current-global-map)
- (read-kbd-macro key) 'helm-command-prefix))
- (set var key)))
-
-(defcustom helm-minibuffer-history-key "C-r"
- "The key `helm-minibuffer-history' is bound to in minibuffer local maps."
- :type '(choice (string :tag "Key") (const :tag "no binding"))
- :group 'helm-config
- :set
- (lambda (var key)
- (dolist (map '(minibuffer-local-completion-map
- minibuffer-local-filename-completion-map
- minibuffer-local-filename-must-match-map ; Emacs 23.1.+
- minibuffer-local-isearch-map
- minibuffer-local-map
- minibuffer-local-must-match-filename-map ; Older Emacsen
- minibuffer-local-must-match-map
- minibuffer-local-ns-map))
- (when (and (boundp map) (keymapp (symbol-value map)))
- (when (and (boundp var) (symbol-value var))
- (define-key (symbol-value map)
- (read-kbd-macro (symbol-value var)) nil))
- (when key
- (define-key (symbol-value map)
- (read-kbd-macro key) 'helm-minibuffer-history))))
- (set var key)))
-
-(defcustom helm-c-browse-code-regexp-lisp
- "^ *\(def\\(un\\|subst\\|macro\\|face\\|alias\\|advice\\|struct\\|\
-type\\|theme\\|var\\|group\\|custom\\|const\\|method\\|class\\)"
- "Regexp used to parse lisp buffer when browsing code."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-browse-code-regexp-python
- "\\<def\\>\\|\\<class\\>"
- "Regexp used to parse python buffer when browsing code."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-browse-code-regexp-alist
- `((lisp-interaction-mode . ,helm-c-browse-code-regexp-lisp)
- (emacs-lisp-mode . ,helm-c-browse-code-regexp-lisp)
- (lisp-mode . ,helm-c-browse-code-regexp-lisp)
- (python-mode . ,helm-c-browse-code-regexp-python))
- "Alist to store regexps for browsing code corresponding \
-to a specific `major-mode'."
- :type 'list
- :group 'helm-config)
-
-(defcustom helm-c-external-programs-associations nil
- "Alist to store externals programs associated with file extension.
-This variable overhide setting in .mailcap file.
-e.g : '\(\(\"jpg\" . \"gqview\"\) (\"pdf\" . \"xpdf\"\)\) "
- :type 'list
- :group 'helm-config)
-
-(defcustom helm-ff-auto-update-initial-value t
- "Auto update when only one candidate directory is matched.
-This is the default value when starting `helm-find-files'."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-c-copy-async-prefered-emacs "emacs"
- "Path to the emacs you want to use for copying async.
-Emacs versions < 24 fail to copy directory due to a bug not fixed
-in `copy-directory'."
- :group 'helm-config
- :type 'string)
-
-(defcustom helm-ff-lynx-style-map t
- "Use arrow keys to navigate with `helm-find-files'.
-You will have to restart Emacs or reeval `helm-find-files-map'
-and `helm-c-read-file-map' for this take effect."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-ff-history-max-length 100
- "Number of elements shown in `helm-find-files' history."
- :group 'helm-config
- :type 'integer)
-
-(defcustom helm-ff-smart-completion t
- "Try to complete filenames smarter when non--nil.
-See `helm-ff-transform-fname-for-completion' for more info."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-ff-default-kbsize 1024.0
- "Default Kbsize to use for showing files size.
-It is a float, usually 1024.0 but could be 1000.0 on some systems."
- :group 'helm-config
- :type 'float)
-
-(defcustom helm-ff-tramp-not-fancy t
- "No colors when listing remote files when set to non--nil.
-This make listing much faster, specially on slow machines."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-ff-exif-data-program "exiftran"
- "Program used to extract exif data of an image file."
- :group 'helm-config
- :type 'string)
-
-(defcustom helm-ff-exif-data-program-args "-d"
- "*Arguments used for `helm-ff-exif-data-program'."
- :group 'helm-config
- :type 'string)
-
-(defcustom helm-c-grep-use-ioccur-style-keys t
- "Use Arrow keys to jump to occurences."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-c-pdfgrep-default-read-command "xpdf '%f' %p"
- "Default command to read pdf files from pdfgrep.
-Where '%f' format spec is filename and '%p' is page number"
- :group 'helm-config
- :type 'string)
-
-(defcustom helm-c-etags-tag-file-name "TAGS"
- "Etags tag file name."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-etags-tag-file-search-limit 10
- "The limit level of directory to search tag file.
-Don't search tag file deeply if outside this value."
- :type 'number
- :group 'helm-config)
-
-(defcustom helm-c-etags-use-regexp-search nil
- "When non--nil search etags candidates by regexp.
-This disable helm-match-plugin when enabled.
-When nil search is performed directly on patter and *match-plugin is used
-if available. You can customize `helm-c-etags-search-regexp'."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-c-etags-search-regexp "^.+: .+ \\<%s"
- "Regexp that match tags in an helm etags buffer.
-The format spec is replaced by pattern.
-This regexp have no effect when `helm-c-etags-use-regexp-search'
-is nil."
- :group 'helm-config
- :type 'regexp)
-
-(defcustom helm-c-eldoc-in-minibuffer-show-fn
- 'helm-c-show-info-in-mode-line
- "A function to display eldoc info.
-Should take one arg: the string to display."
- :group 'helm-config
- :type 'symbol)
-
-(defcustom helm-c-turn-on-show-completion t
- "Display candidate in buffer while moving selection when non--nil."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-c-show-completion-use-special-display t
- "A special display will be used in lisp completion if non--nil.
-All functions that are wrapped in macro `with-helm-show-completion'
-will be affected."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-c-show-completion-min-window-height 7
- "Minimum completion window height used in show completion.
-This is used in macro `with-helm-show-completion'."
- :group 'helm-config
- :type 'integer)
-
-(defcustom helm-lisp-completion-or-indent-delay 0.6
- "After this delay `helm-lisp-completion-counter' is reset to 0.
-This allow to indent again without completing lisp symbol after this delay.
-Default is 0.6 seconds."
- :group 'helm-config
- :type 'number)
-
-(defcustom helm-c-default-external-file-browser "nautilus"
- "Default external file browser for your system.
-Directories will be opened externally with it when
-opening file externally in `helm-find-files'.
-Set to nil if you do not have external file browser
-or do not want to use it.
-Windows users should set that to \"explorer.exe\"."
- :group 'helm-config
- :type 'string)
-
-(defcustom helm-c-use-adaptative-sorting nil
- "Wheter to use or not adaptative sorting.
-Even if a source use it, it will have no effect when set to nil."
- :type 'boolean
- :group 'helm-config)
-
-(defcustom helm-ff-newfile-prompt-p t
- "Whether Prompt or not when creating new file.
-This set `ffap-newfile-prompt'."
- :type 'boolean
- :group 'helm-config)
-
-
-(defcustom helm-ff-avfs-directory nil
- "The default avfs directory, usually '.avfs'.
-When this is set you will be able to expand archive filenames with `C-z'
-inside an avfs directory mounted with mountavfs.
-See <http://sourceforge.net/projects/avf/>."
- :type 'boolean
- :group 'helm-config)
-
-(defcustom helm-ff-file-compressed-list '("gz" "bz2" "zip" "7z")
- "Minimal list of compressed files extension."
- :type 'list
- :group 'helm-config)
-
-(defcustom helm-locate-db-file-regexp "m?locate\.db$"
- "Default regexp to match locate database.
-If nil Search in all files."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-ff-locate-db-filename "locate.db"
- "The basename of the locatedb file you use locally in your directories.
-When this is set and `helm' find such a file in the directory from
-where you launch locate, it will use this file and will not prompt you
-for a db file.
-Note that this happen only when locate is launched with a prefix arg."
- :group 'helm-config
- :type 'string)
-
-(defcustom helm-c-locate-command nil
- "A list of arguments for locate program.
-If nil it will be calculated when `helm-locate' startup
-with these default values for different systems:
-
-Gnu/linux: \"locate -i -r %s\"
-berkeley-unix: \"locate -i %s\"
-windows-nt: \"es -i -r %s\"
-Others: \"locate %s\"
-
-This string will be passed to format so it should end with `%s'.
-The \"-r\" option must be the last option."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-c-show-info-in-mode-line-delay 12
- "Eldoc will show info in mode-line during this delay if user is idle."
- :type 'integer
- :group 'helm-config)
-
-(defcustom helm-c-copy-files-async-log-file "/tmp/dired.log"
- "The file used to communicate with two emacs when copying files async."
- :type 'string
- :group 'helm-config)
-
-(defcustom helm-ff-printer-list nil
- "A list of available printers on your system.
-When non--nil let you choose a printer to print file.
-Otherwise when nil the variable `printer-name' will be used.
-On Unix based systems (lpstat command needed) you don't need to set this,
-`helm-ff-find-printers' will find a list of available printers for you."
- :type 'list
- :group 'helm-config)
-
-(defcustom helm-ff-transformer-show-only-basename nil
- "Show only basename of candidates in `helm-find-files'.
-This can be toggled at anytime from `helm-find-files' with \
-\\<helm-find-files-map>0\\[helm-ff-run-toggle-basename]."
- :type 'boolean
- :group 'helm-config)
-
-(defcustom helm-ff-quick-delete-dont-prompt-for-deletion nil
- "Don't ask in persistent deletion of files when non--nil."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-ff-signal-error-on-dot-files t
- "Signal error when file is `.' or `..' on file deletion when non--nil.
-Default is non--nil.
-WARNING: Setting this to nil is unsafe and can cause deletion of a whole tree."
- :group 'helm-config
- :type 'boolean)
-
-(defcustom helm-completing-read-handlers-alist
- '((describe-function . helm-completing-read-symbols)
- (describe-variable . helm-completing-read-symbols)
- (debug-on-entry . helm-completing-read-symbols)
- (find-function . helm-completing-read-symbols)
- (trace-function . helm-completing-read-symbols)
- (trace-function-background . helm-completing-read-symbols)
- (find-tag . helm-completing-read-with-cands-in-buffer)
- (ffap-alternate-file . nil))
- "Alist of handlers to replace `completing-read', `read-file-name' in `helm-mode'.
-Each entry is a cons cell like \(emacs_command . completing-read_handler\)
-where key and value are symbols.
-
-Each key is an Emacs command that use originaly `completing-read'.
-
-Each value maybe an helm function that take same arguments as
-`completing-read' plus NAME and BUFFER, where NAME is the name of the new
-helm source and BUFFER the name of the buffer we will use.
-This function prefix name must start by \"helm\".
-
-See `helm-completing-read-symbols' for example.
-
-If the value of an entry is nil completion will fall back to
-emacs vanilla behavior.
-e.g If you want to disable helm completion for `describe-function':
-\(describe-function . nil\).
-
-Ido is also supported, you can use `ido-completing-read' and
-`ido-read-file-name' as value of an entry or just 'ido.
-e.g ido completion for `find-file':
-\(find-file . ido\)
-same as
-\(find-file . ido-read-file-name\)
-Note that you don't need to enable `ido-mode' for this to work."
- :group 'helm-config
- :type '(alist :key-type symbol :value-type symbol))
-
-(defcustom helm-M-x-requires-pattern 2
- "Value of requires-pattern for `helm-M-x'.
-Set it to 0 to disable requires-pattern in `helm-M-x'."
- :group 'helm-config
- :type 'boolean)
-
-;;; Build info-index sources with info-index plug-in.
-;;
-;;
-(defun helm-c-build-info-index-command (name doc source buffer)
- "Define an helm command NAME with documentation DOC.
-Arg SOURCE will be an existing helm source named
-`helm-c-source-info-<NAME>' and BUFFER a string buffer name."
- (eval (list 'defun name nil doc
- (list 'interactive)
- (list 'helm
- :sources source
- :buffer buffer
- :candidate-number-limit 1000))))
-
-(defun helm-c-define-info-index-sources (var-value &optional commands)
- "Define helm sources named helm-c-source-info-<NAME>.
-Sources are generated for all entries of `helm-c-default-info-index-list'.
-If COMMANDS arg is non--nil build also commands named `helm-info<NAME>'.
-Where NAME is one of `helm-c-default-info-index-list'."
- (loop with symbols = (loop for str in var-value
- collect
- (intern (concat "helm-c-source-info-" str)))
- for sym in symbols
- for str in var-value
- do (set sym (list (cons 'name (format "Info index: %s" str))
- (cons 'info-index str)))
- when commands
- do (let ((com (intern (concat "helm-info-" str))))
- (helm-c-build-info-index-command
- com (format "Predefined helm for %s info." str)
- sym (format "*helm info %s*" str)))))
-
-(defun helm-info-index-set (var value)
- (set var value)
- (helm-c-define-info-index-sources value t))
-
-(defcustom helm-c-default-info-index-list
- '("elisp" "cl" "org" "gnus" "tramp" "ratpoison"
- "zsh" "bash" "coreutils" "fileutils"
- "find" "sh-utils" "textutils" "libc"
- "make" "automake" "autoconf" "emacs-lisp-intro"
- "emacs" "elib" "eieio" "gauche-refe" "guile"
- "guile-tut" "goops" "screen" "latex" "gawk"
- "sed" "m4" "wget" "binutils" "as" "bfd" "gprof"
- "ld" "diff" "flex" "grep" "gzip" "libtool"
- "texinfo" "info" "gdb" "stabs" "cvsbook" "cvs"
- "bison" "id-utils" "global")
- "Info Manual entries to use for building helm info index commands."
- :group 'helm-config
- :type 'list
- :set 'helm-info-index-set)
-
-(defcustom helm-c-register-max-offset 160
- "Max size of string register entries before truncating."
- :group 'helm-config
- :type 'integer)
-
-
-;;; Faces
-;;
-;;
-(defface helm-buffer-saved-out
- '((t (:foreground "red")))
- "*Face used for buffer files modified outside of emacs."
- :group 'helm-config)
-
-(defface helm-buffer-not-saved
- '((t (:foreground "Indianred2")))
- "*Face used for buffer files not already saved on disk."
- :group 'helm-config)
-
-(defface helm-ff-prefix
- '((t (:background "yellow" :foreground "black")))
- "*Face used to prefix new file or url paths in `helm-find-files'."
- :group 'helm-config)
-
-(defface helm-ff-executable
- '((t (:foreground "green")))
- "*Face used for executable files in `helm-find-files'."
- :group 'helm-config)
-
-(defface helm-ff-directory
- '((t (:foreground "DarkRed" :background "LightGray")))
- "*Face used for directories in `helm-find-files'."
- :group 'helm-config)
-
-(defface helm-ff-symlink
- '((t (:foreground "DarkOrange")))
- "*Face used for symlinks in `helm-find-files'."
- :group 'helm-config)
-
-(defface helm-ff-invalid-symlink
- '((t (:foreground "black" :background "red")))
- "*Face used for invalid symlinks in `helm-find-files'."
- :group 'helm-config)
-
-(defface helm-ff-file
- '((t (:foreground "CadetBlue" :underline t)))
- "*Face used for file names in `helm-find-files'."
- :group 'helm-config)
-
-(defface helm-grep-match
- '((t (:inherit match)))
- "Face used to highlight grep matches."
- :group 'helm-config)
-
-(defface helm-grep-file
- '((t (:foreground "BlueViolet" :underline t)))
- "Face used to highlight grep results filenames."
- :group 'helm-config)
-
-(defface helm-grep-lineno
- '((t (:foreground "Darkorange1")))
- "Face used to highlight grep number lines."
- :group 'helm-config)
-
-(defface helm-grep-running
- '((t (:foreground "Red")))
- "Face used in mode line when grep is running."
- :group 'helm-config)
-
-(defface helm-grep-finish
- '((t (:foreground "Green")))
- "Face used in mode line when grep is finish."
- :group 'helm-config)
-
-(defface helm-M-x-key-face '((t (:foreground "orange" :underline t)))
- "*Face used in helm-M-x to show keybinding."
- :group 'helm)
-
-(defface helm-bmkext-info
- '((t (:foreground "green")))
- "*Face used for W3m Emacs bookmarks (not w3m bookmarks)."
- :group 'helm)
-
-(defface helm-bmkext-w3m
- '((t (:foreground "yellow")))
- "*Face used for W3m Emacs bookmarks (not w3m bookmarks)."
- :group 'helm)
-
-(defface helm-bmkext-gnus
- '((t (:foreground "magenta")))
- "*Face used for Gnus bookmarks."
- :group 'helm)
-
-(defface helm-bmkext-man
- '((t (:foreground "Orange4")))
- "*Face used for Woman/man bookmarks."
- :group 'helm)
-
-(defface helm-bmkext-no--file
- '((t (:foreground "grey")))
- "*Face used for non--file bookmarks."
- :group 'helm)
-
-(defface helm-bmkext-file
- '((t (:foreground "Deepskyblue2")))
- "*Face used for non--file bookmarks."
- :group 'helm)
-
-(defface helm-bookmarks-su-face '((t (:foreground "red")))
- "Face for su/sudo bookmarks."
- :group 'helm)
-
-(defface helm-w3m-bookmarks-face '((t (:foreground "cyan1" :underline t)))
- "Face for w3m bookmarks" :group 'helm)
-
-(defface helm-emms-playlist
- '((t (:foreground "Springgreen4" :underline t)))
- "*Face used for tracks in current emms playlist."
- :group 'helm)
-
-(defface helm-apt-installed
- '((t (:foreground "green")))
- "*Face used for apt installed candidates."
- :group 'helm)
-
-(defface helm-apt-deinstalled
- '((t (:foreground "DimGray")))
- "*Face used for apt deinstalled candidates."
- :group 'helm)
-
-(defface helm-gentoo-match-face '((t (:foreground "red")))
- "Face for helm-gentoo installed packages."
- :group 'traverse-faces)
-
-(defface helm-lisp-show-completion
- '((t (:background "DarkSlateGray")))
- "*Face used for showing candidates in `helm-lisp-completion'."
- :group 'helm-config)
-
-(defface helm-lisp-completion-info
- '((t (:foreground "red")))
- "*Face used for showing info in `helm-lisp-completion'."
- :group 'helm-config)
-
-(defface helm-overlay-line-face '((t (:background "IndianRed4" :underline t)))
- "Face for source header in the helm buffer." :group 'helm)
-
-;;;###autoload
-(defun helm-configuration ()
- "Customize `helm'."
- (interactive)
- (customize-group "helm-config"))
(provide 'helm-vars)
View
9 helm-w3m.el
@@ -28,6 +28,15 @@
(when (executable-find "w3m")
(require 'w3m-bookmark nil t)))
+
+(defgroup helm-w3m nil
+ "W3m related Applications and libraries for Helm."
+ :group 'helm)
+
+(defface helm-w3m-bookmarks-face '((t (:foreground "cyan1" :underline t)))
+ "Face for w3m bookmarks" :group 'helm-w3m)
+
+
(defvar w3m-bookmark-file "~/.w3m/bookmark.html")
(defvar helm-w3m-bookmarks-regexp ">\\([^><]+.[^</a>]\\)")
(defvar helm-w3m-bookmark-url-regexp "\\(https\\|http\\|ftp\\|file\\)://[^>]*")
View
3 helm.el
@@ -103,6 +103,9 @@
"Open helm."
:prefix "helm-" :group 'convenience)
+(defface helm-overlay-line-face '((t (:background "IndianRed4" :underline t)))
+ "Face for source header in the helm buffer." :group 'helm)
+
(defvar helm-type-attributes nil
"It's a list of \(TYPE ATTRIBUTES ...\).
ATTRIBUTES are the same as attributes for `helm-sources'.

0 comments on commit ba17f09

Please sign in to comment.
Something went wrong with that request. Please try again.