minor updates.

git-svn-id: svn://qnap.local/TwoTerm/trunk@3154 5590a31f-7b70-45f8-8c82-aa3a8e5f4507
This commit is contained in:
Kelvin Sherlock 2017-02-05 18:15:34 +00:00
parent e1c6f11214
commit 70b38025ba
4 changed files with 14 additions and 14 deletions

View File

@ -358,51 +358,51 @@ enum {
switch (_state)
{
case StateDCAX:
_dca.x = c - 32;
_dca.x = (c & 0x7f) - 32;
_state = StateDCAY;
break;
case StateDCAY:
_dca.y = c - 32;
screen->setCursor(&_textPort, _dca);
_dca.y = (c & 0x7f) - 32;
// goto xy does not respect the text window.
if (_dca.x >= 80) _dca.x = 0;
if (_dca.y >= 24) _dca.y = 0;
screen->setCursor(&_textPort, _dca);
//screen->setCursor(_dca);
_state = StateText;
break;
case StateSetPort1:
// [
if (c == '[')
{
_state++;
}
else
{
_state = StateText;
}
break;
case StateSetPort2:
// left
_vp[0] = c - 32;
_vp[0] = (c & 0x7f) - 32;
_state++;
break;
case StateSetPort3:
// right
_vp[1] = c - 32 + 1;
_vp[1] = (c & 0x7f) - 32 + 1;
_state++;
break;
case StateSetPort4:
// top
_vp[2] = c - 32;
_vp[2] = (c & 0x7f) - 32;
_state++;
break;
case StateSetPort5:
// bottom
// and validation.
_vp[3] = c - 32 + 1;
_vp[3] = (c & 0x7f) - 32 + 1;
_vp[0] = std::max(0, _vp[0]);
_vp[2] = std::max(0, _vp[2]);

View File

@ -190,7 +190,7 @@ enum {
screen->deleteLine(&_textPort, _textPort.cursor.y);
break;
case CTRL('V'):
//Insert blank like.
//Insert blank line.
// TODO -- verify if the line is before or after the current line,
// TODO -- verify if x/y change
// TODO -- verify scrolling behavior.

View File

@ -117,7 +117,7 @@
s.append([_emulator termName]);
s.append(1, (char)0);
s.append(1, (char )0);
s.append(1, (char)0);
for (std::string::size_type index = 0;;)
{

View File

@ -75,7 +75,7 @@ private:
#ifdef __cplusplus
ring_buffer<256> _debug_buffer;
ring_buffer<1024> _debug_buffer;
ViewScreen _screen;
#endif