Hi,
(non)Update on this old issue.
Neil Jerram wrote:
Good point. I believe Jon's going to raise this (inability to do
readline starting from the column after the prompt) with the readline
people.
I filed a bug report some time ago, since I was unable to find any sort
of users mailing list. I
Neil Jerram <[EMAIL PROTECTED]> writes:
>
> Good point. I believe Jon's going to raise this (inability to do
> readline starting from the column after the prompt) with the readline
> people.
I see there's an rl_already_prompted, though you still have to tell it
the prompt string to make redisplay
Kevin Ryde <[EMAIL PROTECTED]> writes:
> Neil Jerram <[EMAIL PROTECTED]> writes:
>>
>> Slightly confusingly, set-readline-prompt! does also set the default
>> prompt for an explicit `readline' call (1). I think the overall
>> situation would be clearer if it didn't.
>
> It's not too terrible, may
Kevin Ryde <[EMAIL PROTECTED]> writes:
> This is what I ended up checking-in.
This all looks great to me; sorry for not commenting earlier!
Regards,
Neil
___
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile
This is what I ended up checking-in.
6.5.3 Readline Functions
The following functions are provided by
(use-modules (ice-9 readline))
There are two ways to use readline from Scheme code, either make
calls to `readline' directly to get line by line input, or use
I wrote:
>
> ... some words for the manual.
What else should be described?
Extra options to `readline' for the input/output ports, or is that
only meant for the %readline level and only set-readline-input-port!
for the high level?
(readline-port) create/return the readline port?
Is it possible
Neil Jerram <[EMAIL PROTECTED]> writes:
>
> + (let ((outer-new-input-prompt new-input-prompt)
> + (outer-continuation-prompt continuation-prompt)
Could there be a way for an application to get the prompts back,
so it could do the same sort of save/restore too?
_
Neil Jerram <[EMAIL PROTECTED]> writes:
>
> Slightly confusingly, set-readline-prompt! does also set the default
> prompt for an explicit `readline' call (1). I think the overall
> situation would be clearer if it didn't.
It's not too terrible, may as well leave it alone in case anyone's
nutted i
Neil Jerram <[EMAIL PROTECTED]> writes:
> The bug which Jon has noted, about the effect of set-readline-prompt!
> not lasting very long, is caused by the fact that Guile's REPL code,
> when using readline, does a
>
> (set-readline-prompt! "guile>" "...")
>
> before reading an expression from the
Kevin Ryde <[EMAIL PROTECTED]> writes:
> Neil Jerram <[EMAIL PROTECTED]> writes:
>>
>> ... instead of by a parameter to `readline',
>
> Is that readline function meant to be used? I assume it's emulating
> the C function of that name. If you use it and no other input it
> works does it?
Yes, it
Neil Jerram <[EMAIL PROTECTED]> writes:
>
> ... instead of by a parameter to `readline',
Is that readline function meant to be used? I assume it's emulating
the C function of that name. If you use it and no other input it
works does it?
___
Guile-use
Hi Kevin,
It might be as simple as
(readline "foo: ")
Not sure if that's meant to be documented, seems like a pretty
sensible usage, even if reading current-input-port might be usual.
Sorry, I think I misunderstood you before. I thought you had gotten
confused between `read-line' a
Jon Wilson <[EMAIL PROTECTED]> writes:
> Hi Kevin,
>
>> (readline "foo: ")
>
> This gives an error.
I think what you need is (set-readline-prompt! "foo: "). The reason
it's done this way, instead of by a parameter to `readline', is that
when readline is activated it applies to the input por
Hi Kevin,
(readline "foo: ")
This gives an error.
(read-line (current-input-port) 'trim "foo: ")
does not give an error, but "foo: " is ignored. The first two arguments
are the port to read from and the handle-delim value. Any further
arguments seem to be completely ignored. Sor
Jon Wilson <[EMAIL PROTECTED]> writes:
>
> This prints "prompt: " on a line, and then after a short time, it is
> erased.
It might be as simple as
(readline "foo: ")
Not sure if that's meant to be documented, seems like a pretty
sensible usage, even if reading current-input-port might be
Hi,
I'm trying to read user input (interactive) using guile. I'd like to use
(ice-9 readline), so that the user can use backspace and history and such.
I'd also like to have a prompt at the beginning of the line. These last
two desires seem to be incompatible, at least mod my best efforts.
16 matches
Mail list logo