Develop and Download Open Source Software

Browse Subversion Repository

Annotation of /branches/ttcomtester/teraterm/teraterm/vtdisp.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 9040 - (hide annotations) (download) (as text)
Sun Nov 29 15:26:40 2020 UTC (3 years, 4 months ago) by zmatsuo
Original Path: trunk/teraterm/teraterm/vtdisp.h
File MIME type: text/x-chdr
File size: 5538 byte(s)
[ファイル]/[印刷]からの印刷をUnicodeに対応した

- 文字描画関数 DrawStrW(), DrawStrA() を vtdisp.c に追加
  - 画面描画、印刷から利用
  - vtwinで背景付きのとき描画が乱れていたのを修正
- DispStr(), PrnOutText() 内で描画時にキリル文字変換を行っていたのを削除
  - RussConvStr()
  - 従来も無効化していた
  - 内部バッファに文字をUnicodeで保存したときに、表示に適したANSI文字コードに変換して保存している
1 doda 6806 /*
2     * Copyright (C) 1994-1998 T. Teranishi
3 zmatsuo 7459 * (C) 2008-2019 TeraTerm Project
4 doda 6806 * All rights reserved.
5     *
6 doda 6841 * Redistribution and use in source and binary forms, with or without
7     * modification, are permitted provided that the following conditions
8     * are met:
9 doda 6806 *
10 doda 6841 * 1. Redistributions of source code must retain the above copyright
11     * notice, this list of conditions and the following disclaimer.
12     * 2. Redistributions in binary form must reproduce the above copyright
13     * notice, this list of conditions and the following disclaimer in the
14     * documentation and/or other materials provided with the distribution.
15     * 3. The name of the author may not be used to endorse or promote products
16     * derived from this software without specific prior written permission.
17 doda 6806 *
18 doda 6841 * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR
19     * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
20     * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
21     * IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY DIRECT, INDIRECT,
22     * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
23     * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
24     * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
25     * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26     * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
27     * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28 doda 6806 */
29 maya 3227
30     /* TERATERM.EXE, VT terminal display routines */
31 zmatsuo 8675
32     #include "buffer.h" // for TCharAttr
33    
34 maya 3227 #ifdef __cplusplus
35     extern "C" {
36     #endif
37    
38     /* prototypes */
39     //<!--by AKASI
40 yutakapon 8106 void BGInitialize(BOOL initialize_once);
41 maya 3227 void BGSetupPrimary(BOOL);
42    
43 doda 3715 void BGExchangeColor(void);
44    
45 maya 3227 void BGOnSettingChange(void);
46     void BGOnEnterSizeMove(void);
47     void BGOnExitSizeMove(void);
48    
49     extern BOOL BGEnable;
50     extern BOOL BGNoFrame;
51     extern BOOL BGNoCopyBits;
52     //-->
53    
54     void InitDisp();
55     void EndDisp();
56     void DispReset();
57     void DispConvWinToScreen
58     (int Xw, int Yw, int *Xs, int *Ys, PBOOL Right);
59     void DispConvScreenToWin
60     (int Xs, int Ys, int *Xw, int *Yw);
61 zmatsuo 7528 //void SetLogFont();
62 maya 3227 void ChangeFont();
63     void ResetIME();
64     void ChangeCaret();
65     void CaretKillFocus(BOOL show);
66 doda 3322 void UpdateCaretPosition(BOOL enforce);
67 maya 3227 void CaretOn();
68     void CaretOff();
69     void DispDestroyCaret();
70     BOOL IsCaretOn();
71     void DispEnableCaret(BOOL On);
72     BOOL IsCaretEnabled();
73     void DispSetCaretWidth(BOOL DW);
74     void DispChangeWinSize(int Nx, int Ny);
75     void ResizeWindow(int x, int y, int w, int h, int cw, int ch);
76     void PaintWindow(HDC PaintDC, RECT PaintRect, BOOL fBkGnd,
77     int* Xs, int* Ys, int* Xe, int* Ye);
78     void DispEndPaint();
79     void DispClearWin();
80     void DispChangeBackground();
81     void DispChangeWin();
82     void DispInitDC();
83     void DispReleaseDC();
84     void DispSetupDC(TCharAttr Attr, BOOL Reverse);
85 zmatsuo 9040 void DispStr(const char *Buff, int Count, int Y, int* X);
86 doda 8445 void DispStrW(const wchar_t *StrW, const char *WidthInfo, int Count, int Y, int* X);
87 maya 3227 void DispEraseCurToEnd(int YEnd);
88     void DispEraseHomeToCur(int YHome);
89     void DispEraseCharsInLine(int XStart, int Count);
90     BOOL DispDeleteLines(int Count, int YEnd);
91     BOOL DispInsertLines(int Count, int YEnd);
92     BOOL IsLineVisible(int* X, int* Y);
93     void AdjustScrollBar();
94     void DispScrollToCursor(int CurX, int CurY);
95     void DispScrollNLines(int Top, int Bottom, int Direction);
96     void DispCountScroll();
97     void DispUpdateScroll();
98     void DispScrollHomePos();
99     void DispAutoScroll(POINT p);
100     void DispHScroll(int Func, int Pos);
101     void DispVScroll(int Func, int Pos);
102     void DispSetupFontDlg();
103     void DispRestoreWinSize();
104     void DispSetWinPos();
105     void DispSetActive(BOOL ActiveFlag);
106     void InitColorTable();
107     void DispApplyANSIColor();
108     void DispSetNearestColors(int start, int end, HDC DispCtx);
109     int TCharAttrCmp(TCharAttr a, TCharAttr b);
110 doda 4770 void DispSetColor(unsigned int num, COLORREF color);
111     void DispResetColor(unsigned int num);
112     COLORREF DispGetColor(unsigned int num);
113 maya 3227 void DispSetCurCharAttr(TCharAttr Attr);
114 doda 3297 void DispMoveWindow(int x, int y);
115 doda 3302 void DispShowWindow(int mode);
116 doda 3464 void DispResizeWin(int w, int h);
117 doda 3466 BOOL DispWindowIconified();
118 doda 7271 void DispGetWindowPos(int *x, int *y, BOOL client);
119 doda 7270 void DispGetWindowSize(int *width, int *height, BOOL client);
120 doda 7272 void DispGetRootWinSize(int *x, int *y, BOOL inPixels);
121 doda 5073 int DispFindClosestColor(int red, int green, int blue);
122 doda 6306 void UpdateBGBrush(void);
123 zmatsuo 9040 void DrawStrW(HDC DC, HDC BGDC, const wchar_t *StrW, const char *WidthInfo, int Count,
124     int font_width, int font_height, int Y, int* X);
125     void DrawStrA(HDC DC, HDC BGDC, const char *StrA, int Count,
126     int font_width, int font_height, int Y, int* X);
127 maya 3227
128     extern int WinWidth, WinHeight;
129     extern HFONT VTFont[AttrFontMask+1];
130     extern int FontHeight, FontWidth, ScreenWidth, ScreenHeight;
131     extern BOOL AdjustSize, DontChangeSize;
132     extern int CursorX, CursorY;
133     extern int WinOrgX, WinOrgY, NewOrgX, NewOrgY;
134     extern int NumOfLines, NumOfColumns;
135     extern int PageStart, BuffEnd;
136     extern TCharAttr DefCharAttr;
137    
138 zmatsuo 7434 extern BOOL IMEstat;
139 zmatsuo 7534 extern BOOL IMECompositionState;
140 zmatsuo 7434
141 maya 3227 #define SCROLL_BOTTOM 1
142     #define SCROLL_LINEDOWN 2
143     #define SCROLL_LINEUP 3
144     #define SCROLL_PAGEDOWN 4
145     #define SCROLL_PAGEUP 5
146     #define SCROLL_POS 6
147     #define SCROLL_TOP 7
148    
149 doda 3309 #define WINDOW_MINIMIZE 1
150     #define WINDOW_MAXIMIZE 2
151     #define WINDOW_RESTORE 3
152     #define WINDOW_RAISE 4
153     #define WINDOW_LOWER 5
154 doda 3310 #define WINDOW_REFRESH 6
155 doda 7274 #define WINDOW_TOGGLE_MAXIMIZE 7
156 doda 3309
157 maya 3227 #ifdef __cplusplus
158     }
159     #endif

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26