|
From: | Juergen Sauermann |
Subject: | Re: [Bug-apl] Request for feature: Embedded mode |
Date: | Mon, 09 Dec 2013 17:07:49 +0100 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130330 Thunderbird/17.0.5 |
Hello Elias,
I think most of the things below do already exist. Lets say you write the following in the preferences file for GNU APL: Color ANSI (default) CIN-SEQUENCE 5b 5b 20 49 4E 20 20 5d 5d // [[ IN ]] COUT-SEQUENCE 5b 5b 20 4F 55 54 20 5d 5d // [[ OUT ]] CERR-SEQUENCE 5b 5b 20 45 52 52 20 5d 5d // [[ ERR ]] RESET-SEQUENCE // nothing Then GNU APL produces this: [[ IN ]] 1 + 2 [[ OUT ]]3 [[ IN ]] ]log 5 [[ ERR ]] Log facility ' ... function find_closing() ' is now ON [[ IN ]] 2 + 3 [[ OUT ]]5 [[ IN ]] The channel tag [[ IN/OUT/ERR ]] is sent whenever GNU APL switches from one channel to another. We could create an --emacs commandl line option that sets it to any value you prefer (no need to be fully configurable) so people would not need to modify the preferences file. The stderr printout on )ERASE should have gone already; there may be some printouts to CERR left over here and there, but they should be removed over time. The CIN channel is used for printing the prompt and for making the ⍞ prompt editable (a somewhat awkward feature of ⍞ input). The echoing of the user input is done by eg. readline, not by CIN. CIN and COUT both go to stdout and you can use the tags above to distinguish them. Normally the prompt is 6 blanks which is easy to overlook. If the prompt is not-editable (and the 6 blanks prompt is not) then the prompt is displayed by readline and not by CIN, which is my best explanation for not showing up in emacs. With readline disabled you may see it. /// Juergen On 12/09/2013 03:23 PM, Elias Mårtenson wrote:
|
[Prev in Thread] | Current Thread | [Next in Thread] |