Implement command history
Posted: Mon Jul 11, 2016 11:42 pm
And here's the second question that I've been thinking about.
Does anyone know of anything that implements a command history? I'm thinking of a Unix/DOS type shell where you could press up and down arrow to work through the last few commands entered. I imagine you possibly can't get do this but if there was a way to intercept or hijack keypresses then you could probably cover the whole up/down thing, and the only real problem would be a way of capturing the 'line' before the QL processed it. So you'd also have to hijack the return key, I guess, store the line in a buffer, then allow the QL to process the line as usual.
If this is all well trodden ground, completely impossible due to certain QL internals that most of you already understand and know about, please just shoot me down and I'll look for another problem to tackle. But it there are things a little like this out there, it might be interesting to try and play with it - I certainly find entering direct commands a pain without some element of line-history.
Does anyone know of anything that implements a command history? I'm thinking of a Unix/DOS type shell where you could press up and down arrow to work through the last few commands entered. I imagine you possibly can't get do this but if there was a way to intercept or hijack keypresses then you could probably cover the whole up/down thing, and the only real problem would be a way of capturing the 'line' before the QL processed it. So you'd also have to hijack the return key, I guess, store the line in a buffer, then allow the QL to process the line as usual.
If this is all well trodden ground, completely impossible due to certain QL internals that most of you already understand and know about, please just shoot me down and I'll look for another problem to tackle. But it there are things a little like this out there, it might be interesting to try and play with it - I certainly find entering direct commands a pain without some element of line-history.