Re: [gnome-mud] <ESC>2K Does not reset cursor position.



Hello Doug,

On Sun, 2009-02-01 at 19:52 -0700, Doug Morrow wrote:
> It would appear to me that the standard behavior when receiving an
> <ESC>2K would be to not only clear the line but to reset the cursor
> position to the beginning of the line... otherwise things like idling
> on my mud result in the player status bar gradually moving to the
> right!
> 
> The simple telnet program included in Ubuntu 8.10 demonstrates the
> proper behavior, rogue spacing is never leftover, because the cursor
> position is reset.
> 
> I'm just having a hard time finding the place in the code that parses
> the ansi codes...

What you are referring to as ansi codes are in my terminology "Standard
ECMA-48 Control Functions for Coded Character Sets" Control Sequences
documented in the freely available ECMA-048.pdf document. The ANSI
standard body maybe had a standard for a very similar thing as well, or
just their own number. Anyway, that's that, the take-away point here is
that there is this extensive document that documents all the things you
might not ever wanted to know about these control sequences :)

In gnome-mud all this is taken care of by the VTE library. Hence it
would be interesting to know how a _raw_ log of your MUD session with
that <esc>2K in it would behave if 'cat raw.log' is done in a VTE based
terminal client, such as gnome-terminal, XFCE's Terminal or evilvte.
And how it behaves in a telnet session that is running inside such a
terminal.
Also, can you find in the ECMA-048 document what command is that 'K' and
what it is documented to do? Cursor position reset or not, etc.

> If someone could help me by submitting a quick patch to illustrate how
> I can make this change, I do like the client!

Any change here would actually affect all VTE based things - and if the
standard says it is doing it wrong currently, then it's perhaps a bug
worth fixing, unless real world convention is otherwise for some reason
or some such reasoning that VTE developers can comment on once we get
more details about this.


I hope this helps a bit, and doesn't scare you away with it being in the
VTE library. Might be fun to do some digging in the standards document,
no VTE knowledge needed or anything for starters.

The standards PDF document is available from
http://www.ecma-international.org/publications/standards/Ecma-048.htm


Please let us know of your findings,

Kind Regards,
Mart Raudsepp



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]