Skip to content

Commit

Permalink
Use new command line syntax for colors
Browse files Browse the repository at this point in the history
  • Loading branch information
Pedro Kroger authored and Pedro Kroger committed Sep 3, 2011
1 parent 7b26cae commit d2d967a
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions docs/emacs/ipython.el
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
;; always in ``pylab`` mode with hardcoded light-background colors, you can ;; always in ``pylab`` mode with hardcoded light-background colors, you can
;; use:: ;; use::
;; ;;
;; (setq py-python-command-args '("-pylab" "--colors" "LightBG")) ;; (setq py-python-command-args '("-pylab" "--colors=LightBG"))
;; ;;
;; ;;
;; NOTE: This mode is currently somewhat alpha and although I hope that it ;; NOTE: This mode is currently somewhat alpha and although I hope that it
Expand Down Expand Up @@ -220,14 +220,14 @@ the second for a 'normal' command, and the third for a multiline command.")
(unless (member "--colors" py-python-command-args) (unless (member "--colors" py-python-command-args)
(setq py-python-command-args (setq py-python-command-args
(nconc py-python-command-args (nconc py-python-command-args
(list "--colors" (list (concat "--colors="
(cond (cond
((eq frame-background-mode 'dark) ((eq frame-background-mode 'dark)
"Linux") "Linux")
((eq frame-background-mode 'light) ((eq frame-background-mode 'light)
"LightBG") "LightBG")
(t ; default (backg-mode isn't always set by XEmacs) (t ; default (backg-mode isn't always set by XEmacs)
"LightBG")))))) "LightBG")))))))
(unless (equal ipython-backup-of-py-python-command py-python-command) (unless (equal ipython-backup-of-py-python-command py-python-command)
(setq ipython-backup-of-py-python-command py-python-command)) (setq ipython-backup-of-py-python-command py-python-command))
(setq py-python-command ipython-command)) (setq py-python-command ipython-command))
Expand Down Expand Up @@ -351,7 +351,7 @@ in the current *Python* session."
(process-send-string python-process (process-send-string python-process
(format ipython-completion-command-string pattern)) (format ipython-completion-command-string pattern))
(accept-process-output python-process) (accept-process-output python-process)

;(message (format "DEBUG return: %s" ugly-return)) ;(message (format "DEBUG return: %s" ugly-return))
(setq completions (setq completions
(split-string (substring ugly-return 0 (position ?\n ugly-return)) sep)) (split-string (substring ugly-return 0 (position ?\n ugly-return)) sep))
Expand Down

0 comments on commit d2d967a

Please sign in to comment.