Takafumi Arakaki
bccae92dde
Use ein-shared-output.el from ein-connect.el
2012-05-24 13:17:42 +02:00
Takafumi Arakaki
2cc5f5c1db
Add ein-shared-output.el
2012-05-24 12:56:07 +02:00
Takafumi Arakaki
fd045e2587
Fix payload handler: %loadpy works now
2012-05-23 23:32:51 +02:00
Takafumi Arakaki
fb1067835b
Add tests for input-prompt-number
2012-05-23 23:13:24 +02:00
Takafumi Arakaki
2201f41ea3
Add a note on the input-prompt-number slot
2012-05-23 23:03:59 +02:00
Takafumi Arakaki
98bd0ccb5a
Revert "Make input-prompt-number slot typed"
...
Strongly typed `:input-prompt-number' becomes a problem when reading a
notebook that saved "*". As treating it using `:running' makes no
sense (nothing is running on kernel when the notebook is opened),
using flexible type for the slot is the right choice.
This reverts commit 5402274c71
.
2012-05-23 22:56:36 +02:00
Takafumi Arakaki
89b7f008aa
Little bit wiser rename command
2012-05-23 21:50:25 +02:00
Takafumi Arakaki
ad0adf9884
Fix ein:cell-output-json-to-class
...
ein:notebook-clear-output-command could not clear out extra newline in
the footer.
2012-05-23 20:20:02 +02:00
Takafumi Arakaki
5402274c71
Make input-prompt-number slot typed
2012-05-23 20:10:52 +02:00
Takafumi Arakaki
47d4beb30d
Make input area face work nicely with zenburn
2012-05-23 19:41:02 +02:00
Takafumi Arakaki
617f166a5c
Flush out echo area after saving notebook
...
Otherwise, "Connecting to..." or "Retry saving..." remains in the echo
area. Also, message when the saving is fail is added.
2012-05-23 19:08:07 +02:00
Takafumi Arakaki
3cf3a6d17a
Don't move pointer when copying cell
2012-05-23 18:49:54 +02:00
Takafumi Arakaki
160f15becd
Fix: copied cell can't be executed
2012-05-23 18:46:09 +02:00
Takafumi Arakaki
294eded27e
Add tests for the previous fix
2012-05-23 15:53:10 +02:00
Takafumi Arakaki
905aee9133
Quick fix for ein:notebook-cell-from-type
2012-05-23 15:46:51 +02:00
Takafumi Arakaki
45206014ff
Merge branch 'refactor-kernel'
...
Kernel module is decoupled from cell and notebook module. This
enables interaction to the kernels from non-notebook buffers. To
demonstrate this ability, ein-connect.el is added. This module
connect any buffer to existing notebook, enables tool-tip, help
browser and completion functionality to be used in the buffer.
Changes are mostly following the refactoring in IPython JS client:
https://github.com/ipython/ipython/pull/1711
This merge fixes #1 .
2012-05-23 14:14:12 +02:00
Takafumi Arakaki
5e80b885b5
Use ac-source-ein-cached in connected buffer
2012-05-23 13:42:54 +02:00
Takafumi Arakaki
bb091e0406
Trim indent when eval-ing buffer with ein:connect
2012-05-23 13:30:34 +02:00
Takafumi Arakaki
1113b4eeb2
Add ein:trim-indent and its tests
2012-05-23 13:24:21 +02:00
Takafumi Arakaki
2f8676ee4c
Rename to ein:notebook-complete-command
2012-05-23 11:27:52 +02:00
Takafumi Arakaki
e0b99eb069
Add ein:connect-complete-command
2012-05-23 11:26:51 +02:00
Takafumi Arakaki
99cfe8e8c4
Autoload ein:connect-to-notebook
2012-05-23 11:09:54 +02:00
Takafumi Arakaki
41baba4410
Add ein:connect-request-tool-tip-or-help-command
2012-05-23 11:06:54 +02:00
Takafumi Arakaki
7a2f998195
Add a FIXME comment on ein-connect.el
2012-05-23 11:04:22 +02:00
Takafumi Arakaki
260b2d8e7d
Add ein:notebook-opened-buffers
...
Put shared logic together.
2012-05-23 10:48:43 +02:00
Takafumi Arakaki
7a331b6895
Remove unnecessary line from ein:notebook-open
...
Don't need to remove key from the map here, since it will be
added (overwritten) later by ein:notebook-url-retrieve-callback.
2012-05-23 10:47:43 +02:00
Takafumi Arakaki
e1822283ac
Add ein-connect.el
2012-05-23 04:23:17 +02:00
Takafumi Arakaki
146aac147f
Better emacs-lisp type output handling
2012-05-23 03:19:22 +02:00
Takafumi Arakaki
806d10ae06
Pass the test ein:notebook-request-help
2012-05-23 02:43:44 +02:00
Takafumi Arakaki
c42b756065
Fix ein:pager--open-with-text
...
Arguments for plist-get were flipped.
The previously added and failed test
ein:notebook-execute-current-cell-question is passed now.
2012-05-23 02:31:01 +02:00
Takafumi Arakaki
7ca440ab75
Merge branch 'master' into refactor-kernel
2012-05-23 02:26:05 +02:00
Takafumi Arakaki
d2801ebcfc
Add test: ein:notebook-execute-current-cell-question
2012-05-23 02:21:45 +02:00
Takafumi Arakaki
4cbd11ebaa
Merge branch 'master' into refactor-kernel
2012-05-23 02:10:14 +02:00
Takafumi Arakaki
d538d7673e
Add new test: ein:notebook-request-help
2012-05-23 02:03:23 +02:00
Takafumi Arakaki
3985f97eb8
Change the spec of callbacks: msg-type is str now
...
Test ein:notebook-execute-current-cell is passed.
At this point all unit tests in test/test-ein-*.el are passed.
msg-type was first a string and I changed it to a keyword when I am
writing ein:kernel-execute. But as I need to fix a lot of other
places, I change it back to a string. Note that msg-type can come
from JSON directly when the notebook is first opened, so it must be
consistent with that routines.
Maybe I will change it again, but at that time, symbol is better than
keyword because msg-type is a value rather than a key.
2012-05-23 01:40:00 +02:00
Takafumi Arakaki
676e4ff523
Fix test ein:notebook-execute-current-cell
...
Many old functions are updated.
2012-05-23 01:15:42 +02:00
Takafumi Arakaki
7e7d81c638
Fix ein:kernel-get-callbacks-for-msg
...
The order of arguments was wrong.
2012-05-23 01:13:10 +02:00
Takafumi Arakaki
2847424fcc
Fix ein:notebook-cell-from-type
...
TYPE is a symbol, not a string.
2012-05-23 01:12:12 +02:00
Takafumi Arakaki
46af87db27
Setup dummy kernel and events for notebook tests
...
This fixes a lot of tests (but not all).
2012-05-23 00:00:33 +02:00
Takafumi Arakaki
7fede75855
Fix ein:codecell: add kernel slot
2012-05-22 23:53:25 +02:00
Takafumi Arakaki
1c1135685b
Fix ein:notebook-new: remove msg-cell-map
2012-05-22 23:51:04 +02:00
Takafumi Arakaki
6a7b0497b0
Simplify mocking for test-ein-kernel.el
2012-05-22 23:45:53 +02:00
Takafumi Arakaki
085fd73823
Fix test-ein-kernel.el: these tests are passed
2012-05-22 23:32:47 +02:00
Takafumi Arakaki
18c7c027ff
Fix the event from ein:kernel-restart
2012-05-22 23:30:18 +02:00
Takafumi Arakaki
15a3f31412
Ensure that event hooks are called in notebook buffer
2012-05-22 23:03:21 +02:00
Takafumi Arakaki
83d7e15b04
Use updated execute functions in notebook
2012-05-22 22:38:39 +02:00
Takafumi Arakaki
7c4d628253
Setup event handler for kernel in notebook
2012-05-22 22:34:00 +02:00
Takafumi Arakaki
ce01997a1e
Setup kernel for code cells
2012-05-22 22:32:49 +02:00
Takafumi Arakaki
1fc79a506e
Fix ein:cell-execute: input text was not fetched
2012-05-22 22:30:34 +02:00
Takafumi Arakaki
d9bd79102b
Allow empty CALLBACKS for ein:kernel-execute
2012-05-22 22:28:32 +02:00