亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? ascscrn.cpp

?? 使用BorlandC++4.5編譯的一個(gè)MUD客戶端程序
?? CPP
?? 第 1 頁 / 共 2 頁
字號(hào):
    const void * source = &_TextElement(Pos(0,source_row));
    memcpy(target, source, Width() * sizeof(char));

    // Move color info now (cross your fingers!)
    Pos source_pos(0,source_row);
    Pos target_pos(0,target_row);
    for (int i = 0; i < Width(); i++)
    {
        _ForegroundElement(target_pos) = _ForegroundElement(source_pos);
        source_pos.X() += 1;
        target_pos.X() += 1;
    };

}

// _ClearRows - quick and dirty
//
void AsciiScreen::_ClearRows(int top, int bottom)
{
    for (int i=top; i <= bottom; i++)
        _ClearRow(i);
}

// ClearRow - clears row to spaces and sets it to the current color!
void AsciiScreen::_ClearRow(int row)
{
    ASSERT(row >= 0 && row < Height(), "Row must be on screen");

    _Invalidate(Pos(0,row), Size(Width(),1));
    
    // Just set the row to all spaces
    memset(&_TextElement(Pos(0,row)), ' ', (Width() * sizeof(char)));

    int start = (row * Width());
    int end = start + Width();
    for (int i = start; i < end; i++)
    {
        ASSERT(i < (Width() * Height()), "Index past end of array?");
        ASSERT(i >= 0, "Negative array index not allowed");
        
        _foreground[i] = _cursorForeground;
    };
}

void AsciiScreen::_ClearScreen()
{
    // Initialize screen memory
    memset(_text, (int)' ', (Width() * Height() * sizeof(char)));

    // Initialize all screen colors
    for (int i=0; i < (Width() * Height()); i++)
        _foreground[i] = _cursorForeground;

    _Invalidate(Pos(0,0), Size(Width(),Height()));
}

void AsciiScreen::_ClearToEOL()
{
    int width = Width() - _cursor.X();
    memset(&_TextElement(_cursor), ' ', width * sizeof(char));

    _Invalidate(_cursor, Size(width,1));

    // Set Color
    int start = ((_cursor.Y() * Width()) + _cursor.X()) - 1;
    int end = ((_cursor.Y() + 1) * Width()) - 1;
    ASSERT(end < (Width() * Height()), "Index past end of array?");
    ASSERT(end >= 0, "Negative array index?");
    
    for (int i = start; i < end; i++)
        _foreground[i] = _cursorForeground;

}

void AsciiScreen::_EscapeSequence(EscapeSequence & esc)
{
    // We are assuming that the sequence is comeplete, etc.
    //
    // Note that screen locations are 1-indexed in the escape sequences,
    // so there's lots of "subtract one" here.
    switch (esc.Type())
    {
      case EscapeSequence::CMOVE:
        {
            Pos new_pos(esc.Parameter(1) - 1,  // Column
                        esc.Parameter(0) - 1); // Row

            if (IsOnScreen(new_pos)) // Ignore if off screen
            {
                _Invalidate(_cursor, Size(1,1));
                _cursor = new_pos;
                _Invalidate(_cursor, Size(1,1));
            };
        };
        break;
        
      case EscapeSequence::SCROLL: // Set scroll region
        _scrollRegionTop = esc.Parameter(0) - 1;
        _scrollRegionBottom = esc.Parameter(1) - 1;

        // Make sure the scroll region is on screen
        if (_scrollRegionTop < 0)
            _scrollRegionTop = 0;
        else if (_scrollRegionTop >= Height())
            _scrollRegionTop = Height() - 1;

        if (_scrollRegionBottom < 0)
            _scrollRegionBottom = 0;
        else if (_scrollRegionBottom >= Height())
            _scrollRegionBottom = Height() - 1;

        if (_scrollRegionBottom < _scrollRegionTop)
            _scrollRegionBottom = _scrollRegionTop;
        
        break;
        
      case EscapeSequence::REV_NEWLINE: // Scroll current region back one
        _ReverseNewLine();
        break;    
  
      case EscapeSequence::CLRSCR:
        _ClearScreen();
        _cursor.X() = 0;
        _cursor.Y() = 0;
        break;
        
      case EscapeSequence::CLREOL:
        _ClearToEOL();
        break;
        
      case EscapeSequence::ANSI_COLOR:
        _AnsiColor(esc);
        break;
        
      case EscapeSequence::UNKNOWN: // Unrecoginzed by parser
      case EscapeSequence::NONE:   // Error, not parsed correctly
      default:
        ASSERT(0, "Unexpected escape sequence");
        break; // Not reached
    };
}

// _IncrementPos - move cursor one space
//
// This automatically wraps the cursor if at eol, and scrolls the screen
// if it is the last point on the screen
void AsciiScreen::_IncrementPos()
{
    if ((_cursor.X() + 1) >= Width())
    {
        _Invalidate(_cursor, Size(1,1));
        _NewLine();
        _Invalidate(_cursor, Size(1,1)); 
    }
    else
    {
        _Invalidate(_cursor, Size(2,1)); // Invalidate two spaces
        _cursor.X() += 1;
    };
}

void AsciiScreen::_ReverseNewLine()
{
    _cursor.X() = 0;      // Wrap X of cursor

    // Either wrap Y or scroll
    if ((_cursor.Y() - 1) < _scrollRegionTop) // Need to scroll?
        _ScrollCurrentRegion(-1);
    else
        _cursor.Y() -= 1;
    
    ASSERT(IsOnScreen(_cursor), "Logic error moved cursor off screen");
}

// ------------------------------------------------------------------
// _CarriageReturn - cursor to column 0, no line feed.
//
void AsciiScreen::_CarriageReturn()
{
    if (0 != _cursor.X()) // Don't bother if already at col 0
    {
        _Invalidate(_cursor, Size(1,1)); // Invalidate old pos
        _cursor.X() = 0;
        _Invalidate(_cursor, Size(1,1)); // Invalidate new pos
    };
}

// ------------------------------------------------------------------
// _NewLine - wrap cursor
//
void AsciiScreen::_NewLine(int count)
{
    _cursor.X() = 0;      // Wrap X of cursor
    int scroll_count = 0; // Amount to scroll current screen

    while (count)
    {
        -- count;
        // Either wrap Y or scroll
        if (_cursor.Y() >= _scrollRegionBottom) // Need to scroll?
            ++ scroll_count;
        else
            _cursor.Y() += 1;
    };
    if (0 < scroll_count)
        _ScrollCurrentRegion(scroll_count);
    
    ASSERT(IsOnScreen(_cursor), "Cursor moved past bottom of screen");
}

// EOF //

@2.1log@Roll.@text@d3 4a6 4// $Id: ascscrn.cpp 1.5 1995/10/15 23:27:50 tsurace Beta tsurace $// $Log: ascscrn.cpp $// Revision 1.5  1995/10/15  23:27:50  tsurace// Added a comment.d8 3d149 1a149 1    // Hell, I give up, something's really wrong--lose datad172 2a173 2            if (put_me == '\r')        // Ignore carriage returns?                ; // do nothingd257 1a257 1    a485 5        _Invalidate(_cursor, Size(1,1));        _cursor.X() = esc.Parameter(1) - 1; // Column        _cursor.Y() = esc.Parameter(0) - 1; // Row                if (! IsOnScreen(_cursor)) // cursor is off screen?d487 9a495 2            _cursor.X() = 0;       // Reset the cursor to a safe location            _cursor.Y() = 0;a496 1        _Invalidate(_cursor, Size(1,1));d575 13@1.5log@Added a comment.@text@d3 5a7 2// $Id: ascscrn.cpp 1.4 1995/10/11 20:58:37 tsurace Exp tsurace $// $Log: ascscrn.cpp $@1.4log@Switched to my ASSERT macro.Fixed reverse-scroll bug that caused core (or ASSERT failure).Added try/catch blocks to stop memory leaks.@text@d3 1a3 1// $Id: ascscrn.cpp 1.3 1995/10/08 23:27:10 tsurace Exp tsurace $d5 5d197 5a201 1// Does not attempt to preserve the contents@1.3log@Added ansi (foreground) color support.@text@d3 5a7 2// $Id$// $Log$d14 1a14 1#include <assert.h>d18 1d63 2a64 2    assert (0 == bold || 1 == bold);   // Invalid parameters?    assert (color >= 0 && color <= 7);d104 2a105 2    assert(NULL != _invalidateFunc); // Bad pointer!    assert(NULL != _scrollFunc);d124 1a124 1    assert(IsOnScreen(pos)); // Is this position valid?a137 2    _inputBuffer.Append(c);     // Append string to bufferd142 2d181 1a181 1    assert(NULL != c); // Null pointer is illegald196 11a206 2    delete [] _text;    _text = new char[width * height];d208 3d212 2a213 1    _foreground = new COLORREF[width * height];d239 3a241 3    assert(bottom >= top); // Hey, this won't work!    assert(top >= 0);    assert(bottom < Height()); // Off screen?a245 4    // This is tricky - it lets me pretend bottom is one past the    // actual bottom of the scroll area    ++ bottom;    d251 1a251 1        if (amount > bottom - top)d259 1a259 1            for (i = top; (i + amount) < bottom; i++)d263 1a263 1            for (i = (bottom - amount); i < bottom; i++)d269 1a269 1        if ((-amount) > bottom - top)d276 1a276 1            for (i = bottom; (i + amount) > top; i--)d287 1a287 1        _ClearRows(top, bottom-1);d292 2a293 2        if (0 == _CallScrollFunc(top,bottom - 1,amount))            _Invalidate(Pos(0,top), Size(Width(),bottom-top));d381 2a382 2    assert(target_row >= 0 && target_row < Height());  // Off screen?    assert(source_row >= 0 && source_row < Height());d414 1a414 1    assert(row >= 0 && row < Height()); // Off screen?d425 2a426 2        assert(i < (Width() * Height())); // Out of bounds?        assert(i >= 0);d454 2a455 2    assert(end < (Width() * Height())); // Out of bounds?    assert(end >= 0);                   // Out of bounds?d474 6a479 1        assert(IsOnScreen(_cursor)); // Oops!d486 15a500 2        assert(_scrollRegionTop >= 0 && _scrollRegionTop < Height());        assert(_scrollRegionBottom >= 0 && _scrollRegionBottom < Height());d524 1a524 1        assert(0); // Oops!d558 1a558 1    assert(IsOnScreen(_cursor)); // Off Screen?d573 1a573 1        if ((_cursor.Y() + 1) > _scrollRegionBottom) // Need to scroll?d581 1a581 1    assert(IsOnScreen(_cursor)); // Off Screen?@1.2log@Added Resize function, reverse newline handling.@text@d3 3a5 1// Please note:  This module makes MS-Windoze calls  :}  I got lazy!d16 32a47 1// Temporaryd49 16d87 1d108 1a108 1    delete [] _text;d293 58a444 1    {d446 1a446 1    };d486 2a487 2      case EscapeSequence::BOLD_ON:        _cursorForeground = _boldForeground;a489 4      case EscapeSequence::BOLD_OFF:        _cursorForeground = _normalForeground;        break;@1.1log@Initial revision@text@d85 4d135 24d216 1a216 1            for (i = top; i < (bottom + amount); i--)d224 1a224 1        _ClearRows(top, bottom);d286 1a286 1    for (int i=top; i < bottom; i++)d300 1a300 1    int start = (row * Width()) - 1;a317 1    {d319 1a319 1    };d365 2a366 2      case EscapeSequence::SCR_REV: // Scroll current region back one        // Not implementedd412 13@

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品制服美女久久| 精品国产sm最大网站免费看| 国产一区二区精品久久91| 亚洲国产精品一区二区久久| 日韩美女视频一区二区| 国产精品精品国产色婷婷| 久久精品一区蜜桃臀影院| 日韩免费视频一区| 精品日产卡一卡二卡麻豆| 日韩午夜电影av| 精品国产免费人成电影在线观看四季 | 亚洲欧美日韩人成在线播放| 久久日韩精品一区二区五区| 日韩视频免费观看高清在线视频| 成人av在线影院| 91老司机福利 在线| 国产精品66部| 99精品1区2区| 91激情在线视频| 精品久久久久久久久久久久包黑料| 精品免费国产二区三区| 欧美岛国在线观看| 久久精品视频一区二区三区| 日韩欧美在线123| 亚洲欧洲韩国日本视频| 午夜伊人狠狠久久| 国产成人一区在线| 欧美一卡二卡三卡| 国产精品不卡在线| 裸体一区二区三区| 91理论电影在线观看| 久久影音资源网| 亚洲一区二区三区四区在线免费观看| 天天综合天天综合色| 国产盗摄精品一区二区三区在线 | 日本福利一区二区| 欧美剧情片在线观看| 国产精品天干天干在观线| 免费成人在线播放| 欧美日本在线看| 亚洲欧美偷拍另类a∨色屁股| 国产一区二区在线电影| 欧美日韩国产在线观看| 一区二区三区成人| www.在线欧美| 亚洲欧洲日韩综合一区二区| 经典三级视频一区| 久久婷婷国产综合国色天香| 一二三区精品视频| 欧美日韩中文精品| 婷婷综合另类小说色区| 国产精品亚洲第一| 欧美国产成人精品| 国产精品一区一区| 亚洲欧美一区二区在线观看| 成人黄色av电影| 亚洲黄色录像片| 欧美喷潮久久久xxxxx| 亚洲一二三级电影| 在线国产电影不卡| 午夜视频在线观看一区二区三区| 欧美日韩亚洲丝袜制服| 日韩av一区二区三区四区| 日韩午夜在线影院| 成人美女在线视频| 亚洲自拍欧美精品| 日韩免费视频一区二区| 成人一区二区三区视频在线观看 | 亚洲国产精品一区二区尤物区| 国产视频一区二区在线| 不卡一区在线观看| 亚洲黄色av一区| 国产福利精品导航| 国产女主播在线一区二区| 日韩高清在线不卡| 日韩视频在线你懂得| 风间由美性色一区二区三区| 国产欧美精品区一区二区三区 | 94-欧美-setu| 日本欧美一区二区三区| 国产精品无遮挡| 久久久青草青青国产亚洲免观| 欧美综合视频在线观看| 国产成人99久久亚洲综合精品| 午夜伊人狠狠久久| 亚洲人成网站精品片在线观看| 精品一区二区三区久久| 日韩和欧美的一区| 欧美日韩黄色一区二区| 91国模大尺度私拍在线视频| 久久电影网站中文字幕| 日韩天堂在线观看| 欧美中文字幕一区二区三区亚洲| 亚洲成人激情社区| 一区二区高清在线| 一区二区在线观看免费视频播放| 久久久综合精品| 国产婷婷色一区二区三区四区 | 日本中文字幕一区二区有限公司| 国产欧美一区二区三区鸳鸯浴| 精品电影一区二区三区 | 91精品国产一区二区三区| 91福利精品视频| 欧美精品成人一区二区三区四区| 91麻豆精品国产自产在线| 91精品国产福利在线观看| 日韩视频免费观看高清完整版 | 欧美日韩在线三级| 91精品国产免费| 精品久久久久久久久久久院品网| 精品少妇一区二区三区免费观看| 亚洲精品一区二区三区影院| 国产三级欧美三级| 亚洲第一成年网| 成人av电影免费观看| 91麻豆精品国产91久久久使用方法| 久久先锋影音av| 日韩中文字幕av电影| 99久久精品国产导航| 日韩精品一区二区三区老鸭窝| 中文字幕日韩欧美一区二区三区| 日韩av一区二区三区| 欧美日韩午夜在线视频| 亚洲视频在线一区| 国产高清不卡一区| 欧美va亚洲va香蕉在线| 日韩在线观看一区二区| 欧美性受xxxx黑人xyx性爽| 最新国产成人在线观看| 99久久综合精品| 国产精品伦理在线| 99r国产精品| 亚洲综合免费观看高清完整版| 91美女在线视频| 一区二区三区在线观看动漫| 99re66热这里只有精品3直播| 欧美—级在线免费片| 国产不卡在线播放| 欧美韩国日本不卡| 色综合久久久久综合体桃花网| 亚洲久本草在线中文字幕| 91国产视频在线观看| 日本va欧美va瓶| 国产亚洲综合av| 99久久精品免费看| 免费精品视频在线| 欧美国产日本视频| 欧美三级视频在线播放| 舔着乳尖日韩一区| 国产亚洲欧美日韩俺去了| 色偷偷成人一区二区三区91 | 色88888久久久久久影院按摩| 亚洲精品福利视频网站| 日韩欧美国产高清| 91免费版pro下载短视频| 蜜桃视频一区二区三区| 国产精品久久久久久久久晋中 | 国产一区二区毛片| 亚洲成av人在线观看| 国产欧美精品一区二区色综合| 欧美在线观看视频一区二区| 国产一区在线视频| 日韩高清国产一区在线| 亚洲女与黑人做爰| 国产亚洲精品7777| 欧美v国产在线一区二区三区| 色网站国产精品| 色综合久久中文综合久久牛| 激情综合亚洲精品| 秋霞影院一区二区| 亚洲国产一二三| 一区二区欧美视频| 亚洲一区自拍偷拍| 亚洲一级二级在线| 亚洲在线免费播放| 亚洲精选在线视频| 婷婷丁香激情综合| 五月婷婷另类国产| 青青国产91久久久久久| 天天综合日日夜夜精品| 青青青伊人色综合久久| 毛片一区二区三区| 狠狠久久亚洲欧美| 成人高清视频在线| 欧美在线免费观看亚洲| 欧美日韩国产影片| 国产三级三级三级精品8ⅰ区| 国产蜜臀av在线一区二区三区| 国产精品欧美久久久久一区二区| 国产精品国产三级国产有无不卡 | 欧美日韩国产色站一区二区三区| 麻豆精品在线观看| 国产亚洲人成网站| 亚洲精选视频在线| 蜜桃视频一区二区| 91免费版在线| 国产欧美日韩在线看| 国产精品嫩草影院av蜜臀| 亚洲日本va午夜在线影院| 亚洲第一av色|