Revision: 8675 https://osdn.net/projects/ttssh2/scm/svn/commits/8675 Author: zmatsuo Date: 2020-04-09 01:00:51 +0900 (Thu, 09 Apr 2020) Log Message: ----------- buffer.c に関連する定義を buffer.h に移動 - common/tttypes.h に入っていた Modified Paths: -------------- trunk/teraterm/common/tttypes.h trunk/teraterm/teraterm/buffer.h trunk/teraterm/teraterm/teraprn.h trunk/teraterm/teraterm/vtdisp.h -------------- next part -------------- Modified: trunk/teraterm/common/tttypes.h =================================================================== --- trunk/teraterm/common/tttypes.h 2020-04-08 16:00:39 UTC (rev 8674) +++ trunk/teraterm/common/tttypes.h 2020-04-08 16:00:51 UTC (rev 8675) @@ -68,45 +68,6 @@ #define IdKanji 2 #define IdSpecial 3 - /* Character attribute bit masks */ -#define AttrDefault 0x00 -#define AttrDefaultFG 0x00 -#define AttrDefaultBG 0x00 -#define AttrBold 0x01 -#define AttrUnder 0x02 -#define AttrSpecial 0x04 -#define AttrFontMask 0x07 -#define AttrBlink 0x08 -#define AttrReverse 0x10 -#define AttrLineContinued 0x20 /* valid only at the beggining or end of a line */ -/* begin - ishizaki */ -#define AttrURL 0x40 -/* end - ishizaki */ -#define AttrKanji 0x80 // 1=\x91S\x8Ap(2cell)/0=\x94\xBC\x8Ap(1cell) -#if UNICODE_INTERNAL_BUFF -#define AttrPadding 0x100 // 1=padding(2cell\x82̎\x9F\x82\xCC1cell or \x8Ds\x96\x96) -#endif - /* Color attribute bit masks */ -#define Attr2Fore 0x01 -#define Attr2Back 0x02 -#define AttrSgrMask (AttrBold | AttrUnder | AttrBlink | AttrReverse) -#define AttrColorMask (AttrBold | AttrBlink | AttrReverse) -#define Attr2ColorMask (Attr2Fore | Attr2Back) - -#define Attr2Protect 0x04 - -typedef struct { - BYTE Attr; - BYTE Attr2; -#if UNICODE_INTERNAL_BUFF - WORD AttrEx; -#endif - BYTE Fore; - BYTE Back; -} TCharAttr; - -typedef TCharAttr *PCharAttr; - /* Color codes */ #define IdBack 0 #define IdRed 1 Modified: trunk/teraterm/teraterm/buffer.h =================================================================== --- trunk/teraterm/teraterm/buffer.h 2020-04-08 16:00:39 UTC (rev 8674) +++ trunk/teraterm/teraterm/buffer.h 2020-04-08 16:00:51 UTC (rev 8675) @@ -1,6 +1,6 @@ /* * Copyright (C) 1994-1998 T. Teranishi - * (C) 2005-2019 TeraTerm Project + * (C) 2005-2020 TeraTerm Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -29,10 +29,50 @@ /* TERATERM.EXE, scroll buffer routines */ +#pragma once + #ifdef __cplusplus extern "C" { #endif + /* Character attribute bit masks */ +#define AttrDefault 0x00 +#define AttrDefaultFG 0x00 +#define AttrDefaultBG 0x00 +#define AttrBold 0x01 +#define AttrUnder 0x02 +#define AttrSpecial 0x04 +#define AttrFontMask 0x07 +#define AttrBlink 0x08 +#define AttrReverse 0x10 +#define AttrLineContinued 0x20 /* valid only at the beggining or end of a line */ +/* begin - ishizaki */ +#define AttrURL 0x40 +/* end - ishizaki */ +#define AttrKanji 0x80 // 1=\x91S\x8Ap(2cell)/0=\x94\xBC\x8Ap(1cell) +#define AttrPadding 0x100 // 1=padding(2cell\x82̎\x9F\x82\xCC1cell or \x8Ds\x96\x96) + + /* Color attribute bit masks */ +#define Attr2Fore 0x01 +#define Attr2Back 0x02 +#define AttrSgrMask (AttrBold | AttrUnder | AttrBlink | AttrReverse) +#define AttrColorMask (AttrBold | AttrBlink | AttrReverse) +#define Attr2ColorMask (Attr2Fore | Attr2Back) + +#define Attr2Protect 0x04 + +typedef struct { + BYTE Attr; + BYTE Attr2; +#if 1 //UNICODE_INTERNAL_BUFF + WORD AttrEx; // \x83A\x83g\x83\x8A\x83r\x83\x85\x81[\x83g\x82𑝂₷\x83e\x83X\x83g +#endif + BYTE Fore; + BYTE Back; +} TCharAttr; + +typedef TCharAttr *PCharAttr; + void InitBuffer(); void LockBuffer(); void UnlockBuffer(); Modified: trunk/teraterm/teraterm/teraprn.h =================================================================== --- trunk/teraterm/teraterm/teraprn.h 2020-04-08 16:00:39 UTC (rev 8674) +++ trunk/teraterm/teraterm/teraprn.h 2020-04-08 16:00:51 UTC (rev 8675) @@ -29,6 +29,8 @@ /* TERATERM.EXE, Printing routines */ +#include "buffer.h" // for TCharAttr + #ifdef __cplusplus extern "C" { #endif Modified: trunk/teraterm/teraterm/vtdisp.h =================================================================== --- trunk/teraterm/teraterm/vtdisp.h 2020-04-08 16:00:39 UTC (rev 8674) +++ trunk/teraterm/teraterm/vtdisp.h 2020-04-08 16:00:51 UTC (rev 8675) @@ -28,6 +28,9 @@ */ /* TERATERM.EXE, VT terminal display routines */ + +#include "buffer.h" // for TCharAttr + #ifdef __cplusplus extern "C" { #endif