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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? window.cpp

?? 支持XMODEM,YMODEM,FAX協議的串口通信軟件包
?? CPP
字號:
// ******************************************************************** //
//                                                                      //
//      WINDOW.CPP                                                      //
//      Copyright (c) 1993, Michael Holmes and Bob Flanders             //
//      C++ Communication Utilities                                     //
//                                                                      //
//      Chapter 7: Receiving a FAX                                      //
//      Last changed in chapter 2                                       //
//                                                                      //
//      This file contains the definition and interface for             //
//      the window class.                                               //
//                                                                      //
// ******************************************************************** //


extern
int    _wscroll;                            // screen scrolling flag

enum    boxes                               // line drawing box types
    {
    none = -1,                              // no box
    single_line,                            // single line box
    double_line                             // double line box
    };

struct  box_characters                      // box drawing characters
     {
     char ul_char,                          // upper left corner
          ur_char,                          // upper right corner
          ll_char,                          // lower left corner
          lr_char,                          // lower right corner
          top_char,                         // horizontal line
          side_char;                        // vertical line
     } box_chars[2] =
         {
         { '\xda', '\xbf', '\xc0', '\xd9',  // single line box
           '\xc4', '\xb3'},
         { '\xc9', '\xbb', '\xc8', '\xbc',  // double line box
           '\xcd', '\xba'}
         };

class Window
    {
    public:
        Window(char ul_c, char ul_r,        // define window, upper left
               char lr_c, char lr_r,        //   lower right,
               char cn,   char cr);         //   normal & reverse colors
        void Open(boxes box = none),        // open window
             AtSay(int c, int r, char *s),  // display string at position
             AtSayReverse(int c, int r,     // display string at position
               char *s),                    //   in reverse video
             Display(char),                 // display a character
             Display(char *s),              // display a string
             DisplayReverse(char *s),       // display string in rev video
             Clear(void),                   // clear window
             GotoXY(int c, int r),          // goto xy location
             MakeCurrent(void),             // make window current
             Close(void);                   // close window
       ~Window();                           // destructor

    private:
        char  ul_col, ul_row,               // window upper left
              lr_col, lr_row,               // ..and lower right
              cursor_col, cursor_row,       // cursor column and row
              cn_color, cr_color,           // norm and reverse colors
             *old_data,                     // overlaid data
              open_flag,                    // window open/close flag
              scroll_flag;                  // scrolling enabled flag
        boxes border_flag;                  // border type
    };



//
//  Globals
//

int     max_lines = 25;                     // max lines on screen

Window *last_window;                        // last window pointer



/* ******************************************************************** *
 *
 *  Window -- define window instance
 *
 * ******************************************************************** */

Window::Window(char ul_c, char ul_r,        // upper left corner
               char lr_c, char lr_r,        // lower right corner
               char cn,   char cr)          // normal and reverse colors
{

ul_col = ul_c;                              // save window coordinates
ul_row = ul_r;                              // ..row and column
lr_col = lr_c;                              // ..for upper left
lr_row = lr_r;                              // ..and lower right

cn_color = cn;                              // save user colors
cr_color = cr;                              // ..for later

cursor_col = cursor_row = 1;                // init cursor column and row
open_flag = 0;                              // clear open flags

old_data = new char[(((lr_c - ul_c) + 1)    // get work buffer
            * ((lr_r - ul_r) + 1)) * 2];    // ..for old screen image

}



/* ******************************************************************** *
 *
 *  Open -- open a window
 *
 * ******************************************************************** */

void    Window::Open(boxes box)             // border flag
{
int     i;                                  // loop control
struct  box_characters *b;                  // box characters


if (open_flag)                              // q. window already opened?
    return;                                 // a. yes .. just return

border_flag = box;                          // set border flag
open_flag = 1;                              // show window opened

gettext(ul_col, ul_row, lr_col, lr_row,     // capture old screen data
            old_data);                      // ..to temp buffer

window(ul_col, ul_row, lr_col, lr_row);     // make window active

textcolor(FG(cn_color));                    // set up foreground
textbackground(BG(cn_color));               // ..and background colors

clrscr();                                   // clear window
scroll_flag = _wscroll;                     // ..and save scroll setting

if (box != none)                            // q. border requested?
    {                                       // a. yes .. draw the box
    b = &box_chars[box];                    // get line drawing group
    _wscroll = 0;                           // disable scrolling

    gotoxy(1, 1);                           // goto upper left corner
    cprintf("%c", b->ul_char);              // put out first corner

    for (i = 1; i < (lr_col - ul_col); i++) // build top of box..
        cprintf("%c", b->top_char);         // ..with horizontals

    cprintf("%c", b->ur_char);              // ..and upper right corner

    gotoxy(1, (lr_row - ul_row) + 1);       // goto lower left corner
    cprintf("%c", b->ll_char);              // put out bottom corner

    for (i = 1; i < (lr_col - ul_col); i++) // build bottom of box
        cprintf("%c", b->top_char);         // ..with horizontals

    cprintf("%c", b->lr_char);              // ..and lower right corner

    for (i = 2; i <= (lr_row - ul_row); i++)// put the sides on the box
        {
        gotoxy(1, i);                       // jump to left side of box
        cprintf("%c", b->side_char);        // ..and draw a chunk

        gotoxy((lr_col - ul_col) + 1, i);   // ..then jump to right side
        cprintf("%c", b->side_char);        // ..of the box and draw
        }

    _wscroll = scroll_flag;                 // restore scrolling mode

    }
}



/* ******************************************************************** *
 *
 *  AtSay -- display string at position
 *
 * ******************************************************************** */

void    Window::AtSay(int c, int r,         // column and row to
              char *s)                      // display string
{

GotoXY(c, r);                               // set up at the right place

cprintf("%s", s);                           // display string in window

cursor_col = wherex();                      // save cursor column..
cursor_row = wherey();                      // ..and cursor row

}



/* ******************************************************************** *
 *
 *  AtSayReverse -- display string at position in reverse video
 *
 * ******************************************************************** */

void    Window::AtSayReverse(int c, int r,  // column and row to
              char *s)                      // display string
{

GotoXY(c, r);                               // set up at the right place
textcolor(FG(cr_color));                    // set up foreground
textbackground(BG(cr_color));               // ..and background colors

cprintf("%s", s);                           // display string in window

cursor_col = wherex();                      // save cursor column..
cursor_row = wherey();                      // ..and cursor row
textcolor(FG(cn_color));                    // then set colors back to
textbackground(BG(cn_color));               // ..their normal settings

}



/* ******************************************************************** *
 *
 *  Display -- display a character in a window
 *
 * ******************************************************************** */

void    Window::Display(char c)             // character to display
{

MakeCurrent();                              // make this window current
cprintf("%c", c);                           // display string in window
cursor_col = wherex();                      // save cursor column..
cursor_row = wherey();                      // ..and cursor row

}



/* ******************************************************************** *
 *
 *  Display -- display string in window
 *
 * ******************************************************************** */

void    Window::Display(char *s)            // string to display
{

MakeCurrent();                              // make this window current
cprintf("%s", s);                           // display string in window
cursor_col = wherex();                      // save cursor column..
cursor_row = wherey();                      // ..and cursor row

}



/* ******************************************************************** *
 *
 *  DisplayReverse -- display string in reverse video
 *
 * ******************************************************************** */

void    Window::DisplayReverse(char *s)     // string to display
{

MakeCurrent();                              // make this window current
textcolor(FG(cr_color));                    // set up foreground
textbackground(BG(cr_color));               // ..and background colors

cprintf("%s", s);                           // display string in window

cursor_col = wherex();                      // save cursor column..
cursor_row = wherey();                      // ..and cursor row
textcolor(FG(cn_color));                    // then set colors back to
textbackground(BG(cn_color));               // ..their normal settings

}



/* ******************************************************************** *
 *
 *  Clear -- clear current window
 *
 * ******************************************************************** */

void    Window::Clear(void)
{

MakeCurrent();                              // make this window current
clrscr();                                   // ..then clear it

cursor_col = wherex();                      // save cursor column..
cursor_row = wherey();                      // ..and cursor row

}



/* ******************************************************************** *
 *
 *  GotoXY -- position cursor in window
 *
 * ******************************************************************** */

void    Window::GotoXY(int c, int r)        // column and row
{

MakeCurrent();                              // make this window current
gotoxy(c, r);                               // goto requested location
cursor_col = wherex();                      // save cursor column..
cursor_row = wherey();                      // ..and cursor row

}



/* ******************************************************************** *
 *
 *  Close -- close window and restore screen
 *
 * ******************************************************************** */

void    Window::Close(void)
{

if (NOT open_flag)                          // q. window already closed?
    return;                                 // a. yes .. just return

open_flag = 0;                              // clear opened flag

puttext(ul_col, ul_row, lr_col, lr_row,     // restore old screen data
            old_data);                      // ..from temp buffer

}



/* ******************************************************************** *
 *
 *  ~Window -- destructor
 *
 * ******************************************************************** */

Window::~Window()
{

if (open_flag)                              // q. window still open?
    Close();                                // a. yes .. close window

last_window = 0;                            // clear window pointer
delete old_data;                            // de-allocate screen buffer
window(1, 1, 80, max_lines);                // set whole screen as window

}



/* ******************************************************************** *
 *
 *  MakeCurrent -- make this window current
 *
 * ******************************************************************** */

void    Window::MakeCurrent(void)
{

if (last_window != this)                    // q. same window?
    {
    last_window = this;                     // a. no .. use this window
    _wscroll = scroll_flag;                 // ..and set up scroll flag

    if (border_flag == none)                // q. any border?
        window(ul_col, ul_row,              // a. no .. set up window
                lr_col, lr_row);            // ..using entire area
     else
        window(ul_col + 1, ul_row + 1,      // else .. set up the window
                lr_col - 1, lr_row - 1);    // ..allowing for the border

    gotoxy(cursor_col, cursor_row);         // ..and re-place cursor
    textcolor(FG(cn_color));                // ..and set up foreground
    textbackground(BG(cn_color));           // ..and background colors
    }
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美日韩亚洲综合| 亚洲综合色区另类av| 亚洲免费看黄网站| 波多野结衣在线aⅴ中文字幕不卡| 99re热视频精品| 亚洲情趣在线观看| 亚洲欧美色综合| 一区二区三区不卡视频在线观看| 欧美日韩成人综合在线一区二区| 男男视频亚洲欧美| 国产亚洲精品中文字幕| 91麻豆福利精品推荐| 日本不卡不码高清免费观看| 午夜成人在线视频| 国产精品久久久久久久久图文区| 一本色道久久综合精品竹菊| 日韩成人免费看| 亚洲少妇最新在线视频| 亚洲精品一区二区三区福利| 成人动漫一区二区| 91久久精品一区二区三区| 激情丁香综合五月| 一区二区三区日韩在线观看| 亚洲第一二三四区| 一区二区中文字幕在线| 2021国产精品久久精品| 欧美精品三级日韩久久| 91色.com| 日韩欧美国产麻豆| 在线观看一区不卡| 色综合久久九月婷婷色综合| 欧美日韩亚州综合| 久久精品夜色噜噜亚洲aⅴ| 亚洲视频一区在线| 三级精品在线观看| 午夜精品久久久久久久99水蜜桃 | 国产精品久久久一区麻豆最新章节| 国产精品色在线观看| 久久新电视剧免费观看| √…a在线天堂一区| 毛片av一区二区| 夜夜夜精品看看| 久久99精品久久久| 久久爱www久久做| 精品在线一区二区三区| 色综合天天综合给合国产| 成人av电影免费观看| 欧美日韩精品一区视频| 中文字幕在线不卡国产视频| 人人精品人人爱| 91麻豆福利精品推荐| 国产日韩av一区| 日本一区二区不卡视频| 亚洲国产精品v| 玖玖九九国产精品| 欧美日免费三级在线| 国产精品不卡一区二区三区| 国产一区中文字幕| 国产成人午夜精品5599| 盗摄精品av一区二区三区| aaa国产一区| 久久久久国产精品免费免费搜索| 国产婷婷一区二区| 九九**精品视频免费播放| 欧美群妇大交群中文字幕| 亚洲美女在线国产| 色综合色狠狠天天综合色| 欧美韩国一区二区| 国产成人免费xxxxxxxx| 久久久91精品国产一区二区精品| 日本sm残虐另类| 91精品国产福利| 国产欧美一区二区精品婷婷| 男男gaygay亚洲| 91精品国产免费| 丝袜美腿一区二区三区| 欧美日韩三级视频| 午夜电影久久久| 日韩欧美一区中文| 《视频一区视频二区| 成人网在线播放| 国产精品国产精品国产专区不蜜 | 激情五月婷婷综合网| 91精品在线免费观看| 久久精品人人做人人爽人人| 国产美女久久久久| 国产日产欧美一区| 一本色道久久综合亚洲精品按摩| 怡红院av一区二区三区| 国产在线精品免费| 久久精品视频网| 91免费观看国产| 香港成人在线视频| 精品国产一二三| 成人免费av在线| 亚洲成人免费观看| 日韩一区二区中文字幕| 国产乱子伦一区二区三区国色天香| 9色porny自拍视频一区二区| 亚洲欧美日韩在线| 91 com成人网| 大尺度一区二区| 亚洲国产视频在线| 99久久99久久精品免费观看| 亚洲综合网站在线观看| 欧美精品久久久久久久多人混战 | 欧美日韩在线三级| 美女视频免费一区| 国产女主播一区| 色婷婷综合视频在线观看| 免费在线欧美视频| 国产精品国产馆在线真实露脸 | 欧美精品一区二区精品网| 国产91高潮流白浆在线麻豆| 日韩三级精品电影久久久| 国产aⅴ综合色| 日韩国产欧美一区二区三区| 国产欧美一区二区精品仙草咪| 91国偷自产一区二区使用方法| 蜜桃视频在线观看一区二区| 国产精品不卡一区二区三区| 欧美成人国产一区二区| 奇米精品一区二区三区在线观看一| 国产欧美一区二区精品性| 欧美日韩你懂的| 成人动漫av在线| 蜜臀av一区二区在线观看 | 欧美成人激情免费网| 91极品美女在线| 成人一区二区三区视频| 毛片一区二区三区| 亚洲国产精品一区二区久久| 中文字幕制服丝袜一区二区三区 | 亚洲黄色免费电影| 久久久久99精品国产片| 日韩一区和二区| 欧美日韩精品一区二区天天拍小说| 成人激情av网| 国产福利精品一区| 国产乱子伦一区二区三区国色天香| 日韩不卡手机在线v区| 亚洲一区二区三区四区在线| 最新国产精品久久精品| 国产午夜精品福利| 久久久久国产精品厨房| 久久婷婷国产综合国色天香 | 91美女在线观看| 不卡的电影网站| 成人免费看片app下载| 国产精品99久久久久久似苏梦涵| 久久狠狠亚洲综合| 美国一区二区三区在线播放| 日本vs亚洲vs韩国一区三区二区| 亚洲国产成人高清精品| 亚洲国产精品嫩草影院| 亚洲国产精品久久久久婷婷884| 悠悠色在线精品| 亚洲大型综合色站| 日韩国产成人精品| 蜜臀av一区二区在线观看| 久久爱www久久做| 国产精品一区一区三区| 成人综合激情网| 91蝌蚪porny九色| 精品视频在线免费观看| 91精品国产欧美一区二区成人| 91精品国产综合久久久久久久| 欧美精品在线观看一区二区| 欧美一区二视频| 国产人成亚洲第一网站在线播放| 国产精品国模大尺度视频| 亚洲最新在线观看| 久久精品国产色蜜蜜麻豆| 久草在线在线精品观看| 丁香激情综合国产| 欧美日韩在线观看一区二区| 日韩欧美激情四射| 国产精品每日更新| 午夜精品福利一区二区三区av| 免费成人深夜小野草| 国产成人午夜精品影院观看视频 | 欧美日韩一级黄| 日韩美女一区二区三区| 国产精品女主播在线观看| 一区二区三区日韩欧美精品| 美女一区二区三区在线观看| 大白屁股一区二区视频| 欧美色国产精品| 国产亚洲欧洲997久久综合| 亚洲黄色av一区| 国产精品123| 欧美美女直播网站| 欧美激情一区三区| 香蕉av福利精品导航| av男人天堂一区| 欧美一级xxx| 亚洲午夜影视影院在线观看| 国产乱色国产精品免费视频| 欧美三级韩国三级日本一级| 国产欧美中文在线|