Upgrade packages

This commit is contained in:
Marcus Kammer 2020-02-03 19:45:34 +01:00
parent b928bb7c27
commit cac6948e7e
510 changed files with 14096 additions and 49003 deletions

View file

@ -0,0 +1,228 @@
;;; anaphora-autoloads.el --- automatically extracted autoloads
;;
;;; Code:
(add-to-list 'load-path (directory-file-name
(or (file-name-directory #$) (car load-path))))
;;;### (autoloads nil "anaphora" "anaphora.el" (0 0 0 0))
;;; Generated autoloads from anaphora.el
(let ((loads (get 'anaphora 'custom-loads))) (if (member '"anaphora" loads) nil (put 'anaphora 'custom-loads (cons '"anaphora" loads))))
(defvar anaphora-use-long-names-only nil "\
Use only long names such as `anaphoric-if' instead of traditional `aif'.")
(custom-autoload 'anaphora-use-long-names-only "anaphora" t)
(defun anaphora--install-traditional-aliases (&optional arg) "\
Install traditional short aliases for anaphoric macros.
With negative numeric ARG, remove traditional aliases." (let ((syms (quote ((if . t) (prog1 . t) (prog2 . t) (when . when) (while . t) (and . t) (cond . cond) (lambda . lambda) (block . block) (case . case) (ecase . ecase) (typecase . typecase) (etypecase . etypecase) (let . let) (+ . t) (- . t) (* . t) (/ . t))))) (cond ((and (numberp arg) (< arg 0)) (dolist (cell syms) (when (ignore-errors (eq (symbol-function (intern-soft (format "a%s" (car cell)))) (intern-soft (format "anaphoric-%s" (car cell))))) (fmakunbound (intern (format "a%s" (car cell))))))) (t (dolist (cell syms) (let* ((builtin (car cell)) (traditional (intern (format "a%s" builtin))) (long (intern (format "anaphoric-%s" builtin)))) (defalias traditional long) (put traditional (quote lisp-indent-function) (get builtin (quote lisp-indent-function))) (put traditional (quote edebug-form-spec) (cdr cell))))))))
(unless anaphora-use-long-names-only (anaphora--install-traditional-aliases))
(autoload 'anaphoric-if "anaphora" "\
Like `if', but the result of evaluating COND is bound to `it'.
The variable `it' is available within THEN and ELSE.
COND, THEN, and ELSE are otherwise as documented for `if'.
\(fn COND THEN &rest ELSE)" nil t)
(function-put 'anaphoric-if 'lisp-indent-function '2)
(autoload 'anaphoric-prog1 "anaphora" "\
Like `prog1', but the result of evaluating FIRST is bound to `it'.
The variable `it' is available within BODY.
FIRST and BODY are otherwise as documented for `prog1'.
\(fn FIRST &rest BODY)" nil t)
(function-put 'anaphoric-prog1 'lisp-indent-function '1)
(autoload 'anaphoric-prog2 "anaphora" "\
Like `prog2', but the result of evaluating FORM2 is bound to `it'.
The variable `it' is available within BODY.
FORM1, FORM2, and BODY are otherwise as documented for `prog2'.
\(fn FORM1 FORM2 &rest BODY)" nil t)
(function-put 'anaphoric-prog2 'lisp-indent-function '2)
(autoload 'anaphoric-when "anaphora" "\
Like `when', but the result of evaluating COND is bound to `it'.
The variable `it' is available within BODY.
COND and BODY are otherwise as documented for `when'.
\(fn COND &rest BODY)" nil t)
(function-put 'anaphoric-when 'lisp-indent-function '1)
(autoload 'anaphoric-while "anaphora" "\
Like `while', but the result of evaluating TEST is bound to `it'.
The variable `it' is available within BODY.
TEST and BODY are otherwise as documented for `while'.
\(fn TEST &rest BODY)" nil t)
(function-put 'anaphoric-while 'lisp-indent-function '1)
(autoload 'anaphoric-and "anaphora" "\
Like `and', but the result of the previous condition is bound to `it'.
The variable `it' is available within all CONDITIONS after the
initial one.
CONDITIONS are otherwise as documented for `and'.
Note that some implementations of this macro bind only the first
condition to `it', rather than each successive condition.
\(fn &rest CONDITIONS)" nil t)
(autoload 'anaphoric-cond "anaphora" "\
Like `cond', but the result of each condition is bound to `it'.
The variable `it' is available within the remainder of each of CLAUSES.
CLAUSES are otherwise as documented for `cond'.
\(fn &rest CLAUSES)" nil t)
(autoload 'anaphoric-lambda "anaphora" "\
Like `lambda', but the function may refer to itself as `self'.
ARGS and BODY are otherwise as documented for `lambda'.
\(fn ARGS &rest BODY)" nil t)
(function-put 'anaphoric-lambda 'lisp-indent-function 'defun)
(autoload 'anaphoric-block "anaphora" "\
Like `block', but the result of the previous expression is bound to `it'.
The variable `it' is available within all expressions of BODY
except the initial one.
NAME and BODY are otherwise as documented for `block'.
\(fn NAME &rest BODY)" nil t)
(function-put 'anaphoric-block 'lisp-indent-function '1)
(autoload 'anaphoric-case "anaphora" "\
Like `case', but the result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `case'.
\(fn EXPR &rest CLAUSES)" nil t)
(function-put 'anaphoric-case 'lisp-indent-function '1)
(autoload 'anaphoric-ecase "anaphora" "\
Like `ecase', but the result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `ecase'.
\(fn EXPR &rest CLAUSES)" nil t)
(function-put 'anaphoric-ecase 'lisp-indent-function '1)
(autoload 'anaphoric-typecase "anaphora" "\
Like `typecase', but the result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `typecase'.
\(fn EXPR &rest CLAUSES)" nil t)
(function-put 'anaphoric-typecase 'lisp-indent-function '1)
(autoload 'anaphoric-etypecase "anaphora" "\
Like `etypecase', but result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `etypecase'.
\(fn EXPR &rest CLAUSES)" nil t)
(function-put 'anaphoric-etypecase 'lisp-indent-function '1)
(autoload 'anaphoric-let "anaphora" "\
Like `let', but the result of evaluating FORM is bound to `it'.
FORM and BODY are otherwise as documented for `let'.
\(fn FORM &rest BODY)" nil t)
(function-put 'anaphoric-let 'lisp-indent-function '1)
(autoload 'anaphoric-+ "anaphora" "\
Like `+', but the result of evaluating the previous expression is bound to `it'.
The variable `it' is available within all expressions after the
initial one.
NUMBERS-OR-MARKERS are otherwise as documented for `+'.
\(fn &rest NUMBERS-OR-MARKERS)" nil t)
(autoload 'anaphoric-- "anaphora" "\
Like `-', but the result of evaluating the previous expression is bound to `it'.
The variable `it' is available within all expressions after the
initial one.
NUMBER-OR-MARKER and NUMBERS-OR-MARKERS are otherwise as
documented for `-'.
\(fn &optional NUMBER-OR-MARKER &rest NUMBERS-OR-MARKERS)" nil t)
(autoload 'anaphoric-* "anaphora" "\
Like `*', but the result of evaluating the previous expression is bound to `it'.
The variable `it' is available within all expressions after the
initial one.
NUMBERS-OR-MARKERS are otherwise as documented for `*'.
\(fn &rest NUMBERS-OR-MARKERS)" nil t)
(autoload 'anaphoric-/ "anaphora" "\
Like `/', but the result of evaluating the previous divisor is bound to `it'.
The variable `it' is available within all expressions after the
first divisor.
DIVIDEND, DIVISOR, and DIVISORS are otherwise as documented for `/'.
\(fn DIVIDEND DIVISOR &rest DIVISORS)" nil t)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "anaphora" '("anaphora-install-font-lock-keywords")))
;;;***
;; Local Variables:
;; version-control: never
;; no-byte-compile: t
;; no-update-autoloads: t
;; coding: utf-8
;; End:
;;; anaphora-autoloads.el ends here

View file

@ -0,0 +1,2 @@
;;; -*- no-byte-compile: t -*-
(define-package "anaphora" "20180618.2200" "anaphoric macros providing implicit temp variables" 'nil :commit "3b2da3f759b244975852e79721c4a2dbad3905cf" :keywords '("extensions") :authors '(("Roland Walker" . "walker@pobox.com")) :maintainer '("Roland Walker" . "walker@pobox.com") :url "http://github.com/rolandwalker/anaphora")

View file

@ -0,0 +1,461 @@
;;; anaphora.el --- anaphoric macros providing implicit temp variables -*- lexical-binding: t -*-
;;
;; This code is in the public domain.
;;
;; Author: Roland Walker <walker@pobox.com>
;; Homepage: http://github.com/rolandwalker/anaphora
;; URL: http://raw.githubusercontent.com/rolandwalker/anaphora/master/anaphora.el
;; Package-Version: 20180618.2200
;; Version: 1.0.4
;; Last-Updated: 18 Jun 2018
;; EmacsWiki: Anaphora
;; Keywords: extensions
;;
;;; Commentary:
;;
;; Quickstart
;;
;; (require 'anaphora)
;;
;; (awhen (big-long-calculation)
;; (foo it) ; `it' is provided as
;; (bar it)) ; a temporary variable
;;
;; ;; anonymous function to compute factorial using `self'
;; (alambda (x) (if (= x 0) 1 (* x (self (1- x)))))
;;
;; ;; to fontify `it' and `self'
;; (with-eval-after-load "lisp-mode"
;; (anaphora-install-font-lock-keywords))
;;
;; Explanation
;;
;; Anaphoric expressions implicitly create one or more temporary
;; variables which can be referred to during the expression. This
;; technique can improve clarity in certain cases. It also enables
;; recursion for anonymous functions.
;;
;; To use anaphora, place the anaphora.el library somewhere
;; Emacs can find it, and add the following to your ~/.emacs file:
;;
;; (require 'anaphora)
;;
;; The following macros are made available
;;
;; `aand'
;; `ablock'
;; `acase'
;; `acond'
;; `aecase'
;; `aetypecase'
;; `aif'
;; `alambda'
;; `alet'
;; `aprog1'
;; `aprog2'
;; `atypecase'
;; `awhen'
;; `awhile'
;; `a+'
;; `a-'
;; `a*'
;; `a/'
;;
;; See Also
;;
;; M-x customize-group RET anaphora RET
;; http://en.wikipedia.org/wiki/On_Lisp
;; http://en.wikipedia.org/wiki/Anaphoric_macro
;;
;; Notes
;;
;; Partially based on examples from the book "On Lisp", by Paul
;; Graham.
;;
;; Compatibility and Requirements
;;
;; GNU Emacs version 26.1 : yes
;; GNU Emacs version 25.x : yes
;; GNU Emacs version 24.x : yes
;; GNU Emacs version 23.x : yes
;; GNU Emacs version 22.x : yes
;; GNU Emacs version 21.x and lower : unknown
;;
;; Bugs
;;
;; TODO
;;
;; better face for it and self
;;
;;; License
;;
;; All code contributed by the author to this library is placed in the
;; public domain. It is the author's belief that the portions adapted
;; from examples in "On Lisp" are in the public domain.
;;
;; Regardless of the copyright status of individual functions, all
;; code herein is free software, and is provided without any express
;; or implied warranties.
;;
;;; Code:
;;
;;; requirements
;; for declare, labels, do, block, case, ecase, typecase, etypecase
(require 'cl-lib)
;;; customizable variables
;;;###autoload
(defgroup anaphora nil
"Anaphoric macros providing implicit temp variables"
:version "1.0.4"
:link '(emacs-commentary-link :tag "Commentary" "anaphora")
:link '(url-link :tag "GitHub" "http://github.com/rolandwalker/anaphora")
:link '(url-link :tag "EmacsWiki" "http://emacswiki.org/emacs/Anaphora")
:prefix "anaphora-"
:group 'extensions)
;;;###autoload
(defcustom anaphora-use-long-names-only nil
"Use only long names such as `anaphoric-if' instead of traditional `aif'."
:type 'boolean
:group 'anaphora)
;;; font-lock
(defun anaphora-install-font-lock-keywords nil
"Fontify keywords `it' and `self'."
(font-lock-add-keywords 'emacs-lisp-mode `((,(concat "\\<" (regexp-opt '("it" "self") 'paren) "\\>")
1 font-lock-variable-name-face)) 'append))
;;; aliases
;;;###autoload
(progn
(defun anaphora--install-traditional-aliases (&optional arg)
"Install traditional short aliases for anaphoric macros.
With negative numeric ARG, remove traditional aliases."
(let ((syms '(
(if . t)
(prog1 . t)
(prog2 . t)
(when . when)
(while . t)
(and . t)
(cond . cond)
(lambda . lambda)
(block . block)
(case . case)
(ecase . ecase)
(typecase . typecase)
(etypecase . etypecase)
(let . let)
(+ . t)
(- . t)
(* . t)
(/ . t)
)))
(cond
((and (numberp arg)
(< arg 0))
(dolist (cell syms)
(when (ignore-errors
(eq (symbol-function (intern-soft (format "a%s" (car cell))))
(intern-soft (format "anaphoric-%s" (car cell)))))
(fmakunbound (intern (format "a%s" (car cell)))))))
(t
(dolist (cell syms)
(let* ((builtin (car cell))
(traditional (intern (format "a%s" builtin)))
(long (intern (format "anaphoric-%s" builtin))))
(defalias traditional long)
(put traditional 'lisp-indent-function
(get builtin 'lisp-indent-function))
(put traditional 'edebug-form-spec (cdr cell)))))))))
;;;###autoload
(unless anaphora-use-long-names-only
(anaphora--install-traditional-aliases))
;;; macros
;;;###autoload
(defmacro anaphoric-if (cond then &rest else)
"Like `if', but the result of evaluating COND is bound to `it'.
The variable `it' is available within THEN and ELSE.
COND, THEN, and ELSE are otherwise as documented for `if'."
(declare (debug t)
(indent 2))
`(let ((it ,cond))
(if it ,then ,@else)))
;;;###autoload
(defmacro anaphoric-prog1 (first &rest body)
"Like `prog1', but the result of evaluating FIRST is bound to `it'.
The variable `it' is available within BODY.
FIRST and BODY are otherwise as documented for `prog1'."
(declare (debug t)
(indent 1))
`(let ((it ,first))
(progn ,@body)
it))
;;;###autoload
(defmacro anaphoric-prog2 (form1 form2 &rest body)
"Like `prog2', but the result of evaluating FORM2 is bound to `it'.
The variable `it' is available within BODY.
FORM1, FORM2, and BODY are otherwise as documented for `prog2'."
(declare (debug t)
(indent 2))
`(progn
,form1
(let ((it ,form2))
(progn ,@body)
it)))
;;;###autoload
(defmacro anaphoric-when (cond &rest body)
"Like `when', but the result of evaluating COND is bound to `it'.
The variable `it' is available within BODY.
COND and BODY are otherwise as documented for `when'."
(declare (debug when)
(indent 1))
`(anaphoric-if ,cond
(progn ,@body)))
;;;###autoload
(defmacro anaphoric-while (test &rest body)
"Like `while', but the result of evaluating TEST is bound to `it'.
The variable `it' is available within BODY.
TEST and BODY are otherwise as documented for `while'."
(declare (debug t)
(indent 1))
`(do ((it ,test ,test))
((not it))
,@body))
;;;###autoload
(defmacro anaphoric-and (&rest conditions)
"Like `and', but the result of the previous condition is bound to `it'.
The variable `it' is available within all CONDITIONS after the
initial one.
CONDITIONS are otherwise as documented for `and'.
Note that some implementations of this macro bind only the first
condition to `it', rather than each successive condition."
(declare (debug t))
(cond
((null conditions)
t)
((null (cdr conditions))
(car conditions))
(t
`(anaphoric-if ,(car conditions) (anaphoric-and ,@(cdr conditions))))))
;;;###autoload
(defmacro anaphoric-cond (&rest clauses)
"Like `cond', but the result of each condition is bound to `it'.
The variable `it' is available within the remainder of each of CLAUSES.
CLAUSES are otherwise as documented for `cond'."
(declare (debug cond))
(if (null clauses)
nil
(let ((cl1 (car clauses))
(sym (gensym)))
`(let ((,sym ,(car cl1)))
(if ,sym
(if (null ',(cdr cl1))
,sym
(let ((it ,sym)) ,@(cdr cl1)))
(anaphoric-cond ,@(cdr clauses)))))))
;;;###autoload
(defmacro anaphoric-lambda (args &rest body)
"Like `lambda', but the function may refer to itself as `self'.
ARGS and BODY are otherwise as documented for `lambda'."
(declare (debug lambda)
(indent defun))
`(cl-labels ((self ,args ,@body))
#'self))
;;;###autoload
(defmacro anaphoric-block (name &rest body)
"Like `block', but the result of the previous expression is bound to `it'.
The variable `it' is available within all expressions of BODY
except the initial one.
NAME and BODY are otherwise as documented for `block'."
(declare (debug block)
(indent 1))
`(cl-block ,name
,(funcall (anaphoric-lambda (body)
(cl-case (length body)
(0 nil)
(1 (car body))
(t `(let ((it ,(car body)))
,(self (cdr body))))))
body)))
;;;###autoload
(defmacro anaphoric-case (expr &rest clauses)
"Like `case', but the result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `case'."
(declare (debug case)
(indent 1))
`(let ((it ,expr))
(cl-case it ,@clauses)))
;;;###autoload
(defmacro anaphoric-ecase (expr &rest clauses)
"Like `ecase', but the result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `ecase'."
(declare (debug ecase)
(indent 1))
`(let ((it ,expr))
(cl-ecase it ,@clauses)))
;;;###autoload
(defmacro anaphoric-typecase (expr &rest clauses)
"Like `typecase', but the result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `typecase'."
(declare (debug typecase)
(indent 1))
`(let ((it ,expr))
(cl-typecase it ,@clauses)))
;;;###autoload
(defmacro anaphoric-etypecase (expr &rest clauses)
"Like `etypecase', but result of evaluating EXPR is bound to `it'.
The variable `it' is available within CLAUSES.
EXPR and CLAUSES are otherwise as documented for `etypecase'."
(declare (debug etypecase)
(indent 1))
`(let ((it ,expr))
(cl-etypecase it ,@clauses)))
;;;###autoload
(defmacro anaphoric-let (form &rest body)
"Like `let', but the result of evaluating FORM is bound to `it'.
FORM and BODY are otherwise as documented for `let'."
(declare (debug let)
(indent 1))
`(let ((it ,form))
(progn ,@body)))
;;;###autoload
(defmacro anaphoric-+ (&rest numbers-or-markers)
"Like `+', but the result of evaluating the previous expression is bound to `it'.
The variable `it' is available within all expressions after the
initial one.
NUMBERS-OR-MARKERS are otherwise as documented for `+'."
(declare (debug t))
(cond
((null numbers-or-markers)
0)
(t
`(let ((it ,(car numbers-or-markers)))
(+ it (anaphoric-+ ,@(cdr numbers-or-markers)))))))
;;;###autoload
(defmacro anaphoric-- (&optional number-or-marker &rest numbers-or-markers)
"Like `-', but the result of evaluating the previous expression is bound to `it'.
The variable `it' is available within all expressions after the
initial one.
NUMBER-OR-MARKER and NUMBERS-OR-MARKERS are otherwise as
documented for `-'."
(declare (debug t))
(cond
((null number-or-marker)
0)
((null numbers-or-markers)
`(- ,number-or-marker))
(t
`(let ((it ,(car numbers-or-markers)))
(- ,number-or-marker (+ it (anaphoric-+ ,@(cdr numbers-or-markers))))))))
;;;###autoload
(defmacro anaphoric-* (&rest numbers-or-markers)
"Like `*', but the result of evaluating the previous expression is bound to `it'.
The variable `it' is available within all expressions after the
initial one.
NUMBERS-OR-MARKERS are otherwise as documented for `*'."
(declare (debug t))
(cond
((null numbers-or-markers)
1)
(t
`(let ((it ,(car numbers-or-markers)))
(* it (anaphoric-* ,@(cdr numbers-or-markers)))))))
;;;###autoload
(defmacro anaphoric-/ (dividend divisor &rest divisors)
"Like `/', but the result of evaluating the previous divisor is bound to `it'.
The variable `it' is available within all expressions after the
first divisor.
DIVIDEND, DIVISOR, and DIVISORS are otherwise as documented for `/'."
(declare (debug t))
(cond
((null divisors)
`(/ ,dividend ,divisor))
(t
`(let ((it ,divisor))
(/ ,dividend (* it (anaphoric-* ,@divisors)))))))
(provide 'anaphora)
;;
;; Emacs
;;
;; Local Variables:
;; indent-tabs-mode: nil
;; mangle-whitespace: t
;; require-final-newline: t
;; coding: utf-8
;; byte-compile-warnings: (not cl-functions redefine)
;; End:
;;
;; LocalWords: Anaphora EXPR awhen COND ARGS alambda ecase typecase
;; LocalWords: etypecase aprog aand acond ablock acase aecase alet
;; LocalWords: atypecase aetypecase
;;
;;; anaphora.el ends here

Binary file not shown.

View file

@ -18,11 +18,11 @@
("Leo Liu" . "sdl.web@gmail.com"))
(:keywords "tools" "processes" "convenience"))])
(ada-mode .
[(6 2 1)
[(7 0 1)
((uniquify-files
(1 0 1))
(wisi
(2 2 1))
(3 0 1))
(emacs
(25 0)))
"major-mode for editing Ada sources" tar
@ -397,7 +397,7 @@
("Gary D. Foster" . "Gary.Foster@Corp.Sun.COM"))
(:maintainer "Luke Lee" . "luke.yx.lee@gmail.com"))])
(csv-mode .
[(1 10)
[(1 11)
((emacs
(24 1))
(cl-lib
@ -1414,7 +1414,7 @@
[(9 3 2)
nil "Outline-based notes management and organizer" tar
((:url . "https://orgmode.org")
(:maintainer "Bastien Guerry <bzg at gnu dot org>")
(:maintainer "Bastien Guerry" . "bzg@gnu.org")
(:authors
("Carsten Dominik <carsten at orgmode dot org>"))
(:keywords "outlines" "hypermedia" "calendar" "wp"))])
@ -1735,15 +1735,17 @@
("Bastien Guerry" . "bzg@gnu.org"))
(:maintainer "Bastien Guerry" . "bzg@gnu.org"))])
(relint .
[(1 12)
[(1 13)
((xr
(1 14)))
(1 15))
(emacs
(26 1)))
"Elisp regexp mistake finder" tar
((:url . "https://github.com/mattiase/relint")
(:maintainer "Mattias Engdegård" . "mattiase@acm.org")
(:authors
("Mattias Engdegård" . "mattiase@acm.org"))
(:keywords "lisp" "maint" "regexps"))])
(:keywords "lisp" "regexps"))])
(rich-minority .
[(1 0 1)
((cl-lib
@ -2236,7 +2238,7 @@
("Bastien" . "bzg@gnu.org"))
(:maintainer "Bastien" . "bzg@gnu.org"))])
(wisi .
[(2 2 1)
[(3 0 1)
((emacs
(25 0))
(seq
@ -2297,13 +2299,15 @@
("Thien-Thi Nguyen" . "ttn@gnu.org"))
(:keywords "multimedia" "xpm"))])
(xr .
[(1 14)
nil "Convert string regexp to rx notation" tar
[(1 15)
((emacs
(26 1)))
"Convert string regexp to rx notation" tar
((:url . "https://github.com/mattiase/xr")
(:maintainer "Mattias Engdegård" . "mattiase@acm.org")
(:authors
("Mattias Engdegård" . "mattiase@acm.org"))
(:keywords "lisp" "maint" "regexps"))])
(:keywords "lisp" "regexps"))])
(yasnippet .
[(0 14 0)
((cl-lib

View file

@ -1,71 +0,0 @@
;;; auto-complete-autoloads.el --- automatically extracted autoloads
;;
;;; Code:
(add-to-list 'load-path (directory-file-name
(or (file-name-directory #$) (car load-path))))
;;;### (autoloads nil "auto-complete" "auto-complete.el" (0 0 0 0))
;;; Generated autoloads from auto-complete.el
(autoload 'auto-complete "auto-complete" "\
Start auto-completion at current point.
\(fn &optional SOURCES)" t nil)
(autoload 'auto-complete-mode "auto-complete" "\
AutoComplete mode
\(fn &optional ARG)" t nil)
(defvar global-auto-complete-mode nil "\
Non-nil if Global Auto-Complete mode is enabled.
See the `global-auto-complete-mode' command
for a description of this minor mode.
Setting this variable directly does not take effect;
either customize it (see the info node `Easy Customization')
or call the function `global-auto-complete-mode'.")
(custom-autoload 'global-auto-complete-mode "auto-complete" nil)
(autoload 'global-auto-complete-mode "auto-complete" "\
Toggle Auto-Complete mode in all buffers.
With prefix ARG, enable Global Auto-Complete mode if ARG is positive;
otherwise, disable it. If called from Lisp, enable the mode if
ARG is omitted or nil.
Auto-Complete mode is enabled in all buffers where
`auto-complete-mode-maybe' would do it.
See `auto-complete-mode' for more information on Auto-Complete mode.
\(fn &optional ARG)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "auto-complete" '("auto-complete-mode" "ac-")))
;;;***
;;;### (autoloads nil "auto-complete-config" "auto-complete-config.el"
;;;;;; (0 0 0 0))
;;; Generated autoloads from auto-complete-config.el
(autoload 'ac-config-default "auto-complete-config" "\
\(fn)" nil nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "auto-complete-config" '("ac-")))
;;;***
;;;### (autoloads nil nil ("auto-complete-pkg.el") (0 0 0 0))
;;;***
;; Local Variables:
;; version-control: never
;; no-byte-compile: t
;; no-update-autoloads: t
;; coding: utf-8
;; End:
;;; auto-complete-autoloads.el ends here

View file

@ -1,551 +0,0 @@
;;; auto-complete-config.el --- auto-complete additional configuations
;; Copyright (C) 2009, 2010 Tomohiro Matsuyama
;; Author: Tomohiro Matsuyama <m2ym.pub@gmail.com>
;; Keywords: convenience
;; Version: 1.5.0
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; This program is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'cl-lib)
(require 'auto-complete)
(declare-function semantic-analyze-current-context "semantic/analyze")
(declare-function semantic-tag-class "semantic/tag")
(declare-function semantic-tag-function-arguments "semantic/tag")
(declare-function semantic-format-tag-type "semantic/format")
(declare-function semantic-format-tag-name "semantic/format")
(declare-function yas-expand-snippet "yasnippet")
(declare-function oref "eieio" (obj slot))
;;;; Additional sources
;; imenu
(defvar ac-imenu-index nil)
(ac-clear-variable-every-10-minutes 'ac-imenu-index)
(defun ac-imenu-candidates ()
(cl-loop with i = 0
with stack = (progn
(unless (local-variable-p 'ac-imenu-index)
(make-local-variable 'ac-imenu-index))
(or ac-imenu-index
(setq ac-imenu-index
(ignore-errors
(with-no-warnings
(imenu--make-index-alist))))))
with result
while (and stack (or (not (integerp ac-limit))
(< i ac-limit)))
for node = (pop stack)
if (consp node)
do
(let ((car (car node))
(cdr (cdr node)))
(if (consp cdr)
(mapc (lambda (child)
(push child stack))
cdr)
(when (and (stringp car)
(string-match (concat "^" (regexp-quote ac-prefix)) car))
;; Remove extra characters
(if (string-match "^.*\\(()\\|=\\|<>\\)$" car)
(setq car (substring car 0 (match-beginning 1))))
(push car result)
(cl-incf i))))
finally return (nreverse result)))
(ac-define-source imenu
'((depends imenu)
(candidates . ac-imenu-candidates)
(symbol . "s")))
;; gtags
(defface ac-gtags-candidate-face
'((t (:inherit ac-candidate-face :foreground "navy")))
"Face for gtags candidate"
:group 'auto-complete)
(defface ac-gtags-selection-face
'((t (:inherit ac-selection-face :background "navy")))
"Face for the gtags selected candidate."
:group 'auto-complete)
(defun ac-gtags-candidate ()
(ignore-errors
(split-string (shell-command-to-string (format "global -ciq %s" ac-prefix)) "\n")))
(ac-define-source gtags
'((candidates . ac-gtags-candidate)
(candidate-face . ac-gtags-candidate-face)
(selection-face . ac-gtags-selection-face)
(requires . 3)
(symbol . "s")))
;; yasnippet
(defface ac-yasnippet-candidate-face
'((t (:inherit ac-candidate-face
:background "sandybrown" :foreground "black")))
"Face for yasnippet candidate."
:group 'auto-complete)
(defface ac-yasnippet-selection-face
'((t (:inherit ac-selection-face :background "coral3")))
"Face for the yasnippet selected candidate."
:group 'auto-complete)
(defun ac-yasnippet-table-hash (table)
(cond
((fboundp 'yas/snippet-table-hash)
(yas/snippet-table-hash table))
((fboundp 'yas/table-hash)
(yas/table-hash table))))
(defun ac-yasnippet-table-parent (table)
(cond
((fboundp 'yas/snippet-table-parent)
(yas/snippet-table-parent table))
((fboundp 'yas/table-parent)
(yas/table-parent table))))
(defun ac-yasnippet-candidate-1 (table)
(with-no-warnings
(let ((hashtab (ac-yasnippet-table-hash table))
(parent (ac-yasnippet-table-parent table))
candidates)
(maphash (lambda (key value)
(push key candidates))
hashtab)
(setq candidates (all-completions ac-prefix (nreverse candidates)))
(if parent
(setq candidates
(append candidates (ac-yasnippet-candidate-1 parent))))
candidates)))
(defun ac-yasnippet-candidates ()
(with-no-warnings
(cond (;; 0.8 onwards
(fboundp 'yas-active-keys)
(all-completions ac-prefix (yas-active-keys)))
(;; >0.6.0
(fboundp 'yas/get-snippet-tables)
(apply 'append (mapcar 'ac-yasnippet-candidate-1
(condition-case nil
(yas/get-snippet-tables major-mode)
(wrong-number-of-arguments
(yas/get-snippet-tables)))))
)
(t
(let ((table
(if (fboundp 'yas/snippet-table)
;; <0.6.0
(yas/snippet-table major-mode)
;; 0.6.0
(yas/current-snippet-table))))
(if table
(ac-yasnippet-candidate-1 table)))))))
(ac-define-source yasnippet
'((depends yasnippet)
(candidates . ac-yasnippet-candidates)
(action . yas/expand)
(candidate-face . ac-yasnippet-candidate-face)
(selection-face . ac-yasnippet-selection-face)
(symbol . "a")))
;; semantic
(defun ac-semantic-candidates (prefix)
(with-no-warnings
(delete "" ; semantic sometimes returns an empty string
(mapcar (lambda (elem)
(cons (semantic-tag-name elem)
(semantic-tag-clone elem)))
(ignore-errors
(or (semantic-analyze-possible-completions
(semantic-analyze-current-context))
(senator-find-tag-for-completion prefix)))))))
(defun ac-semantic-doc (symbol)
(with-no-warnings
(let* ((proto (semantic-format-tag-summarize-with-file symbol nil t))
(doc (semantic-documentation-for-tag symbol))
(res proto))
(when doc
(setq res (concat res "\n\n" doc)))
res)))
(defun ac-semantic-action ()
(when (and (boundp 'yas-minor-mode) yas-minor-mode)
(let* ((tag (car (last (oref (semantic-analyze-current-context) prefix))))
(class (semantic-tag-class tag))
(args))
(when (eq class 'function)
(setq args (semantic-tag-function-arguments tag))
(yas-expand-snippet
(concat "("
(mapconcat
(lambda (arg)
(let ((arg-type (semantic-format-tag-type arg nil))
(arg-name (semantic-format-tag-name arg nil)))
(concat "${"
(if (string= arg-name "")
arg-type
(concat arg-type " " arg-name))
"}")))
args
", ")
")$0"))))))
(ac-define-source semantic
'((available . (or (require 'semantic-ia nil t)
(require 'semantic/ia nil t)))
(candidates . (ac-semantic-candidates ac-prefix))
(document . ac-semantic-doc)
(action . ac-semantic-action)
(prefix . cc-member)
(requires . 0)
(symbol . "m")))
(ac-define-source semantic-raw
'((available . (or (require 'semantic-ia nil t)
(require 'semantic/ia nil t)))
(candidates . (ac-semantic-candidates ac-prefix))
(document . ac-semantic-doc)
(action . ac-semantic-action)
(symbol . "s")))
;; eclim
(defun ac-eclim-candidates ()
(with-no-warnings
(cl-loop for c in (eclim/java-complete)
collect (nth 1 c))))
(ac-define-source eclim
'((candidates . ac-eclim-candidates)
(prefix . c-dot)
(requires . 0)
(symbol . "f")))
;; css
;; Copied from company-css.el
(defconst ac-css-property-alist
;; see http://www.w3.org/TR/CSS21/propidx.html
'(("azimuth" angle "left-side" "far-left" "left" "center-left" "center"
"center-right" "right" "far-right" "right-side" "behind" "leftwards"
"rightwards")
("background" background-color background-image background-repeat
background-attachment background-position)
("background-attachment" "scroll" "fixed")
("background-color" color "transparent")
("background-image" uri "none")
("background-position" percentage length "left" "center" "right" percentage
length "top" "center" "bottom" "left" "center" "right" "top" "center"
"bottom")
("background-repeat" "repeat" "repeat-x" "repeat-y" "no-repeat")
("border" border-width border-style border-color)
("border-bottom" border)
("border-bottom-color" border-color)
("border-bottom-style" border-style)
("border-bottom-width" border-width)
("border-collapse" "collapse" "separate")
("border-color" color "transparent")
("border-left" border)
("border-left-color" border-color)
("border-left-style" border-style)
("border-left-width" border-width)
("border-right" border)
("border-right-color" border-color)
("border-right-style" border-style)
("border-right-width" border-width)
("border-spacing" length length)
("border-style" border-style)
("border-top" border)
("border-top-color" border-color)
("border-top-style" border-style)
("border-top-width" border-width)
("border-width" border-width)
("bottom" length percentage "auto")
("caption-side" "top" "bottom")
("clear" "none" "left" "right" "both")
("clip" shape "auto")
("color" color)
("content" "normal" "none" string uri counter "attr()" "open-quote"
"close-quote" "no-open-quote" "no-close-quote")
("counter-increment" identifier integer "none")
("counter-reset" identifier integer "none")
("cue" cue-before cue-after)
("cue-after" uri "none")
("cue-before" uri "none")
("cursor" uri "*" "auto" "crosshair" "default" "pointer" "move" "e-resize"
"ne-resize" "nw-resize" "n-resize" "se-resize" "sw-resize" "s-resize"
"w-resize" "text" "wait" "help" "progress")
("direction" "ltr" "rtl")
("display" "inline" "block" "list-item" "run-in" "inline-block" "table"
"inline-table" "table-row-group" "table-header-group" "table-footer-group"
"table-row" "table-column-group" "table-column" "table-cell"
"table-caption" "none")
("elevation" angle "below" "level" "above" "higher" "lower")
("empty-cells" "show" "hide")
("float" "left" "right" "none")
("font" font-style font-variant font-weight font-size "/" line-height
font-family "caption" "icon" "menu" "message-box" "small-caption"
"status-bar")
("font-family" family-name generic-family)
("font-size" absolute-size relative-size length percentage)
("font-style" "normal" "italic" "oblique")
("font-variant" "normal" "small-caps")
("font-weight" "normal" "bold" "bolder" "lighter" "100" "200" "300" "400"
"500" "600" "700" "800" "900")
("height" length percentage "auto")
("left" length percentage "auto")
("letter-spacing" "normal" length)
("line-height" "normal" number length percentage)
("list-style" list-style-type list-style-position list-style-image)
("list-style-image" uri "none")
("list-style-position" "inside" "outside")
("list-style-type" "disc" "circle" "square" "decimal" "decimal-leading-zero"
"lower-roman" "upper-roman" "lower-greek" "lower-latin" "upper-latin"
"armenian" "georgian" "lower-alpha" "upper-alpha" "none")
("margin" margin-width)
("margin-bottom" margin-width)
("margin-left" margin-width)
("margin-right" margin-width)
("margin-top" margin-width)
("max-height" length percentage "none")
("max-width" length percentage "none")
("min-height" length percentage)
("min-width" length percentage)
("orphans" integer)
("outline" outline-color outline-style outline-width)
("outline-color" color "invert")
("outline-style" border-style)
("outline-width" border-width)
("overflow" "visible" "hidden" "scroll" "auto")
("padding" padding-width)
("padding-bottom" padding-width)
("padding-left" padding-width)
("padding-right" padding-width)
("padding-top" padding-width)
("page-break-after" "auto" "always" "avoid" "left" "right")
("page-break-before" "auto" "always" "avoid" "left" "right")
("page-break-inside" "avoid" "auto")
("pause" time percentage)
("pause-after" time percentage)
("pause-before" time percentage)
("pitch" frequency "x-low" "low" "medium" "high" "x-high")
("pitch-range" number)
("play-during" uri "mix" "repeat" "auto" "none")
("position" "static" "relative" "absolute" "fixed")
("quotes" string string "none")
("richness" number)
("right" length percentage "auto")
("speak" "normal" "none" "spell-out")
("speak-header" "once" "always")
("speak-numeral" "digits" "continuous")
("speak-punctuation" "code" "none")
("speech-rate" number "x-slow" "slow" "medium" "fast" "x-fast" "faster"
"slower")
("stress" number)
("table-layout" "auto" "fixed")
("text-align" "left" "right" "center" "justify")
("text-decoration" "none" "underline" "overline" "line-through" "blink")
("text-indent" length percentage)
("text-transform" "capitalize" "uppercase" "lowercase" "none")
("top" length percentage "auto")
("unicode-bidi" "normal" "embed" "bidi-override")
("vertical-align" "baseline" "sub" "super" "top" "text-top" "middle"
"bottom" "text-bottom" percentage length)
("visibility" "visible" "hidden" "collapse")
("voice-family" specific-voice generic-voice "*" specific-voice
generic-voice)
("volume" number percentage "silent" "x-soft" "soft" "medium" "loud"
"x-loud")
("white-space" "normal" "pre" "nowrap" "pre-wrap" "pre-line")
("widows" integer)
("width" length percentage "auto")
("word-spacing" "normal" length)
("z-index" "auto" integer))
"A list of CSS properties and their possible values.")
(defconst ac-css-value-classes
'((absolute-size "xx-small" "x-small" "small" "medium" "large" "x-large"
"xx-large")
(border-style "none" "hidden" "dotted" "dashed" "solid" "double" "groove"
"ridge" "inset" "outset")
(color "aqua" "black" "blue" "fuchsia" "gray" "green" "lime" "maroon" "navy"
"olive" "orange" "purple" "red" "silver" "teal" "white" "yellow"
"rgb")
(counter "counter")
(family-name "Courier" "Helvetica" "Times")
(generic-family "serif" "sans-serif" "cursive" "fantasy" "monospace")
(generic-voice "male" "female" "child")
(margin-width "auto") ;; length percentage
(relative-size "larger" "smaller")
(shape "rect")
(uri "url"))
"A list of CSS property value classes and their contents.")
(defconst ac-css-pseudo-classes
'("active" "after" "before" "first" "first-child" "first-letter" "first-line"
"focus" "hover" "lang" "left" "link" "right" "visited")
"Identifiers for CSS pseudo-elements and pseudo-classes.")
(defvar ac-css-property nil
"Current editing property.")
(defun ac-css-prefix ()
(when (save-excursion (re-search-backward "\\_<\\(.+?\\)\\_>\\s *:[^;]*\\=" nil t))
(setq ac-css-property (match-string 1))
(or (ac-prefix-symbol) (point))))
(defun ac-css-property-candidates ()
(let ((list (assoc-default ac-css-property ac-css-property-alist)))
(if list
(cl-loop with seen
with value
while (setq value (pop list))
if (symbolp value)
do (unless (memq value seen)
(push value seen)
(setq list
(append list
(or (assoc-default value ac-css-value-classes)
(assoc-default (symbol-name value) ac-css-property-alist)))))
else collect value)
ac-css-pseudo-classes)))
(ac-define-source css-property
'((candidates . ac-css-property-candidates)
(prefix . ac-css-prefix)
(requires . 0)))
;; slime
(ac-define-source slime
'((depends slime)
(candidates . (car (slime-simple-completions ac-prefix)))
(symbol . "s")
(cache)))
;; ghc-mod
(ac-define-source ghc-mod
'((depends ghc)
(candidates . (ghc-select-completion-symbol))
(symbol . "s")
(cache)))
;;;; Not maintained sources
;; ropemacs
(defvar ac-ropemacs-loaded nil)
(defun ac-ropemacs-require ()
(with-no-warnings
(unless ac-ropemacs-loaded
(pymacs-load "ropemacs" "rope-")
(if (boundp 'ropemacs-enable-autoimport)
(setq ropemacs-enable-autoimport t))
(setq ac-ropemacs-loaded t))))
(defun ac-ropemacs-setup ()
(ac-ropemacs-require)
;(setq ac-sources (append (list 'ac-source-ropemacs) ac-sources))
(setq ac-omni-completion-sources '(("\\." ac-source-ropemacs))))
(defun ac-ropemacs-initialize ()
(autoload 'pymacs-apply "pymacs")
(autoload 'pymacs-call "pymacs")
(autoload 'pymacs-eval "pymacs" nil t)
(autoload 'pymacs-exec "pymacs" nil t)
(autoload 'pymacs-load "pymacs" nil t)
(add-hook 'python-mode-hook 'ac-ropemacs-setup)
t)
(defvar ac-ropemacs-completions-cache nil)
(defvar ac-source-ropemacs
'((init
. (lambda ()
(setq ac-ropemacs-completions-cache
(mapcar
(lambda (completion)
(concat ac-prefix completion))
(ignore-errors
(rope-completions))))))
(candidates . ac-ropemacs-completions-cache)))
;; rcodetools
(defvar ac-source-rcodetools
'((init . (lambda ()
(require 'rcodetools)
(condition-case x
(save-excursion
(rct-exec-and-eval rct-complete-command-name "--completion-emacs-icicles"))
(error) (setq rct-method-completion-table nil))))
(candidates . (lambda ()
(all-completions
ac-prefix
(mapcar
(lambda (completion)
(replace-regexp-in-string "\t.*$" "" (car completion)))
rct-method-completion-table))))))
;;;; Default settings
(defun ac-common-setup ()
;(add-to-list 'ac-sources 'ac-source-filename)
)
(defun ac-emacs-lisp-mode-setup ()
(setq ac-sources (append '(ac-source-features ac-source-functions ac-source-yasnippet ac-source-variables ac-source-symbols) ac-sources)))
(defun ac-cc-mode-setup ()
(setq ac-sources (append '(ac-source-yasnippet ac-source-gtags) ac-sources)))
(defun ac-ruby-mode-setup ())
(defun ac-css-mode-setup ()
(setq ac-sources (append '(ac-source-css-property) ac-sources)))
;;;###autoload
(defun ac-config-default ()
(setq-default ac-sources '(ac-source-abbrev ac-source-dictionary ac-source-words-in-same-mode-buffers))
(add-hook 'emacs-lisp-mode-hook 'ac-emacs-lisp-mode-setup)
(add-hook 'c-mode-common-hook 'ac-cc-mode-setup)
(add-hook 'ruby-mode-hook 'ac-ruby-mode-setup)
(add-hook 'css-mode-hook 'ac-css-mode-setup)
(add-hook 'auto-complete-mode-hook 'ac-common-setup)
(global-auto-complete-mode t))
(provide 'auto-complete-config)
;;; auto-complete-config.el ends here

View file

@ -1,6 +0,0 @@
(define-package "auto-complete" "20170125.245" "Auto Completion for GNU Emacs"
'((popup "0.5.0")
(cl-lib "0.5")))
;; Local Variables:
;; no-byte-compile: t
;; End:

File diff suppressed because it is too large Load diff

View file

@ -1,72 +0,0 @@
abort
abs
abstract
accept
access
aliased
all
and
array
at
begin
body
case
constant
declare
delay
delta
digits
do
else
elsif
end
entry
exception
exit
for
function
generic
goto
if
in
interface
is
limited
loop
mod
new
not
null
of
or
others
out
overriding
package
pragma
private
procedure
protected
raise
range
record
rem
renames
requeue
return
reverse
select
separate
subtype
synchronized
tagged
task
terminate
then
type
until
use
when
while
with
xor

View file

@ -1,99 +0,0 @@
alignas
alignof
and
and_eq
asm
auto
bitand
bitor
bool
break
case
catch
char
char16_t
char32_t
class
compl
concept
const
const_cast
constexpr
continue
decltype
default
define
defined
delete
do
double
dynamic_cast
elif
else
endif
enum
error
explicit
export
extern
false
final
float
for
friend
goto
if
ifdef
ifndef
include
inline
int
line
long
mutable
namespace
new
noexcept
not
not_eq
nullptr
operator
or
or_eq
override
pragma
_Pragma
private
protected
public
register
reinterpret_cast
requires
return
short
signed
sizeof
static
static_assert
static_cast
struct
switch
template
this
thread_local
throw
true
try
typedef
typeid
typename
union
unsigned
using
virtual
void
volatile
wchar_t
while
xor
xor_eq

View file

@ -1,55 +0,0 @@
auto
_Alignas
_Alignof
_Atomic
_Bool
break
case
char
_Complex
const
continue
default
define
defined
do
double
elif
else
endif
enum
error
extern
float
for
goto
_Generic
if
ifdef
ifndef
_Imaginary
include
inline
int
line
long
_Noreturn
pragma
register
restrict
return
short
signed
sizeof
static
struct
switch
_Static_assert
typedef
_Thread_local
undef
union
unsigned
void
volatile
while

View file

@ -1,231 +0,0 @@
# OCaml 3.12.1
# Keywords
and
as
assert
begin
class
constraint
do
done
downto
else
end
exception
external
false
for
fun
function
functor
if
in
include
inherit
initializer
lazy
let
match
method
module
mutable
new
object
of
open
or
private
rec
sig
struct
then
to
true
try
type
val
virtual
when
while
with
# Pervasives
!
!=
&
&&
*
**
*.
+
+.
-
-.
/
/.
:=
<
<=
<>
=
==
>
>=
@
FP_infinite
FP_nan
FP_normal
FP_subnormal
FP_zero
LargeFile
Open_append
Open_binary
Open_creat
Open_nonblock
Open_rdonly
Open_text
Open_trunc
Open_wronly
Oupen_excl
^
^^
abs
abs_float
acos
asin
asr
at_exit
atan
atan2
bool_of_string
ceil
char_of_int
classify_float
close_in
close_in_noerr
close_out
close_out_noerr
compare
cos
cosh
decr
do_at_exit
epsilon_float
exit
exp
expm1
failwith
float
float_of_int
float_of_string
floor
flush
flush_all
format
format4
format_of_string
fpclass
frexp
fst
ignore
in_channel
in_channel_length
incr
infinity
input
input_binary_int
input_byte
input_char
input_line
input_value
int_of_char
int_of_float
int_of_string
invalid_arg
land
ldexp
lnot
log
log10
log1p
lor
lsl
lsr
lxor
max
max_float
max_int
min
min_float
min_int
mod
mod_float
modf
nan
neg_infinity
not
open_flag
open_in
open_in_bin
open_in_gen
open_out
open_out_bin
open_out_gen
or
out_channel
out_channel_length
output
output_binary_int
output_byte
output_char
output_string
output_value
pos_in
pos_out
pred
prerr_char
prerr_endline
prerr_float
prerr_int
prerr_newline
prerr_string
print_char
print_endline
print_float
print_int
print_newline
print_string
raise
read_float
read_int
read_line
really_input
ref
seek_in
seek_out
set_binary_mode_in
set_binary_mode_out
sin
sinh
snd
sqrt
stderr
stdin
stdout
string_of_bool
string_of_float
string_of_format
string_of_int
succ
tan
tanh
truncate
unsafe_really_input
valid_float_lexem
||
~
~+
~+.
~-
~-.

View file

@ -1,580 +0,0 @@
*agent*
*allow-unresolved-vars*
*assert*
*clojure-version*
*command-line-args*
*compile-files*
*compile-path*
*compiler-options*
*data-readers*
*default-data-reader-fn*
*err*
*file*
*flush-on-newline*
*fn-loader*
*in*
*math-context*
*ns*
*out*
*print-dup*
*print-length*
*print-level*
*print-meta*
*print-readably*
*read-eval*
*source-path*
*unchecked-math*
*use-context-classloader*
*verbose-defrecords*
*warn-on-reflection*
->ArrayChunk
->Vec
->VecNode
->VecSeq
-cache-protocol-fn
-reset-methods
accessor
aclone
add-classpath
add-watch
agent
agent-error
agent-errors
aget
alength
alias
all-ns
alter
alter-meta!
alter-var-root
amap
ancestors
and
apply
areduce
array-map
as->
aset
aset-boolean
aset-byte
aset-char
aset-double
aset-float
aset-int
aset-long
aset-short
assert
assoc
assoc!
assoc-in
associative?
atom
await
await-for
await1
bases
bean
bigdec
bigint
biginteger
binding
bit-and
bit-and-not
bit-clear
bit-flip
bit-not
bit-or
bit-set
bit-shift-left
bit-shift-right
bit-test
bit-xor
boolean
boolean-array
booleans
bound-fn
bound-fn*
bound?
butlast
byte
byte-array
bytes
case
cast
char
char-array
char-escape-string
char-name-string
char?
chars
chunk
chunk-append
chunk-buffer
chunk-cons
chunk-first
chunk-next
chunk-rest
chunked-seq?
class
class?
clear-agent-errors
clojure-version
coll?
comment
commute
comp
comparator
compare
compare-and-set!
compile
complement
concat
cond
cond->
cond->>
condp
conj
conj!
cons
constantly
construct-proxy
contains?
count
counted?
create-ns
create-struct
cycle
dec
dec'
decimal?
declare
default-data-readers
definline
definterface
defmacro
defmethod
defmulti
defn
defn-
defonce
defprotocol
defrecord
defstruct
deftype
delay
delay?
deliver
denominator
deref
derive
descendants
destructure
disj
disj!
dissoc
dissoc!
distinct
distinct?
doall
doc
dorun
doseq
dosync
dotimes
doto
double
double-array
doubles
drop
drop-last
drop-while
dtype
empty
empty?
ensure
enumeration-seq
error-handler
error-mode
eval
even?
every-pred
every?
ex-data
ex-info
extend
extend-class
extend-protocol
extend-type
extenders
extends?
false?
ffirst
file-seq
filter
filterv
find
find-doc
find-keyword
find-ns
find-protocol-impl
find-protocol-method
find-var
first
flatten
float
float-array
float?
floats
flush
fn
fn?
fnext
fnil
for
force
format
frequencies
future
future-call
future-cancel
future-cancelled?
future-done?
future?
gen-class
gen-interface
gensym
get
get-in
get-method
get-proxy-class
get-thread-bindings
get-validator
group-by
hash
hash-combine
hash-map
hash-set
identical?
identity
if-let
if-not
ifn?
import
in-ns
inc
inc'
init-proxy
instance?
int
int-array
integer?
interleave
intern
interpose
into
into-array
ints
io!
isa?
iterate
iterator-seq
juxt
keep
keep-indexed
key
keys
keyword
keyword?
last
lazy-cat
lazy-seq
let
letfn
line-seq
list
list*
list?
load
load-file
load-reader
load-string
loaded-libs
locking
long
long-array
longs
loop
macroexpand
macroexpand-1
make-array
make-hierarchy
map
map-indexed
map?
mapcat
mapv
max
max-key
memfn
memoize
merge
merge-with
meta
method-sig
methods
min
min-key
mod
munge
name
namespace
namespace-munge
neg?
newline
next
nfirst
nil?
nnext
not
not-any?
not-empty
not-every?
not=
ns
ns-aliases
ns-imports
ns-interns
ns-map
ns-name
ns-publics
ns-refers
ns-resolve
ns-unalias
ns-unmap
nth
nthnext
nthrest
num
number?
numerator
object-array
odd?
or
parents
partial
partition
partition-all
partition-by
pcalls
peek
persistent!
pmap
pop
pop!
pop-thread-bindings
pos?
pr
pr-str
prefer-method
prefers
primitives-classnames
print
print-ctor
print-dup
print-method
print-namespace-doc
print-simple
print-str
printf
println
println-str
prn
prn-str
promise
proxy
proxy-call-with-super
proxy-mappings
proxy-name
proxy-super
push-thread-bindings
pvalues
quot
rand
rand-int
rand-nth
range
ratio?
rational?
rationalize
re-find
re-groups
re-matcher
re-matches
re-pattern
re-seq
read
read-line
read-string
realized?
reduce
reduce-kv
reduced
reduced?
reductions
ref
ref-history-count
ref-max-history
ref-min-history
ref-set
refer
refer-clojure
reify
release-pending-sends
rem
remove
remove-all-methods
remove-method
remove-ns
remove-watch
repeat
repeatedly
replace
replicate
require
reset!
reset-meta!
resolve
rest
restart-agent
resultset-seq
reverse
reversible?
rseq
rsubseq
satisfies?
second
select-keys
send
send-off
send-via
seq
seq?
seque
sequence
sequential?
set
set-agent-send-executor!
set-agent-send-off-executor!
set-error-handler!
set-error-mode!
set-validator!
set?
short
short-array
shorts
shuffle
shutdown-agents
slurp
some
some->
some->>
some-fn
sort
sort-by
sorted-map
sorted-map-by
sorted-set
sorted-set-by
sorted?
special-form-anchor
special-symbol?
spit
split-at
split-with
str
stream?
string?
struct
struct-map
subs
subseq
subvec
supers
swap!
symbol
symbol?
sync
syntax-symbol-anchor
take
take-last
take-nth
take-while
test
the-ns
thread-bound?
time
to-array
to-array-2d
trampoline
transient
tree-seq
true?
type
unchecked-add
unchecked-add-int
unchecked-byte
unchecked-char
unchecked-dec
unchecked-dec-int
unchecked-divide
unchecked-divide-int
unchecked-double
unchecked-float
unchecked-inc
unchecked-inc-int
unchecked-int
unchecked-long
unchecked-multiply
unchecked-multiply-int
unchecked-negate
unchecked-negate-int
unchecked-remainder
unchecked-remainder-int
unchecked-short
unchecked-subtract
unchecked-subtract-int
underive
unquote
unquote-splicing
update-in
update-proxy
use
val
vals
var-get
var-set
var?
vary-meta
vec
vector
vector-of
vector?
when
when-first
when-let
when-not
while
with-bindings
with-bindings*
with-in-str
with-loading-context
with-local-vars
with-meta
with-open
with-out-str
with-precision
with-redefs
with-redefs-fn
xml-seq
zero?
zipmap

View file

@ -1,475 +0,0 @@
*agent*
*clojure-version*
*command-line-args*
*compile-files*
*compile-path*
*err*
*file*
*flush-on-newline*
*in*
*ns*
*out*
*print-dup*
*print-length*
*print-level*
*print-meta*
*print-readably*
*read-eval*
*warn-on-reflection*
accessor
aclone
add-classpath
add-watch
agent
agent-error
agent-errors
aget
alength
alias
all-ns
alter
alter-meta!
alter-var-root
amap
ancestors
and
apply
areduce
array-map
aset
aset-boolean
aset-byte
aset-char
aset-double
aset-float
aset-int
aset-long
aset-short
assert
assoc
assoc!
assoc-in
associative?
atom
await
await-for
bases
bean
bigdec
bigint
binding
bit-and
bit-and-not
bit-clear
bit-flip
bit-not
bit-or
bit-set
bit-shift-left
bit-shift-right
bit-test
bit-xor
boolean
boolean-array
booleans
bound-fn
bound-fn*
butlast
byte
byte-array
bytes
case
cast
char
char-array
char-escape-string
char-name-string
char?
chars
class
class?
clear-agent-errors
clojure-version
coll?
comment
commute
comp
comparator
compare
compare-and-set!
compile
complement
concat
cond
condp
conj
conj!
cons
constantly
construct-proxy
contains?
count
counted?
create-ns
create-struct
cycle
dec
decimal?
declare
definline
defmacro
defmethod
defmulti
defn
defn-
defonce
defprotocol
defstruct
deftype
delay
delay?
deliver
deref
derive
descendants
disj
disj!
dissoc
dissoc!
distinct
distinct?
doall
doc
dorun
doseq
dosync
dotimes
doto
double
double-array
doubles
drop
drop-last
drop-while
dtype
empty
empty?
ensure
enumeration-seq
error-handler
error-mode
eval
even?
every?
extend
extend-class
extend-protocol
extend-type
extenders
extends?
false?
ffirst
file-seq
filter
find
find-doc
find-ns
find-var
first
float
float-array
float?
floats
flush
fn
fn?
fnext
for
force
format
future
future-call
future-cancel
future-cancelled?
future-done?
future?
gen-class
gen-interface
gensym
get
get-in
get-method
get-proxy-class
get-thread-bindings
get-validator
hash
hash-map
hash-set
identical?
identity
if-let
if-not
ifn?
import
in-ns
inc
init-proxy
instance?
int
int-array
integer?
interleave
intern
interpose
into
into-array
ints
io!
isa?
iterate
iterator-seq
juxt
key
keys
keyword
keyword?
last
lazy-cat
lazy-seq
let
letfn
line-seq
list
list*
list?
load
load-file
load-reader
load-string
loaded-libs
locking
long
long-array
longs
loop
macroexpand
macroexpand-1
make-array
make-hierarchy
map
map?
mapcat
max
max-key
memfn
memoize
merge
merge-with
meta
methods
min
min-key
mod
name
namespace
neg?
newline
next
nfirst
nil?
nnext
not
not-any?
not-empty
not-every?
not=
ns
ns-aliases
ns-imports
ns-interns
ns-map
ns-name
ns-publics
ns-refers
ns-resolve
ns-unalias
ns-unmap
nth
nthnext
num
number?
object-array
odd?
or
parents
partial
partition
pcalls
peek
persistent!
pmap
pop
pop!
pop-thread-bindings
pos?
pr
pr-str
prefer-method
prefers
print
print-namespace-doc
print-str
printf
println
println-str
prn
prn-str
promise
proxy
proxy-mappings
proxy-super
push-thread-bindings
pvalues
quot
rand
rand-int
range
ratio?
rationalize
re-find
re-groups
re-matcher
re-matches
re-pattern
re-seq
read
read-line
read-string
reduce
ref
ref-history-count
ref-max-history
ref-min-history
ref-set
refer
refer-clojure
reify
release-pending-sends
rem
remove
remove-method
remove-ns
remove-watch
repeat
repeatedly
replace
replicate
require
reset!
reset-meta!
resolve
rest
restart-agent
resultset-seq
reverse
reversible?
rseq
rsubseq
satisfies?
second
select-keys
send
send-off
seq
seq?
seque
sequence
sequential?
set
set-error-handler!
set-error-mode!
set-validator!
set?
short
short-array
shorts
shutdown-agents
slurp
some
sort
sort-by
sorted-map
sorted-map-by
sorted-set
sorted-set-by
sorted?
special-form-anchor
special-symbol?
split-at
split-with
str
stream?
string?
struct
struct-map
subs
subseq
subvec
supers
swap!
symbol
symbol?
sync
syntax-symbol-anchor
take
take-last
take-nth
take-while
test
the-ns
time
to-array
to-array-2d
trampoline
transient
tree-seq
true?
type
unchecked-add
unchecked-dec
unchecked-divide
unchecked-inc
unchecked-multiply
unchecked-negate
unchecked-remainder
unchecked-subtract
underive
update-in
update-proxy
use
val
vals
var-get
var-set
var?
vary-meta
vec
vector
vector-of
vector?
when
when-first
when-let
when-not
while
with-bindings
with-bindings*
with-in-str
with-local-vars
with-meta
with-open
with-out-str
with-precision
xml-seq
zero?
zipmap

View file

@ -1,278 +0,0 @@
# Generated by the following form.
# (loop for regexp in (append
# coq-solve-tactics
# coq-keywords
# coq-reserved
# coq-tactics
# coq-tacticals
# (list "Set" "Type" "Prop"))
# append (split-string regexp (regexp-quote "\\s-+")) into words
# finally (loop initially (goto-char (point-max))
# for word in (delete-dups (sort words 'string<))
# do (insert word) (newline)))
Abort
About
Abstract
Add
Admit
Admitted
All
Arguments
AutoInline
Axiom
Bind
Canonical
Cd
Chapter
Check
Close
CoFixpoint
CoInductive
Coercion
Coercions
Comments
Conjecture
Constant
Constructors
Corollary
Declare
Defined
Definition
Delimit
Dependent
Depth
Derive
End
Eval
Export
Extern
Extract
Extraction
Fact
False
Field
File
Fixpoint
Focus
Function
Functional
Goal
Hint
Hypotheses
Hypothesis
Hyps
Identity
If
Immediate
Implicit
Import
Inductive
Infix
Inline
Inlined
Inspect
Inversion
Language
Lemma
Let
Library
Limit
LoadPath
Local
Locate
Ltac
ML
Module
Morphism
Next Obligation
NoInline
Notation
Notations
Obligation
Obligations
Off
On
Opaque
Open
Optimize
Parameter
Parameters
Path
Print
Printing
Program
Proof
Prop
Pwd
Qed
Rec
Record
Recursive
Remark
Remove
Require
Reserved
Reset
Resolve
Rewrite
Ring
Save
Scheme
Scope
Search
SearchAbout
SearchPattern
SearchRewrite
Section
Semi
Set
Setoid
Show
Solve
Sort
Strict
Structure
Synth
Tactic
Test
Theorem
Time
Transparent
True
Type
Undo
Unfocus
Unfold
Unset
Variable
Variables
Width
Wildcard
abstract
absurd
after
apply
as
assert
assumption
at
auto
autorewrite
beta
by
case
cbv
change
clear
clearbody
cofix
coinduction
compare
compute
congruence
constructor
contradiction
cut
cutrewrite
decide
decompose
delta
dependent
dest
destruct
discrR
discriminate
do
double
eapply
eauto
econstructor
eexists
eleft
elim
else
end
equality
esplit
exact
exists
fail
field
first
firstorder
fix
fold
forall
fourier
fun
functional
generalize
hnf
idtac
if
in
induction
info
injection
instantiate
into
intro
intros
intuition
inversion
inversion_clear
iota
lapply
lazy
left
let
linear
load
match
move
omega
pattern
pose
progress
prolog
quote
record
red
refine
reflexivity
rename
repeat
replace
return
rewrite
right
ring
set
setoid
setoid_replace
setoid_rewrite
simpl
simple
simplify_eq
solve
specialize
split
split_Rabs
split_Rmult
stepl
stepr
struct
subst
sum
symmetry
tauto
then
transitivity
trivial
try
unfold
until
using
with
zeta

View file

@ -1,874 +0,0 @@
!important
@font-face
@font-feature-values
@keyframes
ActiveBorder
ActiveCaption
Alpha
AppWorkspace
Background
Barn
BasicImage
Blinds
Blur
ButtonFace
ButtonHighlight
ButtonShadow
ButtonText
CaptionText
CheckerBoard
Chroma
Compositor
CradientWipe
DXImageTransform
DropShadow
Emboss
Engrave
Fade
FlipH
FlipV
Glow
Gray
GrayText
Highlight
HighlightText
Hz
ICMFilter
InactiveBorder
InactiveCaption
InactiveCaptionText
InfoBackground
InfoText
Inset
Invert
Iris
Light
MaskFilter
Matrix
Menu
MenuText
Microsoft
MotionBlur
Pixelate
RadialWipe
RandomBars
RandomDissolve
RevealTrans
Scrollbar
Shadow
Slide
Spiral
Stretch
Strips
ThreeDDarkShadow
ThreeDFace
ThreeDHighlight
ThreeDLightShadow
ThreeDShadow
Wave
Wheel
Window
WindowFrame
WindowText
Xray
Zigzag
_azimuth
_background
_background-position-x
_background-position-y
_border
_bottom
_caption
_clear
_clip
_color
_content
_counter
_cue
_cursor
_direction
_display
_elevation
_empty
_filter
_filter:progid:DXImageTransform.Microsoft
_float
_font
_height
_ime
_ime-mode
_layout
_layout-flow
_layout-grid
_layout-grid-char
_layout-grid-line
_layout-grid-mode
_layout-grid-type
_left
_letter
_line
_line-break
_list
_margin
_orphans
_outline
_overflow
_overflow-x
_overflow-y
_padding
_page
_pause
_pitch
_play
_position
_quotes
_richness
_right
_ruby
_ruby-align
_ruby-overhang
_ruby-position
_scrollbar
_scrollbar-3dlight-color
_scrollbar-arrow-color
_scrollbar-base-color
_scrollbar-darkshadow-color
_scrollbar-face-color
_scrollbar-highlight-color
_scrollbar-track-color
_speak
_speech
_stress
_table
_text
_text-align-last
_text-autospace
_text-justify
_text-kashida-space
_text-overflow
_text-underline-position
_top
_unicode
_vertical
_visibility
_voice
_volume
_white
_widows
_width
_word
_word-break
_word-wrap
_writing
_writing-mode
_z
_zoom
above
active
adjust
after
aliceblue
align
align-content
align-items
align-self
always
animation
animation-delay
animation-direction
animation-duration
animation-fill-mode
animation-iteration-count
animation-name
animation-play-state
animation-timing-function
antiquewhite
aqua
aquamarine
armenian
arrow
attachment
auto
autospace
avoid
azimuth
azure
backface-visibility
background
background-attachment
background-clip
background-color
background-image
background-origin
background-position
background-repeat
background-size
bar
base
baseline
before
behind
beige
below
bidi
bidi-override
bisque
black
blanchedalmond
blink
block
blue
blueviolet
bold
bolder
border
border-bottom
border-bottom-color
border-bottom-left-radius
border-bottom-right-radius
border-bottom-style
border-bottom-width
border-collapse
border-color
border-image
border-image-outset
border-image-repeat
border-image-slice
border-image-source
border-image-width
border-left
border-left-color
border-left-style
border-left-width
border-radius
border-right
border-right-color
border-right-style
border-right-width
border-spacing
border-style
border-top
border-top-color
border-top-left-radius
border-top-right-radius
border-top-style
border-top-width
border-width
both
bottom
box
box-decoration-break
box-shadow
box-sizing
break
break-after
break-before
break-inside
brown
burlwood
cadetblue
capitalize
caps
caption
caption-side
cell
cells
center
center-left
center-right
char
chartreuse
chocolate
circle
cjk
cjk-ideographic
clear
clip
close
close-quote
cm
code
collapse
color
column
column-count
column-fill
column-gap
column-rule
column-rule-color
column-rule-style
column-rule-width
column-span
column-width
columns
compact
condensed
content
continuous
coral
cornflowerblue
cornsilk
counter
counter-increment
counter-reset
crimson
crop
cross
crosshair
cue
cue-after
cue-before
cursive
cursor
cyan
darkblue
darkcyan
darkgoldenrod
darkgray
darkgreen
darkkhaki
darkmagenta
darkolivegreen
darkorange
darkorchid
darkred
darksalmon
darkseagreen
darkshadow
darkslateblue
darkslategray
darkturquoise
darkviolet
dashed
decimal
decimal-leading-zero
decoration
deeppink
deepskyblue
default
deg
digits
dimgray
direction
disc
display
dodgerblue
dotted
double
during
e
e-resize
elevation
em
embed
empty
empty-cells
ex
expanded
extra
extra-condensed
extra-expanded
face
family
fantasy
far
far-left
far-right
fast
faster
filter
firebrick
first
first-child
first-letter
first-line
fixed
flex
flex-basis
flex-direction
flex-flow
flex-grow
flex-shrink
flex-wrap
float
floralwhite
flow
focus
font
font-family
font-feature-setting
font-kerning
font-language-override
font-size
font-size-adjust
font-stretch
font-style
font-synthesis
font-variant
font-variant-alternates
font-variant-caps
font-variant-east-asian
font-variant-ligatures
font-variant-numeric
font-variant-position
font-weight
footer
forestgreen
fuchsia
gainsboro
georgian
ghostwhite
gold
goldenrod
gray
greek
green
greenyellow
grid
groove
group
hanging-punctuation
header
hebrew
height
help
hidden
hide
high
higher
hiragana
hiragana-iroha
honeydew
hotpink
hover
hyphens
icon
ideographic
image
image-orientation
image-rendering
image-resolution
ime-mode
in
increment
indent
index
indianred
indigo
inherit
inline
inline-block
inline-table
inset
inside
iroha
italic
item
ivory
justify
justify-content
kHz
kashida
katakana
katakana-iroha
khaki
landscape
lang()
large
larger
last
latin
lavender
lavenderblush
lawngreen
layout
leading
left
left-side
leftwards
lenonchiffon
letter
letter-spacing
level
lightblue
lightcoral
lightcyan
lighter
lightgoldenrodyellow
lightgray
lightgreen
lightgrey
lightpink
lightsalmon
lightseagreen
lightskyblue
lightslategray
lightsteelblue
lightyellow
lime
limegreen
line
line-break
line-height
line-through
linen
link
list
list-item
list-style
list-style-image
list-style-position
list-style-type
loud
low
lower
lower-alpha
lower-greek
lower-latin
lower-roman
lowercase
ltr
magenta
margin
margin-bottom
margin-left
margin-right
margin-top
mark
mark-after
mark-before
marker
marker-offset
marks
maroon
marquee-direction
marquee-play-count
marquee-speed
marquee-style
mask
mask-type
max
max-height
max-width
medium
mediumaquamarine
mediumblue
mediumorchid
mediumpurple
mediumseagreen
mediumslateblue
mediumspringgreen
mediumturquoise
mediumvioletred
menu
message
message-box
middle
midnightblue
min
min-height
min-width
mintcream
mistyrose
mix
mm
moccasin
mode
monospace
move
ms
n
n-resize
naby
narrower
nav-down
nav-index
nav-left
nav-right
nav-up
navajowhite
ne
ne-resize
no
no-close-quote
no-open-quote
no-repeat
none
normal
nowrap
number
numeral
nw
nw-resize
object-fit
object-position
oblique
offset
oldlace
olive
olivedrab
once
opacity
open
open-quote
orange
orangered
orchid
order
orphans
out
outline
outline-color
outline-offset
outline-style
outline-width
outset
outside
overflow
overflow-wrap
overflow-x
overflow-y
overhang
overline
override
padding
padding-bottom
padding-left
padding-right
padding-top
page
page-break-after
page-break-before
page-break-inside
palegoldenrod
palegreen
paleturquoise
palevioletred
papayawhip
pause
pause-after
pause-before
pc
peachpuff
perspective
perspective-origin
peru
phonemes
pink
pitch
pitch-range
play
play-during
plum
pointer
portrait
position
powderblue
pre
pre-line
pre-wrap
progid
progress
pt
punctuation
purple
px
quote
quotes
rad
range
rate
red
relative
repeat
repeat-x
repeat-y
reset
resize
rest
rest-after
rest-before
richness
ridge
right
right-side
rightwards
roman
rosybrown
row
royalblue
rtl
run
run-in
s
s-resize
saddlebrown
salmon
sandybrown
sans-serif
scroll
se
se-resize
seagreen
seashell
semi
semi-condensed
semi-expanded
separate
serif
shadow
show
side
sienna
silent
silever
silver
size
skyblue
slateblue
slategray
slow
slower
small
small-caps
small-caption
smaller
snow
soft
solid
space
spacing
speak
speak-header
speak-numeral
speak-punctuation
specific
specific-voice
speech
speech-rate
spell
spell-out
springgreen
square
static
status
status-bar
steelblue
stress
stretch
style
sub
super
sw
sw-resize
tab-size
table
table-caption
table-cell
table-column
table-column-group
table-footer-group
table-header-group
table-layout
table-row
table-row-group
tan
teal
text
text-align
text-align-last
text-bottom
text-combine-horizontal
text-decoration
text-decoration-color
text-decoration-line
text-decoration-style
text-indent
text-justify
text-orientation
text-overflow
text-shadow
text-top
text-transform
text-underline-position
thick
thin
thistle
through
tomato
top
track
transform
transform-origin
transform-style
transition
transition-delay
transition-duration
transition-property
transition-timing-function
transparent
turquoise
type
ultra
ultra-condensed
ultra-expanded
underline
unicode
unicode-bidi
upper
upper-alpha
upper-latin
upper-roman
uppercase
variant
vertical
vertical-align
violet
visibility
visible
visited
voice
voice-balance
voice-duration
voice-family
voice-pitch
voice-pitch-range
voice-rate
voice-stress
voice-volume
volume
w
w-resize
wait
weight
wheat
white
white-space
whitesmoke
wider
widows
width
word
word-break
word-spacing
word-wrap
wrap
writing-mode
x
x-fast
x-high
x-large
x-loud
x-low
x-slow
x-small
x-soft
xx
xx-large
xx-small
y
yellow
yellowgreen
z
z-index
zero

View file

@ -1,216 +0,0 @@
after
begin
catch
case
cond
end
fun
if
let
of
query
receive
try
when
and
andalso
band
bnot
bor
bsl
bsr
bxor
div
not
or
orelse
rem
xor
is_atom
is_binary
is_bitstring
is_boolean
is_float
is_function
is_integer
is_list
is_number
is_pid
is_port
is_record
is_reference
is_tuple
atom
binary
bitstring
boolean
function
integer
list
number
pid
port
record
reference
tuple
abs
adler32
adler32_combine
alive
apply
atom_to_binary
atom_to_list
binary_to_atom
binary_to_existing_atom
binary_to_list
binary_to_term
bit_size
bitstring_to_list
byte_size
check_process_code
contact_binary
crc32
crc32_combine
date
decode_packet
delete_module
disconnect_node
element
erase
exit
float
float_to_list
garbage_collect
get
get_keys
group_leader
halt
hd
integer_to_list
internal_bif
iolist_size
iolist_to_binary
is_alive
is_atom
is_binary
is_bitstring
is_boolean
is_float
is_function
is_integer
is_list
is_number
is_pid
is_port
is_process_alive
is_record
is_reference
is_tuple
length
link
list_to_atom
list_to_binary
list_to_bitstring
list_to_existing_atom
list_to_float
list_to_integer
list_to_pid
list_to_tuple
load_module
make_ref
module_loaded
monitor_node
node
node_link
node_unlink
nodes
notalive
now
open_port
pid_to_list
port_close
port_command
port_connect
port_control
pre_loaded
process_flag
process_info
processes
purge_module
put
register
registered
round
self
setelement
size
spawn
spawn_link
spawn_monitor
spawn_opt
split_binary
statistics
term_to_binary
time
throw
tl
trunc
tuple_size
tuple_to_list
unlink
unregister
whereis
append_element
bump_reductions
cancel_timer
demonitor
display
fun_info
fun_to_list
function_exported
get_cookie
get_stacktrace
hash
integer_to_list
is_builtin
list_to_integer
loaded
localtime
localtime_to_universaltime
make_tuple
max
md5
md5_final
md5_init
md5_update
memory
min
monitor
monitor_node
phash
phash2
port_call
port_info
port_to_list
ports
process_display
read_timer
ref_to_list
resume_process
send
send_after
send_nosuspend
set_cookie
start_timer
suspend_process
system_flag
system_info
system_monitor
system_profile
trace
trace_delivered
trace_info
trace_pattern
universaltime
universaltime_to_localtime
yield

View file

@ -1,37 +0,0 @@
abstract
break
case
catch
const
continue
do
else
elseif
end
eval
export
false
finally
for
function
global
if
ifelse
immutable
import
importall
in
let
macro
module
otherwise
quote
return
switch
throw
true
try
type
typealias
using
while

View file

@ -1,25 +0,0 @@
break
case
chan
const
continue
default
defer
else
fallthrough
for
func
go
goto
if
import
interface
map
package
range
return
select
struct
switch
type
var

View file

@ -1,679 +0,0 @@
Arrows
BangPatterns
Bool
Bounded
CPP
Char
Complex
ConstrainedClassMethods
Control.Applicative
Control.Arrow
Control.Category
Control.Concurrent
Control.Concurrent.MVar
Control.Concurrent.QSem
Control.Concurrent.QSemN
Control.Concurrent.STM
Control.Concurrent.STM.TArray
Control.Concurrent.STM.TChan
Control.Concurrent.STM.TMVar
Control.Concurrent.STM.TVar
Control.Concurrent.SampleVar
Control.Exception
Control.Exception.Base
Control.Monad
Control.Monad.Cont
Control.Monad.Cont.Class
Control.Monad.Error
Control.Monad.Error.Class
Control.Monad.Fix
Control.Monad.Identity
Control.Monad.Instances
Control.Monad.List
Control.Monad.RWS
Control.Monad.RWS.Class
Control.Monad.RWS.Lazy
Control.Monad.RWS.Strict
Control.Monad.Reader
Control.Monad.Reader.Class
Control.Monad.ST
Control.Monad.ST.Lazy
Control.Monad.ST.Strict
Control.Monad.STM
Control.Monad.State
Control.Monad.State.Class
Control.Monad.State.Lazy
Control.Monad.State.Strict
Control.Monad.Trans
Control.Monad.Writer
Control.Monad.Writer.Class
Control.Monad.Writer.Lazy
Control.Monad.Writer.Strict
Control.OldException
Control.Parallel
Control.Parallel.Strategies
DEPRECATED
Data.Array
Data.Array.Diff
Data.Array.IArray
Data.Array.IO
Data.Array.IO.Internals
Data.Array.MArray
Data.Array.Paralell
Data.Array.Paralell.Arr
Data.Array.Paralell.Base
Data.Array.Paralell.Int
Data.Array.Paralell.Lifted
Data.Array.Paralell.PArray
Data.Array.Paralell.Prelude
Data.Array.Paralell.Prelude.Double
Data.Array.Paralell.Stream
Data.Array.Paralell.Unlifted
Data.Array.Paralell.Unlifted.Distributed
Data.Array.Paralell.Unlifted.Paralell
Data.Array.Paralell.Unlifted.Sqeuential
Data.Array.Paralell.Word8
Data.Array.ST
Data.Array.Storable
Data.Array.Unboxed
Data.Bits
Data.Bool
Data.ByteString
Data.ByteString.Char8
Data.ByteString.Fusion
Data.ByteString.Internal
Data.ByteString.Lazy
Data.ByteString.Lazy.Char8
Data.ByteString.Lazy.Fusion
Data.ByteString.Lazy.Internal
Data.ByteString.Unsafe
Data.Char
Data.Complex
Data.Data
Data.Dynamic
Data.Either
Data.Eq
Data.Fixed
Data.Foldable
Data.Function
Data.Generics
Data.Generics.Aliases
Data.Generics.Basics
Data.Generics.Instances
Data.Generics.Schemes
Data.Generics.Text
Data.Generics.Twins
Data.Graph
Data.HashTable
Data.IORef
Data.Int
Data.IntMap
Data.IntSet
Data.Ix
Data.List
Data.Map
Data.Maybe
Data.Monoid
Data.Ord
Data.Ratio
Data.STRef
Data.STRef.Lazy
Data.STRef.Strict
Data.Sequence
Data.Set
Data.String
Data.Time
Data.Time.Calendar
Data.Time.Calendar.Easter
Data.Time.Calendar.Julian
Data.Time.Calendar.MonthDay
Data.Time.Calendar.OrdinalDate
Data.Time.Calendar.WeekDate
Data.Time.Clock
Data.Time.Clock.POSIX
Data.Time.Clock.TAI
Data.Time.Format
Data.Time.LocalTime
Data.Traversable
Data.Tree
Data.Tuple
Data.Typeable
Data.Unique
Data.Version
Data.Word
Debug.Trace
DeriveDataTypeable
DisambiguateRecordFields
Distribution.Compat.ReadP
Distribution.Compiler
Distribution.InstalledPackageInfo
Distribution.License
Distribution.Make
Distribution.ModuleName
Distribution.Package
Distribution.PackageDescription
Distribution.PackageDescription.Check
Distribution.PackageDescription.Configuration
Distribution.PackageDescription.Parse
Distribution.ParseUtils
Distribution.ReadE
Distribution.Simple
Distribution.Simple.Build
Distribution.Simple.Build.Macros
Distribution.Simple.Build.PathsModule
Distribution.Simple.BuildPaths
Distribution.Simple.Command
Distribution.Simple.Compiler
Distribution.Simple.Configure
Distribution.Simple.GHC
Distribution.Simple.Haddock
Distribution.Simple.Hugs
Distribution.Simple.Install
Distribution.Simple.InstallDirs
Distribution.Simple.JHC
Distribution.Simple.LocalBuildInfo
Distribution.Simple.NHC
Distribution.Simple.PackageIndex
Distribution.Simple.PreProcess
Distribution.Simple.PreProcess.Unlit
Distribution.Simple.Program
Distribution.Simple.Register
Distribution.Simple.Setup
Distribution.Simple.SrcDist
Distribution.Simple.UserHooks
Distribution.Simple.Utils
Distribution.System
Distribution.Text
Distribution.Verbosity
Distribution.Version
Double
EQ
Either
EmptyDataDecls
Enum
Eq
ExistentialQuantification
ExtendedDefaultRules
False
FilePath
FlexibleContexts
FlexibleInstances
Float
Floating
Foreign
Foreign.C
Foreign.C.Error
Foreign.C.String
Foreign.C.Types
Foreign.Concurrent
Foreign.ForeignPtr
Foreign.Marshal
Foreign.Marshal.Alloc
Foreign.Marshal.Array
Foreign.Marshal.Error
Foreign.Marshal.Pool
Foreign.Marshal.Utils
Foreign.Ptr
Foreign.StablePtr
Foreign.Storable
ForeignFunctionInterface
Fractional
FunctionnalDependencies
Functor
GADTs
GHC.Arr
GHC.Bool
GHC.Conc
GHC.ConsoleHandler
GHC.Desugar
GHC.Environment
GHC.Err
GHC.Exts
GHC.Generics
GHC.Handle
GHC.Ordering
GHC.PArr
GHC.Prim
GHC.PrimopWrappers
GHC.Tuple
GHC.Types
GHC.Unicode
GHC.Unit
GT
GeneralizedNewtypeDeriving
Generics
INCLUDE
INLINE
IO
IOError
IOException
ImplicitParams
ImplicitPrelude
ImpredicativeTypes
IncoherentInstances
Int
Integer
Integral
Just
KindSignatures
LANGUAGE
LINE
LT
Language.Haskell.Extension
Language.Haskell.Lexer
Language.Haskell.ParseMonad
Language.Haskell.ParseUtils
Language.Haskell.Parser
Language.Haskell.Pretty
Language.Haskell.Syntax
Language.Haskell.TH
Language.Haskell.TH.Lib
Language.Haskell.TH.Ppr
Language.Haskell.TH.PprLib
Language.Haskell.TH.Quote
Language.Haskell.TH.Syntax
Left
LiberalTypeSynonyms
MagicHash
Maybe
Monad
MonoPatBinds
MonomorphismRestriction
MultiParamTypeClasses
NOINLINE
NamedFieldPuns
Network
Network.BSD
Network.Socket
Network.URI
NewQualifiedOperators
NoArrows
NoBangPatterns
NoCPP
NoConstrainedClassMethods
NoDeriveDataTypeable
NoDisambiguateRecordFields
NoEmptyDataDecls
NoExistentialQuantification
NoExtendedDefaultRules
NoFlexibleContexts
NoFlexibleInstances
NoForeignFunctionInterface
NoFunctionnalDependencies
NoGADTs
NoGeneralizedNewtypeDeriving
NoGenerics
NoImplicitParams
NoImplicitPrelude
NoImpredicativeTypes
NoIncoherentInstances
NoKindSignatures
NoLiberalTypeSynonyms
NoMagicHash
NoMonoPatBinds
NoMonomorphismRestriction
NoMultiParamTypeClasses
NoNamedFieldPuns
NoNewQualifiedOperators
NoOverlappingInstances
NoOverloadedStrings
NoPArr
NoPackageImports
NoParallelListComp
NoPatternGuards
NoPolymorphicComponents
NoQuasiQuotes
NoRank2Types
NoRankNTypes
NoRecordWildCards
NoRecursiveDo
NoRelaxedPolyRec
NoScopedTypeVariables
NoStandaloneDeriving
NoTemplateHaskell
NoTransformListComp
NoTypeFamilies
NoTypeOperators
NoTypeSynonymInstances
NoUnboxedTuples
NoUndecidableInstances
NoUnicodeSyntax
NoUnliftedFFITypes
NoViewPatterns
Nothing
Num
Numeric
OPTIONS_GHC
Ord
Ordering
OverlappingInstances
OverloadedStrings
PArr
PackageImports
ParallelListComp
PatternGuards
PolymorphicComponents
Prelude
QuasiQuotes
RULES
Rank2Types
RankNTypes
Ratio
Read
ReadS
Real
RealFloat
RealFrac
RecordWildCards
RecursiveDo
RelaxedPolyRec
Right
SOURCE
SPECIALIZE
ScopedTypeVariables
ShowS
StandaloneDeriving
String
System.CPUTime
System.Cmd
System.Console.Editline
System.Console.GetOpt
System.Console.Readline
System.Directory
System.Environment
System.Exit
System.FilePath
System.FilePath.Posix
System.FilePath.Windows
System.IO
System.IO.Error
System.IO.Unsafe
System.Info
System.Locale
System.Mem
System.Mem.StableName
System.Mem.Weak
System.Posix
System.Posix.Directory
System.Posix.DynamicLinker
System.Posix.DynamicLinker.Module
System.Posix.DynamicLinker.Prim
System.Posix.Env
System.Posix.Error
System.Posix.Files
System.Posix.IO
System.Posix.Process
System.Posix.Process.Internals
System.Posix.Resource
System.Posix.Semaphore
System.Posix.SharedMem
System.Posix.Signals
System.Posix.Signals.Exts
System.Posix.Temp
System.Posix.Terminal
System.Posix.Time
System.Posix.Types
System.Posix.Unistd
System.Posix.User
System.Process
System.Random
System.Time
System.Timeout
TemplateHaskell
Test.HUnit
Test.HUnit.Base
Test.HUnit.Lang
Test.HUnit.Terminal
Test.HUnit.Text
Test.QuickCheck
Test.QuickCheck.Batch
Test.QuickCheck.Poly
Test.QuickCheck.Utils
Text.Html
Text.Html.BlockTable
Text.ParserCombinators.Parsec
Text.ParserCombinators.Parsec.Char
Text.ParserCombinators.Parsec.Combinator
Text.ParserCombinators.Parsec.Error
Text.ParserCombinators.Parsec.Expr
Text.ParserCombinators.Parsec.Language
Text.ParserCombinators.Parsec.Perm
Text.ParserCombinators.Parsec.Pos
Text.ParserCombinators.Parsec.Prim
Text.ParserCombinators.Parsec.Token
Text.ParserCombinators.ReadP
Text.ParserCombinators.ReadPrec
Text.PrettyPrint
Text.PrettyPrint.HughesPJ
Text.Printf
Text.Read
Text.Read.Lex
Text.Regex.Base
Text.Regex.Base.Context
Text.Regex.Base.Impl
Text.Regex.Base.RegexLike
Text.Regex.Posix
Text.Regex.Posix.ByteString
Text.Regex.Posix.String
Text.Regex.Posix.Wrap
Text.Show
Text.Show.Functions
Text.XHtml
Text.XHtml.Debug
Text.XHtml.Frameset
Text.XHtml.Strict
Text.XHtml.Table
Text.XHtml.Transitional
Trace.Hpc.Mix
Trace.Hpc.Reflect
Trace.Hpc.Tix
Trace.Hpc.Util
TransformListComp
True
TypeFamilies
TypeOperators
TypeSynonymInstances
UNPACK
UnboxedTuples
UndecidableInstances
UnicodeSyntax
UnliftedFFITypes
Unsafe.Coerce
ViewPatterns
WARNING
abs
acos
acosh
all
and
any
appendFile
as
asTypeOf
asin
asinh
atan
atan2
atanh
break
case
catch
ceiling
class
compare
concat
concatMap
const
cos
cosh
curry
cycle
data
decodeFloat
default
deriving
div
divMod
do
drop
dropWhile
either
elem
else
encodeFloat
enumFrom
enumFromThen
enumFromThenTo
enumFromTo
error
exp
exponent
fail
filter
flip
floatDigits
floatRadix
floatRange
floor
fmap
fold
fold1
foldr
foldr1
fromEnum
fromInteger
fromIntegral
fromRational
fst
gcd
getChar
getContents
getLine
head
hiding
id
if
import
in
infix
infixl
infixr
init
instance
intract
ioError
isDenormalized
isIEEE
isInfinite
isNan
isNegativeZero
iterate
last
lcm
length
let
lex
lines
log
logBase
lookup
map
mapM
mapM_
max
maxBound
maximum
maybe
min
minBound
minimum
mod
module
negate
newtype
not
notElem
null
odd
of
or
otherwise
pi
pred
print
product
properFraction
putChar
putStr
putStrLn
qualified
quot
quotRem
read
readFile
readIO
readList
readLn
readParen
reads
readsPrec
realtoFrac
recip
rem
repeat
replicate
return
reverse
round
scaleFloat
scanl
scanl1
scanr
scanr1
seq
sequence
sequence_
show
showChar
showList
showParen
showString
shows
showsPrec
significand
signum
sin
sinh
snd
span
splitAt
sqrt
subtract
succ
sum
tail
take
takeWhile
tan
tanh
then
toEnum
toInteger
toRational
truncate
type
uncurry
undefined
unlines
until
unwords
unzip
unzip3
userError
where
words
writeFile
zip
zip3
zipWith
zipWith3

View file

@ -1,53 +0,0 @@
abstract
assert
boolean
break
byte
case
catch
char
class
const
continue
default
do
double
else
enum
extends
final
finally
float
for
goto
if
implements
import
instanceof
int
interface
long
native
new
package
private
protected
public
return
short
static
strictfp
super
switch
synchronized
this
throw
throws
transient
try
void
volatile
while
@Override
@Deprecated
@SuppressWarnings

View file

@ -1,148 +0,0 @@
Anchor
Area
Array
Boolean
Button
Checkbox
Date
Document
Element
FileUpload
Form
Frame
Function
Hidden
History
Image
Infinity
JavaArray
JavaClass
JavaObject
JavaPackage
Link
Location
Math
MimeType
NaN
Navigator
Number
Object
Option
Packages
Password
Plugin
Radio
RegExp
Reset
Select
String
Submit
Text
Textarea
Window
alert
arguments
assign
blur
break
callee
caller
captureEvents
case
clearInterval
clearTimeout
close
closed
comment
confirm
constructor
continue
default
defaultStatus
delete
do
document
else
escape
eval
export
find
focus
for
frames
function
getClass
history
home
if
import
in
innerHeight
innerWidth
isFinite
isNan
java
label
length
location
locationbar
menubar
moveBy
moveTo
name
navigate
navigator
netscape
new
onBlur
onError
onFocus
onLoad
onUnload
open
opener
outerHeight
outerWidth
pageXoffset
pageYoffset
parent
parseFloat
parseInt
personalbar
print
prompt
prototype
ref
releaseEvents
resizeBy
resizeTo
return
routeEvent
scroll
scrollBy
scrollTo
scrollbars
self
setInterval
setTimeout
status
statusbar
stop
sun
switch
taint
this
toString
toolbar
top
typeof
unescape
untaint
unwatch
valueOf
var
void
watch
while
window
with

View file

@ -1,37 +0,0 @@
abstract
break
case
catch
const
continue
do
else
elseif
end
eval
export
false
finally
for
function
global
if
ifelse
immutable
import
importall
in
let
macro
module
otherwise
quote
return
switch
throw
true
try
type
typealias
using
while

View file

@ -1,21 +0,0 @@
and
break
do
else
elseif
end
false
for
function
if
in
local
nil
not
or
repeat
return
then
true
until
while

View file

@ -1,70 +0,0 @@
addr
and
as
asm
atomic
bind
block
break
case
cast
concept
const
continue
converter
defer
discard
distinct
div
do
elif
else
end
enum
except
export
finally
for
from
func
generic
if
import
in
include
interface
is
isnot
iterator
let
macro
method
mixin
mod
nil
not
notin
object
of
or
out
proc
ptr
raise
ref
return
shl
shr
static
template
try
tuple
type
using
var
when
while
with
without
xor
yield

View file

@ -1,161 +0,0 @@
auto
break
case
char
const
continue
default
do
double
else
enum
extern
float
for
goto
if
inline
int
long
register
restrict
return
short
signed
sizeof
static
struct
switch
typedef
union
unsigned
void
volatile
while
_Alignas
_Alignof
_Atomic
_Bool
_Complex
_Generic
_Imaginary
_Noreturn
_Static_assert
_Thread_local
alignas
alignof
atomic_
bool
complex
imaginary
noreturn
static_assert
thread_local
#if
#elif
#else
#endif
defined
#ifdef
#ifndef
#define
#undef
#include
#line
#error
#pragma
_Pragma
asm
fortran
#import
self
_cmd
instancetype
__bridge
__bridge_transfer
__bridge_retained
__bridge_retain
@not_keyword
@class
@compatibility_alias
@defs
@encode
@end
@implementation
@interface
@private
@protected
@protocol
@public
@selector
@throw
@try
@catch
@finally
@synchronized
@autoreleasepool
@property
@package
@required
@optional
@synthesize
@dynamic
@import
@available
__attribute__((visibility("default")))
__attribute__((visibility("hidden")))
__attribute__((deprecated))
__attribute__((unavailable))
__attribute__((objc_exception))
__attribute__((objc_root_class))
__covariant
__contravariant
__kindof
getter=
setter=
readonly
readwrite
assign
retain
copy
nonatomic
atomic
strong
weak
unsafe_unretained
nonnull
nullable
null_unspecified
null_resettable
class
__attribute__((deprecated))
in
out
inout
oneway
bycopy
byref
nonnull
nullable
null_unspecified
__attribute__((unused))
super
true
false
__objc_yes
__objc_no
Class
id
SEL
IMP
BOOL
STR
NSInteger
NSUInteger
YES
NO
Nil
nil
__strong
__unsafe_unretained
__autoreleasing

View file

@ -1,46 +0,0 @@
# GNU Octave, and probably proprietary MATLAB
# https://www.gnu.org/software/octave/doc/interpreter/Keywords.html
__FILE__
__LINE__
break
case
catch
classdef
continue
do
else
elseif
end
end_try_catch
end_unwind_protect
endclassdef
endenumeration
endevents
endfor
endfunction
endif
endmethods
endparfor
endproperties
endswitch
endwhile
enumeration
events
for
function
global
if
methods
otherwise
parfor
persistent
properties
return
static
switch
try
unitl
unwind_protect
unwind_protect_cleanup
while

File diff suppressed because it is too large Load diff

View file

@ -1,379 +0,0 @@
ArithmeticError
AssertionError
AttributeError
BaseException
BufferError
BytesWarning
DeprecationWarning
EOFError
Ellipsis
EnvironmentError
Exception
False
FloatingPointError
FutureWarning
GeneratorExit
IOError
ImportError
ImportWarning
IndentationError
IndexError
KeyError
KeyboardInterrupt
LookupError
MemoryError
NameError
None
NotImplemented
NotImplementedError
OSError
OverflowError
PendingDeprecationWarning
ReferenceError
RuntimeError
RuntimeWarning
StandardError
StopIteration
SyntaxError
SyntaxWarning
SystemError
SystemExit
TabError
True
TypeError
UnboundLocalError
UnicodeDecodeError
UnicodeEncodeError
UnicodeError
UnicodeTranslateError
UnicodeWarning
UserWarning
ValueError
Warning
ZeroDivisionError
__builtins__
__debug__
__doc__
__file__
__future__
__import__
__init__
__main__
__name__
__package__
_dummy_thread
_thread
abc
abs
aifc
all
and
any
apply
argparse
array
as
assert
ast
asynchat
asyncio
asyncore
atexit
audioop
base64
basestring
bdb
bin
binascii
binhex
bisect
bool
break
buffer
builtins
bytearray
bytes
bz2
calendar
callable
cgi
cgitb
chr
chuck
class
classmethod
cmath
cmd
cmp
code
codecs
codeop
coerce
collections
colorsys
compile
compileall
complex
concurrent
configparser
contextlib
continue
copy
copyreg
copyright
credits
crypt
csv
ctypes
curses
datetime
dbm
decimal
def
del
delattr
dict
difflib
dir
dis
distutils
divmod
doctest
dummy_threading
elif
else
email
enumerate
ensurepip
enum
errno
eval
except
exec
execfile
exit
faulthandler
fcntl
file
filecmp
fileinput
filter
finally
float
fnmatch
for
format
formatter
fpectl
fractions
from
frozenset
ftplib
functools
gc
getattr
getopt
getpass
gettext
glob
global
globals
grp
gzip
hasattr
hash
hashlib
heapq
help
hex
hmac
html
http
id
if
imghdr
imp
impalib
import
importlib
in
input
inspect
int
intern
io
ipaddress
is
isinstance
issubclass
iter
itertools
json
keyword
lambda
len
license
linecache
list
locale
locals
logging
long
lzma
macpath
mailbox
mailcap
map
marshal
math
max
memoryview
mimetypes
min
mmap
modulefinder
msilib
msvcrt
multiprocessing
netrc
next
nis
nntplib
not
numbers
object
oct
open
operator
optparse
or
ord
os
ossaudiodev
parser
pass
pathlib
pdb
pickle
pickletools
pipes
pkgutil
platform
plistlib
poplib
posix
pow
pprint
print
profile
property
pty
pwd
py_compiler
pyclbr
pydoc
queue
quit
quopri
raise
random
range
raw_input
re
readline
reduce
reload
repr
reprlib
resource
return
reversed
rlcompleter
round
runpy
sched
select
selectors
self
set
setattr
shelve
shlex
shutil
signal
site
slice
smtpd
smtplib
sndhdr
socket
socketserver
sorted
spwd
sqlite3
ssl
stat
staticmethod
statistics
str
string
stringprep
struct
subprocess
sum
sunau
super
symbol
symtable
sys
sysconfig
syslog
tabnanny
tarfile
telnetlib
tempfile
termios
test
textwrap
threading
time
timeit
tkinter
token
tokenize
trace
traceback
tracemalloc
try
tty
tuple
turtle
type
types
unichr
unicode
unicodedata
unittest
urllib
uu
uuid
vars
venv
warnings
wave
weakref
webbrowser
while
winsound
winreg
with
wsgiref
xdrlib
xml
xmlrpc
xrange
yield
zip
zipfile
zipimport
zlib

View file

@ -1,183 +0,0 @@
AlignBottom
AlignCenter
AlignHCenter
AlignLeft
AlignRight
AlignTop
AlignVCenter
AnchorAnimation
AnchorChanges
Audio
Behavior
Binding
BorderImage
ColorAnimation
Column
Component
Connections
Easing
Flickable
Flipable
Flow
FocusScope
GestureArea
Grid
GridView
Horizontal
Image
InBack
InBounce
InCirc
InCubic
InElastic
InExpo
InOutBack
InOutBounce
InOutCirc
InOutCubic
InOutElastic
InOutExpo
InOutQuad
InOutQuart
InOutQuint
InQuad
InQuart
InQuint
InQuint
InSine
Item
LayoutItem
LeftButton
Linear
ListElement
ListModel
ListView
Loader
MidButton
MiddleButton
MouseArea
NoButton
NumberAnimation
OutBack
OutBounce
OutCirc
OutCubic
OutElastic
OutExpo
OutInBack
OutInBounce
OutInCirc
OutInCubic
OutInElastic
OutInExpo
OutInQuad
OutInQuart
OutInQuint
OutQuad
OutQuart
OutQuint
OutSine
Package
ParallelAnimation
ParentAnimation
ParentChange
ParticleMotionGravity
ParticleMotionLinear
ParticleMotionWander
Particles
Path
PathAttribute
PathCubic
PathLine
PathPercent
PathQuad
PathView
PauseAnimation
PropertyAction
PropertyAnimation
PropertyChanges
Qt
QtObject
Rectangle
Repeater
RightButton
Rotation
RotationAnimation
Row
Scale
ScriptAction
SequentialAnimation
SmoothedAnimation
SoundEffect
SpringFollow
State
StateChangeScript
StateGroup
SystemPalette
Text
TextEdit
TextInput
Timer
Transition
Translate
Vertical
Video
ViewsPositionersMediaEffects
VisualDataModel
VisualItemModel
WebView
WorkerScript
XmlListModel
XmlRole
alias
as
bool
break
case
catch
color
const
continue
date
debugger
default
delete
do
double
else
enum
false
false
finally
for
function
if
import
import
in
instanceof
int
let
new
null
on
parent
property
real
return
signal
string
switch
this
throw
true
try
typeof
undefined
url
var
variant
void
while
with
yield

View file

@ -1,181 +0,0 @@
$!
$"
$$
$&
$'
$*
$+
$,
$-0
$-F
$-I
$-K
$-a
$-d
$-i
$-l
$-p
$-v
$-w
$.
$/
$0
$1
$10
$11
$2
$3
$4
$5
$6
$7
$8
$9
$:
$;
$<
$=
$>
$?
$@
$DEBUG
$FILENAME
$KCODE
$LOADED_FEATURES
$LOAD_PATH
$PROGRAM_NAME
$SAFE
$VERBOSE
$\
$_
$`
$deferr
$defout
$stderr
$stdin
$stdout
$~
ARGF
ARGV
Array
BEGIN
DATA
END
ENV
FALSE
Float
Integer
NIL
PLATFORM
RELEASE_DATE
RUBY_COPYRIGHT
RUBY_DESCRIPTION
RUBY_PATCHLEVEL
RUBY_PLATFORM
RUBY_RELEASE_DATE
RUBY_VERSION
SCRIPT_LINES__
STDERR
STDIN
STDOUT
String
TOPLEVEL_BINDING
TRUE
VERSION
__method__
`
abort
alias
and
at_exit
autoload
autoload?
begin
binding
block_given
break
callcc
caller
case
catch
chomp
chomp!
chop
chop
class
def
defined?
do
else
elsif
end
ensure
eval
exec
exit
exit!
fail
false
for
fork
format
getc
gets
global_variables
gsub
gsub!
if
in
iterator?
lambda
load
local_variables
loop
module
next
nil
not
open
or
p
printf
proc
putc
puts
raise
rand
readline
readlines
redo
require
require_relative
rescue
retry
return
scan
select
self
set_trace_func
sleep
split
sprintf
srand
sub
sub!
super
syscall
system
test
then
throw
trace_var
trap
true
undef
unless
until
untrace_var
warn
when
while
yield

File diff suppressed because it is too large Load diff

View file

@ -1,216 +0,0 @@
case-lambda
call/cc
class
define-class
exit-handler
field
import
inherit
init-field
interface
let*-values
let-values
let/ec
mixin
opt-lambda
override
protect
provide
public
rename
require
require-for-syntax
syntax
syntax-case
syntax-error
unit/sig
unless
when
with-syntax
and
begin
call-with-current-continuation
call-with-input-file
call-with-output-file
case
cond
define
define-syntax
delay
do
dynamic-wind
else
for-each
if
lambda
let
let*
let-syntax
letrec
letrec-syntax
map
or
syntax-rules
abs
acos
angle
append
apply
asin
assoc
assq
assv
atan
boolean?
caar
cadr
call-with-input-file
call-with-output-file
call-with-values
car
cdddar
cddddr
cdr
ceiling
char->integer
char-alphabetic?
char-ci<=?
char-ci<?
char-ci=?
char-ci>=?
char-ci>?
char-downcase
char-lower-case?
char-numeric?
char-ready?
char-upcase
char-upper-case?
char-whitespace?
char<=?
char<?
char=?
char>=?
char>?
char?
close-input-port
close-output-port
complex?
cons
cos
current-input-port
current-output-port
denominator
display
eof-object?
eq?
equal?
eqv?
eval
even?
exact->inexact
exact?
exp
expt
#f
floor
force
gcd
imag-part
inexact->exact
inexact?
input-port?
integer->char
integer?
interaction-environment
lcm
length
list
list->string
list->vector
list-ref
list-tail
list?
load
log
magnitude
make-polar
make-rectangular
make-string
make-vector
max
member
memq
memv
min
modulo
negative?
newline
not
null-environment
null?
number->string
number?
numerator
odd?
open-input-file
open-output-file
output-port?
pair?
peek-char
port?
positive?
procedure?
quasiquote
quote
quotient
rational?
rationalize
read
read-char
real-part
real?
remainder
reverse
round
scheme-report-environment
set!
set-car!
set-cdr!
sin
sqrt
string
string->list
string->number
string->symbol
string-append
string-ci<=?
string-ci<?
string-ci=?
string-ci>=?
string-ci>?
string-copy
string-fill!
string-length
string-ref
string-set!
string<=?
string<?
string=?
string>=?
string>?
string?
substring
symbol->string
symbol?
#t
tan
transcript-off
transcript-on
truncate
values
vector
vector->list
vector-fill!
vector-length
vector-ref
vector-set!

File diff suppressed because it is too large Load diff

View file

@ -1,182 +0,0 @@
# Bash Family Shell Dictionary
# http://www.gnu.org/software/bash/manual/bash.html
.
:
[
alias
bg
bind
break
builtin
caller
cd
command
compgen
complete
compopt
continue
declare
dirs
disown
echo
enable
eval
exec
exit
export
fc
fg
getopts
hash
help
history
jobs
kill
let
local
logout
mapfile
popd
printf
pushd
pwd
read
readarray
readonly
return
set
shift
shopt
source
suspend
test
times
trap
type
typeset
ulimit
umask
unalias
unset
wait
!
[[
]]
case
do
done
elif
else
esac
fi
for
function
if
in
select
then
time
until
while
{
}
!
#
$
*
-
0
?
@
_
BASH
BASH_ALIASES
BASH_ARGC
BASH_ARGV
BASH_CMDS
BASH_COMMAND
BASH_ENV
BASH_EXECUTION_STRING
BASH_LINENO
BASH_REMATCH
BASH_SOURCE
BASH_SUBSHELL
BASH_VERSINFO
BASH_VERSION
BASH_XTRACEFD
BASHOPTS
BASHPID
CDPATH
COLUMNS
COMP_CWORD
COMP_KEY
COMP_LINE
COMP_POINT
COMP_TYPE
COMP_WORDBREAKS
COMP_WORDS
COMPREPLY
DIRSTACK
EMACS
EUID
FCEDIT
FIGNORE
FUNCNAME
GLOBIGNORE
GROUPS
HISTCMD
HISTCONTROL
HISTFILE
HISTFILESIZE
HISTIGNORE
HISTSIZE
HISTTIMEFORMAT
HOME
HOSTFILE
HOSTNAME
HOSTTYPE
IFS
IGNOREEOF
INPUTRC
LANG
LC_ALL
LC_COLLATE
LC_CTYPE
LC_MESSAGES
LC_MESSAGES
LC_NUMERIC
LINENO
LINES
MACHTYPE
MAIL
MAILCHECK
MAILPATH
OLDPWD
OPTARG
OPTERR
OPTIND
OSTYPE
PATH
PIPESTATUS
POSIXLY_CORRECT
PPID
PROMPT_COMMAND
PROMPT_DIRTRIM
PS1
PS2
PS3
PS4
PWD
RANDOM
REPLY
SECONDS
SHELL
SHELLOPTS
SHLVL
TEXTDOMAIN
TEXTDOMAINDIR
TIMEFORMAT
TMOUT
TMPDIR
UID

View file

@ -1,87 +0,0 @@
associatedtype
class
deinit
enum
extension
func
import
init
inout
let
operator
precedencegroup
protocol
struct
subscript
typealias
var
fileprivate
internal
private
public
static
undef
sil
sil_stage
sil_vtable
sil_global
sil_witness_table
sil_default_witness_table
sil_coverage_map
sil_scope
defer
if
guard
do
repeat
else
for
in
while
return
break
continue
fallthrough
switch
case
default
where
catch
as
Any
false
is
nil
rethrows
super
self
Self
throw
true
try
throws
__FILE__
__LINE__
__COLUMN__
__FUNCTION__
__DSO_HANDLE__
_
#if
#else
#elseif
#endif
#keyPath
#line
#sourceLocation
#selector
#available
#fileLiteral
#imageLiteral
#colorLiteral
#FileReference
#Image
#Color
#file
#column
#function
#dsohandle

View file

@ -1,172 +0,0 @@
after
append
apply
array
auto_execok
auto_import
auto_load
auto_load_index
auto_mkindex
auto_mkindex_old
auto_qualify
auto_reset
bell
binary
bind
bindtags
break
button
canvas
case
catch
cd
chan
checkbutton
clipboard
clock
close
concat
continue
destroy
dict
encoding
entry
eof
error
eval
event
exec
exit
expr
fblocked
fconfigure
fcopy
file
fileevent
flush
focus
font
for
foreach
format
frame
gets
glob
global
grab
grid
if
image
incr
info
interp
join
label
labelframe
lappend
lassign
lindex
linsert
list
listbox
llength
load
lower
lrange
lrepeat
lreplace
lreverse
lsearch
lset
lsort
menu
menubutton
message
namespace
open
option
pack
package
panedwindow
pid
pkg_mkIndex
place
proc
puts
pwd
radiobutton
raise
read
regexp
registry
regsub
rename
return
scale
scan
scrollbar
seek
selection
set
socket
source
spinbox
split
string
subst
switch
tclLog
tclPkgSetup
tclPkgUnknown
tcl_findLibrary
tell
text
time
tk
tk_chooseColor
tk_chooseDirectory
tk_getOpenFile
tk_getSaveFile
tk_menuSetFocus
tk_messageBox
tk_popup
tk_textCopy
tk_textCut
tk_textPaste
tkwait
toplevel
ttk::button
ttk::checkbutton
ttk::combobox
ttk::entry
ttk::focusFirst
ttk::frame
ttk::label
ttk::labelframe
ttk::menubutton
ttk::notebook
ttk::paned
ttk::panedwindow
ttk::progressbar
ttk::radiobutton
ttk::scale
ttk::scrollbar
ttk::separator
ttk::setTheme
ttk::sizegrip
ttk::style
ttk::takefocus
ttk::themes
ttk::treeview
trace
unknown
unload
unset
update
uplevel
upvar
variable
vwait
while
winfo
wm

View file

@ -1,797 +0,0 @@
absRefPrefix
accessibility
accessibilityWrap
accessKey
ACT
ACTIFSUB
ACTIVSUBRO
ACTRO
addAttributes
addExtUrlsAndShortCuts
additionalHeaders
additionalParams
addParams
addQueryString
addQueryString
adjustItemsH
adjustSubItemsH
adminPanelStyles
after
age
align
align.field
all
allowedAttribs
allowedGroups
allowEdit
allowNew
allowTags
allStdWrap
allWrap
alternativeSortingField
alternativeTempPath
altImgResource
altTarget
altText
alwaysActivePIDlist
alwaysLink
andWhere
angle
antiAlias
append
applyTotalH
applyTotalW
arrayReturnMode
arrowACT
arrowImgParams
arrowNO
ATagBeforeWrap
ATagParams
ATagTitle
atLeast
atMost
authcodeFields
autoInsertPID
autostart
backColor
badMess
base64
baseURL
beforeImg
beforeImgLink
beforeImgTagParams
beforeROImg
beforeWrap
begin
begin
beginAtLevel
beLoginLinkIPList
beLoginLinkIPList_login
beLoginLinkIPList_logout
beUserLogin
bgImg
blankStrEqFalse
blur
bm
bodyTag
bodyTag
bodyTagAdd
bodyTagCObject
bodyTagMargins
border
border
borderCol
bordersWithin
borderThick
bottomContent
bottomHeight
br
breakSpace
breakWidth
brTag
bytes
c
cache_clearAtMidnight
cached
cache_period
caption
captionAlign
captionSplit
case
case
CASE
casesensitiveComp
cellpadding
cellspacing
char
charcoal
clearCacheOfPages
cMargins
COA
COA_INT
cObject
cObjNum
code
collapse
color
color1
color2
color3
color.default
color.field
colRelations
cols
cols
colSpace
COLUMNS
COMMENT
commentWrap
compensateFieldWidth
compX
compY
concatenateJsAndCss
conf
config
config
CONFIG
constants
CONTENT
content_fallback
content_from_pid_allowOutsideDomain
controllerActionName
controllerExtensionName
controllerName
crop
cropHTML
csConv
cssInline
CSS_inlineStyle
CTABLE
CUR
CURIFSUB
CURIFSUBRO
current
CURRO
cWidth
data
dataArray
dataWrap
date
debug
debugData
debugFunc
debugItemConf
debugRenumberedObject
decimals
dec_point
default
defaultAlign
defaultCmd
defaultCode
defaultGetVars
delete
denyTags
depth
dimensions
directImageLink
directionLeft
directionUp
directReturn
disableAllHeaderCode
disableAltText
disableCharsetHeader
disableImgBorderAttr
disablePageExternalUrl
disablePrefixComment
disablePreviewNotification
displayActiveOnLoad
displayActiveOnLoad
displayrecord
distributeX
distributeY
doctype
doctypeSwitch
doNotLinkIt
doNotShowLink
doNotStripHTML
dontCheckPid
dontFollowMouse
dontHideOnMouseUp
dontLinkIfSubmenu
dontMd5FieldNames
dontWrapInTable
doubleBrTag
doublePostCheck
dWorkArea
edge
edit
editIcons
editIcons
editPanel
EDITPANEL
EDITPANEL
effects
email
emailMess
emboss
emptyTitleHandling
emptyTitleHandling
emptyTitleHandling
enable
enableContentLengthHeader
encapsLines
encapsLinesStdWrap
encapsTagList
entryLevel
equalH
equals
evalErrors
evalFunc
excludeDoktypes
excludeNoSearchPages
excludeUidList
expAll
explode
ext
extbase
externalBlocks
extOnReady
extTarget
face.default
face.field
FEData
fe_userEditSelf
fe_userOwnSelf
field
fieldPrefix
fieldRequired
fieldWrap
file
FILE
filelink
fileList
fileTarget
firstLabel
firstLabelGeneral
flip
flop
foldSpeed
foldTimer
fontFile
fontSize
fontSizeMultiplicator
fontTag
footerData
forceAbsoluteUrl
forceTypeValue
FORM
format
formName
formurl
frame
frameReloadIfNotInFrameset
frameSet
freezeMouseover
ftu
gamma
gapBgCol
gapLineCol
gapLineThickness
gapWidth
gif
GIFBUILDER
globalNesting
GMENU
goodMess
gray
gr_list
groupBy
headerComment
headerData
headTag
height
hiddenFields
hide
hideButCreateMap
hideMenuTimer
hideMenuWhenNotOver
hideNonTranslated
highColor
HMENU
hover
hoverStyle
HRULER
HTML
html5
htmlmail
HTMLparser
htmlSpecialChars
htmlTag_dir
htmlTag_langKey
htmlTag_setParams
http
icon
iconCObject
icon_image_ext_list
icon_link
icon_thumbSize
if
ifBlank
ifEmpty
IFSUB
IFSUBRO
ignore
IMAGE
image_compression
image_effects
image_frames
imgList
imgMap
imgMapExtras
imgMax
imgNameNotRandom
imgNamePrefix
imgObjNum
imgParams
imgPath
imgStart
IMGTEXT
import
inBranch
includeCSS
includeJS
includeJSFooter
includeJSFooterlibs
includeJSlibs
includeLibrary
includeLibs
includeNotInMenu
incT3Lib_htmlmail
index_descrLgd
index_enable
index_externals
index_metatags
infomail
inlineJS
inlineLanguageLabel
inlineSettings
inlineStyle2TempFile
innerStdWrap_all
innerWrap
innerWrap2
inputLevels
insertClassesFromRTE
insertData
intensity
intTarget
intval
invert
IProcFunc
isFalse
isGreaterThan
isInList
isLessThan
isPositive
isTrue
itemArrayProcFunc
items
iterations
javascriptLibs
join
jpg
jsFooterInline
jsInline
JSMENU
JSwindow
JSwindow.altUrl
JSwindow.altUrl_noDefaultParams
JSwindow.expand
JSwindow.newWindow
JSwindow_params
jumpurl
jumpurl_enable
jumpurl_mailto_disable
keep
keepNonMatchedTags
keywords
keywordsField
labelStdWrap
labelWrap
lang
language
language_alt
languageField
layer_menu_id
layerStyle
layout
layoutRootPath
leftjoin
leftOffset
levels
limit
lineColor
lineThickness
linkAccessRestrictedPages
linkParams
linkVars
linkWrap
list
listNum
lm
LOAD_REGISTER
locale_all
localNesting
locationData
lockFilePath
lockPosition
lockPosition_addSelf
lockPosition_adjust
loginUser
longdescURL
loop
lowColor
lower
mailto
main
mainScript
makelinks
markers
markerWrap
mask
max
maxAge
maxH
maxHeight
maxItems
maxW
maxWidth
maxWInText
m.bgImg
m.bottomImg
m.bottomImg_mask
md5
meaningfulTempFilePrefix
menuBackColor
menuHeight
menuOffset
menuWidth
message_page_is_being_generated
message_preview
message_preview_workspace
meta
metaCharset
method
minH
minifyCSS
minifyJS
minItems
minItems
minW
m.mask
moveJsFromHeaderToFooter
MP_defaults
MP_disableTypolinkClosestMPvalue
MP_mapRootPoints
MULTIMEDIA
name
namespaces
negate
newRecordFromTable
newRecordInPid
next
niceText
NO
noAttrib
noBlur
no_cache
noCols
noLink
noLinkUnderline
nonCachedSubst
none
nonTypoTagStdWrap
nonTypoTagUserFunc
nonWrappedTag
noOrderBy
noPageTitle
noResultObj
normalWhenNoLanguage
noRows
noScale
noScaleUp
noscript
noStretchAndMarginCells
notification_email_charset
notification_email_encoding
notification_email_urlmode
noTrimWrap
noValueInsert
noWrapAttr
numberFormat
numRows
obj
offset
offset
_offset
offsetWrap
onlyCurrentPid
opacity
options
orderBy
OTABLE
outerWrap
outline
output
outputLevels
override
overrideAttribs
overrideEdit
overrideId
PAGE
pageGenScript
pageRendererTemplateFile
pageTitleFirst
parameter
params
parseFunc
parseFunc
parseValues
partialRootPath
path
pidInList
pixelSpaceFontSizeRef
plainTextStdWrap
pluginNames
png
postCObject
postUserFunc
postUserFunkInt
preCObject
prefixComment
prefixLocalAnchors
prefixLocalAnchors
prefixRelPathWith
preIfEmptyListNum
prepend
preUserFunc
prev
previewBorder
printBeforeContent
prioriCalc
processScript
properties
protect
protectLvar
quality
quality
radioInputWrap
radioWrap
range
range
rawUrlEncode
recipient
RECORDS
recursive
redirect
reduceColors
relativeToParentLayer
relativeToTriggerItem
relPathPrefix
remap
remapTag
removeBadHTML
removeDefaultJS
removeIfEquals
removeIfFalse
removeObjectsOfDummy
removePrependedNumbers
removeTags
removeWrapping
renderCharset
renderObj
renderWrap
REQ
required
required
resources
resultObj
returnKey
returnLast
reverseOrder
rightjoin
rm
rmTagIfNoAttrib
RO_chBgColor
rootline
rotate
rows
rowSpace
sample
sample
section
sectionIndex
select
sendCacheHeaders
sendCacheHeaders_onlyWhenLoginDeniedInBranch
separator
setContentToCurrent
setCurrent
setfixed
setFixedHeight
setFixedWidth
setJS_mouseOver
setJS_openPic
setKeywords
shadow
sharpen
shear
short
shortcutIcon
showAccessRestrictedPages
showActive
showFirst
simulateStaticDocuments
simulateStaticDocuments_addTitle
simulateStaticDocuments_dontRedirectPathInfoError
simulateStaticDocuments_noTypeIfNoTitle
simulateStaticDocuments_pEnc
simulateStaticDocuments_pEnc_onlyP
simulateStaticDocuments_replacementChar
sitetitle
size
size.default
size.field
slide
smallFormFields
solarize
source
space
spaceAfter
spaceBefore
spaceBelowAbove
spaceLeft
spaceRight
spacing
spamProtectEmailAddresses
spamProtectEmailAddresses_atSubst
spamProtectEmailAddresses_lastDotSubst
SPC
special
split
splitRendering
src
stat
stat_apache
stat_apache_logfile
stat_apache_niceTitle
stat_apache_noHost
stat_apache_noRoot
stat_apache_notExtended
stat_apache_pagenames
stat_excludeBEuserHits
stat_excludeIPList
stat_mysql
stat_pageLen
stat_titleLen
stat_typeNumList
stayFolded
stdWrap
stdWrap2
strftime
stripHtml
stripProfile
stylesheet
submenuObjSuffixes
subMenuOffset
subparts
subst_elementUid
subst_elementUid
substMarksSeparately
substring
swirl
sword
sword_noMixedCase
sword_standAlone
sys_language_mode
sys_language_overlay
sys_language_softExclude
sys_language_softMergeIfNotBlank
sys_language_uid
sys_page
table
tableParams
tables
tableStdWrap
tableStyle
tags
target
TCAselectItem
TDparams
template
TEMPLATE
templateFile
text
TEXT
textMargin
textMargin_outOfText
textMaxLength
textObjNum
textPos
textStyle
thickness
thousands_sep
title
titleTagFunction
titleText
titleText
tm
TMENU
token
topOffset
totalWidth
transparentBackground
transparentColor
trim
twice
typeNum
types
typolink
typolinkCheckRootline
typolinkEnableLinksAcrossDomains
typolinkLinkAccessRestrictedPages
typolinkLinkAccessRestrictedPages_addParams
uid
uidInList
uniqueGlobal
uniqueLinkVars
uniqueLocal
unset
unsetEmpty
upper
url
useCacheHash
useLargestItemX
useLargestItemY
USER
USERDEF1
USERDEF1RO
USERDEF2RO
USERFEF2
userFunc
userFunc_updateArray
userIdColumn
USER_INT
USERNAME_substToken
USERUID_substToken
USR
USRRO
value
variables
wave
where
width
wordSpacing
workArea
workOnSubpart
wrap
wrap2
wrap3
wrapAlign
wrapFieldName
wrapItemAndSub
wrapNoWrappedLines
wraps
xhtml_11
xhtml_2
xhtml_basic
xhtml_cleaning
xhtmlDoctype
xhtml_frames
xhtml+rdfa_10
xhtml_strict
xhtml_trans
xml_10
xml_11
xmlprologue
xPosOffset
yPosOffset

View file

@ -1,231 +0,0 @@
# OCaml 3.12.1
# Keywords
and
as
assert
begin
class
constraint
do
done
downto
else
end
exception
external
false
for
fun
function
functor
if
in
include
inherit
initializer
lazy
let
match
method
module
mutable
new
object
of
open
or
private
rec
sig
struct
then
to
true
try
type
val
virtual
when
while
with
# Pervasives
!
!=
&
&&
*
**
*.
+
+.
-
-.
/
/.
:=
<
<=
<>
=
==
>
>=
@
FP_infinite
FP_nan
FP_normal
FP_subnormal
FP_zero
LargeFile
Open_append
Open_binary
Open_creat
Open_nonblock
Open_rdonly
Open_text
Open_trunc
Open_wronly
Oupen_excl
^
^^
abs
abs_float
acos
asin
asr
at_exit
atan
atan2
bool_of_string
ceil
char_of_int
classify_float
close_in
close_in_noerr
close_out
close_out_noerr
compare
cos
cosh
decr
do_at_exit
epsilon_float
exit
exp
expm1
failwith
float
float_of_int
float_of_string
floor
flush
flush_all
format
format4
format_of_string
fpclass
frexp
fst
ignore
in_channel
in_channel_length
incr
infinity
input
input_binary_int
input_byte
input_char
input_line
input_value
int_of_char
int_of_float
int_of_string
invalid_arg
land
ldexp
lnot
log
log10
log1p
lor
lsl
lsr
lxor
max
max_float
max_int
min
min_float
min_int
mod
mod_float
modf
nan
neg_infinity
not
open_flag
open_in
open_in_bin
open_in_gen
open_out
open_out_bin
open_out_gen
or
out_channel
out_channel_length
output
output_binary_int
output_byte
output_char
output_string
output_value
pos_in
pos_out
pred
prerr_char
prerr_endline
prerr_float
prerr_int
prerr_newline
prerr_string
print_char
print_endline
print_float
print_int
print_newline
print_string
raise
read_float
read_int
read_line
really_input
ref
seek_in
seek_out
set_binary_mode_in
set_binary_mode_out
sin
sinh
snd
sqrt
stderr
stdin
stdout
string_of_bool
string_of_float
string_of_format
string_of_int
succ
tan
tanh
truncate
unsafe_really_input
valid_float_lexem
||
~
~+
~+.
~-
~-.

View file

@ -1,313 +0,0 @@
`define
`else
`endif
`ifdef
`ifndef
`macromodule
`module
`primitive
`timescale
above
abs
absdelay
ac_stim
acos
acosh
alias
aliasparam
always
always_comb
always_ff
always_latch
analog
analysis
and
asin
asinh
assert
assign
assume
atan
atan2
atanh
automatic
before
begin
bind
bins
binsof
bit
branch
break
buf
bufif0
bufif1
byte
case
casex
casez
cell
chandle
class
clocking
cmos
config
connectmodule
connectrules
const
constraint
context
continue
cos
cosh
cover
covergroup
coverpoint
cross
ddt
ddx
deassign
default
define
defparam
design
disable
discipline
dist
do
driver_update
edge
else
end
endcase
endclass
endclocking
endconfig
endconnectrules
enddiscipline
endfunction
endgenerate
endgroup
endif
endinterface
endmodule
endnature
endpackage
endparamset
endprimitive
endprogram
endproperty
endsequence
endspecify
endtable
endtask
enum
event
exclude
exp
expect
export
extends
extern
final
final_step
first_match
flicker_noise
floor
flow
for
force
foreach
forever
fork
forkjoin
from
function
generate
genvar
ground
highz0
highz1
hypot
idt
idtmod
if
ifdef
iff
ifndef
ifnone
ignore_bins
illegal_bins
import
incdir
include
inf
initial
initial_step
inout
input
inside
instance
int
integer
interface
intersect
join
join_any
join_none
laplace_nd
laplace_np
laplace_zd
laplace_zp
large
last_crossing
liblist
library
limexp
ln
local
localparam
log
logic
longint
macromodule
mailbox
matches
max
medium
min
modport
module
nand
nand
nature
negedge
net_resolution
new
nmos
nmos
noise_table
nor
noshowcancelled
not
notif0
notif1
null
or
output
package
packed
parameter
paramset
pmos
pmos
posedge
potential
pow
primitive
priority
program
property
protected
pull0
pull1
pullup
pulsestyle_ondetect
pulsestyle_onevent
pure
rand
randc
randcase
randcase
randsequence
rcmos
real
realtime
ref
reg
release
repeat
return
rnmos
rpmos
rtran
rtranif0
rtranif1
scalared
semaphore
sequence
shortint
shortreal
showcancelled
signed
sin
sinh
slew
small
solve
specify
specparam
sqrt
static
string
strong0
strong1
struct
super
supply
supply0
supply1
table
tagged
tan
tanh
task
then
this
throughout
time
timeprecision
timer
timescale
timeunit
tran
tran
tranif0
tranif1
transition
tri
tri
tri0
tri1
triand
trior
trireg
type
typedef
union
unique
unsigned
use
uwire
var
vectored
virtual
void
wait
wait_order
wand
weak0
weak1
while
white_noise
wildcard
wire
with
within
wor
wreal
xnor
xor
zi_nd
zi_np
zi_zd

View file

@ -1,256 +0,0 @@
;;; ein-ac.el --- Auto-complete extension
;; Copyright (C) 2012- Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-ac.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-ac.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-ac.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'auto-complete)
(require 'ein-core)
(eval-when-compile (require 'ein-notebook)
(defvar ein:mumamo-codecell-mode))
;;; Configuration
(defcustom ein:use-auto-complete-superpack nil
"Set to `t' to use preset a little bit hacky auto-complete configuration.
When this option is enabled, cached omni completion is available."
:type 'boolean
:group 'ein)
(defvar ein:ac-sources (and (boundp 'ac-sources)
(default-value 'ac-sources))
"Extra `ac-sources' used in notebook.")
;;; Chunk (adapted from auto-complete-chunk.el)
(defvar ein:ac-chunk-regex
(rx (group (| (syntax whitespace)
(syntax open-parenthesis)
(syntax close-parenthesis)
(syntax string-quote) ; Complete files for `open("path/..`
bol))
(? (syntax punctuation)) ; to complete ``~/PATH/...``
(* (+ (| (syntax word) (syntax symbol)))
(syntax punctuation))
(+ (| (syntax word) (syntax symbol)))
(? (syntax punctuation))
point)
"A regexp that matches to a \"chunk\" containing words and dots.")
(defun ein:ac-chunk-beginning ()
"Return the position where the chunk begins."
(ignore-errors
(save-excursion
(+ (re-search-backward ein:ac-chunk-regex) (length (match-string 1))))))
(defun ein:ac-chunk-candidates-from-list (chunk-list)
"Return matched candidates in CHUNK-LIST."
(let* ((start (ein:ac-chunk-beginning)))
(when start
(cl-loop with prefix = (buffer-substring start (point))
for cc in chunk-list
when (string-prefix-p prefix cc)
collect cc))))
;;; AC Source
(defvar ein:ac-direct-matches nil
"Variable to store completion candidates for `auto-completion'.")
;; FIXME: Maybe this should be buffer-local?
(defun ein:ac-direct-get-matches ()
(ein:ac-chunk-candidates-from-list ein:ac-direct-matches))
(define-obsolete-function-alias 'ac-complete-ein-cached 'ac-complete-ein-async
"0.2.1")
(define-obsolete-variable-alias 'ac-source-ein-cached 'ac-source-ein-async
"0.2.1")
(defun ein:ac-request-in-background ()
(cl-case ein:completion-backend
(ein:use-ac-backend (ein:aif (ein:get-kernel)
(ein:completer-complete
it
(list :complete_reply
(cons (lambda (_ content __)
(ein:ac-prepare-completion (plist-get content :matches)))
nil))
#'ignore)))))
;;; Completer interface
(defun ein:ac-dot-complete (callback)
"Insert a dot and request completion via CALLBACK of 0-arity"
(interactive (list (lambda () (call-interactively #'ein:completer-complete))))
(insert ".")
(if (not (ac-cursor-on-diable-face-p))
(funcall callback)))
(defun ein:ac-prepare-completion (matches)
"Prepare `ac-source-ein-direct' using MATCHES from kernel.
Call this function before calling `auto-complete'."
(when matches
(setq ein:ac-direct-matches matches))) ; let-binding won't work
(cl-defun ein:completer-finish-completing-ac
(matched-text
matches
&key (expand ac-expand-on-auto-complete)
&allow-other-keys)
"Invoke completion using `auto-complete'.
Only the argument MATCHES is used. MATCHED-TEXT is for
compatibility with `ein:completer-finish-completing-default'."
;; I don't need to check if the point is at right position, as in
;; `ein:completer-finish-completing-default' because `auto-complete'
;; checks it anyway.
(ein:log 'debug "COMPLETER-FINISH-COMPLETING-AC: matched-text=%S matches=%S"
matched-text matches)
(ein:ac-prepare-completion matches)
(when matches ; No auto-complete drop-down list when no matches
(let ((ac-expand-on-auto-complete expand))
(ac-start))))
;;; Async document request hack
(defun ein:ac-request-document-for-selected-candidate ()
"Request object information for the candidate at point.
This is called via `ac-next'/`ac-previous'/`ac-update' and set
`document' property of the current candidate string. If server
replied within `ac-quick-help-delay' seconds, auto-complete will
popup help string."
(ein:aif (ein:get-kernel)
(let* ((candidate (ac-selected-candidate))
(kernel it)
(api-version (ein:$kernel-api-version kernel))
(callbacks (list (if (< api-version 3)
:object_info_reply
:inspect_request)
(cons #'ein:ac-set-document candidate))))
(when (and candidate
(ein:kernel-live-p kernel)
(not (get-text-property 0 'document candidate)))
(ein:log 'debug "Requesting object info for AC candidate %S"
candidate)
(ein:kernel-object-info-request kernel candidate callbacks)))))
(defun ein:ac-set-document (candidate content -metadata-not-used-)
(ein:log 'debug "EIN:AC-SET-DOCUMENT candidate=%S content=%S"
candidate content)
(put-text-property 0 (length candidate)
'document (ein:kernel-construct-help-string content)
candidate))
(defadvice ac-next (after ein:ac-next-request)
"Monkey patch `auto-complete' internal function to request
help documentation asynchronously."
(ein:ac-request-document-for-selected-candidate))
(defadvice ac-previous (after ein:ac-previous-request)
"Monkey patch `auto-complete' internal function to request
help documentation asynchronously."
(ein:ac-request-document-for-selected-candidate))
(defadvice ac-update (after ein:ac-update-request)
"Monkey patch `auto-complete' internal function to request help
documentation asynchronously. This will request info for the
first candidate when the `ac-menu' pops up."
(ein:ac-request-document-for-selected-candidate))
;;; Setup
(defun ein:ac-superpack ()
"Enable richer auto-completion.
* Enable auto-completion help by monkey patching `ac-next'/`ac-previous'"
(interactive)
(ad-enable-advice 'ac-next 'after 'ein:ac-next-request)
(ad-enable-advice 'ac-previous 'after 'ein:ac-previous-request)
(ad-enable-advice 'ac-update 'after 'ein:ac-update-request)
(ad-activate 'ac-next)
(ad-activate 'ac-previous)
(ad-activate 'ac-update))
(defun ein:ac-setup ()
"Call this function from mode hook (see `ein:ac-config')."
(setq ac-sources (append '(ac-source-ein-async) ein:ac-sources)))
(defun ein:ac-setup-maybe ()
"Setup `ac-sources' for mumamo.
.. note:: Setting `ein:notebook-mumamo-mode-hook' does not work
because `ac-sources' in `ein:notebook-mumamo-mode'-enabled
buffer is *chunk local*, rather than buffer local.
Making `ac-sources' permanent-local also addresses issue of
MuMaMo discarding `ac-sources'. However, it effects to entire
Emacs setting. So this is not the right way to do it.
Using `mumamo-make-variable-buffer-permanent' (i.e., adding
`ac-sources' to `mumamo-per-buffer-local-vars' or
`mumamo-per-main-major-local-vars') is also not appropriate.
Adding `ac-sources' to them makes it impossible to different
`ac-sources' between chunks, which is good for EIN but may not
for other package."
(and (ein:eval-if-bound 'ein:notebook-mode)
(ein:eval-if-bound 'ein:notebook-mumamo-mode)
(eql major-mode ein:mumamo-codecell-mode)
(ein:ac-setup)))
(defun ein:ac-config (&optional superpack)
"Install auto-complete-mode for notebook modes.
Specifying non-`nil' to SUPERPACK enables richer auto-completion
\(see `ein:ac-superpack')."
(add-hook 'after-change-major-mode-hook 'ein:ac-setup-maybe)
(add-hook 'ein:notebook-mode-hook 'ein:ac-setup)
(when superpack
(ein:ac-superpack)))
(defun ein:ac-install-backend ()
(ac-define-source ein-direct
'((candidates . ein:ac-direct-get-matches)
(requires . 0)
(prefix . ein:ac-chunk-beginning)
(symbol . "s")))
(ac-define-source ein-async
'((candidates . ein:ac-direct-get-matches)
(requires . 0)
(prefix . ein:ac-chunk-beginning)
(init . ein:ac-request-in-background)
(symbol . "c")))
(ein:ac-config ein:use-auto-complete-superpack))
(provide 'ein-ac)
;;; ein-ac.el ends here

Binary file not shown.

View file

@ -1,276 +0,0 @@
;;; ein-cell-edit.el --- Notebook cell editing
;; Copyright (C) 2016 John M. Miller
;; Author: John Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-cell-edit.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-cell-edit.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-worksheet.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; This code inspired by borrowing from org-src.el.
;;; Code:
(require 'ein-cell)
(autoload 'julia-mode "julia-mode")
(autoload 'markdown-mode "markdown-mode")
(autoload 'R-mode "ess-r-mode")
(autoload 'org-src--remove-overlay "org-src")
(autoload 'org-src-switch-to-buffer "org-src")
(defvar ein:src--cell nil)
(defvar ein:src--ws nil)
(defvar ein:src--allow-write-back t)
(defvar ein:src--overlay nil)
(defvar ein:src--saved-window-config nil)
(declare-function ein:notebook--get-nb-or-error "ein-notebook" ())
(defvar ein:edit-cell-mode-map
(let ((map (make-sparse-keymap)))
(define-key map "\C-c'" 'ein:edit-cell-exit)
(define-key map "\C-c\C-k" 'ein:edit-cell-abort)
(define-key map "\C-c\C-c" 'ein:edit-cell-save-and-execute)
(define-key map "\C-x\C-s" 'ein:edit-cell-save)
(define-key map "\C-c\C-x" 'ein:edit-cell-view-traceback)
map))
(define-minor-mode ein:edit-cell-mode
"Minor mode for language major mode buffers generated by EIN.
This minor mode is turned on when editing a source code snippet with \\[ein:edit-cell-contents]
\\{ein:edit-cell-mode-map}
."
nil " EinCell" nil
(set (make-local-variable 'header-line-format)
(substitute-command-keys
"Edit, execute with \\[ein:edit-cell-execute] then exit with \\[ein:edit-cell-exit] \
or abort with \\[ein:edit-cell-abort]"))
;; Possibly activate various auto-save features (for the edit buffer
;; or the source buffer).
;; (when org-edit-src-turn-on-auto-save
;; (setq buffer-auto-save-file-name
;; (concat (make-temp-name "org-src-")
;; (format-time-string "-%Y-%d-%m")
;; ".txt")))
;; (unless (or org-src--auto-save-timer (zerop org-edit-src-auto-save-idle-delay))
;; (setq org-src--auto-save-timer
;; (run-with-idle-timer
;; org-edit-src-auto-save-idle-delay t
;; (lambda ()
;; (save-excursion
;; (let (edit-flag)
;; (dolist (b (buffer-list))
;; (with-current-buffer b
;; (when (org-src-edit-buffer-p)
;; (unless edit-flag (setq edit-flag t))
;; (when (buffer-modified-p) (org-edit-src-save)))))
;; (unless edit-flag
;; (cancel-timer org-src--auto-save-timer)
;; (setq org-src--auto-save-timer nil))))))))
)
(defun ein:cell-configure-edit-buffer ()
(when (and (bound-and-true-p org-src--from-org-mode) (boundp 'org-src--beg-marker))
(add-hook 'kill-buffer-hook #'org-src--remove-overlay nil 'local)
(if (bound-and-true-p org-src--allow-write-back)
(progn
(setq buffer-offer-save t)
(setq buffer-file-name
(concat (buffer-file-name (marker-buffer org-src--beg-marker))
"[" (buffer-name) "]"))
(setq write-contents-functions '(ein:edit-cell-save)))
(setq buffer-read-only t))))
(defun ein:edit-cell-view-traceback ()
"Jump to traceback, if there is one, for current edit."
(interactive)
(let ((buf (current-buffer))
(cell ein:src--cell))
(with-current-buffer (ein:worksheet--get-buffer ein:src--ws)
(ein:cell-goto cell)
(ein:tb-show))))
(defun ein:edit-cell-save-and-execute ()
"Save, then execute the countents of the EIN source edit buffer
and place results (if any) in output of original notebook cell."
(interactive)
(ein:edit-cell-save)
(when (and (slot-exists-p ein:src--cell 'kernel)
(slot-boundp ein:src--cell 'kernel))
(ein:cell-execute-internal ein:src--cell
(slot-value ein:src--cell 'kernel)
(buffer-string)
:silent nil)))
(defun ein:edit-cell-save ()
"Save contents of EIN source edit buffer back to original notebook
cell."
(interactive)
(set-buffer-modified-p nil)
(let* ((edited-code (buffer-string))
(cell ein:src--cell)
(overlay ein:src--overlay)
(read-only (overlay-get overlay 'modification-hooks)))
(overlay-put overlay 'modification-hooks nil)
(overlay-put overlay 'insert-in-front-hooks nil)
(overlay-put overlay 'insert-behind-hooks nil)
(with-current-buffer (ein:worksheet--get-buffer ein:src--ws)
(ein:cell-set-text cell edited-code))
;;(setf (slot-value ein:src--cell 'input) edited-code)
(overlay-put overlay 'modification-hooks read-only)
(overlay-put overlay 'insert-in-front-hooks read-only)
(overlay-put overlay 'insert-behind-hooks read-only)))
(defun ein:edit-cell-exit ()
"Close the EIN source edit buffer, saving contents back to the
original notebook cell, unless being called via
`ein:edit-cell-abort'."
(interactive)
(let ((edit-buffer (current-buffer))
(ws ein:src--ws)
(cell ein:src--cell))
(ein:remove-overlay)
(when ein:src--allow-write-back
(ein:edit-cell-save))
(kill-buffer edit-buffer)
(switch-to-buffer-other-window (ein:worksheet--get-buffer ws))
(ein:cell-goto cell)
(when ein:src--saved-window-config
(set-window-configuration ein:src--saved-window-config)
(setq ein:src--saved-window-config nil))))
(defun ein:edit-cell-abort ()
"Abort editing the current cell, contents will revert to
previous value."
(interactive)
(let (ein:src--allow-write-back) (ein:edit-cell-exit)))
(defun ein:construct-cell-edit-buffer-name (bufname cid cell-type)
(concat "*EIN Src " bufname "[ " cid "/" cell-type " ]*" ))
(defun ein:get-mode-for-kernel (kernelspec)
(if (null kernelspec)
'python ;; FIXME
(intern (ein:$kernelspec-language kernelspec))))
;; (ein:case-equal (ein:$kernelspec-language kernelspec)
;; (("julia" "python" "R") )
;; (t 'python))))
(defun ein:edit-src-continue (e)
(interactive "e")
(mouse-set-point e)
(let ((buf (get-char-property (point) 'edit-buffer)))
(if buf (org-src-switch-to-buffer buf 'continue)
(user-error "No sub-editing buffer for area at point"))))
(defun ein:make-source-overlay (beg end edit-buffer)
"Create overlay between BEG and END positions and return it.
EDIT-BUFFER is the buffer currently editing area between BEG and
END."
(let ((overlay (make-overlay beg end)))
(overlay-put overlay 'face 'secondary-selection)
(overlay-put overlay 'edit-buffer edit-buffer)
(overlay-put overlay 'help-echo
"Click with mouse-1 to switch to buffer editing this segment")
(overlay-put overlay 'face 'secondary-selection)
(overlay-put overlay 'keymap
(let ((map (make-sparse-keymap)))
(define-key map [mouse-1] 'ein:edit-src-continue)
map))
(let ((read-only
(list
(lambda (&rest _)
(user-error
"Cannot modify an area being edited in a dedicated buffer")))))
(overlay-put overlay 'modification-hooks read-only)
(overlay-put overlay 'insert-in-front-hooks read-only)
(overlay-put overlay 'insert-behind-hooks read-only))
overlay))
(defun ein:remove-overlay ()
"Remove overlay from current source buffer."
(when (overlayp ein:src--overlay) (delete-overlay ein:src--overlay)))
(defcustom ein:raw-cell-default-edit-mode 'LaTeX-mode
"The major mode to use when editing a cell of type 'Raw' in the
dedicated edit buffer. By default we use LaTeX-mode."
:type 'symbol
:group 'ein)
(defun ein:edit-cell-contents ()
"Edit the contents of the current cell in a buffer using an
appropriate language major mode. Functionality is very similar to
`org-edit-special'."
(interactive)
(setq ein:src--saved-window-config (current-window-configuration))
(let* ((cell (or (ein:worksheet-get-current-cell)
(error "Must be called from inside an EIN worksheet cell.")))
(nb (ein:notebook--get-nb-or-error))
(ws (ein:worksheet--get-ws-or-error))
(type (slot-value cell 'cell-type))
(name (ein:construct-cell-edit-buffer-name (buffer-name) (ein:cell-id cell) type)))
(ein:aif (get-buffer name)
(switch-to-buffer-other-window it)
(ein:create-edit-cell-buffer name cell nb ws))))
(defun ein:edit-cell-detect-type (contents notebook &optional raw-cell-p)
(if (string-match "^%%\\(.*\\)" contents)
(ein:case-equal (match-string 1 contents)
(("html" "HTML") (html-mode))
(("latex" "LATEX") (LaTeX-mode))
(("ruby") (ruby-mode))
(("sh" "bash") (sh-mode))
(("javascript" "js") (javascript-mode))
(t (funcall ein:raw-cell-default-edit-mode)))
(if raw-cell-p
(funcall ein:raw-cell-default-edit-mode)
(cl-case (ein:get-mode-for-kernel (ein:$notebook-kernelspec notebook))
(julia (julia-mode))
(python (python-mode))
(R (R-mode))))))
(defun ein:create-edit-cell-buffer (name cell notebook worksheet)
(let* ((contents (ein:cell-get-text cell))
(type (slot-value cell 'cell-type))
(buffer (generate-new-buffer-name name))
(overlay (ein:make-source-overlay (ein:cell-input-pos-min cell)
(ein:cell-input-pos-max cell)
buffer)))
(switch-to-buffer-other-window buffer)
(insert contents)
(remove-text-properties (point-min) (point-max)
'(display nil invisible nil intangible nil))
(set-buffer-modified-p nil)
(setq buffer-file-name buffer) ;; Breaks anaconda-mode without this special fix.
(condition-case e
(ein:case-equal type
(("markdown") (markdown-mode))
(("raw") (ein:edit-cell-detect-type contents notebook t))
(("code") (ein:edit-cell-detect-type contents notebook)))
(error (message "Language mode `%s' fails with: %S"
type (nth 1 e))))
(set (make-local-variable 'ein:src--overlay) overlay)
(set (make-local-variable 'ein:src--cell) cell)
(set (make-local-variable 'ein:src--ws) worksheet)
(set (make-local-variable 'ein:src--allow-write-back) t)
(ein:edit-cell-mode)))
(provide 'ein-cell-edit)

View file

@ -1,78 +0,0 @@
;;; ein-cell-output.el --- Cell module
;; (C) 2015- John M. Miller
;; Author: John M. Miller (millejoh at mac dot com)
;; This file is NOT part of GNU Emacs.
;; ein-cell-output.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-cell-output.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-cell-output.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; Because wiriting cell outputs to nbformat v4.0 json is complicated
;; enought that it warrants a file all to its own.
;;; Code:
(require 'ein-cell)
(defvar ein:output-type-map
'((:svg . :image/svg+xml) (:png . :image/png) (:jpeg . :image/jpeg)
(:text . :text/plain)
(:html . :text/html) (:latex . :text/latex) (:javascript . :text/javascript)))
(defun ein:output-property (maybe-property)
(cdr (assoc maybe-property ein:output-type-map)))
;;; Dealing with Code cell outputs
(defun ein:cell-stream-output-to-json (output)
`((output_type . "stream")
(name . ,(plist-get output :stream))
(text . ,(plist-get output :text))))
(defun ein:cell-error-output-to-json (output)
`((output_type . "error")
(ename . ,(plist-get output :ename))
(evalue . ,(plist-get output :evalue))
(traceback . ,(plist-get output :traceback))))
(defun ein:cell-execute-result-output-to-json (output)
(let ((data (ein:aif (plist-get output :text)
`("text/plain" . ,it)
(plist-get output :data))))
`((output_type . "execute_result")
(metadata . ,(make-hash-table))
(execution_count . ,(or (plist-get output :prompt_number)
(plist-get output :execution_count)))
(data . (,data)))))
(defun ein:maybe-get-output-mime-data (output)
(cl-loop for type in '(:svg :png :jpeg :html :latex :javascript :text)
if (plist-get output type)
collecting (cons (ein:output-property type) (plist-get output type))))
(defun ein:cell-display-data-output-to-json (output)
(let ((data (or (ein:maybe-get-output-mime-data output)
(plist-get output :data))))
`((output_type . "display_data")
(data . ,data)
(metadata . ,(make-hash-table)))))
(defun ein:find-and-make-outputs (output-plist)
(cl-loop for prop in ein:output-type-map
when (plist-get output-plist (cdr prop))
collect (list (cdr prop) (plist-get output-plist (cdr prop)))))
(provide 'ein-cell-output)

Binary file not shown.

View file

@ -1,123 +0,0 @@
;;; -*- mode: emacs-lisp; lexical-binding: t; -*-
;;; ein-company.el --- Support for completion using company back-end.
;; Copyright (C) 2017 - John Miller
;; Author: John Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-company.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-company.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-company.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'deferred)
(require 'ein-completer)
(require 'company nil t)
(autoload 'company-begin-backend "company")
(autoload 'company-doc-buffer "company")
(defun ein:company--deferred-complete ()
(let ((d (deferred:new #'identity)))
(ein:completer-complete
(ein:get-kernel)
(list :complete_reply
(cons (lambda (d* &rest args) (deferred:callback-post d* args))
d))
(apply-partially (lambda (d* err) (deferred:callback-post d* err)) d))
d))
(defun ein:company--complete (prefix fetcher)
(deferred:$
(deferred:next
(lambda ()
(ein:company--deferred-complete)))
(deferred:nextc it
(lambda (replies)
(unless (stringp replies) ;; if not an error
(ein:completions--prepare-matches prefix fetcher replies))))))
(defun ein:completions--prepare-matches (prefix fetcher replies)
(cl-destructuring-bind
((&key matches cursor_start cursor_end &allow-other-keys) ; :complete_reply
_metadata)
replies
(let ((nix (- cursor_end cursor_start))
prefixed-matches)
(dolist (match matches)
(setq prefixed-matches
(nconc prefixed-matches (list (concat prefix (substring match nix))))))
(ein:completions--build-oinfo-cache prefixed-matches)
(funcall fetcher prefixed-matches))))
;;;###autoload
(defun ein:company-backend (command &optional arg &rest _)
(interactive (list 'interactive))
(cl-case command
(interactive (company-begin-backend 'ein:company-backend))
(prefix (and (eq ein:completion-backend 'ein:use-company-backend)
(or (ein:worksheet-at-codecell-p) ein:connect-mode)
(ein:get-kernel)
(ein:object-prefix-at-point)))
(annotation (let ((kernel (ein:get-kernel)))
(ein:aif (gethash arg (ein:$kernel-oinfo-cache kernel))
(plist-get it :definition))))
(doc-buffer (cons :async
(lambda (cb)
(ein:company-handle-doc-buffer arg cb))))
(location (cons :async
(lambda (cb)
(ein:pytools-find-source (ein:get-kernel-or-error)
arg
cb))))
(candidates
(let* ((kernel (ein:get-kernel-or-error))
(cached (ein:completions-get-cached arg (ein:$kernel-oinfo-cache kernel))))
(ein:aif cached it
(unless (ein:company--punctuation-check (thing-at-point 'line)
(current-column))
(cl-case ein:completion-backend
(t
(cons :async
(lambda (cb)
(ein:company--complete arg cb)))))))))))
(defun ein:company--punctuation-check (thing col)
(or (string-match "[[:nonascii:]]" thing)
(let ((query (ein:trim-right (cl-subseq thing 0 col) "[\n]")))
(string-match "[]()\",[{}'=: ]$" query (- col 2)))))
(defun ein:company-handle-doc-buffer-finish (packed content _metadata-not-used_)
(when (plist-get content :found)
(funcall (plist-get packed :callback) (company-doc-buffer
(ansi-color-apply (cadr (plist-get content :data)))))))
(defun ein:company-handle-doc-buffer (object cb)
(ein:kernel-object-info-request (ein:get-kernel-or-error)
object
(list :inspect_reply
(cons #'ein:company-handle-doc-buffer-finish
(list :object object
:callback cb)))))
(when (boundp 'company-backends)
(add-to-list 'company-backends 'ein:company-backend))
(provide 'ein-company)

View file

@ -1,186 +0,0 @@
;;; -*- mode: emacs-lisp; lexical-binding: t -*-
;;; ein-completer.el --- Completion module
;; Copyright (C) 2018- Takafumi Arakaki / John Miller
;; Author: Takafumi Arakaki <aka.tkf at gmail.com> / John Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-completer.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-completer.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-completer.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(declare-function ac-cursor-on-diable-face-p "auto-complete")
(require 'ein-core)
(require 'ein-log)
(require 'ein-subpackages)
(require 'ein-kernel)
(require 'ein-pytools)
(require 'ein-ac)
(require 'dash)
(make-obsolete-variable 'ein:complete-on-dot nil "0.15.0")
(defun ein:completer-choose ()
(cond
((eq ein:completion-backend 'ein:use-none-backend) #'ignore)
((ein:eval-if-bound 'auto-complete-mode) #'ein:completer-finish-completing-ac)
(t #'ein:completer-finish-completing-default)))
(defun ein:completer-beginning (matched-text)
(save-excursion
(re-search-backward (concat matched-text "\\="))))
(defun ein:completer-finish-completing (args content _metadata)
(ein:log 'debug "COMPLETER-FINISH-COMPLETING: content=%S" content)
(let* ((beg (point))
(delta (- (plist-get content :cursor_end)
(plist-get content :cursor_start)))
(matched-text (buffer-substring beg (- beg delta)))
(matches (plist-get content :matches))
(completer (ein:completer-choose)))
(ein:log 'debug "COMPLETER-FINISH-COMPLETING: completer=%s" completer)
(apply completer matched-text matches args)))
(defun ein:completer-finish-completing-default (matched-text matches
&rest _ignore)
(let* ((end (point))
(beg (ein:completer-beginning matched-text))
(word (if (and beg matches)
(ein:completing-read "Complete: " matches
nil nil matched-text))))
(when word
(delete-region beg end)
(insert word))))
(defun ein:completer-complete (kernel callbacks errback)
"Start completion for the code at point.
EXPAND keyword argument is supported by
`ein:completer-finish-completing-ac'. When it is specified,
it overrides `ac-expand-on-auto-complete' when calling
`auto-complete'."
(interactive (list (ein:get-kernel)
(list :complete_reply
(cons #'ein:completer-finish-completing '(:expand nil)))
#'ignore))
(multiple-value-bind (code pos) (ein:get-completion-context (ein:$kernel-api-version kernel))
(ein:log 'debug (format "EIN:COMPLETER-COMPLETE Code block: %s at position :%s" code pos))
(ein:kernel-complete kernel
code ;; (thing-at-point 'line)
pos ;; (current-column)
callbacks errback)))
(defun ein:get-completion-context (api-version)
(cond ((< api-version 5)
(values (thing-at-point 'line) (current-column)))
((and (ein:get-kernel) (ein:get-cell-at-point))
(let* ((cell (ein:get-cell-at-point))
(code (ein:cell-get-text cell))
(beg (ein:cell-input-pos-min cell)))
(values code (- (point) beg))))
((ein:get-kernel)
(values (buffer-string) (1- (point))))))
;;; Retrieving Python Object Info
(defun ein:completions--reset-oinfo-cache (kernel)
(setf (ein:$kernel-oinfo-cache kernel) (make-hash-table :test #'equal)))
(defun ein:dev-clear-oinfo-cache (kernel)
(interactive (list (ein:get-kernel)))
(ein:completions--reset-oinfo-cache kernel))
(defun ein:completions-get-cached (partial oinfo-cache)
(cl-loop for candidate being the hash-keys of oinfo-cache
when (string-prefix-p partial candidate)
collect candidate))
(defun ein:completions--get-oinfo (objs)
(let ((d (deferred:new #'identity))
(kernel (ein:get-kernel)))
(ein:case-equal (ein:kernel-language kernel)
(("python")
(if (ein:kernel-live-p kernel)
(ein:kernel-execute
kernel
(format "__ein_generate_oinfo_data(%s, locals())" objs)
(list
:output `(,(lambda (d* &rest args) (deferred:callback-post d* args)) . ,d)))
(deferred:callback-post d "kernel not live"))))
d))
(defvar ein:oinfo-chunk-size 50)
(defun ein:completions--build-oinfo-cache (objects)
(cl-labels ((object-string (o)
(format "'%s'" (ein:trim o "\\s-\\|\n\\|\\.")))
(to-ostrings (objs)
(s-join ", " (-map #'(lambda (x) (object-string x))
objs)))
(do-completions (ostrings kernel)
(deferred:$
(deferred:next
(lambda ()
(ein:completions--get-oinfo ostrings)))
(deferred:nextc it
(lambda (output)
(if (stringp output)
(ein:display-warning output :error)
(ein:completions--prepare-oinfo output objects kernel)))))))
(if (< (length objects) ein:oinfo-chunk-size)
(do-completions (format "[%s]" (to-ostrings (-non-nil objects))) (ein:get-kernel))
(dolist (chunk (-partition-all ein:oinfo-chunk-size (-non-nil objects)))
(do-completions (format "[%s]" (to-ostrings chunk)) (ein:get-kernel))))))
(defun ein:completions--prepare-oinfo (output objs kernel)
(condition-case err
(cl-destructuring-bind (msg-type content _) output
(ein:case-equal msg-type
(("stream" "display_data" "pyout" "execute_result")
(ein:aif (plist-get content :text)
(let ((all-oinfo (ein:json-read-from-string it)))
(cl-loop for oinfo in all-oinfo
for obj in objs
doing (unless (string= (plist-get oinfo :string_form) "None")
(setf (gethash obj (ein:$kernel-oinfo-cache kernel))
oinfo))))))
(("error" "pyerr")
(ein:log 'verbose "ein:completions--prepare-oinfo: %s"
(plist-get content :traceback)))))
(error
(ein:log 'verbose "ein:completions--prepare-oinfo: [%s]"
(error-message-string err))
(let (eval-expression-print-length eval-expression-print-level)
(prin1 output #'external-debugging-output)))))
;;; Support for Eldoc
(defun ein:completer--get-eldoc-signature ()
(ein:and-let* ((func (ein:function-at-point))
(kernel (ein:get-kernel)))
(ein:aif (gethash func (ein:$kernel-oinfo-cache kernel))
(ein:kernel-construct-defstring it)
(ein:completions--build-oinfo-cache (list func))
nil)))
(provide 'ein-completer)
;;; ein-completer.el ends here

View file

@ -1,414 +0,0 @@
;;; ein-connect.el --- Connect external buffers to IPython -*- lexical-binding: t -*-
;; Copyright (C) 2012- Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-connect.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-connect.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-connect.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; FIXME: There is a problem when connected notebook is closed.
;; This can be fixed in some ways:
;; * Turn off ein:connect when the command that uses kernel is invoked
;; but corresponding notebook was closed already.
;; * Connect directly to ein:kernel and make its destructor to care
;; about connecting buffers.
;;; Code:
(require 'eieio)
(require 'company nil t)
(require 'ein-notebook)
(eval-when-compile (require 'auto-complete))
(autoload 'company-mode "company")
;;; Utils
(defun ein:maybe-save-buffer (option)
"Conditionally save current buffer.
Return `t' if the buffer is unmodified or `nil' otherwise.
If the buffer is modified, buffer is saved depending on the value
of OPTION:
ask : Ask whether the buffer should be saved.
yes : Save buffer always.
no : Do not save buffer."
(if (not (buffer-modified-p))
t
(cl-case option
(ask (when (y-or-n-p "Save buffer? ")
(save-buffer)
t))
(yes (save-buffer)
t)
(t nil))))
;;; Configuration
(defcustom ein:connect-run-command "%run"
"``%run`` magic command used for `ein:connect-run-buffer'.
Types same as `ein:console-security-dir' are valid."
:type '(choice
(string :tag "command" "%run")
(alist :tag "command mapping"
:key-type (choice :tag "URL or PORT"
(string :tag "URL" "http://127.0.0.1:8888")
(integer :tag "PORT" 8888)
(const default))
:value-type (string :tag "command" "%run"))
(function :tag "command getter"
(lambda (url-or-port) (format "%%run -n -i -t -d"))))
:group 'ein)
(defcustom ein:connect-reload-command "%run -n"
"Setting for `ein:connect-reload-buffer'.
Same as `ein:connect-run-command'."
:type '(choice
(string :tag "command" "%run")
(alist :tag "command mapping"
:key-type (choice :tag "URL or PORT"
(string :tag "URL" "http://127.0.0.1:8888")
(integer :tag "PORT" 8888)
(const default))
:value-type (string :tag "command" "%run"))
(function :tag "command getter"
(lambda (url-or-port) (format "%%run -n -i -t -d"))))
:group 'ein)
(defun ein:connect-run-command-get ()
(ein:choose-setting 'ein:connect-run-command
(ein:$notebook-url-or-port (ein:connect-get-notebook))))
(defcustom ein:connect-save-before-run 'yes
"Whether the buffer should be saved before `ein:connect-run-buffer'."
:type '(choice (const :tag "Always save buffer" yes)
(const :tag "Always do not save buffer" no)
(const :tag "Ask" ask))
:group 'ein)
(defcustom ein:connect-aotoexec-lighter nil
"String appended to the lighter of `ein:connect-mode' (`ein:c')
when auto-execution mode is on. When `nil', use the same string
as `ein:cell-autoexec-prompt'."
:type '(choice (string :tag "String appended to ein:c" "@")
(const :tag "Use `ein:cell-autoexec-prompt'." nil))
:group 'ein)
(defcustom ein:connect-default-notebook nil
"Notebook to be connect when `ein:connect-to-default-notebook' is called.
Example setting to connect to \"My_Notebook\" in the server at
port 8888 when opening any buffer in `python-mode'::
(setq ein:connect-default-notebook \"8888/My_Notebook\")
(add-hook 'python-mode-hook 'ein:connect-to-default-notebook)
`ein:connect-default-notebook' can also be a function without any
argument. This function must return a string (notebook path of
the form \"URL-OR-PORT/NOTEBOOK-NAME\").
As `ein:connect-to-default-notebook' requires notebook list to be
loaded, consider using `ein:notebooklist-load' to load notebook
list if you want to connect to notebook without manually opening
notebook list."
:type '(choice (string :tag "URL-OR-PORT/NOTEBOOK-NAME")
(function :tag "Notebook path getter"))
:group 'ein)
;;; Class
(ein:deflocal ein:%connect% nil
"Buffer local variable to store an instance of `ein:connect'")
(define-obsolete-variable-alias 'ein:@connect 'ein:%connect% "0.1.2")
(defclass ein:connect ()
((notebook :initarg :notebook :type ein:$notebook)
(buffer :initarg :buffer :type buffer)
(autoexec :initarg :autoexec :initform nil :type boolean
:document "Auto-execution mode flag.
See also the document of the `autoexec' slot of `ein:codecell'
class.")))
(defun ein:connect-setup (notebook buffer)
(with-current-buffer buffer
(setq ein:%connect%
(ein:connect :notebook notebook :buffer buffer))
ein:%connect%))
;;; Methods
;; FIXME: Clarify names of these `connect-to-*' functions:
;;;###autoload
(defun ein:connect-to-notebook-command (&optional not-yet-opened)
"Connect to notebook. When the prefix argument is given,
you can choose any notebook on your server including the ones
not yet opened. Otherwise, already chose from already opened
notebooks."
(interactive "P")
(call-interactively (if not-yet-opened
#'ein:connect-to-notebook
#'ein:connect-to-notebook-buffer)))
;;;###autoload
(defun ein:connect-to-notebook (nbpath &optional buffer no-reconnection)
"Connect any buffer to notebook and its kernel."
(interactive (list (ein:notebooklist-ask-path "notebook")))
(cl-multiple-value-bind (url-or-port path) (ein:notebooklist-parse-nbpath nbpath)
(ein:notebook-open url-or-port path nil
(apply-partially
(lambda (buffer* no-reconnection* notebook _created)
(ein:connect-buffer-to-notebook notebook buffer* no-reconnection*))
(or buffer (current-buffer)) no-reconnection))))
;;;###autoload
(defun ein:connect-to-notebook-buffer (buffer-or-name)
"Connect any buffer to opened notebook and its kernel."
(interactive (list (ein:completing-read "Notebook buffer to connect: "
(ein:notebook-opened-buffer-names))))
(ein:aif (get-buffer buffer-or-name)
(let ((notebook (buffer-local-value 'ein:%notebook% it)))
(ein:connect-buffer-to-notebook notebook))
(error "No buffer %s" buffer-or-name)))
;;;###autoload
(defun ein:connect-buffer-to-notebook (notebook &optional buffer
no-reconnection)
"Connect BUFFER to NOTEBOOK."
(unless buffer
(setq buffer (current-buffer)))
(with-current-buffer buffer
(if (or (not no-reconnection)
(not ein:%connect%))
(let ((connection (ein:connect-setup notebook buffer)))
(when (ein:eval-if-bound 'ac-sources)
(push 'ac-source-ein-async ac-sources))
(ein:connect-mode)
(ein:log 'info "Connected to %s"
(ein:$notebook-notebook-name notebook))
connection)
(ein:log 'info "Buffer is already connected to notebook."))))
(defun ein:connect-get-notebook ()
(slot-value ein:%connect% 'notebook))
(defun ein:connect-get-kernel ()
(ein:$notebook-kernel (ein:connect-get-notebook)))
(defun ein:connect-eval-buffer ()
"Evaluate the whole buffer. Note that this will run the code
inside the ``if __name__ == \"__main__\":`` block."
(interactive)
(let ((b (current-buffer)))
(deferred:$
(deferred:next
(lambda ()
(with-current-buffer b
(ein:shared-output-eval-string (ein:connect-get-kernel) (buffer-string) nil :silent t))))
(deferred:nextc it
(lambda ()
(with-current-buffer b
(ein:connect-execute-autoexec-cells))))))
(ein:log 'info "Whole buffer is sent to the kernel."))
(defun ein:connect-run-buffer (&optional ask-command)
"Run buffer using ``%run``. Ask for command if the prefix ``C-u`` is given.
Variable `ein:connect-run-command' sets the default command."
(interactive "P")
(ein:aif (ein:aand (ein:get-url-or-port)
(ein:filename-to-python it (buffer-file-name)))
(let* ((default-command (ein:connect-run-command-get))
(command (if ask-command
(read-from-minibuffer "Command: " default-command)
default-command))
(cmd (format "%s \"%s\"" command it)))
(if (ein:maybe-save-buffer ein:connect-save-before-run)
(progn
(ein:shared-output-eval-string (ein:connect-get-kernel) cmd nil :silent t)
(ein:connect-execute-autoexec-cells)
(ein:log 'info "Command sent to the kernel: %s" cmd))
(ein:log 'info "Buffer must be saved before %%run.")))
(error (concat "This buffer has no associated file. "
"Use `ein:connect-eval-buffer' instead."))))
(defun ein:connect-run-or-eval-buffer (&optional eval)
"Run buffer using the ``%run`` magic command or eval whole
buffer if the prefix ``C-u`` is given.
Variable `ein:connect-run-command' sets the command to run.
You can change the command and/or set the options.
See also: `ein:connect-run-buffer', `ein:connect-eval-buffer'."
(interactive "P")
(if eval
(ein:connect-eval-buffer)
(ein:connect-run-buffer)))
(defun ein:connect-reload-buffer ()
"Reload buffer using the command set by `ein:connect-reload-command'."
(interactive)
(let ((ein:connect-run-command ein:connect-reload-command))
(call-interactively #'ein:connect-run-buffer)))
(defun ein:connect-eval-region (start end)
(interactive "r")
(ein:shared-output-eval-string (ein:connect-get-kernel) (buffer-substring start end) nil)
(ein:log 'info "Selected region is sent to the kernel."))
(define-obsolete-function-alias
'ein:connect-eval-string-internal
'ein:shared-output-eval-string "0.1.2")
(define-obsolete-function-alias
'ein:connect-request-tool-tip-or-help-command
'ein:pytools-request-tooltip-or-help "0.1.2")
(defun ein:connect-pop-to-notebook ()
(interactive)
(ein:connect-assert-connected)
(pop-to-buffer (ein:notebook-buffer (ein:connect-get-notebook))))
;;; Generic getter
(defun ein:get-url-or-port--connect ()
(ein:aand (ein:get-notebook--connect) (ein:$notebook-url-or-port it)))
(defun ein:get-notebook--connect ()
(when (ein:connect-p ein:%connect%)
(slot-value ein:%connect% 'notebook)))
(defun ein:get-kernel--connect ()
(ein:aand (ein:get-notebook--connect) (ein:$notebook-kernel it)))
(defun ein:get-traceback-data--connect ()
;; FIXME: Check if the TB in shared-output buffer is originated from
;; the current buffer.
(ein:aand (ein:shared-output-get-cell) (ein:cell-get-tb-data it)))
(autoload 'ein:shared-output-get-cell "ein-shared-output") ; FIXME: Remove!
;;; Auto-execution
(defun ein:connect-assert-connected ()
(cl-assert (ein:connect-p ein:%connect%) nil
"Current buffer (%s) is not connected to IPython notebook."
(buffer-name))
(cl-assert (ein:notebook-live-p (slot-value ein:%connect% 'notebook)) nil
"Connected notebook is not live (probably already closed)."))
(defun ein:connect-execute-autoexec-cells ()
"Call `ein:notebook-execute-autoexec-cells' via `after-save-hook'."
(ein:connect-assert-connected)
(when (slot-value ein:%connect% 'autoexec)
(ein:notebook-execute-autoexec-cells (ein:connect-get-notebook))))
(defun ein:connect-toggle-autoexec ()
"Toggle auto-execution mode of the current connected buffer.
When auto-execution mode is on, cells in connected notebook will
be automatically executed whenever run, eval or reload command [#]_
is called in this buffer.
.. [#] Namely, one of
* `ein:connect-run-buffer'
* `ein:connect-eval-buffer'
* `ein:connect-run-or-eval-buffer'
* `ein:connect-reload-buffer'
Note that you need to set cells to run in the connecting buffer
or no cell will be executed.
Use the `ein:worksheet-turn-on-autoexec' command in notebook to
change the cells to run."
(interactive)
(ein:connect-assert-connected)
(let ((autoexec-p (not (slot-value ein:%connect% 'autoexec))))
(setf (slot-value ein:%connect% 'autoexec) autoexec-p)
(ein:log 'info "Auto-execution mode is %s."
(if autoexec-p "enabled" "disabled"))))
;;; Auto-connect
;;;###autoload
(defun ein:connect-to-default-notebook ()
"Connect to the default notebook specified by
`ein:connect-default-notebook'. Set this to `python-mode-hook'
to automatically connect any python-mode buffer to the
notebook."
(ein:log 'verbose "CONNECT-TO-DEFAULT-NOTEBOOK")
(ein:and-let* ((nbpath ein:connect-default-notebook)
((not (ein:worksheet-buffer-p))))
(when (functionp nbpath)
(setq nbpath (funcall nbpath)))
(ein:connect-to-notebook nbpath nil t)))
;;; ein:connect-mode
(defvar ein:connect-mode-map (make-sparse-keymap))
(let ((map ein:connect-mode-map))
(define-key map "\C-c\C-c" 'ein:connect-run-or-eval-buffer)
(define-key map "\C-c\C-l" 'ein:connect-reload-buffer)
(define-key map "\C-c\C-r" 'ein:connect-eval-region)
(define-key map (kbd "C-:") 'ein:shared-output-eval-string)
(define-key map "\C-c\C-h" 'ein:pytools-request-tooltip-or-help)
(define-key map "\C-c\C-i" 'ein:completer-complete)
(define-key map "\C-c\C-z" 'ein:connect-pop-to-notebook)
(define-key map "\C-c\C-a" 'ein:connect-toggle-autoexec)
(define-key map "\C-c\C-o" 'ein:console-open)
(define-key map "\C-c\C-x" 'ein:tb-show)
(define-key map "\M-." 'ein:pytools-jump-to-source-command)
(define-key map (kbd "C-c C-.") 'ein:pytools-jump-to-source-command)
(define-key map "\M-," 'ein:pytools-jump-back-command)
(define-key map (kbd "C-c C-,") 'ein:pytools-jump-back-command)
(define-key map (kbd "C-c C-/") 'ein:notebook-scratchsheet-open)
map)
(defun ein:connect-mode-get-lighter ()
(if (slot-value ein:%connect% 'autoexec)
(format " ein:c%s" (or ein:connect-aotoexec-lighter
ein:cell-autoexec-prompt))
" ein:c"))
(define-minor-mode ein:connect-mode
"Minor mode for communicating with IPython notebook.
\\{ein:connect-mode-map}"
:lighter (:eval (ein:connect-mode-get-lighter))
:keymap ein:connect-mode-map
:group 'ein
(cl-case ein:completion-backend
(ein:use-ac-backend
(define-key ein:connect-mode-map "." 'ein:ac-dot-complete)
(auto-complete-mode))
(ein:use-company-backend
(add-to-list 'company-backends #'ein:company-backend)
(company-mode))))
(put 'ein:connect-mode 'permanent-local t)
(provide 'ein-connect)
;;; ein-connect.el ends here

View file

@ -1,235 +0,0 @@
;;; ein-console.el --- IPython console integration
;; Copyright (C) 2012 Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-console.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-console.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-console.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'ein-core)
;; Functions from `Fabian Gallina's python.el`_
;; NOTE: Do *not* load python.el here, since user may be using the other
;; version of python-mode.
(declare-function python-shell-make-comint "python")
(declare-function python-shell-get-process-name "python")
(declare-function python-shell-switch-to-shell "python")
;;; Define aliases to old variables and functions.
(define-obsolete-variable-alias
'ein:notebook-console-security-dir 'ein:console-security-dir "0.1.2")
(define-obsolete-variable-alias
'ein:notebook-console-executable 'ein:console-executable "0.1.2")
(define-obsolete-variable-alias
'ein:notebook-console-args 'ein:console-args "0.1.2")
(define-obsolete-function-alias
'ein:notebook-console-open 'ein:console-open "0.1.2")
;;; Configuration
(defcustom ein:console-security-dir ""
"Security directory setting.
Following types are valid:
string
Use this value as a path to security directory.
Handy when you have only one IPython server.
alist
An alist whose element is \"(URL-OR-PORT . DIR)\".
Key (URL-OR-PORT) can be string (URL), integer (port), or
`default' (symbol). The value of `default' is used when
other key does not much. Normally you should have this
entry.
function
Called with an argument URL-OR-PORT (integer or string).
You can have complex setting using this."
:type '(choice
(string :tag "Security directory"
"~/.config/ipython/profile_nbserver/security/")
(alist :tag "Security directory mapping"
:key-type (choice :tag "URL or PORT"
(string :tag "URL" "http://127.0.0.1:8888")
(integer :tag "PORT" 8888)
(const default))
:value-type (string :tag "Security directory"))
(function :tag "Security directory getter"
(lambda (url-or-port)
(format "~/.config/ipython/profile_%s/security/"
url-or-port))))
:group 'ein)
(defcustom ein:console-executable (executable-find "jupyter")
"IPython executable used for console.
Example: ``\"/user/bin/ipython\"``.
Types same as `ein:console-security-dir' are valid."
:type '(choice
(string :tag "IPython executable" "/user/bin/ipython")
(alist :tag "IPython executable mapping"
:key-type (choice :tag "URL or PORT"
(string :tag "URL" "http://127.0.0.1:8888")
(integer :tag "PORT" 8888)
(const default))
:value-type (string :tag "IPython executable"
"/user/bin/ipython"))
(function :tag "IPython executable getter"
(lambda (url-or-port) (executable-find "ipython"))))
:group 'ein)
(defcustom ein:console-args '()
"Additional argument when using console.
.. warning:: Space-separated string is obsolete now. Use a list
of string as value now.
Setting to use IPython profile named \"YOUR-IPYTHON-PROFILE\"::
(setq ein:console-args '(\"--profile\" \"YOUR-IPYTHON-PROFILE\"))
Together with `ein:console-security-dir', you can open IPython
console connecting to a remote kernel.::
(setq ein:console-args '(\"--ssh\" \"HOSTNAME\"))
(setq ein:console-security-dir \"PATH/TO/SECURITY/DIR\")
You can setup `ein:console-args' per server basis using alist form::
(setq ein:console-args
'((8888 . '(\"--profile\" \"PROFILE\"))
(8889 . '(\"--ssh\" \"HOSTNAME\"))
(default . '(\"--profile\" \"default\"))))
If you want to use more complex setting, you can set a function to it::
(setq ein:console-args
(lambda (url-or-port) '(\"--ssh\" \"HOSTNAME\")))
See also: `ein:console-security-dir'."
:type '(choice
(repeat (string :tag "Arguments to IPython" "--profile"))
(alist :tag "Arguments mapping"
:key-type (choice :tag "URL or PORT"
(string :tag "URL" "http://127.0.0.1:8888")
(integer :tag "PORT" 8888)
(const default))
:value-type
(repeat (string :tag "Arguments to IPython" "--profile")))
(function :tag "Additional arguments getter"
(lambda (url-or-port)
(list "--ssh" (format "%s" url-or-port)))))
:group 'ein)
(defun ein:console-security-dir-get (url-or-port)
(let ((dir (ein:choose-setting 'ein:console-security-dir url-or-port)))
(if (equal dir "")
dir
(file-name-as-directory (expand-file-name dir)))))
(defun ein:console-executable-get (url-or-port)
(or (ein:choose-setting 'ein:console-executable url-or-port)
(error "Cannot find console executable!")))
(defun ein:console-args-get (url-or-port)
(ein:choose-setting 'ein:console-args url-or-port
(lambda (x)
(or (stringp x)
(and (listp x)
(stringp (car x)))))))
(defun ein:ensure-url-or-port ()
(or (ein:get-url-or-port)
(error "Cannot find notebook to connect!")))
(defun ein:console-make-command ()
;; FIXME: use %connect_info to get connection file, then I can get
;; rid of `ein:console-security-dir'.
(let* ((url-or-port (ein:ensure-url-or-port))
(dir (ein:console-security-dir-get url-or-port))
(kid (ein:kernel-id (ein:get-kernel)))
(ipy (ein:console-executable-get url-or-port))
(args (ein:console-args-get url-or-port)))
;; FIMXE: do I need "python" here?
(append (list ipy "console" "--existing"
(format "%skernel-%s.json" dir kid))
(if (listp args)
args
(ein:display-warning-once
"String value for `ein:console-args' is obsolete.
Use list of string instead of space separated string.")
(split-string-and-unquote args)))))
(defun ein:console-get-buffer ()
(let ((url-or-port (ein:get-url-or-port))
(notebook (ein:get-notebook)))
(format "*ein:console %s/%s*" url-or-port (ein:notebook-name notebook))))
;;;###autoload
(defun ein:console-open ()
"Open IPython console.
To use this function, `ein:console-security-dir' and
`ein:console-args' must be set properly.
This function works best with the new python.el_ which is shipped
with Emacs 24.2 or later. If you don't have it, this function
opens a \"plain\" command line interpreter (comint) buffer where
you cannot use fancy stuff such as TAB completion.
It should be possible to support python-mode.el. Patches are welcome!
.. _python.el: https://github.com/fgallina/python.el"
(interactive)
;; FIXME: Workaround for running current version of Jupyter console on windows
(when (eql system-type 'windows-nt)
(if (string-match-p "jupyter" (ein:console-executable-get (ein:ensure-url-or-port)))
(setenv "JUPYTER_CONSOLE_TEST" "1")
(setenv "IPY_TEST_SIMPLE_PROMPT" "1")))
(if (fboundp 'python-shell-switch-to-shell)
(let ((cmd (mapconcat #'shell-quote-argument
(ein:console-make-command) " "))
;; python.el settings:
(python-shell-setup-codes nil)
;; python.el makes dedicated process when
;; `buffer-file-name' has some value.
(buffer-file-name (buffer-name)))
;; The following line does what `run-python' does.
;; But as `run-python' changed the call signature in the new
;; version, let's do this manually.
;; See also: https://github.com/tkf/emacs-ipython-notebook/pull/50
(run-python cmd)
;(python-shell-make-comint cmd (python-shell-get-process-name t))
;; Pop to inferior Python process buffer
(python-shell-switch-to-shell))
(let* ((command (ein:console-make-command))
(program (car command))
(args (cdr command))
(buffer (ein:console-get-buffer)))
(apply #'make-comint-in-buffer
"ein:console" buffer program nil args)
(pop-to-buffer buffer))))
(provide 'ein-console)
;;; ein-console.el ends here

Binary file not shown.

Binary file not shown.

View file

@ -1,51 +0,0 @@
;;; ein-hy.el --- Hylang Support -*- lexical-binding: t; -*-
;; (C) 2018 - John M. Miller
;; Author: John Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-hy.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-hy.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-hy.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;; Code:
(require 'ein-classes)
(cl-defmethod ein:cell-insert-prompt ((cell ein:hy-codecell))
"Insert prompt of the CELL in the buffer.
Called from ewoc pretty printer via `ein:cell-pp'."
;; Newline is inserted in `ein:cell-insert-input'.
(ein:insert-read-only
(concat
(format "In (hy) [%s]" (or (ein:oref-safe cell 'input-prompt-number) " "))
(ein:maybe-show-slideshow-data cell)
(when (slot-value cell 'autoexec) " %s" ein:cell-autoexec-prompt))
'font-lock-face 'ein:cell-input-prompt))
(cl-defmethod ein:cell-execute-internal ((cell ein:hy-codecell)
kernel code &rest args)
(ein:cell-clear-output cell t t t)
(ein:cell-set-input-prompt cell "*")
(ein:cell-running-set cell t)
(setf (slot-value cell 'dynamic) t)
(apply #'ein:kernel-execute kernel (ein:pytools-wrap-hy-code code) (ein:cell-make-callbacks cell) args))
(cl-defmethod ein:cell-to-nb4-json :before ((cell ein:hy-codecell) _ &optional _ignore)
(let ((metadata (slot-value cell 'metadata)))
(setf metadata (plist-put metadata :ein.hycell t))))
(provide 'ein-hy)

Binary file not shown.

View file

@ -1,125 +0,0 @@
;;; -*- mode: emacs-lisp; lexical-binding: t -*-
;;; ein-inspector.el --- An inspector, in emacs, for Python
;; Copyright (C) 2017 - John Miller
;; Authors: Takafumi Arakaki <aka.tkf at gmail.com>
;; John M. Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-inspector.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-inspector.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-inspector.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;; Code:
(require 'ein-pytools)
;;;###autoload
(defun ein:inspect-object (kernel object)
(interactive (list (ein:get-kernel-or-error)
(ein:object-at-point-or-error)))
(ein:kernel-execute kernel
(format "__import__('ein_inspector').generate_inspector_data('%s', globals(), locals())"
object)
(list
:output
(cons #'ein:prepare-inspector
(list kernel object)))))
(defun ein:prepare-inspector (packed _msg-type content _metadata)
(cl-destructuring-bind (_kernel oname)
packed
(ein:aif (or (plist-get content :text) (plist-get content :data))
(let ((oinfo (ein:json-read-from-string it)))
(if (not (plist-get oinfo :type))
(ein:log 'warn "[EIN:INSPECTOR]: %s" (plist-get oinfo :error))
(ein:render-inspector oinfo)))
(ein:log 'warn "[EIN:INSPECTOR]: Could not find inspect data for object %s." oname))))
(defclass ein:iobject ()
((name :accessor ein:iobject-name :documentation "String representation can be evaluated in python to generate the object being inspected.")
(type :accessor ein:iobject-type :documentation "Python type of object, as returned by `type()`.")
(repr :accessor ein:iobject-repr :documentation "Value of object, as returned by its `__str__` method.")
(source-file :accessor ein:iobject-sfile :documentation "If availabe, the filename where the source for this object is to be found.")
(source-lines :accessor ein:iobject-slines :documentation "If available, the line in the file where the source for this object is found.")
(doc :accessor ein:iobject-doc :documentation "If available, the documentation string for this object."))
:documentation "Class to hold information returned by Python `inspect` module for a Python object identified in the `name` slot.")
(defun ein:new-inspector-object (object-info)
(make-instance 'ein:iobject
:name (plist-get object-info :name)
:type (plist-get object-info :type)
:repr (plist-get object-info :repr)
:source-file (plist-get object-info :source_file)
:source-lines (plist-get object-info :source_lines)
:doc (plist-get object-info :doc)))
(defvar ein:inspector-visit-source-map (make-sparse-keymap))
(defvar ein:inspector-mode-map
(let ((map (make-sparse-keymap)))
(set-keymap-parent map (make-composed-keymap widget-keymap
special-mode-map))
map)
"Keymap for ein:inspector-mode.")
(define-derived-mode ein:inspector-mode special-mode "EIN:INSPECTOR-MODE"
"Major mode for inspector Python objects from the emacs-ipython-notebook."
)
(defun ein:render-inspector (oinfo)
(let ((name (plist-get oinfo :name)))
(switch-to-buffer (format "*EIN Inspector: %s*" name))
(kill-all-local-variables)
(let ((inhibit-read-only t))
(erase-buffer))
(remove-overlays)
(let* ((type (plist-get oinfo :type))
(repr (plist-get oinfo :repr))
(sfile (plist-get oinfo :source_file))
(slines (last (plist-get oinfo :source_lines)))
(info-str (format "%s = {%s} %s" name type repr)))
(if sfile
(widget-create 'link
:notify
(lambda (&rest _ignore)
(ein:goto-file sfile (car slines)))
info-str)
(widget-insert (propertize info-str 'face 'bold)))
(widget-insert (format "\n\n%s\n\n" (make-string 80 ?\u2501)))
(widget-insert (format "%s\n\n%s\n\n" (plist-get oinfo :doc) (make-string 80 ?\u2501)))
(widget-insert (propertize (format "%s: %s\n" type name)
'face 'bold))))
(ein:inspector-mode)
(widget-setup))
(defun ein:inspector-visit-source ()
(message "Visit source!"))
(defun ein:inspector-visit-thing ())
(defun ein:inspector-section-toggle (_section))
(defun ein:inspector-section-show (_section))
(defun ein:inspector-section-hide (_section)
)
(provide 'ein-inspector)

View file

@ -1,279 +0,0 @@
;;; ein-jupyter.el --- Manage the jupyter notebook server -*- lexical-binding: t -*-
;; Copyright (C) 2017 John M. Miller
;; Authors: John M. Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-jupyter.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-jupyter.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-jupyter.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;; Code:
(require 'ein-core)
(require 'ein-notebooklist)
(require 'ein-dev)
(defcustom ein:jupyter-server-buffer-name "*ein:jupyter-server*"
"The name of the buffer for the jupyter notebook server
session."
:group 'ein
:type 'string)
(defcustom ein:jupyter-server-run-timeout 60000
"Time, in milliseconds, to wait for the jupyter server to start before declaring timeout and cancelling the operation."
:group 'ein
:type 'integer)
(defcustom ein:jupyter-server-args '("--no-browser")
"Add any additional command line options you wish to include
with the call to the jupyter notebook."
:group 'ein
:type '(repeat string))
(defcustom ein:jupyter-default-notebook-directory nil
"If you are tired of always being queried for the location of
the notebook directory, you can set it here for future calls to
`ein:jupyter-server-start'"
:group 'ein
:type '(directory))
(defvar *ein:jupyter-server-accept-timeout* 60)
(defvar *ein:jupyter-server-process-name* "EIN: Jupyter notebook server")
(defvar *ein:last-jupyter-command* nil)
(defvar *ein:last-jupyter-directory* nil)
(defcustom ein:jupyter-default-server-command "jupyter"
"The default command to start a jupyter notebook server.
Changing this to `jupyter-notebook' requires customizing `ein:jupyter-server-use-subcommand' to nil.
"
:group 'ein
:type '(file)
:set (lambda (symbol value)
(set-default symbol value)
(setq *ein:last-jupyter-command* nil)))
(defcustom ein:jupyter-server-use-subcommand "notebook"
"Users of \"jupyter-notebook\" (as opposed to \"jupyter notebook\") need to `Omit'."
:group 'ein
:type '(choice (string :tag "Subcommand" "notebook")
(const :tag "Omit" nil)))
(defcustom ein:jupyter-default-kernel 'first-alphabetically
"With which of ${XDG_DATA_HOME}/jupyter/kernels to create new notebooks."
:group 'ein
:type (append
'(choice (other :tag "First alphabetically" first-alphabetically))
(condition-case err
(mapcar
(lambda (x) `(const :tag ,(cdr x) ,(car x)))
(cl-loop
for (k . spec) in
(alist-get
'kernelspecs
(let ((json-object-type 'alist))
(json-read-from-string
(shell-command-to-string
(format "%s kernelspec list --json"
ein:jupyter-default-server-command)))))
collect `(,k . ,(alist-get 'display_name (alist-get 'spec spec)))))
(error (ein:log 'warn "ein:jupyter-default-kernel: %s" err)
'((string :tag "Ask"))))))
(defsubst ein:jupyter-server-process ()
"Return the emacs process object of our session"
(get-buffer-process (get-buffer ein:jupyter-server-buffer-name)))
(defun ein:jupyter-server--run (buf cmd dir &optional args)
(when ein:debug
(add-to-list 'ein:jupyter-server-args "--debug"))
(unless (stringp dir)
(error "ein:jupyter-server--run: notebook directory required"))
(let* ((vargs (append (ein:aif ein:jupyter-server-use-subcommand (list it))
(list (format "--notebook-dir=%s" (convert-standard-filename dir)))
args
ein:jupyter-server-args))
(proc (apply #'start-process
*ein:jupyter-server-process-name* buf cmd vargs)))
(ein:log 'info "ein:jupyter-server--run: %s %s" cmd (ein:join-str " " vargs))
(set-process-query-on-exit-flag proc nil)
proc))
(defun ein:jupyter-server-conn-info (&optional buffer-name)
"Return the url-or-port and password for BUFFER or the global session."
(unless buffer-name
(setq buffer-name ein:jupyter-server-buffer-name))
(let ((buffer (get-buffer buffer-name))
(result '(nil nil)))
(if buffer
(with-current-buffer buffer
(save-excursion
(goto-char (point-max))
(re-search-backward (format "Process %s" *ein:jupyter-server-process-name*)
nil "") ;; important if we start-stop-start
(when (re-search-forward "\\([[:alnum:]]+\\) is\\( now\\)? running" nil t)
(let ((hub-p (cl-search "jupyterhub" (downcase (match-string 1)))))
(when (re-search-forward "\\(https?://[^:]*:[0-9]+\\)\\(?:/\\?token=\\([[:alnum:]]+\\)\\)?" nil t)
(let ((raw-url (match-string 1))
(token (or (match-string 2) (and (not hub-p) ""))))
(setq result (list (ein:url raw-url) token)))))))))
result))
(defun ein:jupyter-server-login-and-open (&optional callback)
"Log in and open a notebooklist buffer for a running jupyter notebook server.
Determine if there is a running jupyter server (started via a
call to `ein:jupyter-server-start') and then try to guess if
token authentication is enabled. If a token is found use it to generate a
call to `ein:notebooklist-login' and once authenticated open the notebooklist buffer
via a call to `ein:notebooklist-open'."
(interactive)
(when (ein:jupyter-server-process)
(cl-multiple-value-bind (url-or-port _password) (ein:jupyter-server-conn-info)
(ein:notebooklist-login url-or-port callback))))
(defsubst ein:set-process-sentinel (proc url-or-port)
"URL-OR-PORT might get redirected from (ein:jupyter-server-conn-info).
This is currently only the case for jupyterhub.
Once login handshake provides the new URL-OR-PORT, we set various state as pertains
our singleton jupyter server process here."
;; Would have used `add-function' if it didn't produce gv-ref warnings.
(set-process-sentinel
proc
(apply-partially (lambda (url-or-port* sentinel proc* event)
(ein:aif sentinel (funcall it proc* event))
(funcall #'ein:notebooklist-sentinel url-or-port* proc* event))
url-or-port (process-sentinel proc))))
;;;###autoload
(defun ein:jupyter-server-start (server-cmd-path notebook-directory
&optional no-login-p login-callback port)
"Start SERVER-CMD_PATH with `--notebook-dir' NOTEBOOK-DIRECTORY. Login after connection established unless NO-LOGIN-P is set. LOGIN-CALLBACK takes two arguments, the buffer created by ein:notebooklist-open--finish, and the url-or-port argument of ein:notebooklist-open*.
This command opens an asynchronous process running the jupyter
notebook server and then tries to detect the url and password to
generate automatic calls to `ein:notebooklist-login' and
`ein:notebooklist-open'.
With \\[universal-argument] prefix arg, it will prompt the user for the path to
the jupyter executable first. Else, it will try to use the
value of `*ein:last-jupyter-command*' or the value of the
customizable variable `ein:jupyter-default-server-command'.
Then it prompts the user for the path of the root directory
containing the notebooks the user wants to access.
The buffer named by `ein:jupyter-server-buffer-name' will contain
the log of the running jupyter server."
(interactive
(let* ((default-command (or *ein:last-jupyter-command*
ein:jupyter-default-server-command))
(server-cmd-path
(executable-find (if current-prefix-arg
(read-file-name "Server command: " default-directory nil nil
default-command)
default-command)))
(notebook-directory
(read-directory-name "Notebook directory: "
(or *ein:last-jupyter-directory*
ein:jupyter-default-notebook-directory))))
(list server-cmd-path notebook-directory nil #'(lambda (buffer _url-or-port)
(pop-to-buffer buffer)))))
(unless (and (stringp server-cmd-path)
(file-exists-p server-cmd-path)
(file-executable-p server-cmd-path))
(error "Command %s not found or not executable"
(or *ein:last-jupyter-command*
ein:jupyter-default-server-command)))
(setf *ein:last-jupyter-command* server-cmd-path
*ein:last-jupyter-directory* notebook-directory)
(if (ein:jupyter-server-process)
(error "Please first M-x ein:stop"))
(add-hook 'kill-emacs-hook #'(lambda ()
(ignore-errors (ein:jupyter-server-stop t))))
(let ((proc (ein:jupyter-server--run ein:jupyter-server-buffer-name
*ein:last-jupyter-command*
*ein:last-jupyter-directory*
(if (numberp port)
`("--port" ,(format "%s" port)
"--port-retries" "0")))))
(when (eql system-type 'windows-nt)
(accept-process-output proc (/ ein:jupyter-server-run-timeout 1000)))
(cl-loop repeat 30
until (car (ein:jupyter-server-conn-info ein:jupyter-server-buffer-name))
do (sleep-for 0 500)
finally do
(unless (car (ein:jupyter-server-conn-info ein:jupyter-server-buffer-name))
(ein:log 'warn "Jupyter server failed to start, cancelling operation")
(ein:jupyter-server-stop t)))
(when (and (not no-login-p) (ein:jupyter-server-process))
(unless login-callback
(setq login-callback #'ignore))
(add-function :after (var login-callback)
(apply-partially (lambda (proc* _buffer url-or-port)
(ein:set-process-sentinel proc* url-or-port))
proc))
(ein:jupyter-server-login-and-open login-callback))))
;;;###autoload
(defalias 'ein:run 'ein:jupyter-server-start)
;;;###autoload
(defalias 'ein:stop 'ein:jupyter-server-stop)
(defun ein:undocumented-shutdown (url-or-port)
(ein:query-singleton-ajax
(list 'shutdown-server url-or-port)
(ein:url url-or-port "api/shutdown")
:type "POST"
:timeout 3 ;; content-query-timeout and query-timeout default nil
:sync t))
;;;###autoload
(defun ein:jupyter-server-stop (&optional force log)
(interactive)
(ein:and-let* ((url-or-port (car (ein:jupyter-server-conn-info)))
(ok (or force (y-or-n-p "Stop server and close notebooks?"))))
(ein:notebook-close-notebooks t)
(cl-loop repeat 10
do (ein:query-running-process-table)
until (zerop (hash-table-count ein:query-running-process-table))
do (sleep-for 0 500))
(if (eq system-type 'windows-nt)
(progn
(ein:undocumented-shutdown url-or-port)
(ein:aif (ein:jupyter-server-process)
(delete-process it)))
(let* ((proc (ein:jupyter-server-process))
(pid (process-id proc)))
(ein:log 'info "Signaled %s with pid %s" proc pid)
(signal-process pid 15)
(run-at-time 2 nil
(lambda ()
(ein:log 'info "Resignaled %s with pid %s" proc pid)
(signal-process pid 15)))))
;; `ein:notebooklist-sentinel' frequently does not trigger
(ein:notebooklist-list-remove url-or-port)
(kill-buffer (ein:notebooklist-get-buffer url-or-port))
(when log
(with-current-buffer ein:jupyter-server-buffer-name
(write-region (point-min) (point-max) log)))))
(provide 'ein-jupyter)

Binary file not shown.

View file

@ -1,115 +0,0 @@
;;; ein-kernelinfo.el --- Kernel info module
;; Copyright (C) 2012 Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-kernelinfo.el is free software: you can redistribute it and/or
;; modify it under the terms of the GNU General Public License as
;; published by the Free Software Foundation, either version 3 of the
;; License, or (at your option) any later version.
;; ein-kernelinfo.el is distributed in the hope that it will be
;; useful, but WITHOUT ANY WARRANTY; without even the implied warranty
;; of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-kernelinfo.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'ein-kernel)
(require 'eieio)
(defclass ein:kernelinfo ()
((kernel
:initarg :kernel :type ein:$kernel
:documentation "Kernel instance.")
(get-buffers
:initarg :get-buffers
:documentation "A packed function to get buffers associated
with the kernel. The buffer local `default-directory' variable
in these buffer will be synced with the kernel's cwd.")
(hostname
:initarg :hostname :type string
:documentation "Host name of the machine where the kernel is running on.")
(language
:initarg :language :type string
:accessor ein:kernelinfo-language
:documentation "Language for the running kernel.")
(ccwd
:initarg :ccwd :type string
:documentation "cached CWD (last time checked CWD)."))
:documentation "Info related (but unimportant) to kernel")
(defun ein:kernelinfo-new (kernel get-buffers kernel-language)
"Make a new `ein:kernelinfo' instance based on KERNEL and GET-BUFFERS."
(let ((kerinfo (make-instance 'ein:kernelinfo)))
(setf (slot-value kerinfo 'kernel) kernel)
(setf (slot-value kerinfo 'get-buffers) get-buffers)
(setf (slot-value kerinfo 'language) kernel-language)
(ein:case-equal kernel-language
("python" (ein:kernelinfo-setup-hooks kerinfo)))
kerinfo))
(defun ein:kernelinfo-setup-hooks (kerinfo)
"Add `ein:kernelinfo-update-*' to `ein:$kernel-after-*-hook'."
(with-slots (kernel) kerinfo
(push (cons #'ein:kernelinfo-update-all kerinfo)
(ein:$kernel-after-start-hook kernel))
(push (cons #'ein:kernelinfo-update-ccwd kerinfo)
(ein:$kernel-after-execute-hook kernel))))
(defun ein:kernelinfo-update-all (kerinfo)
"Update KERINFO slots by triggering all update functions."
(ein:log 'debug "(ein:kernel-live-p kernel) = %S"
(ein:kernel-live-p (slot-value kerinfo 'kernel)))
(ein:kernelinfo-update-ccwd kerinfo)
(ein:kernelinfo-update-hostname kerinfo))
(defun ein:kernelinfo-update-ccwd (kerinfo)
"Update cached current working directory (CCWD) and change
`default-directory' of kernel related buffers."
(let ((ccwd-string (ein:case-equal (ein:kernelinfo-language kerinfo)
(("python") "__import__('sys').stdout.write(__import__('os').getcwd())")
((t) nil))))
(when ccwd-string
(ein:kernel-request-stream
(slot-value kerinfo 'kernel)
ccwd-string
(lambda (cwd kerinfo)
(with-slots (kernel get-buffers) kerinfo
(setq cwd (ein:kernel-filename-from-python kernel cwd))
(oset kerinfo :ccwd cwd)
;; sync buffer's `default-directory' with CWD
(when (file-accessible-directory-p cwd)
(dolist (buffer (ein:funcall-packed get-buffers))
(when (buffer-live-p buffer)
(with-current-buffer buffer
(setq default-directory (file-name-as-directory cwd))))))))
(list kerinfo)))))
(defun ein:kernelinfo-update-hostname (kerinfo)
"Get hostname in which kernel is running and store it in KERINFO."
(let ((hostname-string (ein:case-equal (ein:kernelinfo-language kerinfo)
(("python") "__import__('sys').stdout.write(__import__('socket').gethostname())")
((t) nil))))
(when hostname-string
(ein:kernel-request-stream
(slot-value kerinfo 'kernel)
hostname-string ; "__import__('sys').stdout.write(__import__('socket').gethostname())" ; uname() not available in windows
(lambda (hostname kerinfo)
(oset kerinfo :hostname hostname))
(list kerinfo)))))
(provide 'ein-kernelinfo)
;;; ein-kernelinfo.el ends here

View file

@ -1,78 +0,0 @@
;;; ein-multilang-fontify.el --- Syntax highlighting for multiple-languages
;; Copyright (C) 2012 Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-multilang-fontify.el is free software: you can redistribute it
;; and/or modify it under the terms of the GNU General Public License
;; as published by the Free Software Foundation, either version 3 of
;; the License, or (at your option) any later version.
;; ein-multilang-fontify.el is distributed in the hope that it will be
;; useful, but WITHOUT ANY WARRANTY; without even the implied warranty
;; of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-multilang-fontify.el.
;; If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
;; It would be nice if org-src is available, but this module should
;; work without org-src. Data on `org-src-lang-modes' is used
;; if this variable is bound.
(require 'org-src nil t)
(defun ein:mlf-get-lang-mode (lang)
"Return major mode for LANG.
Modified version of `org-src-get-lang-mode'."
(when (symbolp lang)
(setq lang (symbol-name lang)))
(intern
(format "%s-mode"
(or (and (bound-and-true-p org-src-lang-modes)
(cdr (assoc lang org-src-lang-modes)))
lang))))
(defun ein:mlf-font-lock-fontify-block (lang start end)
"Patched version of `org-src-font-lock-fontify-block'."
(let ((lang-mode (ein:mlf-get-lang-mode lang)))
(if (fboundp lang-mode)
(let ((string (buffer-substring-no-properties start end))
(modified (buffer-modified-p))
(orig-buffer (current-buffer))
pos
next)
(remove-text-properties start end '(face nil))
(with-current-buffer
(get-buffer-create
(concat " ein:mlf-fontification:" (symbol-name lang-mode)))
(delete-region (point-min) (point-max))
(insert string)
(unless (eq major-mode lang-mode) (funcall lang-mode))
(font-lock-fontify-buffer)
(setq pos (point-min))
(cl-loop for next = (next-single-property-change pos 'face nil (point-max))
do (put-text-property
;; `font-lock-face' property is used instead of `font'.
;; This is the only difference from org-src.
(+ start (1- pos)) (+ start next) 'font-lock-face
(get-text-property pos 'face) orig-buffer)
do (setq pos next)
until (eq pos (point-max))))
(add-text-properties
start end
'(font-lock-fontified t fontified t font-lock-multiline t))
(set-buffer-modified-p modified)))))
(provide 'ein-multilang-fontify)
;;; ein-multilang-fontify.el ends here

View file

@ -1,434 +0,0 @@
;;; ein-multilang.el --- Notebook mode with multiple language fontification
;; Copyright (C) 2012 Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-multilang.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-multilang.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-multilang.el.
;; If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(eval-when-compile (defvar markdown-mode-map))
(require 'ein-worksheet)
(require 'ein-multilang-fontify)
(require 'python)
(require 'ess-r-mode nil t)
(require 'ess-custom nil t)
(require 'clojure-mode nil t)
(require 'julia-mode nil t)
(require 'haskell-mode nil t)
(require 'hy-mode nil t)
(require 'cc-mode)
(declare-function ess-indent-line "ess")
(declare-function ess-r-eldoc-function "ess-r-completion")
(declare-function ess-setq-vars-local "ess-utils")
(declare-function haskell-indentation-indent-line "haskell-indentation")
(defun ein:ml-fontify (limit)
"Fontify next input area comes after the current point then
return `t' or `nil' if not found.
See info node `(elisp) Search-based Fontification'."
(ein:log-ignore-errors
(ein:ml-fontify-1 limit)))
(defun ein:ml-current-or-next-input-cell (ewoc-node)
"Almost identical to `ein:worksheet-next-input-cell' but return
the current cell if EWOC-NODE is the input area node."
(let* ((ewoc-data (ewoc-data ewoc-node))
(cell (ein:$node-data ewoc-data))
(path (ein:$node-path ewoc-data))
(element (nth 1 path)))
(if (memql element '(prompt input))
cell
(ein:cell-next cell))))
(defun ein:ml-fontify-1 (limit)
"Actual implementation of `ein:ml-fontify'.
This function may raise an error."
(ein:and-let* ((pos (point))
(node (ein:worksheet-get-nearest-cell-ewoc-node pos limit))
(cell (ein:ml-current-or-next-input-cell node))
(start (ein:cell-input-pos-min cell))
(end (ein:cell-input-pos-max cell))
((<= end limit))
((< start end))
(lang (ein:cell-language cell)))
(let ((inhibit-read-only t))
(ein:mlf-font-lock-fontify-block lang start end)
;; Emacs fontification mechanism requires the function to move
;; the point. Do *not* use `(goto-char end)'. As END is in the
;; input area, fontification falls into an infinite loop.
(ewoc-goto-node (slot-value cell 'ewoc) (ein:cell-element-get cell :footer)))
t))
(defun ein:ml-back-to-prev-node ()
(ein:aand (ein:worksheet-get-ewoc) (ewoc-goto-prev it 1)))
(defvar ein:ml-font-lock-keywords
'((ein:ml-fontify))
"Default `font-lock-keywords' for `ein:notebook-multilang-mode'.")
(defun ein:ml-set-font-lock-defaults ()
(setq-local font-lock-defaults
'(ein:ml-font-lock-keywords
;; The following are adapted from org-mode but I am not sure
;; if I need them:
t nil nil
ein:ml-back-to-prev-node)))
;;;###autoload
(define-derived-mode ein:notebook-multilang-mode prog-mode "EIN"
"A mode for fontifying multiple languages.
\\{ein:notebook-multilang-mode-map}
"
(setq-local beginning-of-defun-function
'ein:worksheet-beginning-of-cell-input)
(setq-local end-of-defun-function
'ein:worksheet-end-of-cell-input)
(ein:ml-set-font-lock-defaults))
(eval-after-load "auto-complete"
'(add-to-list 'ac-modes 'ein:notebook-multilang-mode))
;;; Language setup functions
(defun ein:ml-narrow-to-cell ()
"Narrow to the current cell."
(ein:and-let* ((pos (point))
(node (ein:worksheet-get-nearest-cell-ewoc-node pos))
(cell (ein:ml-current-or-next-input-cell node))
(start (ein:cell-input-pos-min cell))
(end (ein:cell-input-pos-max cell))
((< start end)))
(narrow-to-region start end)))
(defun ein:ml-indent-line-function (lang-func)
(save-restriction
(ein:ml-narrow-to-cell)
(funcall lang-func)))
(defun ein:ml-indent-region (lang-func start end)
(save-restriction
(ein:ml-narrow-to-cell)
(funcall lang-func start end)))
(defun ein:ml-lang-setup-python ()
"Presumably tkf had good reasons to choose only these forms from `python-mode'."
(setq-local mode-name "EIN[Py]")
(setq-local comment-start "# ")
(setq-local comment-start-skip "#+\\s-*")
(setq-local parse-sexp-lookup-properties t)
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'python-indent-line-function))
(setq-local indent-region-function
(apply-partially #'ein:ml-indent-region #'python-indent-region))
(set-syntax-table python-mode-syntax-table)
(set-keymap-parent ein:notebook-multilang-mode-map python-mode-map))
(defun ein:ml-lang-setup-clojure ()
"Minimally different than the the python setup"
(when (featurep 'clojure-mode)
(setq-local mode-name "EIN[Clj]")
(setq-local comment-start "; ")
(setq-local comment-start-skip ";+\\s-*")
(setq-local parse-sexp-lookup-properties t)
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'clojure-indent-line))
(setq-local indent-region-function
(apply-partially #'ein:ml-indent-region #'clojure-indent-region))
(set-syntax-table clojure-mode-syntax-table)
(set-keymap-parent ein:notebook-multilang-mode-map clojure-mode-map)))
(defun ein:ml-lang-setup-julia ()
(when (featurep 'julia-mode)
(setq-local mode-name "EIN[julia]")
(setq-local comment-start "# ")
(setq-local comment-start-skip "#+\\s-*")
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'julia-indent-line))
(when (boundp 'julia-mode-syntax-table)
(set-syntax-table julia-mode-syntax-table))
(when (boundp 'julia-mode-map)
(set-keymap-parent ein:notebook-multilang-mode-map julia-mode-map))))
(defun ein:ml-lang-setup-R ()
(when (and (featurep 'ess-r-mode) (featurep 'ess-custom))
(setq-local mode-name "EIN[R]")
(when (boundp 'ess-r-customize-alist)
(ess-setq-vars-local ess-r-customize-alist))
(setq-local paragraph-start (concat "\\s-*$\\|" page-delimiter))
(setq-local paragraph-separate (concat "\\s-*$\\|" page-delimiter))
(setq-local paragraph-ignore-fill-prefix t)
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'ess-indent-line))
(when (and (boundp 'ess-style) (boundp 'ess-default-style))
(setq-local ess-style ess-default-style))
(when (and (boundp 'prettify-symbols-alist) (boundp 'ess-r-prettify-symbols))
(setq-local prettify-symbols-alist ess-r-prettify-symbols))
(when (boundp 'ess-r-mode-syntax-table)
(set-syntax-table ess-r-mode-syntax-table))
(when (boundp 'ess-r-mode-map)
(set-keymap-parent ein:notebook-multilang-mode-map ess-r-mode-map))))
(defun ein:ml-lang-setup-haskell ()
(when (featurep 'haskell-mode)
(setq-local mode-name "EIN[haskell]")
(setq-local comment-start "-- ")
;; (setq-local comment-start-skip "--\\s-*")
(when (boundp 'haskell-indentation-indent-line)
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'haskell-indentation-indent-line)))
(when (boundp 'haskell-mode-syntax-table)
(set-syntax-table haskell-mode-syntax-table))
(when (boundp 'haskell-mode-map)
(set-keymap-parent ein:notebook-multilang-mode-map haskell-mode-map))))
(defun ein:ml-lang-setup-hy ()
(when (featurep 'hy-mode)
(setq-local mode-name "EIN[hy]")
(hy-mode--setup-font-lock)
(hy-mode--setup-syntax)
(hy-mode--support-smartparens)
(set-keymap-parent ein:notebook-multilang-mode-map hy-mode-map)))
(defun ein:ml-lang-setup-c++ ()
(when (featurep 'c++-mode)
(setq-local mode-name "EIN[c++]")
(setq-local comment-start "// ")
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'c-indent-line))
(set-syntax-table c++-mode-syntax-table)
(set-keymap-parent ein:notebook-multilang-mode-map c++-mode-map)))
(defun ein:ml-lang-setup-c ()
(when (featurep 'c-mode)
(setq-local mode-name "EIN[c]")
(setq-local comment-start "/* ")
(setq-local comment-end " */")
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'c-indent-line))
(set-syntax-table c-mode-syntax-table)
(set-keymap-parent ein:notebook-multilang-mode-map c-mode-map)))
(defun ein:ml-lang-setup-C++11 ()
(ein:ml-lang-setup-c++))
(defun ein:ml-lang-setup-C++14 ()
(ein:ml-lang-setup-c++))
(defun ein:ml-lang-setup-C++17 ()
(ein:ml-lang-setup-c++))
(defun ein:ml-lang-setup-generic ()
(setq-local mode-name "EIN[unknown]")
(setq-local indent-line-function
(apply-partially #'ein:ml-indent-line-function #'indent-relative))
(set-syntax-table prog-mode-syntax-table)
(set-keymap-parent ein:notebook-multilang-mode-map prog-mode-map))
(defun ein:ml-lang-setup (kernelspec)
(let ((setup-func (intern (concat "ein:ml-lang-setup-" (ein:$kernelspec-language kernelspec)))))
(if (fboundp setup-func)
(funcall setup-func)
(warn "ein:ml-lang-setup: unknown kernelspec language '%s', multilang support disabled."
(ein:$kernelspec-language kernelspec))
(ein:ml-lang-setup-generic))))
;; (defun ein:ml-lang-setup-markdown ()
;; "Use `markdown-mode-map'. NOTE: This function is not used now."
;; (when (featurep 'markdown-mode)
;; (set-keymap-parent ein:notebook-multilang-mode-map markdown-mode-map)))
;;; yasnippet
(defvar ein:ml-yasnippet-parents '(python-mode markdown-mode)
"Parent modes for `ein:notebook-multilang-mode' to register in yasnippet.")
(defun ein:ml-setup-yasnippet ()
(cl-loop for define-parents in '(yas/define-parents
yas--define-parents)
when (fboundp define-parents)
do (ignore-errors
;; `let' is for workaround the bug in yasnippet
(let ((mode-sym 'ein:notebook-multilang-mode))
(funcall define-parents
mode-sym
ein:ml-yasnippet-parents)))))
(eval-after-load "yasnippet" '(ein:ml-setup-yasnippet))
;;; Imenu Support
;; Most of this is borrowed from python.el
;; Just replace python with ein in most cases.
(defvar ein:imenu-format-item-label-function
'ein:imenu-format-item-label
"Imenu function used to format an item label.
It must be a function with two arguments: TYPE and NAME.")
(defvar ein:imenu-format-parent-item-label-function
'ein:imenu-format-parent-item-label
"Imenu function used to format a parent item label.
It must be a function with two arguments: TYPE and NAME.")
(defvar ein:imenu-format-parent-item-jump-label-function
'ein:imenu-format-parent-item-jump-label
"Imenu function used to format a parent jump item label.
It must be a function with two arguments: TYPE and NAME.")
(defun ein:imenu-format-item-label (type name)
"Return Imenu label for single node using TYPE and NAME."
(format "%s (%s)" name type))
(defun ein:imenu-format-parent-item-label (type name)
"Return Imenu label for parent node using TYPE and NAME."
(format "%s..." (ein:imenu-format-item-label type name)))
(defun python-imenu-format-parent-item-jump-label (type _name)
"Return Imenu label for parent node jump using TYPE and NAME."
(if (string= type "class")
"*class definition*"
"*function definition*"))
(defun ein:imenu--put-parent (type name pos tree)
"Add the parent with TYPE, NAME and POS to TREE."
(let ((label
(funcall ein:imenu-format-item-label-function type name))
(jump-label
(funcall ein:imenu-format-parent-item-jump-label-function type name)))
(if (not tree)
(cons label pos)
(cons label (cons (cons jump-label pos) tree)))))
(defun ein:imenu--build-tree (&optional min-indent prev-indent tree)
"Recursively build the tree of nested definitions of a node.
Arguments MIN-INDENT, PREV-INDENT and TREE are internal and should
not be passed explicitly unless you know what you are doing."
(setq min-indent (or min-indent 0)
prev-indent (or prev-indent python-indent-offset))
(let* ((pos (python-nav-backward-defun))
(type)
(name (when (and pos (looking-at python-nav-beginning-of-defun-regexp))
(let ((split (split-string (match-string-no-properties 0))))
(setq type (car split))
(cadr split))))
(label (when name
(funcall ein:imenu-format-item-label-function type name)))
(indent (current-indentation))
(children-indent-limit (+ python-indent-offset min-indent)))
(cond ((not pos)
;; Nothing found, probably near to bobp.
nil)
((<= indent min-indent)
;; The current indentation points that this is a parent
;; node, add it to the tree and stop recursing.
(ein:imenu--put-parent type name pos tree))
(t
(ein:imenu--build-tree
min-indent
indent
(if (<= indent children-indent-limit)
;; This lies within the children indent offset range,
;; so it's a normal child of its parent (i.e., not
;; a child of a child).
(cons (cons label pos) tree)
;; Oh no, a child of a child?! Fear not, we
;; know how to roll. We recursively parse these by
;; swapping prev-indent and min-indent plus adding this
;; newly found item to a fresh subtree. This works, I
;; promise.
(cons
(ein:imenu--build-tree
prev-indent indent (list (cons label pos)))
tree)))))))
(defun ein:imenu-create-index ()
"Return tree Imenu alist for the current Python buffer.
Change `ein:imenu-format-item-label-function',
`ein:imenu-format-parent-item-label-function',
`ein:imenu-format-parent-item-jump-label-function' to
customize how labels are formatted."
(goto-char (point-max))
(let ((index)
(tree))
(while (setq tree (ein:imenu--build-tree))
(setq index (cons tree index)))
index))
(defun ein:imenu-create-flat-index (&optional alist prefix)
"Return flat outline of the current Python buffer for Imenu.
Optional argument ALIST is the tree to be flattened; when nil
`ein:imenu-build-index' is used with
`ein:imenu-format-parent-item-jump-label-function'
`ein:imenu-format-parent-item-label-function'
`ein:imenu-format-item-label-function' set to
(lambda (type name) name)
Optional argument PREFIX is used in recursive calls and should
not be passed explicitly.
Converts this:
((\"Foo\" . 103)
(\"Bar\" . 138)
(\"decorator\"
(\"decorator\" . 173)
(\"wrap\"
(\"wrap\" . 353)
(\"wrapped_f\" . 393))))
To this:
((\"Foo\" . 103)
(\"Bar\" . 138)
(\"decorator\" . 173)
(\"decorator.wrap\" . 353)
(\"decorator.wrapped_f\" . 393))"
;; Inspired by imenu--flatten-index-alist removed in revno 21853.
(apply
'nconc
(mapcar
(lambda (item)
(let ((name (if prefix
(concat prefix "." (car item))
(car item)))
(pos (cdr item)))
(cond ((or (numberp pos) (markerp pos))
(list (cons name pos)))
((listp pos)
(cons
(cons name (cdar pos))
(python-imenu-create-flat-index (cddr item) name))))))
(or alist
(let* ((fn (lambda (_type name) name))
(ein:imenu-format-item-label-function fn)
(ein:imenu-format-parent-item-label-function fn)
(ein:imenu-format-parent-item-jump-label-function fn))
(python-imenu-create-index))))))
(provide 'ein-multilang)
;;; ein-multilang.el ends here

File diff suppressed because it is too large Load diff

View file

@ -1,117 +0,0 @@
;;; ein-org.el --- Org-mode link support for EIN
;; Copyright (C) 2012 Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-org.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-org.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-org.el.
;; If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'org)
(require 'ein-notebooklist)
;; FIXME: Separate org-unrelated cores from the following code and
;; expose them as API in ein-link.el.
(cl-defun ein:org-goto-link (notebook created
&key worksheet-index search &allow-other-keys)
(if created
(ein:log 'info "Linked notebook did not exist. Created a new one.")
(if worksheet-index
(ein:notebook-worksheet-open-ith notebook worksheet-index
#'pop-to-buffer)
(pop-to-buffer (ein:notebook-buffer notebook)))
(when search
(goto-char (point-min))
(search-forward search nil t))))
;;;###autoload
(defun ein:org-open (link-path)
"Open IPython notebook specified by LINK-PATH.
This function is to be used for FOLLOW function of
`org-add-link-type'."
(let ((link (read link-path)))
(cl-destructuring-bind (&key url-or-port name &allow-other-keys)
link
(ein:notebook-open url-or-port name))))
;;;###autoload
(defun ein:org-store-link ()
"Call `org-store-link-props' when in notebook buffer.
This function is to be used for `org-store-link-functions'.
Examples::
ipynb:(:url-or-port 8888 :name \"My_Notebook\")
ipynb:(:url-or-port \"http://notebook-server\" :name \"My_Notebook\")
Note that spaces will be escaped in org files.
As how IPython development team supports multiple directory in
IPython notebook server is unclear, it is not easy to decide the
format for notebook links. Current approach is to use
S-expression based (rather verbose) serialization, so that
extending link spec without loosing backward compatibility is
easier. For the examples of link format in general, see Info
node `(org) External links' and Info node `(org) Search options'"
(ein:and-let* (((ein:worksheet-buffer-p))
(notebook (ein:get-notebook))
(name (ein:$notebook-notebook-path notebook))
(link (list :url-or-port (ein:get-url-or-port)
:name name))
(description name))
(ein:aif (ein:notebook-worksheet-index notebook)
(unless (= it 0)
(plist-put link :worksheet-index it))
(error "[ein] Cannot link to scratch sheet!"))
(when (region-active-p)
;; FIXME: It does not work when selecting muli-line.
(plist-put link :search (buffer-substring-no-properties
(region-beginning) (region-end))))
(org-store-link-props
:type "ipynb"
:link (let ((print-length nil)
(print-level nil))
(format "ipynb:%S" link))
:description description)))
;;;###autoload
(eval-after-load "org"
'(if (fboundp 'org-link-set-parameters)
(org-link-set-parameters "ipynb"
:follow 'ein:org-open
:help-echo "Open ipython notebook."
:store 'ein:org-store-link)
(org-add-link-type "ipynb" :follow 'ein:org-open)
(add-hook 'org-store-link-functions 'ein:org-store-link)))
;; The above expression is evaluated via loaddef file. At the moment,
;; org.el nor ein-org.el need not be loaded. When org-mode is used,
;; the above `progn' is executed but still ein-org.el is not loaded.
;; When `ein:org-open' or `ein:org-store-link' is called for opening
;; or storing ipynb link, ein-org.el is loaded finally. (When
;; ein-org.el is loaded the above expression is evaluated again, but
;; that's OK as the expression is idempotent.)
(provide 'ein-org)
;;; ein-org.el ends here

Binary file not shown.

View file

@ -1,14 +0,0 @@
(define-package "ein" "20200127.249" "Emacs IPython Notebook"
'((emacs "25")
(websocket "20191017.30")
(auto-complete "1.4.0")
(request "20190621.1622")
(deferred "0.5")
(polymode "20190426.1729")
(markdown-mode "20171116.756")
(dash "2.13.0")
(s "1.11.0")
(skewer-mode "1.6.2")))
;; Local Variables:
;; no-byte-compile: t
;; End:

View file

@ -1,82 +0,0 @@
;;; ein-python.el --- Workarounds for python.el
;; Copyright (C) 2012 Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-python.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-python.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-python.el.
;; If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'python)
(require 'ein-worksheet)
(defvar ein:python-block-start
(rx line-start
symbol-start
(or "def" "class" "if" "elif" "else" "try"
"except" "finally" "for" "while" "with")
symbol-end))
(defun ein:python-indent-calculate-indentation--around (orig &rest args)
"False if there is no python block yet in this cell."
(condition-case _
(ein:and-let* ((cell (ein:worksheet-get-current-cell))
(beg (ein:cell-input-pos-min cell))
(p (point))
((< beg (point))))
(if (not (search-backward-regexp ein:python-block-start beg t))
0
(goto-char p)
(apply orig args)))
(error (apply orig args))))
(advice-add 'python-indent--calculate-indentation :around #'ein:python-indent-calculate-indentation--around)
;; (defadvice python-indent-calculate-indentation
;; (around ein:python-indent-calculate-levels activate)
;; "Hack `python-indent-calculate-levels' to reset indent per cell.
;; Let's say you have a notebook something like this::
;; In [1]:
;; def func():
;; pass
;; In [2]:
;; something[]
;; Here, ``[]`` is the cursor position. When you hit the tab here,
;; you don't expect it to indent. However, python.el tries to follow
;; the indent of ``func()`` then you get indentation. This advice
;; workaround this problem.
;; Note that this workaround does not work with the MuMaMo based
;; notebook mode."
;; (if (ein:ein-block-start-p)
;; ad-do-it
;; 0))
(provide 'ein-python)
;;; ein-python.el ends here

Binary file not shown.

View file

@ -1,467 +0,0 @@
;;; ein-pytools.el --- Python tools build on top of kernel
;; Copyright (C) 2012- Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-pytools.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-pytools.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-pytools.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
;; for `ein:pytools-pandas-to-ses'
(declare-function ses-yank-tsf "ses")
(declare-function ses-command-hook "ses")
(require 'ein-kernel)
(require 'ein-notebook)
(require 'ein-shared-output)
(defun ein:goto-file (filename lineno &optional other-window)
"Jump to file FILEAME at line LINENO.
If OTHER-WINDOW is non-`nil', open the file in the other window."
(funcall (if other-window #'find-file-other-window #'find-file) filename)
(goto-char (point-min))
(forward-line (1- lineno)))
(defun ein:goto-marker (marker &optional other-window)
(funcall (if other-window #'pop-to-buffer #'switch-to-buffer)
(marker-buffer marker))
(goto-char marker))
(defcustom ein:propagate-connect t
"Set to `t' to connect to the notebook after jumping to a buffer."
:type '(choice (const :tag "Yes" t)
(const :tag "No" nil))
:group 'ein)
(defun ein:pytools-setup-hooks (kernel notebook)
(push (cons #'ein:pytools-load-safely kernel)
(ein:$kernel-after-start-hook kernel)))
(defun ein:pytools-wrap-hy-code (code)
(format "__import__('hy').eval(__import__('hy').read_str('''%s'''))" code))
(defun ein:pytools-load-safely (kernel)
(with-temp-buffer
(let ((pytools-file (format "%s/%s" ein:source-dir "ein_remote_safe.py")))
(insert-file-contents pytools-file)
(ein:kernel-execute
kernel
(buffer-string)))))
(defun ein:pytools-reinject ()
"Re-send ein's pytools code to the current kernel.
If the kernel is reset by the notebook server then it may become
necessary to call this command to ensure pytools continue
working."
(interactive)
(ein:pytools-load-safely (ein:get-kernel-or-error)))
(defun ein:pytools-add-sys-path (kernel)
(ein:kernel-execute
kernel
(format "__import__('sys').path.append('%s')" ein:source-dir)))
(defun ein:set-buffer-file-name (nb msg-type content -not-used-)
(let ((buf (ein:notebook-buffer nb)))
(ein:case-equal msg-type
(("stream" "output")
(with-current-buffer buf
(setq buffer-file-name
(expand-file-name
(format "%s" (ein:$notebook-notebook-name nb))
(plist-get content :text))))))))
(defun ein:pytools-get-notebook-dir (packed)
(cl-multiple-value-bind (kernel notebook) packed
(ein:kernel-execute
kernel
(format "print(__import__('os').getcwd(),end='')")
(list
:output (cons
#'ein:set-buffer-file-name
notebook)))))
;;; Tooltip and help
;; We can probably be more sophisticated than this, but
;; as a hack it will do.
(defun ein:pytools-magic-func-p (fstr)
(string-prefix-p "%" fstr))
(defun ein:pytools-request-tooltip (kernel func)
(interactive (list (ein:get-kernel-or-error)
(ein:object-at-point-or-error)))
(unless (ein:pytools-magic-func-p func)
(if (>= (ein:$kernel-api-version kernel) 3)
(ein:kernel-execute
kernel
(format "__ein_print_object_info_for(%s)" func)
(list
:output (cons
(lambda (name msg-type content -metadata-not-used-)
(ein:case-equal msg-type
(("stream" "display_data")
(ein:pytools-finish-tooltip name (ein:json-read-from-string (plist-get content :text)) nil))))
func)))
(ein:kernel-object-info-request
kernel func (list :object_info_reply
(cons #'ein:pytools-finish-tooltip nil))))))
(declare-function pos-tip-show "pos-tip")
(declare-function popup-tip "popup")
(defun ein:pytools-finish-tooltip (-ignore- content -metadata-not-used-)
;; See: Tooltip.prototype._show (tooltip.js)
(let ((tooltip (ein:kernel-construct-help-string content))
(defstring (ein:kernel-construct-defstring content))
(name (plist-get content :name)))
(if tooltip
(cond
((and window-system (featurep 'pos-tip))
(pos-tip-show tooltip 'ein:pos-tip-face nil nil 0))
((featurep 'popup)
(popup-tip tooltip))
(t (when (stringp defstring)
(message (ein:trim (ansi-color-apply defstring))))))
(ein:log 'info "no info for %s" name))))
(defun ein:pytools-request-help (kernel func)
(interactive (list (ein:get-kernel-or-error)
(ein:object-at-point-or-error)))
(ein:kernel-execute kernel
(format "%s?" func) ; = code
nil ; = callbacks
;; It looks like that magic command does
;; not work in silent mode.
:silent nil))
(defun ein:pytools-request-tooltip-or-help (&optional pager)
"Show the help for the object at point using tooltip.
When the prefix argument ``C-u`` is given, open the help in the
pager buffer. You can explicitly specify the object by selecting it."
(interactive "P")
(call-interactively (if pager
#'ein:pytools-request-help
#'ein:pytools-request-tooltip)))
;;; Source jump
(defvar ein:pytools-jump-stack nil)
(defvar ein:pytools-jump-to-source-not-found-regexp
(ein:join-str "\\|"
(list "^WARNING: .*"
"^Traceback (most recent call last):\n"
"^.*<ipython-input-[^>\n]+>\n"
"^\n")))
(defun ein:pytools-jump-to-source-1 (packed msg-type content -metadata-not-used-)
(ein:log 'debug "msg-type[[%s]] content[[%s]]" msg-type content)
(cl-destructuring-bind (kernel object other-window notebook) packed
(ein:log 'debug "object[[%s]] other-window[[%s]]" object other-window)
(ein:case-equal msg-type
(("stream" "display_data")
(ein:aif (or (plist-get content :text) (plist-get content :data))
(if (string-match ein:pytools-jump-to-source-not-found-regexp it)
(ein:log 'info
"Jumping to the source of %s...Not found" object)
(cl-destructuring-bind (filename &optional lineno &rest ignore)
(split-string it "\n")
(setq lineno (string-to-number lineno)
filename (ein:kernel-filename-from-python kernel filename))
(ein:log 'debug "filename[[%s]] lineno[[%s]] ignore[[%s]]"
filename lineno ignore)
(if (not (file-exists-p filename))
(ein:log 'info
"Jumping to the source of %s...Not found" object)
(let ((ein:connect-default-notebook nil))
;; Avoid auto connection to connect to the
;; NOTEBOOK instead of the default one.
(ein:goto-file filename lineno other-window))
;; Connect current buffer to NOTEBOOK. No reconnection.
(ein:connect-buffer-to-notebook notebook nil t)
(push (point-marker) ein:pytools-jump-stack)
(ein:log 'info "Jumping to the source of %s...Done" object))))))
(("pyerr" "error")
(ein:log 'info "Jumping to the source of %s...Not found" object)))))
(defun ein:pytools-jump-to-source (kernel object &optional
other-window notebook)
(ein:log 'info "Jumping to the source of %s..." object)
(let ((last (car ein:pytools-jump-stack)))
(if (ein:aand last (eql (current-buffer) (marker-buffer it)))
(unless (equal (point) (marker-position last))
(push (point-marker) ein:pytools-jump-stack))
(setq ein:pytools-jump-stack (list (point-marker)))))
(ein:kernel-execute
kernel
(format "__ein_find_source('%s')" object)
(list
:output
(cons
#'ein:pytools-jump-to-source-1
(list kernel object other-window notebook)))))
(defun ein:pytools-find-source (kernel object &optional callback)
"Find the file and line where object is defined.
This function mostly exists to support company-mode, but might be
useful for other purposes. If the definition for object can be
found and when callback isort specified, the callback will be
called with a cons of the filename and line number where object
is defined."
(ein:kernel-execute
kernel
(format "__ein_find_source('%s')" object)
(list
:output
(cons
#'ein:pytools-finish-find-source
(list kernel object callback)))))
(defun ein:pytools-finish-find-source (packed msg-type content -ignored-)
(cl-destructuring-bind (kernel object callback) packed
(if (or (string= msg-type "stream")
(string= msg-type "display_data"))
(ein:aif (or (plist-get content :text) (plist-get content :data))
(if (string-match ein:pytools-jump-to-source-not-found-regexp it)
(ein:log 'info
"Source of %s not found" object)
(cl-destructuring-bind (filename &optional lineno &rest ignore)
(split-string it "\n")
(if callback
(funcall callback
(cons (ein:kernel-filename-from-python kernel filename)
(string-to-number lineno)))
(cons (ein:kernel-filename-from-python kernel filename)
(string-to-number lineno)))))) ;; FIXME Generator?
(ein:log 'info "Source of %s notebook found" object))))
(defun ein:pytools-jump-to-source-command (&optional other-window)
"Jump to the source code of the object at point.
When the prefix argument ``C-u`` is given, open the source code
in the other window. You can explicitly specify the object by
selecting it."
(interactive "P")
(if poly-ein-mode
(cl-letf (((symbol-function 'xref--prompt-p) #'ignore))
(if other-window
(call-interactively #'xref-find-definitions-other-window)
(call-interactively #'xref-find-definitions)))
(let ((kernel (ein:get-kernel))
(object (ein:object-at-point)))
(cl-assert (ein:kernel-live-p kernel) nil "Kernel is not ready.")
(cl-assert object nil "Object at point not found.")
(ein:pytools-jump-to-source kernel object other-window
(when ein:propagate-connect
(ein:get-notebook))))))
(defun ein:pytools-jump-back-command (&optional other-window)
"Go back to the point where `ein:pytools-jump-to-source-command'
is executed last time. When the prefix argument ``C-u`` is
given, open the last point in the other window."
(interactive "P")
(if poly-ein-mode
(call-interactively #'xref-pop-marker-stack)
(when (ein:aand (car ein:pytools-jump-stack)
(equal (point) (marker-position it)))
(setq ein:pytools-jump-stack (cdr ein:pytools-jump-stack)))
(ein:aif (car ein:pytools-jump-stack)
(ein:goto-marker it other-window)
(ein:log 'info "Nothing on stack."))))
(define-obsolete-function-alias
'ein:pytools-eval-string-internal
'ein:shared-output-eval-string "0.1.2")
(defun ein:pytools-doctest ()
"Do the doctest of the object at point."
(interactive)
(let ((object (ein:object-at-point)))
(ein:shared-output-eval-string (ein:get-kernel)
(format "__ein_run_docstring_examples(%s)" object)
t)))
(defun ein:pytools-whos ()
"Execute ``%whos`` magic command and popup the result."
(interactive)
(ein:shared-output-eval-string (ein:get-kernel) "%whos" t))
(defun ein:pytools-hierarchy (&optional ask)
"Draw inheritance graph of the class at point.
hierarchymagic_ extension is needed to be installed.
You can explicitly specify the object by selecting it.
.. _hierarchymagic: https://github.com/tkf/ipython-hierarchymagic"
(interactive "P")
(let ((object (ein:object-at-point)))
(when ask
(setq object (read-from-minibuffer "class or object: " object)))
(cl-assert (and object (not (equal object "")))
nil "Object at point not found.")
(ein:shared-output-eval-string (ein:get-kernel) (format "%%hierarchy %s" object) t)))
(defun ein:pytools-pandas-to-ses (dataframe)
"View pandas_ DataFrame in SES_ (Simple Emacs Spreadsheet).
Open a `ses-mode' buffer and import DataFrame object into it.
SES_ is distributed with Emacs since Emacs 22, so you don't need
to install it if you are using newer Emacs.
.. _pandas: http://pandas.pydata.org
.. _SES: http://www.gnu.org/software/emacs/manual/html_node/ses/index.html"
(interactive (list (read-from-minibuffer "pandas DataFrame "
(ein:object-at-point))))
(let ((buffer (get-buffer-create
(generate-new-buffer-name "*ein:ses pandas*"))))
;; fetch TSV (tab separated values) via stdout
(ein:kernel-request-stream
(ein:get-kernel)
(concat dataframe ".to_csv(__import__('sys').stdout, sep='\\t')")
(lambda (tsv buffer)
(with-current-buffer buffer
(cl-flet ((y-or-n-p
(prompt)
(if (string-prefix-p "Yank will insert " prompt)
t
(error "Unexpected prompt: %s" prompt))))
;; Import DataFrame as TSV
(ses-yank-tsf tsv nil))
;; Force SES to update (equivalent to run `post-command-hook').
(ses-command-hook)))
(list buffer))
;; Open `ses-mode' buffer
(with-current-buffer buffer
(ses-mode))
(pop-to-buffer buffer)))
(defun ein:pytools-export-buffer (buffer format)
"Export contents of notebook using nbconvert_ to user-specified format
\(options will depend on the version of nbconvert available\) to a new buffer.
Currently EIN/IPython supports exporting to the following formats:
- HTML
- JSON (this is basically the same as opening the ipynb file in a buffer).
- Latex
- Markdown
- Python
- RST
- Slides
.. _nbconvert: http://ipython.org/ipython-doc/stable/notebook/nbconvert.html"
(interactive (list (read-buffer "Buffer: " (current-buffer) t)
(ein:completing-read "Export format: "
(list "html"
"json"
"latex"
"markdown"
"python"
"rst"
"slides"))))
(let* ((nb (car (ein:notebook-opened-notebooks
#'(lambda (nb)
(equal (buffer-name (ein:notebook-buffer nb))
buffer)))))
(json (json-encode (ein:notebook-to-json nb)))
(name (format "*ein %s export: %s*" format (ein:$notebook-notebook-name nb)))
(buffer (get-buffer-create name)))
(if (equal format "json")
(with-current-buffer buffer
(erase-buffer)
(insert json)
(json-pretty-print (point-min) (point-max)))
(ein:kernel-request-stream
(ein:get-kernel)
(format "__ein_export_nb(r'%s', '%s')"
json
format)
(lambda (export buffer)
(with-current-buffer buffer
(erase-buffer)
(insert export)))
(list buffer)))
(switch-to-buffer buffer)))
;;;; Helper functions for working with matplotlib
(defun ein:pytools-set-figure-size (width height)
"Set the default figure size for matplotlib figures. Works by setting `rcParams['figure.figsize']`."
(interactive "nWidth: \nnHeight: ")
(ein:shared-output-eval-string (ein:get-kernel)
(format "__ein_set_figure_size('[%s, %s]')" width height)
nil))
(defun ein:pytools-set-figure-dpi (dpi)
"Set the default figure dpi for matplotlib figures. Works by setting `rcParams['figure.figsize']`."
(interactive "nFigure DPI: ")
(ein:shared-output-eval-string (ein:get-kernel)
(format "__ein_set_figure_dpi('%s')" dpi)
nil))
(defun ein:pytools-set-matplotlib-parameter (param value)
"Generically set any matplotlib parameter exposed in the matplotlib.pyplot.rcParams variable. Value is evaluated as a Python expression, so be careful of side effects."
(interactive
(list (completing-read "Parameter: " (ein:pytools--get-matplotlib-params) nil t)
(read-string "Value: " nil)))
(let* ((split (cl-position ?. param))
(family (cl-subseq param 0 split))
(setting (cl-subseq param (1+ split))))
(ein:shared-output-eval-string (ein:get-kernel)
(format "__ein_set_matplotlib_param('%s', '%s', '%s')" family setting value)
nil)))
(defun ein:pytools--get-matplotlib-params ()
(ein:shared-output-eval-string (ein:get-kernel)
(format "__ein_get_matplotlib_params()")
nil)
(with-current-buffer (ein:shared-output-create-buffer)
(ein:wait-until #'(lambda ()
(slot-value (slot-value *ein:shared-output* :cell) :outputs))
nil
5.0)
(let ((outputs (first (slot-value (slot-value *ein:shared-output* :cell) :outputs))))
(ein:json-read-from-string (plist-get outputs :text)))))
(defun ein:pytools--estimate-screen-dpi ()
(let* ((pixel-width (display-pixel-width))
(pixel-height (display-pixel-height))
(in-width (/ (display-mm-width) 25.4))
(in-height (/ (display-mm-height) 25.4)))
(values (/ pixel-width in-width) (/ pixel-height in-height))))
(defun ein:pytools-matplotlib-dpi-correction ()
"Estimate the screen dpi and set the matplotlib rc parameter 'figure.dpi' to that value. Call this command *after* importing matplotlib into your notebook, else this setting will be overwritten after the first call to `import matplotlib' Further testing is needed to see how well this works on high resolution displays."
(interactive)
(multiple-value-bind (dpi-w dpi-h) (ein:pytools--estimate-screen-dpi)
(let ((dpi (floor (/ (+ dpi-w dpi-h) 2.0))))
(ein:log 'info "Setting matplotlib scaling to: %s dpi" dpi)
(ein:pytools-set-figure-dpi dpi))))
(provide 'ein-pytools)
;;; ein-pytools.el ends here

View file

@ -1,98 +0,0 @@
;;; -*- mode: emacs-lisp; lexical-binding: t; -*-
;;; ein-skewer.el --- Cell module
;; (C) 2016 - John M Miller
;; Author: John M Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-skewer.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-skewre.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-cell.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; This depends on the skewer package, so likely will get split into
;; its own package at some point.
;;; Code:
(require 'skewer-mode)
(require 'skewer-html)
(require 'simple-httpd)
(defvar *ein:skewer-running-p* nil "True if the emacs httpd server has been started.")
(defun ein:js-prepare-result (result type)
(list :output_type type :text result))
(defun ein:update-javascript-output (cell json result)
(let ((val (ein:js-prepare-result
(or (cdr (assoc 'value result)) "See browser for result.")
(plist-get json :output_type))))
(setf (slot-value cell 'outputs) (list val))
(ein:cell-append-output cell val (slot-value cell 'dynamic))))
(defservlet current-jupyter-cell-output text/html (path)
(let ((cell-id (file-name-nondirectory path)))
(insert (gethash cell-id *ein:skewer-cell-output-cache*))))
(defvar *ein:skewer-html-template*
"<html>
<head>
<title>Emacs IPython Notebook</title>
<script src=\"/skewer\"></script>
</head>
<body>
%s
</body>
</html>")
(defvar *ein:skewer-cell-output-cache* (make-hash-table :test #'equal))
(defun ein:skewer--handle-html (cell string)
(setf (gethash (slot-value cell 'cell-id) *ein:skewer-cell-output-cache*)
(format *ein:skewer-html-template* string) ))
;; Format of result is ((id . STR) (type . STR) (status . STR) (value . STR) (time . FLOAT))
(defun ein:execute-javascript (cell json)
(unless (httpd-running-p) ;; *ein:skewer-running-p*
(run-skewer))
(deferred:$
(deferred:next
(lambda ()
(let ((result nil))
(ein:aif (plist-get json :html)
(progn
(let ((cell-id (slot-value cell 'cell-id)))
(ein:skewer--handle-html cell it)
(setq result (list '(id . nil)
'(type . str)
'(stats . nil)
(cons 'value (format "Open http://localhost:8080/current-jupyter-cell-output/%s" cell-id))
'(time . nil)))
(browse-url (format "http://localhost:8080/current-jupyter-cell-output/%s" cell-id))))
(skewer-eval (plist-get json :javascript)
(lambda (v)
(setq result v))
:type (if (plist-get json :html)
"html"
"eval")))
(cl-loop until result
do (accept-process-output nil 0.01)
finally (return result)))))
(deferred:nextc it
(lambda (result)
(ein:update-javascript-output cell json result)))))
(provide 'ein-skewer)

Binary file not shown.

View file

@ -1,55 +0,0 @@
;;; ein-smartrep.el --- smartrep integration
;; Copyright (C) 2012- Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-smartrep.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-smartrep.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-smartrep.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;;
;;; Code:
(require 'smartrep nil t)
(defcustom ein:smartrep-notebook-mode-alist
'(("C-t" . ein:worksheet-toggle-cell-type)
("C-l" . ein:worksheet-clear-output)
("C-k" . ein:worksheet-kill-cell)
("C-y" . ein:worksheet-yank-cell)
("C-a" . ein:worksheet-insert-cell-above)
("C-b" . ein:worksheet-insert-cell-below)
("C-n" . ein:worksheet-goto-next-input)
("C-p" . ein:worksheet-goto-prev-input)
("C-m" . ein:worksheet-merge-cell)
("<up>" . ein:worksheet-move-cell-up)
("<down>" . ein:worksheet-move-cell-down))
"alist passed to `smartrep-define-key'."
:type '(repeat (cons string function))
:group 'ein)
(when (fboundp 'smartrep-define-key)
(defmacro ein:smartrep-config (map)
`(smartrep-define-key
,map
"C-c"
ein:smartrep-notebook-mode-alist)))
(provide 'ein-smartrep)
;;; ein-smartrep.el ends here

View file

@ -1,45 +0,0 @@
;;; ein-subpackages.el --- Subpackage management
;; Copyright (C) 2012- Takafumi Arakaki
;; Author: Takafumi Arakaki <aka.tkf at gmail.com>
;; This file is NOT part of GNU Emacs.
;; ein-subpackages.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-subpackages.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-subpackages.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; This module was more important when packages came from git submodules.
;; It has been gutted since.
;;
;;; Code:
(defcustom ein:completion-backend 'ein:use-none-backend
"EIN defaults to your individual company-mode or auto-complete-mode configuration. Change this setting to gather completions from the jupyter server::
* ein:use-none-backend: local completions only (configured outside EIN)
* ein:use-company-backend: company-style remote completions (elpy takes precedence)
* ein:use-ac-backend: deprecated auto-complete remote completions
"
:type '(choice
(const ein:use-none-backend)
(const ein:use-company-backend)
(const ein:use-ac-backend))
:group 'ein)
(provide 'ein-subpackages)
;;; ein-subpackages.el ends here

View file

@ -1,68 +0,0 @@
;;; ein-timestamp.el --- Elisp implementation of the ExecuteTime nbextension
;; Copyright (C) 2018- John M. Miller
;; Author: John M. Miller <millejoh at mac.com>
;; This file is NOT part of GNU Emacs.
;; ein-timestamp.el is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; ein-timestamp.el is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with ein-timestamp.el. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; A rough approximation of the ExecuteTime (https://jupyter-contrib-nbextensions.readthedocs.io/en/latest/nbextensions/execute_time/readme.html) nbextension
;;; Code:
(require 'ein-kernel)
(require 'ein-cell)
(defcustom ein:timestamp-format "%FT%T"
"The format spec for timestamps.
See `ein:format-time-string'."
:type '(or string function)
:group 'ein)
(defun ein:timestamp--shell-reply-hook (msg-type header content metadata)
(when (string-equal msg-type "execute_reply")
(let ((start-time (plist-get metadata :started))
(end-time (plist-get header :date)))
(plist-put metadata :execute-time (list start-time end-time)))))
(defun ein:timestamp--execute-reply-hook (cell content metadata)
(if-let ((etime (plist-get metadata :execute-time)))
(if (ein:cell-metadata cell)
(plist-put (ein:cell-metadata cell)
:execute-time
etime)
(setf (ein:cell-metadata cell) (list :execute-time etime))))
(ein:cell-running-set cell nil)
(let ((buffer-undo-list t))
(ewoc-invalidate (ein:basecell--ewoc cell) (ein:cell-element-get cell :footer))))
(cl-defmethod ein:cell-insert-footer :after ((cell ein:codecell))
(if (slot-value cell 'running)
(ein:insert-read-only "Execution pending\n\n")
(if-let ((etime (plist-get (ein:cell-metadata cell) :execute-time)))
(let ((start-time (date-to-time (car etime)))
(end-time (date-to-time (cadr etime))))
(ein:insert-read-only
(format "Last executed %s in %ss\n\n"
(ein:format-time-string ein:timestamp-format start-time)
(float-time (time-subtract end-time start-time))))))))
(add-hook 'ein:on-shell-reply-functions 'ein:timestamp--shell-reply-hook)
(add-hook 'ein:on-execute-reply-functions 'ein:timestamp--execute-reply-hook)
(provide 'ein-timestamp)

Binary file not shown.

View file

@ -1,46 +0,0 @@
"""
Python utilities for the ein inspector.
Copyright (C) 2017- John M. Miller
Author: John Miller <millejoh at gmail.com>
ein_inspector.py is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
ein_inspector.py is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with ein_inspector.py. If not, see <http://www.gnu.org/licenses/>.
"""
import json
import inspect
def generate_inspector_data(obj_str, globals, locals):
odata = {'name': obj_str}
try:
obj = eval(obj_str, globals, locals)
except NameError:
odata['error'] = 'Object {} not found.'.format(obj_str)
else:
odata['doc'] = inspect.getdoc(obj)
odata['type'] = str(type(obj))
odata['repr'] = str(obj)
try:
odata['source_file'] = inspect.getsourcefile(obj)
odata['source_lines'] = inspect.getsourcelines(obj)
except:
odata['source_file'] = None
odata['source_lines'] = None
print(json.dumps(odata))
return odata

View file

@ -1,163 +0,0 @@
"""
Python utilities to use it from ein.el
Copyright (C) 2012- Takafumi Arakaki
Author: Takafumi Arakaki <aka.tkf at gmail.com>
ein.py is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
ein.py is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with ein.py. If not, see <http://www.gnu.org/licenses/>.
"""
__ein_pytools_version = "1.1.0"
try:
from matplotlib import rc as __ein_rc
from matplotlib import rcParams as __ein_rcParams
__ein_matplotlib_available = True
except ImportError:
__ein_matplotlib_available = False
def __ein_export_nb(nb_json, format):
import IPython.nbconvert as nbconvert
import IPython.nbformat as nbformat
nb = nbformat.reads(nb_json, nbformat.NO_CONVERT)
output = nbconvert.export_by_name(format, nb)
print(output[0])
def __ein_find_edit_target_012(*args, **kwds):
from IPython.core.interactiveshell import InteractiveShell
inst = InteractiveShell.instance()
return inst._find_edit_target(*args, **kwds)
def __ein_find_edit_target_013(*args, **kwds):
from IPython.core.interactiveshell import InteractiveShell
inst = InteractiveShell.instance()
return CodeMagics._find_edit_target(inst, *args, **kwds)
def __ein_find_edit_target_python(name):
from inspect import getsourcefile, getsourcelines
try:
obj = eval(name)
except NameError:
return False
else:
sfile = getsourcefile(obj)
sline = getsourcelines(obj)[-1]
if sfile and sline:
return(sfile, sline, False)
else:
return False
try:
from IPython.core.magics import CodeMagics
__ein_find_edit_target = __ein_find_edit_target_013
except ImportError:
__ein_find_edit_target = __ein_find_edit_target_012
def __ein_set_matplotlib_param(family, setting, value):
settings = {}
if __ein_matplotlib_available:
settings[setting] = eval(value)
__ein_rc(family, **settings)
else:
raise RuntimeError("Matplotlib not installed in this instance of python!")
def __ein_set_figure_size(dim):
__ein_set_matplotlib_param('figure', 'figsize', dim)
def __ein_set_figure_dpi(dpi):
__ein_set_matplotlib_param('figure', 'dpi', dpi)
def __ein_get_matplotlib_params():
if __ein_matplotlib_available:
import json
print(json.dumps([k for k in __ein_rcParams.keys()]))
else:
raise RuntimeError("Matplotlib not installed in this instance of python!")
def __ein_find_source(name):
"""Given an object as string, `name`, print its place in source code."""
# FIXME: use JSON display object instead of stdout
ret = __ein_find_edit_target_python(name) or __ein_find_edit_target(name, {}, [])
if ret:
(filename, lineno, use_temp) = ret
if not use_temp:
print(filename)
print(lineno)
return
raise RuntimeError("Source code for {0} cannot be found".format(name))
def __ein_run_docstring_examples(obj, verbose=True):
from IPython.core.interactiveshell import InteractiveShell
import doctest
inst = InteractiveShell.instance()
globs = inst.user_ns
return doctest.run_docstring_examples(obj, globs, verbose=verbose)
def __ein_generate_oinfo_data(ostrings, locals=None):
import json
defined_objects = [__ein_maybe_undefined_object(obj, locals) for obj in ostrings
if __ein_maybe_undefined_object(obj, locals) is not None]
odata = [__ein_object_info_for(obj) for obj in defined_objects]
print (json.dumps(odata))
return odata
def __ein_maybe_undefined_object(obj, locals=None):
try:
return eval(obj, None, locals)
except Exception:
return None
except SyntaxError:
return None
def __ein_object_info_for(obj):
import IPython.core.oinspect
inspector = IPython.core.oinspect.Inspector()
try:
return inspector.info(obj)
except Exception:
return inspector.info(None)
def __ein_print_object_info_for(obj):
import json
oinfo = __ein_object_info_for(obj)
print (json.dumps(oinfo))
def __ein_eval_hy_string(obj):
try:
import hy
except ImportError:
print("Hy not supported in this kernel. Execute `pip install hy` if you want this support.")
expr = hy.read_str(obj)
ret = hy.eval(expr)
return ret

Binary file not shown.

Binary file not shown.

View file

@ -5,34 +5,12 @@
(add-to-list 'load-path (directory-file-name
(or (file-name-directory #$) (car load-path))))
;;;### (autoloads nil "ein-ac" "ein-ac.el" (0 0 0 0))
;;; Generated autoloads from ein-ac.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-ac" '("ein:")))
;;;***
;;;### (autoloads nil "ein-cell" "ein-cell.el" (0 0 0 0))
;;; Generated autoloads from ein-cell.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-cell" '("ein:")))
;;;***
;;;### (autoloads nil "ein-cell-edit" "ein-cell-edit.el" (0 0 0 0))
;;; Generated autoloads from ein-cell-edit.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-cell-edit" '("ein:")))
;;;***
;;;### (autoloads nil "ein-cell-output" "ein-cell-output.el" (0 0
;;;;;; 0 0))
;;; Generated autoloads from ein-cell-output.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-cell-output" '("ein:")))
;;;***
;;;### (autoloads nil "ein-classes" "ein-classes.el" (0 0 0 0))
@ -40,84 +18,6 @@
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-classes" '("ein:")))
;;;***
;;;### (autoloads nil "ein-company" "ein-company.el" (0 0 0 0))
;;; Generated autoloads from ein-company.el
(autoload 'ein:company-backend "ein-company" "\
\(fn COMMAND &optional ARG &rest _)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-company" '("ein:comp")))
;;;***
;;;### (autoloads nil "ein-completer" "ein-completer.el" (0 0 0 0))
;;; Generated autoloads from ein-completer.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-completer" '("ein:")))
;;;***
;;;### (autoloads nil "ein-connect" "ein-connect.el" (0 0 0 0))
;;; Generated autoloads from ein-connect.el
(autoload 'ein:connect-to-notebook-command "ein-connect" "\
Connect to notebook. When the prefix argument is given,
you can choose any notebook on your server including the ones
not yet opened. Otherwise, already chose from already opened
notebooks.
\(fn &optional NOT-YET-OPENED)" t nil)
(autoload 'ein:connect-to-notebook "ein-connect" "\
Connect any buffer to notebook and its kernel.
\(fn NBPATH &optional BUFFER NO-RECONNECTION)" t nil)
(autoload 'ein:connect-to-notebook-buffer "ein-connect" "\
Connect any buffer to opened notebook and its kernel.
\(fn BUFFER-OR-NAME)" t nil)
(autoload 'ein:connect-buffer-to-notebook "ein-connect" "\
Connect BUFFER to NOTEBOOK.
\(fn NOTEBOOK &optional BUFFER NO-RECONNECTION)" nil nil)
(autoload 'ein:connect-to-default-notebook "ein-connect" "\
Connect to the default notebook specified by
`ein:connect-default-notebook'. Set this to `python-mode-hook'
to automatically connect any python-mode buffer to the
notebook.
\(fn)" nil nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-connect" '("ein:")))
;;;***
;;;### (autoloads nil "ein-console" "ein-console.el" (0 0 0 0))
;;; Generated autoloads from ein-console.el
(autoload 'ein:console-open "ein-console" "\
Open IPython console.
To use this function, `ein:console-security-dir' and
`ein:console-args' must be set properly.
This function works best with the new python.el_ which is shipped
with Emacs 24.2 or later. If you don't have it, this function
opens a \"plain\" command line interpreter (comint) buffer where
you cannot use fancy stuff such as TAB completion.
It should be possible to support python-mode.el. Patches are welcome!
.. _python.el: https://github.com/fgallina/python.el
\(fn)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-console" '("ein:")))
;;;***
;;;### (autoloads nil "ein-contents-api" "ein-contents-api.el" (0
@ -217,18 +117,6 @@ change in its input area.
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-iexec" '("ein:iexec-")))
;;;***
;;;### (autoloads nil "ein-inspector" "ein-inspector.el" (0 0 0 0))
;;; Generated autoloads from ein-inspector.el
(autoload 'ein:inspect-object "ein-inspector" "\
\(fn KERNEL OBJECT)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-inspector" '("ein:")))
;;;***
;;;### (autoloads nil "ein-ipdb" "ein-ipdb.el" (0 0 0 0))
@ -256,26 +144,28 @@ A simple mode for ipynb file.
;;;### (autoloads nil "ein-jupyter" "ein-jupyter.el" (0 0 0 0))
;;; Generated autoloads from ein-jupyter.el
(autoload 'ein:jupyter-crib-token "ein-jupyter" "\
Shell out to jupyter for its credentials knowledge. Return list of (PASSWORD TOKEN).
\(fn URL-OR-PORT)" nil nil)
(autoload 'ein:jupyter-crib-running-servers "ein-jupyter" "\
Shell out to jupyter for running servers.
\(fn)" nil nil)
(autoload 'ein:jupyter-server-start "ein-jupyter" "\
Start SERVER-CMD_PATH with `--notebook-dir' NOTEBOOK-DIRECTORY. Login after connection established unless NO-LOGIN-P is set. LOGIN-CALLBACK takes two arguments, the buffer created by ein:notebooklist-open--finish, and the url-or-port argument of ein:notebooklist-open*.
Start SERVER-COMMAND with `--notebook-dir' NOTEBOOK-DIRECTORY.
This command opens an asynchronous process running the jupyter
notebook server and then tries to detect the url and password to
generate automatic calls to `ein:notebooklist-login' and
`ein:notebooklist-open'.
Login after connection established unless NO-LOGIN-P is set.
LOGIN-CALLBACK takes two arguments, the buffer created by
`ein:notebooklist-open--finish', and the url-or-port argument
of `ein:notebooklist-open*'.
With \\[universal-argument] prefix arg, it will prompt the user for the path to
the jupyter executable first. Else, it will try to use the
value of `*ein:last-jupyter-command*' or the value of the
customizable variable `ein:jupyter-default-server-command'.
With \\[universal-argument] prefix arg, prompt the user for the
server command.
Then it prompts the user for the path of the root directory
containing the notebooks the user wants to access.
The buffer named by `ein:jupyter-server-buffer-name' will contain
the log of the running jupyter server.
\(fn SERVER-CMD-PATH NOTEBOOK-DIRECTORY &optional NO-LOGIN-P LOGIN-CALLBACK PORT)" t nil)
\(fn SERVER-COMMAND NOTEBOOK-DIRECTORY &optional NO-LOGIN-P LOGIN-CALLBACK PORT)" t nil)
(defalias 'ein:run 'ein:jupyter-server-start)
@ -286,7 +176,7 @@ the log of the running jupyter server.
\(fn &optional FORCE LOG)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-jupyter" '("ein:" "*ein:")))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-jupyter" '("ein:" "*ein:jupyter-server-")))
;;;***
@ -299,7 +189,14 @@ Log on to a jupyterhub server using PAM authentication. Requires jupyterhub vers
\(fn URL-OR-PORT USERNAME PASSWORD CALLBACK)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-jupyterhub" '("ein:jupyterhub-" "*ein:jupyterhub-connections*")))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-jupyterhub" '("ein:" "*ein:jupyterhub-connections*")))
;;;***
;;;### (autoloads nil "ein-k8s" "ein-k8s.el" (0 0 0 0))
;;; Generated autoloads from ein-k8s.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-k8s" '("ein:k8s-")))
;;;***
@ -336,32 +233,23 @@ Log on to a jupyterhub server using PAM authentication. Requires jupyterhub vers
;;;***
;;;### (autoloads nil "ein-multilang" "ein-multilang.el" (0 0 0 0))
;;; Generated autoloads from ein-multilang.el
;;;### (autoloads nil "ein-markdown-mode" "ein-markdown-mode.el"
;;;;;; (0 0 0 0))
;;; Generated autoloads from ein-markdown-mode.el
(autoload 'ein:notebook-multilang-mode "ein-multilang" "\
A mode for fontifying multiple languages.
\\{ein:notebook-multilang-mode-map}
(autoload 'ein:markdown-mode "ein-markdown-mode" "\
Major mode for editing ein:markdown files.
\(fn)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-multilang" '("ein:" "python-imenu-format-parent-item-jump-label")))
;;;***
;;;### (autoloads nil "ein-multilang-fontify" "ein-multilang-fontify.el"
;;;;;; (0 0 0 0))
;;; Generated autoloads from ein-multilang-fontify.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-multilang-fontify" '("ein:mlf-")))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-markdown-mode" '("ein:markdown" "defun-markdown-")))
;;;***
;;;### (autoloads nil "ein-node" "ein-node.el" (0 0 0 0))
;;; Generated autoloads from ein-node.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-node" '("ein:node-")))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-node" '("ein:")))
;;;***
@ -388,13 +276,6 @@ where `created' indicates a new notebook or an existing one.
\(fn URL-OR-PORT PATH &optional KERNELSPEC CALLBACK ERRBACK NO-POP)" t nil)
(defalias 'ein:exit 'ein:quit)
(autoload 'ein:quit "ein-notebook" "\
Close all notebooks and servers.
\(fn &optional FORCE)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-notebook" '("ein:" "*ein:notebook--pending-query*")))
;;;***
@ -403,32 +284,11 @@ Close all notebooks and servers.
;;;;;; 0 0 0))
;;; Generated autoloads from ein-notebooklist.el
(autoload 'ein:notebooklist-enable-keepalive "ein-notebooklist" "\
Enable periodic calls to the notebook server to keep long running sessions from expiring.
By long running we mean sessions to last days, or weeks. The
frequency of the refresh (which is very similar to a call to
`ein:notebooklist-open`) is controlled by
`ein:notebooklist-keepalive-refresh-time`, and is measured in
terms of hours. If `ein:enable-keepalive' is non-nil this will
automatically be called during calls to `ein:notebooklist-open`.
\(fn &optional URL-OR-PORT)" t nil)
(autoload 'ein:notebooklist-disable-keepalive "ein-notebooklist" "\
Disable the notebooklist keepalive calls to the jupyter notebook server.
\(fn)" t nil)
(autoload 'ein:notebooklist-reload "ein-notebooklist" "\
Reload current Notebook list.
\(fn &optional NBLIST RESYNC CALLBACK)" t nil)
(autoload 'ein:notebooklist-upload-file "ein-notebooklist" "\
\(fn UPLOAD-PATH)" t nil)
(autoload 'ein:notebooklist-new-notebook "ein-notebooklist" "\
@ -457,12 +317,6 @@ or even this (if you want fast Emacs start-up)::
;; load notebook list if Emacs is idle for 3 sec after start-up
(run-with-idle-timer 3 nil #'ein:notebooklist-load)
You should setup `ein:url-or-port' or `ein:default-url-or-port'
in order to make this code work.
See also:
`ein:connect-to-default-notebook', `ein:connect-default-notebook'.
\(fn &optional URL-OR-PORT)" nil nil)
(autoload 'ein:notebooklist-open "ein-notebooklist" "\
@ -480,15 +334,6 @@ and the url-or-port argument of ein:notebooklist-open*.
\(fn URL-OR-PORT CALLBACK &optional COOKIE-PLIST)" t nil)
(autoload 'ein:notebooklist-change-url-port "ein-notebooklist" "\
Update the ipython/jupyter notebook server URL for all the
notebooks currently opened from the current notebooklist buffer.
This function works by calling `ein:notebook-update-url-or-port'
on all the notebooks opened from the current notebooklist.
\(fn NEW-URL-OR-PORT)" t nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-notebooklist" '("ein:" "render-" "generate-breadcrumbs")))
;;;***
@ -499,41 +344,6 @@ on all the notebooks opened from the current notebooklist.
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-notification" '("ein:")))
;;;***
;;;### (autoloads nil "ein-org" "ein-org.el" (0 0 0 0))
;;; Generated autoloads from ein-org.el
(autoload 'ein:org-open "ein-org" "\
Open IPython notebook specified by LINK-PATH.
This function is to be used for FOLLOW function of
`org-add-link-type'.
\(fn LINK-PATH)" nil nil)
(autoload 'ein:org-store-link "ein-org" "\
Call `org-store-link-props' when in notebook buffer.
This function is to be used for `org-store-link-functions'.
Examples::
ipynb:(:url-or-port 8888 :name \"My_Notebook\")
ipynb:(:url-or-port \"http://notebook-server\" :name \"My_Notebook\")
Note that spaces will be escaped in org files.
As how IPython development team supports multiple directory in
IPython notebook server is unclear, it is not easy to decide the
format for notebook links. Current approach is to use
S-expression based (rather verbose) serialization, so that
extending link spec without loosing backward compatibility is
easier. For the examples of link format in general, see Info
node `(org) External links' and Info node `(org) Search options'
\(fn)" nil nil)
(eval-after-load "org" '(if (fboundp 'org-link-set-parameters) (org-link-set-parameters "ipynb" :follow 'ein:org-open :help-echo "Open ipython notebook." :store 'ein:org-store-link) (org-add-link-type "ipynb" :follow 'ein:org-open) (add-hook 'org-store-link-functions 'ein:org-store-link)))
;;;***
;;;### (autoloads nil "ein-output-area" "ein-output-area.el" (0 0
@ -554,7 +364,7 @@ node `(org) External links' and Info node `(org) Search options'
;;;### (autoloads nil "ein-process" "ein-process.el" (0 0 0 0))
;;; Generated autoloads from ein-process.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-process" '("ein:process-")))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-process" '("ein:")))
;;;***
@ -569,13 +379,6 @@ Pseudo console mode. Hit RET to execute code.
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-pseudo-console" '("ein:pseudo-console-mode-map")))
;;;***
;;;### (autoloads nil "ein-python" "ein-python.el" (0 0 0 0))
;;; Generated autoloads from ein-python.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-python" '("ein:python-")))
;;;***
;;;### (autoloads nil "ein-pytools" "ein-pytools.el" (0 0 0 0))
@ -617,48 +420,12 @@ See also `ein:cell-max-num-outputs'.
\(fn)" t nil)
(autoload 'ein:shared-output-eval-string "ein-shared-output" "\
Evaluate a piece of code. Prompt will appear asking the code to run.
This is handy when you want to execute something quickly without
making a cell. If the code outputs something, it will go to the
shared output buffer. You can open the buffer by the command
`ein:shared-output-pop-to-buffer'.
Entry to `ein:cell-execute-internal' from the shared output cell.
.. ARGS is passed to `ein:kernel-execute'. Unlike `ein:kernel-execute',
`:silent' is `nil' by default.
\(fn KERNEL CODE POPUP &rest ARGS)" t nil)
\(fn KERNEL CODE &rest ARGS)" nil nil)
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-shared-output" '("ein:" "*ein:shared-output*")))
;;;***
;;;### (autoloads nil "ein-skewer" "ein-skewer.el" (0 0 0 0))
;;; Generated autoloads from ein-skewer.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-skewer" '("ein:" "*ein:skewer-" "current-jupyter-cell-output")))
;;;***
;;;### (autoloads nil "ein-smartrep" "ein-smartrep.el" (0 0 0 0))
;;; Generated autoloads from ein-smartrep.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-smartrep" '("ein:smartrep-notebook-mode-alist")))
;;;***
;;;### (autoloads nil "ein-subpackages" "ein-subpackages.el" (0 0
;;;;;; 0 0))
;;; Generated autoloads from ein-subpackages.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-subpackages" '("ein:completion-backend")))
;;;***
;;;### (autoloads nil "ein-timestamp" "ein-timestamp.el" (0 0 0 0))
;;; Generated autoloads from ein-timestamp.el
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ein-timestamp" '("ein:timestamp-")))
;;;***
;;;### (autoloads nil "ein-traceback" "ein-traceback.el" (0 0 0 0))
@ -699,7 +466,7 @@ Show full traceback in traceback viewer.
(if (featurep 'org) (let* ((orig (get 'org-babel-load-languages 'custom-type)) (orig-cdr (cdr orig)) (choices (plist-get orig-cdr :key-type))) (push '(const :tag "Ein" ein) (nthcdr 1 choices)) (put 'org-babel-load-languages 'custom-type (cons (car orig) (plist-put orig-cdr :key-type choices)))))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ob-ein" '("ob-ein-" "org-babel-edit-prep:ein" "*ob-ein-sentinel*")))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "ob-ein" '("ob-ein-" "*ob-ein-sentinel*")))
;;;***
@ -707,12 +474,12 @@ Show full traceback in traceback viewer.
;;; Generated autoloads from poly-ein.el
(autoload 'poly-ein-mode "poly-ein")
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "poly-ein" '("pm-" "poly-ein-" "ein:polymode")))
(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "poly-ein" '("pm-" "poly-ein-")))
;;;***
;;;### (autoloads nil nil ("ein-hy.el" "ein-pkg.el" "ein.el") (0
;;;;;; 0 0 0))
;;;### (autoloads nil nil ("ein-completer.el" "ein-pkg.el" "ein.el")
;;;;;; (0 0 0 0))
;;;***

Some files were not shown because too many files have changed in this diff Show more