// WndRichEdit.cpp : _xZkqqHx_iDeDiDjDiDhGiDiKiDiBiDjDiDgFiBfLiDfGiDiHiDjD_xHqqkZx_ _xZkqqHx_iDhEiDeAiDeDiDiL_xHqqkZx_
//

#include "stdafx.h"
#include <algorithm>		// For find template.
#include <float.h>			// For DBL_MAX.
#include "DynamicDraw.h"	// For FFGetApp().
#include "FoundDoc.h"		// For g_pDoc.
#include "UtilCoord.h"		// For mm2lg.etc.
#include "UtilMisc.h"		// For PolyCrossHoriz.
#include "UtilStr.h"		// For GetWChar.
#include "UtilGraph.h"		// For PenInit.
#include "UtilErr.h"		// For FFMessageBox.
#include "TextOut.h"		// For FCTextOut.
#include "UtilDlg.h"		// For FFPopupSubmenu.
#include "UtilWin.h"		// For FFGetWindowText.
// 06.12.03 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ ()
#include "UtilBezier.h"		// For FFGetStdElemLen.
#include "DynamicDrawView.h"// For g_pView.
//#include "MainFrame.h"	// For HRuler, VRuler.
#include "CtlBrHRuler.h"	// For SetTextRange, etc.
#include "CtlBrVRuler.h"	// For SetTextRange, etc.
#include "RegData.h"		// GetOptiRegColor.
#include "UndoArchive.h"	// For FCUndoArchive.
#include "UtilFile.h"		// For WriteVSizeU,etc.
#include "SearchParser.h"	// For FCSearchParser.
#include "RichEditBuffer.h"	// For FCRichEditBuffer.
#include "FrameWnd.h"		// For FFGetMainWnd().
#include "ObjFigure.h"		// For FDOF_TEXT_RESIZE_XXX.
#include "RichText.h"		// For SetRichText.
#include "WndRichEdit.h"	// This header.
#if defined(_IME_ON)
#include <imm.h>
#endif // defined(_IME_ON)

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

// 03.07.08 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//// Superclass = FCTextEditorExp _xZkqqHx_iClOiCkKiBeB_xHqqkZx_FCTextEditorExp _xZkqqHx_iCmNiLpDiCmIiCmMiCmFiBeB_xHqqkZx_
// BASE_CLASS = CWnd _xZkqqHx_iCmJjAnNjCoIiBeC_xHqqkZx_


// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCmMiNmFjBoFiDfEiDeDiDfJiCpAiLeLjCoIiBeC_xHqqkZx_
#define FDWIN_MAX	(MAXSHORT - 100)

//----- 06.05.21 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//#define WCH_HAN_KUTEN	0xff64		// '_xZkqqHx_iBeB_xHqqkZx_'
//#define WCH_HAN_TOUTEN	0xff61		// '_xZkqqHx_iBeC_xHqqkZx_'
//#define WCH_ZEN_SPC		0x3000		// '_xZkqqHx_iBeA_xHqqkZx_'
//#define WCH_ZEN_KUTEN	0x3001		// '_xZkqqHx_iBeB_xHqqkZx_'
//#define WCH_ZEN_TOUTEN	0x3002		// '_xZkqqHx_iBeC_xHqqkZx_'
//#define WCH_ZEN_COMMA	0xff0c		// '_xZkqqHx_iBeD_xHqqkZx_'
//#define WCH_ZEN_PERIOD	0xff0e		// '_xZkqqHx_iBeE_xHqqkZx_'
//----- 06.05.21 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

// _xZkqqHx_iJpMiNhDjFlGiOjKiCmMjFjNiBeC_xHqqkZx_
#define FDWR_RETURN_WIDTH	fmmetol(1.0)

// _xZkqqHx_iDhJiBfLiDfH_xHqqkZx_UP/DOWN_xZkqqHx_iCmMiDfIiDeOiDiNiBfLiDiLjHmKiBeC_xHqqkZx_
static const long FD_TED_PAGE_SCROLL_NUM = 10;

//----------<NOT EXPORT TO VIEWER>-----------
// _xZkqqHx_jDgPjIfOjGlMiCpAiPiJiKpKiJlLiBeC_xHqqkZx_
LPCTSTR			CFCWndRichEdit::m_lpszClassName	= NULL;
// 05.07.11 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//DWORD			CFCWndRichEdit::m_dwRTF			= NULL;
short			CFCWndRichEdit::m_nEditCtrlCount= 0;
FCRichEditBuffer*	CFCWndRichEdit::m_richpEditCtrl	= NULL;
//----------</NOT EXPORT TO VIEWER>-----------

//----- 06.05.21 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//enum FDCharKind
//{
//	FDCK_ANSI_BEGIN,	// _xZkqqHx_iClBiCoKiCoGiCoIiJlKiBgJiImIiPoDiCmMjCgMiBgKiCmN_xHqqkZx_ANSI_xZkqqHx_iLeMiNiGiBeC_xHqqkZx_
//	FDCK_ANSI_MARK,		// _xZkqqHx_iLeMiNiG_xHqqkZx_.20-2f 3a-40 5b-60 7b-7e
//	FDCK_ANSI_NUMBER,	// _xZkqqHx_jAjEiOjK_xHqqkZx_.30-39
//	FDCK_ANSI_ALPHABET,	// _xZkqqHx_iDeBiDiLiDhEiDeAiDhIiDgCiDgH_xHqqkZx_.41-5a 61-7a
//	FDCK_ANSI_ETC,		// _xZkqqHx_iClLiCmMjBlM_xHqqkZx_.
//	FDCK_ANSI_END,		// _xZkqqHx_iClBiCoKiCoGiCoIiPoDiBgJiImIiJlKiCmMjCgMiBgKiCmN_xHqqkZx_ANSI_xZkqqHx_iLeMiNiGiBeC_xHqqkZx_
//	FDCK_ZENK_BEGIN,	// _xZkqqHx_iClBiCoKiCoGiCoIiJlKiBgJiImIiPoDiCmMjCgMiBgKiCmNjBfDiKhAiLeMiNiGiBeC_xHqqkZx_
//	FDCK_ZENK_ALPHABET,	// _xZkqqHx_jBfDiKhAiDeBiDiLiDhEiDeAiDhIiDgCiDgHiBeC_xHqqkZx_
//	FDCK_ZENK_END,		// _xZkqqHx_iClBiCoKiCoGiCoIiPoDiBgJiImIiJlKiCmMjCgMiBgKiCmNjBfDiKhAiLeMiNiGiBeC_xHqqkZx_
//	FDCK_OTHER_BEGIN,	// _xZkqqHx_iClBiCoKiCoGiCoIiJlKiCmNiClLiCmMjBlMiCmMiDfCiBfLiDgIiBeC_xHqqkZx_
//};
//----- 06.05.21 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

static const long s_l10xFontSizeList[] =
{
	10,
	20,
	30,
	40,
	50,
	60,
	70,
	80,
	90,
	100,
	105,
	110,
	120,
	140,
	160,
	180,
	200,
	220,
	240,
	260,
	280,
	360,
	480,
	720,
	800,
	900,
	1000,
	1100,
	1200,
	1300,
	1400,
	1500,
	1600,
	1700,
	1800,
	1900,
	2000,
	2100,
	2200,
	2300,
	2400,
	2500,
	2600,
	2700,
	2800,
	2900,
	3000,
	3100,
	3200,
	3300,
	3400,
	3500,
	3600,
	3700,
	3800,
	3900,
	4000,
	4100,
	4200,
	4300,
	4400,
	4500,
	4600,
	4700,
	4800,
	4900,
	5000,
}; // s_l10xFontSizeList.

/////////////////////////////////////////////////////////////////////////////
// Misc_xZkqqHx_iKnGjAjEiMfBiBeC_xHqqkZx_

//----------<NOT EXPORT TO VIEWER>-----------
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	myGetExtentWidth
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFlGiOjKjHmMiIoGiCpAiJkBjFpLiMpMiCmJiKgHjBoFiClHiCoJiBeC_xHqqkZx_Windows95/98_xZkqqHx_iCmNiDhEiDeIiDjDiDgHiCmM_xHqqkZx_ABC_xZkqqHx_iPoOjFpBiCkK_xHqqkZx_
 *			_xZkqqHx_iCkCiCkCiCkJiClAiCpBiBgJ_xHqqkZx_"f"_xZkqqHx_iCmM_xHqqkZx_Italic_xZkqqHx_jBmMiCmIiCmHiBgKiCmIiCmMiCmFiBeBjFlGiOjKiCkKjAoIjHeMiClHiCoJjFjNiCpA_xHqqkZx_
 *			_xZkqqHx_jHfNjHfEiCpAiOjNiCmBiCmEiNeMiClAiCoJjFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iClBiCoKiCpAiClFiCmIiCkCiCmGiBeBjFnCiPfHjCiGiCmJ_xHqqkZx_"f"_xZkqqHx_iCmMjAoGiCmBiClPiCoFiCkKjFfMiOkGiClDiCoKiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nrRect	:_xZkqqHx_jHmMiIoGiOhHjCoIiBeCiKgHjCkDiClFiCmEjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.07.28 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
static void myGetExtentWidth (FCShortRect& nrRect)
{
	int iEx = 1;
	if (FFVersionInfo().dwPlatformId == VER_PLATFORM_WIN32_WINDOWS &&
		FFVersionInfo().dwMinorVersion < 90)
	//----- Windows95_xZkqqHx_iMgO_xHqqkZx_OS_xZkqqHx_iKiOiCmCiBeB_xHqqkZx_WindowsMe_xZkqqHx_jGkCjGjO_xHqqkZx_ ------
	{
		iEx = (nrRect.right - nrRect.left) * 0.7;
		if (iEx < 1) iEx = 1;
	}
	// X_xZkqqHx_jFpLiMpMiCmJ_xHqqkZx_iEx_xZkqqHx_iDgIiDgCiDgHiKgHjBoFiBeC_xHqqkZx_
	nrRect.ExtendX(iEx);
} // myGetExtentWidth.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CrossHorizReduce
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhMiDiKiDfDiDjDiCmGjAiFjFlNjApMiCkKiDeOiDiNiDfIiClHiCoJjDfPiCmM_xHqqkZx_X_xZkqqHx_iNmAjFfHjEhKjHpBiCpAiBeBiDhNiBfLiDfHiDjDjFkK_xHqqkZx_
 *			_xZkqqHx_iLlHiCnPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmvCrossX	:_xZkqqHx_iDhNiBfLiDfHiDjDjFkKiLlHiCnPiCoHiCoKiCoJ_xHqqkZx_X_xZkqqHx_iNmAjFfHjEhKjHpB_xHqqkZx_.
 *			mmMarginL	:_xZkqqHx_iNlGiDhNiBfLiDfHiDjD_xHqqkZx_.
 *			mmMarginR	:_xZkqqHx_iJeFiDhNiBfLiDfHiDjD_xHqqkZx_.
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jAnNiMhGiDgNiBfLiDgH_xHqqkZx_P237.
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.10.30 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
static void CrossHorizReduce (mmetolVector& mmvCrossX,
								mmetol mmMarginL, mmetol mmMarginR)
{
	long l = 0;

	while (l < mmvCrossX.size())
	{
		mmvCrossX[l]	+= mmMarginL;
		mmvCrossX[l+1]	-= mmMarginR;
		if (mmvCrossX[l+1] <= mmvCrossX[l])
		{
			mmvCrossX.erase(mmvCrossX.begin() + l,
							mmvCrossX.begin() + l + 2);
		} else
		{
			l += 2;
		}
	}
} // CrossHorizReduce.

//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	GetMostLeft
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jHfOiCkGiCoHiCoKiClNiDeOiDiNiDfIiPoOjFpBiCmJiKoOiCmDiCkLiBeBiOhHjCoIiImKjChFiCoGiCoIiCoAiJeFiCmJiCkAiCoIiBeBiKiOiCmC_xHqqkZx_
// *			_xZkqqHx_iNmFiCoAiNlGiCmJiImKjChFiClHiCoJjFjN_xHqqkZx_mmWidth_xZkqqHx_iCmMiLpDiCkLiDfIiDhJiBfLiDfIiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmLeftX		:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiNlGiNmAjFfHiCpAjFnEiClHiBeC_xHqqkZx_
// *			mmWidth		:_xZkqqHx_iMjPiNpFiClHiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCmMjFjNiBeC_xHqqkZx_
// *			mmBeginL	:_xZkqqHx_iMjPiNpFiCpAiKeKiOgOiClHiCoJiNmAjFfHiBeCiClBiCoKiCoGiCoIiCoAiJeFiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
// *			mmvaCrossX	:_xZkqqHx_iDeOiDiNiDfIiPoOjFpBiBeC_xHqqkZx_
// *			iCrossXSz	:mmvaCrossX_xZkqqHx_iCmMiDfEiDeDiDfJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	TRUE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClHiCoJiPoKiNiHiBeC_xHqqkZx_
// *			FALSE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiHiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.10.29 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *			99.11.19 Fukushiro M. _xZkqqHx_iDeBiDiLiDfDiDiKiDfJiDiAiPeDjAlD_xHqqkZx_
// *************************************************************************/
//static BOOL GetMostLeft (mmetol& mmLeftX, mmetol mmWidth, mmetol mmBeginL,
//						mmetolVector mmvaCrossX[], int iCrossXSz)
//{
//	// _xZkqqHx_iKpEiCmCiDeOiDiNiDfIiPoOjFpBiCmJiDhNiDgCiDgAiClFiClNiCkJiCmMiDeKiDeFiDjDiDgHiBeC_xHqqkZx_
//	int iMatch = 0;
//	// _xZkqqHx_iMlLiNnNiMjPiNpFjCiGiCmMiDeOiDiNiDfIiPoOjFpBjEhKjHpBjDfJiOjKiBeC_xHqqkZx_
//	int iCross = 0;
//	while (iMatch < iCrossXSz)
//	{
//		int iGap = 0;
//		for (;;)
//		{
//			// _xZkqqHx_iMlLiNnNiCmMiDeOiDiNiDfIiPoOjFpBiCmMiNmFiMoDiCnMiCmFiMjPiNpFiClFiCmEiClFiCnMiCmBiClNiCmIiCoHiBeBiOlIjEhDiPeJjHlJiBeC_xHqqkZx_
//			if (mmvaCrossX[iCross].size() <= iGap) return FALSE;
//			// _xZkqqHx_iDeOiDiNiDfIiPoOjFpBjCiGiCmMiDeNiDiDiDgCiDhGiCmMiNlGiNmAjFfHiCmGiJeFiNmAjFfHiBeC_xHqqkZx_
//			const mmetol mmGapL = mmvaCrossX[iCross][iGap];
//			const mmetol mmGapR = mmvaCrossX[iCross][iGap + 1];
//			// _xZkqqHx_iMjPiNpFiClFiCmEiCkCiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCkKiDeNiDiDiDgCiDhGiCmJiOpLiCnMiCoJiPoKiNiHiBeC_xHqqkZx_
//			if (mmGapL <= mmBeginL && mmBeginL + mmWidth <= mmGapR)
//			{
//				// _xZkqqHx_iDhNiDgCiDgAiDeKiDeFiDjDiDfOiCmJiCfAiJmBiOfKiBeC_xHqqkZx_
//				iMatch++;
//				// _xZkqqHx_iCmGiCoIiCkAiCkGiClIiBeBiClBiCmMiDeOiDiNiDfIiPoOjFpBiCmMiMjPiNpFiCpAiPeJjHlJiClFiCmEiOjPiCmMiDeOiDiNiDfIiPoOjFpBiCnGiBeCiBeC_xHqqkZx_
//				break;
//			}
//			// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKiDeNiDiDiDgCiDhGiCoGiCoIiCoAiNlGiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
//			if (mmBeginL < mmGapL)
//			{
//				// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiNlGiImKjChFiCpAiDeNiDiDiDgCiDhGiNlGiNmAjFfHiCnMiCmFiJeFiCmJiKpBiClJiCoJiBeC_xHqqkZx_
//				mmBeginL = mmGapL;
//				// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiNlGiImKjChFiCpAiInKjDkOiClFiClNiCmMiCmFiBeBiDhNiDgCiDgAiDeKiDeFiDjDiDfOiCmNjGlDiMpIiBeC_xHqqkZx_
//				iMatch = 0;
//				// iGap_xZkqqHx_iCmJiJmBiOfKiClFiCmIiCkCiCoGiCkEiCmJiBeBiOjPiCmMiDiLiBfLiDhGiCnGjClFiCnEiBeC_xHqqkZx_
//				continue;
//			}
//			iGap += 2;
//		}
//		if (iCrossXSz <= ++iCross) iCross = 0;
//	}
//	// _xZkqqHx_iMjPiNpFiMiLiJmKiCmMiLpDiCkLiDfIiDhJiBfLiDfIiNlGiNmAjFfHiCpAjAnNjCoIiBeC_xHqqkZx_
//	mmLeftX = mmBeginL;
//	return TRUE;
//} // GetMostLeft.
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	GetMostLeft
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jHfOiCkGiCoHiCoKiClNiDeOiDiNiDfIiPoOjFpBiCmJiKoOiCmDiCkLiBeBiOhHjCoIiImKjChFiCoGiCoIiCoAiJeFiCmJiCkAiCoIiBeBiKiOiCmC_xHqqkZx_
 *			_xZkqqHx_iNmFiCoAiNlGiCmJiImKjChFiClHiCoJjFjN_xHqqkZx_mmWidth_xZkqqHx_iCmMiLpDiCkLiDfIiDhJiBfLiDfIiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmLeftX		:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiNlGiNmAjFfHiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmWidth		:_xZkqqHx_iMjPiNpFiClHiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCmMjFjNiBeC_xHqqkZx_
 *			mmBeginL	:_xZkqqHx_iMjPiNpFiCpAiKeKiOgOiClHiCoJiNmAjFfHiBeCiClBiCoKiCoGiCoIiCoAiJeFiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
 *			mmvCrossX	:_xZkqqHx_iDeOiDiNiDfIiPoOjFpBiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	TRUE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClHiCoJiPoKiNiHiBeC_xHqqkZx_
 *			FALSE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
static BOOL GetMostLeft (mmetol& mmLeftX, mmetol mmWidth, mmetol mmBeginL, const mmetolVector& mmvCrossX)
{
	int iGap = 0;
	for (;;)
	{
		// _xZkqqHx_iMlLiNnNiCmMiDeOiDiNiDfIiPoOjFpBiCmMiNmFiMoDiCnMiCmFiMjPiNpFiClFiCmEiClFiCnMiCmBiClNiCmIiCoHiBeBiOlIjEhDiPeJjHlJiBeC_xHqqkZx_
		if (mmvCrossX.size() <= iGap) return FALSE;
		// _xZkqqHx_iDeOiDiNiDfIiPoOjFpBjCiGiCmMiDeNiDiDiDgCiDhGiCmMiNlGiNmAjFfHiCmGiJeFiNmAjFfHiBeC_xHqqkZx_
		const mmetol mmGapL = mmvCrossX[iGap];
		const mmetol mmGapR = mmvCrossX[iGap + 1];
		// _xZkqqHx_iMjPiNpFiClFiCmEiCkCiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCkKiDeNiDiDiDgCiDhGiCmJiOpLiCnMiCoJiPoKiNiHiBeC_xHqqkZx_
		if (mmGapL <= mmBeginL && mmBeginL + mmWidth <= mmGapR)
			break;
		if (mmBeginL < mmGapL)
		//----- _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiMjPiNpFiKoOjDfPiCkKiDeNiDiDiDgCiDhGiCoGiCoIiCoAiNlGiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiNlGiImKjChFiCpAiDeNiDiDiDgCiDhGiNlGiNmAjFfHiCnMiCmFiJeFiCmJiKpBiClJiCoJiBeC_xHqqkZx_
			mmBeginL = mmGapL;
			// iGap_xZkqqHx_iCmJiJmBiOfKiClFiCmIiCkCiCoGiCkEiCmJiBeBiOjPiCmMiDiLiBfLiDhGiCnGjClFiCnEiBeC_xHqqkZx_
		} else
		{
			iGap += 2;
		}
	}
	// _xZkqqHx_iMjPiNpFiMiLiJmKiCmMiLpDiCkLiDfIiDhJiBfLiDfIiNlGiNmAjFfHiCpAjAnNjCoIiBeC_xHqqkZx_
	mmLeftX = mmBeginL;
	return TRUE;
} // GetMostLeft.

//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	GetMostRight
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jHfOiCkGiCoHiCoKiClNiDeOiDiNiDfIiPoOjFpBiCmJiKoOiCmDiCkLiBeBiOhHjCoIiImKjChFiCoGiCoIiCoAiNlGiCmJiCkAiCoIiBeBiKiOiCmC_xHqqkZx_
// *			_xZkqqHx_iNmFiCoAiJeFiCmJiImKjChFiClHiCoJjFjN_xHqqkZx_mmWidth_xZkqqHx_iCmMiLpDiCkLiDfIiDhJiBfLiDfIiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmRightX	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiJeFiNmAjFfHiCpAjFnEiClHiBeC_xHqqkZx_
// *			mmWidth		:_xZkqqHx_iMjPiNpFiClHiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCmMjFjNiBeC_xHqqkZx_
// *			mmBeginR	:_xZkqqHx_iMjPiNpFiCpAiKeKiOgOiClHiCoJiNmAjFfHiBeCiClBiCoKiCoGiCoIiCoAiNlGiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
// *			mmvaCrossX	:_xZkqqHx_iDeOiDiNiDfIiPoOjFpBiBeC_xHqqkZx_
// *			iCrossXSz	:mmvaCrossX_xZkqqHx_iCmMiDfEiDeDiDfJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	TRUE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClHiCoJiPoKiNiHiBeC_xHqqkZx_
// *			FALSE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiHiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//static BOOL GetMostRight (mmetol& mmRightX, mmetol mmWidth, mmetol mmBeginR,
//						mmetolVector mmvaCrossX[], int iCrossXSz)
//{
//	// _xZkqqHx_iKpEiCmCiDeOiDiNiDfIiPoOjFpBiCmJiDhNiDgCiDgAiClFiClNiCkJiCmMiDeKiDeFiDjDiDgHiBeC_xHqqkZx_
//	int iMatch = 0;
//	// _xZkqqHx_iMlLiNnNiMjPiNpFjCiGiCmMiDeOiDiNiDfIiPoOjFpBjEhKjHpBjDfJiOjKiBeC_xHqqkZx_
//	int iCross = 0;
//	while (iMatch < iCrossXSz)
//	{
//		int iGap = mmvaCrossX[iCross].size() - 2;
//		for (;;)
//		{
//			// _xZkqqHx_iMlLiNnNiCmMiDeOiDiNiDfIiPoOjFpBiCmMiNmFiPiJiCnMiCmFiMjPiNpFiClFiCmEiClFiCnMiCmBiClNiCmIiCoHiBeBiOlIjEhDiPeJjHlJiBeC_xHqqkZx_
//			if (iGap < 0) return FALSE;
//			// _xZkqqHx_iDeOiDiNiDfIiPoOjFpBjCiGiCmMiDeNiDiDiDgCiDhGiCmMiNlGiNmAjFfHiCmGiJeFiNmAjFfHiBeC_xHqqkZx_
//			const mmetol mmGapL = mmvaCrossX[iCross][iGap];
//			const mmetol mmGapR = mmvaCrossX[iCross][iGap + 1];
//			// _xZkqqHx_iMjPiNpFiClFiCmEiCkCiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCkKiDeNiDiDiDgCiDhGiCmJiOpLiCnMiCoJiPoKiNiHiBeC_xHqqkZx_
//			if (mmGapL <= mmBeginR - mmWidth && mmBeginR <= mmGapR)
//			{
//				// _xZkqqHx_iDhNiDgCiDgAiDeKiDeFiDjDiDfOiCmJiCfAiJmBiOfKiBeC_xHqqkZx_
//				iMatch++;
//				// _xZkqqHx_iCmGiCoIiCkAiCkGiClIiBeBiClBiCmMiDeOiDiNiDfIiPoOjFpBiCmMiMjPiNpFiCpAiPeJjHlJiClFiCmEiOjPiCmMiDeOiDiNiDfIiPoOjFpBiCnGiBeCiBeC_xHqqkZx_
//				break;
//			}
//			// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKiDeNiDiDiDgCiDhGiCoGiCoIiCoAiJeFiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
//			if (mmGapR < mmBeginR)
//			{
//				// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiJeFiImKjChFiCpAiDeNiDiDiDgCiDhGiJeFiNmAjFfHiCnMiCmFiNlGiCmJiKpBiClJiCoJiBeC_xHqqkZx_
//				mmBeginR = mmGapR;
//				// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiNlGiImKjChFiCpAiInKjDkOiClFiClNiCmMiCmFiBeBiDhNiDgCiDgAiDeKiDeFiDjDiDfOiCmNjGlDiMpIiBeC_xHqqkZx_
//				iMatch = 0;
//				// iGap_xZkqqHx_iCmJiMlIiOfKiClFiCmIiCkCiCoGiCkEiCmJiBeBiOjPiCmMiDiLiBfLiDhGiCnGjClFiCnEiBeC_xHqqkZx_
//				continue;
//			}
//			iGap -= 2;
//		}
//		if (iCrossXSz <= ++iCross) iCross = 0;
//	}
//	// _xZkqqHx_iMjPiNpFiMiLiJmKiCmMiLpDiCkLiDfIiDhJiBfLiDfIiJeFiNmAjFfHiCpAjAnNjCoIiBeC_xHqqkZx_
//	mmRightX = mmBeginR;
//	return TRUE;
//} // GetMostRight.
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	GetMostRight
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jHfOiCkGiCoHiCoKiClNiDeOiDiNiDfIiPoOjFpBiCmJiKoOiCmDiCkLiBeBiOhHjCoIiImKjChFiCoGiCoIiCoAiNlGiCmJiCkAiCoIiBeBiKiOiCmC_xHqqkZx_
 *			_xZkqqHx_iNmFiCoAiJeFiCmJiImKjChFiClHiCoJjFjN_xHqqkZx_mmWidth_xZkqqHx_iCmMiLpDiCkLiDfIiDhJiBfLiDfIiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmRightX	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiJeFiNmAjFfHiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmWidth		:_xZkqqHx_iMjPiNpFiClHiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCmMjFjNiBeC_xHqqkZx_
 *			mmBeginR	:_xZkqqHx_iMjPiNpFiCpAiKeKiOgOiClHiCoJiNmAjFfHiBeCiClBiCoKiCoGiCoIiCoAiNlGiCpAiMjPiNpFiClHiCoJiBeC_xHqqkZx_
 *			mmvCrossX	:_xZkqqHx_iDeOiDiNiDfIiPoOjFpBiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	TRUE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClHiCoJiPoKiNiHiBeC_xHqqkZx_
 *			FALSE	:_xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
static BOOL GetMostRight (mmetol& mmRightX, mmetol mmWidth, mmetol mmBeginR, const mmetolVector& mmvCrossX)
{
	int iGap = mmvCrossX.size() - 2;
	for (;;)
	{
		// _xZkqqHx_iMlLiNnNiCmMiDeOiDiNiDfIiPoOjFpBiCmMiNmFiPiJiCnMiCmFiMjPiNpFiClFiCmEiClFiCnMiCmBiClNiCmIiCoHiBeBiOlIjEhDiPeJjHlJiBeC_xHqqkZx_
		if (iGap < 0) return FALSE;
		// _xZkqqHx_iDeOiDiNiDfIiPoOjFpBjCiGiCmMiDeNiDiDiDgCiDhGiCmMiNlGiNmAjFfHiCmGiJeFiNmAjFfHiBeC_xHqqkZx_
		const mmetol mmGapL = mmvCrossX[iGap];
		const mmetol mmGapR = mmvCrossX[iGap + 1];
		// _xZkqqHx_iMjPiNpFiClFiCmEiCkCiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCkKiDeNiDiDiDgCiDhGiCmJiOpLiCnMiCoJiPoKiNiHiBeC_xHqqkZx_
		if (mmGapL <= mmBeginR - mmWidth && mmBeginR <= mmGapR)
			break;
		// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCkKiDeNiDiDiDgCiDhGiCoGiCoIiCoAiJeFiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		if (mmGapR < mmBeginR)
		{
			// _xZkqqHx_iLpDiCkLiDfIiDhJiBfLiDfIiCmMiJeFiImKjChFiCpAiDeNiDiDiDgCiDhGiJeFiNmAjFfHiCnMiCmFiNlGiCmJiKpBiClJiCoJiBeC_xHqqkZx_
			mmBeginR = mmGapR;
			// iGap_xZkqqHx_iCmJiMlIiOfKiClFiCmIiCkCiCoGiCkEiCmJiBeBiOjPiCmMiDiLiBfLiDhGiCnGjClFiCnEiBeC_xHqqkZx_
		} else
		{
			iGap -= 2;
		}
	}
	// _xZkqqHx_iMjPiNpFiMiLiJmKiCmMiLpDiCkLiDfIiDhJiBfLiDfIiJeFiNmAjFfHiCpAjAnNjCoIiBeC_xHqqkZx_
	mmRightX = mmBeginR;
	return TRUE;
} // GetMostRight.

//----- 06.05.21 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	GetCharKind
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFlGiOjKiDfCiBfLiDgIiCmMiOoNjHnOiBgJiDfGiDhEiDgH_xHqqkZx_JIS_xZkqqHx_iBgKiCpAjFnEiClH_xHqqkZx_.
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wChar	:_xZkqqHx_jFlGiOjKiDfCiBfLiDgIiBeC_xHqqkZx_UNICODE_xZkqqHx_iBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jFlGiOjKiDfCiBfLiDgIiCmMiOoNjHnO_xHqqkZx_.
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.03 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *			01.04.19 Fukushiro M. UNICODE_xZkqqHx_iJlLiBeC_xHqqkZx_
// *************************************************************************/
//static FDCharKind GetCharKind (WORD wChar)
//{
//	if (wChar < L' ')		return FDCK_ANSI_ETC;
//	else
//	if (wChar < L'0')		return FDCK_ANSI_MARK;
//	else
//	if (wChar < L':')		return FDCK_ANSI_NUMBER;
//	else
//	if (wChar < L'A')		return FDCK_ANSI_MARK;
//	else
//	if (wChar < L'[')		return FDCK_ANSI_ALPHABET;
//	else
//	if (wChar < L'a')		return FDCK_ANSI_MARK;
//	else
//	if (wChar < L'{')		return FDCK_ANSI_ALPHABET;
//	else
//	if (wChar < 0x00c0)		return FDCK_ANSI_MARK;
//	else
//	if (wChar < 0x0250)		return FDCK_ANSI_ALPHABET;	// _xZkqqHx_jAlDiKgNiCmJiCmNiBeBiDiJiDgFiDjDiKgHjCkD_xHqqkZx_A,B_xZkqqHx_iBeC_xHqqkZx_
//	else
//	if (0xff21 <= wChar && wChar <= 0xff3a || 0xff41 <= wChar && wChar <= 0xff5a)
//							return FDCK_ZENK_ALPHABET;	// _xZkqqHx_jBfDiKhAiDeBiDiLiDhEiDeAiDhIiDgCiDgHiBeC_xHqqkZx_
//	else
//		return FDCharKind(FDCK_OTHER_BEGIN + FFUnicodeToSubset(wChar));
//} // GetCharKind.
//----- 06.05.21 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

//----------</NOT EXPORT TO VIEWER>-----------

/////////////////////////////////////////////////////////////////////////////
// class FCShortRect

FCShortRect::FCShortRect ()
	: left(0), top(0), right(0), bottom(0)
{
} // FCShortRect::FCShortRect.

FCShortRect::FCShortRect (short nL, short nT, short nR, short nB)
	: left(nL), top(nT), right(nR), bottom(nB)
{
} // FCShortRect::FCShortRect.

BOOL FCShortRect::IsRectEmpty () const
{
	return (left == right) || (top == bottom);
} // FCShortRect::IsRectEmpty.

void FCShortRect::SetRect (short nL, short nT, short nR, short nB)
{
	left	= nL;
	top		= nT;
	right	= nR;
	bottom	= nB;
} // FCShortRect::SetRect.

BOOL FCShortRect::operator != (const FCShortRect& rect) const
{
	return (left != rect.left) || (top != rect.top) ||
			(right != rect.right) || (bottom != rect.bottom);
} // FCShortRect::operator.

BOOL FCShortRect::operator == (const FCShortRect& rect) const
{
	return (left == rect.left) && (top == rect.top) &&
			(right == rect.right) && (bottom == rect.bottom);
} // FCShortRect::operator.

void FCShortRect::operator = (const FCShortRect& rect)
{
	left	= rect.left;
	top		= rect.top;
	right	= rect.right;
	bottom	= rect.bottom;
} // FCShortRect::operator.

void FCShortRect::operator |= (const FCShortRect& rect)
{
	if (IsRectEmpty())
	{
		left	= rect.left;
		top		= rect.top;
		right	= rect.right;
		bottom	= rect.bottom;
	} else
	{
		if (rect.left < left) left = rect.left;
		if (rect.top < top) top = rect.top;
		if (right < rect.right) right = rect.right;
		if (bottom < rect.bottom) bottom = rect.bottom;
	}
} // FCShortRect::operator.

void FCShortRect::Empty ()
{
	left	= 0;
	top		= 0;
	right	= 0;
	bottom	= 0;
} // FCShortRect::Empty.

void FCShortRect::ExtendX (short n)
{
	left	-= n;
	right	+= n;
} // FCShortRect::ExtendX.

/////////////////////////////////////////////////////////////////////////////
// FCEditChar

FCEditChar::FCEditChar () {}

FCEditChar::FCEditChar (WORD wChar, SFontID foidFont, WORD wOffset,
						short nAfterSpace, COLORREF crColor,
						BYTE byUnderline, BYTE byStrikeOut, fmmetol mmfWidth,
						fmmetol mmfAbcA, fmmetol mmfAbcC, fmmetol mmfPreSpace, BYTE byCrossStat) :
						m_wChar(wChar), m_foidFont(foidFont), m_wOffset(wOffset),
						m_nAfterSpace(nAfterSpace), m_crColor(crColor),
						m_byUnderline(byUnderline), m_byStrikeOut(byStrikeOut),
						m_mmfWidth(mmfWidth), m_mmfAbcA(mmfAbcA), m_mmfAbcC(mmfAbcC),
						m_mmfPreSpace(mmfPreSpace), m_byCrossStat(byCrossStat)
{
} // FCEditChar::FCEditChar.

void FCEditChar::Clear ()
{
	m_wChar = 0;
	m_foidFont = 0;
	m_wOffset = 0;
	m_nAfterSpace = 0;
	m_crColor = 0;
	m_byUnderline = 0;
	m_byStrikeOut = 0;
	m_mmfWidth = 0;
	m_mmfAbcA = 0;
	m_mmfAbcC = 0;
	m_mmfPreSpace = 0;
	m_byCrossStat = 0;
	m_nrRect.Empty();
} // FCEditChar::Clear.

void FCEditChar::OutStream (BYTEVector& vStream) const
{
	vStream << m_wChar;			// _xZkqqHx_jFlGiOjKiDfCiBfLiDgIiBeC_xHqqkZx_
	vStream << m_foidFont;		// _xZkqqHx_jFlGiOjKiCmMiDhEiDeIiDjDiDgH_xHqqkZx_ID_xZkqqHx_iBeC_xHqqkZx_
	vStream << m_wOffset;		// Baseline_xZkqqHx_iCkJiCoHiCmM_xHqqkZx_Offset_xZkqqHx_iBeC_xHqqkZx_
	vStream << m_nAfterSpace;	// _xZkqqHx_jFlGiOjKiMoDiCoLiCmMiLpDjEjCiBeC_xHqqkZx_
	vStream << m_crColor;		// _xZkqqHx_jFlGiOjKiCmMjAeGiBeC_xHqqkZx_
	vStream << m_byUnderline;	// _xZkqqHx_iJlKjApMiMgAiOkOiBeC_xHqqkZx_
	vStream << m_byStrikeOut;	// _xZkqqHx_iOoGiPmBiClFjApMiMgAiOkOiBeC_xHqqkZx_
	vStream << m_mmfWidth;		// _xZkqqHx_jFlGiOjKiCmMjFjNiBeC_xHqqkZx_
	vStream << m_mmfAbcA;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
	vStream << m_mmfAbcC;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
	vStream << m_mmfPreSpace;	// _xZkqqHx_jFlGiOjKiCmMjBePiCmMjHfNjEjCiBeC_xHqqkZx_
	vStream << m_byCrossStat;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
} // FCEditChar::OutStream.

void FCEditChar::InStream (const BYTE*& pData)
{
	::FFReadData(m_wChar, pData);			// _xZkqqHx_jFlGiOjKiDfCiBfLiDgIiBeC_xHqqkZx_
	::FFReadData(m_foidFont, pData);		// _xZkqqHx_jFlGiOjKiCmMiDhEiDeIiDjDiDgH_xHqqkZx_ID_xZkqqHx_iBeC_xHqqkZx_
	::FFReadData(m_wOffset, pData);		// Baseline_xZkqqHx_iCkJiCoHiCmM_xHqqkZx_Offset_xZkqqHx_iBeC_xHqqkZx_
	::FFReadData(m_nAfterSpace, pData);	// _xZkqqHx_jFlGiOjKiMoDiCoLiCmMiLpDjEjCiBeC_xHqqkZx_
	::FFReadData(m_crColor, pData);	// _xZkqqHx_jFlGiOjKiCmMjAeGiBeC_xHqqkZx_
	::FFReadData(m_byUnderline, pData);	// _xZkqqHx_iJlKjApMiMgAiOkOiBeC_xHqqkZx_
	::FFReadData(m_byStrikeOut, pData);	// _xZkqqHx_iOoGiPmBiClFjApMiMgAiOkOiBeC_xHqqkZx_
	::FFReadData(m_mmfWidth, pData);		// _xZkqqHx_jFlGiOjKiCmMjFjNiBeC_xHqqkZx_
	::FFReadData(m_mmfAbcA, pData);		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
	::FFReadData(m_mmfAbcC, pData);		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
	::FFReadData(m_mmfPreSpace, pData);	// _xZkqqHx_jFlGiOjKiCmMjBePiCmMjHfNjEjCiBeC_xHqqkZx_
	::FFReadData(m_byCrossStat, pData);	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
} // FCEditChar::InStream.

void FCEditChar::Overread (const FCFontCharInfo& fci)
{
	ASSERT(fci.dwMask & FDFI_FLAG_ALL == FDFI_FLAG_ALL);
	m_byUnderline	= fci.byUnderline;
	m_byStrikeOut	= fci.byStrikeOut;
	m_wOffset		= fci.wOffset;
	m_nAfterSpace	= fci.nCharAfter;
	m_crColor	= fci.crColor;
} // FCEditChar::Overread.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditChar::ReqOverwrite
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	FCFontCharInfo_xZkqqHx_iBgJiDhEiDeIiDjDiDgHiPoOjFpBiBgKiCmJjBlGiNnNiClFiBeB_xHqqkZx_FCSFontRec
 *			_xZkqqHx_iBgJiDhEiDeIiDjDiDgHiDiMiDfCiBfLiDgIiBgKiCmJiMiHiCkPiCmEiCkCiCoJiPoOjFpBiCpA_xHqqkZx_ FCFontCharInfo _xZkqqHx_iCmJjCmHiJmBiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	fci	:FCFontCharInfo_xZkqqHx_iBgJiDhEiDeIiDjDiDgHiPoOjFpBiBgKiCpAiOhHjCoIiBeCiPoOjFpBiCpAjCmHiJmBiClFiCmEjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iJlKjApMiBeFiPmBjApMiBeFiPoDiJlKjFhEiCkLiBjFiPoDiJlKiInKjDkOiBeFiKnEiKhFiBeFjAeGiCmMiPoOjFpBiCpAjCmHiJmBiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditChar::ReqOverwrite (FCFontCharInfo& fci) const
{
	fci.dwMask |=	FDFI_FLAG_UNDERLINE |
					FDFI_FLAG_STRIKEOUT |
					FDFI_FLAG_OFFSET |
					FDFI_FLAG_CHARAFTER |
					FDFI_FLAG_COLORREF;
	fci.byUnderline = m_byUnderline;	// _xZkqqHx_iJlKjApMiBeC_xHqqkZx_
	fci.byStrikeOut = m_byStrikeOut;	// _xZkqqHx_iPmBjApMiBeC_xHqqkZx_
	fci.wOffset = m_wOffset;			// _xZkqqHx_iPoDiJlKjFhEiCkLiBjFiPoDiJlKiInKjDkOiBeC_xHqqkZx_
	fci.nCharAfter = m_nAfterSpace;		// _xZkqqHx_iKnEiKhFiBeC_xHqqkZx_
	fci.crColor = m_crColor;			// _xZkqqHx_jAeGiBeC_xHqqkZx_
} // FCEditChar::ReqOverwrite.

//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	==
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjFlGiOjKiCmGjDjJiClFiCkCiCkJjClCiCnHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ec	:_xZkqqHx_jBmOiPnLiCmMjFlGiOjKiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jDjJiClFiCkCiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jClCiCnHiCoJjBkOjAkLiCmNiBeB_xHqqkZx_OutStream _xZkqqHx_iCmFiPgPjHmNiClDiCoKiCoJjDoAjHgFiCmMiCnNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL FCEditChar::operator == (const FCEditChar& ec) const
{
	if (m_wChar != ec.m_wChar) return FALSE;				// _xZkqqHx_jFlGiOjKiDfCiBfLiDgIiBeC_xHqqkZx_
	if (m_foidFont != ec.m_foidFont) return FALSE;			// _xZkqqHx_jFlGiOjKiCmMiDhEiDeIiDjDiDgH_xHqqkZx_ID_xZkqqHx_iBeC_xHqqkZx_
	if (m_wOffset != ec.m_wOffset) return FALSE;			// Baseline_xZkqqHx_iCkJiCoHiCmM_xHqqkZx_Offset_xZkqqHx_iBeC_xHqqkZx_
	if (m_nAfterSpace != ec.m_nAfterSpace) return FALSE;	// _xZkqqHx_jFlGiOjKiMoDiCoLiCmMiLpDjEjCiBeC_xHqqkZx_
	if (m_crColor != ec.m_crColor) return FALSE;			// _xZkqqHx_jFlGiOjKiCmMjAeGiBeC_xHqqkZx_
	if (m_byUnderline != ec.m_byUnderline) return FALSE;	// _xZkqqHx_iJlKjApMiMgAiOkOiBeC_xHqqkZx_
	if (m_byStrikeOut != ec.m_byStrikeOut) return FALSE;	// _xZkqqHx_iOoGiPmBiClFjApMiMgAiOkOiBeC_xHqqkZx_

	// m_mmfWidth,m_mmfAbcA,m_mmfAbcC _xZkqqHx_iCmN_xHqqkZx_m_foidFont_xZkqqHx_iCkJiCoHiOfKiPgPiClDiCoKiCoJjCgMiCmFiCkAiCoJiClNiCnPiBeB_xHqqkZx_
	// _xZkqqHx_jEoEiKhCiClHiCoJjFeLjHhGiCmNjGlDiCkCiCmGjElLjCgGiBeC_xHqqkZx_
//----- 06.03.03 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	if (!abouteq(m_mmfWidth, ec.m_mmfWidth)) return FALSE;	// _xZkqqHx_jFlGiOjKiCmMjFjNiBeC_xHqqkZx_
//	if (!abouteq(m_mmfAbcA, ec.m_mmfAbcA)) return FALSE;	// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
//	if (!abouteq(m_mmfAbcC, ec.m_mmfAbcC)) return FALSE;	// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
//----- 06.03.03 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

	// m_mmfPreSpace _xZkqqHx_iCmG_xHqqkZx_ m_byCrossStat _xZkqqHx_iCoAjEoEiKhCiClFiCmEiCkCiClNiCkKiBeB_xHqqkZx_
	// OptimizeCmdQueue_xZkqqHx_iKnGjAjEjCiGiCmFjFhDjHhGiCmGjElLjCgGiBeC_xHqqkZx_
//----- 06.02.20 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	if (!abouteq(m_mmfPreSpace, ec.m_mmfPreSpace)) return FALSE;	// _xZkqqHx_jFlGiOjKiCmMjBePiCmMjHfNjEjCiBeC_xHqqkZx_
//	if (m_byCrossStat != ec.m_byCrossStat) return FALSE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
//----- 06.02.20 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	return TRUE;
} // FCEditChar::operator == (const FCEditChar& ec).

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	!=
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjFlGiOjKiCmGiInJiCmIiCoJiCkJjClCiCnHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ec	:_xZkqqHx_jBmOiPnLiCmMjFlGiOjKiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iInJiCmIiCoJiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jClCiCnHiCoJjBkOjAkLiCmNiBeB_xHqqkZx_OutStream _xZkqqHx_iCmFiPgPjHmNiClDiCoKiCoJjDoAjHgFiCmMiCnNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL FCEditChar::operator != (const FCEditChar& ec) const
{
	return !(operator == (ec));
} // FCEditChar::operator != (const FCEditChar& ec).
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----


size_t FCEditChar::SizeOfStream ()
{
	return	sizeof(((FCEditChar*)NULL)->m_wChar) +
			sizeof(((FCEditChar*)NULL)->m_foidFont) +
			sizeof(((FCEditChar*)NULL)->m_wOffset) +
			sizeof(((FCEditChar*)NULL)->m_nAfterSpace) +
			sizeof(((FCEditChar*)NULL)->m_crColor) +
			sizeof(((FCEditChar*)NULL)->m_byUnderline) +
			sizeof(((FCEditChar*)NULL)->m_byStrikeOut) +
			sizeof(((FCEditChar*)NULL)->m_mmfWidth) +
			sizeof(((FCEditChar*)NULL)->m_mmfAbcA) +
			sizeof(((FCEditChar*)NULL)->m_mmfAbcC) +
			sizeof(((FCEditChar*)NULL)->m_mmfPreSpace) +
			sizeof(((FCEditChar*)NULL)->m_byCrossStat);
} // FCEditChar::SizeOfStream.

/////////////////////////////////////////////////////////////////////////////
// FCEditLine

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::FCEditLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDjDiDfIiDgHiDiJiDeOiDfO_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.19 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
FCEditLine::FCEditLine ()
{
	//----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFjDkPiClGjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_mmStartIndent = 0.0;
	m_mmRightIndent = 0.0;
	m_mmOffset = 0.0;

	m_mmvTabs.clear();
	m_byAlignment = FDRC_AL_LEFT;

	//----- _xZkqqHx_jAoGjDkKiNhDiBeFiMhAjBlBiNhDiCpAiMiIjCoIiClHiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_byLineType = FDRC_LT_HEAD;
	//----- _xZkqqHx_iNhDiKnEiKhFiCpAiOhHjCoIiClHiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_nTwipLineAfter = 0;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_
	//----- _xZkqqHx_iNhDiCmMjFlGiOjKiPoOjFpBiCpAiOpLiCnPiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_vEditChar.clear();
	//----- _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiCmFjCgMiCkKiOfKiPgPiJmCjEfMiCmIiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_mmY = 0.0;
	m_mmfTMHeight = 0.0;
	m_mmfTMAscent = 0.0;
	m_mmfTMExternalLeading = 0.0;
} // FCEditLine::FCEditLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::Clear
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiPoOjFpBiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.03.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditLine::Clear ()
{
	m_mmStartIndent = 0;
	m_mmRightIndent = 0;
	m_mmOffset = 0;
	m_mmvTabs.clear();
	m_byAlignment = 0;
	m_byLineType = 0;
	m_nTwipLineAfter = 0;
	m_vEditChar.clear();
	m_mmY = 0;
	m_mmfTMHeight = 0;
	m_mmfTMAscent = 0;
	m_mmfTMExternalLeading = 0;
} // FCEditLine::Clear.

//----- 01.02.17 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::GetFormat
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCmMjBkOjAkLiCpAiBeB_xHqqkZx_PARAFORMAT_xZkqqHx_iNfMjBkCjBmMiCmJiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pfForm	:PARAFORMAT_xZkqqHx_iNfMjBkCjBmMiCmMjCgMiCpAjFnEiClHiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.01.28 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void FCEditLine::GetFormat (PARAFORMAT& pfForm) const
//{
//	pfForm.cbSize = sizeof(pfForm);
//	pfForm.dwMask = PFM_ALIGNMENT | PFM_NUMBERING | PFM_OFFSET |
//					PFM_RIGHTINDENT | PFM_STARTINDENT | PFM_TABSTOPS;
//	pfForm.wNumbering = 0;
//	pfForm.wReserved = 0;
//	pfForm.dxStartIndent = mm2tw(m_mmStartIndent);
//	pfForm.dxRightIndent = mm2tw(m_mmRightIndent);
//	pfForm.dxOffset = mm2tw(m_mmOffset);
//	switch (m_byAlignment)
//	{
//	case FDRC_AL_RIGHT:
//		pfForm.wAlignment = PFA_RIGHT;
//		break;
//	case FDRC_AL_CENTER:
//		pfForm.wAlignment = PFA_CENTER;
//		break;
//	default: // FDRC_AL_LEFT, FDRC_AL_LEFTRIGHT,FDRC_AL_NONE.
//		pfForm.wAlignment = PFA_LEFT;
//		break;
//	}
//	pfForm.cTabCount = m_mmvTabs.size();
//	for (long lC = 0; lC < m_mmvTabs.size(); lC++)
//		pfForm.rgxTabs[lC] = mm2tw(m_mmvTabs[lC]);
//} // FCEditLine::GetFormat.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::SetFormat
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCpA_xHqqkZx_PARAFORMAT_xZkqqHx_iNfMjBkCjBmMiCmFiPiJiKpKiJlLiClHiCoJ_xHqqkZx_.
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pfForm	: PARAFORMAT_xZkqqHx_iNfMjBkCjBmM_xHqqkZx_
// *************************************************************************/
//void FCEditLine::SetFormat (const PARAFORMAT& pfForm)
//{
//	if (pfForm.dwMask & PFM_STARTINDENT)
//		m_mmStartIndent	= tw2mm(pfForm.dxStartIndent);
//
//	if (pfForm.dwMask & PFM_RIGHTINDENT)
//		m_mmRightIndent	= tw2mm(pfForm.dxRightIndent);
//
//	if (pfForm.dwMask & PFM_OFFSET)
//		m_mmOffset	= tw2mm(pfForm.dxOffset);
//
//	if (pfForm.dwMask & PFM_TABSTOPS)
//	{
//		m_mmvTabs.clear();
//		for (short nTab = 0; nTab < pfForm.cTabCount; nTab++)
//			m_mmvTabs.push_back(tw2mm(pfForm.rgxTabs[nTab]));
//	}
//
//	if (pfForm.dwMask & PFM_ALIGNMENT)
//	{
//		switch (pfForm.wAlignment)
//		{
//		case PFA_LEFT:
//			m_byAlignment = FDRC_AL_LEFT;
//			break;
//		case PFA_RIGHT:
//			m_byAlignment = FDRC_AL_RIGHT;
//			break;
//		case PFA_CENTER:
//			m_byAlignment = FDRC_AL_CENTER;
//			break;
//		default:
//			m_byAlignment = FDRC_AL_NONE;
//		}
//	}
//} // FCEditLine::SetFormat.
//----- 01.02.17 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::GetFormat
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCmMjBkOjAkLiCpA_xHqqkZx_FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCmJiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	tli	:FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCmMjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.02.17 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditLine::GetFormat (FCTextLineInfo& tli) const
{
	tli.dwMask = FDTL_FLAG_ALL;
	tli.mmStartIndent = m_mmStartIndent;	// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	tli.mmRightIndent = m_mmRightIndent;	// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	tli.mmOffset = m_mmOffset;				// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgHiBgJjAoGjDkKiNhDiCmJjBmOiClHiCoJiDeJiDhEiDfKiDgCiDgHjCgMiBgK_xHqqkZx_
	tli.mmvTabs = m_mmvTabs;				// _xZkqqHx_iDfOiDhFjEhKjHpBiBeC_xHqqkZx_
	tli.byAlignment = m_byAlignment;		// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBgJiNlGjCiGiJjLiJeFiKpBiClJiBgK_xHqqkZx_
	tli.nTwipLineAfter = m_nTwipLineAfter;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmM_xHqqkZx_TWIPS_xZkqqHx_jAjEiBeC_xHqqkZx_
} // FCEditLine::GetFormat.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::SetFormat
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCpA_xHqqkZx_FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCmFiPiJiKpKiJlLiClHiCoJ_xHqqkZx_.
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	tli	: FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.02.17 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditLine::SetFormat (const FCTextLineInfo& tli)
{
	if (tli.dwMask & FDTL_FLAG_STARTINDENT)
		m_mmStartIndent = tli.mmStartIndent;	// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_RIGHTINDENT)
		m_mmRightIndent = tli.mmRightIndent;	// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_OFFSET)
		m_mmOffset = tli.mmOffset;				// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgHiBgJjAoGjDkKiNhDiCmJjBmOiClHiCoJiDeJiDhEiDfKiDgCiDgHjCgMiBgK_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_TABSTOPS)
		m_mmvTabs = tli.mmvTabs;				// _xZkqqHx_iDfOiDhFjEhKjHpBiBeC_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_ALIGNMENT)
		m_byAlignment = tli.byAlignment;		// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBgJiNlGjCiGiJjLiJeFiKpBiClJiBgK_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_LINEAFTER)
		m_nTwipLineAfter = tli.nTwipLineAfter;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmM_xHqqkZx_TWIPS_xZkqqHx_jAjEiBeC_xHqqkZx_
} // FCEditLine::SetFormat.
//----- 01.02.17 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----


void FCEditLine::operator = (const FCStatLine& slStat)
{
	/*----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFjDkPiClGjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----*/
	m_mmStartIndent	= slStat.m_mmStartIndent;
	m_mmRightIndent	= slStat.m_mmRightIndent;
	m_mmOffset		= slStat.m_mmOffset;
	m_mmvTabs		= slStat.m_mmvTabs;
	m_byAlignment	= slStat.m_byAlignment;

	/*----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFiInJiCmIiCoJjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----*/
	m_byLineType	= slStat.m_byLineType;	
	//----- _xZkqqHx_iNhDiKnEiKhFiCpAiOhHjCoIiClHiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_nTwipLineAfter = slStat.m_nTwipLineAfter;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_

	FCStatCharVector::const_iterator i;
	SFontID		foidFont;		// _xZkqqHx_jFlGiOjKiCmMiDhEiDeIiDjDiDgH_xHqqkZx_ID.
	WORD		wOffset;		// Baseline_xZkqqHx_iCkJiCoHiCmM_xHqqkZx_Offset.
	short		nAfterSpace;	// _xZkqqHx_jFlGiOjKiCmMiMoDiCoLiCmMiLpDjEjCiBeC_xHqqkZx_
	COLORREF	crColor;		// _xZkqqHx_jFlGiOjKiCmMjAeG_xHqqkZx_.
//----- 01.02.13 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	BYTE		byUnderline;	// _xZkqqHx_iJlKjApMiBeC_xHqqkZx_
	BYTE		byStrikeOut;	// _xZkqqHx_iOoGiPmBiClFjApMiBeC_xHqqkZx_
	BYTE		byCrossStat;	// _xZkqqHx_jFlGiOjKiIoMiCoKiPpDjBnEiBeC_xHqqkZx_
//----- 01.02.13 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	fmmetol		mmfPreSpace = 0.0;	// _xZkqqHx_jFlGiOjKjBePjHfNjEjC_xHqqkZx_.
	for (i = slStat.m_vStatChar.begin(); i != slStat.m_vStatChar.end(); i++)
	{
		switch ((*i).m_wChar)
		{
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		case FDRCH_FONT:
//			foidFont = (*i).m_foidFont;
//			break;
//		case FDRCH_OFFSET:
//			wOffset = (*i).m_wOffset;
//			break;
//		case FDRCH_AFTERSPACE:
//			nAfterSpace = (*i).m_nAfterSpace;
//			break;
//		case FDRCH_SCOLOR:
//			crColor = (*i).m_crColor;
//			break;
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		case FDRCH_FONT_AND_OFFSET:
			foidFont = (*i).m_foidFont;
			wOffset = (*i).m_wOffset;
			break;
		case FDRCH_COLORREF:
			crColor = (*i).m_crColor;
			break;
		case FDRCH_AFTERSPACE:
			nAfterSpace = (*i).m_nAfterSpace;
			break;
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

//----- 01.02.15 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
		case FDRCH_LINES_AND_CROSSSTAT:
			byUnderline = (*i).m_byUnderline;
			byStrikeOut = (*i).m_byStrikeOut;
			byCrossStat = (*i).m_byCrossStat;
			break;
//----- 01.02.15 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

		case FDRCH_PRESPACE:
			mmfPreSpace = (*i).m_mmfPreSpace;
			break;
		default:
//----- 01.02.13 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//			m_vEditChar.push_back(FCEditChar((*i).m_wChar, foidFont, wOffset,
//											nAfterSpace, crColor, (*i).m_mmfWidth,
//											(*i).m_mmfAbcA, (*i).m_mmfAbcC,
//											mmfPreSpace));
//----- 01.02.13 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
			m_vEditChar.push_back(FCEditChar((*i).m_wChar, foidFont, wOffset,
											nAfterSpace, crColor,
											byUnderline, byStrikeOut, (*i).m_mmfWidth,
											(*i).m_mmfAbcA, (*i).m_mmfAbcC,
											mmfPreSpace, byCrossStat));
//----- 01.02.13 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
			// PreSpace_xZkqqHx_iCmNiCfAiJpBiMmAiCoIjHeMiMpI_xHqqkZx_.
			mmfPreSpace = 0.0;
		}
	}

	m_mmY					= slStat.m_mmY;
	m_mmfTMHeight			= slStat.m_mmfTMHeight;
	m_mmfTMAscent			= slStat.m_mmfTMAscent;
	m_mmfTMExternalLeading	= slStat.m_mmfTMExternalLeading;
// 99.11.20 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	m_mmfHeadSpace			= slStat.m_mmfHeadSpace;
} // FCEditLine::operator = (const FCStatLine& slStat).

void FCEditLine::CopyProperty (const FCEditLine& elEdit)
{
	/*----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFjDkPiClGjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----*/
	m_mmStartIndent	= elEdit.m_mmStartIndent;
	m_mmRightIndent	= elEdit.m_mmRightIndent;
	m_mmOffset		= elEdit.m_mmOffset;
	m_mmvTabs		= elEdit.m_mmvTabs;
	m_byAlignment	= elEdit.m_byAlignment;
	//----- _xZkqqHx_jAoGjDkKiNhDiBeFiMhAjBlBiNhDiCpAiMiIjCoIiClHiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_byLineType	= elEdit.m_byLineType;		// _xZkqqHx_iNhDiCmMiDfOiDeDiDhG_xHqqkZx_(_xZkqqHx_jAoGjDkK_xHqqkZx_/_xZkqqHx_iMhAjBlB_xHqqkZx_)
	//----- _xZkqqHx_iNhDiKnEiKhFiCpAiOhHjCoIiClHiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	m_nTwipLineAfter = elEdit.m_nTwipLineAfter;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_
} // FCEditLine::CopyProperty.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::CalcTabPos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfOiDhFjFlGiOjKiCpAiCfAjFlGiOjKjBmFiCmBiClNiOjOiCmMjAfGiClFiCkCiImKjChFiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmX	: _xZkqqHx_iMlLiNnNiCmMiImKjChFiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jAfGiClFiCkCiImKjChFiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iDfOiDhFiCmJiCmCiCkCiCmE_xHqqkZx_
 *			_xZkqqHx_iDfOiDhFiImKjChFiCmNiBeBiOhHjCoIiCkKjGlDiCkCiPoKiNiH_xHqqkZx_0.5_xZkqqHx_iDeDiDjDiDgAiClCiCmGiBeBjBkGiClP_xHqqkZx_12.7mm_xZkqqHx_iClCiCmGiCmJ_xHqqkZx_
 *			_xZkqqHx_jAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.21 Fukushiro M. _xZkqqHx_iDeBiDiLiDfDiDiKiDfJiDiAiCpAiKmIjCfAiCmIiCoAiCmMiCmJjFmPiNfIiBeC_xHqqkZx_
 *************************************************************************/
#define TAB_DIFF	12.7
mmetol FCEditLine::CalcTabPos (mmetol mmX) const
{
	int iTab;
	for (iTab = 0; iTab < m_mmvTabs.size(); iTab++)
	//----- _xZkqqHx_iMmFjHeMiDfOiDhFiCkKjAnNjCoIiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
	{
		if (roughless(mmX ,m_mmvTabs[iTab]))
		//----- _xZkqqHx_iOhHjCoIiClDiCoKiClNiNmAjFfHiCpAiMjPiNpFiCmMiDfOiDhFiImKjChFiCkKiJhKiCkGiClNiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_iDeJiDhEiDfKiDgCiDgHiImKjChFiCkKiDfOiDhFiImKjChFiCmG_xHqqkZx_mmX_xZkqqHx_iCmMiKnEiCmJiCkAiCoJiPoKiNiHiCmNiBeB_xHqqkZx_
			// _xZkqqHx_iDeJiDhEiDfKiDgCiDgHiImKjChFiCpAiDfOiDhFiImKjChFiCmGiClFiCmEjFnEiClHiBeC_xHqqkZx_
			if (roughless(mmX, m_mmStartIndent + m_mmOffset) &&
				roughless(m_mmStartIndent + m_mmOffset, m_mmvTabs[iTab]))
				return m_mmStartIndent + m_mmOffset;
			// _xZkqqHx_iDfOiDhFiImKjChFiCpAjFnEiClHiBeC_xHqqkZx_
			return m_mmvTabs[iTab];
		}
	}
	//----- _xZkqqHx_iMmFjHeMiDfOiDhFiCkKjAnNjCoIiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiHiIlNiCkCiCmNiMmFjHeMiDfOiDhFjAnNjCoIjEmNiImNiCpAjClEiCkGiClNiPoKiNiH_xHqqkZx_ -----
	// _xZkqqHx_iDeJiDhEiDfKiDgCiDgHiImKjChFiCmNiNmFiPiJiCmMiDfOiDhFiImKjChFiBeC_xHqqkZx_
	if (roughless(mmX, m_mmStartIndent + m_mmOffset))
		return m_mmStartIndent + m_mmOffset;

	iTab = mmX / TAB_DIFF;
	// mmX_xZkqqHx_iCkKjFiJiIlNiCkCiCmN_xHqqkZx_TAB_DIFF_xZkqqHx_iCmFiKiEiCoIjAnIiCoKiCoJiPoKiNiHiCpAiNgMjHlGiBeC_xHqqkZx_
// 01.02.10 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	while (iTab * TAB_DIFF <= mmX) iTab++;
	while (roughlesseq(iTab * TAB_DIFF, mmX)) iTab++;
	return iTab * TAB_DIFF;
} // FCEditLine::CalcTabPos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::CalcTabRPos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNmAjFfHiCoGiCoIiNlGiCmJiCkAiCoIiBeBiKiOiCmCiNmFiCoAiNmAjFfHiCmJiLnPiCkCiDfOiDhFiImKjChFiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmX	:_xZkqqHx_iMjPiNpFiClHiCoJiNmAjFfHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jAfGiClFiCkCiImKjChFiBeCiDfOiDhFiCkKjAnNjCoIiCmFiCkLiCmIiCkCiPoKiNiHiCmNiCePiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iDfOiDhFiCmJiCmCiCkCiCmE_xHqqkZx_
 *			_xZkqqHx_iDfOiDhFiImKjChFiCmNiBeBiOhHjCoIiCkKjGlDiCkCiPoKiNiH_xHqqkZx_0.5_xZkqqHx_iDeDiDjDiDgAiClCiCmGiBeBjBkGiClP_xHqqkZx_12.7mm_xZkqqHx_iClCiCmGiCmJ_xHqqkZx_
 *			_xZkqqHx_jAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.21 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
mmetol FCEditLine::CalcTabRPos (mmetol mmX) const
{
	int iTab;
	for (iTab = m_mmvTabs.size() - 1; 0 <= iTab; iTab--)
	//----- _xZkqqHx_iMmFjHeMiDfOiDhFiCkKjAnNjCoIiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
	{
		if (roughless(m_mmvTabs[iTab], mmX))
		//----- _xZkqqHx_iOhHjCoIiClDiCoKiClNiNmAjFfHiCpAiMjPiNpFiCmMiDfOiDhFiImKjChFiCkKiJhKiCkGiClNiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_iDeJiDhEiDfKiDgCiDgHiImKjChFiCkKiDfOiDhFiImKjChFiCmG_xHqqkZx_mmX_xZkqqHx_iCmMiKnEiCmJiCkAiCoJiPoKiNiHiCmNiBeB_xHqqkZx_
			// _xZkqqHx_iDeJiDhEiDfKiDgCiDgHiImKjChFiCpAiDfOiDhFiImKjChFiCmGiClFiCmEjFnEiClHiBeC_xHqqkZx_
			if (roughless(m_mmvTabs[iTab], m_mmStartIndent + m_mmOffset) &&
				roughless(m_mmStartIndent + m_mmOffset, mmX))
				return m_mmStartIndent + m_mmOffset;
			// _xZkqqHx_iDfOiDhFiImKjChFiCpAjFnEiClHiBeC_xHqqkZx_
			return m_mmvTabs[iTab];
		}
	}
	//----- _xZkqqHx_iMmFjHeMiDfOiDhFiCkKjAnNjCoIiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiHiIlNiCkCiCmNiMmFjHeMiDfOiDhFjAnNjCoIjEmNiImNiCpAjClEiCkGiClNiPoKiNiH_xHqqkZx_ -----
	// _xZkqqHx_iDeJiDhEiDfKiDgCiDgHiImKjChFiCmNiNmFiPiJiCmMiDfOiDhFiImKjChFiBeC_xHqqkZx_
	if (roughless(mmX, m_mmStartIndent + m_mmOffset)) return 0.0;

	iTab = mmX / TAB_DIFF;
	// mmX_xZkqqHx_iCkKjFiJiIlNiCkCiCmN_xHqqkZx_TAB_DIFF_xZkqqHx_iCmFiKiEiCoIjAnIiCoKiCoJiPoKiNiHiCpAiNgMjHlGiBeC_xHqqkZx_
	while (roughlesseq(mmX, iTab * TAB_DIFF)) iTab--;
	if (roughless(iTab * TAB_DIFF, m_mmStartIndent + m_mmOffset))
		return m_mmStartIndent + m_mmOffset;
	return iTab * TAB_DIFF;

#undef TAB_DIFF
} // FCEditLine::CalcTabRPos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::OutLinStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCmMiPoOjFpBiCmMiCnNiCpAiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiPgPjHmNiClHiCoJiBeC_xHqqkZx_Redo/Undo_xZkqqHx_jHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	vQueue	:_xZkqqHx_iPgPjHmNjAoGiCmMiDeMiDiFiBfLiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iPgPjHmNiClHiCoJiPoOjFpBiCmJiCmNiBeB_xHqqkZx_CalcLine_xZkqqHx_iCmFiNmEiMhGiOfKiClDiCoKiCoJiPoOjFpBiCmNiKnMiCnPiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNhDiPoOjFpB_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *          _xZkqqHx_iEkGiEjPiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkGiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *          _xZkqqHx_iEkAjAoGjDkKiNhD_xHqqkZx_      _xZkqqHx_iEkAjAoGjDkKiBeFiMhAjBlBiNhDiEkAiMhAjBlBiNhD_xHqqkZx_      _xZkqqHx_iEkAiDfOiDhFjAjEiEkAiDfOiDhFiImKjChFiCfAiEkAiDfOiDhFiImKjChFiCfBiEkA_xHqqkZx_      _xZkqqHx_iEkAiDfOiDhFiImKjChFiCiOiEkAiNlGiJeF_xHqqkZx_          _xZkqqHx_iEkAiNhDiKnE_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkAiNlGiDeDiDjDiDgGiDjDiDgHiEkAiJeFiDeDiDjDiDgGiDjDiDgHiEkAiNlGiDeDiDjDiDgGiDjDiDgHiEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkAiDeBiDiJiDeDiDjDiDiBiDjDiDgHiEkAiLjHjHkD_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkIiEjPiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkIiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_              _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkFiEjP_xHqqkZx_mmetol_xZkqqHx_iEjPiEjPiEkJiEjP_xHqqkZx_mmetol_xZkqqHx_iEjPiEjPiEkJiEjP_xHqqkZx_mmetol_xZkqqHx_iEjPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiEjP_xHqqkZx_mmetol_xZkqqHx_iEjPiEkJiEjP_xHqqkZx_mmetol_xZkqqHx_iEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiEjP_xHqqkZx_mmetol_xZkqqHx_iEjPiEkJiEjPiEjP_xHqqkZx_BYTE_xZkqqHx_iEjPiEjPiEjPiEkJ_xHqqkZx_short-_xZkqqHx_iEkH_xHqqkZx_
 *                                                            _xZkqqHx_iEkA_xHqqkZx_                                          _xZkqqHx_iEkA_xHqqkZx_
 *                                                            _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiDfOiDhFjAjEiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.14 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditLine::OutLinStream (BYTEVector& vQueue) const
{
	vQueue << m_mmStartIndent;	// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	vQueue << m_mmRightIndent;	// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	vQueue << m_mmOffset;		// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgHiBgJjAoGjDkKiNhDiCmJ_xHqqkZx_
								// _xZkqqHx_jBmOiClHiCoJiDeJiDhEiDfKiDgCiDgHjCgMiBgK_xHqqkZx_.
	//----- _xZkqqHx_iDfOiDhFiCmMiImKjChFiCmMjHpBiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	::WriteVSizeU(vQueue, m_mmvTabs.size());
	mmetolVector::const_iterator iTab;
	for (iTab = m_mmvTabs.begin(); iTab != m_mmvTabs.end(); iTab++)
		vQueue << *iTab;
	vQueue << m_byAlignment;	// // _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBgJiNlGjCiGiJjLiJeFiKpBiClJiBgK_xHqqkZx_
	//----- _xZkqqHx_iNhDiKnEiKhFiCpAiOhHjCoIiClHiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	vQueue << m_nTwipLineAfter;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_
} // FCEditLine::OutLinStream.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::InLinStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCmMiPoOjFpBiCmMiCnNiCpAiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCkJiCoHjDpMjHmNiClHiCoJiBeC_xHqqkZx_Redo/Undo_xZkqqHx_jHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	bypQueue	:_xZkqqHx_jDpMjHmNiMlDiCmMiDeMiDiFiBfLiCpAiOhHjCoIiBeCiDhMiDeDiDjDiDfOiCpAjAgJiCnPiCmEjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.14 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditLine::InLinStream (const BYTE*& bypQueue)
{
	int iC;
	::FFReadData(m_mmStartIndent, bypQueue);	// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	::FFReadData(m_mmRightIndent, bypQueue);	// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	::FFReadData(m_mmOffset, bypQueue);		// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgHiBgJjAoGjDkKiNhDiCmJ_xHqqkZx_
											// _xZkqqHx_jBmOiClHiCoJiDeJiDhEiDfKiDgCiDgHjCgMiBgK_xHqqkZx_.
	//----- _xZkqqHx_iDfOiDhFiCmMiImKjChFiCmMjHpBiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
	DWORD dwTabSz = ::ReadVSizeU(bypQueue);
	m_mmvTabs.resize(dwTabSz);
	for (iC = 0; iC < m_mmvTabs.size(); iC++)
		::FFReadData(m_mmvTabs[iC], bypQueue);	// _xZkqqHx_iDfOiDhFjDmHiCnNiNjOiCnNiBeC_xHqqkZx_

	::FFReadData(m_byAlignment, bypQueue);	// // _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBgJiNlGjCiGiJjLiJeFiKpBiClJiBgK_xHqqkZx_
//----- 05.07.01 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	//----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFiInJiCmIiCoJjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
//	::FFReadData(m_byLineType, bypQueue);		// _xZkqqHx_iNhDiCmMiDfOiDeDiDhG_xHqqkZx_(_xZkqqHx_jAoGjDkK_xHqqkZx_/_xZkqqHx_iMhAjBlB_xHqqkZx_)
//----- 05.07.01 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	//----- _xZkqqHx_iNhDiKnEiKhFiCpAiOhHjCoIiClHiCoJiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----
	::FFReadData(m_nTwipLineAfter, bypQueue);	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_
} // FCEditLine::InLinStream.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::OutLinChrStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCmGjFlGiOjKiCmMiPoOjFpBiCpAiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiPgPjHmNiClHiCoJiBeC_xHqqkZx_Redo/Undo_xZkqqHx_jHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	vQueue	:_xZkqqHx_iPgPjHmNjAoGiCmMiDeMiDiFiBfLiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iPgPjHmNiClHiCoJiPoOjFpBiCmJiCmNiBeB_xHqqkZx_CalcLine_xZkqqHx_iCmFiNmEiMhGiOfKiClDiCoKiCoJiPoOjFpBiCmNiKnMiCnPiCmIiCkCiBeC_xHqqkZx_
 *
 *          _xZkqqHx_iNhDiBjFjFlGiOjKiPoOjFpB_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *          _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkGiEjPiEjPiEjPiEjPiEjPiEkG_xHqqkZx_
 *          _xZkqqHx_iEkAiNhDiPoOjFpBiEkAjFlGiOjKjAjEiEkAjFlGiOjKiPoOjFpBiCfAiEkAjFlGiOjKiPoOjFpBiCfBiEkA_xHqqkZx_      _xZkqqHx_iEkAjFlGiOjKiPoOjFpBiCiOiEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkIiEjPiEjPiEjPiEjPiEjPiEkI_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkFiJmCjFmPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiEjPiMmFjCoIiEjPiEjPiEkJiEjPiMmFjCoIiEjPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiEjPiMmFjCoIiEjPiEjPiEkH_xHqqkZx_
 *                          _xZkqqHx_iEkA_xHqqkZx_                                          _xZkqqHx_iEkA_xHqqkZx_
 *                          _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPjFlGiOjKjAjEiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.14 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditLine::OutLinChrStream (BYTEVector& vQueue) const
{
	// _xZkqqHx_iNhDiPoOjFpBiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
	OutLinStream(vQueue);
	//----- _xZkqqHx_jFlGiOjKjHpBiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	::WriteVSizeU(vQueue, m_vEditChar.size());
	FCEditCharVector::const_iterator i;
	for (i = m_vEditChar.begin(); i != m_vEditChar.end(); i++)
		(*i).OutStream(vQueue);
} // FCEditLine::OutLinChrStream.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCEditLine::InLinChrStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCmGjFlGiOjKiCmMiPoOjFpBiCpAiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCkJiCoHjDpMjHmNiClHiCoJiBeC_xHqqkZx_Redo/Undo_xZkqqHx_jHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	bypQueue	:_xZkqqHx_jDpMjHmNiMlDiCmMiDeMiDiFiBfLiCpAiOhHjCoIiBeCiDhMiDeDiDjDiDfOiCpAjAgJiCnPiCmEjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.14 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCEditLine::InLinChrStream (const BYTE*& bypQueue)
{
	// _xZkqqHx_iNhDiPoOjFpBiCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
	InLinStream(bypQueue);
	//----- _xZkqqHx_jFlGiOjKjHpBiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
	DWORD dwCharSz = ::ReadVSizeU(bypQueue);
	m_vEditChar.resize(dwCharSz);
	for (int iC = 0; iC < m_vEditChar.size(); iC++)
		m_vEditChar[iC].InStream(bypQueue);	// _xZkqqHx_jFlGiOjKjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
} // FCEditLine::InLinChrStream.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	==
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiCmGjDjJiClFiCkCiCkJjClCiCnHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	el	:_xZkqqHx_jBmOiPnLiCmMiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jDjJiClFiCkCiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jClCiCnHiCoJjBkOjAkLiCmNiBeB_xHqqkZx_OutStream _xZkqqHx_iCmFiPgPjHmNiClDiCoKiCoJjDoAjHgFiCmMiCnNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL FCEditLine::operator == (const FCEditLine& el) const
{
	// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	if (!almosteq(m_mmStartIndent, el.m_mmStartIndent)) return FALSE;
	// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	if (!almosteq(m_mmRightIndent, el.m_mmRightIndent)) return FALSE;
	// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	if (!almosteq(m_mmOffset, el.m_mmOffset)) return FALSE;
	// _xZkqqHx_iDfOiDhFiImKjChFiBeC_xHqqkZx_
	if (!almosteq(m_mmvTabs, el.m_mmvTabs)) return FALSE;
	// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBgJiNlGjCiGiJjLiJeFiKpBiClJiBgK_xHqqkZx_
	if (m_byAlignment != el.m_byAlignment) return FALSE;
	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_
	if (m_nTwipLineAfter != el.m_nTwipLineAfter) return FALSE;
	return TRUE;
} // FCEditLine::operator ==.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	!=
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiCmGiInJiCmIiCoJiCkJjClCiCnHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	el	:_xZkqqHx_jBmOiPnLiCmMiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iInJiCmIiCoJiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jClCiCnHiCoJjBkOjAkLiCmNiBeB_xHqqkZx_OutStream _xZkqqHx_iCmFiPgPjHmNiClDiCoKiCoJjDoAjHgFiCmMiCnNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL FCEditLine::operator != (const FCEditLine& el) const
{
	return !(operator == (el));
} // FCEditLine::operator !=.

////////////////////////// _xZkqqHx_jFjEjFgJjHhAiCmMiDeOiDiJiDfI_xHqqkZx_ ////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
// FCStatChar
FCStatChar::FCStatChar ()
{
	// memcmp_xZkqqHx_iCmFiDeJiDhFiDfHiDeGiDeOiDgHjEoEiKhCiCpAiClHiCoJiClNiCnPiBeBiNfMjBkCjBmMiDeNiDiDiDgCiDhGiCoAjBfDiCmEiCePiCmFjGiEiCnPiCoJiBeC_xHqqkZx_
	memset(this, 0, sizeof(*this));
} // FCStatChar::FCStatChar.

//----- 01.02.15 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//FCStatChar::FCStatChar (WORD wChar, WORD wOffset_foid)
//{
//	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
//	memset(this, 0, sizeof(*this));
//	m_wChar = wChar;
//	m_wOffset = wOffset_foid;
//	m_mmfAbcA = 0.0;
//	m_mmfAbcC = 0.0;
//} // FCStatChar::FCStatChar.
//
//FCStatChar::FCStatChar (WORD wChar, short nAfterSpace)
//{
//	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
//	memset(this, 0, sizeof(*this));
//	m_wChar = wChar;
//	m_nAfterSpace = nAfterSpace;
//	m_mmfAbcA = 0.0;
//	m_mmfAbcC = 0.0;
//} // FCStatChar::FCStatChar.
//----- 01.02.15 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

FCStatChar::FCStatChar (WORD wChar, fmmetol mmfPreSpace)
{
	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
	memset(this, 0, sizeof(*this));
	m_wChar = wChar;
	m_mmfPreSpace = mmfPreSpace;
	m_mmfAbcA = 0.0;
	m_mmfAbcC = 0.0;
} // FCStatChar::FCStatChar.

FCStatChar::FCStatChar (WORD wChar, fmmetol mmfWidth, fmmetol mmfAbcA, fmmetol mmfAbcC)
{
	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
	memset(this, 0, sizeof(*this));
	m_wChar = wChar;
	m_mmfWidth = mmfWidth;
	m_mmfAbcA = mmfAbcA;	// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
	m_mmfAbcC = mmfAbcC;	// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
} // FCStatChar::FCStatChar.

//----- 01.02.08 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//FCStatChar::FCStatChar (WORD wChar, SFontID foid)
//{
//	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
//	memset(this, 0, sizeof(*this));
//	m_wChar = wChar;
//	m_foidFont = foid;
//	m_mmfAbcA = 0.0;
//	m_mmfAbcC = 0.0;
//} // FCStatChar::FCStatChar.
//----- 01.02.08 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

//----- 01.02.15 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//FCStatChar::FCStatChar (WORD wChar, BYTE byLine)
//{
//	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
//	memset(this, 0, sizeof(*this));
//	m_wChar = wChar;
//	m_byUnderline = byLine;
//	m_mmfAbcA = 0.0;
//	m_mmfAbcC = 0.0;
//} // FCStatChar::FCStatChar.
//----- 01.02.15 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

FCStatChar::FCStatChar (WORD wChar, SFontID foid, WORD wOffset)
{
	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
	memset(this, 0, sizeof(*this));
	m_wChar = wChar;
	m_foidFont = foid;
	m_wOffset = wOffset;
	m_mmfAbcA = 0.0;
	m_mmfAbcC = 0.0;
} // FCStatChar::FCStatChar.

FCStatChar::FCStatChar (WORD wChar, COLORREF cref)
{
	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
	memset(this, 0, sizeof(*this));
	m_wChar = wChar;
	m_crColor = cref;
	m_mmfAbcA = 0.0;
	m_mmfAbcC = 0.0;
} // FCStatChar::FCStatChar.

FCStatChar::FCStatChar (WORD wChar, short nAfterSpace)
{
	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
	memset(this, 0, sizeof(*this));
	m_wChar = wChar;
	m_nAfterSpace = nAfterSpace;
	m_mmfAbcA = 0.0;
	m_mmfAbcC = 0.0;
} // FCStatChar::FCStatChar.

FCStatChar::FCStatChar (WORD wChar, BYTE byUnderline, BYTE byStrikeOut, BYTE byCrossStat)
{
	// operator == _xZkqqHx_iCmFiCmN_xHqqkZx_memcmp _xZkqqHx_iCmFjEoEiKhCiClHiCoJiClNiCnPiBeBiCnMiCmBiClDiCoHiCmJiClFiCmEiCkIiCkNiBeC_xHqqkZx_
	memset(this, 0, sizeof(*this));
	m_wChar = wChar;
	m_byUnderline = byUnderline;
	m_byStrikeOut = byStrikeOut;
	m_byCrossStat = byCrossStat;
	m_mmfAbcA = 0.0;
	m_mmfAbcC = 0.0;
} // FCStatChar::FCStatChar.

BOOL FCStatChar::operator == (const FCStatChar& sc) const
{
	return (memcmp(this, &sc, sizeof(*this)) == 0);
} // FCStatChar::operator ==.

BOOL FCStatChar::operator != (const FCStatChar& sc) const
{
	return (memcmp(this, &sc, sizeof(*this)) != 0);
} // FCStatChar::operator !=.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatChar::OutStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBkOjAkLiDgGiBfLiDfOiCmMiPgPjHmNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ar	:_xZkqqHx_iPgPjHmNjAoGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.03.04 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCStatChar::OutStream (FCUndoArchive& ar) const
{
	ar << m_wChar;			// _xZkqqHx_jFlGiOjKiDfCiBfLiDgI_xHqqkZx_.
	ar << m_dwForStream;	// _xZkqqHx_jDpMiPgPjHmNjHhAiBeC_xHqqkZx_
	ar << m_mmfAbcA;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
	ar << m_mmfAbcC;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
} // FCStatChar::OutStream.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatChar::InStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBkOjAkLiDgGiBfLiDfOiCmMjDpMjHmNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ar	:_xZkqqHx_jDpMjHmNjAoGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.03.04 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCStatChar::InStream (FCUndoArchive& ar)
{
	ar >> m_wChar;			// _xZkqqHx_jFlGiOjKiDfCiBfLiDgI_xHqqkZx_.
	ar >> m_dwForStream;	// _xZkqqHx_jDpMiPgPjHmNjHhAiBeC_xHqqkZx_
	ar >> m_mmfAbcA;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
	ar >> m_mmfAbcC;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
} // FCStatChar::InStream.

/////////////////////////////////////////////////////////////////////////////
// FCStatLine

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatLine::FCStatLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDjDiDfIiDgHiDiJiDeOiDfO_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.19 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
FCStatLine::FCStatLine ()
{
	m_mmStartIndent	= 0.0;
	m_mmRightIndent	= 0.0;
	m_mmOffset		= 0.0;
	m_mmvTabs.clear();
	m_byAlignment	= FDRC_AL_LEFT;
	m_byLineType	= FDRC_LT_HEAD;
	m_nTwipLineAfter = 0;
	m_vStatChar.clear();
	m_mmY			= 0.0;
	m_mmfTMHeight	= 0.0;
	m_mmfTMAscent	= 0.0;
	m_mmfTMExternalLeading	= 0.0;
} // FCStatLine::FCStatLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatLine::GetFormat
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCmMjBkOjAkLiCpA_xHqqkZx_FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCmJiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	tli	:FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCmMjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.02.17 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCStatLine::GetFormat (FCTextLineInfo& tli) const
{
	tli.dwMask = FDTL_FLAG_ALL;
	tli.mmStartIndent = m_mmStartIndent;	// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	tli.mmRightIndent = m_mmRightIndent;	// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	tli.mmOffset = m_mmOffset;				// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgHiBgJjAoGjDkKiNhDiCmJjBmOiClHiCoJiDeJiDhEiDfKiDgCiDgHjCgMiBgK_xHqqkZx_
	tli.mmvTabs = m_mmvTabs;				// _xZkqqHx_iDfOiDhFjEhKjHpBiBeC_xHqqkZx_
	tli.byAlignment = m_byAlignment;		// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBgJiNlGjCiGiJjLiJeFiKpBiClJiBgK_xHqqkZx_
	tli.nTwipLineAfter = m_nTwipLineAfter;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmM_xHqqkZx_TWIPS_xZkqqHx_jAjEiBeC_xHqqkZx_
} // FCStatLine::GetFormat.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatLine::SetFormat
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDiCpA_xHqqkZx_FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCmFiPiJiKpKiJlLiClHiCoJ_xHqqkZx_.
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	tli	: FCTextLineInfo_xZkqqHx_iNfMjBkCjBmMiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.02.17 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCStatLine::SetFormat (const FCTextLineInfo& tli)
{
	if (tli.dwMask & FDTL_FLAG_STARTINDENT)
		m_mmStartIndent = tli.mmStartIndent;	// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_RIGHTINDENT)
		m_mmRightIndent = tli.mmRightIndent;	// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgHiBeC_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_OFFSET)
		m_mmOffset = tli.mmOffset;				// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgHiBgJjAoGjDkKiNhDiCmJjBmOiClHiCoJiDeJiDhEiDfKiDgCiDgHjCgMiBgK_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_TABSTOPS)
		m_mmvTabs = tli.mmvTabs;				// _xZkqqHx_iDfOiDhFjEhKjHpBiBeC_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_ALIGNMENT)
		m_byAlignment = tli.byAlignment;		// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBgJiNlGjCiGiJjLiJeFiKpBiClJiBgK_xHqqkZx_
	if (tli.dwMask & FDTL_FLAG_LINEAFTER)
		m_nTwipLineAfter = tli.nTwipLineAfter;	// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmM_xHqqkZx_TWIPS_xZkqqHx_jAjEiBeC_xHqqkZx_
} // FCStatLine::SetFormat.

void FCStatLine::operator = (const FCEditLine& elEdit)
{
	/*----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFjDkPiClGjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----*/
	m_mmStartIndent	= elEdit.m_mmStartIndent;
	m_mmRightIndent	= elEdit.m_mmRightIndent;
	m_mmOffset		= elEdit.m_mmOffset;
	m_mmvTabs		= elEdit.m_mmvTabs;
	m_byAlignment	= elEdit.m_byAlignment;

	/*----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFiInJiCmIiCoJjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----*/
	m_byLineType			= elEdit.m_byLineType;
	m_nTwipLineAfter		= elEdit.m_nTwipLineAfter;

	FCEditCharVector::const_iterator i;
	i = elEdit.m_vEditChar.begin();

	SFontID		foidFont	= (*i).m_foidFont;
	WORD		wOffset		= (*i).m_wOffset;
	short		nAfterSpace	= (*i).m_nAfterSpace;
	COLORREF	crColor	= (*i).m_crColor;
//----- 01.02.12 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	BYTE		byUnderline = (*i).m_byUnderline;
	BYTE		byStrikeOut = (*i).m_byStrikeOut;
	BYTE		byCrossStat = (*i).m_byCrossStat;
//----- 01.02.12 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	m_vStatChar.push_back(FCStatChar(FDRCH_FONT, foidFont));
//	m_vStatChar.push_back(FCStatChar(FDRCH_OFFSET, wOffset));
//	m_vStatChar.push_back(FCStatChar(FDRCH_AFTERSPACE, nAfterSpace));
//	m_vStatChar.push_back(FCStatChar(FDRCH_SCOLOR, crColor));
//	m_vStatChar.push_back(FCStatChar(FDRCH_UNDERLINE, byUnderline));
//	m_vStatChar.push_back(FCStatChar(FDRCH_STRIKEOUT, byStrikeOut));
//	m_vStatChar.push_back(FCStatChar(FDRCH_CROSSSTAT, byCrossStat));
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	m_vStatChar.push_back(FCStatChar(FDRCH_FONT_AND_OFFSET, foidFont, wOffset));
	m_vStatChar.push_back(FCStatChar(FDRCH_COLORREF, crColor));
	m_vStatChar.push_back(FCStatChar(FDRCH_AFTERSPACE, nAfterSpace));
	m_vStatChar.push_back(FCStatChar(FDRCH_LINES_AND_CROSSSTAT, byUnderline, byStrikeOut, byCrossStat));
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

	for (; i != elEdit.m_vEditChar.end(); i++)
	{
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		if (foidFont != (*i).m_foidFont)
//		{
//			foidFont = (*i).m_foidFont;
//			m_vStatChar.push_back(FCStatChar(FDRCH_FONT, foidFont));
//		}
//		if (wOffset != (*i).m_wOffset)
//		{
//			wOffset = (*i).m_wOffset;
//			m_vStatChar.push_back(FCStatChar(FDRCH_OFFSET, wOffset));
//		}
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		if (foidFont != (*i).m_foidFont || wOffset != (*i).m_wOffset)
		{
			foidFont = (*i).m_foidFont;
			wOffset = (*i).m_wOffset;
			m_vStatChar.push_back(FCStatChar(FDRCH_FONT_AND_OFFSET, foidFont, wOffset));
		}
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
		if ((*i).m_mmfPreSpace != 0.0)
		{
			m_vStatChar.push_back(FCStatChar(FDRCH_PRESPACE, (*i).m_mmfPreSpace));
		}
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		if (nAfterSpace != (*i).m_nAfterSpace)
//		{
//			nAfterSpace = (*i).m_nAfterSpace;
//			m_vStatChar.push_back(FCStatChar(FDRCH_AFTERSPACE, nAfterSpace));
//		}
//		if (crColor != (*i).m_crColor)
//		{
//			crColor = (*i).m_crColor;
//			m_vStatChar.push_back(FCStatChar(FDRCH_SCOLOR, crColor));
//		}
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		if (crColor != (*i).m_crColor)
		{
			crColor = (*i).m_crColor;
			m_vStatChar.push_back(FCStatChar(FDRCH_COLORREF, crColor));
		}
		if (nAfterSpace != (*i).m_nAfterSpace)
		{
			nAfterSpace = (*i).m_nAfterSpace;
			m_vStatChar.push_back(FCStatChar(FDRCH_AFTERSPACE, nAfterSpace));
		}
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

//----- 01.02.15 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
		if (byUnderline != (*i).m_byUnderline || byStrikeOut != (*i).m_byStrikeOut ||
			byCrossStat != (*i).m_byCrossStat)
		{
			byUnderline = (*i).m_byUnderline;
			byStrikeOut = (*i).m_byStrikeOut;
			byCrossStat = (*i).m_byCrossStat;
			m_vStatChar.push_back(FCStatChar(FDRCH_LINES_AND_CROSSSTAT,
											byUnderline, byStrikeOut, byCrossStat));
		}
//----- 01.02.15 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
		m_vStatChar.push_back(FCStatChar((*i).m_wChar,
								(*i).m_mmfWidth, (*i).m_mmfAbcA, (*i).m_mmfAbcC));
	}
	m_mmY					= elEdit.m_mmY;
	m_mmfTMHeight			= elEdit.m_mmfTMHeight;
	m_mmfTMAscent			= elEdit.m_mmfTMAscent;
	m_mmfTMExternalLeading	= elEdit.m_mmfTMExternalLeading;

} // FCStatLine::operator = (const FCEditLine& elEdit).

void FCStatLine::operator = (const FCStatLine& sl)
{
	/*----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFjDkPiClGjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----*/
	m_mmStartIndent	= sl.m_mmStartIndent;
	m_mmRightIndent	= sl.m_mmRightIndent;
	m_mmOffset		= sl.m_mmOffset;
	m_mmvTabs		= sl.m_mmvTabs;
	m_byAlignment	= sl.m_byAlignment;

	/*----- _xZkqqHx_jAoGjDkKiNhDiBeBiMhAjBlBiNhDiCmFiInJiCmIiCoJjCgMiCpAiOjNiCmCiDiBiDjDiDgPjFmPjAjE_xHqqkZx_ -----*/
	m_byLineType			= sl.m_byLineType;
	m_nTwipLineAfter		= sl.m_nTwipLineAfter;
	m_vStatChar				= sl.m_vStatChar;
	m_mmY					= sl.m_mmY;
	m_mmfTMHeight			= sl.m_mmfTMHeight;
	m_mmfTMAscent			= sl.m_mmfTMAscent;
	m_mmfTMExternalLeading	= sl.m_mmfTMExternalLeading;
} // FCStatLine::operator = (const FCStatLine& sl).

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatLine::OutStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBkOjAkLiDgGiBfLiDfOiCmMiPgPjHmNiCpAiNhDiCkEiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ar	:_xZkqqHx_iPgPjHmNjAoGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.03.04 Fukushiro M. CArchive_xZkqqHx_iCkJiCoH_xHqqkZx_FCUndoArchive_xZkqqHx_iCmJjFmPiNfIiBeC_xHqqkZx_
 *************************************************************************/
void FCStatLine::OutStream (FCUndoArchive& ar) const
{
	ar << m_mmStartIndent;			// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	ar << m_mmRightIndent;			// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	ar << m_mmOffset;				// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	//----- _xZkqqHx_iDfOiDhFiCmMiImKjChFiCmMjHpBiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	ar << static_cast<WORD>(m_mmvTabs.size());
	mmetolVector::const_iterator iTab;
	for (iTab = m_mmvTabs.begin(); iTab != m_mmvTabs.end(); iTab++)
		ar << *iTab;
	//----- _xZkqqHx_iClLiCmMjBlMiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	ar << m_byAlignment;			// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgH_xHqqkZx_.
	ar << m_byLineType;				// _xZkqqHx_iNhDiCmMiDfOiDeDiDhG_xHqqkZx_(_xZkqqHx_jAoGjDkK_xHqqkZx_/_xZkqqHx_iMhAjBlB_xHqqkZx_)
	ar << m_nTwipLineAfter;		// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_
	//----- _xZkqqHx_jFlGiOjKjHpBiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	ar << static_cast<WORD>(m_vStatChar.size());
	FCStatCharVector::const_iterator i;
	for (i = m_vStatChar.begin(); i != m_vStatChar.end(); i++)
		(*i).OutStream(ar);
	//----- _xZkqqHx_iClLiCmMjBlMiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	ar << m_mmY;					// _xZkqqHx_iNhDiCmMiPoDiCmMiNmAjFfH_xHqqkZx_.
	ar << m_mmfTMHeight;			// _xZkqqHx_jFlGiOjKiCmMiNiCiClD_xHqqkZx_.
	ar << m_mmfTMAscent;			// _xZkqqHx_iDhIiBfLiDfIiDiJiDeDiDjDiCkJiCoHiNhDiCmMiPoDiCnMiCmFiCmMiNiCiClD_xHqqkZx_.
	ar << m_mmfTMExternalLeading;	// _xZkqqHx_jFlGiOjKiCmMiJlKiCmMiMiEiKnE_xHqqkZx_.
} // FCStatLine::OutStream.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatLine::InStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBkOjAkLiDgGiBfLiDfOiCmMjDpMjHmNiCpAiNhDiCkEiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ar	:_xZkqqHx_jDpMjHmNjAoGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.03.04 Fukushiro M. CArchive_xZkqqHx_iCkJiCoH_xHqqkZx_FCUndoArchive_xZkqqHx_iCmJjFmPiNfIiBeC_xHqqkZx_
 *************************************************************************/
void FCStatLine::InStream (FCUndoArchive& ar)
{
	ar >> m_mmStartIndent;			// _xZkqqHx_jAoGjDkKiNhDiCmMiNlGiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	ar >> m_mmRightIndent;			// _xZkqqHx_jAoGjDkKiBeFiMhAjBlBiNhDiCmMiJeFiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	ar >> m_mmOffset;				// _xZkqqHx_iMhAjBlBiNhDiCmMiDeDiDjDiDgGiDjDiDgH_xHqqkZx_.
	//----- _xZkqqHx_iDfOiDhFiCmMiImKjChFiCmMjHpBiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
	m_mmvTabs.clear();
	WORD wSize;
	mmetol mmTab;
	ar >> wSize;
	long lC;
	for (lC = 0; lC < wSize; lC++)
	{
		ar >> mmTab;
		m_mmvTabs.push_back(mmTab);
	}
	//----- _xZkqqHx_iClLiCmMjBlMiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
	ar >> m_byAlignment;			// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgH_xHqqkZx_.
	ar >> m_byLineType;				// _xZkqqHx_iNhDiCmMiDfOiDeDiDhG_xHqqkZx_(_xZkqqHx_jAoGjDkK_xHqqkZx_/_xZkqqHx_iMhAjBlB_xHqqkZx_)
	ar >> m_nTwipLineAfter;		// _xZkqqHx_iNhDiKnEiBgJiNhDiCmMiJlKiBgKiCmMiDhMiDeDiDjDiDgHjAjEiBeC_xHqqkZx_
	//----- _xZkqqHx_jFlGiOjKjHpBiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
	m_vStatChar.clear();
	FCStatChar sc;
	ar >> wSize;
	for (lC = 0; lC < wSize; lC++)
	{
		sc.InStream(ar);
		m_vStatChar.push_back(sc);
	}
	//----- _xZkqqHx_iClLiCmMjBlMiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
	ar >> m_mmY;					// _xZkqqHx_iNhDiCmMiPoDiCmMiNmAjFfH_xHqqkZx_.
	ar >> m_mmfTMHeight;			// _xZkqqHx_jFlGiOjKiCmMiNiCiClD_xHqqkZx_.
	ar >> m_mmfTMAscent;			// _xZkqqHx_iDhIiBfLiDfIiDiJiDeDiDjDiCkJiCoHiNhDiCmMiPoDiCnMiCmFiCmMiNiCiClD_xHqqkZx_.
	ar >> m_mmfTMExternalLeading;	// _xZkqqHx_jFlGiOjKiCmMiJlKiCmMiMiEiKnE_xHqqkZx_.
} // FCStatLine::InStream.

BOOL FCStatLine::operator == (const FCStatLine& sl) const
{
	if (!almosteq(m_mmStartIndent, sl.m_mmStartIndent)) return FALSE;
	if (!almosteq(m_mmRightIndent, sl.m_mmRightIndent)) return FALSE;
	if (!almosteq(m_mmOffset, sl.m_mmOffset)) return FALSE;
	//----- m_mmvTabs_xZkqqHx_iCpAjEoEiKhC_xHqqkZx_ -----
	if (m_mmvTabs.size() != sl.m_mmvTabs.size()) return FALSE;
	mmetolVector::const_iterator imm0, imm1;
	for (imm0 = m_mmvTabs.begin(), imm1 = sl.m_mmvTabs.begin();
		 imm0 != m_mmvTabs.end(); imm0++, imm1++)
		if (!almosteq(*imm0, *imm1)) return FALSE;
	//----- _xZkqqHx_iClLiCmMjBlMiCpAjEoEiKhC_xHqqkZx_ -----
	if (m_byAlignment != sl.m_byAlignment) return FALSE;
	if (m_byLineType != sl.m_byLineType) return FALSE;
	if (m_nTwipLineAfter != sl.m_nTwipLineAfter) return FALSE;
	//----- m_vStatChar_xZkqqHx_iCpAjEoEiKhC_xHqqkZx_ -----
	if (m_vStatChar.size() != sl.m_vStatChar.size()) return FALSE;
	FCStatCharVector::const_iterator ic0, ic1;
	for (ic0 = m_vStatChar.begin(), ic1 = sl.m_vStatChar.begin();
		 ic0 != m_vStatChar.end(); ic0++, ic1++)
		if (*ic0 != *ic1) return FALSE;
	//----- _xZkqqHx_iClLiCmMjBlMiCpAjEoEiKhC_xHqqkZx_ -----
	if (!almosteq(m_mmY, sl.m_mmY)) return FALSE;
	if (!almosteq(m_mmfTMHeight, sl.m_mmfTMHeight)) return FALSE;
	if (!almosteq(m_mmfTMAscent, sl.m_mmfTMAscent)) return FALSE;
	if (!almosteq(m_mmfTMExternalLeading, sl.m_mmfTMExternalLeading)) return FALSE;
	return TRUE;
} // FCStatLine::operator ==.

BOOL FCStatLine::operator != (const FCStatLine& sl) const
{
	return !(FCStatLine::operator == (sl));
} // FCStatLine::operator !=.

/////////////////////////////////////////////////////////////////////////////
// FCStatLineVector_xZkqqHx_iKnGjAjEiBeC_xHqqkZx_

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatLineVector::OutStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgGiBfLiDfOiCpAiDfIiDgHiDiKiBfLiDiAiPgPjHmNiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ar	:_xZkqqHx_iPgPjHmNjHhAiDeBiBfLiDeKiDeDiDhFiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.05.27 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCStatLineVector::OutStream (FCUndoArchive& ar) const
{
	//----- _xZkqqHx_jFlGiOjKjHpBiPoOjFpBiCpAiPgPjHmN_xHqqkZx_ -----
	ar << static_cast<long>(size());
	FCStatLineVector::const_iterator iL;
	for (iL = begin(); iL != end(); iL++) (*iL).OutStream(ar);
} // FCStatLineVector::OutStream.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	FCStatLineVector::InStream
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfIiDgHiDiKiBfLiDiAiCkJiCoHiDgGiBfLiDfOiCpAjDpMjHmNiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ar	:_xZkqqHx_jDpMjHmNjHhAiDeBiBfLiDeKiDeDiDhFiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.05.27 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void FCStatLineVector::InStream (FCUndoArchive& ar)
{
	//----- _xZkqqHx_jFlGiOjKjHpBiPoOjFpBiCpAjDpMjHmN_xHqqkZx_ -----
	// _xZkqqHx_iKpJjBlGiCmMjFlGiOjKjHpBiPoOjFpBiCpAiNoNiPjMiBeC_xHqqkZx_
	clear();
	long lSize;
	ar >> lSize;
	while (0 < lSize--)
	{
		push_back(FCStatLine());
		back().InStream(ar);
	}
} // FCStatLineVector::InStream.

/////////////////////////////////////////////////////////////////////////////
// CFCWndRichEdit

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CFCWndRichEdit
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDjDiDfIiDgHiDiJiDeOiDfOiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.26 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
CFCWndRichEdit::CFCWndRichEdit ()
{
	m_vEditLine.clear();
	// _xZkqqHx_iMlLiNnNiCmMjFlGiOjKiDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
	memset(&m_fciCurExtCodeFormat, 0, sizeof(m_fciCurExtCodeFormat));
	// _xZkqqHx_iMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
	memset(&m_fciCurStdCodeFormat, 0, sizeof(m_fciCurStdCodeFormat));
	// _xZkqqHx_jBfDiJoGjGmKiDeHiDgGiDeCiDfOiDiCiBfLiDgIiBeI_xHqqkZx_
	m_bIsFullScreen = FALSE;
} // CFCWndRichEdit::CFCWndRichEdit.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::~CFCWndRichEdit
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgGiDfIiDgHiDiJiDeOiDfOiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.26 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
CFCWndRichEdit::~CFCWndRichEdit ()
{
} // CFCWndRichEdit::~CFCWndRichEdit.

//----------<NOT EXPORT TO VIEWER>-----------

BEGIN_MESSAGE_MAP(CFCWndRichEdit, BASE_CLASS)
	//{{AFX_MSG_MAP(CFCWndRichEdit)
	ON_WM_CREATE()
	ON_WM_DESTROY()
	ON_WM_PAINT()
	ON_WM_SETFOCUS()
	ON_WM_KILLFOCUS()
	ON_WM_LBUTTONDOWN()
	ON_WM_GETDLGCODE()
	ON_WM_KEYDOWN()
	ON_WM_CHAR()
	ON_WM_LBUTTONUP()
	ON_WM_MOUSEMOVE()
	ON_WM_CONTEXTMENU()
	ON_WM_MBUTTONDOWN()
	ON_WM_MBUTTONUP()
	ON_WM_MBUTTONDBLCLK()
	//}}AFX_MSG_MAP
//	ON_MESSAGE(WM_IME_CHAR, OnImeChar)
	ON_MESSAGE(WM_IME_STARTCOMPOSITION, OnImeStartcomposition)
	ON_MESSAGE(WM_IME_ENDCOMPOSITION, OnImeEndcomposition)
	ON_MESSAGE(WM_USER_RULER_MARKER, OnRulerMarker)
	ON_MESSAGE(WM_USER_CURRENT_LINE_UPDATED, OnCurrentLineUpdated)
	ON_MESSAGE(WM_IME_COMPOSITION, OnImeComposition)
//----- 00.08.05 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	ON_MESSAGE(WM_IME_COMPOSITIONFULL, OnImeCompositionfull)
//	ON_MESSAGE(WM_IME_CONTROL, OnImeControl)
//	ON_MESSAGE(WM_IME_KEYDOWN, OnImeKeydown)
//	ON_MESSAGE(WM_IME_KEYUP, OnImeKeyup)
//	ON_MESSAGE(WM_IME_NOTIFY, OnImeNotify)
//	ON_MESSAGE(WM_IME_SELECT, OnImeSelect)
//	ON_MESSAGE(WM_IME_SETCONTEXT, OnImeSetcontext)
//----- 00.08.05 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
END_MESSAGE_MAP()

//----------</NOT EXPORT TO VIEWER>-----------

/////////////////////////////////////////////////////////////////////////////
// _xZkqqHx_iDiGiBfLiDfFiDfCiBfLiDgI_xHqqkZx_.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::Create
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeOiDiJiDfIjAlGjAkMiBeCiClBiCmMiDeOiDiJiDfIiCmMjDgPjIfOiCmG_xHqqkZx_CWnd::CreateEx_xZkqqHx_iCmMiOmAiNhDiCpAiNhDiCkEiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	dwExStyle	: _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCmMiKgHjCkDiDfIiDfOiDeDiDiL_xHqqkZx_
 *			dwStyle		: _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCmMjFfHiPiAiDfIiDfOiDeDiDiL_xHqqkZx_
 *			rect		: _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCmMiImKjChFiBeFiDfEiDeDiDfJ_xHqqkZx_
 *			pParentWnd	: _xZkqqHx_jAgFiDeFiDeCiDjDiDgIiDeF_xHqqkZx_
 *			nID			: _xZkqqHx_iClBiCmMjFjEjFgJiCmM_xHqqkZx_ID
 *			pContext	: 
 *************************************************************************/
BOOL CFCWndRichEdit::Create (DWORD dwExStyle, DWORD dwStyle,
							const RECT& rect, CWnd* pParentWnd,
							UINT nID, CCreateContext* pContext)
{
	//----- _xZkqqHx_iDeOiDiJiDfIiCpAjDgPjIfO_xHqqkZx_ -----
	if (m_lpszClassName == NULL)
	{
    	m_lpszClassName = ::AfxRegisterWndClass(CS_HREDRAW | CS_VREDRAW,
							::FFGetApp()->LoadStandardCursor(IDC_IBEAM));
	}
	if (CreateEx(dwExStyle, m_lpszClassName, _T(""), dwStyle,
					rect.left, rect.top,
					rect.right - rect.left, rect.bottom - rect.top,
					pParentWnd->GetSafeHwnd(), NULL, NULL))
	{
		SetDlgCtrlID(nID);	// _xZkqqHx_iOhBiDeFiDeCiDjDiDgIiDeFiCmGiClFiCmEjDgPjIfOiBeC_xHqqkZx_
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		ClearAll();
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		// _xZkqqHx_iClBiClBiCmF_xHqqkZx_ ClearAll() _xZkqqHx_iCmNiOmAiNhDiClFiCmIiCkCiBeCjGkCiClO_xHqqkZx_g_pEnv_xZkqqHx_iCkKiPiJiKpKiJlLiClDiCoKiCmE_xHqqkZx_
		// _xZkqqHx_iCkCiCmIiCkCiClNiCnPiBeBiDhEiDeIiDjDiDgHjDgPjIfOiCkKiNhDiCoNiCoKiCmEiCkCiCmIiCkCiBeC_xHqqkZx_
//----- 01.02.15 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
		return TRUE;
	}
	return FALSE;
} // CFCWndRichEdit::Create.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetSpecKeyCallback
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jDmBjFmKiCmIiDeMiBfLiBgJ_xHqqkZx_ESC_xZkqqHx_jDjJiBgKiCkKiJjPiClDiCoKiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJ_xHqqkZx_Callback_xZkqqHx_iKnGjAjEiCpA_xHqqkZx_
 *			_xZkqqHx_jDgPjIfOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	fncCallback	: Callback_xZkqqHx_iKnGjAjE_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetSpecKeyCallback (FDRichSpecKeyCallback fncCallback)
{
	m_fncCallback = fncCallback;
} // CFCWndRichEdit::SetSpecKeyCallback.

//----- 01.04.26 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetTargetObject
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFnCiPfHjBmOiPnLiCmMjFjEjFgJiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	ojpTarget	:_xZkqqHx_jFjEjFgJ_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::SetTargetObject (const FCObjFigure* ojpTarget)
//{
//	m_ojpTarget = ojpTarget;
//} // CFCWndRichEdit::SetTargetObject.
//----- 01.04.26 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::PenBrushInit
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iKePiMgAjApMiBeBjEhHiMgJjDgIjCnHiClFjHhAiCmMiDhJiDjDiBeFiDhFiDiJiDfGiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.26 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::PenBrushInit (	PenStyleID psidPenStyle,
									fmmetol mmfPenWeight,
									SColorID scidPenBackSColor,
									SColorID scidBrushBackSColor)
{
	m_psidPenStyle			= psidPenStyle;
	m_mmfPenWeight			= mmfPenWeight;
	m_scidPenBackSColor		= scidPenBackSColor;
	m_scidBrushBackSColor	= scidBrushBackSColor;
//----- 06.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDeHiDgGiDeCiDfOjEhHiMgJjAeGiCpAjAnNjCoIiBeC_xHqqkZx_
	if (m_scidBrushBackSColor == FD_S_COLOR_TRANSPARENT)
		m_crBackground = g_pReg->GetOptiSheetColor();
	else
		m_crBackground = ::OptiColor(g_pEnv->scid2cref(m_scidBrushBackSColor));
//----- 06.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::PenBrushInit.
//----- 01.04.26 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetMaskPolygon
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCmJiDhNiDfIiDeOiCpAiNhDiCkEiClNiCnPiCmMiDhMiDiKiDfDiDjDiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmptpPoly	:_xZkqqHx_iDhMiDiKiDfDiDjDjEhKjHpB_xHqqkZx_
 *			lPoly		:mmptpPoly_xZkqqHx_iCmMiDfEiDeDiDfJ_xHqqkZx_.
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.10.28 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetMaskPolygon (DBLPoint* mmptpPoly, long lPoly, const DBLPoint& mmptLeftTop)
{
//----- 05.02.20 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	// m_mmptPoly_xZkqqHx_iCpAiDeOiDiKiDeBiBeC_xHqqkZx_
//	m_vmmptPoly.clear();
//	if (mmptpPoly != NULL)
//	{
//		// mmptpPoly_xZkqqHx_iCpAiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
//		m_vmmptPoly.insert(m_vmmptPoly.end(), mmptpPoly, mmptpPoly + lPoly);
//		// mmptpPoly_xZkqqHx_iCmJiKePjAnKiClHiCoJiDhEiDiMiBfLiDiAiCpAiMhGiOfKiBeC_xHqqkZx_
//		DBLRect mmrtFrame;
//		::FFCalcFrame(mmrtFrame, m_vmmptPoly.size(), m_vmmptPoly.begin());
//		//----- mmptpPoly_xZkqqHx_iCmMjEhKjHpBiCpAiBeBiKePjAnKiDhEiDiMiBfLiDiAiCmMiNlGiPoDiCkKiCePiCmJiCmIiCoJiCoGiCkEjAlDiLeLiJlL_xHqqkZx_ -----
//		DBLPointVector::iterator iPt;
//		for (iPt = m_vmmptPoly.begin(); iPt != m_vmmptPoly.end(); iPt++)
//		{
//			(*iPt).x -= mmrtFrame.left;
//			(*iPt).y -= mmrtFrame.top;
//		}
//	}
//----- 05.02.20 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	// m_mmptPoly_xZkqqHx_iCpAiDeOiDiKiDeBiBeC_xHqqkZx_
	m_vmmptPoly.clear();
	if (mmptpPoly != NULL)
	{
		// mmptpPoly_xZkqqHx_iCpAiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
		m_vmmptPoly.insert(m_vmmptPoly.end(), mmptpPoly, mmptpPoly + lPoly);
		// mmptpPoly_xZkqqHx_iCmJiKePjAnKiClHiCoJiDhEiDiMiBfLiDiAiCpAiMhGiOfKiBeC_xHqqkZx_
		DBLRect mmrtFrame;
		::FFCalcFrame(mmrtFrame, m_vmmptPoly.size(), m_vmmptPoly.begin());
		//----- mmptpPoly_xZkqqHx_iCmMjEhKjHpBiCpAiBeBiKePjAnKiDhEiDiMiBfLiDiAiCmMiNlGiPoDiCkKiCePiCmJiCmIiCoJiCoGiCkEjAlDiLeLiJlL_xHqqkZx_ -----
		DBLPointVector::iterator iPt;
		for (iPt = m_vmmptPoly.begin(); iPt != m_vmmptPoly.end(); iPt++)
			*iPt -= DBLPoint(mmrtFrame.left, mmrtFrame.top);
		// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCpAiInKjDkOiBeC_xHqqkZx_
		MoveWindowMM(DBLRect(	mmptLeftTop.x,
								mmptLeftTop.y,
								mmptLeftTop.x + mmrtFrame.Width(),
								mmptLeftTop.y + mmrtFrame.Height()));
		// _xZkqqHx_iNmFiPiJiCmJjAnNjCoIiClDiCoKiClNiClBiCmMiDeFiDeCiDjDiDgIiDeFiCmMiDfEiDeDiDfJiBeC_xHqqkZx_
		m_mmrtWindowOrig = m_mmrtWindow;
		// _xZkqqHx_iNmFiPiJiCmJjAnNjCoIiClDiCoKiClNiDhNiDfIiDeOiDhMiDiKiDfDiDjDjEhKjHpBiBeCiDeHiDgGiDeCiDfOiDeFiDeCiDjDiDgIiDeFiNlGiPoD_xHqqkZx_=(0,0)_xZkqqHx_iCmJjAlDiLeLiJlLiBeC_xHqqkZx_
		m_vmmptPolyOrig = m_vmmptPoly;
	}
//----- 05.02.20 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::SetMaskPolygon.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ClearMaskPolygon
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAiPmBiLiOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.06.22 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::ClearMaskPolygon ()
{
	m_vmmptPoly.clear();
// 02.05.30 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)
//	m_vlgptPoly.clear();
} // CFCWndRichEdit::ClearMaskPolygon.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RotateBackgroundColor
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jEhHiMgJjAeGiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jEhHiMgJjAeGiCpAiDgGiDhEiDeIiDiLiDgHjAeG_xHqqkZx_ -> _xZkqqHx_iDePiDiMiBfL_xHqqkZx_ -> _xZkqqHx_iNjF_xHqqkZx_ -> _xZkqqHx_jEjC_xHqqkZx_ -> _xZkqqHx_jAmC_xHqqkZx_ -> _xZkqqHx_jAnE_xHqqkZx_ _xZkqqHx_iCmG_xHqqkZx_
 *			_xZkqqHx_jAnIiCoIjBnGiCkGiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.03.25 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RotateBackgroundColor ()
{
	// _xZkqqHx_iDgGiDhEiDeIiDiLiDgHiCmMiDeHiDgGiDeCiDfOjEhHiMgJjAeGiCpAiOoGjDlOiBeC_xHqqkZx_
	COLORREF crDefault;
	if (m_scidBrushBackSColor == FD_S_COLOR_TRANSPARENT)
		crDefault = g_pReg->GetOptiSheetColor();
	else
		crDefault = ::OptiColor(g_pEnv->scid2cref(m_scidBrushBackSColor));

	const COLORREF crRotate[] =
	{
// 06.05.22 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//		FD_COLREF_GRAY,
		FD_COLREF_DIM_GRAY,
		FD_COLREF_BLACK,
		FD_COLREF_WHITE,
		FD_COLREF_BLUE,
		FD_COLREF_RED
	};
	// _xZkqqHx_jAeGiCmMiDiNiBfLiDgFiBfLiDfGiDiHiDjDjEhKjHpBiBeC_xHqqkZx_
	vector<COLORREF> vColorRotation;
	// _xZkqqHx_iDgGiDhEiDeIiDiLiDgHjAeGiCpAjAnNjCoIiBeC_xHqqkZx_
	vColorRotation.push_back(crDefault);
	for (int iC = 0; iC != sizeof(crRotate) / sizeof(crRotate[0]); iC++)
	{
		// _xZkqqHx_iDgGiDhEiDeIiDiLiDgHjAeGiCmGiCmNiCmBiCkLiCoIiInJiCmIiCoJjAeGiClOiCkPiCpAiDiNiBfLiDgFiBfLiDfGiDiHiDjDiCmJjCmHiJmBiBeC_xHqqkZx_
		double dR0 = (double)GetRValue(crDefault);
		double dG0 = (double)GetGValue(crDefault);
		double dB0 = (double)GetBValue(crDefault);
		double dR1 = (double)GetRValue(crRotate[iC]);
		double dG1 = (double)GetGValue(crRotate[iC]);
		double dB1 = (double)GetBValue(crRotate[iC]);
		if (1200 < POW2(dR0 - dR1) + POW2(dG0 - dG1) + POW2(dB0 - dB1))
			vColorRotation.push_back(crRotate[iC]);
	}
	// _xZkqqHx_iMlLiNnNiCmMjAeGiCpAiDiNiBfLiDgFiBfLiDfGiDiHiDjDjEhKjHpBiCmJiMkJiCmCiCkPiCoJiBeC_xHqqkZx_
	vector<COLORREF>::const_iterator iCol = std::find(vColorRotation.begin(), vColorRotation.end(), m_crBackground);
	if (iCol == vColorRotation.end())
	{
		iCol = vColorRotation.begin();
	} else
	{
		iCol++;
		if (iCol == vColorRotation.end())
			iCol = vColorRotation.begin();
	}
	// _xZkqqHx_jAfGiClFiCkCjEhHiMgJjAeGiCpAjAnNjCoIiBeC_xHqqkZx_
	m_crBackground = *iCol;
	// _xZkqqHx_jBfDiJoGjGmKiCpAiNmEjFgAiJoGiBeC_xHqqkZx_
	if (::IsWindow(m_hWnd) && IsWindowVisible())
		Invalidate();
} // CFCWndRichEdit::RotateBackgroundColor.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::IsFullScreenEditMode
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBfDiJoGjGmKiDeHiDgGiDeCiDfOiDiCiBfLiDgIiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.26 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::IsFullScreenEditMode () const
{
	return m_bIsFullScreen;
} // CFCWndRichEdit::IsFullScreenEditMode.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetFullScreenEditMode
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBfDiJoGjGmKiDeHiDgGiDeCiDfOiDiCiBfLiDgIiCpAjAnNjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.26 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetFullScreenEditMode (BOOL bIsFullMode)
{
	// _xZkqqHx_iDiCiBfLiDgIiCkKjDkPiClGiCmIiCoHjFjMiLeBiBeC_xHqqkZx_
	if (m_bIsFullScreen == bIsFullMode) return;
	m_bIsFullScreen = bIsFullMode;
// 05.03.01 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (IsWindowVisible())
	if (::IsWindow(m_hWnd) && IsWindowVisible())
	//----- _xZkqqHx_iDeHiDgGiDeCiDfOiCkKjFfMiOkGjCiGiCmMiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_jBfDiJoGjGmKiDiCiBfLiDgIiCmMjFfMiOkGiPiIjHjNiBeC_xHqqkZx_
		UpdateFullScreenMode(m_bIsFullScreen);
		// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiBeC_xHqqkZx_
		CalcLineAll();
		// _xZkqqHx_iDiLiBfLiDiJiBfLiCmMjAnNjCoIiBeC_xHqqkZx_
		FFGetMainWnd()->HRuler()->SetTextRange(this, m_mmrtWindow.left + m_mmMarginL,
												m_mmrtWindow.right - m_mmMarginR);
		FFGetMainWnd()->VRuler()->SetTextRange(this, m_mmrtWindow.top + m_mmMarginT,
												m_mmrtWindow.bottom - m_mmMarginB);
		// _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiNmEiMhGiOfKiBeCjDkPiOjOiCmJiDiLiBfLiDiJiBfLiCmMjFfMiOkGiCoAiNfIjAfGiBeC_xHqqkZx_
		m_mmCaretX = RepositionCaret();
	}
} // CFCWndRichEdit::SetFullScreenEditMode.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::IsTextOver
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCkKiDeJiBfLiDgPiBfLiClFiCmEiCkCiCoJiCkJiCmHiCkEiCkJiCpAjClCiCnHiCmEjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDeJiBfLiDgPiBfLiClFiCmEiCkCiCoJiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.27 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::IsTextOver () const
{
	// _xZkqqHx_iNmFiMoDiCmMiNhDiCkKiDeJiBfLiDgPiBfLiCmIiCoHiCmO_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
	if (m_mmrtWindow.Height() - m_mmMarginB <
		m_vEditLine.back().m_mmY + m_vEditLine.back().m_mmfTMHeight +
		m_vEditLine.back().m_mmfTMExternalLeading) return TRUE;
	return FALSE;
} // CFCWndRichEdit::IsTextOver.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcEnoughSizeRatio
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoJiDeHiDgGiDeCiDfOiCmMiDfEiDeDiDfJiCpAiMhGiOfKiClFiBeBiMlLiNnNiCmMiDfEiDeDiDfJiCmJjBmOiClFiCmE_xHqqkZx_
 *			_xZkqqHx_iCmHiCoKiClOiCkPiKgHjBoFiClHiCoJiCkJiCmMjEoEjHkGiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	dRatioHorz	:_xZkqqHx_iJkBjFpLiMpMiCmMiKgHjBoFjHkGiCpAjFnEiClHiBeC_xHqqkZx_
 *			dRatioVert	:_xZkqqHx_iPgDjFpLiMpMiCmMiKgHjBoFjHkGiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iOfKiPgPiCmJiOlIjEhDiClFiClNiPoKiNiHiCmN_xHqqkZx_FALSE_xZkqqHx_iBeC_xHqqkZx_
 *			_xZkqqHx_jAiFjFlNjFpLiMpMiCmMiCnNiCmMiDiKiDfEiDeDiDfJiCmMiPoKiNiHiBeBiCkCiCkNiCoHjBoFiCkLiCkNiClFiCmEiCoA_xHqqkZx_
 *			_xZkqqHx_jFlGiOjKiCkKjDpMiCoHiCmIiCkCiPoKiNiHiCkKiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_jDoAjFjEiCmMiDgGiBfLiDfOiCpAiPjBiCkLiKlHiCkGiCoJiCmMiCmFiBeBiClBiCmMiKnGjAjEiOmAiNhDiImIiNhOiCmNiDfEiDeDiDfJiBeB_xHqqkZx_
 *			_xZkqqHx_iDiMiDeDiDeBiDeFiDgHiKnGjIeBiCmMiPoOjFpBiCkKjFmPiNfIiClDiCoKiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJiBeBiDhMiDiKiDfDiDjDiCkKjAnNjCoIiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jFjEjFgJiDfEiDeDiDfJiCmJiCoGiCoJiDiMiDeDiDeBiDeFiDgHiCpAiMlFjGkHiCmJiMhGiOfKiClFiBeBjAlDiKgNiCmIiKgHjBoFiPgLiPkMjEoEiCpAjFnEiClHiBeC_xHqqkZx_
 * 
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.27 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CalcEnoughSizeRatio (	double& dRatioHorz,
											double& dRatioVert,
											const FCObjFigure* pObj)
{
	// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAiOoGjDlOiClHiCoJiClNiCnPiCmMjFjEjFgJiCpAiNoMjAkMiBeC_xHqqkZx_
	auto_ptr<FCObjDynabase> pNewObj(pObj->Duplicate());
	// _xZkqqHx_jDoAjFjEiDgFiDeMiDfIiDgHiCmNiBeBiDiKiDfEiDeDiDfJiOjOiCmMiMhGiOfKiDiNiDfIiCmJiCmIiCoJiClNiCnPiNoNiPjMiBeC_xHqqkZx_
	if (pNewObj->GetRichText() != NULL)
		delete pNewObj->SetRichText(NULL);

	// _xZkqqHx_iDiKiDfEiDeDiDfJjBePiCmMiKoOiPiAiDhEiDiMiBfLiDiAiBeC_xHqqkZx_
	DBLRect mmrtFrameOrig;
	if (pNewObj->CanRotate())
	//----- _xZkqqHx_jFjEjFgJiCkKiJpBjDfNiJmCjEfMiCmFiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_iKoOiPiAiDhEiDiMiBfLiDiAiDfEiDeDiDfJiCpAiOoGjDlOiBeC_xHqqkZx_
		pNewObj->Rotate(-pObj->GetTextAngle(), DBLPoint(0, 0));
		mmrtFrameOrig = pNewObj->GetResizeFrame();
		pNewObj->Rotate(pObj->GetTextAngle(), DBLPoint(0, 0));
	} else
	//----- _xZkqqHx_jFjEjFgJiCkKiJpBjDfNjFhDiJmCjEfMiCmFiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_iKoOiPiAiDhEiDiMiBfLiDiAiDfEiDeDiDfJiCpAiOoGjDlOiBeC_xHqqkZx_
		mmrtFrameOrig = pNewObj->GetResizeFrame();
	}

//----- 05.03.04 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDiKiDfEiDeDiDfJiMmFjCoIjDfPiCpAiLiBiCnPiCoJiClNiCnPiCmMiDhEiDiMiBfLiDiAiBeC_xHqqkZx_
//	DBLRect mmrtFixFrame;
//	if (pNewObj->CanRotate())
//	//----- _xZkqqHx_jFjEjFgJiCkKiJpBjDfNiJmCjEfMiCmFiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
//		mmrtFixFrame = mmrtFrameOrig;
//	} else
//	//----- _xZkqqHx_jFjEjFgJiCkKiJpBjDfNjFhDiJmCjEfMiCmFiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
//		// _xZkqqHx_iJpBjDfNiClFiCmEiCkCiCmIiCkCjFjEjFgJiCmMiDhEiDiMiBfLiDiAiCpAiOoGjDlOiClFiBeBiClLiCoKiCpAiJpBjDfNiClDiClJiCmE_xHqqkZx_
//		// _xZkqqHx_iKePjAnKiClHiCoJiDhEiDiMiBfLiDiAiCpAiJpBjDfNiMoDiCmMiDfEiDeDiDfJiCmGiClFiCmEiOoGjDlOiClHiCoJiBeC_xHqqkZx_
//		DBLPoint mmpta4[4];
//		mmrtFrameOrig.Get4Polygon(mmpta4);
//		// _xZkqqHx_iDhNiDfIiDeOjFjEjFgJiCmMiDhMiDiKiDfDiDjDiCpAiDgFiDeMiDfIiDgHjFjEjFgJiCmMiJpBjDfNjFkKiLhEjFmPiKlHiBeC_xHqqkZx_
//		::RotateConv(mmpta4, 4,
//					sin(-pObj->GetTextAngle() * M_PI),
//					cos(-pObj->GetTextAngle() * M_PI),
//					0, 0);
//		::FFCalcFrame(mmrtFixFrame, 4, mmpta4);
//	}
//	// _xZkqqHx_iDiKiDfEiDeDiDfJiOjOiCmMiMmFjCoIjDfPiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
//	mmptFixPoint.SetPoint(0,0);
//	switch (GetResizeHorz())
//	{
//	case FD_RPT_H_LEFT:	// _xZkqqHx_jFjEjFgJiCmMiNlGjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//		mmptFixPoint.x = mmrtFixFrame.left;
//		break;
//	case FD_RPT_H_CENTER:	// _xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//		mmptFixPoint.x = (mmrtFixFrame.left + mmrtFixFrame.right) / 2.0;
//		break;
//	case FD_RPT_H_RIGHT:	// _xZkqqHx_jFjEjFgJiCmMiJeFjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//		mmptFixPoint.x = mmrtFixFrame.right;
//		break;
//	}
//	switch (GetResizeVert())
//	{
//	case FD_RPT_V_TOP:		// _xZkqqHx_jFjEjFgJiCmMiPoDjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//		mmptFixPoint.y = mmrtFixFrame.top;
//		break;
//	case FD_RPT_V_CENTER:	// _xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//		mmptFixPoint.y = (mmrtFixFrame.top + mmrtFixFrame.bottom) / 2.0;
//		break;
//	case FD_RPT_V_BOTTOM:	// _xZkqqHx_jFjEjFgJiCmMiJlKjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//		mmptFixPoint.y = mmrtFixFrame.bottom;
//		break;
//	}
//	// _xZkqqHx_iDiKiDfEiDeDiDfJiOjOiCmMiMmFjCoIjDfPiCpAiJpBjDfNiClFiCmEiLiBiCnPiCoJiBeC_xHqqkZx_
//	::RotateConv(mmptFixPoint,
//				sin(pObj->GetTextAngle() * M_PI),
//				cos(pObj->GetTextAngle() * M_PI),
//				0, 0);
//----- 05.03.04 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

	// _xZkqqHx_iDhEiDiMiBfLiDiAiNlGiPoDiCpAiMlEjDfPiCmJiInKjDkOiBeCiJpBjDfNiCoCiDiKiDfEiDeDiDfJiCmFiNmAjFfHjCgMiCkKjBoFiCkLiCkNiCmIiCoIiJnPiCkMiCmIiCkCiCoGiCkEiCmJiClHiCoJiClNiCnPiBeC_xHqqkZx_
	mmrtFrameOrig -= DBLPoint(mmrtFrameOrig.left, mmrtFrameOrig.top);

	WORD wResizeKind = 0;
	// _xZkqqHx_jAiFjFlNjFpLiMpMiCmJiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
// 05.05.03 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (GetResizeHorz() != FD_RPT_NONE)
	if ((GetFixResize() & FD_RPT_H_MASK) != FD_RPT_NONE)
		wResizeKind |= 1;
	// _xZkqqHx_jAiCjClMjFpLiMpMiCmJiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
// 05.05.03 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (GetResizeVert() != FD_RPT_NONE)
	if ((GetFixResize() & FD_RPT_V_MASK) != FD_RPT_NONE)
		wResizeKind |= 2;
	if (wResizeKind == 0)
	//----- _xZkqqHx_jAiFjFlNjFpLiMpMiBeBjAiCjClMjFpLiMpMiCmGiCoAiDiKiDfEiDeDiDfJiClFiCmIiCkCiPoKiNiH_xHqqkZx_ -----
	{
		dRatioHorz = 1.0;
		dRatioVert = 1.0;
		return TRUE;
	}

	// _xZkqqHx_iCfAiBeE_xHqqkZx_	_xZkqqHx_iCnMiClIiBeBiDgFiDeMiDfIiDgHiCkKjBfDiCmEiOpLiCnMiCoJiDfEiDeDiDfJiCpAiMhGiOfKiClHiCoJiBeCiClLiCmMiJnPjCpGiCmFiBeB_xHqqkZx_
	//		_xZkqqHx_iDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoHiCmIiCkCiNmFjBoFiCmMiDfEiDeDiDfJiBeBiDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoJ_xHqqkZx_
	//		_xZkqqHx_iNmFiPkMiCmMiDfEiDeDiDfJiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
	// _xZkqqHx_iCfBiBeE_xHqqkZx_	_xZkqqHx_iDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoHiCmIiCkCiNmFjBoFiCmMiDfEiDeDiDfJiBeBiDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoJ_xHqqkZx_
	//		_xZkqqHx_iNmFiPkMiCmMiDfEiDeDiDfJiCpAiMlDiCmJiBeBiClLiCmMiKnEiCpAiOoGiCmBiCmEjCgMiCpAiNgJiCoIiNjOiCpBiCmFiCkCiCkNiBeC_xHqqkZx_

	// _xZkqqHx_iDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoHiCmIiCkCiNmFjBoFiCmMiDfEiDeDiDfJjEoEjHkGiBeC_xHqqkZx_
	double dFailR = GetIsShortenByText() ? 0.0 : 1.0;
	// _xZkqqHx_iDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoJiNmFiPkMiCmMiDfEiDeDiDfJjEoEjHkGiBeC_xHqqkZx_
	double dGoodR = DBL_MAX;

	//----- _xZkqqHx_iDhMiDiKiDfDiDjDiCpAiDgFiDeMiDfIiDgHjFjEjFgJiCmMiJpBjDfNjFkKiLhEjFmPiKlH_xHqqkZx_ -----

	double dR;
	if (wResizeKind == 1)	// _xZkqqHx_jAiFjFlNjFpLiMpMiCmMiCnNiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
		dR = m_mmrtWindow.Width() / m_mmrtWindowOrig.Width();
	else
		dR = m_mmrtWindow.Height() / m_mmrtWindowOrig.Height();

	// _xZkqqHx_jFjEjFgJiCkKiJpBjDfNjFhDiJmCiCmFiCkAiCoIiBeBiDgFiDeMiDfIiDgHiKhAjDhIiCkKjAiCjClMiCmMiPoKiNiHiCmNiBeB_xHqqkZx_
	// _xZkqqHx_iPgDiJkBiCmMiKgHjBoFjEoEjHkGiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
	// _xZkqqHx_iDgFiDeMiDfIiDgHiKhAjDhIiCkKjAiFjFlNiBeBjAiCjClMiCmMiPoKiNiHiBeB_xHqqkZx_dRatioHorz_xZkqqHx_iCmG_xHqqkZx_dRatioVert_xZkqqHx_iCmM_xHqqkZx_
	// _xZkqqHx_iCkCiClIiCoKiCkJiCkK_xHqqkZx_1.0_xZkqqHx_iCmFiCkAiCoJiPoKiNiHiCkKiCkAiCoJiClNiCnPiBeCiDiJiDhIiDiLjFjEjFgJiCmMiPoKiNiHiCpAiNgMjHlGiBeC_xHqqkZx_
	BOOL bExchange = FALSE;
	if (!pObj->CanRotate() &&
		(almosteq(pObj->GetTextAngle(), 0.5) || almosteq(pObj->GetTextAngle(), 1.5)))
		bExchange = TRUE;

	// _xZkqqHx_jAiFjFlNjFpLiMpMiCmMiCnNiCmMiDiKiDfEiDeDiDfJiCmMiPoKiNiHiBeBiCkCiCkNiCoHjBoFiCkLiCkNiClFiCmEiCoA_xHqqkZx_
	// _xZkqqHx_jFlGiOjKiCkKjDpMiCoHiCmIiCkCiPoKiNiHiCkKiCkAiCoJiBeCiClBiCoKiCpAiMjPiPgPiClHiCoJiClNiCnPiCmJ_xHqqkZx_
	// _xZkqqHx_jCoCiOhOiDeKiDeFiDjDiDfOiCpAjAnNjCoIiBeC_xHqqkZx_
	// _xZkqqHx_jBePiJpBiBeBiDhNiDfIiDeOjAhNiMgAjCiGiCmJjEhKjChFiCmFiCkLiClNjFlGiOjKjAjEiBeC_xHqqkZx_
	long lInsideCharCountPrev = -1;
	// _xZkqqHx_jCoCiOhOiDeKiDeFiDjDiDfOiBeCjGlDiInDjGkBiCmIiKgHjBoFiCpAjGgIiCkOiClNiCnPiBeC_xHqqkZx_
	long lStopCount = 0;
	for (;;)
	{
		double dRatioX;
		double dRatioY;
		switch (wResizeKind)
		{
		case 1:		// _xZkqqHx_jAiFjFlNjFpLiMpMiCmMiCnNiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
			dRatioX = dR;
			dRatioY = 1.0;
			break;
		case 2:		// _xZkqqHx_jAiCjClMjFpLiMpMiCmMiCnNiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
			dRatioX = 1.0;
			dRatioY = dR;
			break;
		default:	// _xZkqqHx_jAiFjFlNiBeFjAiCjClMjHlMjFpLiMpMiCmJiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
			dRatioX = dR;
			dRatioY = dR;
		}
		// _xZkqqHx_iDhEiDiMiBfLiDiAiCpAiKgHjBoFiBeCjAfGiClFiCkCiDfEiDeDiDfJiCpAjDlOiCoJiBeC_xHqqkZx_
		DBLRect mmrtFrameNew;
		// _xZkqqHx_jFjEjFgJiCkKiJpBjDfNjFhDiJmCiCmFiCkAiCoIiBeBiDgFiDeMiDfIiDgHiKhAjDhIiCkKjAiCjClMiCmMiPoKiNiHiCmNiBeB_xHqqkZx_
		// _xZkqqHx_iPgDiJkBiCmMiKgHjBoFjEoEjHkGiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
		if (!bExchange)
			mmrtFrameNew = mmrtFrameOrig * DBLPoint(dRatioX, dRatioY);
		else
			mmrtFrameNew = mmrtFrameOrig * DBLPoint(dRatioY, dRatioX);
		// _xZkqqHx_jFjEjFgJiCmMiNmFjBoFiDfEiDeDiDfJiCpAiJhKiCkGiCmIiCkCiCoGiCkEiCmJiBeC_xHqqkZx_
		if (FD_OBJ_MAX_W < mmrtFrameNew.Width() ||
			FD_OBJ_MAX_H < mmrtFrameNew.Height()) return FALSE;

		// _xZkqqHx_jFjEjFgJiCpAiDgFiDeMiDfIiDgHiKhA_xHqqkZx_=0_xZkqqHx_iCmJiCmIiCoJiCoGiCkEiJpBjDfNjFoCjAlDiClFiBeBiDfEiDeDiDfJiCpAjAnNjCoIiBeB_xHqqkZx_
		// _xZkqqHx_iNmEiCnBjFjEjFgJiCmMiKhAjDhIiCpAjGnPiClFiCmEiDhMiDiKiDfDiDjDiOoGjDlOiBeC_xHqqkZx_
		// _xZkqqHx_iDhMiDiKiDfDiDjDiCpAiDgFiDeMiDfIiDgHiKhA_xHqqkZx_=0_xZkqqHx_iCmJiCmIiCoJiCoGiCkEiJpBjDfNjFoCjAlDiClFiBeBiDhNiDfIiDeOiCmGiClFiCmEjAnNjCoIiBeC_xHqqkZx_
		// _xZkqqHx_iOkJjDkOiDiKiDfEiDeDiDfJiCmMiDhGiDiNiDfKiDfIiCmGjDkPiClGiDhGiDiNiDfKiDfIiCpAiOmAiOhLiClHiCoJiBeC_xHqqkZx_
		pNewObj->Rotate(-pObj->GetTextAngle(), DBLPoint(0, 0));
		pNewObj->Resize(TRUE, TRUE, mmrtFrameNew, pNewObj->GetResizeFrame());
		pNewObj->Rotate(pObj->GetTextAngle(), DBLPoint(0, 0));
		// _xZkqqHx_jFjEjFgJiCmMiDhMiDiKiDfDiDjDiCmMjClIjDfPiNmAjFfHjEhKjHpBiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
		DBLPointVector vmmptPoly;
// 06.12.04 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//		pNewObj->NewObjPolygonForText(vmmptPoly, FFGetStdElemLen(), NULL, 0);
		pNewObj->NewObjPolygonForText(vmmptPoly, -1, NULL, 0);
		// _xZkqqHx_iDhNiDfIiDeOjFjEjFgJiCmMiDhMiDiKiDfDiDjDiCpAiDgFiDeMiDfIiDgHjFjEjFgJiCmMiJpBjDfNjFkKiLhEjFmPiKlHiBeC_xHqqkZx_
		::RotateConv(vmmptPoly.begin(), vmmptPoly.size(),
					sin(-pObj->GetTextAngle() * M_PI),
					cos(-pObj->GetTextAngle() * M_PI),
					0, 0);
		// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCmGiClFiCmEjAnNjCoIiBeC_xHqqkZx_
		SetMaskPolygon(vmmptPoly.begin(), vmmptPoly.size(), DBLPoint(0,0));

		// _xZkqqHx_jBfDiNhDiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
		CalcLineBelowSub(-1);

		if (IsTextOver())
		//----- _xZkqqHx_iDgFiDeMiDfIiDgHiCkKiCkAiCnDiCoKiClNiPoKiNiH_xHqqkZx_ -----
		{
			if (dFailR < dR) dFailR = dR;
		} else
		//----- _xZkqqHx_iDgFiDeMiDfIiDgHiCkKiOpLiCnMiCmBiClNiPoKiNiH_xHqqkZx_ -----
		{
			if (dR < dGoodR) dGoodR = dR;
			break;
		}

		// _xZkqqHx_iDhNiDfIiDeOjAhNiMgAjCiGiCmJjEhKjChFiCmFiCkLiClNjFlGiOjKjAjEiBeC_xHqqkZx_
		long lInsideCharCount = 0;
		// _xZkqqHx_iDhNiDfIiDeOjAhNiMgAiKePiCmJiCkAiCnDiCoKiClNjFlGiOjKjAjEiBeC_xHqqkZx_
		long lOutsideCharCount = 0;
		FCEditLineVector::iterator iLine;
		for (iLine = m_vEditLine.begin(); iLine != m_vEditLine.end(); iLine++)
		{
			if (m_mmrtWindow.Height() - m_mmMarginB < (*iLine).m_mmY) break;
			lInsideCharCount += (*iLine).m_vEditChar.size();
		}
		for (; iLine != m_vEditLine.end(); iLine++)
			lOutsideCharCount += (*iLine).m_vEditChar.size();

		if (lInsideCharCountPrev == lInsideCharCount)
		//----- _xZkqqHx_jBePiJpBiCmGiDhNiDfIiDeOiCmJiOpLiCnMiCmBiClNjFlGiOjKjAjEiCkKjDkPiClGiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jCoCiOhOiDeKiDeFiDjDiDfOiCpAiJmBiOfKiBeC_xHqqkZx_
			lStopCount++;
			// _xZkqqHx_jGlDiInDjGkBiCmIiKgHjBoFiCpAiCfEiJpBiMeKiCoIjFnEiClFiClNiPoKiNiHiCmNiPiIjHjNiPeJjHlJiBeC_xHqqkZx_
			if (lStopCount == 5) return FALSE;
		} else
		//----- _xZkqqHx_jBePiJpBiCmGiDhNiDfIiDeOiCmJiOpLiCnMiCmBiClNjFlGiOjKjAjEiCkKiInJiCmIiCoJiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jCoCiOhOiDeKiDeFiDjDiDfOiCpAiDiKiDfKiDgCiDgHiBeC_xHqqkZx_
			lStopCount = 0;
			// _xZkqqHx_jBePiJpBiCmMjFmPjAjEiCmGiClFiCmEiKgPiCkGiCmEiCkIiCkNiBeC_xHqqkZx_
			lInsideCharCountPrev = lInsideCharCount;
		}

		// _xZkqqHx_iKgHjBoFjEhLjHkGiCpAiMhGiOfKiBeCiMlLiNnNiCmMjBiNjFlGiOjKjAjEiCmMiCfAiCfEiCePiBjDiCkKiOpLiCnMiCoJiCoGiCkEiBeBjEhLjHkGiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
		// _xZkqqHx_jAiFjFlNiBeFjAiCjClMjFpLiMpMiCmGiCoAiDiKiDfEiDeDiDfJiCmMiPoKiNiHiCmNjFlNjFpLiNkKiCpAiCmGiCoJiBeC_xHqqkZx_
		if (lInsideCharCount == 0)
			if (wResizeKind == 3)
				dR *= sqrt(2.0);
			else
				dR *= 2.0;
		else
			if (wResizeKind == 3)
				dR *= sqrt((double(lInsideCharCount + lOutsideCharCount) * 1.5) / double(lInsideCharCount));
			else
				dR *= (double(lInsideCharCount + lOutsideCharCount) * 1.5) / double(lInsideCharCount);
	}

	//----- _xZkqqHx_iOjPiCmJiBeBiDgFiDeMiDfIiDgHiCkKiOpLiCnMiCoJiNmFjDeLiCmIiDfEiDeDiDfJiCmJiNgJiCoIiNjOiCnO_xHqqkZx_ -----
	while (dGoodR * 0.01 < dGoodR - dFailR)
	//----- _xZkqqHx_jAkMiMpHiCmGiOlIjEhDiCmMiKgHjBoFjHkGiCmMiNlHiCkKiCfAiBjDiImIjDoAiCmJiCmIiCoJiCnMiCmF_xHqqkZx_ -----
	{
		double dR = (dFailR + dGoodR) / 2.0;

		double dRatioX;
		double dRatioY;
		switch (wResizeKind)
		{
		case 1:		// _xZkqqHx_jAiFjFlNjFpLiMpMiCmMiCnNiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
			dRatioX = dR;
			dRatioY = 1.0;
			break;
		case 2:		// _xZkqqHx_jAiCjClMjFpLiMpMiCmMiCnNiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
			dRatioX = 1.0;
			dRatioY = dR;
			break;
		default:	// _xZkqqHx_jAiFjFlNiBeFjAiCjClMjHlMjFpLiMpMiCmJiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
			dRatioX = dR;
			dRatioY = dR;
		}
		// _xZkqqHx_iDhEiDiMiBfLiDiAiCpAiKgHjBoFiBeCjAfGiClFiCkCiDfEiDeDiDfJiCpAjDlOiCoJiBeC_xHqqkZx_
		DBLRect mmrtFrameNew;
		// _xZkqqHx_jFjEjFgJiCkKiJpBjDfNjFhDiJmCiCmFiCkAiCoIiBeBiDgFiDeMiDfIiDgHiKhAjDhIiCkKjAiCjClMiCmMiPoKiNiHiCmNiBeB_xHqqkZx_
		// _xZkqqHx_iPgDiJkBiCmMiKgHjBoFjEoEjHkGiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
		if (!bExchange)
			mmrtFrameNew = mmrtFrameOrig * DBLPoint(dRatioX, dRatioY);
		else
			mmrtFrameNew = mmrtFrameOrig * DBLPoint(dRatioY, dRatioX);

		// _xZkqqHx_jFjEjFgJiCpAiDgFiDeMiDfIiDgHiKhA_xHqqkZx_=0_xZkqqHx_iCmJiCmIiCoJiCoGiCkEiJpBjDfNjFoCjAlDiClFiBeBiDfEiDeDiDfJiCpAjAnNjCoIiBeB_xHqqkZx_
		// _xZkqqHx_iNmEiCnBjFjEjFgJiCmMiKhAjDhIiCpAjGnPiClFiCmEiDhMiDiKiDfDiDjDiOoGjDlOiBeC_xHqqkZx_
		// _xZkqqHx_iDhMiDiKiDfDiDjDiCpAiDgFiDeMiDfIiDgHiKhA_xHqqkZx_=0_xZkqqHx_iCmJiCmIiCoJiCoGiCkEiJpBjDfNjFoCjAlDiClFiBeBiDhNiDfIiDeOiCmGiClFiCmEjAnNjCoIiBeC_xHqqkZx_
		// _xZkqqHx_iOkJjDkOiDiKiDfEiDeDiDfJiCmMiDhGiDiNiDfKiDfIiCmGjDkPiClGiDhGiDiNiDfKiDfIiCpAiOmAiOhLiClHiCoJiBeC_xHqqkZx_
		pNewObj->Rotate(-pObj->GetTextAngle(), DBLPoint(0, 0));
		pNewObj->Resize(TRUE, TRUE, mmrtFrameNew, pNewObj->GetResizeFrame());
		pNewObj->Rotate(pObj->GetTextAngle(), DBLPoint(0, 0));
		// _xZkqqHx_jFjEjFgJiCmMiDhMiDiKiDfDiDjDiCmMjClIjDfPiNmAjFfHjEhKjHpBiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
		DBLPointVector vmmptPoly;
// 06.12.04 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//		pNewObj->NewObjPolygonForText(vmmptPoly, FFGetStdElemLen(), NULL, 0);
		pNewObj->NewObjPolygonForText(vmmptPoly, -1, NULL, 0);
		// _xZkqqHx_iDhNiDfIiDeOjFjEjFgJiCmMiDhMiDiKiDfDiDjDiCpAiDgFiDeMiDfIiDgHjFjEjFgJiCmMiJpBjDfNjFkKiLhEjFmPiKlHiBeC_xHqqkZx_
		::RotateConv(vmmptPoly.begin(), vmmptPoly.size(),
					sin(-pObj->GetTextAngle() * M_PI),
					cos(-pObj->GetTextAngle() * M_PI),
					0, 0);
		// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCmGiClFiCmEjAnNjCoIiBeC_xHqqkZx_
		SetMaskPolygon(vmmptPoly.begin(), vmmptPoly.size(), DBLPoint(0,0));

		// _xZkqqHx_jBfDiNhDiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
		CalcLineBelowSub(-1);
		if (IsTextOver())
			dFailR = dR;
		else
			dGoodR = dR;
	}
	switch (wResizeKind)
	{
	case 1:		// _xZkqqHx_jAiFjFlNjFpLiMpMiCmMiCnNiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
		dRatioHorz = dGoodR;
		dRatioVert = 1.0;
		break;
	case 2:		// _xZkqqHx_jAiCjClMjFpLiMpMiCmMiCnNiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
		dRatioHorz = 1.0;
		dRatioVert = dGoodR;
		break;
	default:	// _xZkqqHx_jAiFjFlNiBeFjAiCjClMjHlMjFpLiMpMiCmJiDiKiDfEiDeDiDfJiClHiCoJiPoKiNiHiBeC_xHqqkZx_
		dRatioHorz = dGoodR;
		dRatioVert = dGoodR;
	}
	return TRUE;
} // CFCWndRichEdit::CalcEnoughSizeRatio.

//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetResizeHorz
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiFjFlNjFpLiMpMiCmMiDiKiDfEiDeDiDfJiLeLjBkFiCpAjFnEiClHiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	FD_RPT_NONE:
// *					_xZkqqHx_iDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCmIiCkCiBeC_xHqqkZx_
// *			FD_RPT_H_LEFT:
// *					_xZkqqHx_jFjEjFgJiCmMiNlGjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_H_CENTER:
// *					_xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_H_RIGHT:
// *					_xZkqqHx_jFjEjFgJiCmMiJeFjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//WORD CFCWndRichEdit::GetResizeHorz () const
//{
//	return m_wResizeHorz;		// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiFjFlNjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
//} // CFCWndRichEdit::GetResizeHorz.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetResizeVert
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiCjClMjFpLiMpMiCmMiDiKiDfEiDeDiDfJiLeLjBkFiCpAjFnEiClHiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	FD_RPT_NONE:
// *					_xZkqqHx_iDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCmIiCkCiBeC_xHqqkZx_
// *			FD_RPT_V_TOP:
// *					_xZkqqHx_jFjEjFgJiCmMiPoDjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_V_CENTER:
// *					_xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_V_BOTTOM:
// *					_xZkqqHx_jFjEjFgJiCmMiJlKjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//WORD CFCWndRichEdit::GetResizeVert () const
//{
//	return m_wResizeVert;		// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiCjClMjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
//} // CFCWndRichEdit::GetResizeVert.
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetFixResize
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiFjFlNjFpLiMpMiCmMiDiKiDfEiDeDiDfJiLeLjBkFiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	FD_RPT_NONE:
 *					_xZkqqHx_iDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCmIiCkCiBeC_xHqqkZx_
 *			FD_RPT_H_LEFT:
 *					_xZkqqHx_jFjEjFgJiCmMiNlGjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
 *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *			FD_RPT_H_CENTER:
 *					_xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
 *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *			FD_RPT_H_RIGHT:
 *					_xZkqqHx_jFjEjFgJiCmMiJeFjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
 *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
WORD CFCWndRichEdit::GetFixResize () const
{
	return m_wFixResize;		// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiFjFlNjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
} // CFCWndRichEdit::GetFixResize.
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetIsShortenByText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiPgLiPkMiOjOiCmJjFjEjFgJiCoAiPgLiPkMiClHiCoJiCkJiCmHiCkEiCkJjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPgLiPkMiClHiCoJiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::GetIsShortenByText () const
{
	return m_bIsShortenByText;	// _xZkqqHx_iDgFiDeMiDfIiDgHiPgLiPkMiOjOiCmJjFjEjFgJiPgLiPkMiBeI_xHqqkZx_
} // CFCWndRichEdit::GetIsShortenByText.

//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetResizeHorz
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiFjFlNjFpLiMpMiCmMiDiKiDfEiDeDiDfJiLeLjBkFiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wResizeHorz:
// *			FD_RPT_NONE:
// *					_xZkqqHx_iDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCmIiCkCiBeC_xHqqkZx_
// *			FD_RPT_H_LEFT:
// *					_xZkqqHx_jFjEjFgJiCmMiNlGjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_H_CENTER:
// *					_xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_H_RIGHT:
// *					_xZkqqHx_jFjEjFgJiCmMiJeFjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::SetResizeHorz (WORD wResizeHorz)
//{
//	m_wResizeHorz = wResizeHorz;		// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiFjFlNjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
//} // CFCWndRichEdit::SetResizeHorz.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetResizeVert
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiCjClMjFpLiMpMiCmMiDiKiDfEiDeDiDfJiLeLjBkFiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wResizeVert:
// *			FD_RPT_NONE:
// *					_xZkqqHx_iDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCmIiCkCiBeC_xHqqkZx_
// *			FD_RPT_V_TOP:
// *					_xZkqqHx_jFjEjFgJiCmMiPoDjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_V_CENTER:
// *					_xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *			FD_RPT_V_BOTTOM:
// *					_xZkqqHx_jFjEjFgJiCmMiJlKjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
// *					_xZkqqHx_jAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::SetResizeVert (WORD wResizeVert)
//{
//	m_wResizeVert = wResizeVert;		// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiCjClMjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
//} // CFCWndRichEdit::SetResizeVert.
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetFixResize
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiFjFlNjFpLiMpMiCmMiDiKiDfEiDeDiDfJiLeLjBkFiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wFixResize:
 *			FD_RPT_NONE:
 *					_xZkqqHx_iDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCmIiCkCiBeC_xHqqkZx_
 *			FD_RPT_H_LEFT:
 *					_xZkqqHx_jFjEjFgJiCmMiNlGjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
 *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *			FD_RPT_H_CENTER:
 *					_xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
 *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *			FD_RPT_H_RIGHT:
 *					_xZkqqHx_jFjEjFgJiCmMiJeFjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmM_xHqqkZx_
 *					_xZkqqHx_jAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetFixResize (WORD wFixResize)
{
	m_wFixResize = wFixResize;		// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiFjFlNjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
} // CFCWndRichEdit::SetFixResize.
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetIsShortenByText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiPgLiPkMiOjOiCmJjFjEjFgJiCoAiPgLiPkMiClHiCoJiCkJiCmHiCkEiCkJjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	bIsShortenByText:	_xZkqqHx_iPgLiPkMiClHiCoJiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetIsShortenByText (BOOL bIsShortenByText)
{
	m_bIsShortenByText = bIsShortenByText;	// _xZkqqHx_iDgFiDeMiDfIiDgHiPgLiPkMiOjOiCmJjFjEjFgJiPgLiPkMiBeI_xHqqkZx_
} // CFCWndRichEdit::SetIsShortenByText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetMargin
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFjEjFgJiDhEiDiMiBfLiDiAiCmJjBmOiClHiCoJiDgFiDeMiDfIiDgHjHmMiIoGiCmMjHfNjEjCiCpAjAnNjCoIiClHiCoJ_xHqqkZx_.
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmMarginL	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGiDhNiBfLiDfHiDjD_xHqqkZx_.
 *			mmMarginT	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDiDhNiBfLiDfHiDjD_xHqqkZx_.
 *			mmMarginR	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFiDhNiBfLiDfHiDjD_xHqqkZx_.
 *			mmMarginB	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKiDhNiBfLiDfHiDjD_xHqqkZx_.
 *************************************************************************/
void CFCWndRichEdit::SetMargin (mmetol mmMarginL, mmetol mmMarginT,
								mmetol mmMarginR, mmetol mmMarginB)
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	// _xZkqqHx_jHfNjEjCjAnNjCoIiBeC_xHqqkZx_
	CmdModifyMargin(mmMarginL, mmMarginT, mmMarginR, mmMarginB);
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();
	//----- _xZkqqHx_jBfDiNhDiCpAiNmEiMhGiOfK_xHqqkZx_ -----
	CalcLineAll();
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
// 05.03.01 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (IsWindowVisible())
	if (::IsWindow(m_hWnd) && IsWindowVisible())
	//----- _xZkqqHx_iDeHiDgGiDeCiDfOjFfMiOkGjCiGiCmNiDiLiBfLiDiJiBfLjFmPiNfI_xHqqkZx_/_xZkqqHx_jEpBjFfMiOkGjCiGiCoAiCkAiCoIiCkGiCoJiClNiCnP_xHqqkZx_ -----
	{
		// _xZkqqHx_iDiLiBfLiDiJiBfLiCmMjAnNjCoIiBeC_xHqqkZx_
		FFGetMainWnd()->HRuler()->SetTextRange(this, m_mmrtWindow.left + m_mmMarginL,
												m_mmrtWindow.right - m_mmMarginR);
		FFGetMainWnd()->VRuler()->SetTextRange(this, m_mmrtWindow.top + m_mmMarginT,
												m_mmrtWindow.bottom - m_mmMarginB);
	}
} // CFCWndRichEdit::SetMargin.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetMargin
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFjEjFgJiDhEiDiMiBfLiDiAiCmJjBmOiClHiCoJiDgFiDeMiDfIiDgHjHmMiIoGiCmMjHfNjEjCiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmMarginL	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGjHfNjEjCiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmMarginT	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDjHfNjEjCiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmMarginR	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFjHfNjEjCiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmMarginB	: _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKjHfNjEjCiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.03.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetMargin (mmetol& mmMarginL, mmetol& mmMarginT,
								mmetol& mmMarginR, mmetol& mmMarginB) const
{
	mmMarginL = m_mmMarginL;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGjHfNjEjCiBeC_xHqqkZx_
	mmMarginT = m_mmMarginT;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDjHfNjEjCiBeC_xHqqkZx_
	mmMarginR = m_mmMarginR;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFjHfNjEjCiBeC_xHqqkZx_
	mmMarginB = m_mmMarginB;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKjHfNjEjCiBeC_xHqqkZx_
} // CFCWndRichEdit::GetMargin.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetVertAlignment
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiCjClMjFpLiMpMiCmMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	byAlign	:_xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetVertAlignment (BYTE byAlign)
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	// _xZkqqHx_iPoDiJlKiDeBiDiJiDeDiDjDiDiBiDjDiDgHjAnNjCoIiBeC_xHqqkZx_
	CmdModifyVertAlign(byAlign);
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();
	//----- _xZkqqHx_jBfDiNhDiCpAiNmEiMhGiOfK_xHqqkZx_ -----
	CalcLineAll();
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
} // CFCWndRichEdit::SetVertAlignment.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetVertAlignment
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiCjClMjFpLiMpMiCmMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BYTE CFCWndRichEdit::GetVertAlignment () const
{
	return m_byVertAlign;
} // CFCWndRichEdit::GetVertAlignment.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ShowWindow
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeHiDgGiDeCiDfOiDeFiDeCiDjDiDgIiDeFiCmMjFfMiOkGiBeFjEpBjFfMiOkGiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nCmdShow	:_xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCmMjFfMiOkGiPpDjBnEiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	Window_xZkqqHx_jFfMiOkGjClMiMoDiCmMiPiJiKpKiJlLiPiIjHjNiCpAiOmAiNhDiClHiCoJiClNiCnPiCmJiNoMjAkMiClFiClNiBeC_xHqqkZx_
 *			Wnd:ShowWindow _xZkqqHx_iCmN_xHqqkZx_virtual _xZkqqHx_iCmFiCmNjGlDiCkCiCmMiCmFjCiNiInDiCkKjFeLjHhGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.01.29 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::ShowWindow (int nCmdShow)
{
	// _xZkqqHx_iDhEiDiMiBfLiDiAiPiJiKpKiJlLjBePiBjFiNoNiPjMiMoDiCmMiPoKiNiHiCmNiOmAiNhDiClFiCmIiCkCiBeC_xHqqkZx_
	if (FFGetMainWnd()->HRuler() == NULL || FFGetMainWnd()->VRuler() == NULL) return;
//----- 05.03.01 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCkKiNoMjAkMiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOjFjMiLeBiBeC_xHqqkZx_
	if (!::IsWindow(m_hWnd)) return;
//----- 05.03.01 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_jFfMiOkGiNmPiCnNiBeBjEpBjFfMiOkGiNmPiCnNiCmMiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
	if (IsWindowVisible() && nCmdShow == SW_SHOW) return;
	if (!IsWindowVisible() && nCmdShow == SW_HIDE) return;

//----- 01.04.26 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// Superclass_xZkqqHx_iOmAiNhDiBeC_xHqqkZx_
//	BASE_CLASS::ShowWindow(nCmdShow);
//----- 01.04.26 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

// 01.04.26 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	if (FFGetMainWnd()->HRuler() == NULL || FFGetMainWnd()->VRuler() == NULL) return;

	if (nCmdShow == SW_SHOW)
	//----- _xZkqqHx_iClBiCoKiCkJiCoHjFfMiOkGiClHiCoJ_xHqqkZx_ -----
	{
		// _xZkqqHx_jBfDiJoGjGmKiDiCiBfLiDgIiCmIiCoHiCmOiBeBjBfDiJoGjGmKiDiCiBfLiDgIiCmJiDhCiDiFiBfLiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
		if (IsFullScreenEditMode())
		{
			UpdateFullScreenMode(TRUE);
			// Superclass_xZkqqHx_iOmAiNhDiBeC_xHqqkZx_UpdateFullScreenMode_xZkqqHx_iCmMiMoDiCmFiBeC_xHqqkZx_
			BASE_CLASS::ShowWindow(nCmdShow);
			// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiBeC_xHqqkZx_Superclass_xZkqqHx_iOmAiNhDiCmMiMoDiCmFiBeC_xHqqkZx_IsWindowVisible_xZkqqHx_iCmMiJgFiLlPiCpAiOpDiCkPiCoJiClNiCnPiBeC_xHqqkZx_
			CalcLineAll();
		} else
		{
			// Superclass_xZkqqHx_iOmAiNhDiBeC_xHqqkZx_
			BASE_CLASS::ShowWindow(nCmdShow);
		}
		//----- RichEditCtrl_xZkqqHx_iCpAjFfHiPiAiDhEiDeIiDjDiDgHiCmFiPiJiKpKiJlL_xHqqkZx_ -----
		// m_fciCurExtCodeFormat _xZkqqHx_iCpAiMlLiNnNiImKjChFiCmMjFlGiOjKiDhEiDeIiDjDiDgHiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
		ResetCurFormat();
		// _xZkqqHx_iDiLiBfLiDiJiBfLiCmMjAnNjCoIiBeC_xHqqkZx_
		FFGetMainWnd()->HRuler()->SetTextRange(this, m_mmrtWindow.left + m_mmMarginL,
												m_mmrtWindow.right - m_mmMarginR);
		FFGetMainWnd()->VRuler()->SetTextRange(this, m_mmrtWindow.top + m_mmMarginT,
												m_mmrtWindow.bottom - m_mmMarginB);
		// _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiNmEiMhGiOfKiBeCjDkPiOjOiCmJiDiLiBfLiDiJiBfLiCmMjFfMiOkGiCoAiNfIjAfGiBeC_xHqqkZx_
		m_mmCaretX = RepositionCaret();
	} else
	//----- _xZkqqHx_iClBiCoKiCkJiCoHjEpBjFfMiOkGiCmJiClHiCoJ_xHqqkZx_ -----
	if (nCmdShow == SW_HIDE)
	{
		// Superclass_xZkqqHx_iOmAiNhDiBeC_xHqqkZx_UpdateFullScreenMode_xZkqqHx_iCmMjBePiCmJiBeC_xHqqkZx_
		BASE_CLASS::ShowWindow(nCmdShow);
		// _xZkqqHx_jBfDiJoGjGmKiDiCiBfLiDgIiCmIiCoHiCmOiBeBjBfDiJoGjGmKiDiCiBfLiDgIiCmMjFfMiOkGiCpAiJpAiPjMiClHiCoJiBeC_xHqqkZx_
		if (IsFullScreenEditMode())
		{
			UpdateFullScreenMode(FALSE);
			// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiBeC_xHqqkZx_
			CalcLineAll();
		}
		// _xZkqqHx_iDiLiBfLiDiJiBfLiCpAjCmKiPoNiCmMiDiCiBfLiDgIiCmJiBeC_xHqqkZx_
		FFGetMainWnd()->HRuler()->UnSetTextRange();
		FFGetMainWnd()->VRuler()->UnSetTextRange();
	}
} // CFCWndRichEdit::ShowWindow.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::MoveWindowMM
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCmMiInKjDkOiBeC_xHqqkZx_View_xZkqqHx_iOmAiNmAjFfHiCmFiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmrct	: _xZkqqHx_iInKjDkOjAoGiNmAjFfHiBeC_xHqqkZx_View_xZkqqHx_iOmAiNmAjFfHiMgOiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::MoveWindowMM (const DBLRect& mmrct)
{
	m_mmrtWindow = mmrct;
	CRect dvrct = mm2lg(mmrct);
	g_pView->LPtoDP(dvrct);
//----- 06.12.02 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCmMjFjNiBeFiNiCiClDiCkKiCePiCmJiCmIiCoHiCmIiCkCiCoGiCkEiCmJiBeC_xHqqkZx_
	if (dvrct.left == dvrct.right)
		dvrct.right = dvrct.left + 1;
	if (dvrct.top == dvrct.bottom)
		dvrct.bottom = dvrct.top + 1;
//----- 06.12.02 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	if (::IsWindow(m_hWnd))
		BASE_CLASS::MoveWindow(dvrct);
	// _xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiPoKiNiHiCmJiBeBiDeHiDgGiDeCiDfOiCoAiNiHiCoNiClJiCmE_xHqqkZx_
	// _xZkqqHx_iDfJiBfLiDiAiClDiClJiCoJiClNiCnPiCmJiDeKiDiMiDgCiDgHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
	RepositionCaret();
} // CFCWndRichEdit::MoveWindowMM.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetWindowRectMM
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeFiDeCiDjDiDgIiDeFiLoJiMgAiCpAiBeBiOmAiNmAjFfHiCmFiOoGjDlOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmrt	:_xZkqqHx_iDeFiDeCiDjDiDgIiDeFiLoJiMgAiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.03 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetWindowRectMM (DBLRect& mmrt) const
{
	mmrt = m_mmrtWindow;
} // CFCWndRichEdit::GetWindowRectMM.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	 vStatLine	:_xZkqqHx_iDgFiDeMiDfIiDgHiDgGiBfLiDfOiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	FCStatLine/FCStatChar_xZkqqHx_iCmNiBeB_xHqqkZx_FCEditLine/FCEditChar_xZkqqHx_iCmJjEoEiCnHiBeBiDgGiBfLiDfO_xHqqkZx_
 *			_xZkqqHx_jHmKiCkKiPkNiCmIiCkCiBeCiClLiCmMjBoDiCoNiCoIjFnCiPfHiNoMiLmGiCmJiCmNiMpMiCkJiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.02.15 Fukushiro M. _xZkqqHx_iPeDjAlD_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetText (const FCStatLineVector& vStatLine)
{
	// _xZkqqHx_jDoAjFjEiDgFiDeMiDfIiDgHiDgGiBfLiDfOiCpAiPiJiKpKiJlLiBeC_xHqqkZx_
	ClearText();
	// _xZkqqHx_jAnNjCoIiClHiCoJiDgFiDeMiDfIiDgHiCkKjGlDiCkCiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
	if (vStatLine.empty()) return;
	//----- _xZkqqHx_iDgFiDeMiDfIiDgHiCpAiDfCiDhDiBfL_xHqqkZx_ -----
	// _xZkqqHx_iPiJiKpKiJlLiOjOiCmJiJpMiNhDiCkKiCfAjFlGiOjKjCmHiJmBiClDiCoKiCmEiCkCiCoJiCmMiCmFiBeBiPmBiLiOiBeC_xHqqkZx_
	m_vEditLine.clear();
	FCStatLineVector::const_iterator iS;
	for (iS = vStatLine.begin(); iS != vStatLine.end(); iS++)
	{
		m_vEditLine.push_back(FCEditLine());
		FCEditLine& elEdit = m_vEditLine.back();
		elEdit = *iS;
	}
	//----- _xZkqqHx_jFlGiOjKiCpAiDfIiDeMiDiDiDjDiClFiCmEiBeBiDhEiDeIiDjDiDgHiPoOjFpBiCpAiPiJiKpKiJlL_xHqqkZx_ -----
//----- 06.05.22 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	FCFontCharInfo fciExtCode = {0};
//	FCFontCharInfo fciStdCode = {0};
//----- 06.05.22 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	// memset _xZkqqHx_iCmFiPiJiKpKiJlLiClHiCoJiClBiCmGiBeC_xHqqkZx_ = {0} _xZkqqHx_iCmFiCmNiCkEiCnMiCkNiPiJiKpKiJlLiCmFiCkLiCmIiCkCiPoKiNiHiCkKiCkAiCmBiClNiBeC_xHqqkZx_
	FCFontCharInfo fciExtCode;
	FCFontCharInfo fciStdCode;
	memset(&fciExtCode, 0, sizeof(fciExtCode));
	memset(&fciStdCode, 0, sizeof(fciStdCode));
//----- 06.05.22 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
//	FCEditLineVector::const_iterator iL;
//	FCEditCharVector::const_iterator iC;
//	//----- _xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiCmMiDhEiDeIiDjDiDgHiPoOjFpBiCpAiOoGjDlOiBeCiNmFiMoDiCmMiCfAjFlGiOjKiCkKiJpMiNhDiCmIiCmMiCmFjFeLiClIiMkJiCmCiCkJiCoJ_xHqqkZx_ -----
//	for (iL = m_vEditLine.begin();
//		 fciExtCode.dwMask == 0 && iL != m_vEditLine.end(); iL++)
//	{
//		for (iC = (*iL).m_vEditChar.begin();
//			 fciExtCode.dwMask == 0 && iC != (*iL).m_vEditChar.end(); iC++)
//		{
////----- 01.04.19 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
////			if (!FFIsStdCode((*iC).m_wChar,
////							g_pEnv->GetSFontRec((*iC).m_foidFont)->GetCharSet()))
////				g_pEnv->GetSFontRec((*iC).m_foidFont)->ReqInit(fciExtCode);
////----- 01.04.19 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
//			if (!FFIsStdFontChar((*iC).m_wChar))
//				g_pEnv->GetSFontRec((*iC).m_foidFont)->ReqInit(fciExtCode);
////----- 01.04.19 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
//		}
//	}
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
	long lLine = 0;
	long lChar = 0;
	//----- _xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiCmMiDhEiDeIiDjDiDgHiPoOjFpBiCpAiOoGjDlOiBeCiNmFiMoDiCmMiCfAjFlGiOjKiCkKiJpMiNhDiCmIiCmMiCmFjFeLiClIiMkJiCmCiCkJiCoJ_xHqqkZx_ -----
	for (;;)
	{
		if (!FFIsStdFontChar(Fdrch2Wchar(GetChar(lLine, lChar).m_wChar)))
		{
			g_pEnv->GetSFontRec(GetChar(lLine, lChar).m_foidFont)->ReqInit(fciExtCode);
			break;
		}
		if (!NextChar(lLine, lChar)) break;
	}
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----

//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
//	//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiDhEiDeIiDjDiDgHiPoOjFpBiCpAiOoGjDlOiBeCiMkJiCmCiCkJiCoJiCmGiCmNiMmAiCoHiCmIiCkC_xHqqkZx_ -----
//	for (iL = m_vEditLine.begin();
//		 fciStdCode.dwMask == 0 && iL != m_vEditLine.end(); iL++)
//	{
//		for (iC = (*iL).m_vEditChar.begin();
//			 fciStdCode.dwMask == 0 && iC != (*iL).m_vEditChar.end(); iC++)
//		{
////----- 01.04.19 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
////			if (FFIsStdCode((*iC).m_wChar,
////							g_pEnv->GetSFontRec((*iC).m_foidFont)->GetCharSet()))
////				g_pEnv->GetSFontRec((*iC).m_foidFont)->ReqInit(fciStdCode);
////----- 01.04.19 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
//			if (FFIsStdFontChar((*iC).m_wChar))
//				g_pEnv->GetSFontRec((*iC).m_foidFont)->ReqInit(fciStdCode);
////----- 01.04.19 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
//		}
//	}
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
	//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiDhEiDeIiDjDiDgHiPoOjFpBiCpAiOoGjDlOiBeCiMkJiCmCiCkJiCoJiCmGiCmNiMmAiCoHiCmIiCkC_xHqqkZx_ -----
	lLine = 0;
	lChar = 0;
	for (;;)
	{
		if (FFIsStdFontChar(Fdrch2Wchar(GetChar(lLine, lChar).m_wChar)))
		{
			g_pEnv->GetSFontRec(GetChar(lLine, lChar).m_foidFont)->ReqInit(fciStdCode);
			break;
		}
		if (!NextChar(lLine, lChar)) break;
	}
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
	if (fciStdCode.dwMask == 0)
	//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiDhEiDeIiDjDiDgHiPoOjFpBiCkKiMkJiCmCiCkJiCoHiCmIiCkJiCmBiClNiPoKiNiH_xHqqkZx_ -----
	{
		fciStdCode = fciExtCode;
		fciStdCode.byCharSet = g_pReg->GetStdFontCharset();
		FFGetNearest(fciStdCode, NULL, &m_fciCurStdCodeFormat);
	}
	//----- _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCmFiBeBiDfEiDeDiDfJiBeFiDeJiDhEiDfKiDgCiDgHiBeFjAeGjDjJiCpAiPiJiKpKiJlL_xHqqkZx_ -----
	FCFontCharInfo fciCur;
	g_pEnv->GetSFontRec(m_vEditLine[0].m_vEditChar[0].m_foidFont)->ReqInit(fciCur);
	m_vEditLine[0].m_vEditChar[0].ReqOverwrite(fciCur);
	FFOverwrite(fciExtCode, fciCur, 
			FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
			FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
	FFOverwrite(fciStdCode, fciCur, 
			FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
			FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
	m_fciCurExtCodeFormat = fciExtCode;
	m_fciCurStdCodeFormat = fciStdCode;
} // CFCWndRichEdit::SetText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	 vStatLine	: _xZkqqHx_iDgGiBfLiDfOiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	FCStatLine/FCStatChar_xZkqqHx_iCmNiBeB_xHqqkZx_FCEditLine/FCEditChar_xZkqqHx_iCmJjEoEiCnHiBeBiDgGiBfLiDfO_xHqqkZx_
 *			_xZkqqHx_jHmKiCkKiPkNiCmIiCkCiBeCiClLiCmMjBoDiCoNiCoIjFnCiPfHiNoMiLmGiCmJiCmNiMpMiCkJiCmIiCkCiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetText (FCStatLineVector& vStatLine) const
{
	vStatLine.clear();
	FCEditLineVector::const_iterator iE;
	for (iE = m_vEditLine.begin(); iE != m_vEditLine.end(); iE++)
	{
		vStatLine.push_back(FCStatLine());
		FCStatLine& slStat = vStatLine.back();
		slStat = *iE;
	}
} // CFCWndRichEdit::GetText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBkOjAkLiCpAiPjMiCkCiClNiBeBiPiDjAiIiCmIjFlGiOjKjHpBiCmMiCnNiCpAiOoGiCoIiPgPiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	str	:_xZkqqHx_iDgFiDeMiDfIiDgHjFlGiOjKjHpBiCpAjFnEiClHiBeC_xHqqkZx_
 *			bIs2CR	:_xZkqqHx_iJpMiNhDiCpAiCfBjFlGiOjK_xHqqkZx_("\r\n")_xZkqqHx_iCmJiClHiCoJiCkJiCpAiOhHjCoIiBeC_xHqqkZx_FALSE _xZkqqHx_iCmIiCoHiCmO_xHqqkZx_ "\n"_xZkqqHx_iCmMiCnNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHjFlGiOjKjHpBiCpAjElCiCkLiPgPiClHiBeCiOoFiCmJiMjPiNpFjHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iDgGiDhEiDeIiDiLiDgHiCmFiCmNiJpMiNhDiDfCiBfLiDgIiCmN_xHqqkZx_("\r\n")_xZkqqHx_iCmFiCmNjGlDiCkNiBeB_xHqqkZx_("\n")_xZkqqHx_iCfAjFlGiOjKiCmJ_xHqqkZx_
 *			_xZkqqHx_jFmPiKlHiClDiCoKiCoJiClBiCmGiCmJjCiNiInDiBeC_xHqqkZx_WndRichEdit_xZkqqHx_jCiGiCmMjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCmGiBeB_xHqqkZx_
 *			_xZkqqHx_jFlGiOjKiImKjChFiCpAiIoKjChGiClDiClJiCoJiClNiCnPiBeC_xHqqkZx_
 *			_xZkqqHx_iNmFiMoDiCmMiJpMiNhDiCmNiOoGiCoIiPgPiClDiCmIiCkCiBeCiClBiCoKiCpAiOoGiCoIiPgPiClHiCmGiBeBiClBiCmMiJpMiNhDiCmJ_xHqqkZx_
 *			_xZkqqHx_iDhBiDgCiDgHiClFiCmEjChFiKlHiCmMjBmOiPnLiCmGiCmIiCmBiCmEiClFiCnMiCkEiBeCiNmFiMoDiCmMiJpMiNhDiCmMjChFiKlHiCmN_xHqqkZx_
 *			_xZkqqHx_jHiOiClPiCoJiBeCiCnMiClNiBeBiNmFiMoDiCmMiJpMiNhDiCmNiBeBjGhLjHiIiClBiCmMiDgFiDeMiDfIiDgHiCmFiCmNiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.17 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetText (WString& str, BOOL bIs2CR) const
{
	str.erase();
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (NextChar_xZkqqHx_iCpAjHjIjHhAiClFiClNjFpLiCkKiCoGiCkC_xHqqkZx_)-----
//	FCEditLineVector::const_iterator iL;
//	FCEditCharVector::const_iterator iC;
//	for (iL = m_vEditLine.begin(); iL != m_vEditLine.end(); iL++)
//	{
//		for (iC = (*iL).m_vEditChar.begin();
//			 iC != (*iL).m_vEditChar.end(); iC++)
//		{
//			switch ((*iC).m_wChar)
//			{
//			case FDRCH_RETURN:		// _xZkqqHx_iJpMiNhDjFlGiOjKiBeC_xHqqkZx_
//				if (bIs2CR) str += L'\r';
//				str += L'\n';
//				break;
//			case FDRCH_CONTINUE:	// _xZkqqHx_iMhAjBlBiLeMiNiGiBeC_xHqqkZx_
//				break;
//			default:
//				str += (*iC).m_wChar;
//			}
//		}
//	}
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (NextChar_xZkqqHx_iCpAjHjIjHhAiClFiClNjFpLiCkKiCoGiCkC_xHqqkZx_)-----
	long lLine = 0;
	long lChar = 0;
	for (;;)
	{
		if (GetChar(lLine, lChar).m_wChar == FDRCH_RETURN)
		//----- _xZkqqHx_iJpMiNhDjFlGiOjKiCmMiPoKiNiH_xHqqkZx_ -----
		{
			if (bIs2CR) str += L'\r';
			str += L'\n';
		} else
		//----- _xZkqqHx_iJpMiNhDjFlGiOjKiImIiKePiCmMiPoKiNiH_xHqqkZx_ -----
		{
			str += GetChar(lLine, lChar).m_wChar;
		}
		if (!NextChar(lLine, lChar)) break;
	}
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (NextChar_xZkqqHx_iCpAjHjIjHhAiClFiClNjFpLiCkKiCoGiCkC_xHqqkZx_)-----
//----- 01.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iNmFiMoDiCmMiJpMiNhDiCpAiNoNiPjMiBeC_xHqqkZx_
	str.resize(str.size() - (bIs2CR ? 2 : 1));
//----- 01.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::GetText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ClearText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCpAiClHiCnHiCmEiPmBiLiOiClHiCoJiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::ClearText ()
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();
	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
	RegisterClearRgn(m_vEditLine.begin(), m_vEditLine.end());
	m_vEditLine.clear();

	// _xZkqqHx_iMlLiNnNiCmMiDhEiDeIiDjDiDgHiCpAjFjEjFgJiPiJiKpKiJlLjHhAiDhEiDeIiDjDiDgHiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
	g_pReg->InitRegFont(m_fciCurExtCodeFormat, FDFT_OBJECT_INIT);
	g_pReg->InitRegFont(m_fciCurStdCodeFormat, FDFT_OBJECT_INIT);
	// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCmNiBeBjFfHiPiAjFlGiOjKiDfCiBfLiDgIiCpAjAnNjCoIiClFiCmEiBeBiPiJiKpKiJlLiClFiCmIiCkIiClFiBeC_xHqqkZx_
	m_fciCurStdCodeFormat.byCharSet = g_pReg->GetStdFontCharset();
	FFGetNearest(m_fciCurStdCodeFormat);

	//----- _xZkqqHx_iNmFiPiJiCmMiCfAiNhDiCpAjAlGjAkMiClHiCoJ_xHqqkZx_ -----
	m_lCurIndex = 0;
	m_mmCaretX = 0.0;
	m_lSelFrom	= -1;
	m_lSelTo	= -1;
	m_vEditLine.push_back(FCEditLine());
	//----- _xZkqqHx_iNmFiPiJiCmMiCfAiNhDiCmMiNmFiPiJiCmMiCfAjFlGiOjKiBgJiJpMiNhDiBgKiCpAjAlGjAkMiClHiCoJ_xHqqkZx_ -----
	// _xZkqqHx_iKpJjBlGiDhEiDeIiDjDiDgHiCpAiMjPiNpFiBeC_xHqqkZx_
	FCSFontRec fontRec(m_fciCurExtCodeFormat);
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
//	SFontID foid = g_pEnv->FindNearestSFont(fontRec);
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
	SFontID foid = g_pEnv->FindNearestSFont(fontRec, NULL);
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
	// _xZkqqHx_iMkJiCmCiCkJiCoHiCmIiCkCiPoKiNiHiCmN_xHqqkZx_ 0(_xZkqqHx_jFfHiPiAiDhEiDeIiDjDiDgH_xHqqkZx_)_xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
	if (foid == FD_S_FONT_UNSPECIFY) foid = FD_S_FONT_STANDARD;
	// _xZkqqHx_iNmFiPiJiCmMiCfAjFlGiOjKiCpAjAlGjAkMiBeC_xHqqkZx_
	m_vEditLine[0].m_vEditChar.push_back(
					FCEditChar(FDRCH_RETURN, foid, 0.0, 0, FD_COLREF_BLACK, 0, 0,
					FDWR_RETURN_WIDTH, 0.0, 0.0, 0.0, FDWR_CROSS_INSIDE));

	// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCpAiPiJiKpKiJlLiClHiCoJiBeC_xHqqkZx_
	ClearAllSession();
	// 0_xZkqqHx_iNhDiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeCiJpMiNhDiCmMiCnNiClOiCkPiCoKiCmHiBeBiDeKiDiMiDgCiDgHjFfMiOkGiCmMiInHiCmJiImKjChFiMhGiOfKiCkKjFeLjHhGiBeC_xHqqkZx_
	CalcLineAll();
	// _xZkqqHx_jFfMiOkGjCiGiCmFiCmIiCkCiCmIiCoHiCmOiClBiClBiCmFiPeJiCoNiCoIiBeC_xHqqkZx_
	if (!::IsWindow(m_hWnd) || !IsWindowVisible()) return;
	// _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
	m_mmCaretX = RepositionCaret();
	// _xZkqqHx_jFfMiOkGjCiGiCmIiCoHiCmOiNmEjFfMiOkGiBeC_xHqqkZx_
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
} // CFCWndRichEdit::ClearText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ClearAll
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iClHiCnHiCmEiCmMiDgGiBfLiDfOiCpAiPmBiLiOiBeFiPiJiKpKiJlLiClHiCoJiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::ClearAll ()
{
// 05.02.19 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	ClearText();

	//-----_xZkqqHx_jEhHiMgJjFgAiJoGjHhAiDhJiDjDiBeFiDhFiDiJiDfGiCpAiDeOiDiKiDeB_xHqqkZx_ -----
	m_psidPenStyle			= FD_PEN_STYLE_UNUSE;
	m_mmfPenWeight			= 0.0;
	m_scidPenBackSColor		= FD_S_COLOR_TRANSPARENT;
	m_scidBrushBackSColor	= FD_S_COLOR_TRANSPARENT;
//----- 06.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDeHiDgGiDeCiDfOjEhHiMgJjAeGiCpAjAnNjCoIiBeC_xHqqkZx_
	m_crBackground = g_pReg->GetOptiSheetColor();
//----- 06.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iDhNiDeFiDfIiDhLiDfOiDjDiCmMiPpDjBnE_xHqqkZx_.
	m_bIsBtnDown = FALSE;
	// _xZkqqHx_iNmEjFgAiJoGiOjOiCmJiPmBiLiOiClHiCoJjHmMiIoGiBeC_xHqqkZx_
	m_nrtClearRgn.Empty();
	// Callback_xZkqqHx_iCpAiPmBiLiO_xHqqkZx_.
	m_fncCallback = NULL;

//----- 05.02.19 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiFjFlNjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
	m_wFixResize = FD_RPT_NONE;
//----- 05.05.03 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmMjAiCjClMjFpLiMpMiCmMjFjEjFgJiDiKiDfEiDeDiDfJjFpLjGeAiBeC_xHqqkZx_
//	m_wResizeVert = FD_RPT_NONE;
//----- 05.05.03 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iDgFiDeMiDfIiDgHiPgLiPkMiOjOiCmJjFjEjFgJiPgLiPkMiBeI_xHqqkZx_
	m_bIsShortenByText = FALSE;
//----- 05.02.19 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

	// _xZkqqHx_iClBiCmMiDeFiDeCiDjDiDgIiDeFiCmMiDfEiDeDiDfJiBeC_xHqqkZx_
	m_mmrtWindow.SetRect(0,0,10,10);
	// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDjEhKjHpBiBeCiDeHiDgGiDeCiDfOiDeFiDeCiDjDiDgIiDeFiNlGiPoD_xHqqkZx_=(0,0)_xZkqqHx_iCmJjAlDiLeLiJlLiBeC_xHqqkZx_
	m_vmmptPoly.clear();
	m_vmmptPoly.push_back(DBLPoint(0,0));
	m_vmmptPoly.push_back(DBLPoint(10,0));
	m_vmmptPoly.push_back(DBLPoint(10,10));
	m_vmmptPoly.push_back(DBLPoint(0,10));
	m_vmmptPoly.push_back(DBLPoint(0,0));

	m_mmMarginL = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGiDhNiBfLiDfHiDjD_xHqqkZx_.
	m_mmMarginT = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDiDhNiBfLiDfHiDjD_xHqqkZx_.
	m_mmMarginR = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFiDhNiBfLiDfHiDjD_xHqqkZx_.
	m_mmMarginB = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKiDhNiBfLiDfHiDjD_xHqqkZx_.

	m_byVertAlign = FDRC_AL_TOP;	// _xZkqqHx_jAiCjClMjFpLiMpMiCmMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiBeC_xHqqkZx_

	// ClearText_xZkqqHx_iCmFiCmNiNhDiDiMiDeDiDeBiDeFiDgHiMhGiOfKiCpAiClHiCoJiCmMiCmFiBeBjBlMiCmMjFmPjAjEiCpAiPiJiKpKiJlLiClFiClNiMoDiCmJiOmAiNhDiBeC_xHqqkZx_
	ClearText();

//----- 05.07.09 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiCpAiJeCiClHiBeC_xHqqkZx_2004.05.13_xZkqqHx_iDeDiDfOiDgAiClDiCpBiCmMiMgGiOkGjEmCiPjBiCkLiNjOiCnNiCmFiBeBiPmBiCkGiClNiDeFiDeCiDjDiDgIiDeFiCnG_xHqqkZx_
	// _xZkqqHx_iDeDiDhIiDjDiDgHiCpAjBjHiCmBiCmEiClFiCnMiCkEiDhNiDeFiDfIiDiGiBfLiDgFiDeCiDiKiDgFiDeCiCmMjGoCjBoIiCkKjFpBiNjAiBeC_xHqqkZx_
	if (::IsWindow(m_hWnd))
		BASE_CLASS::MoveWindow(CRect(-1, -1, 0, 0));
//----- 05.07.09 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::ClearAll.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ClearAllSession
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLjBfDjFjEiCpAiPmBiLiOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::ClearAllSession ()
{
	// Redo,Undo_xZkqqHx_jHhAiDfCiDhNiDjDiDgIjHpBiBeC_xHqqkZx_
	m_byvCmdQueue.clear();
	m_lCmdPos = 0;
} // CFCWndRichEdit::ClearAllSession.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiDgGiBfLiDfOiCpAiDfCiDhDiBfLiClFiCmEjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	byvQueue	:_xZkqqHx_iDeMiDiFiBfLiCmMiDfCiDhDiBfLiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.01.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetCmdQueue (BYTEVector& byvQueue) const
{
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCpAiBeBiNmFiPiJiCkJiCoHiMlLiNnNiImKjChFiCnMiCmFiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
	byvQueue.clear();
	byvQueue.insert(byvQueue.end(), m_byvCmdQueue.begin(),
									m_byvCmdQueue.begin() + m_lCmdPos);
} // CFCWndRichEdit::GetCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiDgGiBfLiDfOiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lQueueSz	:_xZkqqHx_iDfCiDhDiBfLiClHiCoJiDgGiBfLiDfOiDfEiDeDiDfJiCpAiOhHjCoIiBeC_xHqqkZx_
 *			bypQueue	:_xZkqqHx_iDfCiDhDiBfLiClHiCoJiDgGiBfLiDfOiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lQueuePos	:_xZkqqHx_iDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.01.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCmdQueue (long lQueueSz, const BYTE* bypQueue, long lQueuePos)
{
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
	m_byvCmdQueue.clear();
	m_byvCmdQueue.insert(m_byvCmdQueue.end(), bypQueue, bypQueue + lQueueSz);
	m_lCmdPos = lQueuePos;
} // CFCWndRichEdit::SetCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCmdQueueSize
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiCmMiDfEiDeDiDfJiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiDfEiDeDiDfJiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::GetCmdQueueSize () const
{
	return m_byvCmdQueue.size();
} // CFCWndRichEdit::GetCmdQueueSize.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCurIndex
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiDeKiDiMiDgCiDgHiImKjChFiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.24 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::GetCurIndex () const
{
	return m_lCurIndex;
} // CFCWndRichEdit::GetCurIndex.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCurIndex
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiDeKiDiMiDgCiDgHiImKjChFiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.24 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCurIndex (long lIndex)
{
	m_lCurIndex = lIndex;
	m_mmCaretX = RepositionCaret();
//----- 05.07.05 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
	ResetCurFormat();
//----- 05.07.05 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::SetCurIndex.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCurCharPos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiImKjChFiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lCurLine	: _xZkqqHx_jFlGiOjKiImKjChFiCmMiNhD_xHqqkZx_
 *			lCurChar	: _xZkqqHx_jFlGiOjKiImKjChFiCmMjHpB_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetCurCharPos (long& lCurLine, long& lCurChar) const
{
	IndexToCharPos(lCurLine, lCurChar, m_lCurIndex);
} // CFCWndRichEdit::GetCurCharPos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCurCharPos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiImKjChFiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lCurLine	: _xZkqqHx_jFlGiOjKiImKjChFiCmMiNhD_xHqqkZx_
 *			lCurChar	: _xZkqqHx_jFlGiOjKiImKjChFiCmMjHpB_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCurCharPos (long lCurLine, long lCurChar)
{
	m_lCurIndex = CharPosToIndex(lCurLine, lCurChar);
	m_mmCaretX = RepositionCaret();
} // CFCWndRichEdit::SetCurCharPos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetIndexSize
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBfDjBmMiCmMjFlGiOjKjAjEiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNmFiMoDiCmMiNhDiCmMiNmFiMoDiCmMjFlGiOjKiBgJiJpMiNhDiBgKiCmNiBeBjBfDiDeOiDiKiDeBiCmMiPoKiNiHiCoAjBlGiNnNiClFiCmIiCkPiCoKiCmO_xHqqkZx_
 *			_xZkqqHx_iCmIiCoHiCmIiCkCiInHiBeBiDfEiDeDiDfJiCmJiKnMiCnPiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.18 Fukushiro M. CharPosToIndex_xZkqqHx_iCpAiMmEiCnBiPgPiClHiCoGiCkEiCmJjFmPiNfIiBeC_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::GetIndexSize () const
{
	// _xZkqqHx_iNmFiMoDiCmMiCfAjFlGiOjKiBgJiJpMiNhDiBgKiCmNiDeKiDeFiDjDiDgHiClFiCmIiCkCiBeC_xHqqkZx_
	return CharPosToIndex(m_vEditLine.size(), 0) - 1;
} // CFCWndRichEdit::GetIndexSize.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetChar
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	lIndex_xZkqqHx_iCmFiOhHjCoIiClFiClNjFlGiOjKiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIndex	: _xZkqqHx_jFnEiClHjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfI_xHqqkZx_
 *************************************************************************/
const FCEditChar& CFCWndRichEdit::GetChar (long lIndex) const
{
	long	lCurLine, lCurChar;
	IndexToCharPos(lCurLine, lCurChar, lIndex);
	return m_vEditLine[lCurLine].m_vEditChar[lCurChar];
} // CFCWndRichEdit::GetChar.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetLineSize
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDjAjEiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iNhDjAjEiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iPnKiNnH_xHqqkZx_>	SDK_xZkqqHx_iCnGiCmM_xHqqkZx_Export_xZkqqHx_jHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.10.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::GetLineSize () const
{
	return m_vEditLine.size();
} // CFCWndRichEdit::GetLineSize.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCmMiNhDiCmMiPoOjFpBiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	:_xZkqqHx_iNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iNhDiDiMiDfCiBfLiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iPnKiNnH_xHqqkZx_>	SDK_xZkqqHx_iCnGiCmM_xHqqkZx_Export_xZkqqHx_jHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.10.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
const FCEditLine& CFCWndRichEdit::GetLine (long lLine) const
{
	return m_vEditLine[lLine];
} // CFCWndRichEdit::GetLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetSelectNormal
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCmEiCkCiCoJjEmNiImNiCpAjFnEiClHiBeC_xHqqkZx_lFrom <= lTo_xZkqqHx_iCkKjFnLiPnIiClDiCoKiCmEiCkCiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lFrom	:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiPiJiCmMjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *			lTo		:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiMoDiCmMjFlGiOjKiCmMiOjPiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCoJjEmNiImNiCmNiBeB_xHqqkZx_[lFrom, lTo)_xZkqqHx_iCmMjFlGiOjKiCmFiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.26 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetSelectNormal (long& lFrom, long& lTo) const
{
	lFrom = m_lSelFrom;
	lTo = m_lSelTo;
	if (lTo < lFrom) Exchange(lTo, lFrom);
} // CFCWndRichEdit::GetSelectNormal.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetSelect
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCmEiCkCiCoJjEmNiImNiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lFrom	:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiPiJiCmMjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *			lTo		:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiMoDiCmMjFlGiOjKiCmMiOjPiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCoJjEmNiImNiCmNiBeB_xHqqkZx_[lFrom, lTo)_xZkqqHx_iCmMjFlGiOjKiCmFiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	lFrom < lTo _xZkqqHx_iCmGiCmNiMmAiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.22 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetSelect (long& lFrom, long& lTo) const
{
	lFrom = m_lSelFrom;
	lTo = m_lSelTo;
} // CFCWndRichEdit::GetSelect.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetSelect
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjEmNiImNiCmMjFlGiOjKiCpAjBeJjBpAiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lFrom	:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiPiJiCmMjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lTo		:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiMoDiCmMjFlGiOjKiCmMiOjPiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCoJjEmNiImNiCmNiBeB_xHqqkZx_[lFrom, lTo)_xZkqqHx_iCmMjFlGiOjKiCmFiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiCpAjCmHiJmBiBeC_xHqqkZx_
 *			00.01.28 Fukushiro M. _xZkqqHx_iMlLiNnNiCmMjFlGiOjKiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
 *			00.07.19 Fukushiro M. _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkCiPoKiNiHiCmMiPiIjHjNiCpAjCmHiJmBiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetSelect (long lFrom, long lTo)
{
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkCiPoKiNiHiCmNiBeBjEmNiImNiJpAiPjM_xHqqkZx_ -----
	if (lFrom == lTo)
	{
		lFrom = -1;
		lTo = -1;
	}
	//----- _xZkqqHx_iMlLiNnNiCmMjBeJjBpAjEmNiImNiCpAjAlDiLeLiJlL_xHqqkZx_ -----
	long lSelFromOld, lSelToOld;
	GetSelectNormal(lSelFromOld, lSelToOld);
	//----- _xZkqqHx_jAfGiClFiCkCjBeJjBpAjEmNiImNiCpAjAlDiLeLiJlL_xHqqkZx_ -----
	long lSelFromNew= (lFrom < lTo) ? lFrom : lTo;
	long lSelToNew	= (lFrom < lTo) ? lTo : lFrom;
	// _xZkqqHx_jAfGiClFiCkCjEmNiImNiCpAjAnNjCoIiBeC_xHqqkZx_
	m_lSelFrom	= lFrom;
	m_lSelTo	= lTo;

	// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
	ResetCurFormat();

	// _xZkqqHx_jFfMiOkGjCiGiCmFiCmIiCkCiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
	if (!::IsWindow(m_hWnd) || !IsWindowVisible()) return;

	// _xZkqqHx_jDpBiCmCiCmMjHmMiIoGiCmMiPgEiCmIiCmBiCmEiCkCiCmIiCkCjFjEjFkKiClOiCkPiCpAiLiBiCnPiCoJ_xHqqkZx_.
	if (lSelFromOld < lSelToNew && lSelFromNew < lSelToOld)
		::Exchange(lSelToOld, lSelFromNew);
	// _xZkqqHx_iMlLiNnNiCmMjBeJjBpAiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect(lSelFromNew, lSelToNew, lSelFromOld, lSelToOld);

	// _xZkqqHx_iDhCiDiFiBfLiCnGiBeBjBeJjBpAjFmPiNfIiCpAjCmKjCgNiBeC_xHqqkZx_
	if (IsWindowVisible())
		g_pView->PostMessage(WM_USER_TEXT_SELECT_CHANGED);
} // CFCWndRichEdit::SetSelect.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::DrawSelect
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAjFjEjFkKiCmMiBeBjBeJjBpAiDhNiBfLiDeOiCpAjFfMiOkGiBeFjEpBjFfMiOkGiCmJiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pDC	:_xZkqqHx_jFgAiJoGjHhAiDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiCpAiOhHjCoIiBeC_xHqqkZx_NULL_xZkqqHx_iCmMiPoKiNiHiCmNiBeBiClBiClPiCoHiCmF_xHqqkZx_
 *				 _xZkqqHx_jHhAiInDiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::DrawSelect (CDC* pDC)
{
	DrawSelect(m_lSelFrom, m_lSelTo, -1, -1, pDC);
} // CFCWndRichEdit::DrawSelect.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::DrawSelect
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjBeJjBpAjEmNiImNiCmMiBeBjBeJjBpAiDhNiBfLiDeOiCpAjFfMiOkGiBeFjEpBjFfMiOkGiCmJiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lFrom0	:_xZkqqHx_jBeJjBpAjEmNiImNiCePiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lTo0	:_xZkqqHx_jBeJjBpAjEmNiImNiCePiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lFrom1	:_xZkqqHx_jBeJjBpAjEmNiImNiCfAiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lTo1	:_xZkqqHx_jBeJjBpAjEmNiImNiCfAiCpAiOhHjCoIiBeC_xHqqkZx_
 *			pDC		:_xZkqqHx_jFgAiJoGjHhAiDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiCpAiOhHjCoIiBeC_xHqqkZx_NULL_xZkqqHx_iCmMiPoKiNiHiCmNiBeBiClBiClPiCoHiCmF_xHqqkZx_
 *					 _xZkqqHx_jHhAiInDiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::DrawSelect (long lFrom0, long lTo0, long lFrom1, long lTo1, CDC* pDC)
{
	if (lFrom0 == lTo0 && lFrom1 == lTo1) return;
	// _xZkqqHx_jFfMiOkGjCiGiCmFiCmIiCkCiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
// 05.03.01 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (!IsWindowVisible()) return;
	if (!::IsWindow(m_hWnd) || !IsWindowVisible()) return;
	BOOL bOwnDC = FALSE;
	if (pDC == NULL)
	{
		bOwnDC = TRUE;
		pDC = new CClientDC(this); // _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiCpAiNoMjAkMiBeC_xHqqkZx_
	}
	{
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		COLORREF crBack;
//		if (m_scidBrushBackSColor == FD_S_COLOR_TRANSPARENT)
//			crBack = g_pReg->GetOptiSheetColor();
//		else
//			crBack = ::OptiColor(g_pEnv->scid2cref(m_scidBrushBackSColor));
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

		//----- _xZkqqHx_jEhHiMgJjAeGiCkJiCoHiBeBjBeJjBpAjAeGiCpAiNoMjAkMiClHiCoJ_xHqqkZx_ -----
		// _xZkqqHx_iDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmMjBeJjBpAjEmNiImNiCmMjAeGiCpAiOoGjDlOiBeC_xHqqkZx_
		COLORREF crSelColor = g_pReg->GetOptiRegColor(FDCL_TEXT_EDIT_SELECTION);
		long lColorDistance =	POW2(GetRValue(crSelColor) - GetRValue(m_crBackground)) +
								POW2(GetGValue(crSelColor) - GetGValue(m_crBackground)) +
								POW2(GetBValue(crSelColor) - GetBValue(m_crBackground));
		if (lColorDistance < 1200)
		//----- _xZkqqHx_jEmNiImNjAeGiCmGjEhHiMgJjAeGiCkKiLnPiCkCiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jEhHiMgJjAeGiCmGiNmFiCoAiInJiCmIiCoJjAeGiCpAiNoMjAkMiClHiCoJiBeC_xHqqkZx_
			crSelColor = ::OptiColor(RGB(	(GetRValue(m_crBackground) < 128) ? 255 : 0,
											(GetGValue(m_crBackground) < 128) ? 255 : 0,
											(GetBValue(m_crBackground) < 128) ? 255 : 0));
		}
		// XORPEN_xZkqqHx_iCmFjDgIiCoIjCnHiClFiClNiOjOiBeBiClBiCmMjAeGiCmJiCmIiCoJiCoGiCkEiCmJjClCjAkOiBeC_xHqqkZx_
		FCEditDraw eDraw(pDC, 0, m_crBackground ^ crSelColor, -1, 0, 0);


		FCEditLineVector::iterator iLine;
		FCEditCharVector::iterator iChar;
		long lIndex = 0;
		mmetol mmX, mmY;
		for (iLine = m_vEditLine.begin(); iLine != m_vEditLine.end(); iLine++)
		{
			// _xZkqqHx_iDgFiDeMiDfIiDgHiNlGiNmAjFfHiCmJ_xHqqkZx_[_xZkqqHx_jFjEjFgJiNlGiNmAjFfHiBhLiNlGiDhNiBfLiDfHiDjD_xHqqkZx_]_xZkqqHx_iCpAjAnNjCoIiBeC_xHqqkZx_
			if ((*iLine).m_byLineType == FDRC_LT_HEAD)
				mmX = m_mmMarginL + (*iLine).m_mmStartIndent;
			else	// FDRC_LT_CONTINUE.
				mmX = m_mmMarginL + (*iLine).m_mmStartIndent + (*iLine).m_mmOffset;
			// _xZkqqHx_iDgFiDeMiDfIiDgHiCmMiNhDiCmMiPoDjCfLiCmM_xHqqkZx_Y_xZkqqHx_iNmAjFfHiCpAiOoGjDlOiBeC_xHqqkZx_
			mmY = (*iLine).m_mmY;
			// _xZkqqHx_iDgFiDeMiDfIiDgHiCkKjFgAiJoGjEmNiImNiCpAiIoMiCoKiCmEiCkCiCoJiPoKiNiHiCmNiDiLiBfLiDhGiCpAiPeJjHlJiBeC_xHqqkZx_
			if (m_mmrtWindow.Height() - m_mmMarginB <
				mmY + (*iLine).m_mmfTMHeight + (*iLine).m_mmfTMExternalLeading) break;

			//----- _xZkqqHx_iNhDiCmMjFlGiOjKiCpAiCfAjFlGiOjKiClIiCmCiDiLiBfLiDhG_xHqqkZx_ -----
			for (iChar = (*iLine).m_vEditChar.begin();
				 iChar != (*iLine).m_vEditChar.end(); iChar++)
			{
				switch ((*iChar).m_wChar)
				{
				case FDRCH_CONTINUE:
					break;
				case FDRCH_RETURN:	// _xZkqqHx_iJpMiNhDiBeC_xHqqkZx_
//----- 01.02.09 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//					lIndex++;
//					break;
//----- 01.02.09 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
				case WCH_TAB:	// _xZkqqHx_iDfOiDhFiBeC_xHqqkZx_
				case WCH_SPC:	// _xZkqqHx_iLpDjEjCiBeC_xHqqkZx_
				default:		// _xZkqqHx_jFlGiOjKiBeC_xHqqkZx_
					//----- _xZkqqHx_jBeJjBpAiPpDjBnEiCmIiCoHiCmOiBeBjElNjDfNiClHiCoJ_xHqqkZx_ -----
					if ((lFrom0 <= lIndex && lIndex < lTo0) ||
						(lTo0 <= lIndex && lIndex < lFrom0) ||
						(lFrom1 <= lIndex && lIndex < lTo1) ||
						(lTo1 <= lIndex && lIndex < lFrom1))
					{
						eDraw.RectFill(CRect(
							mm2lg(mmX + (*iChar).m_mmfPreSpace),
							mm2lg(mmY),
							mm2lg(mmX + (*iChar).m_mmfPreSpace +
								(*iChar).m_mmfWidth + tw2mm((*iChar).m_nAfterSpace)),
							mm2lg(mmY + (*iLine).m_mmfTMHeight +
										(*iLine).m_mmfTMExternalLeading)));
					}
					lIndex++;
					break;
				}
				mmX += (*iChar).m_mmfPreSpace + (*iChar).m_mmfWidth +
						tw2mm((*iChar).m_nAfterSpace);
			}
		}
	}
	if (bOwnDC)
	{
		delete pDC;
	}
} // CFCWndRichEdit::DrawSelect.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineAll
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBfDiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcLineAll ()
{
	// _xZkqqHx_iNhDiDgHiDgCiDhGiCpAiPiJiKpKiJlLiBeCiClBiCoKiCpAiClFiCmIiCkCiCmGiBeB_xHqqkZx_Redo/Undo_xZkqqHx_iCmFiDiMiDeDiDeBiDeFiDgHiCkK_xHqqkZx_
	// _xZkqqHx_iIoBiCmBiCmEiCkNiCoJiBeC_xHqqkZx_
	m_vEditLine.front().m_mmY = m_mmMarginT;
	// _xZkqqHx_iKkOjBfDiCmJ_xHqqkZx_0_xZkqqHx_iClOiCmGiBeBjFeLiClIiMhGiOfKiCkKiOlIjEhDiClHiCoJiCkJiCoHiBeC_xHqqkZx_
	if (m_vEditLine.front().m_mmY == 0.0)
		m_vEditLine.front().m_mmY = MY_DBL_ROUGH_EPSILON;
	CalcLineBelow(0);
} // CFCWndRichEdit::CalcLineAll.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineBelow
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	lLineFrom_xZkqqHx_iCmMiNhDiCkKjAoGjDkKiNhDiCmMiPoKiNiHiBeBiClLiCoKiImIiJlKiCmMiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
 *			lLineFrom_xZkqqHx_iCmMiNhDiCkKiMhAjBlBiNhDiCmMiPoKiNiHiBeBiCnMiClIjAoGjDkKiNhDiCnMiCmFjGnPiClFiCmEiCkJiCoHiBeBiClLiCoK_xHqqkZx_
 *			_xZkqqHx_iImIiJlKiCmMiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiBeCjFjEjFgJiDfEiDeDiDfJjFmPiNfIiOhHjCoIiCkKiCkAiCoJiPoKiNiHiCmNiBeB_xHqqkZx_
 *			_xZkqqHx_iDgFiDeMiDfIiDgHiCmJiDhEiDeCiDgCiDgHiClHiCoJiDfEiDeDiDfJiCmJjFmPiNfIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLineFrom	:_xZkqqHx_iNmEiMhGiOfKiKeKiOgOiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcLineBelow (long lLineFrom)
{
	// lLineFrom_xZkqqHx_iImIiJlKiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
	CalcLineBelowSub(lLineFrom);

	// _xZkqqHx_iDgFiDeMiDfIiDgHiDiKiDfEiDeDiDfJiOjOiCmJjFjEjFgJiCpAiDiKiDfEiDeDiDfJiClFiCmIiCkCiPoKiNiHiCmNiClBiClBiCmFiPeJjHlJiBeC_xHqqkZx_
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	if (GetResizeHorz() == FD_RPT_NONE &&
//		GetResizeVert() == FD_RPT_NONE) return;
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	if (GetFixResize() == FD_RPT_NONE) return;
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

	// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJiCmMiDgPiDgCiDeOiDeBiDgCiDhGiBeC_xHqqkZx_
	const DBLRect mmrtWindowOrig = m_mmrtWindow;

	if (IsTextOver())
	//----- _xZkqqHx_iDgFiDeMiDfIiDgHiCkKiDhNiDfIiDeOjAhNiMgAiCmMiKePjBkEiCmJiCkAiCnDiCoKiClNiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_jBePiJpBiBeBiDhNiDfIiDeOjAhNiMgAjCiGiCmJjEhKjChFiCmFiCkLiClNjFlGiOjKjAjEiBeC_xHqqkZx_
		long lInsideCharCountPrev = -1;
		// _xZkqqHx_jBePiJpBiCmMiDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJiBeC_xHqqkZx_
		DBLRect mmrtWindowPrev;
		// _xZkqqHx_jBePiJpBiCmMiDhNiDfIiDeOjEhKjHpBiBeC_xHqqkZx_
		DBLPointVector vmmptPolyPrev;
		// _xZkqqHx_jCoCiOhOiDeKiDeFiDjDiDfOiBeCjGlDiInDjGkBiCmIiKgHjBoFiCpAjGgIiCkOiClNiCnPiBeC_xHqqkZx_
		long lStopCount = 0;
		do
		{
			// _xZkqqHx_iDhNiDfIiDeOjAhNiMgAjCiGiCmJjEhKjChFiCmFiCkLiClNjFlGiOjKjAjEiBeC_xHqqkZx_
			long lInsideCharCount = 0;
			// _xZkqqHx_iDhNiDfIiDeOjAhNiMgAiKePiCmJiCkAiCnDiCoKiClNjFlGiOjKjAjEiBeC_xHqqkZx_
			long lOutsideCharCount = 0;
			FCEditLineVector::iterator iLine;
			for (iLine = m_vEditLine.begin(); iLine != m_vEditLine.end(); iLine++)
			{
				if (m_mmrtWindow.Height() - m_mmMarginB < (*iLine).m_mmY) break;
				lInsideCharCount += (*iLine).m_vEditChar.size();
			}
			for (; iLine != m_vEditLine.end(); iLine++)
				lOutsideCharCount += (*iLine).m_vEditChar.size();

			if (lInsideCharCountPrev == lInsideCharCount)
			//----- _xZkqqHx_jBePiJpBiCmGiDhNiDfIiDeOiCmJiOpLiCnMiCmBiClNjFlGiOjKjAjEiCkKjDkPiClGiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_jFlGiOjKjAjEiCkKjDkPiClGiPoKiNiHiCmNjBePiJpBiCmMjFmPjAjEiCmNiLeMiJkPiClFiCmIiCkCiBeC_xHqqkZx_
				// _xZkqqHx_iDfEiDeDiDfJiCpAjBoFiCkLiCkNiClFiCmEiCoAiOpLiCnMiCoJjFlGiOjKjAjEiCkKjDkPiClGiPoKiNiHiBeB_xHqqkZx_
				// _xZkqqHx_iClLiCmMiDfEiDeDiDfJiKgHjBoFiCmNjGlDiInDjGkBiCmIiCoAiCmMiCmIiCmMiCmFiJkPiCkGiCmIiCkCiBeC_xHqqkZx_

				// _xZkqqHx_jCoCiOhOiDeKiDeFiDjDiDfOiCpAiJmBiOfKiBeC_xHqqkZx_
				lStopCount++;
				if (lStopCount == 5)
				//----- _xZkqqHx_jGlDiInDjGkBiCmIiKgHjBoFiCpAiCfEiJpBiMeKiCoIjFnEiClFiClNiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_jBePiJpBiCmGiBeBiDhNiDfIiDeOjAhNiMgAjCiGiCmJjEhKjChFiCmFiCkLiClNjFlGiOjKjAjEiCkKjDkPiClGiPoKiNiHiCmNiBeB_xHqqkZx_
					// _xZkqqHx_iDfEiDeDiDfJiKgHjBoFiCkKiMpIiJmKiCkKjGlDiCkJiCmBiClNiCmGiCkCiCkEiClBiCmGiCmFiBeB_xHqqkZx_
					// _xZkqqHx_iKgHjBoFjBePiCmJjGnPiClFiCmEiDiMiDeDiDeBiDeFiDgHiClFjClMiClFiCmEiPeJjHlJiBeC_xHqqkZx_
					m_mmrtWindow = mmrtWindowPrev;
					m_vmmptPoly = vmmptPolyPrev;
					CalcLineBelowSub(-1);
					break;
				}
			} else
			//----- _xZkqqHx_jBePiJpBiCmGiDhNiDfIiDeOiCmJiOpLiCnMiCmBiClNjFlGiOjKjAjEiCkKiInJiCmIiCoJiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_jCoCiOhOiDeKiDeFiDjDiDfOiCpAiDiKiDfKiDgCiDgHiBeC_xHqqkZx_
				lStopCount = 0;
				// _xZkqqHx_jBePiJpBiCmMjFmPjAjEiCmGiClFiCmEiKgPiCkGiCmEiCkIiCkNiBeC_xHqqkZx_
				lInsideCharCountPrev = lInsideCharCount;
				mmrtWindowPrev = m_mmrtWindow;
				vmmptPolyPrev = m_vmmptPoly;
			}
			// _xZkqqHx_iKgHjBoFjEhLjHkGiCpAiMhGiOfKiBeCiMlLiNnNiCmMjBiNjFlGiOjKjAjEiCmMiCfAiCfAiCePiBjDiCkKiOpLiCnMiCoJiCoGiCkEiBeBjEhLjHkGiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
			double dR = 0.0;
			if (lInsideCharCount == 0)
				dR = 2.0;
			else
				dR = (double(lInsideCharCount + lOutsideCharCount) * 1.1) / double(lInsideCharCount);

			// _xZkqqHx_jAiFjFlNiBeFjAiCjClMiCmMjHlMjFpLiMpMiCmJiDiKiDfEiDeDiDfJiCmMiPoKiNiHiCmNiBeBiKgHjBoFjEhLjHkGiCmMjFlNjFpLiNkKiCpAiOoGiCoJiBeC_xHqqkZx_
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//			if (GetResizeHorz() != FD_RPT_NONE &&
//				GetResizeVert() != FD_RPT_NONE)
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
			if ((GetFixResize() & FD_RPT_H_MASK) != FD_RPT_NONE &&
				(GetFixResize() & FD_RPT_V_MASK) != FD_RPT_NONE)
//----- 05.05.03 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
				dR = sqrt(dR);

			DBLPoint mmptFixPoint(0.0, 0.0);
			DBLPoint mmptRatio(1.0, 1.0);
// 05.05.03 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//			switch (GetResizeHorz())
			switch (GetFixResize() & FD_RPT_H_MASK)
			{
			case FD_RPT_H_LEFT:	// _xZkqqHx_jFjEjFgJiCmMiNlGjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
				mmptFixPoint.x = m_mmrtWindow.left;
				mmptRatio.x = dR;
				break;
			case FD_RPT_H_CENTER:	// _xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
				mmptFixPoint.x = (m_mmrtWindow.left + m_mmrtWindow.right) / 2.0;
				mmptRatio.x = dR;
				break;
			case FD_RPT_H_RIGHT:	// _xZkqqHx_jFjEjFgJiCmMiJeFjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
				mmptFixPoint.x = m_mmrtWindow.right;
				mmptRatio.x = dR;
				break;
			}
// 05.05.03 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//			switch (GetResizeVert())
			switch (GetFixResize() & FD_RPT_V_MASK)
			{
			case FD_RPT_V_TOP:		// _xZkqqHx_jFjEjFgJiCmMiPoDjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
				mmptFixPoint.y = m_mmrtWindow.top;
				mmptRatio.y = dR;
				break;
			case FD_RPT_V_CENTER:	// _xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
				mmptFixPoint.y = (m_mmrtWindow.top + m_mmrtWindow.bottom) / 2.0;
				mmptRatio.y = dR;
				break;
			case FD_RPT_V_BOTTOM:	// _xZkqqHx_jFjEjFgJiCmMiJlKjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
				mmptFixPoint.y = m_mmrtWindow.bottom;
				mmptRatio.y = dR;
				break;
			}
			// _xZkqqHx_iMmFjCoIjDfPiCpAiMlEjDfPiCmJiBeC_xHqqkZx_
			DBLRect mmrtWindowNew = m_mmrtWindow - mmptFixPoint;
			// _xZkqqHx_iDhEiDiMiBfLiDiAiCpAiKgHjBoFiBeC_xHqqkZx_
			mmrtWindowNew *= mmptRatio;
			// _xZkqqHx_jFjEjFgJiCmMiNmFjBoFiDfEiDeDiDfJiCpAiJhKiCkGiCmIiCkCiCoGiCkEiCmJiBeC_xHqqkZx_
			if (FD_OBJ_MAX_W < mmrtWindowNew.Width() ||
				FD_OBJ_MAX_H < mmrtWindowNew.Height()) break;
			// _xZkqqHx_iMmFjCoIjDfPiCpAiMlDiCmJjGnPiClFiCmEiDhEiDiMiBfLiDiAiCmJjAnNjCoIiBeC_xHqqkZx_
			m_mmrtWindow = mmrtWindowNew + mmptFixPoint;
			// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAiKgHjBoFiBeC_xHqqkZx_
			for (int iC = 0; iC < m_vmmptPoly.size(); iC++)
				m_vmmptPoly[iC] *= mmptRatio;
			// _xZkqqHx_jBfDiNhDiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
			CalcLineBelowSub(-1);
		} while (IsTextOver());
//----- 05.02.20 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	} else
//	//----- _xZkqqHx_iDgFiDeMiDfIiDgHiCkKiDhNiDfIiDeOjAhNiMgAiCmMjDoAjBkEiCmJiOpLiCnMiCmBiClNiPoKiNiH_xHqqkZx_ -----
//	{
//		if (GetIsShortenByText())
//		//----- _xZkqqHx_jCfKiCkNiClHiCoJiOhHjCoIiCkKiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
//		{
//			// _xZkqqHx_iNmFiMoDiCmMiNhDiCmMiNiCiClDiCpAiOfKiPgPiBeC_xHqqkZx_
//			mmetol mmLineHeight = m_vEditLine.back().m_mmfTMHeight + m_vEditLine.back().m_mmfTMExternalLeading;
//			// _xZkqqHx_iNmFiMoDiCmMiNhDiCmMiJlKjCfLiCpAiOfKiPgPiBeC_xHqqkZx_
//			mmetol mmTextBottom = m_vEditLine.back().m_mmY + mmLineHeight;
//			if (mmTextBottom + mmLineHeight <= m_mmrtWindow.Height() - m_mmMarginB)
//			//----- _xZkqqHx_iNmFiMoDiCmMiNhDiCmMiJlKiCmJiBeBiCoAiCkEiIoKiNhDjChFiCkPiCoJiDfIiDhJiBfLiDfIiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//			{
//				// _xZkqqHx_iDeJiDiKiDfHiDgJiDiLiDhNiDfIiDeOiCpAjFnLjBlGiBeC_xHqqkZx_
//				const DBLPointVector vmmptPolyOrig = m_vmmptPoly;
//
//				// _xZkqqHx_iPgLiPkMjEhLjHkGiCpAiMhGiOfKiBeC_xHqqkZx_
//				double dR = (mmTextBottom + m_mmMarginB) / m_mmrtWindow.Height();
//				// _xZkqqHx_jAiFjFlNiBeFjAiCjClMiCmMjHlMjFpLiMpMiCmJiDiKiDfEiDeDiDfJiCmMiPoKiNiHiCmNiBeBiKgHjBoFjEhLjHkGiCmMjFlNjFpLiNkKiCpAiOoGiCoJiBeC_xHqqkZx_
//				if (m_wResizeHorz != FD_RPT_NONE &&
//					m_wResizeVert != FD_RPT_NONE)
//					dR = sqrt(dR);
//				do
//				{
//					DBLPoint mmptFixPoint(0.0, 0.0);
//					DBLPoint mmptRatio(1.0, 1.0);
//					switch (m_wResizeHorz)
//					{
//					case FD_RPT_H_LEFT:	// _xZkqqHx_jFjEjFgJiCmMiNlGjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//						mmptFixPoint.x = mmrtWindowOrig.left;
//						mmptRatio.x = dR;
//						break;
//					case FD_RPT_H_CENTER:	// _xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//						mmptFixPoint.x = (mmrtWindowOrig.left + mmrtWindowOrig.right) / 2.0;
//						mmptRatio.x = dR;
//						break;
//					case FD_RPT_H_RIGHT:	// _xZkqqHx_jFjEjFgJiCmMiJeFjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiFjFlNjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//						mmptFixPoint.x = mmrtWindowOrig.right;
//						mmptRatio.x = dR;
//						break;
//					}
//					switch (m_wResizeVert)
//					{
//					case FD_RPT_V_TOP:		// _xZkqqHx_jFjEjFgJiCmMiPoDjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//						mmptFixPoint.y = mmrtWindowOrig.top;
//						mmptRatio.y = dR;
//						break;
//					case FD_RPT_V_CENTER:	// _xZkqqHx_jFjEjFgJiCmMjCiGiJjLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//						mmptFixPoint.y = (mmrtWindowOrig.top + mmrtWindowOrig.bottom) / 2.0;
//						mmptRatio.y = dR;
//						break;
//					case FD_RPT_V_BOTTOM:	// _xZkqqHx_jFjEjFgJiCmMiJlKjCfLiCpAiMmFjCoIiClFiBeBiDgFiDeMiDfIiDgHiDfEiDeDiDfJiCmJjFjEjFgJiDfEiDeDiDfJiCmMjAiCjClMjFpLiMpMiCpAiNiHiCoNiClJiCoJiBeC_xHqqkZx_
//						mmptFixPoint.y = mmrtWindowOrig.bottom;
//						mmptRatio.y = dR;
//						break;
//					}
//
//					DBLRect mmrtWindowNew = mmrtWindowOrig - mmptFixPoint;
//					mmrtWindowNew *= mmptRatio;
//					// _xZkqqHx_iDhEiDiMiBfLiDiAiCpAjAnNjCoIiBeC_xHqqkZx_
//					m_mmrtWindow = mmrtWindowNew + mmptFixPoint;
//					// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAjAnNjCoIiBeC_xHqqkZx_
//					for (int iC = 0; iC < m_vmmptPoly.size(); iC++)
//						m_vmmptPoly[iC] = vmmptPolyOrig[iC] * mmptRatio;
//					CalcLineBelowSub(-1);
//					dR += (1.0 - dR) / 2.0;
//				} while (IsTextOver());
//			}
//		}
//----- 05.02.20 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	}
	// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJiCmJjFmPiNfIiCkKiCkAiCoJiPoKiNiHiCmNiBeBiDiKiDfEiDeDiDfJiBeC_xHqqkZx_
	if (mmrtWindowOrig != m_mmrtWindow)
	{
		DBLRect mmrtSheetEx = g_pEnv->GetSheetRectEx();
		if (mmrtSheetEx.right < m_mmrtWindow.right)
			m_mmrtWindow -= DBLPoint(m_mmrtWindow.right - mmrtSheetEx.right, 0);
		if (mmrtSheetEx.bottom < m_mmrtWindow.bottom)
			m_mmrtWindow -= DBLPoint(0, m_mmrtWindow.bottom - mmrtSheetEx.bottom);
		if (m_mmrtWindow.left < mmrtSheetEx.left)
			m_mmrtWindow += DBLPoint(mmrtSheetEx.left - m_mmrtWindow.left, 0);
		if (m_mmrtWindow.top < mmrtSheetEx.top)
			m_mmrtWindow += DBLPoint(0, mmrtSheetEx.top - m_mmrtWindow.top);
		MoveWindowMM(m_mmrtWindow);
//----- 06.04.02 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
//----- 06.11.27 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
		if (::IsWindow(m_hWnd) && IsWindowVisible())
		//----- _xZkqqHx_iDeHiDgGiDeCiDfOjFfMiOkGjCiGiCmNiDiLiBfLiDiJiBfLjFmPiNfI_xHqqkZx_/_xZkqqHx_jEpBjFfMiOkGjCiGiCoAiCkAiCoIiCkGiCoJiClNiCnP_xHqqkZx_ -----
		{
//----- 06.11.27 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
			// _xZkqqHx_iDiLiBfLiDiJiBfLiCmMjAnNjCoIiBeC_xHqqkZx_
			FFGetMainWnd()->HRuler()->SetTextRange(this, m_mmrtWindow.left + m_mmMarginL,
													m_mmrtWindow.right - m_mmMarginR);
			FFGetMainWnd()->VRuler()->SetTextRange(this, m_mmrtWindow.top + m_mmMarginT,
													m_mmrtWindow.bottom - m_mmMarginB);
// 06.11.27 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ ()
		}
		// _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiNmEiMhGiOfKiBeCjDkPiOjOiCmJiDiLiBfLiDiJiBfLiCmMjFfMiOkGiCoAiNfIjAfGiBeC_xHqqkZx_
		m_mmCaretX = RepositionCaret();
//----- 06.04.02 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	}
} // CFCWndRichEdit::CalcLineBelow.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineBelowSub
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	lLineFrom_xZkqqHx_iCmMiNhDiCkKjAoGjDkKiNhDiCmMiPoKiNiHiBeBiClLiCoKiImIiJlKiCmMiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfK_xHqqkZx_.
 *			lLineFrom_xZkqqHx_iCmMiNhDiCkKiMhAjBlBiNhDiCmMiPoKiNiHiBeBiCnMiClIjAoGjDkKiNhDiCnMiCmFjGnPiClFiCmEiCkJiCoHiBeBiClLiCoK_xHqqkZx_
 *			_xZkqqHx_iImIiJlKiCmMiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLineFrom	:_xZkqqHx_iNmEiMhGiOfKiKeKiOgOiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *						 _xZkqqHx_iNmFiPiJiCmMiNhDiCkJiCoHiKkOjBfDiCmJiNmEiMhGiOfKiClHiCoJiPoKiNiHiCmN_xHqqkZx_-1_xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.10.28 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcLineBelowSub (long lLineFrom)
{
	// _xZkqqHx_iDhEiDiLiDfIiDeOiDiKiBfLiDjDiDeHiDgGiDeCiDfOiDiCiBfLiDgIiCkJiBeI_xHqqkZx_
// 05.03.01 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	const BOOL bFullMode = IsFullScreenEditMode() && IsWindowVisible();
	const BOOL bFullMode = IsFullScreenEditMode();

//----- 05.02.20 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	if (lLineFrom == -1)
	//----- _xZkqqHx_jBfDiNhDiCpAiNmEiMhGiOfKiCmMiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_iNhDiDgHiDgCiDhGiCpAiPiJiKpKiJlLiBeC_xHqqkZx_
		m_vEditLine.front().m_mmY = m_mmMarginT;
		lLineFrom = 0;
	}
//----- 05.02.20 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

	if (lLineFrom == 0)
	//----- _xZkqqHx_iIoKjEnEiPoDiCmMiNhDiCkJiCoHiMhGiOfKiCmMiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_iNhDiKeKiOgOiImKjChFiCkKiKkOjBfDiCmJ_xHqqkZx_0_xZkqqHx_iClOiCmGiBeBjFeLiClIiMhGiOfKiCkKiOlIjEhDiClHiCoJiCkJiCoHiBeC_xHqqkZx_
		if (m_vEditLine.front().m_mmY == 0.0)
			m_vEditLine.front().m_mmY = MY_DBL_ROUGH_EPSILON;
	}
	if (!bFullMode && m_byVertAlign == FDRC_AL_V_CENTER)
	//----- _xZkqqHx_jCmKiPoNiJoGjGmKiDiCiBfLiDgI_xHqqkZx_ _xZkqqHx_iBjF_xHqqkZx_ _xZkqqHx_iPgDjCiGjAfDiImKjChFjBlFiCkG_xHqqkZx_ ----
	{
		// _xZkqqHx_iCnMiClIiMlLiNnNiCmMiImKjChFiCkJiCoHiMhGiOfKiClHiCoJiClNiCnPiCmJiBeB_xHqqkZx_m_vEditLine.front().m_mmY_xZkqqHx_iCpA_xHqqkZx_
		// _xZkqqHx_iPiJiKpKiJlLiClFiCmIiCkCiBeCiClBiCoKiCpAiPiJiKpKiJlLiClHiCoJiCmGiBeBjFlGiOjKiCpAjDpMjHmNiClHiCoJjDhIiCmJjEpHjGkNiCmJ_xHqqkZx_
		// _xZkqqHx_iPoDiJlKiCmJiCnDiCoHiCmCiCkCiCmEiClFiCnMiCkEiBeC_xHqqkZx_
		CalcLineBelowCenter();
	} else
	if (!bFullMode && m_byVertAlign == FDRC_AL_BOTTOM)
	//----- _xZkqqHx_jCmKiPoNiJoGjGmKiDiCiBfLiDgI_xHqqkZx_ _xZkqqHx_iBjF_xHqqkZx_ _xZkqqHx_iJlKiImKjChFjBlFiCkG_xHqqkZx_ ----
	{
		// _xZkqqHx_iCnMiClIiMlLiNnNiCmMiImKjChFiCkJiCoHiMhGiOfKiClHiCoJiClNiCnPiCmJiBeB_xHqqkZx_m_vEditLine.front().m_mmY_xZkqqHx_iCpA_xHqqkZx_
		// _xZkqqHx_iPiJiKpKiJlLiClFiCmIiCkCiBeCiClBiCoKiCpAiPiJiKpKiJlLiClHiCoJiCmGiBeBjFlGiOjKiCpAjDpMjHmNiClHiCoJjDhIiCmJjEpHjGkNiCmJ_xHqqkZx_
		// _xZkqqHx_iPoDiJlKiCmJiCnDiCoHiCmCiCkCiCmEiClFiCnMiCkEiBeC_xHqqkZx_
		CalcLineBelowBottom();
	} else
	//----- _xZkqqHx_jBfDiJoGjGmKiDiCiBfLiDgI_xHqqkZx_ || _xZkqqHx_iPoDiImKjChFjBlFiCkG_xHqqkZx_ ----
	{
		mmetol mmTopOffset;
		mmetol mmBtmOffset;
		if (lLineFrom == 0)
		{
			m_vEditLine.front().m_mmY = m_mmMarginT;
			// _xZkqqHx_iKkOjBfDiCmJ_xHqqkZx_0_xZkqqHx_iClOiCmGiBeBjFeLiClIiMhGiOfKiCkKiOlIjEhDiClHiCoJiCkJiCoHiBeC_xHqqkZx_
			if (m_vEditLine.front().m_mmY == 0.0)
				m_vEditLine.front().m_mmY = MY_DBL_ROUGH_EPSILON;
		}
		CalcLineBelowTop(mmTopOffset, mmBtmOffset, lLineFrom);
	}
} // CFCWndRichEdit::CalcLineBelowSub.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineBelowTop
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	lLineFrom_xZkqqHx_iCmMiNhDiCkKjAoGjDkKiNhDiCmMiPoKiNiHiBeBiClLiCoKiImIiJlKiCmMiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
 *			lLineFrom_xZkqqHx_iCmMiNhDiCkKiMhAjBlBiNhDiCmMiPoKiNiHiBeBiCnMiClIjAoGjDkKiNhDiCnMiCmFjGnPiClFiCmEiCkJiCoHiBeBiClLiCoK_xHqqkZx_
 *			_xZkqqHx_iImIiJlKiCmMiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
 *			_xZkqqHx_jAoGjDkKiNhDiCmMiKeKiOgOiImKjChF_xHqqkZx_(m_mmY)_xZkqqHx_iCmNiBeBjHfMiCnPiOhHjCoIiClFiCmEiCkIiCkJiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmTopOffset	:_xZkqqHx_jAoGjDkKiNhDiCmMiPoDjFpLiCmMiMiEiKnEiCmMjBoFiCkLiClDiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmBtmOffset	:_xZkqqHx_iNmFiPeJiNhDiCmMiJlKjFpLiCmMiMiEiKnEiCmMjBoFiCkLiClDiCpAjFnEiClHiBeC_xHqqkZx_
 *			lLineFrom	:_xZkqqHx_iNmEiMhGiOfKiKeKiOgOiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcLineBelowTop (mmetol& mmTopOffset, mmetol& mmBtmOffset,
										long lLineFrom)
{
#define TOPLINE m_vEditLine.front()
#define PRELINE m_vEditLine[lLine-1]
#define CURLINE m_vEditLine[lLine]
#define LSTLINE m_vEditLine.back()
	// lLineFrom_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
	lLineFrom = JoinLineBelow(lLineFrom);
	// _xZkqqHx_jAoGjDkKiCmMiNhDiCkJiCoHiImIiNhOiCmMiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
	for (long lLine = lLineFrom; lLine < m_vEditLine.size(); lLine++)
	{
		//----- _xZkqqHx_iNhDiKeKiOgOiNmAjFfHiCpAiOfKiPgPiClHiCoJ_xHqqkZx_ -----
//----- 01.01.29 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		if (0 < lLine)
//			CURLINE.m_mmY =	PRELINE.m_mmY +
//							PRELINE.m_mmfTMHeight +
//							PRELINE.m_mmfTMExternalLeading +
//							tw2mm(PRELINE.m_nTwipLineAfter);
//----- 01.01.29 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		if (0 < lLine)
		{
			CURLINE.m_mmY =	PRELINE.m_mmY +
							PRELINE.m_mmfTMHeight +
							PRELINE.m_mmfTMExternalLeading +
							tw2mm(PRELINE.m_nTwipLineAfter);
			// _xZkqqHx_jBePiCmMiNhDiCoGiCoIiPoDiCmJiClBiCmIiCkCiCoGiCkEiCmJiClHiCoJiBeC_xHqqkZx_
			if (CURLINE.m_mmY < PRELINE.m_mmY) CURLINE.m_mmY = PRELINE.m_mmY;
		}
//----- 01.01.29 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
		CalcLine(lLine);
	}
	mmetol mmBottom = LSTLINE.m_mmY + LSTLINE.m_mmfTMHeight + LSTLINE.m_mmfTMExternalLeading;
	mmTopOffset = TOPLINE.m_mmY - m_mmMarginT;
	mmBtmOffset = m_mmrtWindow.Height() - m_mmMarginB - mmBottom;
#undef TOPLINE
#undef PRELINE
#undef CURLINE
#undef LSTLINE
} // CFCWndRichEdit::CalcLineBelowTop.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineBelowCenter
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBfDiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiClHiCoJiBeCiDgFiDeMiDfIiDgHiCmNiBeBiPgDjFpLiMpMjCiGiJjLiCmJjEhKjChF_xHqqkZx_
 *			_xZkqqHx_iClDiCoKiCoJiCoGiCkEiCmJiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *			00.08.02 Fukushiro M. _xZkqqHx_iDeBiDiLiDfDiDiKiDfJiDiAjAkOjHjNiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcLineBelowCenter ()
{
#define TOPLINE m_vEditLine.front()
#define PRELINE m_vEditLine[lLine-1]
#define CURLINE m_vEditLine[lLine]
#define LSTLINE m_vEditLine.back()

do {
	mmetol mmTopOffset;				// _xZkqqHx_iPoDiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	mmetol mmBtmOffset;				// _xZkqqHx_iJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	mmetol mmNewMove = 0.0;;			// _xZkqqHx_iNkBiJpBiCmMiPoDiDeJiDhEiDfKiDgCiDgHiInKjDkOjCgMiBeC_xHqqkZx_
	mmetol mmLastMove = DBL_MAX;		// _xZkqqHx_jBePiJpBiCmMiPoDiDeJiDhEiDfKiDgCiDgHiInKjDkOjCgMiBeC_xHqqkZx_
	mmetol mmLastTopOffset = DBL_MAX;	// _xZkqqHx_jBePiJpBiCmMiPoDiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	mmetol mmOffsetDif;				// _xZkqqHx_iPoDiJlKiDeJiDhEiDfKiDgCiDgHiCmMiNlHjFkKiBeC_xHqqkZx_

	// _xZkqqHx_jAoGjDkKiNhDiKeKiOgOiNmAjFfHiCkKjEmNiImNjDoAiCmJiOpLiCnMiCmBiCmEiCkCiCoJiPoKiNiHiCmNiBeBiClLiClBiCkJiCoHiNhDiImKjChFiCmMiMhGiOfKiCpAiKeKiOgOiClHiCoJiBeC_xHqqkZx_
	// _xZkqqHx_jGiIiJpBiPiJiKpKiJlLiClFiCmEiMhGiOfKiClHiCoJiCmGiBeBjFlGiOjKiCpAiCfAjDpMjHmNiClHiCoJjDhIiCmJiBeBiNhDiCkKjEpHjGkNiCmJiClIiCoKiCmEiClFiCnMiCkEiClNiCnPiBeC_xHqqkZx_
	if (m_mmMarginT < TOPLINE.m_mmY &&
					  TOPLINE.m_mmY <= m_mmrtWindow.Height() - m_mmMarginB)
	{
		for (int iCount = 0; iCount < 10; iCount++)
		{
			TOPLINE.m_mmY += mmNewMove;
			CalcLineBelowTop(mmTopOffset, mmBtmOffset, 0);
			if (mmLastTopOffset == mmTopOffset) break;
			mmLastTopOffset = mmTopOffset;
			mmOffsetDif = mmBtmOffset - mmTopOffset;
			if (mmBtmOffset < 0)
			{
				break;
			} else
			{
				if (fabs(mmOffsetDif) < 0.05 * (fabs(mmTopOffset) + fabs(mmBtmOffset)))
					break;
				mmNewMove = mmOffsetDif / 2.0;
			}
			mmetol mmMoveMax = fabs(mmLastMove * 0.9);
			if (mmMoveMax < fabs(mmNewMove))
			{
				if (mmNewMove < 0)
					mmNewMove = -mmMoveMax;
				else
					mmNewMove = mmMoveMax;
			}
			mmLastMove = mmNewMove;
		}
		if (0 <= mmBtmOffset) break;
	}

	TOPLINE.m_mmY = m_mmMarginT;
	// _xZkqqHx_iKkOjBfDiCmJ_xHqqkZx_0_xZkqqHx_iClOiCmGiBeBjFeLiClIiMhGiOfKiCkKiOlIjEhDiClHiCoJiCkJiCoHiBeC_xHqqkZx_
	if (TOPLINE.m_mmY == 0.0) TOPLINE.m_mmY = MY_DBL_ROUGH_EPSILON;

	CalcLineBelowTop(mmTopOffset, mmBtmOffset, 0);
	if (mmBtmOffset < 0) break;
	mmLastTopOffset = mmTopOffset;				// _xZkqqHx_jBePiJpBiCmMiPoDiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	mmOffsetDif = mmBtmOffset - mmTopOffset;	// _xZkqqHx_iPoDiJlKiDeJiDhEiDfKiDgCiDgHiCmMiNlHjFkKiBeC_xHqqkZx_
	if (fabs(mmOffsetDif) < 0.05 * (fabs(mmTopOffset) + fabs(mmBtmOffset))) break;
	mmNewMove = mmOffsetDif / 2.0;	// _xZkqqHx_iNkBiJpBiCmMiPoDiDeJiDhEiDfKiDgCiDgHiInKjDkOjCgMiBeC_xHqqkZx_
	mmLastMove = mmNewMove;			// _xZkqqHx_jBePiJpBiCmMiPoDiDeJiDhEiDfKiDgCiDgHiInKjDkOjCgMiBeC_xHqqkZx_

	for (int iCount = 0; iCount < 10; iCount++)
	{
		TOPLINE.m_mmY += mmNewMove;
		CalcLineBelowTop(mmTopOffset, mmBtmOffset, 0);
		if (mmLastTopOffset == mmTopOffset) break;
		mmLastTopOffset = mmTopOffset;
		mmOffsetDif = mmBtmOffset - mmTopOffset;
		if (mmBtmOffset < 0)
		{
			mmNewMove = -mmTopOffset / 2.0;
		} else
		{
			if (fabs(mmOffsetDif) < 0.05 * (fabs(mmTopOffset) + fabs(mmBtmOffset)))
				break;
			mmNewMove = mmOffsetDif / 2.0;
		}
		mmetol mmMoveMax = fabs(mmLastMove * 0.9);
		if (mmMoveMax < fabs(mmNewMove))
		{
			if (mmNewMove < 0)
				mmNewMove = -mmMoveMax;
			else
				mmNewMove = mmMoveMax;
		}
		mmLastMove = mmNewMove;
	}
} while (FALSE);

#undef TOPLINE
#undef PRELINE
#undef CURLINE
#undef LSTLINE
} // CFCWndRichEdit::CalcLineBelowCenter.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineBelowBottom
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBfDiNhDiCmMiDiMiDeDiDeBiDeFiDgHiCpAiNmEiMhGiOfKiClHiCoJiBeCiDgFiDeMiDfIiDgHiCmNiBeBiPgDjFpLiMpMiJlKiCmJjEhKjChF_xHqqkZx_
 *			_xZkqqHx_iClDiCoKiCoJiCoGiCkEiCmJiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcLineBelowBottom ()
{
#define TOPLINE m_vEditLine.front()
#define PRELINE m_vEditLine[lLine-1]
#define CURLINE m_vEditLine[lLine]
#define LSTLINE m_vEditLine.back()

	mmetol mmSucceedY;	// _xZkqqHx_jAkMiMpHiOjOiCmM_xHqqkZx_TOPLINE.m_mmY_xZkqqHx_iBeC_xHqqkZx_
	mmetol mmFailY;		// _xZkqqHx_iOlIjEhDiOjOiCmM_xHqqkZx_TOPLINE.m_mmY_xZkqqHx_iBeC_xHqqkZx_
	mmetol mmTopOffset;	// _xZkqqHx_iPoDiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	mmetol mmBtmOffset;	// _xZkqqHx_iJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	mmetol mmMove;		// _xZkqqHx_iPoDiDeJiDhEiDfKiDgCiDgHiInKjDkOjCgMiBeC_xHqqkZx_
	int iTry;			// _xZkqqHx_iMhGiOfKiCmJjCkHjAoNiClHiCoJiJpBjAjEiBeC_xHqqkZx_

	// _xZkqqHx_jAoGjDkKiNhDiKeKiOgOiNmAjFfHiCkKjEmNiImNjDoAiCmJiOpLiCnMiCmBiCmEiCkCiCoJiPoKiNiHiCmNiBeBiClLiClBiCkJiCoHiNhDiImKjChFiCmMiMhGiOfKiCpAiKeKiOgOiClHiCoJiBeC_xHqqkZx_
	// _xZkqqHx_jGiIiJpBiPiJiKpKiJlLiClFiCmEiMhGiOfKiClHiCoJiCmGiBeBjFlGiOjKiCpAiCfAjDpMjHmNiClHiCoJjDhIiCmJiBeBiNhDiCkKjEpHjGkNiCmJiClIiCoKiCmEiClFiCnMiCkEiClNiCnPiBeC_xHqqkZx_
	if (m_mmMarginT < TOPLINE.m_mmY &&
					  TOPLINE.m_mmY <= m_mmrtWindow.Height() - m_mmMarginB)
	{
		iTry = 2;
	} else
	{
		iTry = 1;
		TOPLINE.m_mmY = m_mmMarginT;
		// _xZkqqHx_iKkOjBfDiCmJ_xHqqkZx_0_xZkqqHx_iClOiCmGiBeBjFeLiClIiMhGiOfKiCkKiOlIjEhDiClHiCoJiCkJiCoHiBeC_xHqqkZx_
		if (TOPLINE.m_mmY == 0.0) TOPLINE.m_mmY = MY_DBL_ROUGH_EPSILON;
	}
	mmFailY = DBL_MAX;
	while (0 < iTry--)
	{
		const mmetol mmMemoY = TOPLINE.m_mmY;
		CalcLineBelowTop(mmTopOffset, mmBtmOffset, 0);
		if (mmBtmOffset < 0)
		{
			mmFailY = mmMemoY;
			TOPLINE.m_mmY = m_mmMarginT;
			// _xZkqqHx_iKkOjBfDiCmJ_xHqqkZx_0_xZkqqHx_iClOiCmGiBeBjFeLiClIiMhGiOfKiCkKiOlIjEhDiClHiCoJiCkJiCoHiBeC_xHqqkZx_
			if (TOPLINE.m_mmY == 0.0) TOPLINE.m_mmY = MY_DBL_ROUGH_EPSILON;
			continue;
		}
		if (mmBtmOffset <= 2.0) break;
		mmSucceedY = TOPLINE.m_mmY;
		mmMove = mmBtmOffset - 0.1;
		while (mmFailY <= mmSucceedY + mmMove)
			mmMove /= 2.0;
		for (int iCount = 0; iCount < 5; iCount++)
		{
			TOPLINE.m_mmY = mmSucceedY + mmMove;
			CalcLineBelowTop(mmTopOffset, mmBtmOffset, 0);
			if (mmBtmOffset < 0)
			{
				mmFailY = mmSucceedY + mmMove;
				mmMove /= 2.0;
				continue;
			}
			if (mmBtmOffset <= 2.0) break;
			mmSucceedY = TOPLINE.m_mmY;
			mmMove = mmBtmOffset - 0.1;
			while (mmFailY <= mmSucceedY + mmMove)
				mmMove /= 2.0;
		}
		if (mmBtmOffset < 0)
		{
			TOPLINE.m_mmY = mmSucceedY;
			CalcLineBelowTop(mmTopOffset, mmBtmOffset, 0);
		}
		break;
	}

#undef TOPLINE
#undef PRELINE
#undef CURLINE
#undef LSTLINE
} // CFCWndRichEdit::CalcLineBelowBottom.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanRedo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	Redo_xZkqqHx_iCkKiCmFiCkLiCoJiCkJiCmHiCkEiCkJiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	Redo_xZkqqHx_iJmCjEfMiCmMiOjOiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeBjFhDiJmCjEfMiCmMiOjOiCmN_xHqqkZx_ FALSE _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CanRedo () const
{
// 06.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	return (GetCmdQueuePos() < GetCmdQueueSize());
	return (GetCmdQueuePos() != GetCmdQueueSize());
} // CFCWndRichEdit::CanRedo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanUndo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	Undo_xZkqqHx_iCkKiCmFiCkLiCoJiCkJiCmHiCkEiCkJiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	Undo_xZkqqHx_iJmCjEfMiCmMiOjOiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeBjFhDiJmCjEfMiCmMiOjOiCmN_xHqqkZx_ FALSE _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CanUndo () const
{
	return (0 < GetCmdQueuePos());
} // CFCWndRichEdit::CanUndo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::Redo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iChBiCiFiCiEiCiPiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::Redo ()
{
	long lMinLine = LONG_MAX;
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	long lMinIdx  = LONG_MAX;
	// _xZkqqHx_jBeJjBpAjEmNiImNiCpAiJpAiPjMiBeC_xHqqkZx_
	SetSelect(-1, -1);
	// _xZkqqHx_iCfAiDfKiDgCiDfGiDiHiDjDiCpA_xHqqkZx_ Redo _xZkqqHx_iClHiCoJiBeC_xHqqkZx_
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (Redo1Session(lMinLine, lMinIdx, m_lCurIndex))
	if (Redo1Session(lMinLine, m_lCurIndex))
	{
		// RedoCmdReplaceChars_xZkqqHx_iCmFiKpDiCmJiPeJjCfLiJpMiNhDiCpAiJhKiCkGiCoJiPoKiNiHiCkKiCkAiCoJiCmMiCmFiBeBiClLiCoKiCpAjGgIiOhOiBeC_xHqqkZx_
		const long lIdxSz = GetIndexSize();
		if (lIdxSz < m_lCurIndex) m_lCurIndex = lIdxSz;
		//----- _xZkqqHx_iImIiNhOiCmMiNhDiCmMiImKjChFiCpAiNmEiMhGiOfK_xHqqkZx_ -----
		if (lMinLine < m_vEditLine.size())
		{
			CalcLineBelow(lMinLine);
			m_mmCaretX = RepositionCaret();
			SendRgnRedraw();
			// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
			DrawSelect();
			// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
			ResetCurFormat();
		}
	}
} // CFCWndRichEdit::Redo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::Undo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iChEiCiOiCiEiCiPiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::Undo ()
{
	long lMinLine = LONG_MAX;
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	long lMinIdx  = LONG_MAX;
	// _xZkqqHx_jBeJjBpAjEmNiImNiCpAiJpAiPjMiBeC_xHqqkZx_
	SetSelect(-1, -1);
	// _xZkqqHx_iCfAiDfKiDgCiDfGiDiHiDjDiCpA_xHqqkZx_ Undo _xZkqqHx_iClHiCoJiBeC_xHqqkZx_
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (Undo1Session(lMinLine, lMinIdx, m_lCurIndex))
	if (Undo1Session(lMinLine, m_lCurIndex))
	{
		// _xZkqqHx_iPeJjCfLiJpMiNhDiCpAiJhKiCkGiCoJiPoKiNiHiCkKiCkAiCoJiCkJiCoAiClFiCoKiCmIiCkCiCmMiCmFiBeBiClLiCoKiCpAjGgIiOhOiBeC_xHqqkZx_
		const long lIdxSz = GetIndexSize();
		if (lIdxSz < m_lCurIndex) m_lCurIndex = lIdxSz;
		//----- _xZkqqHx_iImIiNhOiCmMiNhDiCmMiImKjChFiCpAiNmEiMhGiOfK_xHqqkZx_ -----
		if (lMinLine < m_vEditLine.size())
		{
			CalcLineBelow(lMinLine);
			m_mmCaretX = RepositionCaret();
			SendRgnRedraw();
			// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
			DrawSelect();
			// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
			ResetCurFormat();
		}
	}
} // CFCWndRichEdit::Undo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoUntilBottom
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiNmFiMoDiCnMiCmF_xHqqkZx_ Redo _xZkqqHx_iClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.02.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoUntilBottom ()
{
	// Redo_xZkqqHx_jFhDiJmCjEfMiCmIiCoHjFjMiLeBiBeC_xHqqkZx_
	if (!CanRedo()) return;
	long lMinLine = LONG_MAX;
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	long lMinIdx  = LONG_MAX;
	// _xZkqqHx_jBeJjBpAjEmNiImNiCpAiJpAiPjMiBeC_xHqqkZx_
	SetSelect(-1, -1);
	// _xZkqqHx_iNmFiPiJiCnMiCmF_xHqqkZx_ Redo _xZkqqHx_iClHiCoJiBeC_xHqqkZx_
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	while (Redo1Session(lMinLine, lMinIdx, m_lCurIndex));
	while (Redo1Session(lMinLine, m_lCurIndex));

	// RedoCmdReplaceChars_xZkqqHx_iCmFiKpDiCmJiPeJjCfLiJpMiNhDiCpAiJhKiCkGiCoJiPoKiNiHiCkKiCkAiCoJiCmMiCmFiBeBiClLiCoKiCpAjGgIiOhOiBeC_xHqqkZx_
	const long lIdxSz = GetIndexSize();
	if (lIdxSz < m_lCurIndex) m_lCurIndex = lIdxSz;
	//----- _xZkqqHx_iImIiNhOiCmMiNhDiCmMiImKjChFiCpAiNmEiMhGiOfK_xHqqkZx_ -----
	if (lMinLine < m_vEditLine.size())
	{
		CalcLineBelow(lMinLine);
		m_mmCaretX = RepositionCaret();
		SendRgnRedraw();
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
		DrawSelect();
		// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
		ResetCurFormat();
	}
} // CFCWndRichEdit::RedoUntilBottom.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoUntilTop
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiNmFiPiJiCnMiCmF_xHqqkZx_ Undo _xZkqqHx_iClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.02.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoUntilTop ()
{
	// Undo_xZkqqHx_jFhDiJmCjEfMiCmIiCoHjFjMiLeBiBeC_xHqqkZx_
	if (!CanUndo()) return;
	long lMinLine = LONG_MAX;
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	long lMinIdx  = LONG_MAX;
	// _xZkqqHx_jBeJjBpAjEmNiImNiCpAiJpAiPjMiBeC_xHqqkZx_
	SetSelect(-1, -1);
	// _xZkqqHx_iNmFiPiJiCnMiCmF_xHqqkZx_ Undo _xZkqqHx_iClHiCoJiBeC_xHqqkZx_
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	while (Undo1Session(lMinLine, lMinIdx, m_lCurIndex));
	while (Undo1Session(lMinLine, m_lCurIndex));

	// _xZkqqHx_iPeJjCfLiJpMiNhDiCpAiJhKiCkGiCoJiPoKiNiHiCkKiCkAiCoJiCkJiCoAiClFiCoKiCmIiCkCiCmMiCmFiBeBiClLiCoKiCpAjGgIiOhOiBeC_xHqqkZx_
	const long lIdxSz = GetIndexSize();
	if (lIdxSz < m_lCurIndex) m_lCurIndex = lIdxSz;
	//----- _xZkqqHx_iImIiNhOiCmMiNhDiCmMiImKjChFiCpAiNmEiMhGiOfK_xHqqkZx_ -----
	if (lMinLine < m_vEditLine.size())
	{
		CalcLineBelow(lMinLine);
		m_mmCaretX = RepositionCaret();
		SendRgnRedraw();
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
		DrawSelect();
		// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
		ResetCurFormat();
	}
} // CFCWndRichEdit::UndoUntilTop.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanSelectAll
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iBhFiClHiCnHiCmEjBeJjBpAiBhGiCkKiJmCjEfMiCkJiCmHiCkEiCkJiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iJmCjEfMiCmIiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeBjFhDiJmCjEfMiCmIiPoKiNiHiCmN_xHqqkZx_ FALSE _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CanSelectAll () const
{
	return (GetIndexSize() != 0);
} // CFCWndRichEdit::CanSelectAll.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SelectAll
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iBhFiClHiCnHiCmEjBeJjBpAiBhGiCpAiOmAiNhDiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iDiBiDgKiDiFiBfLiBhFiClHiCnHiCmEjBeJjBpAiBhGiCkJiCoH_xHqqkZx_View_xZkqqHx_iCpAjCmKiClFiCmEiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SelectAll ()
{
	SetSelect(0, GetIndexSize());
} // CFCWndRichEdit::SelectAll.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SelectExAll
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	SelectAll _xZkqqHx_iCmFiCmNjBeJjBpAiClDiCoKiCmIiCkCiBeBiPeJjCfLiCmMiJpMiNhDiDfCiBfLiDgIiCoAjBeJjBpAiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	FCRichText _xZkqqHx_iCpAjCmKiClGiCmEiBeBiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmFiCmNiCmIiCkCiPpDjBnEiCmFiCmM_xHqqkZx_
 *			_xZkqqHx_iDhEiDeIiDjDiDgHiCmMjAnNjCoIiBeBiNhDiKnEjAnNjCoIjDjJiCmFiOgHjHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.15 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SelectExAll ()
{
	SetSelect(0, GetIndexSize() + 1);
} // CFCWndRichEdit::SelectExAll.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanPaste
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	RTF/_xZkqqHx_iDgFiDeMiDfIiDgHiCmGiClFiCmEiDhJiBfLiDfIiDgHiJmCjEfMiCkJiCmHiCkEiCkJiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDhJiBfLiDfIiDgHiJmCjEfMiCmIiCoHiCmO_xHqqkZx_ TRUE_xZkqqHx_iBeBjFhDiJmCjEfMiCmIiCoHiCmO_xHqqkZx_ FALSE _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmJiDhJiBfLiDfIiDgHiJmCjEfMiCmIiDgGiBfLiDfOiCmGiClFiCmEiCmNiBeBjFkKiCkJiCmBiCmEiCkCiCoJ_xHqqkZx_
 *			_xZkqqHx_iCoAiCmMiCmFiImIiJlKiCkKiCkAiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iBeF_xHqqkZx_DD3_TEXT
 *			_xZkqqHx_iBeF_xHqqkZx_RTF
 *			_xZkqqHx_iBeF_xHqqkZx_UNICODETEXT (NT,2000,XP)
 *			_xZkqqHx_iBeF_xHqqkZx_TEXT
 *			_xZkqqHx_iCoAiClFiCkJiClFiClNiCoHiBeBiClBiCoKiImIiKePiCmJiCoAiCkAiCoJiCkJiCoAiClFiCoKiCmIiCkCiBgJjHoBiCkGiCmO_xHqqkZx_HTML_xZkqqHx_iCmIiCmHiBgKiBeC_xHqqkZx_
 *			_xZkqqHx_iClBiCmMiClNiCnPiBeB_xHqqkZx_CanPaste_xZkqqHx_iCpAjClCiCnHiCoJiOoIiPiHiCmGiClFiCmEiCmNiBeBiImIiJlKiCmGiCmIiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iCfAiBeE_xHqqkZx_DD3_TEXT _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKiDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmJjBlGiNnNiClHiCoJiCkJiCmHiCkEiCkJjClCiCnHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iCfBiBeE_xHqqkZx_DD3_TEXT _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiHiCmNiBeB_xHqqkZx_RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmJ_xHqqkZx_
 *				_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIiDgGiBfLiDfOiCpAjDfMiCoIjFhEiCkPiJmCjEfMiCkJjGoCiCkCiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *			RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmJjGoCiCkCiNiHiCoNiClJiCoJiClBiCmGiCmFiBeBjGkCjCgNiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCoA_xHqqkZx_
 *			_xZkqqHx_jClCiCnHiCoJiClBiCmGiCkKiCmFiCkLiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jCeBiClFiBeB_xHqqkZx_RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmNiBeB_xHqqkZx_DD3_FILE/EMF/WMF_xZkqqHx_jDjJiCoAjDfMiCoIjFhEiCkPiJmCjEfMiCmG_xHqqkZx_
 *			_xZkqqHx_jElLjCgGiClFiCmEiCkCiCoJiDhEiDfGiCkKiCkAiCoJiBgJ_xHqqkZx_DD3_xZkqqHx_iCmMjCmKiPoNiCmMjFjEjFgJiDfCiDhDiBfLiCmFiCoAiBeB_xHqqkZx_
 *			RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmNjDfMiCoIjFhEiCkPiJmCjEfMiCmGjFnEiClHiBgKiBeC_xHqqkZx_
 *			_xZkqqHx_iClBiCmMiClNiCnPiBeB_xHqqkZx_Paste_xZkqqHx_iKnGjAjEiCmFiCmNiBeBiImIiJlKiCmMiOoIiPiHiCpAiOoGiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iCfAiBeEiImIiJlKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCmMiPiHiCmJiBeBiDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmMjBlGiNnNiCpAjClCiCnHiBeBjBlGiNnNiClHiCoJ_xHqqkZx_
 *				_xZkqqHx_iPoKiNiHiCmNiClLiCmMiMgAiOkOiCmFjDfMiCoIjFhEiCkPiCoJiBeC_xHqqkZx_
 *				_xZkqqHx_iHeA_xHqqkZx_ DD3_TEXT
 *				_xZkqqHx_iHeB_xHqqkZx_ RTF
 *				_xZkqqHx_iHeC_xHqqkZx_ UNICODETEXT (NT,2000,XP)
 *				_xZkqqHx_iHeD_xHqqkZx_ TEXT
 *			_xZkqqHx_iCfBiBeEiCkCiClIiCoKiCmMiMgAiOkOiCoAjBlGiNnNiClFiCmIiCkCiPoKiNiHiCmNiBeBiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiClJiClI_xHqqkZx_
 *				RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmJiDeOiDiKiDgCiDhGiDhLiBfLiDgIiDgGiBfLiDfOiCpAjDfMiCoIjFhEiCkPiClDiClJiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CanPaste () const
{
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	return CanPasteSpec(g_cfRTF);
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	return CanPasteSpec(0);
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::CanPaste.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnPaste
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCmMiDhJiBfLiDfIiDgHiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmJiDhJiBfLiDfIiDgHiJmCjEfMiCmIiDgGiBfLiDfOiCmGiClFiCmEiCmNiBeBjFkKiCkJiCmBiCmEiCkCiCoJ_xHqqkZx_
 *			_xZkqqHx_iCoAiCmMiCmFiImIiJlKiCkKiCkAiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iBeF_xHqqkZx_DD3_TEXT
 *			_xZkqqHx_iBeF_xHqqkZx_RTF
 *			_xZkqqHx_iBeF_xHqqkZx_UNICODETEXT (NT,2000,XP)
 *			_xZkqqHx_iBeF_xHqqkZx_TEXT
 *			_xZkqqHx_iCoAiClFiCkJiClFiClNiCoHiBeBiClBiCoKiImIiKePiCmJiCoAiCkAiCoJiCkJiCoAiClFiCoKiCmIiCkCiBgJjHoBiCkGiCmO_xHqqkZx_HTML_xZkqqHx_iCmIiCmHiBgKiBeC_xHqqkZx_
 *			_xZkqqHx_iClBiCmMiClNiCnPiBeB_xHqqkZx_CanPaste_xZkqqHx_iCpAjClCiCnHiCoJiOoIiPiHiCmGiClFiCmEiCmNiBeBiImIiJlKiCmGiCmIiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iCfAiBeE_xHqqkZx_DD3_TEXT _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKiDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmJjBlGiNnNiClHiCoJiCkJiCmHiCkEiCkJjClCiCnHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iCfBiBeE_xHqqkZx_DD3_TEXT _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiHiCmNiBeB_xHqqkZx_RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmJ_xHqqkZx_
 *				_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIiDgGiBfLiDfOiCpAjDfMiCoIjFhEiCkPiJmCjEfMiCkJjGoCiCkCiNiHiCoNiClJiCoJiBeC_xHqqkZx_
 *			RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmJjGoCiCkCiNiHiCoNiClJiCoJiClBiCmGiCmFiBeBjGkCjCgNiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCoA_xHqqkZx_
 *			_xZkqqHx_jClCiCnHiCoJiClBiCmGiCkKiCmFiCkLiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jCeBiClFiBeB_xHqqkZx_RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmNiBeB_xHqqkZx_DD3_FILE/EMF/WMF_xZkqqHx_jDjJiCoAjDfMiCoIjFhEiCkPiJmCjEfMiCmG_xHqqkZx_
 *			_xZkqqHx_jElLjCgGiClFiCmEiCkCiCoJiDhEiDfGiCkKiCkAiCoJiBgJ_xHqqkZx_DD3_xZkqqHx_iCmMjCmKiPoNiCmMjFjEjFgJiDfCiDhDiBfLiCmFiCoAiBeB_xHqqkZx_
 *			RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmNjDfMiCoIjFhEiCkPiJmCjEfMiCmGjFnEiClHiBgKiBeC_xHqqkZx_
 *			_xZkqqHx_iClBiCmMiClNiCnPiBeB_xHqqkZx_Paste_xZkqqHx_iKnGjAjEiCmFiCmNiBeBiImIiJlKiCmMiOoIiPiHiCpAiOoGiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iCfAiBeEiImIiJlKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCmMiPiHiCmJiBeBiDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmMjBlGiNnNiCpAjClCiCnHiBeBjBlGiNnNiClHiCoJ_xHqqkZx_
 *				_xZkqqHx_iPoKiNiHiCmNiClLiCmMiMgAiOkOiCmFjDfMiCoIjFhEiCkPiCoJiBeC_xHqqkZx_
 *				_xZkqqHx_iHeA_xHqqkZx_ DD3_TEXT
 *				_xZkqqHx_iHeB_xHqqkZx_ RTF
 *				_xZkqqHx_iHeC_xHqqkZx_ UNICODETEXT (NT,2000,XP)
 *				_xZkqqHx_iHeD_xHqqkZx_ TEXT
 *			_xZkqqHx_iCfBiBeEiCkCiClIiCoKiCmMiMgAiOkOiCoAjBlGiNnNiClFiCmIiCkCiPoKiNiHiCmNiBeBiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiClJiClI_xHqqkZx_
 *				RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmJiDeOiDiKiDgCiDhGiDhLiBfLiDgIiDgGiBfLiDfOiCpAjDfMiCoIjFhEiCkPiClDiClJiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.05 Fukushiro M. _xZkqqHx_iPeDjAlD_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnPaste ()
{
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	BOOL bIsRtf = FALSE;		// RTF_xZkqqHx_iDgGiBfLiDfOiCkKiCkAiCoJiCkJiBeI_xHqqkZx_
//	BOOL bIsUnicode = FALSE;	// UNICODE TEXT_xZkqqHx_iDgGiBfLiDfOiCkKiCkAiCoJiCkJiBeI_xHqqkZx_
//	BOOL bIsText = FALSE;		// TEXT_xZkqqHx_iDgGiBfLiDfOiCkKiCkAiCoJiCkJiBeI_xHqqkZx_
//	if (OpenClipboard())
//	{
//		DWORD dwFormat = 0;
//		// _xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIjCiGiCmMiDgGiBfLiDfOiMgAiOkOiCpAjHpBiLjDiBeC_xHqqkZx_
//		do {
//			dwFormat = EnumClipboardFormats(dwFormat);
//			if (dwFormat == g_cfRTF) bIsRtf = TRUE;
//			if (dwFormat == CF_TEXT) bIsText = TRUE;
//		} while (dwFormat != 0);
//		// _xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIiCpAjFmCiClGiCoJiBeC_xHqqkZx_
//		CloseClipboard();
//	}
//	// RTF_xZkqqHx_iDgGiBfLiDfOiCpAjHeEjAoGiClFiCmEjDfMiCoIjFhEiCkPiBeC_xHqqkZx_
//	if (bIsRtf)
//		OnPasteSpec(g_cfRTF);
//	else
//	if (bIsText)
//		OnPasteSpec(CF_TEXT);
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	//	_xZkqqHx_iCfAiBeEiImIiJlKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCmMiPiHiCmJiBeBiDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmMjBlGiNnNiCpAjClCiCnHiBeBjBlGiNnNiClHiCoJ_xHqqkZx_
	//		_xZkqqHx_iPoKiNiHiCmNiClLiCmMiMgAiOkOiCmFjDfMiCoIjFhEiCkPiCoJiBeC_xHqqkZx_
	//		_xZkqqHx_iHeA_xHqqkZx_ DD3_TEXT
	//		_xZkqqHx_iHeB_xHqqkZx_ RTF
	//		_xZkqqHx_iHeC_xHqqkZx_ UNICODETEXT (NT,2000,XP)
	//		_xZkqqHx_iHeD_xHqqkZx_ TEXT
	//	_xZkqqHx_iCfBiBeEiCkCiClIiCoKiCmMiMgAiOkOiCoAjBlGiNnNiClFiCmIiCkCiPoKiNiHiCmNiBeBiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiClJiClI_xHqqkZx_
	//		RICHEDIT_xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiCmJiDeOiDiKiDgCiDhGiDhLiBfLiDgIiDgGiBfLiDfOiCpAjDfMiCoIjFhEiCkPiClDiClJiCoJiBeC_xHqqkZx_

	if (CanPasteSpec(g_cfDDText))
	{
		OnPasteSpec(g_cfDDText);
	} else
	if (CanPasteSpec(g_cfRTF))
	{
		OnPasteSpec(g_cfRTF);
	} else
	if (CanPasteSpec(CF_UNICODETEXT))
	{
		OnPasteSpec(CF_UNICODETEXT);
	} else
	if (CanPasteSpec(CF_TEXT))
	{
		OnPasteSpec(CF_TEXT);
	} else
	{
		OnPasteSpec(0);
	}
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::OnPaste.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanPasteSpec
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiMgAiOkOiCmFiDhJiBfLiDfIiDgHiJmCjEfMiCkJiCmHiCkEiCkJiCpAjClCiCnHiCoJ_xHqqkZx_.
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	dwFormat:_xZkqqHx_iDhJiBfLiDfIiDgHiClHiCoJiDgGiBfLiDfOiMgAiOkOiCpAiOhHjCoIiBeCiMgAiOkOiCpAjDmBjCoIiClFiCmIiCkC_xHqqkZx_
 *					 _xZkqqHx_iPoKiNiHiCmNiCePiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.05 Fukushiro M. _xZkqqHx_iNoMjAkMiBeC_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CanPasteSpec (DWORD dwFormat) const
{
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	if (dwFormat == CF_TEXT)
//		return CanPasteAsText();
//	else
//	if (dwFormat == g_cfRTF)
//		return CanPasteAsRtf();
//	else
//		return FALSE;
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	return m_richpEditCtrl->CanPasteSpecial(dwFormat);
//----- 05.07.10 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::CanPasteSpec.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnPasteSpec
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiMgAiOkOiCmFiDeOiDiKiDgCiDhGiDhLiBfLiDgIiCkJiCoHiDhJiBfLiDfIiDgHiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	dwFormat	:_xZkqqHx_iDhJiBfLiDfIiDgHiClHiCoJiDgGiBfLiDfOiMgAiOkOiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.05 Fukushiro M. _xZkqqHx_iNoMjAkMiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnPasteSpec (DWORD dwFormat)
{
	if (dwFormat == CF_TEXT ||
		dwFormat == CF_UNICODETEXT)
		OnPasteAsText(dwFormat);
	else
		OnPasteAsRtf(dwFormat);
} // CFCWndRichEdit::OnPasteSpec.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanCopy
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDiKiDgCiDgAiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmFiDfCiDhDiBfLiJmCjEfMiCkJiCmHiCkEiCkJiCpAjClCiCnHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDfCiDhDiBfLiJmCjEfMiCmIiCoHiCmO_xHqqkZx_ TRUE_xZkqqHx_iBeBjFhDiJmCjEfMiCmIiCoHiCmO_xHqqkZx_ FALSE _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CanCopy () const
{
	return (0 <= m_lSelFrom && m_lSelFrom != m_lSelTo);
} // CFCWndRichEdit::CanCopy.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnCopy
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDiKiDgCiDgAiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCkJiCoHiDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmJiDfCiDhDiBfLiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnCopy ()
{
	long lSelFrom, lSelTo;
	GetSelectNormal(lSelFrom, lSelTo);
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjAoGjDkKiDeDiDjDiDgGiDgCiDeOiDfIiCmMiNhDiBeFjHpBiCpAiOoGjDlOiBeC_xHqqkZx_
	long lCount = 0;	// _xZkqqHx_iDfCiDhDiBfLiClHiCoJjFlGiOjKjAjEiCpAiDeKiDeFiDjDiDgHiBeC_xHqqkZx_
	long lLine, lChar;
	IndexToCharPos(lLine, lChar, lSelFrom);
	m_richpEditCtrl->BeginAddChar(m_fciCurStdCodeFormat);
	for (long lCharSz = lSelTo - lSelFrom; 0 < lCharSz; lCharSz--)
	{
		const FCEditChar& eChr = m_vEditLine[lLine].m_vEditChar[lChar];
		//----- _xZkqqHx_jFlGiOjKiDhEiDeIiBfLiDhNiDgCiDgHiCmMiOoGjDlO_xHqqkZx_ -----
		FCFontCharInfo fci;
		g_pEnv->GetSFontRec(eChr.m_foidFont)->ReqInit(fci);
		eChr.ReqOverwrite(fci);
		//----- _xZkqqHx_iNhDiDhEiDeIiBfLiDhNiDgCiDgHiCmMiOoGjDlO_xHqqkZx_ -----
		FCTextLineInfo	tli;
		m_vEditLine[lLine].GetFormat(tli);
		// _xZkqqHx_jFlGiOjKiCmMjBhNjDpMiBeC_xHqqkZx_
		if (eChr.m_wChar == FDRCH_RETURN)
			m_richpEditCtrl->NextAddChar(WCH_CR, fci, tli);
		else
			m_richpEditCtrl->NextAddChar(eChr.m_wChar, fci, tli);
		(void)NextChar(lLine, lChar);
	}
	// _xZkqqHx_jFlGiOjKjBhNjDpMiCpAiPeJjHlJiBeC_xHqqkZx_
	m_richpEditCtrl->EndAddChar();
	// _xZkqqHx_iDfCiDhDiBfLiPiIjHjNiBeC_xHqqkZx_
	m_richpEditCtrl->Copy();
	// _xZkqqHx_iDeHiDgGiDeCiDfOiPiJiKpKiJlLiBeC_xHqqkZx_
	m_richpEditCtrl->Clear();
} // CFCWndRichEdit::OnCopy.

//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnChar
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiImKjChFiCmJiCfAjFlGiOjKiCpAjBhNjDpMiClHiCoJiBeCjBhNjDpMiClHiCoJjFlGiOjKiCmNiJpMiNhDjFlGiOjK_xHqqkZx_
// *			_xZkqqHx_iCmFiCkAiCmBiCmEiCoAjHmHiCkCiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wChar	: _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKiBeC_xHqqkZx_UNICODE_xZkqqHx_iCmFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jCiNiInD_xHqqkZx_>	CalcLine_xZkqqHx_iBeB_xHqqkZx_Redraw_xZkqqHx_iPiIjHjNiCpAiNhDiCkEiBeC_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::OnChar (WORD wChar)
//{
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
//	SessionBegin();
//	if (0 <= m_lSelFrom)
//	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
//		//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiHiCmNiPoDiPjBiCkLiDiCiBfLiDgIiCkJiCmHiCkEiCkJiCmNiKnGiMfHiCmIiCkC_xHqqkZx_ -----
//		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
//		DrawSelect();
//		// _xZkqqHx_jBeJjBpAjFjEjFkKiCpAiNoNiPjM_xHqqkZx_.
//		(void)MCmdDeleteSelection();
//	} else if (FFGetMainWnd()->IsOvrMode())
//	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkNiBeBiKiOiCmCiPoDiPjBiCkLiDiCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
//	{
//		// _xZkqqHx_iImIiJlKiCmFiJpMiNhDiCoAiDgAiDeGiDgCiDeOiClFiCmIiCkCiCmGiBeCiPoDiPjBiCkLiCmJiClFiCmEiBeB_xHqqkZx_Enter_xZkqqHx_iClHiCoJiCmGiBeBjClMjBePiCmMjFlGiOjKiCkKiPmBiCkGiCnMiClHiBeC_xHqqkZx_
//		if (m_lCurIndex < GetIndexSize() && wChar != WCH_LF && wChar != WCH_CR)
//		//----- _xZkqqHx_jFlGjGjGiCmFiCmIiCkNiBeBiJpMiNhDjBhNjDpMiCmFiCoAiCmIiCkCiPoKiNiH_xHqqkZx_ -----
//		{
//			//----- _xZkqqHx_iOjPiCmMiCfAjFlGiOjKiCpAjBeJjBpAjEmNiImNiCmJiClFiCmEiNoNiPjM_xHqqkZx_ -----
//			m_lSelFrom = m_lCurIndex;
//			m_lSelTo = m_lCurIndex + 1;
//			(void)MCmdDeleteSelection();
//		}
//	}
//
//	//----- FCEditChar_xZkqqHx_iCpAjAnNjCoI_xHqqkZx_ -----
//	FCEditChar rc;
//
//	FCSFontRec fntRec;
//	// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiHiCmNiBeBjFfHiPiAjFlGiOjKiDfCiBfLiDgIjAoKjHhAiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
//	if (FFIsStdFontChar(wChar))
//	//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
//	{
//		fntRec.Init(m_fciCurStdCodeFormat);
//		rc.Overread(m_fciCurStdCodeFormat);
//	} else
//	//----- _xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
//	{
//		fntRec.Init(m_fciCurExtCodeFormat);
//		rc.Overread(m_fciCurExtCodeFormat);
//	}
//
//	// _xZkqqHx_iOhHjCoIiCmMjFlGiOjKiCkKjBkOiClHiCoJ_xHqqkZx_Charset_xZkqqHx_iCmMiPfHiNiHiCpAiOoGjDlOiBeC_xHqqkZx_
//	WORDVector vCharSet;
//	FFUnicodeToCharSet(vCharSet, wChar, fntRec.GetCharSet());
//	// FCSFontRec_xZkqqHx_iNfMjBkCjBmMiCkJiCoH_xHqqkZx_FontID_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
//	SFontID foidFont = g_pEnv->FindNearestSFont(fntRec, &vCharSet);
//	// _xZkqqHx_jGlDiCkCiPoKiNiHiCmNjDgPjIfOiClHiCoJiBeC_xHqqkZx_
//	if (foidFont == FD_S_FONT_UNSPECIFY)
//		g_pDoc->CmdInsert1SFont(foidFont, fntRec);
//
//	if (wChar == WCH_LF || wChar == WCH_CR)
//	{
//		//----- FCEditChar_xZkqqHx_iCpAiPiJiKpKiJlL_xHqqkZx_ -----
//		rc.m_wChar = FDRCH_RETURN;
//		rc.m_foidFont = foidFont;
//		rc.m_mmfWidth = FDWR_RETURN_WIDTH;
//		rc.m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
//		rc.m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
//		rc.m_mmfPreSpace = 0.0;
//		rc.m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
//	} else
//	if (wChar == WCH_SPC || wChar == WCH_TAB)
//	//----- _xZkqqHx_iLpDjEjCiBeBiDfOiDhFiCmMiPoKiNiH_xHqqkZx_ -----
//	{
//		rc.m_wChar		= wChar;
//		rc.m_foidFont	= foidFont;
//		// _xZkqqHx_iLpDjEjCiCmMjFfHiPiAjFjNiCpAiOoGjDlOiBjFjAnNjCoIiBeCiDfOiDhFiCmMiPoKiNiHiCmNiJlMjAnNjCoIiBeC_xHqqkZx_
//		rc.m_mmfWidth	= g_pEnv->GetSFontRec(rc.m_foidFont)->GetStdSpaceWidth();
//		rc.m_mmfAbcA	= 0.0;
//		rc.m_mmfAbcC	= 0.0;
//		rc.m_mmfPreSpace= 0.0;
//		rc.m_byCrossStat= FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
//	} else
//	{
//		CClientDC dc(this);	// _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
//		// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
//		FCAutoDC atDC(&dc, FALSE, 0, 0);
//
//		//----- _xZkqqHx_jFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJ_xHqqkZx_Zoom_xZkqqHx_iCpAiCfFiCfDjEhLiCmJjAnNjCoIiClHiCoJ_xHqqkZx_ -----
//		double dZoom = g_->dZoom;
//		g_->dZoom = g_->dDisplayPPM * 64;
//
//		//----- _xZkqqHx_iDhEiDeIiDjDiDgHiDfEiDeDiDfJiMhGiOfKjHhAiCmJiMlLiNnNiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_ -----
//		LOGFONT logFont;
//		WORD wCodePage;
//		g_pEnv->GetSFontRec(foidFont)->ReqInit(logFont, 0.0, rc.m_wOffset);
//		wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
//		atDC.SetFont(&logFont);
//
//		//----- _xZkqqHx_jFlGiOjKiBgJiDfCiBfLiDgI_xHqqkZx_wChar_xZkqqHx_iBgKiCmMjFjNiCpAiOoGjDlO_xHqqkZx_ -----
//		ABC abc;
//		// _xZkqqHx_iDfCiBfLiDgIiDhJiBfLiDfHiCmNjFeLjAhLiBeCiDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkNiCmIiCoJiBeC_xHqqkZx_
//		atDC.GetCharABCWidth(wChar, abc, wCodePage);
//		rc.m_wChar   = wChar;
//		rc.m_foidFont= foidFont;
//		rc.m_mmfWidth = static_cast<fmmetol>(lg2mm(abc.abcA + abc.abcB + abc.abcC));
//		rc.m_mmfAbcA = static_cast<fmmetol>(lg2mm(abc.abcA));
//		rc.m_mmfAbcC = static_cast<fmmetol>(lg2mm(abc.abcC));
//		rc.m_mmfPreSpace = 0.0;
//		rc.m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
//
//		// Zoom_xZkqqHx_iCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_
//		g_->dZoom = dZoom;
//	}
//
//	FCEditCharVector vWorkChar;
//	vWorkChar.push_back(rc);
//
//	long lCurLine = MCmdInsertText(vWorkChar);
//
//	/****** _xZkqqHx_jBhNjDpMiPoKiPiKiImIiNhOiCmMiNhDiCmMiImKjChFiCpAiNmEiMhGiOfK_xHqqkZx_ ******/
//	// _xZkqqHx_jBhNjDpMiClDiCoKiClNiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfK_xHqqkZx_.
//	CalcLineBelow(lCurLine);
//	m_mmCaretX = RepositionCaret();
//	SendRgnRedraw();
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
//	DrawSelect();
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
//	SessionEnd();
//} // CFCWndRichEdit::OnChar.
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnDelete
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	DELETE_xZkqqHx_iDeMiBfLiCpAiJjPiClDiCoKiClNiOjOiCmJ_xHqqkZx_PreTranslateMessage_xZkqqHx_iKnGjAjEiCkJiCoHiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBeJjBpAjEmNiImNiCkKjBlGiNnNiClHiCoKiCmOiBeBiClLiCmMjEmNiImNiCpAiNoNiPjMiClHiCoJiBeCjBlGiNnNiClFiCmIiCkCiPoKiNiHiCmNiBeB_xHqqkZx_
 *			_xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCmMiCfAjFlGiOjKiCpAjBeJjBpAjEmNiImNiCmGiClFiCmEiNoNiPjMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnDelete ()
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();
	if (m_lSelFrom < 0)
	/*----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiH_xHqqkZx_ -----*/
	{
		// _xZkqqHx_iDeKiBfLiDfMiDiLiCkKiNmFiMoDiCmMiImKjChFiCmJiCkAiCoJiPoKiNiHiCmNjFjMiLeB_xHqqkZx_.
		if (GetIndexSize() <= m_lCurIndex) return;
		// _xZkqqHx_iOjPiCmMiCfAjFlGiOjKiCpAjBeJjBpAjEmNiImNiCmJ_xHqqkZx_.
		m_lSelFrom = m_lCurIndex;
		m_lSelTo = m_lCurIndex + 1;
	}
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCpAiNoNiPjM_xHqqkZx_.
	long lLineFrom = MCmdDeleteSelection();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();

	/*----- _xZkqqHx_iImIiNhOiCmMiNhDiCmMiImKjChFiCpAiNmEiMhGiOfK_xHqqkZx_ -----*/
	CalcLineBelow(lLineFrom);
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
}	// CFCWndRichEdit::OnDelete.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnBackspace
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	BS_xZkqqHx_iDeMiBfLiCkKjDpMjHmNiClDiCoKiClNiCmGiCkLiBeB_xHqqkZx_OnChar_xZkqqHx_iKnGjAjEiCkJiCoHiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBeJjBpAjEmNiImNiCkKjBlGiNnNiClHiCoKiCmOiBeBiClLiCmMjEmNiImNiCpAiNoNiPjMiClHiCoJiBeCjBlGiNnNiClFiCmIiCkCiPoKiNiHiCmNiBeB_xHqqkZx_
 *			_xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCmMjBePiCmMiCfAjFlGiOjKiCpAjBeJjBpAjEmNiImNiCmGiClFiCmEiNoNiPjMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnBackspace ()
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();
	if (m_lSelFrom < 0)
	/*----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiH_xHqqkZx_ -----*/
	{
		// _xZkqqHx_iDeKiBfLiDfMiDiLiCkKiNmFiPiJiCmMiImKjChFiCmJiCkAiCoJiPoKiNiHiCmNjFjMiLeB_xHqqkZx_.
		if (m_lCurIndex <= 0) return;
		// _xZkqqHx_iOjPiCmMiCfAjFlGiOjKiCpAjBeJjBpAjEmNiImNiCmJ_xHqqkZx_.
		m_lSelFrom = m_lCurIndex - 1;
		m_lSelTo = m_lCurIndex;
	}
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCpAiNoNiPjM_xHqqkZx_.
	long lLineFrom = MCmdDeleteSelection();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();

	/*----- _xZkqqHx_iImIiNhOiCmMiNhDiCmMiImKjChFiCpAiNmEiMhGiOfK_xHqqkZx_ -----*/
	CalcLineBelow(lLineFrom);
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
	// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_.
	ResetCurFormat();
} // CFCWndRichEdit::OnBackspace.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCurCharInfo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFnEiClHiBeCjBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiHiCmNiBeBiClLiCmMjCiGiCmF_xHqqkZx_
 *			_xZkqqHx_iLkEjCmKiClHiCoJiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	fciExtCode	:_xZkqqHx_iKpJjBlGjFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAjAnNjCoIiClHiCoJiBeCiLkEjCmKiDhEiDeIiBfLiDhNiDgCiDgHiCkKjFnEiCoJiBeC_xHqqkZx_
 *			fciStdCode	:_xZkqqHx_iKpJjBlGjFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAjAnNjCoIiClHiCoJiBeCiLkEjCmKiDhEiDeIiBfLiDhNiDgCiDgHiCkKjFnEiCoJiBeC_xHqqkZx_
 *			bInit	:fciExtCode,fciStdCode_xZkqqHx_iCpAiPiJiKpKiJlLiClHiCoJiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeB_xHqqkZx_fciExtCode,fciStdCode
 *					_xZkqqHx_iCmMjCgMiCmGiPgEiCmLiNiHiCoNiClJiCoJiPoKiNiHiCmN_xHqqkZx_ FALSE_xZkqqHx_iCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	bInit_xZkqqHx_iCmJ_xHqqkZx_TRUE_xZkqqHx_iCkKjAnNjCoIiClDiCoKiCmEiCkIiCoIiBeBiKiOiCmC_xHqqkZx_ _xZkqqHx_iCfAjFlGiOjKiCoAiCkJiCnEiCmBiCmEiCkCiCmIiCkCiPoKiNiHiCmNiBeB_xHqqkZx_
 *			dwMask _xZkqqHx_iCmJ_xHqqkZx_ FDFI_FLAG_UNUSED _xZkqqHx_iDhEiDiJiDePiCkKjHkHiCmEiCoHiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.19 Fukushiro M. _xZkqqHx_iOgEjHgMiCpAjFmPiNfIiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetCurCharInfo (	FCFontCharInfo& fciExtCode,
										FCFontCharInfo& fciStdCode, BOOL bInit) const
{
//----- 05.06.30 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	if (0 <= m_lSelFrom)
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
//		BOOL bInitExtCode = bInit;	// fciExtCode_xZkqqHx_iCpAiPiJiKpKiJlLiClHiCoJiCkJiBeI_xHqqkZx_
//		BOOL bInitStdCode = bInit;	// fciStdCode_xZkqqHx_iCpAiPiJiKpKiJlLiClHiCoJiCkJiBeI_xHqqkZx_
//		if (bInit)
//		{
//			// _xZkqqHx_jFfHiPiAiDhEiDeIiBfLiDhNiDgCiDgHiCmFiPiJiKpKiJlLiBeCjBeJjBpAjEmNiImNjCiGiCmJiJhAiOjKiBeFjIgBiOjKiCkKjGlDiCkJiCmBiClNiPoKiNiHiCmJjEpFiCkGiCmEiBeC_xHqqkZx_
//			fciExtCode = m_fciCurExtCodeFormat;
//			fciStdCode = m_fciCurStdCodeFormat;
//		}
//		long lSelFrom, lSelTo;
//		GetSelectNormal(lSelFrom, lSelTo);
//		for (long lC = lSelFrom; lC < lSelTo; lC++)
//		{
//			//----- _xZkqqHx_iMlLiNnNiCmMjFlGiOjKiCmF_xHqqkZx_fciCur_xZkqqHx_iCpAiPiJiKpKiJlL_xHqqkZx_ -----
//			FCEditChar rc = GetChar(lC);
//			FCFontCharInfo fciCur;
//			g_pEnv->GetSFontRec(rc.m_foidFont)->ReqInit(fciCur);
//			rc.ReqOverwrite(fciCur);
//			// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCkJiCmHiCkEiCkJiBeI_xHqqkZx_
//// 02.08.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)
////			if (g_pReg->GetIsUseStdFont() && FFIsStdFontChar(rc.m_wChar))
//			if (g_pReg->GetIsUseStdFont() && FFIsStdFontChar(Fdrch2Wchar(rc.m_wChar)))
//			//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
//			{
//				if (bInitStdCode)
//				{
//					fciStdCode = fciCur;
//					bInitStdCode = FALSE;
//				} else
//				{
//					fciStdCode &= fciCur;
//				}
//			} else
//			//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiImIiKePiCmMiPoKiNiH_xHqqkZx_ -----
//			{
//				if (bInitExtCode)
//				{
//					fciExtCode = fciCur;
//					bInitExtCode = FALSE;
//				} else
//				{
//					fciExtCode &= fciCur;
//				}
//			}
//		}
//	} else
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKjGlDiCkCiPoKiNiH_xHqqkZx_ -----
//	{
//		if (bInit)
//		{
//			// _xZkqqHx_jFfHiPiAiDhEiDeIiBfLiDhNiDgCiDgHiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
//			fciExtCode = m_fciCurExtCodeFormat;
//			fciStdCode = m_fciCurStdCodeFormat;
//		} else
//		{
//			// _xZkqqHx_iInJiCmIiCoJjHhGjBgGiCpAiDhNiDfIiDeOiCkJiCoHiCmNiClIiClHiBeC_xHqqkZx_
//			fciExtCode &= m_fciCurExtCodeFormat;
//			fciStdCode &= m_fciCurStdCodeFormat;
//		}
//	}
//----- 05.06.30 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	if (0 <= m_lSelFrom)
	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		if (bInit)
		{
			// _xZkqqHx_jFfHiPiAiDhEiDeIiBfLiDhNiDgCiDgHiCmFiPiJiKpKiJlLiBeCjBeJjBpAjEmNiImNjCiGiCmJiJhAiOjKiBeFjIgBiOjKiCkKjGlDiCkJiCmBiClNiPoKiNiHiCmJjEpFiCkGiCmEiBeC_xHqqkZx_
			fciExtCode = m_fciCurExtCodeFormat;
			fciStdCode = m_fciCurStdCodeFormat;
			// _xZkqqHx_jGkCiOgHjHhAiCmMiDhEiDiJiDePiCpAjHkHiCmEiCoJiBeC_xHqqkZx_
			fciExtCode.dwMask |= FDFI_FLAG_UNUSED;
			fciStdCode.dwMask |= FDFI_FLAG_UNUSED;
		}
		long lSelFrom, lSelTo;
		GetSelectNormal(lSelFrom, lSelTo);
		for (long lC = lSelFrom; lC < lSelTo; lC++)
		{
			//----- _xZkqqHx_iMlLiNnNiCmMjFlGiOjKiCmF_xHqqkZx_fciCur_xZkqqHx_iCpAiPiJiKpKiJlL_xHqqkZx_ -----
			FCEditChar rc = GetChar(lC);
			FCFontCharInfo fciCur;
			g_pEnv->GetSFontRec(rc.m_foidFont)->ReqInit(fciCur);
			rc.ReqOverwrite(fciCur);
			// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCkJiCmHiCkEiCkJiBeI_xHqqkZx_
			if (g_pReg->GetIsUseStdFont() && FFIsStdFontChar(Fdrch2Wchar(rc.m_wChar)))
			//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
			{
				fciStdCode &= fciCur;
			} else
			//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiImIiKePiCmMiPoKiNiH_xHqqkZx_ -----
			{
				fciExtCode &= fciCur;
			}
		}
	} else
	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKjGlDiCkCiPoKiNiH_xHqqkZx_ -----
	{
		if (bInit)
		{
			// _xZkqqHx_jFfHiPiAiDhEiDeIiBfLiDhNiDgCiDgHiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
			fciExtCode = m_fciCurExtCodeFormat;
			fciStdCode = m_fciCurStdCodeFormat;
			// _xZkqqHx_jGkCiOgHjHhAiCmMiDhEiDiJiDePiCpAjHkHiCmEiCoJiBeC_xHqqkZx_
			fciExtCode.dwMask |= FDFI_FLAG_UNUSED;
			fciStdCode.dwMask |= FDFI_FLAG_UNUSED;
		} else
		{
			// _xZkqqHx_iInJiCmIiCoJjHhGjBgGiCpAiDhNiDfIiDeOiCkJiCoHiCmNiClIiClHiBeC_xHqqkZx_
			fciExtCode &= m_fciCurExtCodeFormat;
			fciStdCode &= m_fciCurStdCodeFormat;
		}
	}
//----- 05.06.30 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::GetCurCharInfo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCurCharInfo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiDhEiDeIiBfLiDhNiDgCiDgHiCpAjAnNjCoIiClHiCoJiBeCiDhNiDfIiDeOiCmFiOhHjCoIiClDiCoKiClNjHhGjBgGiCmMiCnN_xHqqkZx_
 *			_xZkqqHx_iKpJjBlGiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCmJiPoDiPjBiCkLiCmFjAnNjCoIiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	fciExtCode	:_xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *			fciStdCode	:_xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	ToolRichText::OnFormatText_xZkqqHx_iCkJiCoHiBeBiDhEiDeIiDjDiDgHiDfPiDeDiDeBiDiNiDePiCmF_xHqqkZx_
 *			_xZkqqHx_iDhEiDeIiDjDiDgHiCpAjAnNjCoIiClFiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.01.28 Fukushiro M. _xZkqqHx_iMlLiNnNiImKjChFiCkKiNmFiMoDiCmIiCoHiBeBiNmFiPeJiJpMiNhDiCmM_xHqqkZx_
 *								_xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKjFmPiNfIiClDiCoKiCoJiCoGiCkEiCmJiClHiCoJiBeC_xHqqkZx_
 *			02.09.11 Fukushiro M. _xZkqqHx_iDlPiBeBiDmKiCmIiCmHiCmMjFlGiOjKiCpAiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmFjDpMjHmNiClFiBeB_xHqqkZx_
 *								_xZkqqHx_iDhEiDeIiDjDiDgHiCpA_xHqqkZx_Times New Roman_xZkqqHx_iCmJiClHiCoJiCmGiBeBjFfMiOkGiCkK_xHqqkZx_
 *								_xZkqqHx_iJlLiCkPiCoJiPoKiNiHiCmJjBmOiJjOiBeC_xHqqkZx_
 *			02.09.10 Fukushiro M. _xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkC_xHqqkZx_
 *								_xZkqqHx_iPoKiNiHiCmJjBmOiJjOiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCurCharInfo (	const FCFontCharInfo& fciExtCode,
										const FCFontCharInfo& fciStdCode)
{
//----- 05.07.01 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
//	DrawSelect();
//
//	CClientDC dc(this); // _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
//
//	// _xZkqqHx_iDhNiDfIiDeOiCmJjAnNjCoIiClDiCoKiClNiDiBiDjDiDgPiBfLiCmMiCnNiCpAiMlLiNnNiCmMjAnNjCoIiCmJiDfCiDhDiBfLiBeC_xHqqkZx_
//	m_fciCurExtCodeFormat |= fciExtCode;
//	m_fciCurStdCodeFormat |= fciStdCode;
//
//	long lSelFrom = -1;
//	long lSelTo = -1;
//
//	// _xZkqqHx_jBeJjBpAjEmNiImNiOoGjDlOiBeC_xHqqkZx_
//	GetSelectNormal(lSelFrom, lSelTo);
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiNmFiMoDiCmMjFlGiOjKiCpAiKnMiCnOiPoKiNiHiCmNiBeBiNmFiMoDiCmMiJeCiClFiJpMiNhDiCoAjCmHiJmBiBeC_xHqqkZx_
//	if (lSelTo == GetIndexSize()) lSelTo++;
//	if (lSelFrom < 0 && m_lCurIndex == GetIndexSize())
//	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkNiBeBiDeKiDiMiDgCiDgHiCkKiDeHiDgGiDeCiDfOiNmFiMoDiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ ----
//	{
//		// _xZkqqHx_iNmFiMoDiCmMiCfAjFlGiOjKiBgJiJpMiNhDiBgKiCpAjBeJjBpAiBeC_xHqqkZx_
//		lSelFrom = m_lCurIndex;
//		lSelTo = m_lCurIndex + 1;
//	}
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkCiPoKiNiHiCmNiClBiCmMiCnMiCnMjFjMiLeBiBeC_xHqqkZx_
//	if (lSelFrom < 0) return;
//
//	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjAoGjDkKiDeDiDjDiDgGiDgCiDeOiDfIiCmMiNhDiBeFjHpBiCpAiOoGjDlOiBeC_xHqqkZx_
//	long	lLine, lChar;
//	IndexToCharPos(lLine, lChar, lSelFrom);
//	// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKjHhAiCmJjFnLjBlGiBeC_xHqqkZx_
//	const long lLineFrom = lLine;
//	//----- _xZkqqHx_jBeJjBpAiClDiCoKiClNjFlGiOjKjHpBiCmMiDfCiDhDiBfLiCpAiCmGiCoJ_xHqqkZx_ -----
//	FCEditCharVector vChar;	// _xZkqqHx_iDfCiDhDiBfLjAoGjFlGiOjKjHpBiDgPiDgCiDhEiDeAiBeC_xHqqkZx_
//	for (long lCharSz = lSelTo - lSelFrom; 0 < lCharSz; lCharSz--)
//	{
//		vChar.push_back(m_vEditLine[lLine].m_vEditChar[lChar]);
//		(void)NextChar(lLine, lChar);
//	}
//	//----- _xZkqqHx_iDfCiDhDiBfLjAoGiCmMjFlGiOjKjHpBiCmJiBeBiDhEiDeIiDjDiDgHjFmPiNfIiCpAiCkJiCkPiCoJ_xHqqkZx_ -----
//	FCEditCharVector::iterator iEc;
//	// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
//	FCAutoDC atDC(&dc, FALSE, 0, 0);
//	//----- CFont_xZkqqHx_iCmMiPiJiKpKiJlLiLhJiCnBjFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJ_xHqqkZx_Zoom_xZkqqHx_iCpAiCfFiCfDjEhLiCmJjAnNjCoIiClHiCoJ_xHqqkZx_ -----
//	double	dZoom = g_->dZoom;
//	g_->dZoom = g_->dDisplayPPM * 64;
//
//	//----- _xZkqqHx_jFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_ -----
//	LOGFONT logFont;
//	// _xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkCiClNiCnPiBeBiDfCiBfLiDgIiDhJiBfLiDfHiCpAjHhAiInDiBeC_xHqqkZx_
//	WORD	wCodePage;
//	SFontID	foidCurFont = 0;
//	WORD	wCurOffset = 0;
//	g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
//	// _xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkCiClNiCnPiBeBiDfCiBfLiDgIiDhJiBfLiDfHiCpAjHhAiInDiBeC_xHqqkZx_
//	wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
//	atDC.SetFont(&logFont);
//	for (iEc = vChar.begin(); iEc != vChar.end(); iEc++)
//	{
//		//----- _xZkqqHx_iMlLiNnNiCmMiDhEiDeIiDjDiDgHiCmMjBkOjAkLiCmJ_xHqqkZx_fci_xZkqqHx_iCmMjBkOjAkLiCpAiCkJiCnEiClJiCoJ_xHqqkZx_ -----
//		FCFontCharInfo fciCur;
//		g_pEnv->GetSFontRec((*iEc).m_foidFont)->ReqInit(fciCur);
//		(*iEc).ReqOverwrite(fciCur);
//		//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiHiCmNiBeB_xHqqkZx_CharSet_xZkqqHx_iCpAjAnNjCoI_xHqqkZx_ -----
//		if (g_pReg->GetIsUseStdFont() && FFIsStdFontChar(Fdrch2Wchar((*iEc).m_wChar)))
//			fciCur |= fciStdCode;
//		else
//			fciCur |= fciExtCode;
//		FCSFontRec fntRec(fciCur);
//
//		// Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkJiCmBiClNiBeC_xHqqkZx_
//		// _xZkqqHx_iClBiCmMiClNiCnPiBeBiCkLiClPiCpBiCmG_xHqqkZx_CharSet_xZkqqHx_iCpAjClCiCnHiCoJiCoGiCkEiCmJiClFiClNiBeC_xHqqkZx_
//		// _xZkqqHx_iOhHjCoIiCmMjFlGiOjKiCkKjBkOiClHiCoJ_xHqqkZx_Charset_xZkqqHx_iCmMiPfHiNiHiCpAiOoGjDlOiBeC_xHqqkZx_
//		WORDVector vCharSet;
//		FFUnicodeToCharSet(vCharSet, Fdrch2Wchar((*iEc).m_wChar), fntRec.GetCharSet());
//		// FCSFontRec_xZkqqHx_iNfMjBkCjBmMiCkJiCoH_xHqqkZx_FontID_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
//		SFontID foidTmp = g_pEnv->FindNearestSFont(fntRec, &vCharSet);
//		// _xZkqqHx_jGlDiCkCiPoKiNiHiCmNjDgPjIfOiClHiCoJiBeC_xHqqkZx_
//		if (foidTmp == FD_S_FONT_UNSPECIFY)
//			g_pDoc->CmdInsert1SFont(foidTmp, fntRec);
//
//		//----- FCEditChar_xZkqqHx_iCmMjBkOjAkLiBgJjFlGiOjKjFjNjBkOjAkLiCpAiPjMiCkNiBgKiCpAjFmPiNfI_xHqqkZx_ -----
//		(*iEc).m_foidFont= foidTmp;
//		(*iEc).Overread(fciCur);
//
//		if (foidCurFont != (*iEc).m_foidFont || wCurOffset != (*iEc).m_wOffset)
//		//----- _xZkqqHx_iMlLiNnNiCmMiDhEiDeIiDjDiDgHiCmGiInJiCmIiCoJiPoKiNiHiBeBiDhEiDeIiDjDiDgHiNfIjAfGiPiIjHjNiCpAiNhDiCkE_xHqqkZx_ -----
//		{
//			// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiCpAjFmPiNfIiBeC_xHqqkZx_
//			foidCurFont = (*iEc).m_foidFont;
//			// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
//			wCurOffset = (*iEc).m_wOffset;
//			// _xZkqqHx_jFfHiPiAjCgMiCmM_xHqqkZx_Zoom_xZkqqHx_iCmF_xHqqkZx_logFont_xZkqqHx_iCpAjAnNjCoIiBeC_xHqqkZx_
//			g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
//			wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
//			atDC.SetFont(&logFont);
//		}
//		//----- _xZkqqHx_jFlGiOjKiBgJiDfCiBfLiDgI_xHqqkZx_wChar_xZkqqHx_iBgKiCmMjFjNiCpAiOoGjDlO_xHqqkZx_ -----
//		if ((*iEc).m_wChar != FDRCH_RETURN && (*iEc).m_wChar != FDRCH_CONTINUE &&
//			(*iEc).m_wChar != WCH_SPC && (*iEc).m_wChar != WCH_TAB)
//		{
//			ABC abc;
//			atDC.GetCharABCWidth((*iEc).m_wChar, abc, wCodePage);
//			(*iEc).m_mmfWidth = static_cast<fmmetol>(lg2mm(abc.abcA + abc.abcB + abc.abcC));
//			(*iEc).m_mmfAbcA = static_cast<fmmetol>(lg2mm(abc.abcA));
//			(*iEc).m_mmfAbcC = static_cast<fmmetol>(lg2mm(abc.abcC));
//		}
//	}
//	// Zoom_xZkqqHx_iCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_
//	g_->dZoom = dZoom;
//
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
//	SessionBegin();
//	// _xZkqqHx_iDhEiDeIiDjDiDgHjFmPiNfIiDfCiDhNiDjDiDgIiCpAjEkNiNhDiBeC_xHqqkZx_
//	CmdFormatChars(lSelFrom, vChar.size(), vChar.begin());
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
//	SessionEnd();
//
//	//----- _xZkqqHx_iImIiNhOiCmMiNhDiCpAiNmEiMhGiOfK_xHqqkZx_ -----
//	CalcLineBelow(lLineFrom);
//	m_mmCaretX = RepositionCaret();
//	SendRgnRedraw();
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
//	DrawSelect();
//----- 05.07.01 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	struct l_ {
		struct myCharInfo {
			FCFontCharInfo fciExtCode;
			FCFontCharInfo fciStdCode;
		};
		static void myCharInfoCallback (FCFontCharInfo* fciExtCode,
										FCFontCharInfo* fciStdCode,
										CFCWndRichEdit* pEditor,
										void* pData)
		{
			myCharInfo* pInfo = (myCharInfo*)pData;
			if (fciExtCode != NULL)
			{
				// _xZkqqHx_iDhNiDfIiDeOiCmJjAnNjCoIiClDiCoKiClNiDiBiDjDiDgPiBfLiCmMiCnNiCpAiMlLiNnNiCmMjAnNjCoIiCmJiDfCiDhDiBfLiBeC_xHqqkZx_
				*fciExtCode |= pInfo->fciExtCode;
			}
			if (fciStdCode != NULL)
			{
				// _xZkqqHx_iDhNiDfIiDeOiCmJjAnNjCoIiClDiCoKiClNiDiBiDjDiDgPiBfLiCmMiCnNiCpAiMlLiNnNiCmMjAnNjCoIiCmJiDfCiDhDiBfLiBeC_xHqqkZx_
				*fciStdCode |= pInfo->fciStdCode;
			}
		}
	};
	l_::myCharInfo myInfo;
	myInfo.fciExtCode = fciExtCode;
	myInfo.fciStdCode = fciStdCode;
	SetCurCharInfo(l_::myCharInfoCallback, (void*)&myInfo);
//----- 05.07.01 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::SetCurCharInfo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCurLineInfo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiNhDiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFnEiClHiBeCjBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiHiCmNiBeBiClLiCmMjCiGiCmF_xHqqkZx_
 *			_xZkqqHx_iLkEjCmKiClHiCoJiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	tli		:_xZkqqHx_iNhDiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFnEiClHiBeC_xHqqkZx_
 *			bInit	:tli_xZkqqHx_iCpAiPiJiKpKiJlLiClHiCoJiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeB_xHqqkZx_tli _xZkqqHx_iCmMjCgMiCmGiPgEiCmLiNiHiCoNiClJiCoJiPoKiNiHiCmN_xHqqkZx_
 *					 FALSE_xZkqqHx_iCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::GetCurLineInfo (	FCTextLineInfo& tli,
										BOOL bInit) const
{
	if (bInit)
	{
		// _xZkqqHx_jGkCiOgHjHhAiCmMiDhEiDiJiDePiCpAjAnNjCoIiBeC_xHqqkZx_
		tli.dwMask = FDTL_FLAG_UNUSED;
	}
	if (0 <= m_lSelFrom)
	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiPiJiCmGiNmFiMoDiCmMiNhDiCpAiOoGjDlOiBeC_xHqqkZx_
		long lSelFrom, lSelTo;
		GetSelectNormal(lSelFrom, lSelTo);
		long lLineFrom, lLineTo, lChar;
		IndexToCharPos(lLineFrom, lChar, lSelFrom);
		IndexToCharPos(lLineTo, lChar, lSelTo - 1);

		for (long lLine = lLineFrom; lLine <= lLineTo; lLine++)
		//----- _xZkqqHx_jBeJjBpAjEmNiImNiCmMiNhDiCpAiDiLiBfLiDhG_xHqqkZx_ -----
		{
			FCTextLineInfo tliCurrent;
			m_vEditLine[lLine].GetFormat(tliCurrent);
			tli &= tliCurrent;
		}
	} else
	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_iMlLiNnNiImKjChFiCmMiNhDiCpAiOoGjDlOiBeC_xHqqkZx_
		long lLine, lChar;
		GetCurCharPos(lLine, lChar);
		FCTextLineInfo tliCurrent;
		m_vEditLine[lLine].GetFormat(tliCurrent);
		tli &= tliCurrent;
	}
} // CFCWndRichEdit::GetCurLineInfo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCurLineInfo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiNhDiDhEiDeIiBfLiDhNiDgCiDgHiCpAjAnNjCoIiClHiCoJiBeCiDhNiDfIiDeOiCmFiOhHjCoIiClDiCoKiClNjHhGjBgGiCmMiCnN_xHqqkZx_
 *			_xZkqqHx_iKpJjBlGiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCmJiPoDiPjBiCkLiCmFjAnNjCoIiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	tli	:_xZkqqHx_iNhDiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCurLineInfo (const FCTextLineInfo& tli)
{
	struct l_ {
		static void myLineInfoCallback (FCTextLineInfo* tli,
										CFCWndRichEdit* pEditor,
										void* pData)
		{
			const FCTextLineInfo* ptliOverwrite = (const FCTextLineInfo*)pData;
			*tli |= *ptliOverwrite;
		}
	};
	SetCurLineInfo(l_::myLineInfoCallback, (void*)&tli);
} // CFCWndRichEdit::SetCurLineInfo.

//----- 05.07.01 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetAlignment
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCmMiNhDiCmMiKpBiClJiCpAjFnEiClHiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	WndRichEdit.h_xZkqqHx_iCpAiOfBiPmGiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//int CFCWndRichEdit::GetAlignment () const
//{
//	if (0 <= m_lSelFrom)
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
////----- 01.01.26 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
////		long lSelFrom= (m_lSelFrom < m_lSelTo) ? m_lSelFrom : m_lSelTo;
////		long lSelTo	=  (m_lSelFrom < m_lSelTo) ? m_lSelTo : m_lSelFrom;
////----- 01.01.26 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
//		long lSelFrom, lSelTo;
//		GetSelectNormal(lSelFrom, lSelTo);
////----- 01.01.26 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
//		long lLineFrom, lLineTo, lChar;
//		IndexToCharPos(lLineFrom, lChar, lSelFrom);
//		IndexToCharPos(lLineTo, lChar, lSelTo - 1);
//
//		int iAlign = m_vEditLine[lLineFrom].m_byAlignment;
//		for (long lLine = lLineFrom + 1; lLine <= lLineTo; lLine++)
//			if (iAlign != m_vEditLine[lLine].m_byAlignment) return FDRC_AL_NONE;
//		return iAlign;
//	} else
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
//	{
//		long lLine, lChar;
//		GetCurCharPos(lLine, lChar);
//		return m_vEditLine[lLine].m_byAlignment;
//	}
//} // CFCWndRichEdit::GetAlignment.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetAlignment
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiCmMiNhDiCmMiKpBiClJiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	iAlign	:_xZkqqHx_iKpBiClJiCpAiOhHjCoIiBeC_xHqqkZx_WndRichEdit.h_xZkqqHx_iCpAiOfBiPmGiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::SetAlignment (int iAlign)
//{
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
//	DrawSelect();
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
//	SessionBegin();
//	if (0 <= m_lSelFrom)
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
//		long lSelFrom, lSelTo;
//		GetSelectNormal(lSelFrom, lSelTo);
//		long lLineFrom, lLineTo, lChar;
//		// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
//		IndexToCharPos(lLineFrom, lChar, lSelFrom);
//		// lLineFrom_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
//		(void)JoinLineBelow(lLineFrom);
//		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
//		IndexToCharPos(lLineFrom, lChar, lSelFrom);
//		IndexToCharPos(lLineTo, lChar, lSelTo - 1);
//
//		FCEditLine el;
//		for (long lLine = lLineFrom; lLine <= lLineTo; lLine++)
//		{
//			// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
//			el.CopyProperty(m_vEditLine[lLine]);
//			el.m_byAlignment = iAlign;
//			// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
//			CmdFormatLine(CharPosToIndex(lLine, 0), el);
//		}
//		// _xZkqqHx_jFmPiNfIiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
//		CalcLineBelow(lLineFrom);
//		m_mmCaretX = RepositionCaret();
//		SendRgnRedraw();
//	} else
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
//	{
//		long lLine, lChar;
//		// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
//		GetCurCharPos(lLine, lChar);
//		// lLine_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
//		(void)JoinLineBelow(lLine);
//		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
//		GetCurCharPos(lLine, lChar);
//		FCEditLine el;
//		// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
//		el.CopyProperty(m_vEditLine[lLine]);
//		el.m_byAlignment = iAlign;
//		// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
//		CmdFormatLine(CharPosToIndex(lLine, 0), el);
//		// _xZkqqHx_jFmPiNfIiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
//		CalcLineBelow(lLine);
//		m_mmCaretX = RepositionCaret();
//		SendRgnRedraw();
//	}
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
//	SessionEnd();
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
//	DrawSelect();
//} // CFCWndRichEdit::SetAlignment.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetLineAfter
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAjFlGiOjKiImKjChFiCmMiNhDiKnEiBgJiNhDiJlKiBgKiCpAjFnEiClHiBeCjBeJjBpAiCkKjGlDiCkCiPoKiNiHiCmNiDeKiBfLiDfMiDiLiImKjChF_xHqqkZx_
// *			_xZkqqHx_iCmMiNhDiKnEiCpAjFnEiClHiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nLineAfter	:_xZkqqHx_iNhDiKnEiBgJiNhDiJlKiBgKiCpAjFnEiClHiBeCiDhMiDeDiDjDiDgHiNmAjFfHjCgMiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jCgMiCkKjFnEiClJiClNiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeBjFnEiClJiCmIiCkCiPoKiNiHiCmN_xHqqkZx_ FALSE_xZkqqHx_iBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.03.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//BOOL CFCWndRichEdit::GetLineAfter (short& nLineAfter) const
//{
//	if (0 <= m_lSelFrom)
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
//		long lSelFrom, lSelTo;
//		GetSelectNormal(lSelFrom, lSelTo);
//		long lLineFrom, lLineTo, lChar;
//		IndexToCharPos(lLineFrom, lChar, lSelFrom);
//		IndexToCharPos(lLineTo, lChar, lSelTo - 1);
//
//		short nLF = m_vEditLine[lLineFrom].m_nTwipLineAfter;
//		for (long lLine = lLineFrom + 1; lLine <= lLineTo; lLine++)
//			if (nLF != m_vEditLine[lLine].m_nTwipLineAfter) return FALSE;
//		nLineAfter = nLF;
//		return TRUE;
//	} else
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
//	{
//		long lLine, lChar;
//		GetCurCharPos(lLine, lChar);
//		nLineAfter = m_vEditLine[lLine].m_nTwipLineAfter;
//		return TRUE;
//	}
//} // CFCWndRichEdit::GetLineAfter.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetLineAfter
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAjFlGiOjKiImKjChFiCmMiNhDiKnEiBgJiNhDiJlKiBgKiCpAjAnNjCoIiClHiCoJiBeCjBeJjBpAiCkKjGlDiCkCiPoKiNiHiCmN_xHqqkZx_
// *			_xZkqqHx_iDeKiBfLiDfMiDiLiImKjChFiCmMiNhDiKnEiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nLineAfter	:_xZkqqHx_iNhDiKnEiBgJiNhDiJlKiBgKiCpAiOhHjCoIiClHiCoJiBeCiDhMiDeDiDjDiDgHiNmAjFfHjCgMiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.03.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::SetLineAfter (short nLineAfter)
//{
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
//	DrawSelect();
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
//	SessionBegin();
//	if (0 <= m_lSelFrom)
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
//	{
//		long lSelFrom, lSelTo;
//		GetSelectNormal(lSelFrom, lSelTo);
//		long lLineFrom, lLineTo, lChar;
//		// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
//		IndexToCharPos(lLineFrom, lChar, lSelFrom);
//		// lLineFrom_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
//		(void)JoinLineBelow(lLineFrom);
//		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
//		IndexToCharPos(lLineFrom, lChar, lSelFrom);
//		IndexToCharPos(lLineTo, lChar, lSelTo - 1);
//
//		FCEditLine el;
//		for (long lLine = lLineFrom; lLine <= lLineTo; lLine++)
//		{
//			// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
//			el.CopyProperty(m_vEditLine[lLine]);
//			el.m_nTwipLineAfter = nLineAfter;
//			// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
//			CmdFormatLine(CharPosToIndex(lLine, 0), el);
//		}
//		// _xZkqqHx_jFmPiNfIiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
//		CalcLineBelow(lLineFrom);
//		m_mmCaretX = RepositionCaret();
//		SendRgnRedraw();
//	} else
//	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
//	{
//		long lLine, lChar;
//		// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
//		GetCurCharPos(lLine, lChar);
//		// lLine_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
//		(void)JoinLineBelow(lLine);
//		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
//		GetCurCharPos(lLine, lChar);
//		FCEditLine el;
//		// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
//		el.CopyProperty(m_vEditLine[lLine]);
//		el.m_nTwipLineAfter = nLineAfter;
//		// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
//		CmdFormatLine(CharPosToIndex(lLine, 0), el);
//		// _xZkqqHx_jFmPiNfIiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
//		CalcLineBelow(lLine);
//		m_mmCaretX = RepositionCaret();
//		SendRgnRedraw();
//	}
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
//	SessionEnd();
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
//	DrawSelect();
//} // CFCWndRichEdit::SetLineAfter.
//----- 05.07.01 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::InflateFontSize
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAjEmNiImNiCmMiKgFiDhEiDeIiDjDiDgHiCmMiDfEiDeDiDfJiCpAiIoKjCgJjBoFiCkLiCkNiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::InflateFontSize ()
{
	struct l_ {
		static void myCharInfoCallback (FCFontCharInfo* fciExtCode,
										FCFontCharInfo* fciStdCode,
										CFCWndRichEdit* pEditor,
										void* pData)
		{
			if (fciExtCode != NULL)
			{
				// _xZkqqHx_iDhEiDeIiDjDiDgHiDfEiDeDiDfJiDiKiDfIiDgHiCpAiOgHiCmBiCmEiBeBiIoKjCgJjBoFiCkLiCmIiDfEiDeDiDfJiCpAiOoGjDlOiClHiCoJiBeC_xHqqkZx_
				long lpnt10x = FFGetLargerItemFromList(	D2L(10.0 * mm2pnt(fciExtCode->mmHeight)),
														s_l10xFontSizeList,
														sizeof(s_l10xFontSizeList) / sizeof(s_l10xFontSizeList[0]));
				fciExtCode->mmHeight = pnt2mm(dblpnt(lpnt10x) / 10.0);
			}
			if (fciStdCode != NULL)
			{
				// _xZkqqHx_iDhEiDeIiDjDiDgHiDfEiDeDiDfJiDiKiDfIiDgHiCpAiOgHiCmBiCmEiBeBiIoKjCgJjBoFiCkLiCmIiDfEiDeDiDfJiCpAiOoGjDlOiClHiCoJiBeC_xHqqkZx_
				long lpnt10x = FFGetLargerItemFromList(	D2L(10.0 * mm2pnt(fciStdCode->mmHeight)),
														s_l10xFontSizeList,
														sizeof(s_l10xFontSizeList) / sizeof(s_l10xFontSizeList[0]));
				fciStdCode->mmHeight = pnt2mm(dblpnt(lpnt10x) / 10.0);
			}
		}
	};
	SetCurCharInfo(l_::myCharInfoCallback, NULL);
} // CFCWndRichEdit::InflateFontSize.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::DeflateFontSize
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAjEmNiImNiCmMiKgFiDhEiDeIiDjDiDgHiCmMiDfEiDeDiDfJiCpAiIoKjCgJiPkMiClDiCkNiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::DeflateFontSize ()
{
	struct l_ {
		static void myCharInfoCallback (FCFontCharInfo* fciExtCode,
										FCFontCharInfo* fciStdCode,
										CFCWndRichEdit* pEditor,
										void* pData)
		{
			if (fciExtCode != NULL)
			{
				// _xZkqqHx_iDhEiDeIiDjDiDgHiDfEiDeDiDfJiDiKiDfIiDgHiCpAiOgHiCmBiCmEiBeBiIoKjCgJiPkMiClDiCmIiDfEiDeDiDfJiCpAiOoGjDlOiClHiCoJiBeC_xHqqkZx_
				long lpnt10x = FFGetSmallerItemFromList(D2L(10.0 * mm2pnt(fciExtCode->mmHeight)),
														s_l10xFontSizeList,
														sizeof(s_l10xFontSizeList) / sizeof(s_l10xFontSizeList[0]));
				fciExtCode->mmHeight = pnt2mm(dblpnt(lpnt10x) / 10.0);
			}
			if (fciStdCode != NULL)
			{
				// _xZkqqHx_iDhEiDeIiDjDiDgHiDfEiDeDiDfJiDiKiDfIiDgHiCpAiOgHiCmBiCmEiBeBiIoKjCgJiPkMiClDiCmIiDfEiDeDiDfJiCpAiOoGjDlOiClHiCoJiBeC_xHqqkZx_
				long lpnt10x = FFGetSmallerItemFromList(D2L(10.0 * mm2pnt(fciStdCode->mmHeight)),
														s_l10xFontSizeList,
														sizeof(s_l10xFontSizeList) / sizeof(s_l10xFontSizeList[0]));
				fciStdCode->mmHeight = pnt2mm(dblpnt(lpnt10x) / 10.0);
			}
		}
	};
	SetCurCharInfo(l_::myCharInfoCallback, NULL);
} // CFCWndRichEdit::DeflateFontSize.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::FindNext
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHiMoDjFpLiMjPiNpFiCpAiOmAiNhDiClHiCoJiBeCiDhBiDgCiDgHiImKjChFiCpAjBeJjBpAiPpDjBnEiCmJiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	sp	:_xZkqqHx_iMjPiNpFiDeHiDjDiDfHiDjDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDhBiDgCiDgHiClFiClNiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.24 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::FindNext (FCSearchParser& sp)
{
	WString strDoc;
	GetText(strDoc);
	long lCurIndex = GetCurIndex();
	long lFrom;
	long lTo;
	const wchar_t* wcpFrom;
	const wchar_t* wcpTo;
	GetSelectNormal(lFrom, lTo);
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiHiCmNiBeBiJlKjFpLiCpAiMjPiNpFiKeKiOgOiImKjChFiCmJiBeC_xHqqkZx_
	if (lFrom != lTo) lCurIndex++;
	// _xZkqqHx_iMjPiNpFiCmJiDhBiDgCiDgHiClHiCoJiPoKiNiHiCmNiBeBiDfOiBfLiDfBiDgCiDgHjAnNjCoIiBeC_xHqqkZx_
	if (sp.GetNextMatchingPos(wcpFrom, wcpTo, strDoc.c_str(),
											strDoc.c_str() + lCurIndex))
	//----- _xZkqqHx_iMjPiNpFiCmJiDhBiDgCiDgHiClFiClNiPoKiNiH_xHqqkZx_ -----
	{
		lFrom = wcpFrom - strDoc.c_str();
		lTo = wcpTo - strDoc.c_str();
		SetSelect(lFrom, lTo);
		SetCurIndex(lFrom);
		return TRUE;
	} else
	//----- _xZkqqHx_iMjPiNpFiCmJiDhBiDgCiDgHiClFiCmIiCkJiCmBiClNiPoKiNiH_xHqqkZx_ -----
	{
		return FALSE;
	}
} // CFCWndRichEdit::FindNext.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::FindPrev
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDgFiDeMiDfIiDgHjBePjFpLiMjPiNpFiCpAiOmAiNhDiClHiCoJiBeCiDhBiDgCiDgHiImKjChFiCpAjBeJjBpAiPpDjBnEiCmJiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	sp	:_xZkqqHx_iMjPiNpFiDeHiDjDiDfHiDjDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDhBiDgCiDgHiClFiClNiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.24 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::FindPrev (FCSearchParser& sp)
{
	WString strDoc;
	GetText(strDoc);
	long lCurIndex = GetCurIndex();
	long lFrom;
	long lTo;
// 01.01.26 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	GetSelectNormal(lFrom, lTo);
	const wchar_t* wcpFrom;
	const wchar_t* wcpTo;
//----- 01.01.26 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiHiCmNiBeBjEmNiImNiCmMiNmFiPiJiCmMiPoDjFpLiCpAiMjPiNpFiKeKiOgOiImKjChFiCmJiBeC_xHqqkZx_
//	if (lFrom != lTo) lCurIndex = lFrom;
//----- 01.01.26 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iMjPiNpFiCmJiDhBiDgCiDgHiClHiCoJiPoKiNiHiCmNiBeBiDfOiBfLiDfBiDgCiDgHjAnNjCoIiBeC_xHqqkZx_
	if (sp.GetPrevMatchingPos(wcpFrom, wcpTo, strDoc.c_str(),
											strDoc.c_str() + lCurIndex))
	//----- _xZkqqHx_iMjPiNpFiCmJiDhBiDgCiDgHiClFiClNiPoKiNiH_xHqqkZx_ -----
	{
		lFrom = wcpFrom - strDoc.c_str();
		lTo = wcpTo - strDoc.c_str();
		SetSelect(lFrom, lTo);
		SetCurIndex(lFrom);
		return TRUE;
	} else
	//----- _xZkqqHx_iMjPiNpFiCmJiDhBiDgCiDgHiClFiCmIiCkJiCmBiClNiPoKiNiH_xHqqkZx_ -----
	{
		return FALSE;
	}
} // CFCWndRichEdit::FindPrev.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	myMkDiff
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jDpBiCmCiCmMjFlGiOjKjHpBiCmMiNlHjFkKiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lFrom	:strBefore_xZkqqHx_jCiGiCmMiBeBjChFiKlHjFjEjFkKiCmMiNmFiPiJiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *			lTo		:strBefore_xZkqqHx_jCiGiCmMiBeBjChFiKlHjFjEjFkKiCmMiNmFiMoDiCmMiOjPiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *			strNew	:strAfter_xZkqqHx_jCiGiCmMiBeBjChFiKlHjFjEjFkKiCmMjFlGiOjKjHpBiCpAjFnEiClHiBeC_xHqqkZx_
 *			strBefore	:_xZkqqHx_jEoEiKhCiClHiCoJiCfBiCmCiCmMjFlGiOjKjHpBiCmMiCfAiCpAiOhHjCoIiBeC_xHqqkZx_
 *			strAfter	:_xZkqqHx_jEoEiKhCiClHiCoJiCfBiCmCiCmMjFlGiOjKjHpBiCmMiCfBiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jFmPiNfIiCkKiCkAiCoJiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	strBefore = "Hello" strAfter "Hemmmo" _xZkqqHx_iCmMiPoKiNiH_xHqqkZx_
 *			lFrom = 2, lTo = 4, strNew = "mmm"
 *			strBefore = "AAAA" strAfter "AAAAAA" _xZkqqHx_iCmMiPoKiNiH_xHqqkZx_
 *			lFrom = 4, lTo = 4, strNew = "AA"
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
static BOOL myMkDiff (long& lFrom, long& lTo, WString& strNew,
						const WString& strBefore, const WString& strAfter)
{
	// _xZkqqHx_jFmPiNfIiCkKjGlDiCkCiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
	if (strBefore == strAfter) return FALSE;
	for (lFrom = 0; lFrom < strBefore.length() && lFrom < strAfter.length(); lFrom++)
	{
		if (strBefore.at(lFrom) != strAfter.at(lFrom)) break;
	}
	lTo = strBefore.length();
	long lIdxA = strAfter.length();
// 02.06.07 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ (_xZkqqHx_jChFiKlHiBhFjBfDiCmEiCmMiCmMiDiNiDgCiDeOiBhGiCpAiBhFjBfDiCmEiCmMiDiNiDgCiDeOiBhGiCmJjBfDjChFiKlHiCmFjHiOiClPiCoJ_xHqqkZx_)
//	for (; 0 < lTo && 0 < lIdxA && lFrom < lTo; lTo--, lIdxA--)
	for (; 0 < lTo && 0 < lIdxA && lFrom < lTo && lFrom < lIdxA; lTo--, lIdxA--)
	{
		if (strBefore.at(lTo - 1) != strAfter.at(lIdxA - 1)) break;
	}
	strNew.erase();
	strNew.append(strAfter.c_str() + lFrom, strAfter.c_str() + lIdxA);
	return TRUE;
} // myMkDiff.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ReplaceAll
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiDeKiDiMiDgCiDgHiImKjChFiCkJiCoHiImIiNhOiCpAjBfDiCmEjChFiKlHiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	sp	:_xZkqqHx_iMjPiNpFiDeHiDjDiDfHiDjDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::ReplaceAll (FCSearchParser& sp)
{
	// wchar_t_xZkqqHx_iMfOiCmMiDgFiDeMiDfIiDgHiCpAiOoGjDlOiClHiCoJiBeC_xHqqkZx_
	WString strText;
	GetText(strText);
	// _xZkqqHx_jChFiKlHjBmOiPnLiCmMiDgFiDeMiDfIiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
	const wchar_t* pText = strText.c_str() + GetCurIndex();
	// _xZkqqHx_jBeJjBpAiCpAiJpAiPjMiClHiCoJiBeC_xHqqkZx_
	SetSelect(-1, -1);
//----- 02.08.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ (_xZkqqHx_jFhDjHhG_xHqqkZx_)-----
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
//	DrawSelect();
//----- 02.08.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ (_xZkqqHx_jFhDjHhG_xHqqkZx_)-----
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	for (;;)
	{
		wchar_t* wcpFrom;
		wchar_t* wcpTo;
		if (!sp.GetNextMatchingPos(wcpFrom, wcpTo, strText.c_str(), pText)) break;
		// _xZkqqHx_jChFiKlHjBePiCmMjBeJjBpAjEmNiImNiDgFiDeMiDfIiDgHiCpAiOoGjDlOiBeC_xHqqkZx_
		WString strBefore(wcpFrom, wcpTo);
		// _xZkqqHx_jChFiKlHiMoDiCmMiDgFiDeMiDfIiDgHiCpAiOoGjDlOiBeC_xHqqkZx_
		WString strAfter;
		sp.GetReplaceText(strAfter);
		// _xZkqqHx_jChFiKlHiMoDiCmMiBeBiOjPiCmMiMjPiNpFiKeKiOgOiImKjChFiCpAjHfMiCnPiOfKiPgPiBeC_xHqqkZx_
		long lNext = (wcpFrom - strText.c_str()) + strAfter.length();
		// _xZkqqHx_jChFiKlHjBePiBeFiMoDiCmMiDgFiDeMiDfIiDgHiCkJiCoHiBeBiNfIiCmJiPkMiClDiCkCjChFiKlHjEmNiImNiCpAiOfKiPgPiClHiCoJiBeC_xHqqkZx_
		// _xZkqqHx_jHoBiBeG_xHqqkZx_Before = "Masayuki" After = "Masako" -> NewAfter = "ko"
		long lFromBefore;
		long lToBefore;
		WString strNewAfter;
		if (myMkDiff(lFromBefore, lToBefore, strNewAfter, strBefore, strAfter))
		{
			// _xZkqqHx_jChFiKlHjEmNiImNiCpAiOfKiPgPiBeC_xHqqkZx_
			long lFrom = (wcpFrom + lFromBefore) - strText.c_str();
			long lTo = (wcpFrom + lToBefore) - strText.c_str();
			// _xZkqqHx_iDgFiDeMiDfIiDgHiCpAjChFiKlHiClHiCoJiBeC_xHqqkZx_
			strText.replace(lFrom, lTo - lFrom, strNewAfter.c_str());
			// _xZkqqHx_iDeHiDgGiDeCiDfOiCoAjDkPjHgMiCmJjChFiKlHiClHiCoJiBeC_xHqqkZx_
			MCmdReplaceText(lFrom, lTo, strNewAfter.c_str());
		}
		// _xZkqqHx_jAfGiClFiCkCiMjPiNpFiKeKiOgOiImKjChFiCpAiOfKiPgPiClHiCoJiBeC_xHqqkZx_
		pText = strText.c_str() + lNext;
	}
	// _xZkqqHx_iNmFiMoDiCmMjChFiKlHiImKjChFiCpAiMlLiNnNiCmMiDeKiDiMiDgCiDgHiImKjChFiCmJjAnNjCoIiBeC_xHqqkZx_
	SetCurIndex(pText - strText.c_str());
	// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiBeC_xHqqkZx_
	CalcLineAll();
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
} // CFCWndRichEdit::ReplaceAll.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ReplaceOne
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjBeJjBpAjEmNiImNiCkKjBeJjBpAiPpAiMiPiCmJiIoKjChGiClHiCoJiPoKiNiHiBeBiClBiCmMjEmNiImNiCpAjChFiKlHiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lFrom	:_xZkqqHx_jChFiKlHiMoDiCmMjChFiKlHjEmNiImNiCmMiNmFiPiJiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *			lTo		:_xZkqqHx_jChFiKlHiMoDiCmMjChFiKlHjEmNiImNiCmMiNmFiMoDiCmMiOjPiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *			sp		:_xZkqqHx_iMjPiNpFiDeHiDjDiDfHiDjDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iIoKjChGiBeBjChFiKlHiClDiCoKiClNiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.26 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::ReplaceOne (long& lFrom, long& lTo, FCSearchParser& sp)
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCpAiOoGjDlOiBeC_xHqqkZx_
	GetSelectNormal(lFrom, lTo);
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkCiPoKiNiHiCmNiPeJjHlJiBeC_xHqqkZx_
	if (lFrom == lTo) return FALSE;
	// _xZkqqHx_jBeJjBpAiCpAiJpAiPjMiClHiCoJiBeC_xHqqkZx_
	SetSelect(-1, -1);
	// wchar_t_xZkqqHx_iMfOiCmMiDgFiDeMiDfIiDgHiCpAiOoGjDlOiClHiCoJiBeC_xHqqkZx_
	WString strText;
	GetText(strText);
	// _xZkqqHx_iMjPiNpFiPiIjHjNiBeC_xHqqkZx_
	const wchar_t* wcpNext = sp.GetMatchingPos(strText.c_str(), strText.c_str() + lFrom);
	// _xZkqqHx_iMjPiNpFiPpAiMiPiCmJiIoKjChGiClFiCmIiCkCiPoKiNiHiCmNiPeJjHlJiBeC_xHqqkZx_
	if (wcpNext == NULL) return FALSE;
	if (wcpNext - strText.c_str() != lTo) return FALSE;
	// _xZkqqHx_jChFiKlHjBePiCmMjBeJjBpAjEmNiImNiDgFiDeMiDfIiDgHiCpAiOoGjDlOiBeC_xHqqkZx_
	WString strBefore(strText.c_str() + lFrom, wcpNext);
	// _xZkqqHx_jChFiKlHiMoDiCmMiDgFiDeMiDfIiDgHiCpAiOoGjDlOiBeC_xHqqkZx_
	WString strAfter;
	sp.GetReplaceText(strAfter);
	// _xZkqqHx_jChFiKlHjBePiBeFiMoDiCmMiDgFiDeMiDfIiDgHiCkJiCoHiBeBiNfIiCmJiPkMiClDiCkCjChFiKlHjEmNiImNiCpAiOfKiPgPiClHiCoJiBeC_xHqqkZx_
	// _xZkqqHx_jHoBiBeG_xHqqkZx_Before = "Masayuki" After = "Masako" -> NewAfter = "ko"
	long lFromBefore;
	long lToBefore;
	WString strNewAfter;
	if (myMkDiff(lFromBefore, lToBefore, strNewAfter, strBefore, strAfter))
	{
		// _xZkqqHx_jChFiKlHjEmNiImNiCpAiOfKiPgPiBeC_xHqqkZx_
		long lCoreFrom = lFrom + lFromBefore;
		long lCoreTo = lFrom + lToBefore;
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
		DrawSelect();
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
		SessionBegin();
		// _xZkqqHx_jChFiKlHiBeC_xHqqkZx_
		MCmdReplaceText(lCoreFrom, lCoreTo, strNewAfter.c_str());
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
		SessionEnd();
		// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiBeC_xHqqkZx_
		CalcLineAll();
		m_mmCaretX = RepositionCaret();
		SendRgnRedraw();
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
		DrawSelect();
	}
	lTo = lFrom + strAfter.length();
	return TRUE;
} // CFCWndRichEdit::ReplaceOne.

//----- 02.06.24 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnChars
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiImKjChFiCmJjFlGiOjKjHpBiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wcpText	:_xZkqqHx_jBhNjDpMiClHiCoJ_xHqqkZx_UNICODE_xZkqqHx_jFlGiOjKjHpBiCpAiOhHjCoIiBeCiLpDjFlGiOjKiCmFiPeJiCoJjFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	CalcLine_xZkqqHx_iBeB_xHqqkZx_Redraw_xZkqqHx_iPiIjHjNiCpAiNhDiCkEiBeC_xHqqkZx_
 *			_xZkqqHx_iJpMiNhDjFlGiOjKiCkKiKnMiCnMiCoKiCmEiCkCiCmEiCoAiCoGiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	02.06.24 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnChars (const wchar_t* wcpText)
{
	long lLine;
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	long lSelFrom, lSelTo;
	GetSelectNormal(lSelFrom, lSelTo);
	if (0 <= lSelFrom)
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiHiCmNiPoDiPjBiCkLiDiCiBfLiDgIiCkJiCmHiCkEiCkJiCmNiKnGiMfHiCmIiCkC_xHqqkZx_ -----
		lLine = MCmdReplaceText(lSelFrom, lSelTo, wcpText);
	} else if (FFGetMainWnd()->IsOvrMode())
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkNiBeBiKiOiCmCiPoDiPjBiCkLiDiCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
	{
		//----- wcpText_xZkqqHx_jCiGiCmMiJpMiNhDiImIiKePiCmMjFlGiOjKiCmMjAjEiCpAiDeKiDeFiDjDiDgH_xHqqkZx_ -----
		// _xZkqqHx_jFlGiOjKjAjEiCpAiDeKiDeFiDjDiDgHiClFiCmIiCkCiCmGiBeBiPoDiPjBiCkLiCmJiClFiCmEiBeB_xHqqkZx_Enter_xZkqqHx_iClHiCoJiCmGiBeBjClMjBePiCmMjFlGiOjKiCkKiPmBiCkGiCoJiBeC_xHqqkZx_
		long lCount = 0;
		for (long lC = 0; wcpText[lC] != L'\0'; lC++)
			if (wcpText[lC] != L'\r' && wcpText[lC] != L'\n')
				lCount++;
		//----- _xZkqqHx_iJpMiNhDiImIiKePiCmMjFlGiOjKjAjEiCmMjFlGiOjKiCpAjChFiKlHiClHiCoJ_xHqqkZx_ -----
		if (m_lCurIndex + lCount <= GetIndexSize())
			lLine = MCmdReplaceText(m_lCurIndex, m_lCurIndex + lCount, wcpText);
		else
			lLine = MCmdReplaceText(m_lCurIndex, GetIndexSize(), wcpText);
	} else
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkNiBeBiKiOiCmCjBhNjDpMiDiCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
	{
		lLine = MCmdReplaceText(m_lCurIndex, m_lCurIndex, wcpText);
	}
	// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiBeC_xHqqkZx_
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	CalcLineAll();
	CalcLineBelow(lLine);
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();
} // CFCWndRichEdit::OnChars.
//----- 02.06.24 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

//----- 02.08.14 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OverwriteFormat
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAiBeBiOhHjCoIiCmMjFlGiOjKiCmMiPoOjFpBiCmFiPoDiPjBiCkLiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	fciExtCodeFormat	:_xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *								 eChar_xZkqqHx_iCmMjDeLjDjGiCmIiPoOjFpBiCkKiPoDiPjBiCkLiClDiCoKiCmEjFnEiClDiCoKiCoJiBeC_xHqqkZx_
 *			fciStdCodeFormat	:_xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *								 eChar_xZkqqHx_iCmMjDeLjDjGiCmIiPoOjFpBiCkKiPoDiPjBiCkLiClDiCoKiCmEjFnEiClDiCoKiCoJiBeC_xHqqkZx_
 *			eChar				:_xZkqqHx_jFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAiPoDiPjBiCkLiClHiCoJiClNiCnPiCmM_xHqqkZx_
 *								 _xZkqqHx_jFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iPnKiNnH_xHqqkZx_>	_xZkqqHx_iMlDiBfIiCmN_xHqqkZx_ResetCurFormat_xZkqqHx_iCmMiPiIjHjNiKnGjAjEiBeC_xHqqkZx_MCmdReplaceText_xZkqqHx_iCmFiCoA_xHqqkZx_
 *			_xZkqqHx_jHjIjHhAiClHiCoJiClNiCnPiBeBjFkKjHkDiClFiClNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	02.08.14 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OverwriteFormat (FCFontCharInfo& fciExtCodeFormat,
									  FCFontCharInfo& fciStdCodeFormat,
									  const FCEditChar& eChar) const
{
	//----- _xZkqqHx_iOhHjCoIiCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCmGjFlGiOjKiPoOjFpBiCmFiPiJiKpKiJlL_xHqqkZx_ -----
	FCFontCharInfo fciCur;
	g_pEnv->GetSFontRec(eChar.m_foidFont)->ReqInit(fciCur);
	eChar.ReqOverwrite(fciCur);
	// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCkJiCmHiCkEiCkJiCmFiPiJiKpKiJlLjAoGiCpAjFmPiCkGiCoJiBeC_xHqqkZx_
	if (FFIsStdFontChar(Fdrch2Wchar(eChar.m_wChar)))
	{
		FFOverwrite(fciStdCodeFormat, fciCur, FDFI_FLAG_ALL);
		FFOverwrite(fciExtCodeFormat, fciCur, 
				FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
				FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
	} else
	{
		FFOverwrite(fciExtCodeFormat, fciCur, FDFI_FLAG_ALL);
		FFOverwrite(fciStdCodeFormat, fciCur, 
				FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
				FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
	}
} // CFCWndRichEdit::OverwriteFormat.
//----- 02.08.14 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----

//----- 02.08.26 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ (NextChar_xZkqqHx_iCpAjHjIjHhAiClFiClNjFpLiCkKiCoGiCkC_xHqqkZx_)-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetChar
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiBeBjHpBiCmMjFlGiOjKiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	:_xZkqqHx_iNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lChar	:_xZkqqHx_jHpBiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jFlGiOjKiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	02.08.26 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
const FCEditChar& CFCWndRichEdit::GetChar (long lLine, long lChar) const
{
	return m_vEditLine[lLine].m_vEditChar[lChar];
} // CFCWndRichEdit::GetChar.
//----- 02.08.26 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ (NextChar_xZkqqHx_iCpAjHjIjHhAiClFiClNjFpLiCkKiCoGiCkC_xHqqkZx_)-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OptimizeCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMjDoAjHgFiCpAiNmFjDeLiJlLiClFiCmEiBeBiDfEiDeDiDfJiCpAiPkMiClDiCkNiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	byvQueue	:_xZkqqHx_iDeMiDiFiBfLiCpAjAnNjCoIiClFiBeBiNmFjDeLiJlLiClFiClNiMiLiJmKiCpAjFnEiClHiBeC_xHqqkZx_
 *			bIsFlatText	:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMjDoAjHgFiCpAiDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCmJjFmPiKlHiClFiCmE_xHqqkZx_
 *						 _xZkqqHx_iNmFjDeLiJlLiClHiCoJiCkJiBeIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			bIsFlatChar	:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMjDoAjHgFiCpAiDhEiDiJiDgCiDgHiDeMiDiDiDiJiDeOiDfOiCmJjFmPiKlHiClFiCmE_xHqqkZx_
 *						 _xZkqqHx_iNmFjDeLiJlLiClHiCoJiCkJiBeIiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCpAiOhHjCoIiClHiCoJiCmGiBeBiNhDiCmMjBkOjAkLiBeBjHfNjEjCiBeBiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCmJ_xHqqkZx_
 *			_xZkqqHx_iKnGiClHiCoJiPoOjFpBiCmNiNoNiPjMiClDiCoKiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDhEiDiJiDgCiDgHiDeMiDiDiDiJiDeOiDfOiCpAiOhHjCoIiClHiCoJiCmGiBeBiDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCmJiJmBiCkGiCmEiBeBjFlGiOjK_xHqqkZx_
 *			_xZkqqHx_jBkOjAkLiBgJiDhEiDeIiDjDiDgHjDjJiBgKiCmMiPoOjFpBiCkKiNoNiPjMiClDiCoKiBeBjFlGiOjKiDfCiBfLiDgIiCmMiCnNiCmGiCmIiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDhEiDiJiDgCiDgHiDeMiDiDiDiJiDeOiDfOiCmNiDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCkKiOhHjCoIiClDiCoKiCmEiCkCiCoJiPoKiNiHiCmMiCnN_xHqqkZx_
 *			_xZkqqHx_iOhHjCoIiCmFiCkLiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.01.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OptimizeCmdQueue (BYTEVector& byvQueue, BOOL bIsFlatText, BOOL bIsFlatChar)
{
	// _xZkqqHx_iBjMjFlGiOjKjChFiKlHiBhLjFlGiOjKjChFiKlH_xHqqkZx_ _xZkqqHx_iCmMiPoKiNiHiCfA_xHqqkZx_
	//
	//       _xZkqqHx_iEkBiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkC_xHqqkZx_
	// _xZkqqHx_iPpDjBnEiCfAiEkAiCgAiEkAiCgBiEkAiCgCiEkAiCgDiEkAiCgEiEkAiCgFiEkAiCgGiEkAiCgHiEkAiCgIiEkAiCgJiEkAiCgKiEkAiCgLiEkA_xHqqkZx_
	//       _xZkqqHx_iEkEiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkD_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkH_xHqqkZx_
	// _xZkqqHx_iDfCiDhNiDjDiDgIiCfA_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_1 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_1 _xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_X2_xZkqqHx_iEkJ_xHqqkZx_X3_xZkqqHx_iEkH_xHqqkZx_
	//                             _xZkqqHx_iEkBiEjPiEkC_xHqqkZx_
	//                           _xZkqqHx_iEkBiEkD_xHqqkZx_  _xZkqqHx_iEkEiEkC_xHqqkZx_
	//                            _xZkqqHx_iBfP_xHqqkZx_    _xZkqqHx_iBfO_xHqqkZx_
	//                              _xZkqqHx_iBfPiBfO_xHqqkZx_
	//       _xZkqqHx_iEkBiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkC_xHqqkZx_
	// _xZkqqHx_iPpDjBnEiCfBiEkAiCgAiEkAiCgBiEkAiCgCiEkA_xHqqkZx_X1_xZkqqHx_iEkA_xHqqkZx_X2_xZkqqHx_iEkA_xHqqkZx_X3_xZkqqHx_iEkAiCgJiEkAiCgKiEkAiCgLiEkA_xHqqkZx_
	//       _xZkqqHx_iEkEiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkD_xHqqkZx_
	//                           _xZkqqHx_iEkFiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkJiCfIiEkH_xHqqkZx_
	//         _xZkqqHx_iDfCiDhNiDjDiDgIiCfB_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_2 _xZkqqHx_iEkFiEjPiEjPiEjPiEkH_xHqqkZx_
	//                     _xZkqqHx_jCmHiJmB_xHqqkZx_2 _xZkqqHx_iEkF_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkH_xHqqkZx_
	//                             _xZkqqHx_iEkBiEjPiEkC_xHqqkZx_
	//                           _xZkqqHx_iEkBiEkD_xHqqkZx_  _xZkqqHx_iEkEiEkC_xHqqkZx_
	//                            _xZkqqHx_iBfP_xHqqkZx_    _xZkqqHx_iBfO_xHqqkZx_
	//                              _xZkqqHx_iBfPiBfO_xHqqkZx_
	//       _xZkqqHx_iEkBiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkC_xHqqkZx_
	// _xZkqqHx_iPpDjBnEiCfCiEkAiCgAiEkAiCgBiEkAiCgCiEkA_xHqqkZx_X1_xZkqqHx_iEkA_xHqqkZx_X2_xZkqqHx_iEkA_xHqqkZx_Y1_xZkqqHx_iEkA_xHqqkZx_Y2_xZkqqHx_iEkA_xHqqkZx_Y3_xZkqqHx_iEkA_xHqqkZx_Y4_xZkqqHx_iEkA_xHqqkZx_Y5_xZkqqHx_iEkAiCgKiEkAiCgLiEkA_xHqqkZx_
	//       _xZkqqHx_iEkEiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkD_xHqqkZx_
	//
	// _xZkqqHx_iDfCiDhNiDjDiDgIiCfAiCmGiDfCiDhNiDjDiDgIiCfBiCpAiDhNiBfLiDfHiClFiBeBiCfAiDfCiDhNiDjDiDgIiCmFiPpDjBnEiCfAiCkJiCoHiPpDjBnEiCfCiCmJ_xHqqkZx_
	// _xZkqqHx_jFmPiNfIiCmFiCkLiCoJiCoGiCkEiCmJiClHiCoJiBeC_xHqqkZx_
	//
	//                   p1          p3          p2
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkH_xHqqkZx_
	// _xZkqqHx_iDfCiDhNiDjDiDgIiCfA_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_1 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_1 _xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_X2_xZkqqHx_iEkJ_xHqqkZx_X3_xZkqqHx_iEkH_xHqqkZx_
	//                           _xZkqqHx_iEkFiCiBiEkH_xHqqkZx_
	//                           _xZkqqHx_iEkFiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkJiCfIiEkH_xHqqkZx_
	//         _xZkqqHx_iDfCiDhNiDjDiDgIiCfB_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_2 _xZkqqHx_iEkFiEjPiEjPiEjPiEkH_xHqqkZx_
	//                     _xZkqqHx_jCmHiJmB_xHqqkZx_2 _xZkqqHx_iEkF_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkH_xHqqkZx_
	//                           r1      r3          r2
	//
	// _xZkqqHx_iCfAiBeEjCmHiJmB_xHqqkZx_1_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2_xZkqqHx_iCmMjAmP_xHqqkZx_(_xZkqqHx_iCiB_xHqqkZx_)_xZkqqHx_iCpAiOfKiPgPiBeC_xHqqkZx_
	//     _xZkqqHx_iCiBiCpAjCmHiJmB_xHqqkZx_1_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2_xZkqqHx_iCkJiCoHiPjMiKePiClFiCmEiBeBjCmHiJmB_xHqqkZx_1'_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2'_xZkqqHx_iCpAiOfKiPgPiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_1'_xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_X2_xZkqqHx_iEkH_xHqqkZx_
	//                           _xZkqqHx_iEkFiCiBiEkH_xHqqkZx_
	//                         _xZkqqHx_iNoNiPjM_xHqqkZx_2'_xZkqqHx_iEkFiEjPiEkH_xHqqkZx_
	//
	// _xZkqqHx_iCfBiBeEiNoNiPjM_xHqqkZx_1_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2'_xZkqqHx_iCpAiDhNiBfLiDfHiClFiCmEiNoNiPjM_xHqqkZx_1'_xZkqqHx_iCpAiOfKiPgPiBeCiNoNiPjM_xHqqkZx_2'_xZkqqHx_iCmMiCkEiClPiBeB_xHqqkZx_
	//     _xZkqqHx_iNoNiPjM_xHqqkZx_1_xZkqqHx_iCmMjAoGjDkK_xHqqkZx_(p1)_xZkqqHx_iCoGiCoIjBePiCmJiCkAiCoJiCoAiCmMiCmNiBeBiClLiCmMiCnMiCnMiNoNiPjM_xHqqkZx_1_xZkqqHx_iCmMjBePiCmJjAnKjBlBiBeB_xHqqkZx_
	//     p1_xZkqqHx_iCoGiCoIiMoDiCmJiCkAiCoJiCoAiCmMiCmNiBeBiNoNiPjM_xHqqkZx_1_xZkqqHx_iCmMiMoD_xHqqkZx_(p2)_xZkqqHx_iCmJjCmHiJmBiClHiCoJiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkJiCfIiEkH_xHqqkZx_
	//             _xZkqqHx_iNoNiPjM_xHqqkZx_1'_xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkJiEjPiEkH_xHqqkZx_
	//                                           _xZkqqHx_iEkFiEjPiEkHiNoNiPjM_xHqqkZx_2'
	//
	// _xZkqqHx_iCfCiBeEjCmHiJmB_xHqqkZx_1'_xZkqqHx_iCmGjCmHiJmB_xHqqkZx_2_xZkqqHx_iCpAiDhNiBfLiDfHiClFiCmEjCmHiJmB_xHqqkZx_2'_xZkqqHx_iCpAiOfKiPgPiBeCjCmHiJmB_xHqqkZx_1'_xZkqqHx_iCmMiCkEiClPiBeB_xHqqkZx_
	//     _xZkqqHx_jCmHiJmB_xHqqkZx_2_xZkqqHx_iCmMjAoGjDkK_xHqqkZx_(r1)_xZkqqHx_iCoGiCoIjBePiCmJiCkAiCoJiCoAiCmMiCmNiBeBiClLiCmMiCnMiCnMjCmHiJmB_xHqqkZx_2_xZkqqHx_iCmMjBePiCmJjAnKjBlBiBeB_xHqqkZx_
	//     r1_xZkqqHx_iCoGiCoIiMoDiCmJiCkAiCoJiCoAiCmMiCmNiBeBjCmHiJmB_xHqqkZx_2_xZkqqHx_iCmMiMoD_xHqqkZx_(r2)_xZkqqHx_iCmJjCmHiJmBiClHiCoJiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkJiCfIiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_2'_xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_X2_xZkqqHx_iEkJ_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkH_xHqqkZx_
	//
	// _xZkqqHx_iCfDiBeEiNoNiPjM_xHqqkZx_1'_xZkqqHx_iCmGjCmHiJmB_xHqqkZx_2'_xZkqqHx_iCpAiNiHiCoNiClJiCmEiDfCiDhNiDjDiDgI_xHqqkZx_1'_xZkqqHx_iCpAiNoMiCoJiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkJiCfIiEkH_xHqqkZx_
	//  _xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_1' _xZkqqHx_iNoNiPjM_xHqqkZx_1'_xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkJiEjPiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_2'_xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_X2_xZkqqHx_iEkJ_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkH_xHqqkZx_
	//
	// _xZkqqHx_iDhMiDeDiDjDiDgHiCmNiBeBiCfBiCmMiNoNiPjMiCmMiDhNiBfLiDfHiCmFiCmNiNoNiPjM_xHqqkZx_1_xZkqqHx_iCkKjIeBjBlBiClHiCoJiCoGiCkEiCmJjHeEjAoGiClDiClJiCoJiClBiCmGiBeB_xHqqkZx_
	// _xZkqqHx_iCfCiCmMjCmHiJmBiCmMiDhNiBfLiDfHiCmFiCmNjCmHiJmB_xHqqkZx_2_xZkqqHx_iCkKjIeBjBlBiClHiCoJiCoGiCkEiCmJjHeEjAoGiClDiClJiCoJiClBiCmGiCmFiCkAiCoJiBeC_xHqqkZx_
	//
	//
	// _xZkqqHx_iBjMjFlGiOjKjChFiKlHiBhLjFlGiOjKjChFiKlH_xHqqkZx_ _xZkqqHx_iCmMiPoKiNiHiCfB_xHqqkZx_
	//
	//       _xZkqqHx_iEkBiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkC_xHqqkZx_
	// _xZkqqHx_iPpDjBnEiCfAiEkAiCgAiEkAiCgBiEkAiCgCiEkAiCgDiEkAiCgEiEkAiCgFiEkAiCgGiEkAiCgHiEkAiCgIiEkAiCgJiEkAiCgKiEkAiCgLiEkA_xHqqkZx_
	//       _xZkqqHx_iEkEiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkD_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkH_xHqqkZx_
	// _xZkqqHx_iDfCiDhNiDjDiDgIiCfA_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_1 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_1 _xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_X2_xZkqqHx_iEkJ_xHqqkZx_X3_xZkqqHx_iEkJ_xHqqkZx_X4_xZkqqHx_iEkH_xHqqkZx_
	//                             _xZkqqHx_iEkBiEjPiEkC_xHqqkZx_
	//                           _xZkqqHx_iEkBiEkD_xHqqkZx_  _xZkqqHx_iEkEiEkC_xHqqkZx_
	//                            _xZkqqHx_iBfP_xHqqkZx_    _xZkqqHx_iBfO_xHqqkZx_
	//                              _xZkqqHx_iBfPiBfO_xHqqkZx_
	//       _xZkqqHx_iEkBiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkC_xHqqkZx_
	// _xZkqqHx_iPpDjBnEiCfBiEkAiCgAiEkAiCgBiEkAiCgCiEkA_xHqqkZx_X1_xZkqqHx_iEkA_xHqqkZx_X2_xZkqqHx_iEkA_xHqqkZx_X3_xZkqqHx_iEkA_xHqqkZx_X4_xZkqqHx_iEkAiCgIiEkAiCgJiEkAiCgKiEkAiCgLiEkA_xHqqkZx_
	//       _xZkqqHx_iEkEiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkD_xHqqkZx_
	//                       _xZkqqHx_iEkFiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkH_xHqqkZx_
	//     _xZkqqHx_iDfCiDhNiDjDiDgIiCfB_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_2 _xZkqqHx_iEkFiEjPiEjPiEjPiEkH_xHqqkZx_
	//                 _xZkqqHx_jCmHiJmB_xHqqkZx_2 _xZkqqHx_iEkF_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkH_xHqqkZx_
	//                             _xZkqqHx_iEkBiEjPiEkC_xHqqkZx_
	//                           _xZkqqHx_iEkBiEkD_xHqqkZx_  _xZkqqHx_iEkEiEkC_xHqqkZx_
	//                            _xZkqqHx_iBfP_xHqqkZx_    _xZkqqHx_iBfO_xHqqkZx_
	//                              _xZkqqHx_iBfPiBfO_xHqqkZx_
	//       _xZkqqHx_iEkBiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkC_xHqqkZx_
	// _xZkqqHx_iPpDjBnEiCfCiEkAiCgAiEkAiCgBiEkAiCgCiEkA_xHqqkZx_X1_xZkqqHx_iEkA_xHqqkZx_Y1_xZkqqHx_iEkA_xHqqkZx_Y2_xZkqqHx_iEkA_xHqqkZx_Y3_xZkqqHx_iEkA_xHqqkZx_Y4_xZkqqHx_iEkA_xHqqkZx_Y5_xZkqqHx_iEkA_xHqqkZx_X4_xZkqqHx_iEkAiCgIiEkAiCgJiEkAiCgKiEkAiCgLiEkA_xHqqkZx_
	//       _xZkqqHx_iEkEiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkD_xHqqkZx_
	//
	// _xZkqqHx_iDfCiDhNiDjDiDgIiCfAiCmGiDfCiDhNiDjDiDgIiCfBiCpAiDhNiBfLiDfHiClFiBeBiCfAiDfCiDhNiDjDiDgIiCmFiPpDjBnEiCfAiCkJiCoHiPpDjBnEiCfCiCmJ_xHqqkZx_
	// _xZkqqHx_jFmPiNfIiCmFiCkLiCoJiCoGiCkEiCmJiClHiCoJiBeC_xHqqkZx_
	//
	//                   p1              p3  p2
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkH_xHqqkZx_
	// _xZkqqHx_iDfCiDhNiDjDiDgIiCfA_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_1 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_1 _xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_X2_xZkqqHx_iEkJ_xHqqkZx_X3_xZkqqHx_iEkJ_xHqqkZx_X4_xZkqqHx_iEkH_xHqqkZx_
	//                       _xZkqqHx_iEkFiEjPiCiBiEjPiEkH_xHqqkZx_
	//                       _xZkqqHx_iEkFiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkH_xHqqkZx_
	//     _xZkqqHx_iDfCiDhNiDjDiDgIiCfB_xHqqkZx_  _xZkqqHx_iNoNiPjM_xHqqkZx_2 _xZkqqHx_iEkFiEjPiEjPiEjPiEkH_xHqqkZx_
	//                 _xZkqqHx_jCmHiJmB_xHqqkZx_2 _xZkqqHx_iEkF_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkH_xHqqkZx_
	//                       r1      r3          r2
	//
	// _xZkqqHx_iCfAiBeEjCmHiJmB_xHqqkZx_1_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2_xZkqqHx_iCmMjAmP_xHqqkZx_(_xZkqqHx_iCiB_xHqqkZx_)_xZkqqHx_iCpAiOfKiPgPiBeC_xHqqkZx_
	//     _xZkqqHx_iCiBiCpAjCmHiJmB_xHqqkZx_1_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2_xZkqqHx_iCkJiCoHiPjMiKePiClFiCmEiBeBjCmHiJmB_xHqqkZx_1'_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2'_xZkqqHx_iCpAiOfKiPgPiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_1'_xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkH_xHqqkZx_      _xZkqqHx_iEkF_xHqqkZx_X4_xZkqqHx_iEkH_xHqqkZx_
	//                       _xZkqqHx_iEkFiEjPiCiBiEjPiEkH_xHqqkZx_
	//                 _xZkqqHx_iNoNiPjM_xHqqkZx_2'_xZkqqHx_iEkA_xHqqkZx_
	//
	// _xZkqqHx_iCfBiBeEiNoNiPjM_xHqqkZx_1_xZkqqHx_iCmGiNoNiPjM_xHqqkZx_2'_xZkqqHx_iCpAiDhNiBfLiDfHiClFiCmEiNoNiPjM_xHqqkZx_1'_xZkqqHx_iCpAiOfKiPgPiBeCiNoNiPjM_xHqqkZx_2'_xZkqqHx_iCmMiCkEiClPiBeB_xHqqkZx_
	//     _xZkqqHx_iNoNiPjM_xHqqkZx_1_xZkqqHx_iCmMjAoGjDkK_xHqqkZx_(p1)_xZkqqHx_iCoGiCoIjBePiCmJiCkAiCoJiCoAiCmMiCmNiBeBiClLiCmMiCnMiCnMiNoNiPjM_xHqqkZx_1_xZkqqHx_iCmMjBePiCmJjAnKjBlBiBeB_xHqqkZx_
	//     p1_xZkqqHx_iCoGiCoIiMoDiCmJiCkAiCoJiCoAiCmMiCmNiBeBiNoNiPjM_xHqqkZx_1_xZkqqHx_iCmMiMoD_xHqqkZx_(p2)_xZkqqHx_iCmJjCmHiJmBiClHiCoJiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkH_xHqqkZx_
	//             _xZkqqHx_iNoNiPjM_xHqqkZx_1'_xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
	//
	// _xZkqqHx_iCfCiBeEjCmHiJmB_xHqqkZx_1'_xZkqqHx_iCmGjCmHiJmB_xHqqkZx_2_xZkqqHx_iCpAiDhNiBfLiDfHiClFiCmEjCmHiJmB_xHqqkZx_2'_xZkqqHx_iCpAiOfKiPgPiBeCjCmHiJmB_xHqqkZx_1'_xZkqqHx_iCmMiCkEiClPiBeB_xHqqkZx_
	//     _xZkqqHx_jCmHiJmB_xHqqkZx_2_xZkqqHx_iCmMjAoGjDkK_xHqqkZx_(r1)_xZkqqHx_iCoGiCoIjBePiCmJiCkAiCoJiCoAiCmMiCmNiBeBiClLiCmMiCnMiCnMjCmHiJmB_xHqqkZx_2_xZkqqHx_iCmMjBePiCmJjAnKjBlBiBeB_xHqqkZx_
	//     r1_xZkqqHx_iCoGiCoIiMoDiCmJiCkAiCoJiCoAiCmMiCmNiBeBjCmHiJmB_xHqqkZx_2_xZkqqHx_iCmMiMoD_xHqqkZx_(r2)_xZkqqHx_iCmJjCmHiJmBiClHiCoJiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkJiCfIiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_2'_xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkJ_xHqqkZx_X4_xZkqqHx_iEkH_xHqqkZx_
	//
	// _xZkqqHx_iCfDiBeEiNoNiPjM_xHqqkZx_1'_xZkqqHx_iCmGjCmHiJmB_xHqqkZx_2'_xZkqqHx_iCpAiNiHiCoNiClJiCmEiDfCiDhNiDjDiDgI_xHqqkZx_1'_xZkqqHx_iCpAiNoMiCoJiBeC_xHqqkZx_
	//                   _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkJiCfHiEkJiCfIiEkH_xHqqkZx_
	//  _xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_1' _xZkqqHx_iNoNiPjM_xHqqkZx_1'_xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
	//             _xZkqqHx_jCmHiJmB_xHqqkZx_2'_xZkqqHx_iEkF_xHqqkZx_X1_xZkqqHx_iEkJ_xHqqkZx_Y1_xZkqqHx_iEkJ_xHqqkZx_Y2_xZkqqHx_iEkJ_xHqqkZx_Y3_xZkqqHx_iEkJ_xHqqkZx_Y4_xZkqqHx_iEkJ_xHqqkZx_Y5_xZkqqHx_iEkJ_xHqqkZx_X4_xZkqqHx_iEkH_xHqqkZx_
	//

	struct my
	{
		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	LinearOverlap
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	2_xZkqqHx_iCmCiCmMjEmNiImN_xHqqkZx_ [a, b) _xZkqqHx_iCmG_xHqqkZx_ [c, d) (_xZkqqHx_iBkG_xHqqkZx_ a <= b, c <= d) _xZkqqHx_iCmMiPgEiCmIiCoJjEmNiImNiCpA_xHqqkZx_
		 *			_xZkqqHx_iOfKiPgPiClHiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	p, q	:_xZkqqHx_iPgEiCmIiCoJjEmNiImN_xHqqkZx_[p, q) (p <= q) _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			a, b	:_xZkqqHx_jClCiCnHiCoJjEmNiImN_xHqqkZx_[a, b) (a <= b) _xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
		 *			c, d	:_xZkqqHx_jClCiCnHiCoJjEmNiImN_xHqqkZx_[c, d) (c <= d) _xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPgEiCmIiCoJiCkJiBeBjIeBjBlBiClHiCoJiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jHoBiCpAiOkGiClHiBeC_xHqqkZx_
		 *
		 *			-----------------------------------------------------
		 *			_xZkqqHx_iBjLiPgEiCmIiCoJjFjEjFkKiCkKjGlDiCkCiPoKiNiHiBeC_xHqqkZx_
		 *			a=3,b=7     _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkH_xHqqkZx_
		 *			c=8,d=11                        _xZkqqHx_iEkFiCfHiEkJiCfIiEkJ_xHqqkZx_10_xZkqqHx_iEkH_xHqqkZx_
		 *			FALSE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			-----------------------------------------------------
		 *			_xZkqqHx_iBjLiPgEiCmIiCoJjFjEjFkKiCkKjGlDiCkCiPoKiNiHiBeC_xHqqkZx_
		 *			a=8,b=11                        _xZkqqHx_iEkFiCfHiEkJiCfIiEkJ_xHqqkZx_10_xZkqqHx_iEkH_xHqqkZx_
		 *			c=3,d=7     _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkH_xHqqkZx_
		 *			FALSE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			-----------------------------------------------------
		 *			_xZkqqHx_iBjLiPgEiCmIiCoJjFjEjFkKiCmNjGlDiCkCiCkKiBeBjIeBjBlBiClFiCmEiCkCiCoJiPoKiNiHiBeC_xHqqkZx_
		 *			a=3,b=8     _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkH_xHqqkZx_
		 *			c=8,d=11                        _xZkqqHx_iEkFiCfHiEkJiCfIiEkJ_xHqqkZx_10_xZkqqHx_iEkH_xHqqkZx_
		 *			p = b, q = b, TRUE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			-----------------------------------------------------
		 *			_xZkqqHx_iBjLiPgEiCmIiCoJjFjEjFkKiCmNjGlDiCkCiCkKiBeBjIeBjBlBiClFiCmEiCkCiCoJiPoKiNiHiBeC_xHqqkZx_
		 *			a=8,b=11                        _xZkqqHx_iEkFiCfHiEkJiCfIiEkJ_xHqqkZx_10_xZkqqHx_iEkH_xHqqkZx_
		 *			c=3,d=8     _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkJiCfGiEkH_xHqqkZx_
		 *			p = d, q = d, TRUE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			-----------------------------------------------------
		 *			_xZkqqHx_iBjLiPgEiCmIiCoJjFjEjFkKiCkKiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		 *			a=3,b=7     _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkH_xHqqkZx_
		 *			c=4,d=6         _xZkqqHx_iEkFiCfDiEkJiCfEiEkH_xHqqkZx_
		 *			p = c, q = d, TRUE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			-----------------------------------------------------
		 *			_xZkqqHx_iBjLiPgEiCmIiCoJjFjEjFkKiCkKiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		 *			a=6,b=9                 _xZkqqHx_iEkFiCfFiEkJiCfGiEkJiCfHiEkH_xHqqkZx_
		 *			c=3,d=7     _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkH_xHqqkZx_
		 *			p = a, q = d, TRUE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			-----------------------------------------------------
		 *			_xZkqqHx_iBjLiPgEiCmIiCoJjFjEjFkKiCkKiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		 *			a=6,b=6                 _xZkqqHx_iEkA_xHqqkZx_
		 *			c=3,d=7     _xZkqqHx_iEkFiCfCiEkJiCfDiEkJiCfEiEkJiCfFiEkH_xHqqkZx_
		 *			p = a, q = b, TRUE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
		 *			-----------------------------------------------------
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static BOOL LinearOverlap (long& p, long& q, long a, long b, long c, long d)
		{
			if (b < c || d < a) return FALSE;
			if (b == c)
			{
				p = b;
				q = b;
				return TRUE;
			}
			if (d == a)
			{
				p = d;
				q = d;
				return TRUE;
			}
			p = a < c ? c : a;
			q = b < d ? b : d;
			return TRUE;
		} // LinearOverlap.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	ReadCmdDeleteThinLine
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	FDECMD_DELETE_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pQueue	:_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjDmHiCnNiPgPiClHiDeMiDiFiBfLiCpAiOhHjCoIiBeCiOjPiCmMiDfCiDhNiDjDiDgIiCmJ_xHqqkZx_
		 *					 _xZkqqHx_iInKjDkOiClFiCmEjFnEiClHiBeC_xHqqkZx_
		 *			lLnIndex:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
		 *			eLine	:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiPoOjFpBiCpAjFnEiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	pQueue_xZkqqHx_iCmNiDfCiDhNiDjDiDgIiImKjChFiCmJiDhMiDeDiDjDiDfOiCkKiCkAiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static void ReadCmdDeleteThinLine (	const BYTE*& pQueue,
											long& lLnIndex,
											FCEditLine& eLine,
											BOOL bIsFlatText)
		{
			// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
			pQueue++;
			// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lLnIndex = ReadVSizeU(pQueue);
			eLine.InLinChrStream(pQueue);
			// _xZkqqHx_iDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCmMiPoKiNiHiCmNiBeBiNhDiPoOjFpBiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
			if (bIsFlatText) eLine.Clear();
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjBjHiCoJiBeC_xHqqkZx_
			ReadVSizeU(pQueue);
		} // ReadCmdDeleteThinLine.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	ReadCmdDeleteThinLine
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	FDECMD_INSERT_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pQueue	:_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjDmHiCnNiPgPiClHiDeMiDiFiBfLiCpAiOhHjCoIiBeCiOjPiCmMiDfCiDhNiDjDiDgIiCmJ_xHqqkZx_
		 *					 _xZkqqHx_iInKjDkOiClFiCmEjFnEiClHiBeC_xHqqkZx_
		 *			lLnIndex:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
		 *			eLine	:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiPoOjFpBiCpAjFnEiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	pQueue_xZkqqHx_iCmNiDfCiDhNiDjDiDgIiImKjChFiCmJiDhMiDeDiDjDiDfOiCkKiCkAiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static void ReadCmdInsertThinLine (	const BYTE*& pQueue,
											long& lLnIndex,
											FCEditLine& eLine,
											BOOL bIsFlatText)
		{
			// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
			pQueue++;
			// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lLnIndex = ReadVSizeU(pQueue);
			eLine.InLinChrStream(pQueue);
			// _xZkqqHx_iDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCmMiPoKiNiHiCmNiBeBiNhDiPoOjFpBiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
			if (bIsFlatText) eLine.Clear();
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjBjHiCoJiBeC_xHqqkZx_
			ReadVSizeU(pQueue);
		} // ReadCmdInsertThinLine.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	ReadCmdReplaceChars
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	FDECMD_REPLACE_CHARS_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pQueue	:_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjDmHiCnNiPgPiClHiDeMiDiFiBfLiCpAiOhHjCoIiBeCiOjPiCmMiDfCiDhNiDjDiDgIiCmJ_xHqqkZx_
		 *					 _xZkqqHx_iInKjDkOiClFiCmEjFnEiClHiBeC_xHqqkZx_
		 *			mpDelete:_xZkqqHx_iNoNiPjMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAjFnEiClHiBeC_xHqqkZx_
		 *			mpInsert:_xZkqqHx_jBhNjDpMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAjFnEiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	pQueue_xZkqqHx_iCmNiDfCiDhNiDjDiDgIiImKjChFiCmJiDhMiDeDiDjDiDfOiCkKiCkAiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static void ReadCmdReplaceChars (	const BYTE*& pQueue,
											map<long, FCEditChar>& mpDelete,
											map<long, FCEditChar>& mpInsert,
											BOOL bIsFlatChar)
		{
			// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
			pQueue++;
			// _xZkqqHx_jDpMiCoKjBnGiCkGiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lIdxFrom = ReadVSizeU(pQueue);
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lDelCount = ReadVSizeU(pQueue);
			long lIdx;
			for (lIdx = lIdxFrom; lIdx != lIdxFrom + lDelCount; lIdx++)
			{
				FCEditChar eChar;
				eChar.InStream(pQueue);
				// _xZkqqHx_iDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCmMiPoKiNiHiCmNiBeBiPoOjFpBiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
				if (bIsFlatChar)
				{
					const WORD wChar = eChar.m_wChar;
					eChar.Clear();
					eChar.m_wChar = wChar;
				}
				mpDelete[lIdx] = eChar;
			}
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lInsCount = ReadVSizeU(pQueue);
			for (lIdx = lIdxFrom; lIdx != lIdxFrom + lInsCount; lIdx++)
			{
				FCEditChar eChar;
				eChar.InStream(pQueue);
				// _xZkqqHx_iDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCmMiPoKiNiHiCmNiBeBiPoOjFpBiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
				if (bIsFlatChar)
				{
					const WORD wChar = eChar.m_wChar;
					eChar.Clear();
					eChar.m_wChar = wChar;
				}
				mpInsert[lIdx] = eChar;
			}
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjBjHiCoJiBeC_xHqqkZx_
			ReadVSizeU(pQueue);
		} // ReadCmdReplaceChars.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	WriteCmdDeleteThinLine
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	FDECMD_DELETE_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgIiCpAiPjBiCkLiNjOiCnOiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pQueue	:_xZkqqHx_iDfCiDhNiDjDiDgIiCpAiPjBiCkLiNjOiCnOiDeMiDiFiBfLiCpAiOhHjCoIiBeCiOjPiCmMiDfCiDhNiDjDiDgIiCmJ_xHqqkZx_
		 *					 _xZkqqHx_iInKjDkOiClFiCmEjFnEiClHiBeC_xHqqkZx_
		 *			lLnIndex:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			eLine	:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static void WriteCmdDeleteThinLine (BYTE*& pQueue,
											const long& lLnIndex,
											const FCEditLine& eLine)
		{
			BYTEVector vBuff;
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
			vBuff << BYTE(FDECMD_DELETE_THIN_LINE);
			// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
			WriteVSizeU(vBuff, lLnIndex);
			// _xZkqqHx_iNhDiPoOjFpBiCpAiPgPjHmNiBeC_xHqqkZx_
			eLine.OutLinChrStream(vBuff);
			// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
			const long lCmdSize = vBuff.size();
			InsertVSizeU(vBuff, 0, lCmdSize);
			WriteVSizeU(vBuff, lCmdSize);
			memcpy(pQueue, &vBuff[0], vBuff.size());
			pQueue += vBuff.size();
		} // WriteCmdDeleteThinLine.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	WriteCmdInsertThinLine
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	FDECMD_INSERT_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgIiCpAiPjBiCkLiNjOiCnOiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pQueue	:_xZkqqHx_iDfCiDhNiDjDiDgIiCpAiPjBiCkLiNjOiCnOiDeMiDiFiBfLiCpAiOhHjCoIiBeCiOjPiCmMiDfCiDhNiDjDiDgIiCmJ_xHqqkZx_
		 *					 _xZkqqHx_iInKjDkOiClFiCmEjFnEiClHiBeC_xHqqkZx_
		 *			lLnIndex:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			eLine	:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static void WriteCmdInsertThinLine (BYTE*& pQueue,
											const long& lLnIndex,
											const FCEditLine& eLine)
		{
			BYTEVector vBuff;
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
			vBuff << BYTE(FDECMD_INSERT_THIN_LINE);
			// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
			WriteVSizeU(vBuff, lLnIndex);
			// _xZkqqHx_iNhDiPoOjFpBiCpAiPgPjHmNiBeC_xHqqkZx_
			eLine.OutLinChrStream(vBuff);
			// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
			const long lCmdSize = vBuff.size();
			InsertVSizeU(vBuff, 0, lCmdSize);
			WriteVSizeU(vBuff, lCmdSize);
			memcpy(pQueue, &vBuff[0], vBuff.size());
			pQueue += vBuff.size();
		} // WriteCmdInsertThinLine.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	WriteCmdReplaceChars
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	FDECMD_REPLACE_CHARS_xZkqqHx_iDfCiDhNiDjDiDgIiCpAiPjBiCkLiNjOiCnOiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pQueue	:_xZkqqHx_iDfCiDhNiDjDiDgIiCpAiPjBiCkLiNjOiCnOiDeMiDiFiBfLiCpAiOhHjCoIiBeCiOjPiCmMiDfCiDhNiDjDiDgIiCmJ_xHqqkZx_
		 *					 _xZkqqHx_iInKjDkOiClFiCmEjFnEiClHiBeC_xHqqkZx_
		 *			mpDelete:_xZkqqHx_iNoNiPjMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			mpInsert:_xZkqqHx_jBhNjDpMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static void WriteCmdReplaceChars (	BYTE*& pQueue,
											const map<long, FCEditChar>& mpDelete,
											const map<long, FCEditChar>& mpInsert)
		{
			long lIdxFrom = mpDelete.empty() ? mpInsert.begin()->first : mpDelete.begin()->first;
			BYTEVector vBuff;
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
			vBuff << BYTE(FDECMD_REPLACE_CHARS);
			// _xZkqqHx_jDpMiCoKjBnGiCkGiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
			WriteVSizeU(vBuff, lIdxFrom);
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAiLeMjIfOiBeC_xHqqkZx_
			WriteVSizeU(vBuff, mpDelete.size());
			map<long, FCEditChar>::const_iterator i;
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjHpBiCpAiLeMjIfOiBeC_xHqqkZx_
			for (i = mpDelete.begin(); i != mpDelete.end(); i++)
				i->second.OutStream(vBuff);
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAiLeMjIfOiBeC_xHqqkZx_
			WriteVSizeU(vBuff, mpInsert.size());
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjHpBiCpAiLeMjIfOiBeC_xHqqkZx_
			for (i = mpInsert.begin(); i != mpInsert.end(); i++)
				i->second.OutStream(vBuff);
			// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
			const long lCmdSize = vBuff.size();
			InsertVSizeU(vBuff, 0, lCmdSize);
			WriteVSizeU(vBuff, lCmdSize);
			memcpy(pQueue, &vBuff[0], vBuff.size());
			pQueue += vBuff.size();
		} // WriteCmdReplaceChars.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	OptimizeCmdReplaceChars
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jCfAjDmGiCmM_xHqqkZx_ FDECMD_REPLACE_CHARS_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iCpAiPgLiPkMiClHiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mpDelete	:_xZkqqHx_iNoNiPjMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeCiPgLiPkMiClFiClNjCgMiCpAjFnEiClHiBeC_xHqqkZx_
		 *			mpInsert	:_xZkqqHx_jBhNjDpMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeCiPgLiPkMiClFiClNjCgMiCpAjFnEiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPgLiPkMiCmFiCkLiClNiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iJlKiCmJiPgLiPkMiCmMjHoBiCpAiOkGiClHiBeC_xHqqkZx_
		 *
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgCiEkAiCgDiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgCiEkAiCgDiEkAiCgEiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                          _xZkqqHx_iBkL_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   
		 *               _xZkqqHx_jCmHiJmB_xHqqkZx_
		 *          ----------------------------------------
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgCiEkAiCgDiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgCiEkAiCgDiEkAiCgFiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                          _xZkqqHx_iBkL_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgFiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkI_xHqqkZx_
		 *          ----------------------------------------
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgCiEkAiCgDiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                          _xZkqqHx_iBkL_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgCiEkAiCgDiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   
		 *               _xZkqqHx_jCmHiJmB_xHqqkZx_
		 *                   
		 *          ----------------------------------------
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgCiEkAiCgDiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgAiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                          _xZkqqHx_iBkL_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgCiEkAiCgDiEkAiCgEiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgAiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkI_xHqqkZx_
		 *          ----------------------------------------
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_iNoNiPjMiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgCiEkAiCgDiEkAiCgEiEkAiCgFiEkAiCgGiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *                          _xZkqqHx_iBkL_xHqqkZx_
		 *                   
		 *               _xZkqqHx_iNoNiPjM_xHqqkZx_
		 *                   
		 *                   _xZkqqHx_iEkGiEjPiEkGiEjPiEkG_xHqqkZx_
		 *               _xZkqqHx_jCmHiJmBiEkAiCgCiEkAiCgDiEkA_xHqqkZx_
		 *                   _xZkqqHx_iEkIiEjPiEkIiEjPiEkI_xHqqkZx_
		 *          ----------------------------------------
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.28 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static BOOL OptimizeCmdReplaceChars (	map<long, FCEditChar>& mpDelete,
												map<long, FCEditChar>& mpInsert)
		{
			BOOL bReduced = FALSE;
			map<long, FCEditChar>::iterator iDel;
			map<long, FCEditChar>::iterator iIns;
			while (!mpDelete.empty() && !mpInsert.empty())
			{
				iDel = mpDelete.begin();
				iIns = mpInsert.begin();
				if (iDel->second == iIns->second)
				{
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//					map<long, FCEditChar>::iterator i1;
//					map<long, FCEditChar>::iterator i2;
//					for (i1 = mpDelete.begin(); i1 != mpDelete.end(); i1++)
//						TRACE(_T("%d %x | "), i1->first, i1->second.m_wChar);
//					TRACE(_T("\n"));
//					for (i2 = mpInsert.begin(); i2 != mpInsert.end(); i2++)
//						TRACE(_T("%d %x | "), i2->first, i2->second.m_wChar);
//					TRACE(_T("\n"));
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
					bReduced = TRUE;
					mpDelete.erase(iDel);
					mpInsert.erase(iIns);
				} else
				{
					break;
				}
			}
			while (!mpDelete.empty() && !mpInsert.empty())
			{
				iDel = mpDelete.end();
				iIns = mpInsert.end();
				iDel--;
				iIns--;
				if (iDel->second == iIns->second)
				{
					bReduced = TRUE;
					mpDelete.erase(iDel);
					mpInsert.erase(iIns);
				} else
				{
					break;
				}
			}
			return bReduced;
		} // OptimizeCmdReplaceChars.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	MergeCmdDeleteInsertLine
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jHnHiCoIiNiHiCkE_xHqqkZx_ FDECMD_DELETE_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iCmG_xHqqkZx_
		 *			FDECMD_INSERT_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjBiKiOeFiClHiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLnIndexPrev:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			eLinePrev	:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			lLnIndexNew	:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			eLineNew	:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jBiKiOeFiCmFiCkLiClNiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static BOOL MergeCmdDeleteInsertLine (	long lLnIndexPrev,
												const FCEditLine& eLinePrev,
											 	long lLnIndexNew,
												const FCEditLine& eLineNew)
		{
			if (lLnIndexPrev == lLnIndexNew &&
				eLinePrev == eLineNew &&
				eLinePrev.m_vEditChar[0] == eLineNew.m_vEditChar[0])
				return TRUE;
			return FALSE;
		} // MergeCmdDeleteInsertLine.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	MergeCmdInsertDeleteLine
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jHnHiCoIiNiHiCkE_xHqqkZx_ FDECMD_INSERT_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iCmG_xHqqkZx_
		 *			FDECMD_DELETE_THIN_LINE_xZkqqHx_iDfCiDhNiDjDiDgIiCpAjBiKiOeFiClHiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLnIndexPrev:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			eLinePrev	:_xZkqqHx_jBhNjDpMiClDiCoKiClNiNhDiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			lLnIndexNew	:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
		 *			eLineNew	:_xZkqqHx_iNoNiPjMiClDiCoKiClNiNhDiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jBiKiOeFiCmFiCkLiClNiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static BOOL MergeCmdInsertDeleteLine (	long lLnIndexPrev,
												const FCEditLine& eLinePrev,
											 	long lLnIndexNew,
												const FCEditLine& eLineNew)
		{
			if (lLnIndexPrev == lLnIndexNew)
				return TRUE;
			return FALSE;
		} // MergeCmdInsertDeleteLine.

		/*************************************************************************
		 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	MergeCmdReplaceChars
		 *
		 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jIeBjBlBiClFiClN_xHqqkZx_ FDECMD_REPLACE_CHARS_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iCpAiIoKiCmCiCmM_xHqqkZx_
		 *			FDECMD_REPLACE_CHARS_xZkqqHx_iDfCiDhNiDjDiDgIiCmJiDhNiBfLiDfHiClHiCoJiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mpDelete1	:_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_1_xZkqqHx_iCmMiNoNiPjMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeCiDhNiBfLiDfHiClFiClN_xHqqkZx_
		 *						 _xZkqqHx_jCgMiCpAjFnEiClHiBeC_xHqqkZx_
		 *			mpInsert1	:_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_1_xZkqqHx_iCmMjBhNjDpMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeCiDhNiBfLiDfHiClFiClN_xHqqkZx_
		 *						 _xZkqqHx_jCgMiCpAjFnEiClHiBeC_xHqqkZx_
		 *			mpDelete2	:_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_2_xZkqqHx_iCmMiNoNiPjMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeCiDeOiDiKiDeBiClFiCmE_xHqqkZx_
		 *						 _xZkqqHx_jFnEiClHiBeC_xHqqkZx_
		 *			mpInsert2	:_xZkqqHx_iDfCiDhNiDjDiDgI_xHqqkZx_2_xZkqqHx_iCmMjBhNjDpMiClDiCoKiClNjFlGiOjKiPoOjFpBiCpAiOhHjCoIiBeCiDeOiDiKiDeBiClFiCmE_xHqqkZx_
		 *						 _xZkqqHx_jFnEiClHiBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDhNiBfLiDfHiCmFiCkLiClNiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
		 *
		 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
		 *************************************************************************/
		static BOOL MergeCmdReplaceChars (	map<long, FCEditChar>& mpDelete1,
											map<long, FCEditChar>& mpInsert1,
											map<long, FCEditChar>& mpDelete2,
											map<long, FCEditChar>& mpInsert2)
		{
			long p1 = mpDelete1.empty() ? mpInsert1.begin()->first : mpDelete1.begin()->first;
			long r1 = mpDelete2.empty() ? mpInsert2.begin()->first : mpDelete2.begin()->first;

			// mpInsert1 _xZkqqHx_iCmG_xHqqkZx_ mpDelete2 _xZkqqHx_iCkKiMpAiNlHiClFiCmEiCkCiCoJiCkJjClCiCnHiCoJiCmMiClOiCkKiBeB_xHqqkZx_
			// _xZkqqHx_iClBiClBiCmFjCiNiInDiCkKjFeLjHhGiCmIiCmMiCmNiBeB_xHqqkZx_mpInsert1 _xZkqqHx_iCmG_xHqqkZx_ mpDelete2 _xZkqqHx_iCmNiNmFiMoDiCmJ_xHqqkZx_ _xZkqqHx_iJpMiNhD_xHqqkZx_'\n'_xZkqqHx_iCkK_xHqqkZx_
			// _xZkqqHx_iKnMiCnMiCoKiCmEiCkCiCoJiJmCjEfMjAkLiCkKiCkAiCoJiClBiCmGiCmFiCkAiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jHoBiCkGiCmO_xHqqkZx_ mpInsert1 _xZkqqHx_iCkK_xHqqkZx_ 3_xZkqqHx_iNhDjGnKiMoDjElMiCmMjCmHiJmBiCmF_xHqqkZx_ mpDelete2 _xZkqqHx_iCkK_xHqqkZx_ 4_xZkqqHx_iNhDjGnKjBePjElMiCmMiNoNiPjMiCmMiPoKiNiHiBeB_xHqqkZx_
			// mpInsert1 _xZkqqHx_iCmMiNmFiMoDiCmJiJpMiNhDiCkKiKnMiCnMiCoKiCmEiCkCiCoKiCmOiBeB_xHqqkZx_mpInsert1 _xZkqqHx_iCmG_xHqqkZx_ mpDelete2 _xZkqqHx_iCmN_xHqqkZx_
			// _xZkqqHx_jAnKiClFiCmEiCkCiCoJiCmMiCmF_xHqqkZx_ LinearOverlap_xZkqqHx_iKnGjAjEiCmF_xHqqkZx_ _xZkqqHx_iMpAiNlHiClFiCmEiCkCiCoJiCmGjElLjCgGiClDiCoKiCoJiBeC_xHqqkZx_
			// _xZkqqHx_iClFiCkJiClFiBeBiInJiCmIiCoJiNhDiCmMjCmHiJmBiCmGiNoNiPjMiCpAiDhNiBfLiDfHiClFiCmEiClFiCnMiCkEiCmGiBeBiJpMiNhDiCpAjDhCjCiGiCmJiKnMiCnO_xHqqkZx_
			// _xZkqqHx_jChFiKlHjBiAiNoMiCmGiCmIiCmBiCmEiClFiCnMiCkCiBeBiDeHiDiJiBfLiCkKjEkNjAlGiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_iClBiCoKiCpAjGgIiCkOiClNiCnPiBeB_xHqqkZx_LinearOverlap_xZkqqHx_iKnGjAjEiCmFiMpAiNlHiCpAjClCiCnHiCoJiNnLiCmNiBeBiJpMiNhDiCpAiPjMiCkCiClN_xHqqkZx_
			// _xZkqqHx_jFjEjFkKiCmFiCmMiMpAiNlHiCpAiCnMiClIjClCiCnHiCoJiBeCiClBiCoKiCmFiMpAiNlHiClFiCmEiCkCiCoJiCmGjElLjCgGiClDiCoKiCoKiCmOiBeB_xHqqkZx_
			// _xZkqqHx_iCfAiCmGiCfBiCmNjDkPiClGiNhDiCmMjChFiKlHiPiIjHjNiCmIiCmMiCmF_xHqqkZx_ _xZkqqHx_iJpMiNhDiCpAiKnMiCnPiClNjFlGiOjKjHpBiCmMiDhNiBfLiDfHiPiIjHjNiCpA_xHqqkZx_
			// _xZkqqHx_iClFiCmEiCoAjGoCjBoIiCmIiCkCiBeC_xHqqkZx_

			// _xZkqqHx_iCnMiClIiJpMiNhDiCpAiPjMiCkCiClNjEmNiImN_xHqqkZx_(p1_xZkqqHx_iBgA_xHqqkZx_p3,r1_xZkqqHx_iBgA_xHqqkZx_r3)_xZkqqHx_iCpAiOfKiPgPiBeC_xHqqkZx_
			long p3 = p1 + mpInsert1.size();
			long r3 = r1 + mpDelete2.size();
			if (!mpInsert1.empty() &&
				mpInsert1.rbegin()->second.m_wChar == FDRCH_RETURN)
				p3--;
			if (!mpDelete2.empty() &&
				mpDelete2.rbegin()->second.m_wChar == FDRCH_RETURN)
				p3--;
			// _xZkqqHx_iJpMiNhDiCpAiPjMiCkCiClNjEmNiImNiCkKiMpAiNlHiClFiCmEiCkCiCoJiCkJjClCiCnHiCoJiBeC_xHqqkZx_
			// LinearOverlap _xZkqqHx_iCmNiBeB_xHqqkZx_FFIntersect _xZkqqHx_iCpAiOgHiCkEiCoGiCoIiMpIjHkGiCkKiCkCiCkCiBeC_xHqqkZx_
			long a0, a1;	// _xZkqqHx_iPgEiCmIiCoJjEmNiImNiBeCiCiBiCmMiNmFiPiJiCmGiNmFiMoDiBeC_xHqqkZx_
			if (!my::LinearOverlap(a0, a1, p1, p3, r1, r3))
				return FALSE;
			// _xZkqqHx_iJpMiNhDiCpAiPjMiCkCiCmEiCoAiMpAiNlHiClFiCmEiCkCiCoJiCmGjElLiCmBiClNiCmMiCmFiBeBiJpMiNhDiCpAjFhEiCkPiCmE_xHqqkZx_
			// _xZkqqHx_iCiBiCmMjEmNiImN_xHqqkZx_(a0_xZkqqHx_iBgA_xHqqkZx_a1)_xZkqqHx_iCpAiOfKiPgPiClHiCoJiBeC_xHqqkZx_
			p3 = p1 + mpInsert1.size();
			r3 = r1 + mpDelete2.size();
			my::LinearOverlap(a0, a1, p1, p3, r1, r3);
			long p2 = p1 + mpDelete1.size();
			long r2 = r1 + mpInsert2.size();
			mpInsert1.erase(mpInsert1.find(a0), mpInsert1.find(a1));
			mpDelete2.erase(mpDelete2.find(a0), mpDelete2.find(a1));
			map<long, FCEditChar>::const_iterator i;
			for (i = mpDelete2.begin(); i != mpDelete2.end(); i++)
			{
				if (i->first < p1)
					mpDelete1[i->first] = i->second;
				else
					mpDelete1[p2++] = i->second;
			}
			for (i = mpInsert1.begin(); i != mpInsert1.end(); i++)
			{
				if (i->first < r1)
					mpInsert2[i->first] = i->second;
				else
					mpInsert2[r2++] = i->second;
			}
			mpInsert1 = mpInsert2;
			mpDelete2.clear();
			mpInsert2.clear();
			return TRUE;
		} // MergeCmdReplaceChars.
	}; // struct my.

	// _xZkqqHx_iDeMiDiFiBfLiCkKiLpDiCmIiCoHiCmOiJlNiCoAiClJiClIjFjMiLeBiBeC_xHqqkZx_
	if (byvQueue.empty()) return;

	// _xZkqqHx_iNmFjDeLiJlLiCmFjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
	BOOL bUpdated;
	do
	{
		// _xZkqqHx_iNmFjDeLiJlLiCmFjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
		bUpdated = FALSE;
		// _xZkqqHx_iDeMiDiFiBfLiCkJiCoHiDfCiDhNiDjDiDgIiCpAjDmHiCnNiPgPiClHiImKjChFiBeC_xHqqkZx_
		const BYTE* pReadQueue = &byvQueue[0];
		// _xZkqqHx_iDeMiDiFiBfLiPeJjCfLiBeC_xHqqkZx_
		const BYTE* pReadQueueEnd = pReadQueue + byvQueue.size();
		// _xZkqqHx_iDeMiDiFiBfLiCmJiDfCiDhNiDjDiDgIiCpAiPjBiCkLiNjOiCnOiImKjChFiBeC_xHqqkZx_
		BYTE* pWriteQueue = &byvQueue[0];

		// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
		BYTE byCmdPrev = FDECMD_NONE;
		map<long, FCEditChar> mpDeletePrev;
		map<long, FCEditChar> mpInsertPrev;
		long lLnIndexPrev;
		FCEditLine eLinePrev;
		while (pReadQueue != pReadQueueEnd)
		{
			// _xZkqqHx_iDfCiDhNiDjDiDgIjAoGjDkKiImKjChFiCpAiLeMiJkPiBeC_xHqqkZx_
			const BYTE* pCmdTop = pReadQueue;
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			const DWORD dwSizeBn = ReadVSizeU(pReadQueue);
			// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCmNiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
			if (dwSizeBn == 0) continue;
			// _xZkqqHx_iDfCiDhNiDjDiDgIjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
			BYTE byCmdNew = *pReadQueue;

			BYTEVector vCmdBuffNew;
			map<long, FCEditChar> mpDeleteNew;
			map<long, FCEditChar> mpInsertNew;
			long lLnIndexNew;
			FCEditLine eLineNew;

			//----- _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----

			switch (byCmdNew)
			{
			case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				// _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjFkBiOmKiClHiCoJiBeC_xHqqkZx_
				pReadQueue += dwSizeBn;
				// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjBjHiCoJiBeC_xHqqkZx_
				ReadVSizeU(pReadQueue);
				if (bIsFlatText)
				//----- _xZkqqHx_iDhEiDiJiDgCiDgHiDgFiDeMiDfIiDgHiCmMiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_jDmHiCnNiNjOiCpBiClOiDfCiDhNiDjDiDgIiCmNjGlDiMpIiCmJiBeC_xHqqkZx_
					byCmdNew = FDECMD_NONE;
					// _xZkqqHx_iNmFjDeLiJlLiCmFjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
					bUpdated = TRUE;
				} else
				//----- _xZkqqHx_iDiKiDgCiDgAiDgFiDeMiDfIiDgHiCmMiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiKnLiClCiCmGiBgJjBePiMoDiDfEiDeDiDfJiCoAiKnMiCnOiBgKiDgPiDgCiDhEiDeAiCmJjFkBiOmKiBeC_xHqqkZx_
					const long lCmdSize = pReadQueue - pCmdTop;
					vCmdBuffNew.resize(lCmdSize);
					memcpy(&vCmdBuffNew[0], pCmdTop, lCmdSize);
				}
				break;
			case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				// _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjFkBiOmKiClHiCoJiBeC_xHqqkZx_
				pReadQueue += dwSizeBn;
				// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjBjHiCoJiBeC_xHqqkZx_
				ReadVSizeU(pReadQueue);
				if (bIsFlatChar)
				//----- _xZkqqHx_iDhEiDiJiDgCiDgHiDeMiDiDiDiJiDeOiDfOiCmMiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_jDmHiCnNiNjOiCpBiClOiDfCiDhNiDjDiDgIiCmNjGlDiMpIiCmJiBeC_xHqqkZx_
					byCmdNew = FDECMD_NONE;
					// _xZkqqHx_iNmFjDeLiJlLiCmFjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
					bUpdated = TRUE;
				} else
				//----- _xZkqqHx_iDiKiDgCiDgAiDeMiDiDiDiJiDeOiDfOiCmMiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiKnLiClCiCmGiBgJjBePiMoDiDfEiDeDiDfJiCoAiKnMiCnOiBgKiDgPiDgCiDhEiDeAiCmJjFkBiOmKiBeC_xHqqkZx_
					const long lCmdSize = pReadQueue - pCmdTop;
					vCmdBuffNew.resize(lCmdSize);
					memcpy(&vCmdBuffNew[0], pCmdTop, lCmdSize);
				}
				break;
			case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
				my::ReadCmdDeleteThinLine(pReadQueue, lLnIndexNew, eLineNew, bIsFlatText);
				break;
			case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
				my::ReadCmdInsertThinLine(pReadQueue, lLnIndexNew, eLineNew, bIsFlatText);
				break;
			case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
				my::ReadCmdReplaceChars(pReadQueue, mpDeleteNew, mpInsertNew, bIsFlatChar);
				break;
			}

			//----- _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAiNmFjDeLiJlL_xHqqkZx_ -----

			switch (byCmdNew)
			{
			case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
			case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
				break;
			case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
				if (my::OptimizeCmdReplaceChars(mpDeleteNew, mpInsertNew))
				{
					bUpdated = TRUE;	// _xZkqqHx_iNmFjDeLiJlLiCmFjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
					// _xZkqqHx_iNmFjDeLiJlLiCmMiMiLiJmKiBeBiDfCiDhNiDjDiDgIiCkKiLpDiCmJiCmIiCmBiClNiCoH_xHqqkZx_FDECMD_NONE_xZkqqHx_iCpAjAnNjCoIiBeC_xHqqkZx_
					if (mpDeleteNew.empty() && mpInsertNew.empty())
						byCmdNew = FDECMD_NONE;
				}
				break;
			}

			//----- _xZkqqHx_jBePiJpBiDfCiDhNiDjDiDgIiCmGiNkBiJpBiDfCiDhNiDjDiDgIiCmMiDhNiBfLiDfHiCpAiOiOiCnNiCoJ_xHqqkZx_ -----

			// _xZkqqHx_iDfCiDhNiDjDiDgIiCkKiDhNiBfLiDfHiClDiCoKiClNiCkJiBeI_xHqqkZx_
			BOOL bCmdMerged = FALSE;
			switch (byCmdPrev)
			{
			case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				break;
			case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
				if (byCmdNew == FDECMD_INSERT_THIN_LINE &&
					my::MergeCmdDeleteInsertLine(	lLnIndexPrev, eLinePrev,
										 			lLnIndexNew, eLineNew))
				//-----Intersect_xZkqqHx_iClFiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_iDfCiDhNiDjDiDgIiCkKiDhNiBfLiDfHiClDiCoKiClNiCkJiBeI_xHqqkZx_
					bCmdMerged = TRUE;
					// _xZkqqHx_iDhNiBfLiDfHiCmMiMiLiJmKiBeB_xHqqkZx_FDECMD_DELETE_THIN_LINE _xZkqqHx_iCmG_xHqqkZx_ FDECMD_INSERT_THIN_LINE _xZkqqHx_iCmN_xHqqkZx_
					// _xZkqqHx_jBiKiOeFiClDiCoKiCoJiCmMiCmFiBeBiLeMjIfOiCpAiOgDiClDiCmIiCkCiBeC_xHqqkZx_
					byCmdPrev = FDECMD_NONE;
				}
				break;
			case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
				if (byCmdNew == FDECMD_DELETE_THIN_LINE &&
					my::MergeCmdInsertDeleteLine(	lLnIndexPrev, eLinePrev,
												 	lLnIndexNew, eLineNew))
				//-----Intersect_xZkqqHx_iClFiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_iDfCiDhNiDjDiDgIiCkKiDhNiBfLiDfHiClDiCoKiClNiCkJiBeI_xHqqkZx_
					bCmdMerged = TRUE;
					// _xZkqqHx_iDhNiBfLiDfHiCmMiMiLiJmKiBeB_xHqqkZx_FDECMD_INSERT_THIN_LINE _xZkqqHx_iCmG_xHqqkZx_ FDECMD_DELETE_THIN_LINE _xZkqqHx_iCmN_xHqqkZx_
					// _xZkqqHx_jBiKiOeFiClDiCoKiCoJiCmMiCmFiBeBiLeMjIfOiCpAiOgDiClDiCmIiCkCiBeC_xHqqkZx_
					byCmdPrev = FDECMD_NONE;
				}
				break;
			case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
				if (byCmdNew == FDECMD_REPLACE_CHARS &&
					my::MergeCmdReplaceChars(mpDeletePrev,
										 	 mpInsertPrev,
										 	 mpDeleteNew,
										 	 mpInsertNew))
				//-----Intersect_xZkqqHx_iClFiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_iDfCiDhNiDjDiDgIiCkKiDhNiBfLiDfHiClDiCoKiClNiCkJiBeI_xHqqkZx_
					bCmdMerged = TRUE;
					// _xZkqqHx_iDhNiBfLiDfHiMiLiJmKiBeB_xHqqkZx_mpDeletePrev_xZkqqHx_iCmG_xHqqkZx_mpInsertPrev_xZkqqHx_iCkKjDjJiClFiCkNiCmIiCmBiClNiPoKiNiH_xHqqkZx_
					// (_xZkqqHx_jHlMjFpLiLpDiCmJiCmIiCoJiPoKiNiHiCoAiKnMiCnO_xHqqkZx_)_xZkqqHx_iCmNiBeBjBePiJpBiDfCiDhNiDjDiDgIiCoA_xHqqkZx_ FDECMD_NONE_xZkqqHx_iCmJiBeC_xHqqkZx_
					if (mpDeletePrev == mpInsertPrev)
						byCmdPrev = FDECMD_NONE;
				}
				break;
			}
			if (bCmdMerged)
			//----- _xZkqqHx_iDhNiBfLiDfHiClDiCoKiClNiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iNmFjDeLiJlLiCmFjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
				bUpdated = TRUE;
			} else
			//----- _xZkqqHx_iDhNiBfLiDfHiClDiCoKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
			{
				//----- _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPgPjHmNiClHiCoJ_xHqqkZx_ -----
				switch (byCmdPrev)
				{
				case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
					break;
				case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
					// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
					my::WriteCmdDeleteThinLine(pWriteQueue, lLnIndexPrev, eLinePrev);
					break;
				case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
					// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
					my::WriteCmdInsertThinLine(pWriteQueue, lLnIndexPrev, eLinePrev);
					break;
				case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
					// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
					my::WriteCmdReplaceChars(pWriteQueue, mpDeletePrev, mpInsertPrev);
					break;
				}
				// _xZkqqHx_jBePiJpBiDfCiDhNiDjDiDgIiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
				byCmdPrev = FDECMD_NONE;

				//----- _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjBePiJpBiDfCiDhNiDjDiDgIiCnGiInKjDkOiClHiCoJiBeBiIlNiCkCiCmN_xHqqkZx_ _xZkqqHx_iPgPjHmNiClHiCoJ_xHqqkZx_ -----
				switch (byCmdNew)
				{
				case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
				case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
					// _xZkqqHx_iClBiCoKiCoHiCmMiDfCiDhNiDjDiDgIiCmNjBePiJpBiDfCiDhNiDjDiDgIiCmGiClFiCmEjFnLjBlGiClDiCoKiCmIiCkCiBeC_xHqqkZx_
					// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiCnMiCoJiClCiCmGiPgPjHmNiClHiCoJiBeC_xHqqkZx_
					memcpy(pWriteQueue, &vCmdBuffNew[0], vCmdBuffNew.size());
					pWriteQueue += vCmdBuffNew.size();
					break;
				case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
				case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
					// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAjAnNjCoIiBeC_xHqqkZx_
					byCmdPrev = byCmdNew;
					lLnIndexPrev = lLnIndexNew;
					eLinePrev = eLineNew;
					break;
				case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
					// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAjAnNjCoIiBeC_xHqqkZx_
					byCmdPrev = byCmdNew;
					mpDeletePrev = mpDeleteNew;
					mpInsertPrev = mpInsertNew;
					break;
				}
			}
		}

		//----- _xZkqqHx_iOgDiCmBiCmEiCkCiCoJjBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPgPjHmNiClHiCoJ_xHqqkZx_ -----

		switch (byCmdPrev)
		{
		case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			break;
		case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
			my::WriteCmdDeleteThinLine(pWriteQueue, lLnIndexPrev, eLinePrev);
			break;
		case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
			my::WriteCmdInsertThinLine(pWriteQueue, lLnIndexPrev, eLinePrev);
			break;
		case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jBePiJpBiCmMiDfCiDhNiDjDiDgIiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
			my::WriteCmdReplaceChars(pWriteQueue, mpDeletePrev, mpInsertPrev);
			break;
		}
		// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiBfLiCpAjBhNjDpMiBeC_xHqqkZx_
		pWriteQueue[0] = 0;
		pWriteQueue++;
		long lQueueSize = (pWriteQueue - &byvQueue[0]);
		// _xZkqqHx_iNmFiMoDiCmMiDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiBfLiCmMiCnNiCmMiPoKiNiHiCmNiLpDiCmJiBeC_xHqqkZx_
		if (lQueueSize == 1)
			byvQueue.clear();
		else
			byvQueue.resize(lQueueSize);
	} while (bUpdated && !byvQueue.empty());
	// _xZkqqHx_iNmFjDeLiJlLiCmFiIoKjDhIiCmFiCoAjFmPiNfIiClDiCoKiCmEiCkCiCoJiKnEiCmNiDiLiBfLiDhGiCpAiMhAjBlBiBeC_xHqqkZx_
	// _xZkqqHx_jHnHiCoIiNiHiCkEiDfCiDhNiDjDiDgIiCpAiDhNiBfLiDfHiClFjBlBiCkPiCmEiCkCiCoJiCmGiBeBjHkDiCoKiClNiDfCiDhNiDjDiDgIiCkK_xHqqkZx_
	// _xZkqqHx_jHnHiCoIiNiHiCkEiCoGiCkEiCmJiCmIiCoIiBeBiDhNiBfLiDfHiCmFiCkLiCoJiPoKiNiHiCkKiCkAiCoJiClNiCnPiBeC_xHqqkZx_
} // CFCWndRichEdit::OptimizeCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClN_xHqqkZx_UNICODE_xZkqqHx_iDgFiDeMiDfIiDgHiCpAiBeBiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiPfNiCmBiCmE_xHqqkZx_Redo_xZkqqHx_iClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wstrText	:UNICODE_xZkqqHx_iDgFiDeMiDfIiDgHiCpAiOhHjCoIiBeCiJpMiNhDiCmN_xHqqkZx_L'\n'_xZkqqHx_iCfAjFlGiOjKiBeC_xHqqkZx_
 *						 _xZkqqHx_jFmPiNfIiClFiClNjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *			pQueue		:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCpAiOhHjCoIiBeC_xHqqkZx_
 *			szQueueSize	:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiDfEiDeDiDfJiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdQueue (WString& wstrText, const BYTE* pQueue, size_t szQueueSize)
{
	// _xZkqqHx_iDeMiDiFiBfLiPeJjCfLiBeC_xHqqkZx_
	const BYTE* pQueueEnd = pQueue + szQueueSize;
	while (pQueue != pQueueEnd)
	{
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		const DWORD dwSizeBn = ReadVSizeU(pQueue);
		// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCmNiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		if (dwSizeBn == 0) continue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiPeJjCfLiImKjChFiCpAiLeMiJkPiBeC_xHqqkZx_
		const BYTE* pCmdEnd = pQueue + dwSizeBn;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
		BYTE byCmd = *pQueue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		pQueue++;
		//----- _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
		switch (byCmd)
		{
		case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			break;
		case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lLnIndex = ReadVSizeU(pQueue);
			ASSERT(wstrText.GetAt(lLnIndex) == L'\n');
			wstrText.Delete(lLnIndex);
			break;
		  }
		case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lLnIndex = ReadVSizeU(pQueue);
			wstrText.Insert(lLnIndex, L'\n');
			break;
		  }
		case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_jDpMiCoKjBnGiCkGiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lIdxFrom = ReadVSizeU(pQueue);
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lDelCount = ReadVSizeU(pQueue);
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
			pQueue += FCEditChar::SizeOfStream() * lDelCount;
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lInsCount = ReadVSizeU(pQueue);
			WString wstrInsText;
			long lIdx;
			for (lIdx = 0; lIdx != lInsCount; lIdx++)
			{
				FCEditChar eChar;
				eChar.InStream(pQueue);
				if (eChar.m_wChar != FDRCH_RETURN)
					wstrInsText += eChar.m_wChar;
				else
					wstrInsText += L'\n';
			}
			// _xZkqqHx_iDgFiDeMiDfIiDgHiCkJiCoHiNoNiPjMiBeC_xHqqkZx_
			wstrText.Delete(lIdxFrom, lDelCount);
			// _xZkqqHx_iDgFiDeMiDfIiDgHiCpAjBhNjDpMiBeC_xHqqkZx_
			wstrText.Insert(lIdxFrom, wstrInsText);
			break;
		  }
		}
		// _xZkqqHx_iDfCiDhNiDjDiDgIiPeJjCfLiImKjChFiCnGiInKjDkOiBeC_xHqqkZx_
		pQueue = pCmdEnd;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		ReadVSizeU(pQueue);
	}
} // CFCWndRichEdit::RedoCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClN_xHqqkZx_UNICODE_xZkqqHx_iDgFiDeMiDfIiDgHiCpAiBeBiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiPfNiCmBiCmE_xHqqkZx_Undo_xZkqqHx_iClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wstrText	:UNICODE_xZkqqHx_iDgFiDeMiDfIiDgHiCpAiOhHjCoIiBeCiJpMiNhDiCmN_xHqqkZx_L'\n'_xZkqqHx_iCfAjFlGiOjKiBeC_xHqqkZx_
 *						 _xZkqqHx_jFmPiNfIiClFiClNjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *			pQueue		:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCpAiOhHjCoIiBeC_xHqqkZx_
 *			szQueueSize	:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiDfEiDeDiDfJiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdQueue (WString& wstrText, const BYTE* pQueue, size_t szQueueSize)
{
	// _xZkqqHx_iDeMiDiFiBfLiCkKiLpDiCmMiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
	if (szQueueSize == 0) return;
	// _xZkqqHx_iDeMiDiFiBfLjAoGjDkKiBeC_xHqqkZx_
	const BYTE* pQueueTop = pQueue;
	// _xZkqqHx_iDeMiDiFiBfLiPeJjCfLiCnGiInKjDkOiBeC_xHqqkZx_
	pQueue += szQueueSize;

	// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_jFkKiBgJiDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOjFkKiBgKjGnPiClHiBeC_xHqqkZx_
	RReadVSizeU(pQueue);
	while (pQueue != pQueueTop)
	{
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		const DWORD dwSizeBn = RReadVSizeU(pQueue);
		// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCmNiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		if (dwSizeBn == 0) continue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjAoGjDkKiCnGiInKjDkOiBeC_xHqqkZx_
		pQueue -= dwSizeBn;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjAoGjDkKiImKjChFiCpAiLeMiJkPiBeC_xHqqkZx_
		const BYTE* pCmdTop = pQueue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
		BYTE byCmd = *pQueue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		pQueue++;
		//----- _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
		switch (byCmd)
		{
		case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			break;
		case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lLnIndex = ReadVSizeU(pQueue);
			wstrText.Insert(lLnIndex, L'\n');
			break;
		  }
		case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lLnIndex = ReadVSizeU(pQueue);
			ASSERT(wstrText.GetAt(lLnIndex) == L'\n');
			wstrText.Delete(lLnIndex);
			break;
		  }
		case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_jDpMiCoKjBnGiCkGiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lIdxFrom = ReadVSizeU(pQueue);
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lInsCount = ReadVSizeU(pQueue);
			WString wstrInsText;
			long lIdx;
			for (lIdx = 0; lIdx != lInsCount; lIdx++)
			{
				FCEditChar eChar;
				eChar.InStream(pQueue);
				if (eChar.m_wChar != FDRCH_RETURN)
					wstrInsText += eChar.m_wChar;
				else
					wstrInsText += L'\n';
			}
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			long lDelCount = ReadVSizeU(pQueue);
			// _xZkqqHx_iDgFiDeMiDfIiDgHiCkJiCoHiNoNiPjMiBeC_xHqqkZx_
			wstrText.Delete(lIdxFrom, lDelCount);
			// _xZkqqHx_iDgFiDeMiDfIiDgHiCpAjBhNjDpMiBeC_xHqqkZx_
			wstrText.Insert(lIdxFrom, wstrInsText);
			break;
		  }
		}
		// _xZkqqHx_iDfCiDhNiDjDiDgIjAoGjDkKiImKjChFiCnGiInKjDkOiBeC_xHqqkZx_
		pQueue = pCmdTop;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		RReadVSizeU(pQueue);
	}
} // CFCWndRichEdit::UndoCmdQueue.

struct My
{
	// _xZkqqHx_iNoNiPjMjEmNiImNiCmMiKeKiOgOiBeFiPeJjHlJiImKjChFiCkKjBeJjBpAjEmNiImNiCoGiCoIiPoDiCkJiJlKiCkJiCpAiOkGiClHiBeC_xHqqkZx_
	enum {
		UNDER_RANGE = -1,	// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiJlKiBgJjEmNiImNiKeKiOgO_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
		BETWEEN_RANGE = 0,	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjCiGiBgJjEmNiImNiKeKiOgOiBeBjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnMiCmIiCkCiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
		OVER_RANGE = 1,		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiPoDiBgJjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
	};

	static int WhichRange (const FClongRange& range, long lIndex)
	{
		if (lIndex <= range.lFrom)
			return UNDER_RANGE;
		if (range.lTo <= lIndex)
			return OVER_RANGE;
		else
			return BETWEEN_RANGE;
	}

	static BOOL ApplyRange (longRangeVector& vSelectRange,
							long lDelBegin,		// _xZkqqHx_iNoNiPjMiKeKiOgOiImKjChFiBeC_xHqqkZx_
							long lDelEnd,		// _xZkqqHx_iNoNiPjMiPeJjHlJiImKjChFiBeC_xHqqkZx_
							long lInsBegin,		// _xZkqqHx_jBhNjDpMiKeKiOgOiImKjChFiBeC_xHqqkZx_
							long lInsEnd)		// _xZkqqHx_jBhNjDpMiPeJjHlJiImKjChFiBeC_xHqqkZx_
	{
		// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
		BOOL bUpdated = FALSE;
		longRangeVector::iterator iSelRange;
		if (lDelBegin != lDelEnd)
		//----- _xZkqqHx_iNoNiPjMiKeKiOgOiImKjChFiCmGiNoNiPjMiPeJjHlJiImKjChFiCkKiInJiCmIiCoJiPoKiNiH_xHqqkZx_ -----
		{
			for (iSelRange = vSelectRange.begin(); iSelRange != vSelectRange.end();)
			{
				BOOL bIsRemoveSelRange = FALSE;
				switch (WhichRange(*iSelRange, lDelBegin))
				{
				case UNDER_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiJlKiBgJjEmNiImNiKeKiOgO_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					switch (WhichRange(*iSelRange, lDelEnd))
					{
					case UNDER_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiJlKiBgJjEmNiImNiKeKiOgO_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					//----- _xZkqqHx_iDfAiBfLiDfIiCfAiCmMiPoKiNiH_xHqqkZx_ -----
						iSelRange->lFrom -= (lDelEnd - lDelBegin);
						iSelRange->lTo -= (lDelEnd - lDelBegin);
						break;
					case BETWEEN_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjCiGiBgJjEmNiImNiKeKiOgOiBeBjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnMiCmIiCkCiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					//----- _xZkqqHx_iDfAiBfLiDfIiCfBiCmMiPoKiNiH_xHqqkZx_ -----
						iSelRange->lFrom = lDelBegin;
						iSelRange->lTo = iSelRange->lFrom + (iSelRange->lTo - lDelEnd);
						// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
						bUpdated = TRUE;
						break;
					case OVER_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiPoDiBgJjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					//----- _xZkqqHx_iDfAiBfLiDfIiCfFiCmMiPoKiNiH_xHqqkZx_ -----
						iSelRange = vSelectRange.erase(iSelRange);
						// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
						bUpdated = TRUE;
						bIsRemoveSelRange = TRUE;
						break;
					}
					break;
				case BETWEEN_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjCiGiBgJjEmNiImNiKeKiOgOiBeBjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnMiCmIiCkCiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					switch (WhichRange(*iSelRange, lDelEnd))
					{
					case BETWEEN_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjCiGiBgJjEmNiImNiKeKiOgOiBeBjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnMiCmIiCkCiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					//----- _xZkqqHx_iDfAiBfLiDfIiCfCiCmMiPoKiNiH_xHqqkZx_ -----
						iSelRange->lTo -= (lDelEnd - lDelBegin);
						// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
						bUpdated = TRUE;
						break;
					case OVER_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiPoDiBgJjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					//----- _xZkqqHx_iDfAiBfLiDfIiCfDiCmMiPoKiNiH_xHqqkZx_ -----
						iSelRange->lTo = lDelBegin;
						// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
						bUpdated = TRUE;
						break;
					}
					break;
				case OVER_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiPoDiBgJjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
					//----- _xZkqqHx_iDfAiBfLiDfIiCfEiCmMiPoKiNiH_xHqqkZx_ -----
					break;
				}
				if (!bIsRemoveSelRange)
					iSelRange++;
			}
		}
		if (lInsBegin != lInsEnd)
		//----- _xZkqqHx_jBhNjDpMiKeKiOgOiImKjChFiCmGjBhNjDpMiPeJjHlJiImKjChFiCkKiInJiCmIiCoJiPoKiNiH_xHqqkZx_ -----
		{
			for (iSelRange = vSelectRange.begin(); iSelRange != vSelectRange.end(); iSelRange++)
			{
				BOOL bIsInsertSelRange = FALSE;
				switch (WhichRange(*iSelRange, lInsBegin))
				{
				case UNDER_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiJlKiBgJjEmNiImNiKeKiOgO_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
				//----- _xZkqqHx_iDfAiBfLiDfIiCfAiCmMiPoKiNiH_xHqqkZx_ -----
					iSelRange->lFrom += (lInsEnd - lInsBegin);
					iSelRange->lTo += (lInsEnd - lInsBegin);
					break;
				case BETWEEN_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjCiGiBgJjEmNiImNiKeKiOgOiBeBjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnMiCmIiCkCiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
				//----- _xZkqqHx_iDfAiBfLiDfIiCfBiCmMiPoKiNiH_xHqqkZx_ -----
				  {
					// _xZkqqHx_jFkKjCgGiClDiCoKiCoJjBePjElMjFjEjFkKiCpAiNoMjAkMiBeC_xHqqkZx_
					FClongRange range(iSelRange->lFrom, lInsBegin);
					// _xZkqqHx_jFkKjCgGiClDiCoKiCoJiMoDjElMjFjEjFkKiCpAiPeDjAlDiBeCiOjPiCmMiDiLiBfLiDhGiCmFjAlDiClFiCkNjFoCjAlDiClDiCoKiCoJiBeC_xHqqkZx_
					iSelRange->lFrom = lInsBegin;
					// _xZkqqHx_jBePjElMjFjEjFkKiCpAjBhNjDpMiBeC_xHqqkZx_
					iSelRange = vSelectRange.insert(iSelRange, range);
					// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
					bUpdated = TRUE;
					break;
				  }
				case OVER_RANGE:		// _xZkqqHx_jBeJjBpAjEmNiImNiCoGiCoIiPoDiBgJjEmNiImNiPeJjHlJ_xHqqkZx_==_xZkqqHx_iCpAiKnMiCnOiBgKiCmMiPoKiNiHiBeC_xHqqkZx_
				//----- _xZkqqHx_iDfAiBfLiDfIiCfCiCmMiPoKiNiH_xHqqkZx_ -----
					break;
				}
			}
		}
		// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
		return bUpdated;
	} // ApplyRange.
}; // struct My.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjBeJjBpAjEmNiImNiCpAiBeBiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiPfNiCmBiCmE_xHqqkZx_Redo_xZkqqHx_iClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	vSelectRange:_xZkqqHx_jBeJjBpAjEmNiImNiCmMjEhKjHpBiCpAiOhHjCoIiBeC_xHqqkZx_Redo_xZkqqHx_iCpAjDeLjHhAiClFiClNiMiLiJmKiCpAjFnEiClHiBeC_xHqqkZx_
 *			pQueue		:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCpAiOhHjCoIiBeC_xHqqkZx_
 *			szQueueSize	:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiDfEiDeDiDfJiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	vSelectRange_xZkqqHx_iCmFjHfOiCkGiCoHiCoKiClNjBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAiNoNiPjMiBeFjFkKjCgGiClDiCoKiClN_xHqqkZx_
 *			_xZkqqHx_iPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJjBmOiClFiCmEiCmNiBeBjFeLiClI_xHqqkZx_ bIsFlatText = TRUE _xZkqqHx_iCmF_xHqqkZx_
 *			OptimizeCmdQueue_xZkqqHx_iKnGjAjEiCpAiOmAiNhDiClFiCmEiCkIiCkNiClBiCmGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iImIiJlKiCmJiBeBjBeJjBpAjEmNiImNjEhKjHpBiCmJjBmOiClFiCmEiNoNiPjMiCpAjDeLjHhAiClFiClNjHoBiCpAiOkGiClHiBeC_xHqqkZx_
 *
 *                   3       6        10          16   18    20
 *          _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEkH_xHqqkZx_       _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_   _xZkqqHx_iEkFiEjPiEjPiEkH_xHqqkZx_
 *                              7   9
 *                     _xZkqqHx_iNoNiPjMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEkH_xHqqkZx_
 *
 *                               _xZkqqHx_iBkLiNoNiPjMjEmNiImNjDeLjHhAiMoD_xHqqkZx_
 *
 *                   3       6    8           16   18    20
 *          _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEkH_xHqqkZx_   _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_   _xZkqqHx_iEkFiEjPiEjPiEkH_xHqqkZx_
 *
 *
 *          _xZkqqHx_iNoNiPjMiCmJiCmNiBeBiImIiJlKiCmMiCfFiCmCiCmMiDfAiBfLiDfIiCkKiCkAiCoJiBeC_xHqqkZx_
 *          _xZkqqHx_iEkBiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkC_xHqqkZx_
 *          _xZkqqHx_iEkAiDfAiBfLiDfIiCfA_xHqqkZx_                          _xZkqqHx_iEkAiDfAiBfLiDfIiCfD_xHqqkZx_                        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                10          16    _xZkqqHx_iEkA_xHqqkZx_            10          16      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_   _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_            8   10                _xZkqqHx_iEkA_xHqqkZx_                      15  17    _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_   _xZkqqHx_iNoNiPjMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEkH_xHqqkZx_                _xZkqqHx_iEkA_xHqqkZx_             _xZkqqHx_iNoNiPjMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEkH_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *          _xZkqqHx_iEkAiDfAiBfLiDfIiCfB_xHqqkZx_                          _xZkqqHx_iEkAiDfAiBfLiDfIiCfE_xHqqkZx_                        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                10          16    _xZkqqHx_iEkA_xHqqkZx_            10          16      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_   _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_              9   11              _xZkqqHx_iEkA_xHqqkZx_                        16  18  _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_     _xZkqqHx_iNoNiPjMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEkH_xHqqkZx_              _xZkqqHx_iEkA_xHqqkZx_               _xZkqqHx_iNoNiPjMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEkH_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *          _xZkqqHx_iEkAiDfAiBfLiDfIiCfC_xHqqkZx_                          _xZkqqHx_iEkAiDfAiBfLiDfIiCfF_xHqqkZx_                        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                10          16    _xZkqqHx_iEkA_xHqqkZx_            10          16      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_   _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                    12  14        _xZkqqHx_iEkA_xHqqkZx_          19              17    _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_iNoNiPjMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEkH_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_ _xZkqqHx_iNoNiPjMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkEiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkD_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfAiCmFiCmNiBeBjBeJjBpAjEmNiImNjBfDjBmMiCkKiNoNiPjMjFlGiOjKjAjEiClOiCkPiNlGiCmJiKpBiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfBiCmFiCmNiBeBjBeJjBpAjEmNiImNiCmMjBePjElMiCkKiNoNiPjMiClDiCoKiBeBjBfDjBmMiCkKiNlGiCmJiKpBiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfCiCmFiCmNiBeBjBeJjBpAjEmNiImNiCmMiPeJjHlJjFjEiCkKiNlGiCmJiKpBiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfDiCmFiCmNiBeBjBeJjBpAjEmNiImNiCmMiPeJjHlJjFjEiCkKiNlGiCmJiKpBiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfEiCmFiCmNiBeBjBeJjBpAjEmNiImNiCmJjFmPiJlLiCmNjGlDiCkCiBeC_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfFiCmFiCmNiBeBjBeJjBpAjEmNiImNiCmNiNoNiPjMiClDiCoKiCoJiBeC_xHqqkZx_
 *
 *          _xZkqqHx_jBhNjDpMiCmJiCmNiBeBiImIiJlKiCmMiCfCiCmCiCmMiDfAiBfLiDfIiCkKiCkAiCoJiBeC_xHqqkZx_
 *          _xZkqqHx_iEkBiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkC_xHqqkZx_
 *          _xZkqqHx_iEkAiDfAiBfLiDfIiCfA_xHqqkZx_                              _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                10          16        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_              9                       _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_     _xZkqqHx_jBhNjDpMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiBgD_xHqqkZx_                  _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *          _xZkqqHx_iEkAiDfAiBfLiDfIiCfB_xHqqkZx_                              _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                10          16        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                    12                _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_jBhNjDpMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiBgD_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *          _xZkqqHx_iEkAiDfAiBfLiDfIiCfC_xHqqkZx_                              _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                10          16        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_jBeJjBpAjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                              12      _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkA_xHqqkZx_                     _xZkqqHx_jBhNjDpMjEmNiImN_xHqqkZx_ _xZkqqHx_iEkFiEjPiBgD_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_
 *          _xZkqqHx_iEkEiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkD_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfAiCmFiCmNiBeBjBeJjBpAjEmNiImNjBfDjBmMiCkKiJeFiCmJiKpBiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfBiCmFiCmNiBeBjBeJjBpAjEmNiImNiCkKiCfBiCmCiCmJjFkKjCgGiClDiCoKiBeBiMoDiCmMiCfAiCmCiCkKiJeFiCmJiKpBiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfAiBfLiDfIiCfCiCmFiCmNiBeBjBeJjBpAjEmNiImNiCmJjFmPiJlLiCmNjGlDiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.03.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::RedoCmdQueue (	longRangeVector& vSelectRange,
									const BYTE* pQueue,
									size_t szQueueSize)
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
	BOOL bUpdated = FALSE;
	// _xZkqqHx_iDeMiDiFiBfLiPeJjCfLiBeC_xHqqkZx_
	const BYTE* pQueueEnd = pQueue + szQueueSize;
	while (pQueue != pQueueEnd)
	{
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		const DWORD dwSizeBn = ReadVSizeU(pQueue);
		// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCmNiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		if (dwSizeBn == 0) continue;

		long lDelBegin = -1;	// _xZkqqHx_iNoNiPjMiKeKiOgOiImKjChFiBeC_xHqqkZx_
		long lDelEnd = -1;		// _xZkqqHx_iNoNiPjMiPeJjHlJiImKjChFiBeC_xHqqkZx_
		long lInsBegin = -1;	// _xZkqqHx_jBhNjDpMiKeKiOgOiImKjChFiBeC_xHqqkZx_
		long lInsEnd = -1;		// _xZkqqHx_jBhNjDpMiPeJjHlJiImKjChFiBeC_xHqqkZx_

		// _xZkqqHx_iDfCiDhNiDjDiDgIiPeJjCfLiImKjChFiCpAiLeMiJkPiBeC_xHqqkZx_
		const BYTE* pCmdEnd = pQueue + dwSizeBn;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
		BYTE byCmd = *pQueue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		pQueue++;
		//----- _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
		switch (byCmd)
		{
		case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmNiNmFjDeLiJlLiClDiCoKiCmEiCkCiCoJiCmMiCmFiBeBiClBiCoKiCoHiCmMiDfCiDhNiDjDiDgIiCmNjBlGiNnNiClFiCmIiCkCiCmNiClIiBeC_xHqqkZx_
			FFThrowMiscUnknown();
			break;
		case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jFmPiNfIiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lDelBegin = lInsBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKjAjEiCpAiJmBiOfKiBeC_xHqqkZx_
			lDelEnd = lInsEnd = lDelBegin + ReadVSizeU(pQueue);
			break;
		case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lDelBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_iNoNiPjMiCmNiJpMiNhDiCfAjFlGiOjKiBeC_xHqqkZx_
			lDelEnd = lDelBegin + 1;
			break;
		case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lInsBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_jBhNjDpMiCmNiJpMiNhDiCfAjFlGiOjKiBeC_xHqqkZx_
			lInsEnd = lInsBegin + 1;
			break;
		case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jDpMiCoKjBnGiCkGiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lDelBegin = lInsBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAiJmBiOfKiBeC_xHqqkZx_
			lDelEnd = lDelBegin + ReadVSizeU(pQueue);
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
			pQueue += FCEditChar::SizeOfStream() * (lDelEnd - lDelBegin);
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAiJmBiOfKiBeC_xHqqkZx_
			lInsEnd = lInsBegin + ReadVSizeU(pQueue);
			break;
		}
		// _xZkqqHx_iDfCiDhNiDjDiDgIiPeJjCfLiImKjChFiCnGiInKjDkOiBeC_xHqqkZx_
		pQueue = pCmdEnd;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		ReadVSizeU(pQueue);
		// _xZkqqHx_iNoNiPjMiBeFjBhNjDpMiCpAjBeJjBpAjEmNiImNiCmJjDeLjHhAiBeC_xHqqkZx_
		if (My::ApplyRange(vSelectRange, lDelBegin, lDelEnd, lInsBegin, lInsEnd))
			bUpdated = TRUE;	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
	}
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
	return bUpdated;
} // CFCWndRichEdit::RedoCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjBeJjBpAjEmNiImNiCpAiBeBiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiPfNiCmBiCmE_xHqqkZx_Undo_xZkqqHx_iClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	vSelectRange:_xZkqqHx_jBeJjBpAjEmNiImNiCmMjEhKjHpBiCpAiOhHjCoIiBeC_xHqqkZx_Undo_xZkqqHx_iCpAjDeLjHhAiClFiClNiMiLiJmKiCpAjFnEiClHiBeC_xHqqkZx_
 *			pQueue		:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCpAiOhHjCoIiBeC_xHqqkZx_
 *			szQueueSize	:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiDfEiDeDiDfJiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	vSelectRange_xZkqqHx_iCmFjHfOiCkGiCoHiCoKiClNjBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAiNoNiPjMiBeFjFkKjCgGiClDiCoKiClN_xHqqkZx_
 *			_xZkqqHx_iPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.03.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::UndoCmdQueue (	longRangeVector& vSelectRange,
									const BYTE* pQueue,
									size_t szQueueSize)
{
	// _xZkqqHx_iDeMiDiFiBfLiCkKiLpDiCmMiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
	if (szQueueSize == 0) return FALSE;
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
	BOOL bUpdated = FALSE;
	// _xZkqqHx_iDeMiDiFiBfLjAoGjDkKiBeC_xHqqkZx_
	const BYTE* pQueueTop = pQueue;
	// _xZkqqHx_iDeMiDiFiBfLiPeJjCfLiCnGiInKjDkOiBeC_xHqqkZx_
	pQueue += szQueueSize;

	// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_jFkKiBgJiDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOjFkKiBgKjGnPiClHiBeC_xHqqkZx_
	RReadVSizeU(pQueue);
	while (pQueue != pQueueTop)
	{
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		const DWORD dwSizeBn = RReadVSizeU(pQueue);
		// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCmNiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		if (dwSizeBn == 0) continue;

		long lDelBegin = -1;	// _xZkqqHx_iNoNiPjMiKeKiOgOiImKjChFiBeC_xHqqkZx_
		long lDelEnd = -1;		// _xZkqqHx_iNoNiPjMiPeJjHlJiImKjChFiBeC_xHqqkZx_
		long lInsBegin = -1;	// _xZkqqHx_jBhNjDpMiKeKiOgOiImKjChFiBeC_xHqqkZx_
		long lInsEnd = -1;		// _xZkqqHx_jBhNjDpMiPeJjHlJiImKjChFiBeC_xHqqkZx_

		// _xZkqqHx_iDfCiDhNiDjDiDgIjAoGjDkKiCnGiInKjDkOiBeC_xHqqkZx_
		pQueue -= dwSizeBn;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjAoGjDkKiImKjChFiCpAiLeMiJkPiBeC_xHqqkZx_
		const BYTE* pCmdTop = pQueue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
		BYTE byCmd = *pQueue;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		pQueue++;
		//----- _xZkqqHx_iNkBiJpBiCmMiDfCiDhNiDjDiDgIiCpAjDmHiCnNiNjOiCnO_xHqqkZx_ -----
		switch (byCmd)
		{
		case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
		case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmNiNmFjDeLiJlLiClDiCoKiCmEiCkCiCoJiCmMiCmFiBeBiClBiCoKiCoHiCmMiDfCiDhNiDjDiDgIiCmNjBlGiNnNiClFiCmIiCkCiCmNiClIiBeC_xHqqkZx_
			FFThrowMiscUnknown();
			break;
		case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_jFmPiNfIiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lDelBegin = lInsBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKjAjEiCpAiJmBiOfKiBeC_xHqqkZx_
			lDelEnd = lInsEnd = lDelBegin + ReadVSizeU(pQueue);
			break;
		case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lInsBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_jBhNjDpMiCmNiJpMiNhDiCfAjFlGiOjKiBeC_xHqqkZx_
			lInsEnd = lInsBegin + 1;
			break;
		  }
		case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lDelBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_iNoNiPjMiCmNiJpMiNhDiCfAjFlGiOjKiBeC_xHqqkZx_
			lDelEnd = lDelBegin + 1;
			break;
		  }
		case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
		  {
			// _xZkqqHx_jDpMiCoKjBnGiCkGiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
			lInsBegin = lDelBegin = ReadVSizeU(pQueue);
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAiJmBiOfKiBeC_xHqqkZx_
			lInsEnd = lInsBegin + ReadVSizeU(pQueue);
			// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
			pQueue += FCEditChar::SizeOfStream() * (lInsEnd - lInsBegin);
			// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAiJmBiOfKiBeC_xHqqkZx_
			lDelEnd = lDelBegin + ReadVSizeU(pQueue);
			break;
		  }
		}
		// _xZkqqHx_iDfCiDhNiDjDiDgIjAoGjDkKiImKjChFiCnGiInKjDkOiBeC_xHqqkZx_
		pQueue = pCmdTop;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
		RReadVSizeU(pQueue);
		// _xZkqqHx_iNoNiPjMiBeFjBhNjDpMiCpAjBeJjBpAjEmNiImNiCmJjDeLjHhAiBeC_xHqqkZx_
		if (My::ApplyRange(vSelectRange, lDelBegin, lDelEnd, lInsBegin, lInsEnd))
			bUpdated = TRUE;	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
	}
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiIoKiJnDiPiKiCmFiCoAjFmPiNfIiClDiCoKiClNiCkJiBeI_xHqqkZx_
	return bUpdated;
} // CFCWndRichEdit::UndoCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCurCharInfo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCmEiCkCiCoJjEmNiImNiCmMjFlGiOjKiCpAiDiLiBfLiDhGiClFiCmEiBeBiDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCpAiOmAiNhDiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	fncCallback	:_xZkqqHx_iDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *			pData		:_xZkqqHx_iDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCmMiIpIjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCurCharInfo (FDCharInfoCallback fncCallback, void* pData)
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();

	// _xZkqqHx_iMlLiNnNiCmMjFlGiOjKiPoOjFpBiCmJjBmOiClFiCmEiDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiOmAiNhDiBeC_xHqqkZx_
	(*fncCallback)(&m_fciCurExtCodeFormat, &m_fciCurStdCodeFormat, this, pData);

	long lSelFrom = -1;
	long lSelTo = -1;

	// _xZkqqHx_jBeJjBpAjEmNiImNiOoGjDlOiBeC_xHqqkZx_
	GetSelectNormal(lSelFrom, lSelTo);
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiNmFiMoDiCmMjFlGiOjKiCpAiKnMiCnOiPoKiNiHiCmNiBeBiNmFiMoDiCmMiJeCiClFiJpMiNhDiCoAjCmHiJmBiBeC_xHqqkZx_
	if (lSelTo == GetIndexSize()) lSelTo++;
	if (lSelFrom < 0 && m_lCurIndex == GetIndexSize())
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkNiBeBiDeKiDiMiDgCiDgHiCkKiDeHiDgGiDeCiDfOiNmFiMoDiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ ----
	{
		// _xZkqqHx_iNmFiMoDiCmMiCfAjFlGiOjKiBgJiJpMiNhDiBgKiCpAjBeJjBpAiBeC_xHqqkZx_
		lSelFrom = m_lCurIndex;
		lSelTo = m_lCurIndex + 1;
	}
	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKjGlDiCkCiPoKiNiHiCmNiClBiCmMiCnMiCnMjFjMiLeBiBeC_xHqqkZx_
	if (lSelFrom < 0) return;

	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----

	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMjAoGjDkKiDeDiDjDiDgGiDgCiDeOiDfIiCmMiNhDiBeFjHpBiCpAiOoGjDlOiBeC_xHqqkZx_
	long	lLine, lChar;
	IndexToCharPos(lLine, lChar, lSelFrom);
	// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKjHhAiCmJjFnLjBlGiBeC_xHqqkZx_
	const long lLineFrom = lLine;
	//----- _xZkqqHx_jBeJjBpAiClDiCoKiClNjFlGiOjKjHpBiCmMiDfCiDhDiBfLiCpAiCmGiCoJ_xHqqkZx_ -----
	FCEditCharVector vChar;	// _xZkqqHx_iDfCiDhDiBfLjAoGjFlGiOjKjHpBiDgPiDgCiDhEiDeAiBeC_xHqqkZx_
	for (long lCharSz = lSelTo - lSelFrom; 0 < lCharSz; lCharSz--)
	{
		vChar.push_back(m_vEditLine[lLine].m_vEditChar[lChar]);
		(void)NextChar(lLine, lChar);
	}
	//----- _xZkqqHx_iDfCiDhDiBfLjAoGiCmMjFlGiOjKjHpBiCmJiBeBiDhEiDeIiDjDiDgHjFmPiNfIiCpAiCkJiCkPiCoJ_xHqqkZx_ -----
	FCEditCharVector::iterator iEc;
	// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
	CClientDC dc(this);	// _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
	FCAutoDC atDC(&dc, FALSE, 0, 0);
	//----- CFont_xZkqqHx_iCmMiPiJiKpKiJlLiLhJiCnBjFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJ_xHqqkZx_Zoom_xZkqqHx_iCpAiCfFiCfDjEhLiCmJjAnNjCoIiClHiCoJ_xHqqkZx_ -----
	double	dZoom = g_->dZoom;
	g_->dZoom = g_->dDisplayPPM * 64;

	//----- _xZkqqHx_jFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_ -----
	LOGFONT logFont;
	// _xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkCiClNiCnPiBeBiDfCiBfLiDgIiDhJiBfLiDfHiCpAjHhAiInDiBeC_xHqqkZx_
	WORD	wCodePage;
	SFontID	foidCurFont = 0;
	WORD	wCurOffset = 0;
	g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
	// _xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkCiClNiCnPiBeBiDfCiBfLiDgIiDhJiBfLiDfHiCpAjHhAiInDiBeC_xHqqkZx_
	wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
	atDC.SetFont(&logFont);
	for (iEc = vChar.begin(); iEc != vChar.end(); iEc++)
	{
		//----- _xZkqqHx_iMlLiNnNiCmMiDhEiDeIiDjDiDgHiCmMjBkOjAkLiCmJ_xHqqkZx_fci_xZkqqHx_iCmMjBkOjAkLiCpAiCkJiCnEiClJiCoJ_xHqqkZx_ -----
		FCFontCharInfo fciCur;
		g_pEnv->GetSFontRec((*iEc).m_foidFont)->ReqInit(fciCur);
		(*iEc).ReqOverwrite(fciCur);
		//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiHiCmNiBeB_xHqqkZx_CharSet_xZkqqHx_iCpAjAnNjCoI_xHqqkZx_ -----
		if (g_pReg->GetIsUseStdFont() && FFIsStdFontChar(Fdrch2Wchar((*iEc).m_wChar)))
			(*fncCallback)(NULL, &fciCur, this, pData);
		else
			(*fncCallback)(&fciCur, NULL, this, pData);

		FCSFontRec fntRec(fciCur);
		// Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkJiCmBiClNiBeC_xHqqkZx_
		// _xZkqqHx_iClBiCmMiClNiCnPiBeBiCkLiClPiCpBiCmG_xHqqkZx_CharSet_xZkqqHx_iCpAjClCiCnHiCoJiCoGiCkEiCmJiClFiClNiBeC_xHqqkZx_
		// _xZkqqHx_iOhHjCoIiCmMjFlGiOjKiCkKjBkOiClHiCoJ_xHqqkZx_Charset_xZkqqHx_iCmMiPfHiNiHiCpAiOoGjDlOiBeC_xHqqkZx_
		WORDVector vCharSet;
		FFUnicodeToCharSet(vCharSet, Fdrch2Wchar((*iEc).m_wChar), fntRec.GetCharSet());
		// FCSFontRec_xZkqqHx_iNfMjBkCjBmMiCkJiCoH_xHqqkZx_FontID_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
		SFontID foidTmp = g_pEnv->FindNearestSFont(fntRec, &vCharSet);
		// _xZkqqHx_jGlDiCkCiPoKiNiHiCmNjDgPjIfOiClHiCoJiBeC_xHqqkZx_
		if (foidTmp == FD_S_FONT_UNSPECIFY)
			g_pDoc->CmdInsert1SFont(foidTmp, fntRec);

		//----- FCEditChar_xZkqqHx_iCmMjBkOjAkLiBgJjFlGiOjKjFjNjBkOjAkLiCpAiPjMiCkNiBgKiCpAjFmPiNfI_xHqqkZx_ -----
		(*iEc).m_foidFont= foidTmp;
		(*iEc).Overread(fciCur);

		if (foidCurFont != (*iEc).m_foidFont || wCurOffset != (*iEc).m_wOffset)
		//----- _xZkqqHx_iMlLiNnNiCmMiDhEiDeIiDjDiDgHiCmGiInJiCmIiCoJiPoKiNiHiBeBiDhEiDeIiDjDiDgHiNfIjAfGiPiIjHjNiCpAiNhDiCkE_xHqqkZx_ -----
		{
			// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiCpAjFmPiNfIiBeC_xHqqkZx_
			foidCurFont = (*iEc).m_foidFont;
			// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
			wCurOffset = (*iEc).m_wOffset;
			// _xZkqqHx_jFfHiPiAjCgMiCmM_xHqqkZx_Zoom_xZkqqHx_iCmF_xHqqkZx_logFont_xZkqqHx_iCpAjAnNjCoIiBeC_xHqqkZx_
			g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
			wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
			atDC.SetFont(&logFont);
		}
		//----- _xZkqqHx_jFlGiOjKiBgJiDfCiBfLiDgI_xHqqkZx_wChar_xZkqqHx_iBgKiCmMjFjNiCpAiOoGjDlO_xHqqkZx_ -----
		if ((*iEc).m_wChar != FDRCH_RETURN && (*iEc).m_wChar != FDRCH_CONTINUE &&
			(*iEc).m_wChar != WCH_SPC && (*iEc).m_wChar != WCH_TAB)
		{
			ABC abc;
			atDC.GetCharABCWidth((*iEc).m_wChar, abc, wCodePage);
			(*iEc).m_mmfWidth = static_cast<fmmetol>(lg2mm(abc.abcA + abc.abcB + abc.abcC));
			(*iEc).m_mmfAbcA = static_cast<fmmetol>(lg2mm(abc.abcA));
			(*iEc).m_mmfAbcC = static_cast<fmmetol>(lg2mm(abc.abcC));
		}
	}
	// Zoom_xZkqqHx_iCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_
	g_->dZoom = dZoom;

	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	// _xZkqqHx_iDhEiDeIiDjDiDgHjFmPiNfIiDfCiDhNiDjDiDgIiCpAjEkNiNhDiBeC_xHqqkZx_
	CmdFormatChars(lSelFrom, vChar.size(), vChar.begin());
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();

	//----- _xZkqqHx_iImIiNhOiCmMiNhDiCpAiNmEiMhGiOfK_xHqqkZx_ -----
	CalcLineBelow(lLineFrom);
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
} // CFCWndRichEdit::SetCurCharInfo.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCurLineInfo
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCmEiCkCiCoJjEmNiImNiCmMiNhDiCpAiDiLiBfLiDhGiClFiCmEiBeBiDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCpAiOmAiNhDiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	fncCallback	:_xZkqqHx_iDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *			pData		:_xZkqqHx_iDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCmMiIpIjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	05.07.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCurLineInfo (FDLineInfoCallback fncCallback, void* pData)
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	if (0 <= m_lSelFrom)
	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		long lSelFrom, lSelTo;
		GetSelectNormal(lSelFrom, lSelTo);
		long lLineFrom, lLineTo, lChar;
		// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
		IndexToCharPos(lLineFrom, lChar, lSelFrom);
		// lLineFrom_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
		(void)JoinLineBelow(lLineFrom);
		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
		IndexToCharPos(lLineFrom, lChar, lSelFrom);
		IndexToCharPos(lLineTo, lChar, lSelTo - 1);

		for (long lLine = lLineFrom; lLine <= lLineTo; lLine++)
		{
			// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
			FCTextLineInfo tli;
			m_vEditLine[lLine].GetFormat(tli);
			// _xZkqqHx_iDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCpAiOmAiNhDiBeC_xHqqkZx_
			(*fncCallback)(&tli, this, pData);
			// _xZkqqHx_iNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
			FCEditLine elNew;
			elNew.SetFormat(tli);
			// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
			CmdFormatLine(CharPosToIndex(lLine, 0), elNew);
		}
		// _xZkqqHx_jFmPiNfIiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
		CalcLineBelow(lLineFrom);
		m_mmCaretX = RepositionCaret();
		SendRgnRedraw();
	} else
	//----- _xZkqqHx_jBeJjBpAjFjEjFkKiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
	{
		long lLine, lChar;
		// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
		GetCurCharPos(lLine, lChar);
		// lLine_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
		(void)JoinLineBelow(lLine);
		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
		GetCurCharPos(lLine, lChar);

		// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
		FCTextLineInfo tli;
		m_vEditLine[lLine].GetFormat(tli);
		// _xZkqqHx_iDfCiBfLiDiLiDgPiDgCiDeOiKnGjAjEiCpAiOmAiNhDiBeC_xHqqkZx_
		(*fncCallback)(&tli, this, pData);
		// _xZkqqHx_iNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
		FCEditLine elNew;
		elNew.SetFormat(tli);
		// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
		CmdFormatLine(CharPosToIndex(lLine, 0), elNew);

		// _xZkqqHx_jFmPiNfIiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
		CalcLineBelow(lLine);
		m_mmCaretX = RepositionCaret();
		SendRgnRedraw();
	}
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
} // CFCWndRichEdit::SetCurLineInfo.

//----- 05.07.10 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanPasteAsRtf
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIjCiGiCmMiDgFiDeMiDfIiDgHiCpAiBeBiDiKiDgCiDgAiDgFiDeMiDfIiDgHiCmGiClFiCmEiBeB_xHqqkZx_
// *			_xZkqqHx_jDfMiCoIjFhEiCkPiCoJiClBiCmGiCkKiPgPjHiIiCoJiCkJiCpAjClCiCnHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iJmCjEfMiCmIiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//BOOL CFCWndRichEdit::CanPasteAsRtf () const
//{
//	if (!FFCanEditDocument()) return FALSE;
//	return m_richpEditCtrl->CanPaste();
//} // CFCWndRichEdit::CanPasteAsRtf.
//----- 05.07.10 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnPasteAsRtf
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIjCiGiCmMiDgFiDeMiDfIiDgHiCpAiBeBiDiKiDgCiDgAiDgFiDeMiDfIiDgHiCmGiClFiCmEiBeB_xHqqkZx_
 *			_xZkqqHx_jDfMiCoIjFhEiCkPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	dwFormat	:_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeCiOkJjDkOiCmFjBeJjBpA_xHqqkZx_
 *						 _xZkqqHx_iClDiClJiCoJiPoKiNiHiCmNiCePiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnPasteAsRtf (DWORD dwFormat)
{
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
do
{
	if (0 <= m_lSelFrom)
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
		DrawSelect();
		// _xZkqqHx_jBeJjBpAjFjEjFkKiCpAiNoNiPjM_xHqqkZx_.
		(void)MCmdDeleteSelection();
	}

	CClientDC dc(this); // _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
	// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
	FCAutoDC atDC(&dc, FALSE, 0, 0);

	FCEditCharVector vWorkChar;

	//----- _xZkqqHx_iDeHiDgGiDeCiDgCiDgHiDfCiDjDiDgHiDiNiBfLiDiLiCmJiDhJiBfLiDfIiDgH_xHqqkZx_ -----
	// _xZkqqHx_iDhJiBfLiDfIiDgHiPiIjHjNiBeC_xHqqkZx_
	m_richpEditCtrl->PasteSpecial(m_fciCurStdCodeFormat, dwFormat);
	if (m_richpEditCtrl->IsEmpty()) break;

	//----- _xZkqqHx_iDeHiDgGiDeCiDgCiDgHiDfCiDjDiDgHiDiNiBfLiDiLiCmMjFlGiOjKjHpBiCfAjFlGiOjKiCfAjFlGiOjKiCmJjBmOiClFiCmEiBeB_xHqqkZx_
	//		_xZkqqHx_jBkOjAkLiOoGjDlOjDjJiCmMiPiIjHjNiCpAiNhDiCkCiBeB_xHqqkZx_FCEditChar_xZkqqHx_iCmM_xHqqkZx_vector_xZkqqHx_iCpAjAlGjAkMiClHiCoJ_xHqqkZx_ -----
	WORD	wChar;

	//----- _xZkqqHx_jFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJ_xHqqkZx_Zoom_xZkqqHx_iCpAiCfFiCfDjEhLiCmJjAnNjCoIiClHiCoJ_xHqqkZx_ -----
	double	dZoom = g_->dZoom;
	g_->dZoom = g_->dDisplayPPM * 64;

	//----- _xZkqqHx_iCnMiClIjFfHiPiAiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_ -----
	LOGFONT logFont;
// 02.09.10 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ (_xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkC_xHqqkZx_)
	WORD	wCodePage;
	SFontID	foidFont;
	SFontID	foidCurFont = 0;	// _xZkqqHx_jFfHiPiAiDhEiDeIiDjDiDgHiBeC_xHqqkZx_
	WORD	wCurOffset = 0;		// _xZkqqHx_iPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
// 02.09.10 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ (_xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkC_xHqqkZx_)
	wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
	atDC.SetFont(&logFont);

	FCEditChar		rc;
	FCTextLineInfo	tliCurFormat;	// _xZkqqHx_iMlLiNnNiCmMiNhDiDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
	BOOL			bLineTop;		// _xZkqqHx_iNhDiCmMjDkKiCkJiCmHiCkEiCkJiCpAiOhHjCoIiBeC_xHqqkZx_

	// _xZkqqHx_iMlLiNnNiCmMiNhDiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOoGjDlOiBeC_xHqqkZx_
	long lCurLine, lCurChar;
	GetCurCharPos(lCurLine, lCurChar);
	m_vEditLine[lCurLine].GetFormat(tliCurFormat);
	// _xZkqqHx_iMlLiNnNiCmMiNhDiCkKiJpMiNhDiCmMiCnNiCmMiNhDiCmIiCoHiCmOiBeBjBhNjDpMjFlGiOjKiCmNiNhDjDkKiCmGiClFiCmEiIlFiCkEiBeC_xHqqkZx_
	if (m_vEditLine[lCurLine].m_vEditChar.front().m_wChar == FDRCH_RETURN)
		bLineTop = TRUE;
	else
		bLineTop = FALSE;

	long lLineCalcFrom = -1;	// _xZkqqHx_iNhDiNmEiMhGiOfKiCmMiKeKiOgOiImKjChFiCpAiOhHjCoIiBeC_xHqqkZx_

	m_richpEditCtrl->BeginGetChar();
	FCFontCharInfo	fciCur;
	FCTextLineInfo	tliTmp;	// _xZkqqHx_iNhDiDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_

	while (m_richpEditCtrl->NextGetChar(wChar, fciCur, tliTmp))
	{
		//----- _xZkqqHx_iNhDiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOoGjDlO_xHqqkZx_ -----
		if (bLineTop)
		{
			// _xZkqqHx_iClBiCmMiNhDiCmMjBkOjAkLiCpAiOoGjDlOiBeC_xHqqkZx_
			tliCurFormat = tliTmp;
			bLineTop = FALSE;
		}
//----- 06.11.22 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		//----- _xZkqqHx_iDhEiDeIiDjDiDgHiDfEiDeDiDfJiMhGiOfKjHhAiCmJiMlLiNnNiCmMiDhEiDeIiDjDiDgHiCpAiOoGjDlO_xHqqkZx_ -----
//		FCSFontRec fntRec(fciCur);
//----- 06.11.22 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiHiCmNiBeBjFfHiPiAjFlGiOjKiDfCiBfLiDgIjAoKjHhAiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_ -----
		if (FFIsStdFontChar(wChar))
		{
			FFOverwrite(m_fciCurStdCodeFormat, fciCur, FDFI_FLAG_ALL);
			FFOverwrite(m_fciCurExtCodeFormat, fciCur, 
					FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
					FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
//----- 06.11.22 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
			// fciCur_xZkqqHx_iCmNiLpDiCmMiPoKiNiHiCkKiCkAiCoJiCmMiCmF_xHqqkZx_m_fciCurStdCodeFormat_xZkqqHx_iCmF_xHqqkZx_
			// _xZkqqHx_iPiJiKpKiJlLiClFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
			fciCur = m_fciCurStdCodeFormat;
//----- 06.11.22 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
		} else
		{
			FFOverwrite(m_fciCurExtCodeFormat, fciCur, FDFI_FLAG_ALL);
			FFOverwrite(m_fciCurStdCodeFormat, fciCur, 
					FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
					FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
//----- 06.11.22 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
			// fciCur_xZkqqHx_iCmNiLpDiCmMiPoKiNiHiCkKiCkAiCoJiCmMiCmF_xHqqkZx_m_fciCurExtCodeFormat_xZkqqHx_iCmF_xHqqkZx_
			// _xZkqqHx_iPiJiKpKiJlLiClFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
			fciCur = m_fciCurExtCodeFormat;
//----- 06.11.22 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
		}
//----- 06.11.22 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
		//----- _xZkqqHx_iDhEiDeIiDjDiDgHiDfEiDeDiDfJiMhGiOfKjHhAiCmJiMlLiNnNiCmMiDhEiDeIiDjDiDgHiCpAiOoGjDlO_xHqqkZx_ -----
		FCSFontRec fntRec(fciCur);
//----- 06.11.22 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

//----- 02.08.17 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
//		// FCSFontRec_xZkqqHx_iNfMjBkCjBmMiCkJiCoH_xHqqkZx_FontID_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
//		foidFont = g_pEnv->FindNearestSFont(fntRec);
//----- 02.08.17 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
		// _xZkqqHx_iOhHjCoIiCmMjFlGiOjKiCkKjBkOiClHiCoJ_xHqqkZx_Charset_xZkqqHx_iCmMiPfHiNiHiCpAiOoGjDlOiBeC_xHqqkZx_
		WORDVector vCharSet;
		FFUnicodeToCharSet(vCharSet, wChar, fntRec.GetCharSet());
		// FCSFontRec_xZkqqHx_iNfMjBkCjBmMiCkJiCoH_xHqqkZx_FontID_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
		foidFont = g_pEnv->FindNearestSFont(fntRec, &vCharSet);
//----- 02.08.17 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
		// _xZkqqHx_jGlDiCkCiPoKiNiHiCmNjDgPjIfOiClHiCoJiBeC_xHqqkZx_
		if (foidFont == FD_S_FONT_UNSPECIFY)
			g_pDoc->CmdInsert1SFont(foidFont, fntRec);

		if (foidFont != foidCurFont || wCurOffset != fciCur.wOffset)
		//----- _xZkqqHx_iMlLiNnNiCmMiDhEiDeIiDjDiDgHiCmGiInJiCmIiCoJiPoKiNiHiBeBiDhEiDeIiDjDiDgHiNfIjAfGiPiIjHjNiCpAiNhDiCkE_xHqqkZx_ -----
		{
			foidCurFont = foidFont;
			wCurOffset = fciCur.wOffset;
			// _xZkqqHx_jFfHiPiAjCgMiCmM_xHqqkZx_Zoom_xZkqqHx_iCmF_xHqqkZx_logFont_xZkqqHx_iCpAjAnNjCoIiBeC_xHqqkZx_
			g_pEnv->GetSFontRec(foidFont)->ReqInit(logFont, 0.0, wCurOffset);
// 02.09.10 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ (_xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkC_xHqqkZx_)
			wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
			atDC.SetFont(&logFont);
		}

		if (wChar == WCH_LF || wChar == WCH_CR)
		//----- _xZkqqHx_iJpMiNhDiDfCiBfLiDgIiCmMiPoKiNiHiBeCiJpMiNhDiPiIjHjNiCpAiNhDiCkE_xHqqkZx_ -----
		{
			//----- FCEditChar_xZkqqHx_iCpAiPiJiKpKiJlL_xHqqkZx_ -----
			rc.m_wChar   = FDRCH_RETURN;
			rc.m_foidFont = foidFont;
			rc.Overread(fciCur);
			rc.m_mmfWidth = FDWR_RETURN_WIDTH;
			rc.m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
			rc.m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
			rc.m_mmfPreSpace = 0.0;
			rc.m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
			vWorkChar.push_back(rc);
			// _xZkqqHx_jFlGiOjKjHpBjBhNjDpMiPiIjHjNiBeCiNhDiCmMiNmEiMhGiOfKiImKjChFiCoAiOoGjDlOiBeC_xHqqkZx_
			if (lLineCalcFrom < 0)
				lLineCalcFrom = MCmdInsertText(vWorkChar, &tliCurFormat);
			else
				(void)MCmdInsertText(vWorkChar, &tliCurFormat);
			vWorkChar.clear();

			bLineTop = TRUE;	// _xZkqqHx_iOjPiCmMjFlGiOjKiCmNiNhDjDkKiCmGiCmIiCoJiClNiCnP_xHqqkZx_.
		} else
		if (wChar == WCH_SPC || wChar == WCH_TAB)
		//----- _xZkqqHx_iLpDjEjCiBeBiDfOiDhFiCmMiPoKiNiH_xHqqkZx_ -----
		{
			//----- FCEditChar_xZkqqHx_iCpAiPiJiKpKiJlL_xHqqkZx_ -----
			rc.m_wChar		= wChar;
			rc.m_foidFont	= foidFont;
			rc.Overread(fciCur);
			// _xZkqqHx_iLpDjEjCiCmMjFfHiPiAjFjNiCpAiOoGjDlOiBjFjAnNjCoIiBeCiDfOiDhFiCmMiPoKiNiHiCmNiJlMjAnNjCoIiBeC_xHqqkZx_
			rc.m_mmfWidth	= g_pEnv->GetSFontRec(rc.m_foidFont)->GetStdSpaceWidth();
			rc.m_mmfAbcA	= 0.0;
			rc.m_mmfAbcC	= 0.0;
			rc.m_mmfPreSpace= 0.0;
			rc.m_byCrossStat= FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
			vWorkChar.push_back(rc);
		} else
		{
			// _xZkqqHx_jFlGiOjKiBgJiDfCiBfLiDgI_xHqqkZx_wChar_xZkqqHx_iBgKiCmMjFjNiCpAiOoGjDlOiBeC_xHqqkZx_
			ABC abc;
// 02.09.10 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ (_xZkqqHx_iDfOiDeDiMoKiCmIiCmHiCmFiBeBjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkC_xHqqkZx_)
//			atDC.GetCharABCWidth(wChar, abc);
			atDC.GetCharABCWidth(wChar, abc, wCodePage);
			//----- FCEditChar_xZkqqHx_iCpAiPiJiKpKiJlL_xHqqkZx_ -----
			rc.m_wChar   = wChar;
			rc.m_foidFont = foidFont;
			rc.Overread(fciCur);
			rc.m_mmfWidth = static_cast<fmmetol>(lg2mm(abc.abcA + abc.abcB + abc.abcC));
			rc.m_mmfAbcA = static_cast<fmmetol>(lg2mm(abc.abcA));
			rc.m_mmfAbcC = static_cast<fmmetol>(lg2mm(abc.abcC));
			rc.m_mmfPreSpace = 0.0;
			rc.m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
			vWorkChar.push_back(rc);
		}
	}
	if (!vWorkChar.empty())
	{
		// _xZkqqHx_jFlGiOjKjHpBjBhNjDpMiPiIjHjNiBeCiNhDiCmMiNmEiMhGiOfKiImKjChFiCoAiOoGjDlOiBeC_xHqqkZx_
		if (lLineCalcFrom < 0)
			lLineCalcFrom = MCmdInsertText(vWorkChar, &tliCurFormat);
		else
			(void)MCmdInsertText(vWorkChar, &tliCurFormat);
	}
	// Zoom_xZkqqHx_iCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_CalcLineBelow _xZkqqHx_iCkKiJgFiLlPiCpAiOpDiCkPiCoJiClNiCnPiBeBjAoGiCmJiBeC_xHqqkZx_
	g_->dZoom = dZoom;
	// _xZkqqHx_iDeHiDgGiDeCiDfOiPiJiKpKiJlLiBeC_xHqqkZx_
	m_richpEditCtrl->Clear();
	// _xZkqqHx_jBhNjDpMiClDiCoKiClNiImKjChFiCkJiCoHiJlKiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
	CalcLineBelow(lLineCalcFrom);
	m_mmCaretX = RepositionCaret();
	// _xZkqqHx_iNmEjFgAiJoGiBeC_xHqqkZx_
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();

} while (FALSE);
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();
} // CFCWndRichEdit::OnPasteAsRtf.

//----- 05.07.10 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CanPasteAsText
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIjCiGiCmMiDgFiDeMiDfIiDgHiCpAiBeBjFiBjCmKiCmMiDgFiDeMiDfIiDgHiCmGiClFiCmEiBeB_xHqqkZx_
// *			_xZkqqHx_jDfMiCoIjFhEiCkPiCoJiClBiCmGiCkKiPgPjHiIiCoJiCkJiCpAjClCiCnHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iJmCjEfMiCmIiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.04 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//BOOL CFCWndRichEdit::CanPasteAsText () const
//{
//	if (!FFCanEditDocument()) return FALSE;
//	// _xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmJiCkAiCoJiCkJiCmHiCkEiCkJiCpAjClCiCnHiCoJiBeC_xHqqkZx_
//	return ::IsClipboardFormatAvailable(CF_TEXT);
//} // CFCWndRichEdit::CanPasteAsText.
//----- 05.07.10 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnPasteAsText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIjCiGiCmMiDgFiDeMiDfIiDgHiCpAiBeBjFiBjCmKiCmMiDgFiDeMiDfIiDgHiCmGiClFiCmEiBeB_xHqqkZx_
 *			_xZkqqHx_jDfMiCoIjFhEiCkPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	dwFormat	:_xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeC_xHqqkZx_CF_TEXT_xZkqqHx_iCkJ_xHqqkZx_
 *						 CF_UNICODETEXT_xZkqqHx_iCmMiCkCiClIiCoKiCkJiCpAiOhHjCoIiCmFiCkLiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.11.04 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnPasteAsText (DWORD dwFormat)
{
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCpAiOoGiCoIiPgPiClH_xHqqkZx_ -----
	long lSelFrom, lSelTo;
	GetSelectNormal(lSelFrom, lSelTo);
	if (lSelFrom == lSelTo)
		lSelFrom = lSelTo = GetCurIndex();
	//----- _xZkqqHx_iDeOiDiKiDgCiDhGiDhLiBfLiDgIiCkJiCoHiDgFiDeMiDfIiDgHiCpAiOoGiCoIiPgPiClH_xHqqkZx_ -----
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (_xZkqqHx_jCiGiNjBiMoKiCmMiDgFiDeMiDfIiDgHjDfMiCoIjFhEiCkPiCkKiCkEiCnMiCkNiCkCiCkJiCmIiCkC_xHqqkZx_)-----
//	WString wstrText;
//	CEdit edit;
//	edit.Create(WS_CHILD|ES_MULTILINE|ES_AUTOHSCROLL|ES_AUTOVSCROLL, CRect(0,0,10,10), AfxGetMainWnd(), 100);
//	edit.SetSel(0, 0);
//	edit.Paste();
//	FFGetWindowText(&edit, wstrText);
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (_xZkqqHx_jCiGiNjBiMoKiCmMiDgFiDeMiDfIiDgHjDfMiCoIjFhEiCkPiCkKiCkEiCnMiCkNiCkCiCkJiCmIiCkC_xHqqkZx_)-----
	//----- _xZkqqHx_iDeHiDgGiDeCiDgCiDgHiDfCiDjDiDgHiDiNiBfLiDiLiCmJiDhJiBfLiDfIiDgH_xHqqkZx_ -----
	// _xZkqqHx_iDhJiBfLiDfIiDgHiPiIjHjNiBeC_xHqqkZx_
	m_richpEditCtrl->PasteSpecial(m_fciCurStdCodeFormat, dwFormat);
	if (m_richpEditCtrl->IsEmpty()) return;
	// wchar_t_xZkqqHx_iMfOiCmMiDgFiDeMiDfIiDgHiCpAiOoGjDlOiClHiCoJiBeC_xHqqkZx_
	WString wstrText;
	m_richpEditCtrl->GetText(wstrText);
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (_xZkqqHx_jCiGiNjBiMoKiCmMiDgFiDeMiDfIiDgHjDfMiCoIjFhEiCkPiCkKiCkEiCnMiCkNiCkCiCkJiCmIiCkC_xHqqkZx_)-----
	// _xZkqqHx_jBeJjBpAiCpAiJpAiPjMiClHiCoJiBeC_xHqqkZx_
	SetSelect(-1, -1);
//----- 02.08.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ (_xZkqqHx_jFhDjHhG_xHqqkZx_)-----
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
//	DrawSelect();
//----- 02.08.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ (_xZkqqHx_jFhDjHhG_xHqqkZx_)-----
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();
	// _xZkqqHx_iDgFiDeMiDfIiDgHiCpAjChFiKlHiClHiCoJiBeC_xHqqkZx_
	MCmdReplaceText(lSelFrom, lSelTo, wstrText);
	// _xZkqqHx_iNhDiCmMiNmEiMhGiOfKiBeC_xHqqkZx_
	CalcLineAll();
	m_mmCaretX = RepositionCaret();
	SendRgnRedraw();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();
//----- 01.11.05 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
//	DrawSelect();
//----- 01.11.05 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::OnPasteAsText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UpdateFullScreenMode
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhCiDiFiBfLiBeBiDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJiCpAjFmPiNfIiClFiBeBjBfDiJoGjGmKiDiCiBfLiDgIiCmGjCmKiPoNiDiCiBfLiDgIiCmM_xHqqkZx_
 *			_xZkqqHx_jAnIiCoIjBnGiCkGiCpAiNhDiCkEiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	bFullScreen	:_xZkqqHx_jBfDiJoGjGmKiDiCiBfLiDgIiCmJiInKiNhDiClHiCoJiCmGiCkLiCmN_xHqqkZx_ TRUE _xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBfDiJoGjGmKiDiCiBfLiDgIiCmJiInKiNhDiClHiCoJiCmGiCkLiCmJiCmNiBeBiDhCiDiFiBfLiBeBiDeFiDeCiDjDiDgIiDeFjDjJiCpAjFmPiNfIiClHiCoJ_xHqqkZx_
 *			_xZkqqHx_iCmMiCmFiBeBiClLiCmMiPoOjFpBiCmMjFnLjBlGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.26 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UpdateFullScreenMode (BOOL bFullScreen)
{
	if (bFullScreen)
	{
		//----- _xZkqqHx_iDhCiDiFiBfLiCmMiPoOjFpBiBeBiDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJjDjJiCmMiDgPiDgCiDeOiDeBiDgCiDhG_xHqqkZx_ -----

//----- 05.02.20 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		// _xZkqqHx_iClBiCmMiDeFiDeCiDjDiDgIiDeFiCmMiDfEiDeDiDfJiBeC_xHqqkZx_
//		m_mmrtWindowOrig = m_mmrtWindow;
//		// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDjEhKjHpBiBeC_xHqqkZx_
//		m_vmmptPolyOrig = m_vmmptPoly;
//----- 05.02.20 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		// _xZkqqHx_iDhJiDjDjAeGiBeC_xHqqkZx_
		m_scidPenBackSColorOrig = m_scidPenBackSColor;
		// _xZkqqHx_iJoGjGmKiCmMjFgAiJoGjHmMiIoGiCpAiOoGjDlOiBeC_xHqqkZx_
		DBLRect mmrtClient;
		g_pView->GetClientRectMM(mmrtClient);
		// _xZkqqHx_iMlLiNnNiCmMiDhCiDiFiBfLiCmMjCiGjAfDiNmAjFfHiCpAiLeMiJkPiBeC_xHqqkZx_
		m_mmptViewCenterOrig.SetPoint(mmrtClient.CenterPoint());
		// _xZkqqHx_iMlLiNnNiCmMiDfJiBfLiDiAjCgMiCpAiLeMiJkPiBeC_xHqqkZx_
		m_lZoom256Orig = g_->lZoom256;

		//----- _xZkqqHx_iDhCiDiFiBfLiBeBiDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJjDjJiCmMjFmPiNfI_xHqqkZx_ -----
		DBLRect mmrtSheetEx = g_pEnv->GetSheetRectEx();
		DBLPoint mmptCenter(mmrtSheetEx.left + (mmrtSheetEx.Width() / 2.0),
							mmrtSheetEx.top + (mmrtClient.Height() / 2.0));
		m_scidPenBackSColor = FD_S_COLOR_TRANSPARENT;
		// _xZkqqHx_iDfGiBfLiDgHiCmMiNlGiPoDiCpAjAnNjCoIiBeCiClBiClBiCpAjCiGjAfDiCmJiDfJiBfLiDiAiClHiCoJiBeC_xHqqkZx_
		g_pView->SetLastPoint(mmptCenter);
		// _xZkqqHx_iDhCiDiFiBfLiCpAjFfHiPiAjCgMiBgJ_xHqqkZx_256 = _xZkqqHx_iCfAjEhLiBgKiCmJiDfJiBfLiDiAiClHiCoJiBeCjDkPiOjOiCmJiNmEjFgAiJoGiClDiCoKiCoJiBeC_xHqqkZx_
		// _xZkqqHx_jHfMiCnPiBeB_xHqqkZx_256_xZkqqHx_iCmGiInJiCmIiCoJjCgMiCpAjAnNjCoIiClFiCmEiCkIiCkJiCmIiCkCiCmGiBeBiImIiJlKiCkKjDkOiNoMiClFiCmIiCkCiBeC_xHqqkZx_
		g_->lZoom256 = 1;
		g_pView->SendMessage(WM_USER_SET_ZOOM256, TRUE, 256);
		// _xZkqqHx_iDeHiDgGiDeCiDfOiDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJiCmMiMhGiOfKiBeC_xHqqkZx_
		g_pView->GetClientRectMM(mmrtClient);
		mmrtClient.bottom = mmrtSheetEx.bottom;
		//----- _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJiCkK_xHqqkZx_ FDWIN_MAX _xZkqqHx_iCpAiJhKiCkGiCmIiCkCiCoGiCkEiCmJjFoCjAlD_xHqqkZx_ -----
		CRect dvrt = mm2lg(mmrtClient);
		g_pView->LPtoDP(dvrt);
		if (FDWIN_MAX < dvrt.bottom)
		{
			dvrt.bottom = FDWIN_MAX;
			g_pView->DPtoLP(dvrt);
			mmrtClient = lg2mm(dvrt);
		}
		// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiDeHiDgGiDeCiDfOiCpAiDiKiDfEiDeDiDfJiBjFiInKjDkOiBeC_xHqqkZx_
		MoveWindowMM(mmrtClient);
		// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAjAnNjCoIiBeC_xHqqkZx_
		m_vmmptPoly.resize(5);
		DBLRect(0, 0, mmrtClient.Width(), mmrtClient.Height()).
			Get5Polygon(m_vmmptPoly.begin());
//----- 02.05.30 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
//		// _xZkqqHx_jIfPjHjNiNmAjFfHiCmMiDhMiDiKiDfDiDjDiCmJiDfCiDhDiBfLiBeC_xHqqkZx_
//		mm2lg(m_vlgptPoly, m_vmmptPoly);
//----- 02.05.30 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
	} else
	{
		//----- _xZkqqHx_iDhCiDiFiBfLiBeBiDeFiDeCiDjDiDgIiDeFiDfEiDeDiDfJjDjJiCmMjFmPiNfI_xHqqkZx_ -----
		// _xZkqqHx_jFjEjFgJiImKjChFiCpAiNmFiMoDiCmMiDeOiDiKiDgCiDeOiImKjChFiCmJjAnNjCoIiBeCiClBiClBiCpAjCiGjAfDiCmJiDfJiBfLiDiAiClHiCoJiBeC_xHqqkZx_
		g_pView->SetLastPoint(m_mmptViewCenterOrig);
		// _xZkqqHx_iDhCiDiFiBfLiCpAiMlDiCmMjCgMiCmJiDfJiBfLiDiAiClHiCoJiBeCjDkPiOjOiCmJiNmEjFgAiJoGiClDiCoKiCoJiBeC_xHqqkZx_
		// _xZkqqHx_jHfMiCnPiBeB_xHqqkZx_m_lZoom256Orig_xZkqqHx_iCmGiInJiCmIiCoJjCgMiCpAjAnNjCoIiClFiCmEiCkIiCkJiCmIiCkCiCmGiBeBiImIiJlKiCkKjDkOiNoMiClFiCmIiCkCiBeC_xHqqkZx_
		g_->lZoom256 = m_lZoom256Orig + 1;
		g_pView->SendMessage(WM_USER_SET_ZOOM256, TRUE, m_lZoom256Orig);
		// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAjAnNjCoIiBeC_xHqqkZx_
		m_vmmptPoly = m_vmmptPolyOrig;
//----- 02.05.30 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
//		// _xZkqqHx_jIfPjHjNiNmAjFfHiCmMiDhMiDiKiDfDiDjDiCmJiDfCiDhDiBfLiBeC_xHqqkZx_
//		mm2lg(m_vlgptPoly, m_vmmptPoly);
//----- 02.05.30 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
		// _xZkqqHx_iDhJiDjDjAeGiBeC_xHqqkZx_
		m_scidPenBackSColor = m_scidPenBackSColorOrig;
		// _xZkqqHx_iDeFiDeCiDjDiDgIiDeFiDeHiDgGiDeCiDfOiCpAiDiKiDfEiDeDiDfJiBjFiInKjDkOiBeC_xHqqkZx_
		MoveWindowMM(m_mmrtWindowOrig);
	}
} // CFCWndRichEdit::UpdateFullScreenMode.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::NextChar
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOjPiCmMjFlGiOjKiCmJjBjHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	:_xZkqqHx_iNhDjCgMiCpAiOhHjCoIiClFiBeBiNhDjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *			lChar	:_xZkqqHx_jFlGiOjKjCgMiCpAiOhHjCoIiClFiBeBjFlGiOjKjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jBjHiCoJiClBiCmGiCkKiCmFiCkLiClNiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeBiCmFiCkLiCmIiCkJiCmBiClNiPoKiNiHiCmN_xHqqkZx_ FALSE_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::NextChar (long& lLine, long& lChar) const
{
	int iC = 1;
	for (; lLine < m_vEditLine.size(); lLine++)
	{
		for (; lChar < m_vEditLine[lLine].m_vEditChar.size(); lChar++)
		{
			if (m_vEditLine[lLine].m_vEditChar[lChar].m_wChar == FDRCH_CONTINUE) break;
			if (iC-- <= 0) return TRUE;
		}
		lChar = 0;
	}
	return FALSE;
} // CFCWndRichEdit::NextChar.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::IndexToCharPos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiNhDiBeFjHpBiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	:_xZkqqHx_iNhDiCpAjFnEiClH_xHqqkZx_.
 *			lChar	:_xZkqqHx_jHpBiCpAjFnEiClH_xHqqkZx_.
 *			lIndex	:_xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiClHiCoJ_xHqqkZx_.
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.04 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::IndexToCharPos (long& lLine, long& lChar, long lIndex) const
{
	long	lNum;
	for (lLine = 0; lLine < m_vEditLine.size(); lLine++)
	{
		if (m_vEditLine[lLine].m_vEditChar.back().m_wChar == FDRCH_RETURN)
			lNum = m_vEditLine[lLine].m_vEditChar.size();
		else
			lNum = m_vEditLine[lLine].m_vEditChar.size() - 1;

		if (lIndex < lNum)
		{
			lChar = lIndex;
			return;
		}
		lIndex -= lNum;
	}
} // CFCWndRichEdit::IndexToCharPos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCaretChar
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiDeKiDiMiDgCiDgHiImKjChFiCmMjFlGiOjKiCpAiOoGjDlOiClHiCoJiBeCiMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCmMjFlGiOjK_xHqqkZx_
 *			_xZkqqHx_iCmGiCmNiMmAiCoHiCmIiCkCiBeCiDeKiDiMiDgCiDgHiInKjDkOjClMiMoDiCmMiBeBiMlLiNnNiCmMiDhEiDeIiBfLiDhNiDgCiDgHiOoGjDlOiCmJ_xHqqkZx_
 *			_xZkqqHx_iOgHjHhAiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jFlGiOjKiDiMiDfCiBfLiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.02.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
const FCEditChar& CFCWndRichEdit::GetCaretChar () const
{
	if (0 <= m_lSelFrom)
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		long lSelFrom, lSelTo;
		GetSelectNormal(lSelFrom, lSelTo);
		if (lSelTo == m_lCurIndex)
		//----- _xZkqqHx_iDeKiBfLiDfMiDiLiCkKjBeJjBpAjEmNiImNiCmMiNmFiMoDiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiMoDiCmMjFlGiOjKiBeC_xHqqkZx_
			return GetChar(lSelTo - 1);
		} else
		{
			// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiPiJiCmMjFlGiOjKiBeC_xHqqkZx_
			return GetChar(lSelFrom);
		}
	} else if (m_lCurIndex == 0)
	//----- _xZkqqHx_jClMjBePiCmJjFlGiOjKiCkKjGlDiCkCiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_jClMjBePiCmJjFlGiOjKiCkKjGlDiCkCiPoKiNiHiCmNjClMiMoDiCmMjFlGiOjKiCpAiOoGjDlOiBeC_xHqqkZx_
		return GetChar(m_lCurIndex);
	} else
	//----- _xZkqqHx_jClMjBePiCmJjFlGiOjKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		const FCEditChar& rc = GetChar(m_lCurIndex - 1);
		if (rc.m_wChar == FDRCH_RETURN)
			return GetChar(m_lCurIndex);
		else
			return rc;
	}
} // CFCWndRichEdit::GetCaretChar.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcCaret
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiImKjChFiCkJiCoHiDeKiDiMiDgCiDgHiCmMiNmAjFfHiCmGjBoFiCkLiClDiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmX	: _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNlGiPoDiCmM_xHqqkZx_X_xZkqqHx_iNmAjFfH_xHqqkZx_(_xZkqqHx_iDhOiDiKiNmAjFfH_xHqqkZx_)
 *			mmY	: _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNlGiPoDiCmM_xHqqkZx_Y_xZkqqHx_iNmAjFfH_xHqqkZx_(_xZkqqHx_iDhOiDiKiNmAjFfH_xHqqkZx_)
 *			mmH	: _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNiCiClD_xHqqkZx_(_xZkqqHx_iDhOiDiKiNmAjFfH_xHqqkZx_)
 *************************************************************************/
void CFCWndRichEdit::CalcCaret (mmetol& mmX, mmetol& mmY, mmetol& mmH) const
{
	long lCurLine, lCurChar;
	GetCurCharPos(lCurLine, lCurChar);

//----- 01.02.12 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	mmH = m_vEditLine[lCurLine].m_mmfTMHeight + m_vEditLine[lCurLine].m_mmfTMExternalLeading;
//	mmY = m_vEditLine[lCurLine].m_mmY;
//----- 01.02.12 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	const FCEditChar& eChar = GetCaretChar();
	const mmetol mmTMAscent = g_pEnv->GetSFontRec(eChar.m_foidFont)->GetAscent(eChar.m_wOffset);
	const mmetol mmTMDescent = g_pEnv->GetSFontRec(eChar.m_foidFont)->GetDescent(eChar.m_wOffset);
	const mmetol mmTMExternalLeading = g_pEnv->GetSFontRec(eChar.m_foidFont)->
														GetExternalLeading(eChar.m_wOffset);
	// _xZkqqHx_iNhDiCmMiDhIiBfLiDfIiDiJiDeDiDjDiCkJiCoHiDhEiDeIiDjDiDgHiCmM_xHqqkZx_mmTMAscent_xZkqqHx_iCpAiIpIiCkCiClNiImKjChFiCpAiDeKiDiMiDgCiDgHiImKjChFiCmJiOhHjCoIiBeC_xHqqkZx_
	mmY = m_vEditLine[lCurLine].m_mmY + m_vEditLine[lCurLine].m_mmfTMAscent - mmTMAscent;
	// _xZkqqHx_iDhEiDeIiDjDiDgHiCmMiNiCiClDiCpAiDeKiDiMiDgCiDgHiNiCiCmGiClFiCmEjAnNjCoIiBeC_xHqqkZx_
	mmH = mmTMAscent + mmTMDescent + mmTMExternalLeading;
//----- 01.02.12 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

	if (m_vEditLine[lCurLine].m_byLineType == FDRC_LT_HEAD)
		mmX = m_mmMarginL + m_vEditLine[lCurLine].m_mmStartIndent;
	else
		mmX = m_mmMarginL + m_vEditLine[lCurLine].m_mmStartIndent +
				m_vEditLine[lCurLine].m_mmOffset;
	long l;
	for (l = 0; l < lCurChar; l++)
	{	
		if (m_vEditLine[lCurLine].m_vEditChar.size() <= l)
		//----- lCurChar_xZkqqHx_iCkKiNhDiCmMjFlGiOjKjAjEiCoGiCoIiCoAjBoFiCkLiCkCiPoKiNiH_xHqqkZx_ -----
		{
			l--;
			break;
		}
		mmX += m_vEditLine[lCurLine].m_vEditChar[l].m_mmfWidth +
					m_vEditLine[lCurLine].m_vEditChar[l].m_mmfPreSpace +
					tw2mm(m_vEditLine[lCurLine].m_vEditChar[l].m_nAfterSpace);
	}
	// _xZkqqHx_jFlGiOjKjBePiDfIiDhJiBfLiDfIiCpAiJmBiOfKiBeC_xHqqkZx_
	mmX += m_vEditLine[lCurLine].m_vEditChar[l].m_mmfPreSpace;

//----- 01.02.09 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	// _xZkqqHx_iDeKiDiMiDgCiDgH_xHqqkZx_X_xZkqqHx_iImKjChFiCkKjFiJiCmJiCmIiCoJiPoKiNiHiCoAjHeMiCoIjDlOiCoJiBgJiNmFiPiJiCmMjFlGiOjKiCmM_xHqqkZx_AbcA_xZkqqHx_iCkKjBoFiCkLiCkCiPoKiNiHiBgK_xHqqkZx_
//	// _xZkqqHx_iDeKiDiMiDgCiDgH_xHqqkZx_X_xZkqqHx_iImKjChFiCkKjFiJiCmJiCmIiCoJiCmGiBeBjFmPiKlHiDeFiDeCiDjDiDgIiDeFiCkKjAlDiPoNiCmJjFfMiOkGiClDiCoKiCmIiCkCiBeC_xHqqkZx_
//	// _xZkqqHx_iDeKiDiMiDgCiDgHiCmMjFfMiOkGiCoAiClDiCoKiCmIiCkCiBeC_xHqqkZx_
//	if (mmX < 0) mmX = 0.0;
//----- 01.02.09 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	// _xZkqqHx_iDeKiDiMiDgCiDgH_xHqqkZx_X_xZkqqHx_iImKjChFiCkKjFiJiCmJiCmIiCoJiPoKiNiHiCoAjHeMiCoIjDlOiCoJiBgJiNmFiPiJiCmMjFlGiOjKiCmM_xHqqkZx_AbcA_xZkqqHx_iCkKjBoFiCkLiCkCiPoKiNiHiBgK_xHqqkZx_
	// _xZkqqHx_iDeKiDiMiDgCiDgH_xHqqkZx_X_xZkqqHx_iImKjChFiCkKjFiJiCmJiCmIiCoJiCmGiBeBjFmPiKlHiDeFiDeCiDjDiDgIiDeFiCkKjAlDiPoNiCmJjFfMiOkGiClDiCoKiCmIiCkCiBeC_xHqqkZx_
	// _xZkqqHx_iDeKiDiMiDgCiDgHiCmMjFfMiOkGiCoAiClDiCoKiCmIiCkCiBeC_xHqqkZx_
	//----- _xZkqqHx_iJeFjBkEiCmMiMmAjDhIiImKjChFiCpAiMhGiOfK_xHqqkZx_ -----
	const mmetol mmRightLimit = m_mmrtWindow.Width() -
							m_vEditLine[lCurLine].m_mmRightIndent - m_mmMarginR;
	//----- _xZkqqHx_iNlGjBkEiCmMiMmAjDhIiImKjChFiCpAiMhGiOfK_xHqqkZx_ -----
	mmetol mmLeftLimit;
	if (m_vEditLine[lCurLine].m_byLineType == FDRC_LT_HEAD)
		mmLeftLimit = m_mmMarginL + m_vEditLine[lCurLine].m_mmStartIndent;
	else	// FDRC_LT_CONTINUE.
		mmLeftLimit = m_mmMarginL + m_vEditLine[lCurLine].m_mmStartIndent +
					m_vEditLine[lCurLine].m_mmOffset;
	if (mmX < mmLeftLimit) mmX = mmLeftLimit;
	if (mmRightLimit < mmX) mmX = mmRightLimit;
//----- 01.02.09 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::CalcCaret.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RepositionCaret
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiImKjChFiCmJiCkAiCoNiClJiCmEiBeBiDeKiDiMiDgCiDgHiCpAiNmEjFfMiOkGiClHiCoJiBeCiMlLiNnNiCmM_xHqqkZx_
 *			_xZkqqHx_jFlGiOjKiImKjChFiCpAiInKjDkOiClFiClNiMoDiCmJiClBiCmMiKnGjAjEiCpAiOmAiNhDiClHiCoJ_xHqqkZx_.
 *			m_mmCaretX_xZkqqHx_iCpAiNmEiMhGiOfKiClHiCoJ_xHqqkZx_.
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDeKiDiMiDgCiDgHiCmM_xHqqkZx_X_xZkqqHx_iNmAjFfH_xHqqkZx_.
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.09.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
mmetol CFCWndRichEdit::RepositionCaret ()
{
	//----- m_mmCaretX_xZkqqHx_iCpAiMhGiOfKiClHiCoJ_xHqqkZx_ -----
	mmetol	mmX, mmY, mmH;
	CalcCaret(mmX, mmY, mmH);

// 05.03.01 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (IsWindowVisible())
	if (::IsWindow(m_hWnd) && IsWindowVisible())
	//----- Window_xZkqqHx_iCkKjFfMiOkGiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
	{
		//----- _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiPmBiLiOiClHiCoJ_xHqqkZx_ -----
// 02.05.31 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)
//		HideCaret();
		if (GetFocus() == this) HideCaret();
		::DestroyCaret();
		//----- _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiNoMjAkMiClHiCoJ_xHqqkZx_ -----
		CreateSolidCaret(2, mm2lg(mmH));
		SetCaretPos(CPoint(mm2lg(mmX), mm2lg(mmY)));
		// _xZkqqHx_iDeKiDiMiDgCiDgHiCkKiBeBjAhNiMgAiCmMiJlKiCmJiCmNiCnNiPgPiClFiClNiOjOiCmNjFfMiOkGiClFiCmIiCkCiBeC_xHqqkZx_
//----- 02.05.31 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
//		if (mmY + mmH <= m_mmrtWindow.Height() - m_mmMarginB) ShowCaret();
//----- 02.05.31 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
//----- 05.02.20 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		if (mmY + mmH <= m_mmrtWindow.Height() - m_mmMarginB)
//			if (GetFocus() == this) ShowCaret();
//----- 05.02.20 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		// _xZkqqHx_iIoKjEnEiJlKiCmMiNhDiCmFiDeKiDiMiDgCiDgHiCkKiPmBiCkGiCoJiPoKiNiHiCkKiCkAiCoJiClNiCnPiBeB_xHqqkZx_mmY+mmH_xZkqqHx_iCkJiCoH_xHqqkZx_1mm_xZkqqHx_iIpIiCkCiCmEjElLjCoIiClHiCoJiBeC_xHqqkZx_
		if (mmY + mmH - 1 <= m_mmrtWindow.Height() - m_mmMarginB)
			if (GetFocus() == this) ShowCaret();
//----- 05.02.20 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
//----- 02.05.31 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
		// HRuler_xZkqqHx_iCmJiDhNiBfLiDeKiBfLjAnNjCoIiBeCiDeHiDgGiDeCiDfOjFfMiOkGiOjOiCmFiCmIiCkCiCmGjAlDiPoNjDkOiNoMiClFiCmIiCkCiBeC_xHqqkZx_
		long lLine, lChar;
		GetCurCharPos(lLine, lChar);
		if (FFGetMainWnd()->HRuler() != NULL)
		{
			FFGetMainWnd()->HRuler()->Set3Indents(m_vEditLine[lLine].m_mmStartIndent,
											m_vEditLine[lLine].m_mmOffset,
											m_vEditLine[lLine].m_mmRightIndent);
			FFGetMainWnd()->HRuler()->SetTabs(m_vEditLine[lLine].m_mmvTabs);
		}
	}
	return mmX;
} // CFCWndRichEdit::RepositionCaret.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CharPosToIndex
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNhDjEnEiNiGiCmGjFlGiOjKiImKjChFiCkJiCoHiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOfKiPgPiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	:_xZkqqHx_iNhDjEnEiNiGiBeC_xHqqkZx_
 *			lChar	:_xZkqqHx_jFlGiOjKiImKjChFiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	lLine_xZkqqHx_iCmN_xHqqkZx_0_xZkqqHx_iImIiPoDiBeB_xHqqkZx_m_vEditLine.size()_xZkqqHx_jGkCjGjOiBeBiClNiClOiClFiDeDiDjDiDgGiDgCiDeOiDfI_xHqqkZx_
 *			_xZkqqHx_iDfEiDeDiDfJiCpAiLiBiCnPiCoJiOjOiCmN_xHqqkZx_(m_vEditLine.size(), 0)_xZkqqHx_iCpAiOhHjCoIiClFiCmEjHmHiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiCmJiJpAjAoAjCmHiJmBiBeC_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::CharPosToIndex (long lLine, long lChar) const
{
	long lCurIndex = 0;
	long	l;
	for (l = 0; l < lLine; l++)
	{
		if (m_vEditLine[l].m_vEditChar.back().m_wChar == FDRCH_RETURN)
			lCurIndex += m_vEditLine[l].m_vEditChar.size();
		else
			lCurIndex += m_vEditLine[l].m_vEditChar.size() - 1;
	}
	return lCurIndex + lChar;
} // CFCWndRichEdit::CharPosToIndex.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CoordToLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	Y_xZkqqHx_iNmAjFfHjCgMiCkJiCoHiBeBiClLiCmMiNmAjFfHiImKjChFiCmMiNhDiCmJjFmPiKlHiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmy	:Y_xZkqqHx_iNmAjFfHiCpAiOhHjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iNhDjCgMiCpAjFnEiClHiBeC_xHqqkZx_0_xZkqqHx_iNhDiCoGiCoI_xHqqkZx_Y_xZkqqHx_iCkKiPoDiCmIiCoHiCmO_xHqqkZx_ -1_xZkqqHx_iBeBiNmFjBoFiNhDjCgMiCoGiCoI_xHqqkZx_Y_xZkqqHx_iCkKiJlKiCmIiCoHiCmO_xHqqkZx_
 *			_xZkqqHx_iNhDiDfEiDeDiDfJiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::CoordToLine (mmetol mmy) const
{
	// 0_xZkqqHx_iNhDiCoGiCoIiNmAjFfHiCkKiPoDiCmJiCkAiCoJiCmIiCoHiCmO_xHqqkZx_ -1 _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
	if (mmy < m_vEditLine.front().m_mmY) return -1;
	long lLn;
//----- 00.03.05 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	for (lLn = 0; lLn < m_vEditLine.size(); lLn++)
//	{
//		if (m_vEditLine[lLn].m_mmY <= mmy &&
//			mmy <= m_vEditLine[lLn].m_mmY + m_vEditLine[lLn].m_mmfTMHeight) break;
//	}
//----- 00.03.05 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	for (lLn = 0; lLn < m_vEditLine.size(); lLn++)
	{
//----- 01.01.29 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		if (mmy <= m_vEditLine[lLn].m_mmY + m_vEditLine[lLn].m_mmfTMHeight +
//					m_vEditLine[lLn].m_mmfTMExternalLeading +
//					tw2mm(m_vEditLine[lLn].m_nTwipLineAfter)) break;
//----- 01.01.29 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		if (mmy <= m_vEditLine[lLn].m_mmY + m_vEditLine[lLn].m_mmfTMHeight +
					m_vEditLine[lLn].m_mmfTMExternalLeading) break;
//----- 01.01.29 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
	}

//----- 00.03.05 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
	return lLn;
} // CFCWndRichEdit::CoordToLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CoordToGapX
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiCmMiBeBiOhHjCoIiClDiCoKiClNiNmAjFfHiCmJiNmFiCoAiLnPiCkCiDeNiDiDiDgCiDhGjCgMiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	:_xZkqqHx_iNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmx		:_xZkqqHx_iChHiNmAjFfHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDeNiDiDiDgCiDhGjCgMiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	mmx_xZkqqHx_iCmFiOhHjCoIiClDiCoKiClNiChHiNmAjFfHiCkKiBeBjFlGiOjKiCmMiKnEiCmMiDeNiDiDiDgCiDhGiCmMiCmHiClBiCmJiNmFiCoAiLnPiCkCiCkJiCpA_xHqqkZx_
 *			_xZkqqHx_iMhGiOfKiClFiCmEjFnEiClHiBeCiJlKiCmJiDeNiDiDiDgCiDhGjCgMiCmMjHoBiCpAiOkGiClHiBeC_xHqqkZx_
 *
 *			_xZkqqHx_iNhDiCkKiJpMiNhDiCmFiPeJiCoNiCoJiPoKiNiHiBeC_xHqqkZx_
 *			_xZkqqHx_iNhDjFlGiOjKjHpB_xHqqkZx_	_xZkqqHx_iBeAiCkAiBeAiCkCiBeAiCkEiBeAiCkGiBeAiJpM_xHqqkZx_
 *						_xZkqqHx_iBkKiBeAiBkKiBeAiBkKiBeAiBkKiBeAiBkK_xHqqkZx_
 *			_xZkqqHx_iDeNiDiDiDgCiDhGjCgM_xHqqkZx_	_xZkqqHx_iCePiBeAiCfAiBeAiCfBiBeAiCfCiBeAiCfD_xHqqkZx_
 *
 *			_xZkqqHx_iNhDiCkKiMhAjBlBiCmFiPeJiCoNiCoJiPoKiNiHiBeC_xHqqkZx_
 *			_xZkqqHx_iNhDjFlGiOjKjHpB_xHqqkZx_	_xZkqqHx_iBeAiCkAiBeAiCkCiBeAiCkEiBeAiCkGiBeAiMhA_xHqqkZx_
 *						_xZkqqHx_iBkKiBeAiBkKiBeAiBkKiBeAiBkKiBeAiBkK_xHqqkZx_
 *			_xZkqqHx_iDeNiDiDiDgCiDhGjCgM_xHqqkZx_	_xZkqqHx_iCePiBeAiCfAiBeAiCfBiBeAiCfCiBeAiCfD_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::CoordToGapX (long lLine, mmetol mmx) const
{
	const FCEditLine& eL = m_vEditLine[lLine];
	// _xZkqqHx_iNhDiCmJ_xHqqkZx_ FDRCH_CONTINUE/FDRCH_RETURN _xZkqqHx_iClFiCkJiCmIiCkCiPoKiNiHiCmN_xHqqkZx_ Gap = 0.
	if (eL.m_vEditChar.size() <= 1) return 0;
	mmetol mmR;		// _xZkqqHx_jFlGiOjKiCmMjCiGiKnEiNmAjFfHiBeC_xHqqkZx_
	if (eL.m_byLineType == FDRC_LT_HEAD)
		mmR = m_mmMarginL + eL.m_mmStartIndent;
	else
		mmR = m_mmMarginL + eL.m_mmStartIndent + eL.m_mmOffset;
//----- 99.11.20 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDhMiDiKiDfDiDjDiDfIiDeMiDiDiDjDiCmJiCoGiCoJiNlGjCfLiBhLiDhNiBfLiDfHiDjDiCkKjBoFiCkLiCkCiCmIiCoHiBeBiClLiCmBiClPiCpAjBeJiCnEiBeC_xHqqkZx_
//	if (mmR < eL.m_mmfHeadSpace) mmR = eL.m_mmfHeadSpace;
//----- 99.11.20 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// 0_xZkqqHx_jFlGiOjKjGnKiCmMjBePjHfNjEjCiCmGjFlGiOjKjFjNiCmMjElMjFkKiCpAiJmBiOfKiClHiCoJiBeC_xHqqkZx_
	mmR += eL.m_vEditChar[0].m_mmfPreSpace + (eL.m_vEditChar[0].m_mmfWidth / 2.0);

	if (mmx <= mmR) return 0;
	long lChar;
	for (lChar = 1; lChar < eL.m_vEditChar.size() - 1; lChar++)
	{
		// _xZkqqHx_iOgDiCoIiCmMjFlGiOjKjFjNjElMjFkKiCmGiBeBiOjPiCmMjFlGiOjKiCmMjBePjHfNjEjCiBjFjFlGiOjKjFjNjElMjFkKiCpAiJmBiOfKiClHiCoJiBeC_xHqqkZx_
		mmR += (eL.m_vEditChar[lChar - 1].m_mmfWidth / 2.0) +
				eL.m_vEditChar[lChar].m_mmfPreSpace +
				tw2mm(eL.m_vEditChar[lChar].m_nAfterSpace) +
				(eL.m_vEditChar[lChar].m_mmfWidth / 2.0);
		if (mmx <= mmR) break;
	}
	return lChar;
} // CFCWndRichEdit::CoordToGapX.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::JoinContLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	lLine_xZkqqHx_iCmFiOhHjCoIiClDiCoKiCoJiNhDiCmJiMhAjBlBiClHiCoJiNhDiCpAiBeB_xHqqkZx_lLine_xZkqqHx_iCmFiOhHjCoIiClDiCoKiCoJiNhDiCmMjFlGiOjK_xHqqkZx_
 *			_xZkqqHx_iCmGiClFiCmEjCmHiJmBiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	: _xZkqqHx_jAnKjBlBiCpAiKeKiOgOiClHiCoJiNhD_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::JoinContLine (long lLine)
{
#define CURLINE m_vEditLine[lLine]
#define NEXLINE m_vEditLine[lLine+1]

	// _xZkqqHx_iKeKiOgOiNhDiCmMiNmFiMoDiCkKiJpMiNhDiCmIiCoHiCmOjFjMiLeB_xHqqkZx_.
	if (CURLINE.m_vEditChar.back().m_wChar == FDRCH_RETURN) return;

	while (&NEXLINE != m_vEditLine.end() &&
			NEXLINE.m_byLineType == FDRC_LT_CONTINUE)
	{
		// _xZkqqHx_iKeKiOgOiNhDiCmMiNmFiMoDiCmMiMhAjBlBjFlGiOjKiCpAiNoNiPjM_xHqqkZx_.
		CURLINE.m_vEditChar.pop_back();
		// _xZkqqHx_iKeKiOgOiNhDiCmJiOjPiCmMiNhDiCmMjBfDiCmEiCmMjFlGiOjKiCpAjCmHiJmB_xHqqkZx_.
		CURLINE.m_vEditChar.insert(	CURLINE.m_vEditChar.end(),
									NEXLINE.m_vEditChar.begin(),
									NEXLINE.m_vEditChar.end());
		// _xZkqqHx_iOjPiCmMiNhDiCpAiNoNiPjM_xHqqkZx_.
		m_vEditLine.erase(&NEXLINE);
	}

#undef CURLINE
#undef NEXLINE
} // CFCWndRichEdit::JoinContLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::JoinLineBelow
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiImIiNhOiCmJiCmCiCkCiCmEiBeBiMhAjBlBiNhDiCpAiClHiCnHiCmEjAoGjDkKiNhDiCmJjIeBiMiLiClFiCmE_xHqqkZx_
 *			_xZkqqHx_iMhAjBlBiNhDiCpAjGlDiCkNiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	:_xZkqqHx_iKeKiOgOiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iKeKiOgOiNhDiCkKiMhAjBlBiNhDiCmMiPoKiNiHiBeBiClLiCmMjBkOiClHiCoJjAoGjDkKiNhDiCpAjFnEiClHiBeCiKeKiOgOiNhDiCkK_xHqqkZx_
 *			_xZkqqHx_jAoGjDkKiNhDiCmMiPoKiNiHiBeBiKeKiOgOiNhDiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	lLine_xZkqqHx_iCmFiOkGiClDiCoKiCoJiKeKiOgOiNhDiCkKiMhAjBlBiNhDiCmMiPoKiNiHiCmNiBeBiClLiCoKiCkKjBkOiClHiCoJjAoGjDkKiNhDiCnMiCmF_xHqqkZx_
 *			_xZkqqHx_iClDiCkJiCmMiCnKiCmBiCmEiBeBiClLiClBiCkJiCoHjIeBiMiLiPiIjHjNiCpAiKeKiOgOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::JoinLineBelow (long lLine)
{
	//----- _xZkqqHx_iMhAjBlBiNhDiCmMiPoKiNiHiBeBjAoGjDkKiCmMiNhDiCnMiCmFiImKjChFiCpAjGnPiClH_xHqqkZx_ -----
	while (m_vEditLine[lLine].m_byLineType == FDRC_LT_CONTINUE)
		lLine--;
	//----- _xZkqqHx_jAoGjDkKiCmMiNhDiCkJiCoHiImIiNhOiCmMiMhAjBlBiNhDiCpAjAnKjBlBiClHiCoJ_xHqqkZx_ -----
	for (long lLn = lLine; lLn < m_vEditLine.size(); lLn++)
		JoinContLine(lLn);
	return lLine;
} // CFCWndRichEdit::JoinLineBelow.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiCmMiImKjChFiBeBiNiCiClDiCpAiOfKiPgPiClFiBeBiNhDiCmMiDiBiDjDiDgPjFmPjAjEiCpAiNfIjAfGiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfOiDhFjFlGiOjKiCmMjFjNiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jFjNiCmJjEfLiCnMiCoJjFlGiOjKjAjEiCpAiMhGiOfKiClFiBeBiDeJiBfLiDgPiBfLiClHiCoJiPoKiNiHiImIiJlKiCmMiPiIjHjNiCpAiNhDiCkEiBeC_xHqqkZx_
 *			(A) _xZkqqHx_iNhDiCmMiNmFiMoDiCkKiJpMiNhDjFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
 *				_xZkqqHx_iHeA_xHqqkZx_ _xZkqqHx_iMhAjBlBiNhDiCpAiNoMjAkMiClFiBeBjGhLiNhDiCmMiJlKiCmJjBhNjDpMiClHiCoJiBeC_xHqqkZx_
 *				_xZkqqHx_iHeB_xHqqkZx_ _xZkqqHx_iMhAjBlBiNhDiCmJiDeJiBfLiDgPiBfLiClFiClNjFlGiOjKjHpBiCpAiClHiCnHiCmEiInKiClHiBeC_xHqqkZx_
 *				_xZkqqHx_iHeC_xHqqkZx_ _xZkqqHx_jGhLiNhDiCmMiNmFiMoDiCmJiMhAjBlBjFlGiOjKiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
 *			(B) _xZkqqHx_iNhDiCmMiNmFiMoDiCkKiMhAjBlBjFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
 *				_xZkqqHx_iHeA_xHqqkZx_ _xZkqqHx_jGhLiNhDiCmMiNmFiMoDiCmMiMhAjBlBjFlGiOjKiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
 *				_xZkqqHx_iHeB_xHqqkZx_ _xZkqqHx_iMhAjBlBiNhDiCmJiDeJiBfLiDgPiBfLiClFiClNjFlGiOjKjHpBiCpAiClHiCnHiCmEiInKiClHiBeC_xHqqkZx_
 *				_xZkqqHx_iHeC_xHqqkZx_ _xZkqqHx_jGhLiNhDiCmMiNmFiMoDiCmJiMhAjBlBjFlGiOjKiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lLine	: _xZkqqHx_iMhGiOfKiClHiCoJiNhDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCpAiOmAiNhDiClHiCoJjBePiCmJiBeB_xHqqkZx_JoinContLine_xZkqqHx_iKnGjAjEiCmJiCoGiCmBiCmEiMhAjBlBiNhDiCpA_xHqqkZx_
 *			_xZkqqHx_iKeKiOgOiNhDiCmJiMhAiCkCiCmFiCkIiCkJiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcLine (long lLine)
{
#define CURLINE m_vEditLine[lLine]
#define NEXLINE m_vEditLine[lLine+1]
	long lOrdered;
	mmetol mmLeftGap;
	mmetol mmRightGap;
	if (m_vmmptPoly.empty()) return;	// ClearText_xZkqqHx_iCkJiCoHiMmEiCmOiCoKiCoJiOjOiCmJiCkAiCoJiBeC_xHqqkZx_

	// _xZkqqHx_iIoKjEnEiNmFiPiJiCmMiNhDiCmM_xHqqkZx_Y_xZkqqHx_iImKjChFiCpAiKgPiCkGiCmEiCkIiCkNiBeC_xHqqkZx_
	const mmetol mmInitY = CURLINE.m_mmY;
	// _xZkqqHx_iNhD_xHqqkZx_Y_xZkqqHx_iNmAjFfHiCpAiLeMjIfOiBeC_xHqqkZx_
	mmetol mmFirstY = mmInitY;
	// _xZkqqHx_jFlGiOjKjAjEjAkHiMmAiCpAiJpAiPjMiBeC_xHqqkZx_
	long lCharMax = -1;
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	for (;;)
//	{
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		//----- _xZkqqHx_iCnMiClIiBeBiNlGiKpBiClJiCmFiMhGiOfKiClFiCmEiBeBiNhDiCmJiOpLiCnMiCoJjFlGiOjKjAjEiCmMjGnKiImAiCpAjDlOiCoJ_xHqqkZx_ -----
		for (;;)
		{
			lOrdered = CalcLineAlignLeft(CURLINE, mmLeftGap, mmRightGap, 0.0, lCharMax);
			// _xZkqqHx_iNhDiCpAiCkCiCkNiCoHiJlKiCmJjBjHiCmBiCmEiCoAiCfAjFlGiOjKiCoAiOpLiCnMiCoHiCmIiCkCiPoKiNiHiCmNiBeBiPeJjHlJiBeC_xHqqkZx_
			if (lOrdered < 0) break;
			long lNewCount;
			// _xZkqqHx_jCfAiMoKiLkLiKeFiCkJiBeI_xHqqkZx_lOrdered_xZkqqHx_iCkKiClPiCoFiCkEiCmHjCfAiMoKiLkLiKeFiCmMiPoKiNiHiCmNiDiLiBfLiDhGiPeJjHlJiBeC_xHqqkZx_
			if (IsWrapedWordE(lNewCount, CURLINE.m_vEditChar, lOrdered) &&
				IsWrapedWordJ(lNewCount, CURLINE.m_vEditChar, lOrdered)) break;
			// _xZkqqHx_jCfAiMoKiLkLiKeFiImKjChFiCpAjFlGiOjKjAjEjAkHiMmAiCmJjAnNjCoIiBeC_xHqqkZx_
			lCharMax = lNewCount;
			if (lCharMax == 0)
			//----- lOrdered _xZkqqHx_jDoAiCmJiCmNjCfAiMoKiLkLiKeFiCkKjBlGiNnNiClFiCmIiCkCiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iNhD_xHqqkZx_Y_xZkqqHx_iNmAjFfHiPiJiKpKjCgMiCmJ_xHqqkZx_1mm_xZkqqHx_iCpAiJmBiOfKiBeC_xHqqkZx_
				mmFirstY += 1.0;
				// _xZkqqHx_jFlGiOjKjAjEjAkHiMmAiCpAiJpAiPjMiBeC_xHqqkZx_
				lCharMax = -1;
			}
			// CalcLineAlignLeft_xZkqqHx_iCmFjFmPiNfIiClDiCoKiClNiNhD_xHqqkZx_Y_xZkqqHx_iNmAjFfHiCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_
			CURLINE.m_mmY = mmFirstY;
		}

		if (lOrdered < 0)
		//----- _xZkqqHx_iNhDiCmJiCfAjFlGiOjKiCoAiOpLiCnMiCoHiCmIiCkCiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_iJhAiMoKjAkOiMgAiDiLiBfLiDiLiCoAjDpKjGhLiMoKjAkOiMgAiDiLiBfLiDiLiCoAjGlDiMpIiCmIiCoHiCmOiBeBiPiIjHjNiCpAiPeJjHlJiBeC_xHqqkZx_
			if (!g_pReg->GetIsTextFormE1() &&
				!g_pReg->GetIsTextFormJ1()) return;

			//----- _xZkqqHx_jAkOiMgAiDiLiBfLiDiLiCpAiKePiClFiCmEiNmEjDhIiMhGiOfKiClFiCmEiCnNiCoJ_xHqqkZx_ -----

			// _xZkqqHx_iNhD_xHqqkZx_Y_xZkqqHx_iNmAjFfHiCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_
			CURLINE.m_mmY = mmInitY;
			for (;;)
			{
				lOrdered = CalcLineAlignLeft(CURLINE, mmLeftGap, mmRightGap, 0.0, -1);
				// _xZkqqHx_iNhDiCpAiCkCiCkNiCoHiJlKiCmJjBjHiCmBiCmEiCoAiCfAjFlGiOjKiCoAiOpLiCnMiCoHiCmIiCkCiPoKiNiHiCmNiBeBiPeJjHlJiBeC_xHqqkZx_
				if (lOrdered < 0) return;
				// _xZkqqHx_iCfAjFlGiOjKiImIiPoD_xHqqkZx_ _xZkqqHx_iNhDiCmJiOpLiCnMiCmBiClNiPoKiNiHiCmNiOjPiCmMiPiIjHjNiCnGiBeC_xHqqkZx_
				if (lOrdered != 0) break;
				// _xZkqqHx_iCfAjFlGiOjKiCoAiNhDiCmJiOpLiCnMiCoHiCmIiCkCiPoKiNiHiBeBiNhD_xHqqkZx_Y_xZkqqHx_iNmAjFfHiCmJ_xHqqkZx_1mm_xZkqqHx_iCpAiJmBiOfKiClFiCmEiCoAiCkEiIoKjDhIiDgHiDiJiDeDiBeC_xHqqkZx_
				CURLINE.m_mmY += 1.0;
			}
			// _xZkqqHx_jFlGiOjKjAjEjAkHiMmAiCpAjAnNjCoIiBeC_xHqqkZx_
			lCharMax = lOrdered;
		}

		//----- _xZkqqHx_iOjPiCmJiBeBiPoDiCmFjDlOiClNjFlGiOjKjAjEiCkKiOpLiCnMiCoJiCoGiCkEiCmJiBeBjCiGiJjLiKpBiClJ_xHqqkZx_/_xZkqqHx_iJeFiKpBiClJiCpAiMhGiOfK_xHqqkZx_ -----

		if (CURLINE.m_byAlignment == FDRC_AL_CENTER && mmLeftGap < mmRightGap)
		//----- _xZkqqHx_jCiGiJjLiKpBiClJiBjFiJeFiDeNiDiDiDgCiDhGiCkKiNlGiDeNiDiDiDgCiDhGiCoGiCoIjBoFiCkLiCkCiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jAfGiClFiCkCiNlGiDeNiDiDiDgCiDhGiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
			mmetol mmNewGap = (mmLeftGap + mmRightGap) / 2.0;
			long lOrderedBak = lOrdered;
			mmetol mmYBak = CURLINE.m_mmY;
			for (;;)
			{
				// _xZkqqHx_jAfGiClFiCkCiDeNiDiDiDgCiDhGiCmFiMhGiOfKiClFjClMiClFiBeC_xHqqkZx_
				lOrdered = CalcLineAlignLeft(CURLINE, mmLeftGap, mmRightGap, mmNewGap, lOrderedBak);
				// _xZkqqHx_iDeNiDiDiDgCiDhGiCkK_xHqqkZx_0_xZkqqHx_iCmIiCoHiCmOiPeJjHlJiBeCiCkAiCoIiCkGiCmIiCkCiCmGiOhGiCkEiCkKiBeBjEePiCmMiClNiCnPiBeC_xHqqkZx_
				if (almost0(mmRightGap + mmNewGap)) break;
				// _xZkqqHx_iCfAiNhDiCmMiImKjChFiBeBiOpLiCnMiCoJjFlGiOjKjAjEiCmGiCoAiCmJiNlGiKpBiClJiCmJjDjJiClFiCkNiCmIiCoIiBeB_xHqqkZx_
				// _xZkqqHx_iNlGiDeNiDiDiDgCiDhGiCoGiCoIiJeFiDeNiDiDiDgCiDhGiCkKjBoFiCkLiCkCiIlNiCkCiCmNiClLiCmMiNlHiCkKiPkMiClDiCkNiCmIiCoJiCnMiCmFiDiLiBfLiDhGiBeC_xHqqkZx_
				if (lOrderedBak == lOrdered && mmYBak == CURLINE.m_mmY &&
					(mmNewGap - mmRightGap) / (mmRightGap + mmNewGap) <= 0.2) break;
				// _xZkqqHx_iDgPiDgCiDeOiDeBiDgCiDhGiCpAjGnPiClHiBeC_xHqqkZx_
				CURLINE.m_mmY = mmYBak;
				// _xZkqqHx_iNlGiDeNiDiDiDgCiDhGiCpAiMlIiCoHiClFiCmEiOjPiCmMiMhGiOfKiBeC_xHqqkZx_
				mmNewGap -= 5.0;
				if (mmNewGap < 0.0) mmNewGap = 0.0;
			}
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//			// _xZkqqHx_iMhGiOfKiPeJjHlJiBeC_xHqqkZx_
//			break;
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		} else
		if (CURLINE.m_byAlignment == FDRC_AL_RIGHT)
		//----- _xZkqqHx_iJeFiKpBiClJiCmMiPoKiNiH_xHqqkZx_ -----
		{
			long lOrdered2;
			// lOrdered_xZkqqHx_jFlGiOjKjAjEiCpAiOpLiCnPiCoJiCoGiCkEiCmJiBeBiJeFiKpBiClJiCmFiMhGiOfKiClFjClMiClFiBeC_xHqqkZx_
			lOrdered2 = CalcLineAlignRight(CURLINE, lOrdered);
			if (lOrdered2 < lOrdered)
			//----- _xZkqqHx_iJeFiKpBiClJiCmFiMhGiOfKiClFiClNiMiLiJmKiBeBiNlGiKpBiClJiCmFiMhGiOfKiClFiClNjFlGiOjKjAjEiCkKiOpLiCnMiCoHiCmIiCkCiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iNlGiKpBiClJiCmJjGnPiClHiBeC_xHqqkZx_
				lOrdered = CalcLineAlignLeft(CURLINE, mmLeftGap, mmRightGap, 0.0, lCharMax);
			}
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//			// _xZkqqHx_iMhGiOfKiPeJjHlJiBeC_xHqqkZx_
//			break;
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		} else
		if (CURLINE.m_byAlignment == FDRC_AL_LEFTRIGHT &&
			CURLINE.m_vEditChar[lOrdered - 1].m_wChar != FDRCH_RETURN)
		//----- _xZkqqHx_jHlMjCfLjBlFiCkGiBeBiKiOiCmCiMhAjBlBiNhDiCmMiPoKiNiH_xHqqkZx_ -----
		{
			// lOrdered_xZkqqHx_jFlGiOjKjAjEiCpAiOpLiCnPiCoJiCoGiCkEiCmJiBeBjHlMjCfLjBlFiCkGiCmFiMhGiOfKiClFjClMiClFiBeC_xHqqkZx_
			// _xZkqqHx_iMhGiOfKiCmJiOlIjEhDiClFiClNiPoKiNiHiBgJiCnMiClIjHeMiCoIiCkGiCmIiCkCiCkKiBgKiCmNiBeBiNlGiKpBiClJiCmJjGnPiClHiBeC_xHqqkZx_
			if (!CalcLineAlignLeftright(CURLINE, lOrdered, mmRightGap))
				lOrdered = CalcLineAlignLeft(CURLINE, mmLeftGap, mmRightGap, 0.0, lCharMax);
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//			break;
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		} else
//		//----- _xZkqqHx_iNlGiKpBiClJ_xHqqkZx_/_xZkqqHx_jCiGiJjLiKpBiClJiCmFjClCjAkOjFhDjHhGiCmMiPoKiNiH_xHqqkZx_ -----
//		{
//			// _xZkqqHx_iMhGiOfKiPeJjHlJiBeC_xHqqkZx_
//			break;
//----- 05.02.18 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		}
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//	}
	// _xZkqqHx_iCfAiNhDiCkKiClKiCpBiCnEiOpLiCnMiCmBiCmEiCkCiCoJiPoKiNiHiCmNiBeBiClBiCoKiImIiNhOiCmMiPiIjHjNiCmNjFhDjHhGiBeC_xHqqkZx_
	if (lOrdered == CURLINE.m_vEditChar.size()) return;

	/*----- _xZkqqHx_iClBiCoKiImIiNhOiCmMiPiIjHjNiCmNiBeBiNhDiCmMjFlGiOjKjHpBiCkKiDeJiBfLiDgPiBfLiClFiClNiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----*/

	if ((CURLINE.m_vEditChar.back()).m_wChar == FDRCH_RETURN)
	{	/*----- (A) _xZkqqHx_iNhDiCmMiNmFiMoDiCkKiJpMiNhDjFlGiOjKiCmMiPoKiNiH_xHqqkZx_ -----*/
		/*----- _xZkqqHx_iHeA_xHqqkZx_ _xZkqqHx_iMhAjBlBiNhDiCpAiNoMjAkMiClFiBeBjGhLiNhDiCmMiJlKiCmJjBhNjDpMiClHiCoJ_xHqqkZx_ -----*/
		FCEditLine	el;
		el.CopyProperty(CURLINE);
		el.m_byLineType = FDRC_LT_CONTINUE;
		m_vEditLine.insert(&NEXLINE, el);

		/*----- _xZkqqHx_iHeB_xHqqkZx_ _xZkqqHx_iMhAjBlBiNhDiCmJiDeJiBfLiDgPiBfLiClFiClNjFlGiOjKjHpBiCpAiClHiCnHiCmEiInKiClH_xHqqkZx_ -----*/
		NEXLINE.m_vEditChar.insert(NEXLINE.m_vEditChar.begin(),
									&(CURLINE.m_vEditChar[lOrdered]),
									CURLINE.m_vEditChar.end());
		CURLINE.m_vEditChar.erase(	&(CURLINE.m_vEditChar[lOrdered]),
									CURLINE.m_vEditChar.end());

		/*----- _xZkqqHx_iHeC_xHqqkZx_ _xZkqqHx_jGhLiNhDiCmMiNmFiMoDiCmJiMhAjBlBjFlGiOjKiCpAjBhNjDpMiClHiCoJ_xHqqkZx_ -----*/
		FCEditChar rcCont = CURLINE.m_vEditChar.back();
		rcCont.m_wChar = FDRCH_CONTINUE;
		rcCont.m_mmfWidth = 0.0;
		rcCont.m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
		rcCont.m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
		rcCont.m_mmfPreSpace = 0.0;
		rcCont.m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
		CURLINE.m_vEditChar.push_back(rcCont);
	} else
	{	/*----- (B) _xZkqqHx_iNhDiCmMiNmFiMoDiCkKiMhAjBlBjFlGiOjKiCmMiPoKiNiH_xHqqkZx_ -----*/
		/*----- _xZkqqHx_iHeA_xHqqkZx_ _xZkqqHx_jGhLiNhDiCmMiNmFiMoDiCmMiMhAjBlBjFlGiOjKiCpAiNoNiPjMiClHiCoJ_xHqqkZx_ -----*/
		CURLINE.m_vEditChar.pop_back();

		/*----- _xZkqqHx_iHeB_xHqqkZx_ _xZkqqHx_iMhAjBlBiNhDiCmJiDeJiBfLiDgPiBfLiClFiClNjFlGiOjKjHpBiCpAiClHiCnHiCmEiInKiClH_xHqqkZx_ -----*/
		NEXLINE.m_vEditChar.insert(NEXLINE.m_vEditChar.begin(),
									&(CURLINE.m_vEditChar[lOrdered]),
									CURLINE.m_vEditChar.end());
		CURLINE.m_vEditChar.erase(	&(CURLINE.m_vEditChar[lOrdered]),
									CURLINE.m_vEditChar.end());

		/*----- _xZkqqHx_iHeC_xHqqkZx_ _xZkqqHx_jGhLiNhDiCmMiNmFiMoDiCmJiMhAjBlBjFlGiOjKiCpAjBhNjDpMiClHiCoJ_xHqqkZx_ -----*/
		FCEditChar rcCont = CURLINE.m_vEditChar.back();
		rcCont.m_wChar = FDRCH_CONTINUE;
		rcCont.m_mmfWidth = 0.0;
		rcCont.m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
		rcCont.m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
		rcCont.m_mmfPreSpace = 0.0;
		rcCont.m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiCkJiBeI_xHqqkZx_
		CURLINE.m_vEditChar.push_back(rcCont);
	}
#undef CURLINE
#undef NEXLINE
} // CFCWndRichEdit::CalcLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineAlignLeft
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiCmMiImKjChFiBeBiNiCiClDiCpAiOfKiPgPiClFiBeBiNhDiCmMiDiBiDjDiDgPjFmPjAjEiCpAiNfIjAfGiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfOiDhFjFlGiOjKiCmMjFjNiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jFjNiCmJjEfLiCnMiCoJjFlGiOjKjAjEiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	edLine		:_xZkqqHx_iMhGiOfKiClHiCoJiNhDiCpAiOhHjCoIiClFiBeBiMhGiOfKiMiLiJmKiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmLeftGap	:_xZkqqHx_iNlGiDeNiDiDiDgCiDhGiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmRightGap	:_xZkqqHx_iJeFiDeNiDiDiDgCiDhGiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmAlignGap	:_xZkqqHx_iNhDiKpBiClJiCmMiInHiCmMiNlGiDeNiDiDiDgCiDhGiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lCharMax	:edLine_xZkqqHx_iCmFiOhHjCoIiClFiClNiNhDiCmFiBeBiMhGiOfKiMoDiCmJiClBiCmMiNhDiCmJiOpLiCnPiCoJ_xHqqkZx_
 *						 _xZkqqHx_iNmFjBoFjFlGiOjKjAjEiCpAjAkHiMmAiClHiCoJiBeCiCmCiCnMiCoIiBeBjFnEjCgMiCkKiClBiCmMjCgMiCpAjClEiCkGiCoJ_xHqqkZx_
 *						 _xZkqqHx_iClBiCmGiCmNiCmIiCkCiBeCjAkHiMmAiClFiCmIiCkCiPoKiNiHiCmN_xHqqkZx_ -1 _xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iNhDiCmJiOpLiCnMiCmBiClNjFlGiOjKjAjEiBeCiNhDiCpAiCkCiCkNiCoHiJlKiCmJjBjHiCmBiCmEiCoAiCfAjFlGiOjKiCoAiOpLiCnMiCoHiCmIiCkC_xHqqkZx_
 *			_xZkqqHx_iPoKiNiHiCmN_xHqqkZx_-1_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jAnNiMhGiDgNiBfLiDgH_xHqqkZx_P235,P236.
 *			_xZkqqHx_iNhDjCiGiCmMiJpMiNhDiCpAiPjMiCkNjBfDiCmEiCmMjFlGiOjKiCpAiDfIiDeMiDiDiDjDiClFiBeBjFlGiOjKiCmMiNmFjBoFiCmMiNiCiClDiCpA_xHqqkZx_
 *			_xZkqqHx_iNhDiCmMiNiCiClDiCmJjAnNjCoIiClHiCoJiBeCjCeBiClFiBeBiNhDjCiGiCmJiJpMiNhDiClFiCkJiCmIiCkCiPoKiNiHiCmNiBeBiJpMiNhDiCmM_xHqqkZx_
 *			_xZkqqHx_iNiCiClDiCpAiNhDiCmMiNiCiClDiCmJjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * MgL = MarginL
 * MgR = MarginR
 * StI = StartIndent
 * OFF = Offset
 * RtI = RightIndent
 * HdS = HeadSpace
 * AlG = AlignGap
 * LtG = LeftGap
 *                       _xZkqqHx_iEkA_xHqqkZx_     LeftGap      _xZkqqHx_iEkA_xHqqkZx_
 *                       _xZkqqHx_iBkLiBkJ_xHqqkZx_--------------_xZkqqHx_iBkIiBkL_xHqqkZx_
 *                 _xZkqqHx_iEkMiEkKiEkKiEkKiEkKiEkKiEkKiEkN_xHqqkZx_    _xZkqqHx_iEkMiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkN_xHqqkZx_    _xZkqqHx_iEkMiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkN_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_              _xZkqqHx_iEkL_xHqqkZx_            _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_     abcdef     _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_     ghi                _xZkqqHx_iEkL_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_            _xZkqqHx_iEkKiEkO_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iBkKiEkPiEkKiEkKiEkO_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_ _xZkqqHx_iBkK_xHqqkZx_         _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_              _xZkqqHx_iEkAiBkJiBkIiEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiBkJiBkIiEkA_xHqqkZx_    _xZkqqHx_iEkAiBkJiBkIiEkPiEkKiEkKiEkOiBkJiBkIiEkA_xHqqkZx_ _xZkqqHx_iEkAiBkJ_xHqqkZx_-----_xZkqqHx_iBkIiEkAiBkJiBkIiEkL_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_                 MgL_xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_         MgL_xZkqqHx_iEkA_xHqqkZx_       MgR         MgL   _xZkqqHx_iEkA_xHqqkZx_ RightGap_xZkqqHx_iEkA_xHqqkZx_ MgR       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkAiBkJ_xHqqkZx_-------_xZkqqHx_iBkIiEkAiBkJ_xHqqkZx_---_xZkqqHx_iBkIiEkAiBkJiBkIiEkA_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkAiBkJ_xHqqkZx_---_xZkqqHx_iBkIiEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_MgL+StI+OFF_xZkqqHx_iEkA_xHqqkZx_  HdS  _xZkqqHx_iEkA_xHqqkZx_ AlG_xZkqqHx_iEkA_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_MgR+RtI_xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_    (o)           _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_iEkA_xHqqkZx_    MostLeft               _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_iEkAiBkJ_xHqqkZx_-----------------------_xZkqqHx_iBkIiEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_iEkA_xHqqkZx_       (a_xZkqqHx_iCmM_xHqqkZx_)PreSpace       _xZkqqHx_iEkA_xHqqkZx_                         (q)        (r) (s)      (t)
 * (m)          (n)                          (p)
 *
 * (m) _xZkqqHx_iLoJiMgAiCmMiNlGjCfLiBeCjBkGiClP_xHqqkZx_ x=0_xZkqqHx_iBeC_xHqqkZx_
 * (n) _xZkqqHx_iNlGiDhNiBfLiDfHiDjDiCmGiNlGiDeDiDjDiDgGiDjDiDgHiCpAiJmBiOfKiBeCiDhNiDfIiDeOiCmMiMgAiPpDiCmJiKnGiCoNiCoHiClIiBeBiClBiCoKiCoGiCoI_xHqqkZx_
 *     _xZkqqHx_iNlGiCmJjFlGiOjKiCkKiPjBiCkJiCoKiCoJiClBiCmGiCmNjGlDiCkCiBeC_xHqqkZx_
 * MostLeft _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCmGiNlGiDhNiBfLiDfHiDjDiCpAiNgMjHlGiClFiClNiBeBjFlGiOjKjFgAiJoGiJmCjEfMiCmIiNlGjCfLiBeC_xHqqkZx_
 *          (n)_xZkqqHx_iCoGiCoIiNlGiCmJiCkNiCoJiClBiCmGiCmNjGlDiCkCiBeC_xHqqkZx_
 * (o) _xZkqqHx_jFlGiOjKiCmMiImKjChFjBlFiCkGjHhAiCmMiDeNiDiDiDgCiDhGiCpAiNgMjHlGiClFiClNiBeBjFlGiOjKjFgAiJoGiJmCjEfMiCmIiNlGjCfLiBeC_xHqqkZx_
 *     MostLeft _xZkqqHx_iCoGiCoIiNlGiCmJiCkNiCoJiClBiCmGiCmNjGlDiCkCiBeCiCnMiClNiBeBjFlGiOjKiCmNiClBiClBiCoGiCoIiJeFiCmJjFgAiJoGiClDiCoKiCoJiBeC_xHqqkZx_
 * (p) _xZkqqHx_iOmAiNnLiCmJjFlGiOjKiCkKjFgAiJoGiClDiCoKiCoJiImKjChFiBeC_xHqqkZx_(o)_xZkqqHx_iCmMiImKjChFiCkJiCoHjFgAiJoGiClFiClNiCkCiCkKiBeBiClBiCmMiPoKiNiHiCmN_xHqqkZx_
 *     _xZkqqHx_iDhNiDfIiDeOiCmJiIpIiCmBiCkJiCkJiCoIiBeBiJeFiCmJiInKjDkOiBeCiOjPiCmMjFgAiJoGiJmCjEfMiImKjChFiCkJiCoHiNlGiDhNiBfLiDfHiDjDiLjHjHkDiCpA_xHqqkZx_
 *     _xZkqqHx_jChFiCkCiClN_xHqqkZx_(p)_xZkqqHx_iCkJiCoHjFgAiCkLiOgOiCnPiCoJiBeC_xHqqkZx_
 * (q) _xZkqqHx_jFlGiOjKiCmMjFgAiCkLiPeJiCoNiCoIiCmMiImKjChFiBeC_xHqqkZx_
 * (r) _xZkqqHx_jFlGiOjKiCkKjFgAiJoGiJmCjEfMiCmIiBeBiIoKjEnEiJeFiCmMiImKjChFiBeCiDhNiDfIiDeOiCmGiJeFiDhNiBfLiDfHiDjDiCpAiNgMjHlGiBeCjFeLiClI_xHqqkZx_(s)
 *     _xZkqqHx_iCoGiCoIiCoAiNlGiCmJiCkAiCoJiBeC_xHqqkZx_
 * (s) _xZkqqHx_iJeFiDhNiBfLiDfHiDjDiCmGiJeFiDeDiDjDiDgGiDjDiDgHiCpAiJmBiOfKiClFiClNiImKjChFiBeCiDhNiDfIiDeOiCmMiMgAiPpDiCmJiKnGiCoNiCoHiClI_xHqqkZx_
 *     _xZkqqHx_iClBiCoKiCoGiCoIiJeFiCmJjFlGiOjKiCkKiPjBiCkJiCoKiCoJiClBiCmGiCmNjGlDiCkCiBeC_xHqqkZx_
 * (t) _xZkqqHx_iLoJiMgAiCmMiJeFjCfLiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.27 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::CalcLineAlignLeft (FCEditLine& edLine, mmetol& mmLeftGap,
										mmetol& mmRightGap, mmetol mmAlignGap,
										long lCharMax)
{
	//----- _xZkqqHx_iDgPiDgCiDeOiDeBiDgCiDhGjHhAiNfMjBkCjBmMjFmPjAjE_xHqqkZx_ -----
	struct myFCBackup
	{
		void DoBackup (const FCEditLine& edLine, long lCharCount, mmetol mmLGap, mmetol mmRGap)
		{
			vEditChar.clear();
			vEditChar.insert(vEditChar.begin(), edLine.m_vEditChar.begin(),
								edLine.m_vEditChar.begin() + lCharCount);
			mmY = edLine.m_mmY;
			mmfTMHeight = edLine.m_mmfTMHeight;
			mmfTMAscent = edLine.m_mmfTMAscent;
			mmfTMExternalLeading = edLine.m_mmfTMExternalLeading;
			mmLeftGap = mmLGap;
			mmRightGap = mmRGap;
		}
		void DoRestore (FCEditLine& edLine, long& lCharCount, mmetol& mmLGap, mmetol& mmRGap)
		{
			memcpy(&edLine.m_vEditChar[0], &vEditChar[0],
					vEditChar.size() * sizeof(FCEditChar));
			edLine.m_mmY = mmY;
			edLine.m_mmfTMHeight = mmfTMHeight;
			edLine.m_mmfTMAscent = mmfTMAscent;
			edLine.m_mmfTMExternalLeading = mmfTMExternalLeading;
			lCharCount = vEditChar.size();
			mmLGap = mmLeftGap;
			mmRGap = mmRightGap;
		}
		void Clear ()
		{
			vEditChar.clear();
		}

		FCEditCharVector vEditChar;
		mmetol	mmY;
		fmmetol	mmfTMHeight;
		fmmetol	mmfTMAscent;
		fmmetol	mmfTMExternalLeading;
		mmetol	mmLeftGap;
		mmetol	mmRightGap;
	}; // struct myFCBackup.

	long lCharCount = -1;
	for (;;)
	{
		//----- _xZkqqHx_iNhDiCmMiNiCiClDiCpAiNmFiPiJiCmMjFlGiOjKiCmMiNiCiClDiCmFiPiJiKpKiJlL_xHqqkZx_ -----
		FCEditChar& eChar = (edLine.m_vEditChar)[0];
		mmetol mmTMAscent = g_pEnv->GetSFontRec(eChar.m_foidFont)->GetAscent(eChar.m_wOffset);
		mmetol mmTMDescent = g_pEnv->GetSFontRec(eChar.m_foidFont)->GetDescent(eChar.m_wOffset);
		mmetol mmTMExternalLeading = g_pEnv->GetSFontRec(eChar.m_foidFont)->GetExternalLeading(eChar.m_wOffset);

		myFCBackup backup;
		// Y_xZkqqHx_iNmAjFfHiCmMiDeJiBfLiDgPiBfLiCpAiDgAiDeGiDgCiDeOiBeCiClBiClBiCmFiCmN_xHqqkZx_m_mmY_xZkqqHx_iClOiCkPiCpAiDgAiDeGiDgCiDeOiBeC_xHqqkZx_m_mmfTMHeight
		// _xZkqqHx_iCmNiBeBiClBiClBiCmFiCmNjAlDiClFiCkCjCgMiCkKjAnNjCoIiClDiCoKiCmEiCkCiCmIiCkCiClNiCnPiBeBiOfBiPmGiClFiCmEiCmNiCkCiCkPiCmIiCkCiBeC_xHqqkZx_
		// m_mmY_xZkqqHx_iClOiCkPiCpAiDgAiDeGiDgCiDeOiClHiCoJiClBiCmGiCmFiBeBiNhDiCkKiOpLiCnMiCoHiCmIiCkCiCmGiCkLiCmJ_xHqqkZx_m_mmY_xZkqqHx_iCpA_xHqqkZx_m_mmrtWindow_xZkqqHx_iCmM_xHqqkZx_
		// _xZkqqHx_iKePiCnMiCmFjCmHiCkCiPgPiClHjDkNiCkLiCoAiCkAiCoJiBeC_xHqqkZx_
		if (m_mmrtWindow.Height() - m_mmMarginB < edLine.m_mmY) return -1L;
		for (;;)
		{
			int endCode = CalcAlignLeftSimple(edLine, lCharCount, mmLeftGap, mmRightGap,
										mmTMAscent, mmTMDescent, mmTMExternalLeading,
										mmAlignGap, lCharMax);
			// _xZkqqHx_jAlDiPoNiPeJjHlJiCmIiCoHiCmOiBeBiPeJjHlJiBeC_xHqqkZx_
			if (endCode == FTWR_END_NORMAL) break;
			// _xZkqqHx_iMlLiNnNiCmMiNhDiCmMiPoOjFpBiCpAiDgPiDgCiDeOiDeBiDgCiDhGiBeC_xHqqkZx_
			backup.DoBackup(edLine, lCharCount, mmLeftGap, mmRightGap);
			// _xZkqqHx_iDhEiDeIiDjDiDgHiPoDjFjEiCkKiKgHjBoFiCmMiPoKiNiHiBeC_xHqqkZx_
			if (endCode & FTWR_END_OVER_ASCENT)
			{
				mmTMAscent = g_pEnv->GetSFontRec(edLine.m_vEditChar[lCharCount].m_foidFont)->
										GetAscent(edLine.m_vEditChar[lCharCount].m_wOffset);
			}
			// _xZkqqHx_iDhEiDeIiDjDiDgHiJlKjFjEiCkKiKgHjBoFiCmMiPoKiNiHiBeC_xHqqkZx_
			if (endCode & FTWR_END_OVER_DESCENT)
			{
				mmTMDescent = g_pEnv->GetSFontRec(edLine.m_vEditChar[lCharCount].m_foidFont)->
										GetDescent(edLine.m_vEditChar[lCharCount].m_wOffset);
				mmTMExternalLeading = g_pEnv->GetSFontRec(edLine.m_vEditChar[lCharCount].m_foidFont)->
										GetExternalLeading(edLine.m_vEditChar[lCharCount].m_wOffset);
			}
		}
		if (0 < lCharCount)
		//----- _xZkqqHx_iCfAjFlGiOjKiImIiPoDiBeBiNhDiCmJjFlGiOjKiCkKjDpMiCmBiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_iDgPiDgCiDeOiDeBiDgCiDhGiCkKiBeBiMlLiNnNiCmMiNhDiCmMjFlGiOjKjAjEiImIiPoDiCmMjFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
			if (lCharCount <= backup.vEditChar.size())
				backup.DoRestore(edLine, lCharCount, mmLeftGap, mmRightGap);
			break;
		}

		//----- _xZkqqHx_iImIiNhO_xHqqkZx_ _xZkqqHx_iCfAjFlGiOjKiCoAiNhDiCmJjFlGiOjKiCkKjDpMiCmBiCmEiCkCiCmIiCkCiPoKiNiH_xHqqkZx_ -----

		if (backup.vEditChar.size() != 0)
		//----- _xZkqqHx_jBePiJpBiCmMiDgHiDiJiDeDiCmFiCmNiBeBiCfAjFlGiOjKiImIiPoD_xHqqkZx_ _xZkqqHx_iNhDiCmJjFlGiOjKiCkKjDpMiCmBiCmEiCkCiClNiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jBePiJpBiCmMiDgHiDiJiDeDiCmJjCgMiCpAjGnPiClHiBeC_xHqqkZx_
			backup.DoRestore(edLine, lCharCount, mmLeftGap, mmRightGap);
			break;
		}
		// _xZkqqHx_iNkBiJpBiCmMiDgHiDiJiDeDiCoAjBePiJpBiCmMiDgHiDiJiDeDiCoAiBeBiNhDiCmJjFlGiOjKiCkKjDpMiCoHiCmIiCkJiCmBiClNiPoKiNiHiBeC_xHqqkZx_
		// _xZkqqHx_iNhD_xHqqkZx_Y_xZkqqHx_iNmAjFfHiCmJ_xHqqkZx_1mm_xZkqqHx_iCpAiJmBiOfKiBeC_xHqqkZx_
		edLine.m_mmY += 1.0;
	}
	return lCharCount;
} // CFCWndRichEdit::CalcLineAlignLeft.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcAlignLeftSimple
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClN_xHqqkZx_mmTMAscent_xZkqqHx_iBeB_xHqqkZx_mmTMDescent_xZkqqHx_iBeB_xHqqkZx_mmTMExternalLeading_xZkqqHx_iCmF_xHqqkZx_
 *			_xZkqqHx_iNhDiCmMiImKjChFiBeBiNiCiClDiCpAiOfKiPgPiClFiBeBiNhDiCmMiDiBiDjDiDgPjFmPjAjEiCpAiNfIjAfGiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfOiDhFjFlGiOjKiCmMjFjNiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jFjNiCmJjEfLiCnMiCoJjFlGiOjKjAjEiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	edLine		:_xZkqqHx_iMhGiOfKiClHiCoJiNhDiCpAiOhHjCoIiClFiBeBiMhGiOfKiMiLiJmKiCpAjFnEiClHiBeC_xHqqkZx_
 *			lCharCount	:_xZkqqHx_iNhDiCmJjChFiCkNiClBiCmGiCkKiCmFiCkLiClNjFlGiOjKjAjEiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmLeftGap	:_xZkqqHx_iNlGiDeNiDiDiDgCiDhGiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmRightGap	:_xZkqqHx_iJeFiDeNiDiDiDgCiDhGiCpAjFnEiClHiBeC_xHqqkZx_
 *			mmTMAscent	:_xZkqqHx_jFlGiOjKiCmMiPoDjFjEiNiCiClDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmTMDescent	:_xZkqqHx_jFlGiOjKiCmMiJlKjFjEiNiCiClDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmTMExternalLeading :_xZkqqHx_jFlGiOjKiJlKiCmMiMiEiKnEiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmAlignGap	:_xZkqqHx_iNhDiKpBiClJiCmMiInHiCmMiNlGiDeNiDiDiDgCiDhGiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lCharMax	:edLine_xZkqqHx_iCmFiOhHjCoIiClFiClNiNhDiCmFiBeBiMhGiOfKiMoDiCmJiClBiCmMiNhDiCmJiOpLiCnPiCoJ_xHqqkZx_
 *						 _xZkqqHx_iNmFjBoFjFlGiOjKjAjEiCpAjAkHiMmAiClHiCoJiBeCiCmCiCnMiCoIiBeBjFnEjCgMiCkKiClBiCmMjCgMiCpAjClEiCkGiCoJ_xHqqkZx_
 *						 _xZkqqHx_iClBiCmGiCmNiCmIiCkCiBeCjAkHiMmAiClFiCmIiCkCiPoKiNiHiCmN_xHqqkZx_ -1 _xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *			----- _xZkqqHx_iImIiJlKiCmNiBeB_xHqqkZx_AlignLeftright(_xZkqqHx_jHlMjCfLjBlFiCkG_xHqqkZx_)_xZkqqHx_iCmJiOgHjHhA_xHqqkZx_ -----
 *			lSpcIncFirst:_xZkqqHx_iLpDjEjCiCmMjFjNiCmJiJmBiOfKiClHiCoJiPoKiNiHiBeBiJmBiOfKiClHiCoJjFlGiOjKjEmNiImNiCmMiNmFiPiJiCmM_xHqqkZx_
 *						 _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_[lSpcIncFirst, lSpcIncEnd)
 *			lSpcIncEnd	:_xZkqqHx_iLpDjEjCiCmMjFjNiCmJiJmBiOfKiClHiCoJiPoKiNiHiBeBiJmBiOfKiClHiCoJjFlGiOjKjEmNiImNiCmMiNmFiMoDiCmM_xHqqkZx_
 *						 _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_[lSpcIncFirst, lSpcIncEnd)
 *			mmSpcInc	:_xZkqqHx_iLpDjEjCiCmMjFjNiCmJiJmBiOfKiClHiCoJiPoKiNiHiBeBiJmBiOfKiClHiCoJjFjNiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iMhGiOfKiPeJjHlJiCmMiPpDjBnEiCpAjFnEiClHiBeCiImIiJlKiCmMiDhCiDgCiDgHiCkKjHkHiCmCiBeC_xHqqkZx_
 *			FTWR_END_NORMAL		:_xZkqqHx_jFlGiOjKiCkKiClBiCoKiImIiPoDjChFiCkPiCmIiCkCiBeBiIlNiCkCiCmN_xHqqkZx_lCharMax_xZkqqHx_iCmJjCeCiClFiClNiBeC_xHqqkZx_
 *			FTWR_END_OVER_ASCENT:mmTMAscent_xZkqqHx_iOhHjCoIiCmMjCgMiCoGiCoIiBeBjBoFiCkLiCkCiDhEiDeIiDjDiDgHiCkKjEkNjAlGiBeC_xHqqkZx_
 *			FTWR_END_OVER_DESCENT:mmTMDescent_xZkqqHx_iOhHjCoIiCmMjCgMiCoGiCoIiBeBjBoFiCkLiCkCiDhEiDeIiDjDiDgHiCkKjEkNjAlGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jAnNiMhGiDgNiBfLiDgH_xHqqkZx_P235,P236.
 *			_xZkqqHx_iNhDjCiGiCmMiJpMiNhDiCpAiPjMiCkNjBfDiCmEiCmMjFlGiOjKiCpAiDfIiDeMiDiDiDjDiClFiBeBjFlGiOjKiCmMiNmFjBoFiCmMiNiCiClDiCpA_xHqqkZx_
 *			_xZkqqHx_iNhDiCmMiNiCiClDiCmJjAnNjCoIiClHiCoJiBeCjCeBiClFiBeBiNhDjCiGiCmJiJpMiNhDiClFiCkJiCmIiCkCiPoKiNiHiCmNiBeBiJpMiNhDiCmM_xHqqkZx_
 *			_xZkqqHx_iNiCiClDiCpAiNhDiCmMiNiCiClDiCmJjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iLpDjEjCiCmGiJpMiNhDiCmNiBeBiNhDiCmMiJeFjCfLiCpAiJhKiCkGiCmEiCoAjChFiCkNiClBiCmGiCkKiCmFiCkLiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iDfOiDhFiCmNiBeBiClBiCoKiCmJjDjGiCmEiCmNiCnMiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 *			_xZkqqHx_iMlLiNnNiCmMiNhDiImKjChFiBgJ_xHqqkZx_edLine.m_mmY_xZkqqHx_iBgKiCmGiNhDiCmMiNiCiClDiCmJiKoOiCmDiCkCiCmEiBeBjFlGiOjKiCpAiJjPiClFiNjOiCnPiCoJ_xHqqkZx_
 *			_xZkqqHx_iLpDiKnEiCpAjAlIiNlIiClHiCoJiBeCiLpDiKnEjAlIiNlIiCmNiBeBiNhDiCmMiPoDjCfLiBeFiJlKjCfLiBeFjCiGiKnEiCmMjAiFjFlNjApMiCpAiBeBiDhNiDfIiDeO_xHqqkZx_
 *			_xZkqqHx_iDhMiDiKiDfDiDjDiCmGiMpAiNlHiClHiCoJjDfPiCpAiOfKiPgPiClFiBeBiDhNiDfIiDeOjAhNiMgAiCmMjDoAjBkEiCmJiCkAiCoJiLpDiKnEiCpAjClCiCnHiCoJ_xHqqkZx_
 *			_xZkqqHx_iClBiCmGiCmFiCkAiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jAlIiNlIiClFiClNiLpDiKnEiCmJiBeBiOhHjCoIiClDiCoKiClNiNhDiCmMjFlGiOjKjHpBiCkKiJlNjFlGiOjKiOpLiCnMiCoJiCkJiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jBfDiCmEiCmMjFlGiOjKiCkKiOpLiCnMiCmBiClNiPoKiNiHiBeFjFlGiOjKiCkKiJeFjCfLiCmJjCeCiClFiClNiPoKiNiHiCmN_xHqqkZx_ FTWR_END_NORMAL
 *			_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *			_xZkqqHx_jDhCjCiGiCmFiDhEiDeIiDjDiDgHiCmMjFmPiNfIiCkKiCkAiCoIiBeBiDhEiDeIiDjDiDgHiCmM_xHqqkZx_Ascent/Descent _xZkqqHx_iCkKiCoGiCoIjBoFiCkLiCkN_xHqqkZx_
 *			_xZkqqHx_iCmIiCmBiClNiPoKiNiHiCmNiNhDiCmMiNmEiMhGiOfKiCkKjFeLjHhGiCmIiClNiCnPiBeBjBkGiNmAiCmJ_xHqqkZx_
 *			FTWR_END_OVER_ASCENT/FTWR_END_OVER_DESCENT_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * MgL = MarginL
 * MgR = MarginR
 * StI = StartIndent
 * OFF = Offset
 * RtI = RightIndent
 * HdS = HeadSpace
 * AlG = AlignGap
 * LtG = LeftGap
 *                       _xZkqqHx_iEkA_xHqqkZx_     LeftGap      _xZkqqHx_iEkA_xHqqkZx_
 *                       _xZkqqHx_iBkLiBkJ_xHqqkZx_--------------_xZkqqHx_iBkIiBkL_xHqqkZx_
 *                 _xZkqqHx_iEkMiEkKiEkKiEkKiEkKiEkKiEkKiEkN_xHqqkZx_    _xZkqqHx_iEkMiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkN_xHqqkZx_    _xZkqqHx_iEkMiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkKiEkN_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_              _xZkqqHx_iEkL_xHqqkZx_            _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_     abcdef     _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_     ghi                _xZkqqHx_iEkL_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_            _xZkqqHx_iEkKiEkO_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iBkKiEkPiEkKiEkKiEkO_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_    _xZkqqHx_iBkK_xHqqkZx_ _xZkqqHx_iBkK_xHqqkZx_         _xZkqqHx_iBkK_xHqqkZx_    _xZkqqHx_iEkL_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_              _xZkqqHx_iEkAiBkJiBkIiEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiBkJiBkIiEkA_xHqqkZx_    _xZkqqHx_iEkAiBkJiBkIiEkPiEkKiEkKiEkOiBkJiBkIiEkA_xHqqkZx_ _xZkqqHx_iEkAiBkJ_xHqqkZx_-----_xZkqqHx_iBkIiEkAiBkJiBkIiEkL_xHqqkZx_     _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_                 MgL_xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_         MgL_xZkqqHx_iEkA_xHqqkZx_       MgR         MgL   _xZkqqHx_iEkA_xHqqkZx_ RightGap_xZkqqHx_iEkA_xHqqkZx_ MgR       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkAiBkJ_xHqqkZx_-------_xZkqqHx_iBkIiEkAiBkJ_xHqqkZx_---_xZkqqHx_iBkIiEkAiBkJiBkIiEkA_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkAiBkJ_xHqqkZx_---_xZkqqHx_iBkIiEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_MgL+StI+OFF_xZkqqHx_iEkA_xHqqkZx_  HdS  _xZkqqHx_iEkA_xHqqkZx_ AlG_xZkqqHx_iEkA_xHqqkZx_            _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_MgR+RtI_xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_    (o)           _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_           _xZkqqHx_iEkA_xHqqkZx_    MostLeft               _xZkqqHx_iEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkAiBkJ_xHqqkZx_-------_xZkqqHx_iBkIiEkAiBkJ_xHqqkZx_-----------------------_xZkqqHx_iBkIiEkA_xHqqkZx_                         _xZkqqHx_iEkA_xHqqkZx_         _xZkqqHx_iEkA_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_       _xZkqqHx_iEkA_xHqqkZx_
 * _xZkqqHx_iEkA_xHqqkZx_ LeftLimit _xZkqqHx_iEkA_xHqqkZx_       (a_xZkqqHx_iCmM_xHqqkZx_)PreSpace       _xZkqqHx_iEkA_xHqqkZx_                         (q)        (r) (s)      (t)
 * (m)          (n)                          (p)
 *
 * (m) _xZkqqHx_iLoJiMgAiCmMiNlGjCfLiBeCjBkGiClP_xHqqkZx_ x=0_xZkqqHx_iBeC_xHqqkZx_
 * (n) _xZkqqHx_iNlGiDhNiBfLiDfHiDjDiCmGiNlGiDeDiDjDiDgGiDjDiDgHiCpAiJmBiOfKiBeCiDhNiDfIiDeOiCmMiMgAiPpDiCmJiKnGiCoNiCoHiClIiBeBiClBiCoKiCoGiCoI_xHqqkZx_
 *     _xZkqqHx_iNlGiCmJjFlGiOjKiCkKiPjBiCkJiCoKiCoJiClBiCmGiCmNjGlDiCkCiBeC_xHqqkZx_
 * MostLeft _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCmGiNlGiDhNiBfLiDfHiDjDiCpAiNgMjHlGiClFiClNiBeBjFlGiOjKjFgAiJoGiJmCjEfMiCmIiNlGjCfLiBeC_xHqqkZx_
 *          (n)_xZkqqHx_iCoGiCoIiNlGiCmJiCkNiCoJiClBiCmGiCmNjGlDiCkCiBeC_xHqqkZx_
 * (o) _xZkqqHx_jFlGiOjKiCmMiImKjChFjBlFiCkGjHhAiCmMiDeNiDiDiDgCiDhGiCpAiNgMjHlGiClFiClNiBeBjFlGiOjKjFgAiJoGiJmCjEfMiCmIiNlGjCfLiBeC_xHqqkZx_
 *     MostLeft _xZkqqHx_iCoGiCoIiNlGiCmJiCkNiCoJiClBiCmGiCmNjGlDiCkCiBeCiCnMiClNiBeBjFlGiOjKiCmNiClBiClBiCoGiCoIiJeFiCmJjFgAiJoGiClDiCoKiCoJiBeC_xHqqkZx_
 * (p) _xZkqqHx_iOmAiNnLiCmJjFlGiOjKiCkKjFgAiJoGiClDiCoKiCoJiImKjChFiBeC_xHqqkZx_(o)_xZkqqHx_iCmMiImKjChFiCkJiCoHjFgAiJoGiClFiClNiCkCiCkKiBeBiClBiCmMiPoKiNiHiCmN_xHqqkZx_
 *     _xZkqqHx_iDhNiDfIiDeOiCmJiIpIiCmBiCkJiCkJiCoIiBeBiJeFiCmJiInKjDkOiBeCiOjPiCmMjFgAiJoGiJmCjEfMiImKjChFiCkJiCoHiNlGiDhNiBfLiDfHiDjDiLjHjHkDiCpA_xHqqkZx_
 *     _xZkqqHx_jChFiCkCiClN_xHqqkZx_(p)_xZkqqHx_iCkJiCoHjFgAiCkLiOgOiCnPiCoJiBeC_xHqqkZx_
 * (q) _xZkqqHx_jFlGiOjKiCmMjFgAiCkLiPeJiCoNiCoIiCmMiImKjChFiBeC_xHqqkZx_
 * (r) _xZkqqHx_jFlGiOjKiCkKjFgAiJoGiJmCjEfMiCmIiBeBiIoKjEnEiJeFiCmMiImKjChFiBeCiDhNiDfIiDeOiCmGiJeFiDhNiBfLiDfHiDjDiCpAiNgMjHlGiBeCjFeLiClI_xHqqkZx_(s)
 *     _xZkqqHx_iCoGiCoIiCoAiNlGiCmJiCkAiCoJiBeC_xHqqkZx_
 * (s) _xZkqqHx_iJeFiDhNiBfLiDfHiDjDiCmGiJeFiDeDiDjDiDgGiDjDiDgHiCpAiJmBiOfKiClFiClNiImKjChFiBeCiDhNiDfIiDeOiCmMiMgAiPpDiCmJiKnGiCoNiCoHiClI_xHqqkZx_
 *     _xZkqqHx_iClBiCoKiCoGiCoIiJeFiCmJjFlGiOjKiCkKiPjBiCkJiCoKiCoJiClBiCmGiCmNjGlDiCkCiBeC_xHqqkZx_
 * (t) _xZkqqHx_iLoJiMgAiCmMiJeFjCfLiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.27 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
int CFCWndRichEdit::CalcAlignLeftSimple (FCEditLine& edLine,
										long& lCharCount,
										mmetol& mmLeftGap, mmetol& mmRightGap,
										mmetol mmTMAscent, mmetol mmTMDescent,
										mmetol mmTMExternalLeading,
										mmetol mmAlignGap, long lCharMax,
										long lSpcIncFirst, long lSpcIncEnd, mmetol mmSpcInc)
{
	// _xZkqqHx_jFlGiOjKjAjEiCmMiDeKiDeFiDjDiDgHiCpAiCePiCmJiDiKiDfKiDgCiDgHiBeC_xHqqkZx_
	lCharCount = 0;
	// _xZkqqHx_jFlGiOjKjAjEjAkHiMmAiCmMiKgNjEeGiBeC_xHqqkZx_
	if (lCharMax < 0 || edLine.m_vEditChar.size() < lCharMax)
		lCharMax = edLine.m_vEditChar.size();
	if (lCharMax == 0) return FTWR_END_NORMAL;
	// _xZkqqHx_iDhMiDiKiDfDiDjDiCmMjAiFjFlNiDfIiDeMiDiDiDjDiDgGiBfLiDfOiCmMiKgJjEfLjHhAjFmPjAjEiBeC_xHqqkZx_
	mmetolVector mmvaCrossX[3];
	//----- _xZkqqHx_jAiFjFlNjFpLiMpMiCmJiDfIiDeMiDiDiDjD_xHqqkZx_ -----
	// _xZkqqHx_iNhDiCmMiPoDjCfLiBeFjCiGiKnEiBeFiJlKjCfLiCmMiCfCiCmCiCmMjAiFjFlNjApMiCpAiDfIiDeMiDiDiDjDiBeC_xHqqkZx_
	::PolyCrossHoriz(m_vmmptPoly.begin(), m_vmmptPoly.size(), TRUE,
					edLine.m_mmY, mmvaCrossX[0]);
	::PolyCrossHoriz(m_vmmptPoly.begin(), m_vmmptPoly.size(), TRUE,
					edLine.m_mmY + (mmTMAscent + mmTMDescent) / 2.0, mmvaCrossX[1]);
	::PolyCrossHoriz(m_vmmptPoly.begin(), m_vmmptPoly.size(), TRUE,
					edLine.m_mmY + mmTMAscent + mmTMDescent, mmvaCrossX[2]);
//----- 05.02.18 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	//----- _xZkqqHx_iDhNiBfLiDfHiDjDjFkKiLlHiCnPiCoJ_xHqqkZx_ -----
//	CrossHorizReduce(mmvaCrossX[0], m_mmMarginL, m_mmMarginR);
//	CrossHorizReduce(mmvaCrossX[1], m_mmMarginL, m_mmMarginR);
//	CrossHorizReduce(mmvaCrossX[2], m_mmMarginL, m_mmMarginR);
//----- 05.02.18 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	// _xZkqqHx_iDfIiDeMiDiDiDjDiClFiClNiCfCiCmCiCmMjAiFjFlNjApMiCpAiIoKiCmCiCmJiCnMiCmGiCnPiCoJiBeC_xHqqkZx_
	mmetolVector mmvCrossX;
	FFMakeCommonInside(mmvCrossX, mmvaCrossX, 3);
	// _xZkqqHx_iDhNiBfLiDfHiDjDjFkKiLlHiCnPiCoJiBeC_xHqqkZx_
	CrossHorizReduce(mmvCrossX, m_mmMarginL, m_mmMarginR);
//----- 05.02.18 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iJeFjBkEiCmMiMmAjDhIiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	const mmetol mmRightLimit = m_mmrtWindow.Width() -
									edLine.m_mmRightIndent - m_mmMarginR;
	//----- _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiImKjChFiCpAjCoIiCnPiCoJ_xHqqkZx_ -----
	mmetol mmLeftLimit;
	if (edLine.m_byLineType == FDRC_LT_HEAD)
		mmLeftLimit = m_mmMarginL + edLine.m_mmStartIndent;
	else	// FDRC_LT_CONTINUE.
		mmLeftLimit = m_mmMarginL + edLine.m_mmStartIndent + edLine.m_mmOffset;

	//----- _xZkqqHx_jFlGiOjKiPiJiKpKiImKjChFiCoGiCoIiJeF_xHqqkZx_ _xZkqqHx_iKiOiCmC_xHqqkZx_ _xZkqqHx_iNmFiCoAiNlGiCmJiCkAiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCpAiMhGiOfK_xHqqkZx_ -----
	mmetol mmMostLeft;
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (!GetMostLeft(mmMostLeft, 0.0, mmLeftLimit, mmvaCrossX, 3))
	if (!GetMostLeft(mmMostLeft, 0.0, mmLeftLimit, mmvCrossX))
		return FTWR_END_NORMAL;
	//----- _xZkqqHx_jFlGiOjKiJeFiMmAjDhIiCoGiCoIiNlG_xHqqkZx_ _xZkqqHx_iKiOiCmC_xHqqkZx_ _xZkqqHx_iNmFiCoAiJeFiCmJiCkAiCoJiLpDiCkLiDfIiDhJiBfLiDfIiCpAiMhGiOfK_xHqqkZx_ -----
	mmetol mmMostRight;
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (!GetMostRight(mmMostRight, 0.0, mmRightLimit, mmvaCrossX, 3))
	if (!GetMostRight(mmMostRight, 0.0, mmRightLimit, mmvCrossX))
		return FTWR_END_NORMAL;

	// _xZkqqHx_jAoGjDkKiLpDjEjCiCmMiDfEiDeDiDfJiCpAjAnNjCoIiBeC_xHqqkZx_
	mmetol mmHeadSpace = mmMostLeft - mmLeftLimit;
	// _xZkqqHx_iDfIiDfOiBfLiDgHiImKjChFiCmJiDeBiDiJiDeDiDjDiDiBiDjDiDgHjHhAiCmMiNlGiDeNiDiDiDgCiDhGiCpAiJmBiOfKiClFiCmEiCkIiCkNiBeC_xHqqkZx_
	mmetol mmX = mmMostLeft + mmAlignGap;
	// _xZkqqHx_jFlGiOjKiCkKjFgAiJoGiClDiCoKiCoJiNmAjFfHiCmMiNmFiPkMjCgMiCmGiNmFjBoFjCgMiBeC_xHqqkZx_
	mmetol mmMinCharX = mmRightLimit;
	mmetol mmMaxCharX = mmLeftLimit;
	int endType = FTWR_END_NORMAL;
	//--------------------------------------------------------------------
	// _xZkqqHx_iClBiCmMiNhDiCmMjFlGiOjKiCpAiDfIiDeMiDiDiDjDiClFiBeBiNhDiCmMiNiCiClDiBeFiNhDiCmJiOpLiCnMiCoJjFlGiOjKjAjEjDjJiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
	//--------------------------------------------------------------------
	for (; lCharCount < lCharMax; lCharCount++)
	{
		FCEditChar& eChar = (edLine.m_vEditChar)[lCharCount];
		// FONT_xZkqqHx_iPoDjFjEiCkKiKpJjBlGjCgMiCpAiJhKiCkGiCoJiOjOiBeCiClPiCoFiCmBiCmGiCkNiCoHiCkCiCmNiCgOiCgKiBeC_xHqqkZx_
		if (roughless(mmTMAscent, g_pEnv->GetSFontRec(eChar.m_foidFont)->
										GetAscent(eChar.m_wOffset)))
			endType |= FTWR_END_OVER_ASCENT;
		// FONT_xZkqqHx_iJlKjFjEiCkKiKpJjBlGjCgMiCpAiJhKiCkGiCoJiOjOiBeCiClPiCoFiCmBiCmGiCkNiCoHiCkCiCmNiCgOiCgKiBeC_xHqqkZx_
		if (roughless(mmTMDescent, g_pEnv->GetSFontRec(eChar.m_foidFont)->
										GetDescent(eChar.m_wOffset)))
			endType |= FTWR_END_OVER_DESCENT;
		// FONT_xZkqqHx_iPoDjFjEiBeBiJlKjFjEiCkKiNmFjBoFiCmMiOjOiCmNiPeJjHlJiBeC_xHqqkZx_
		if (endType != FTWR_END_NORMAL) break;

		if (eChar.m_wChar == FDRCH_RETURN)
		//----- _xZkqqHx_iJpMiNhDiCmMiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
		{
			// _xZkqqHx_iNhDiCmMiNmFiMoDiCmJiJpMiNhDiCkKiCkLiClNiOjOiCmIiCmHiBeBiLkNiIpIiCmJiJjPiClFiNjOiCnOiBeC_xHqqkZx_
			eChar.m_mmfPreSpace = 0.0;
		} else
		if (eChar.m_wChar == WCH_TAB)
		//----- _xZkqqHx_iDfOiDhFiCmMiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
		{
			// _xZkqqHx_iNmFiCoAiLnPiCkCiDfOiDhFiCmMiImKjChFiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
			mmetol mmTabX = edLine.CalcTabPos(mmX - m_mmMarginL) + m_mmMarginL;
			// _xZkqqHx_iDfOiDhFiImKjChFiCoGiCoIiJeFiKiOiCmCiNmFiCoAiNlGiCmMiLpDiCkLiImKjChFiCpAiMjPiNlIiBeC_xHqqkZx_
			mmetol mmNewX;
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//			if (GetMostLeft(mmNewX, 0.0, mmTabX, mmvaCrossX, 3) && mmNewX <= mmRightLimit)
			if (GetMostLeft(mmNewX, 0.0, mmTabX, mmvCrossX) && mmNewX <= mmRightLimit)
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiBeBiJeFjBkEiMmAjDhIiImKjChFiCmMjDoAjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ ------
			{
				eChar.m_mmfWidth = mmNewX - mmX - tw2mm(eChar.m_nAfterSpace);
			} else
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiBeBiJeFjBkEiMmAjDhIiImKjChFiCmMjDoAjBkEiCmJjGlDiCkCiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iPiIjHjNiPeJjHlJiBeCiDfOiDhFiCmNiNhDiCmJiJjPiClFiNjOiCnOiClBiCmGiCmNiPgPjHiIiCmIiCkCiBeC_xHqqkZx_
				break;
			}
			eChar.m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
			eChar.m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
			eChar.m_mmfPreSpace = 0.0;
			//----- mmMinCharX,mmMaxCharX_xZkqqHx_iCpAiNfIjAfG_xHqqkZx_ -----
			if (mmX + eChar.m_mmfPreSpace + eChar.m_mmfAbcA < mmMinCharX)
				mmMinCharX = mmX + eChar.m_mmfPreSpace + eChar.m_mmfAbcA;
			if (mmMaxCharX < mmX + eChar.m_mmfPreSpace + eChar.m_mmfWidth - eChar.m_mmfAbcC)
				mmMaxCharX = mmX + eChar.m_mmfPreSpace + eChar.m_mmfWidth - eChar.m_mmfAbcC;
		} else
		if (eChar.m_wChar == WCH_SPC)
		//----- _xZkqqHx_iLpDjEjCiCmMiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
		{
			// _xZkqqHx_iLpDjEjCiCmMjFfHiPiAjFjNiCpAiOoGjDlOiBjFjAnNjCoIiBeC_xHqqkZx_
			eChar.m_mmfWidth = g_pEnv->GetSFontRec(eChar.m_foidFont)->GetStdSpaceWidth();
			// _xZkqqHx_jHlMjCfLjBlFiCkGjHhAiCmMiJmBiOfKjFjNiCpAiNgMjHlGiBeC_xHqqkZx_
			if (lSpcIncFirst <= lCharCount && lCharCount < lSpcIncEnd)
				eChar.m_mmfWidth += mmSpcInc;
			mmetol mmNewX;
			fmmetol mmfAbcB = eChar.m_mmfWidth - eChar.m_mmfAbcA - eChar.m_mmfAbcC;
			BOOL bMostLeft;
			if (0 < lCharCount)	// _xZkqqHx_iCfBjEnEjGnKiImIiMoDiCmMjFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
				// (_xZkqqHx_iMlLiNnNiCmM_xHqqkZx_X_xZkqqHx_iImKjChF_xHqqkZx_ + AbcA)_xZkqqHx_iCoGiCoIiJeFiKiOiCmCiNmFiCoAiNlGiCmMiBgJjFjN_xHqqkZx_mmfAbcB_xZkqqHx_iCmMiBgKiLpDiCkLiImKjChFiCpAiMjPiNlIiBeC_xHqqkZx_
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX + eChar.m_mmfAbcA, mmvaCrossX, 3);
				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX + eChar.m_mmfAbcA, mmvCrossX);
			else				// _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
				// _xZkqqHx_iMlLiNnNiCmM_xHqqkZx_X_xZkqqHx_iImKjChFiCoGiCoIiJeFiKiOiCmCiNmFiCoAiNlGiCmMiBgJjFjN_xHqqkZx_mmfAbcB_xZkqqHx_iCmMiBgKiLpDiCkLiImKjChFiCpAiMjPiNlIiBeC_xHqqkZx_
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX, mmvaCrossX, 3);
				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX, mmvCrossX);

			if (bMostLeft && roughlesseq(mmNewX + mmfAbcB, mmRightLimit))
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiBeBiJeFjBkEiMmAjDhIiImKjChFiCmMjDoAjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				eChar.m_mmfPreSpace = (mmNewX - eChar.m_mmfAbcA) - mmX;
			} else
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiBeBiJeFjBkEiMmAjDhIiImKjChFiCmMjDoAjBkEiCmJjGlDiCkCiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iNhDiCmMiNmFiMoDiCmJiLpDjEjCiCkKiCkLiClNiOjOiCmIiCmHiBeBiLkNiIpIiCmJiJjPiClFiNjOiCnOiBeC_xHqqkZx_
				eChar.m_mmfPreSpace = 0.0;
			}
		} else
		//----- _xZkqqHx_iLpDjEjCiBeFjFiBjCmKiCmMjFlGiOjKiCmMiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
		{
			mmetol mmNewX;
			fmmetol mmfAbcB = eChar.m_mmfWidth - eChar.m_mmfAbcA - eChar.m_mmfAbcC;
			BOOL bMostLeft;
			if (0 < lCharCount)	// _xZkqqHx_iCfBjEnEjGnKiImIiMoDiCmMjFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
				// (_xZkqqHx_iMlLiNnNiCmM_xHqqkZx_X_xZkqqHx_iImKjChF_xHqqkZx_ + AbcA)_xZkqqHx_iCoGiCoIiJeFiKiOiCmCiNmFiCoAiNlGiCmMiBgJjFjN_xHqqkZx_mmfAbcB_xZkqqHx_iCmMiBgKiLpDiCkLiImKjChFiCpAiMjPiNlIiBeC_xHqqkZx_
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX + eChar.m_mmfAbcA, mmvaCrossX, 3);
				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX + eChar.m_mmfAbcA, mmvCrossX);
			else				// _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
				// _xZkqqHx_iMlLiNnNiCmM_xHqqkZx_X_xZkqqHx_iImKjChFiCoGiCoIiJeFiKiOiCmCiNmFiCoAiNlGiCmMiBgJjFjN_xHqqkZx_mmfAbcB_xZkqqHx_iCmMiBgKiLpDiCkLiImKjChFiCpAiMjPiNlIiBeC_xHqqkZx_
// 05.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX, mmvaCrossX, 3);
				bMostLeft = GetMostLeft(mmNewX, mmfAbcB, mmX, mmvCrossX);

			if (bMostLeft && roughlesseq(mmNewX + mmfAbcB, mmRightLimit))
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiBeBiJeFjBkEiMmAjDhIiImKjChFiCmMjDoAjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				eChar.m_mmfPreSpace = (mmNewX - eChar.m_mmfAbcA) - mmX;
			} else
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiBeBiJeFjBkEiMmAjDhIiImKjChFiCmMjDoAjBkEiCmJjGlDiCkCiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iDiLiBfLiDhGiCpAiPeJjHlJiBeC_xHqqkZx_
				break;
			}
			//----- mmMinCharX,mmMaxCharX_xZkqqHx_iCpAiNfIjAfG_xHqqkZx_ -----
			if (mmX + eChar.m_mmfPreSpace + eChar.m_mmfAbcA < mmMinCharX)
				mmMinCharX = mmX + eChar.m_mmfPreSpace + eChar.m_mmfAbcA;
			if (mmMaxCharX < mmX + eChar.m_mmfPreSpace + eChar.m_mmfWidth - eChar.m_mmfAbcC)
				mmMaxCharX = mmX + eChar.m_mmfPreSpace + eChar.m_mmfWidth - eChar.m_mmfAbcC;
		}
		//----- _xZkqqHx_jFlGiOjKiIoMiCoKiPpDjBnEiCpAjAnNjCoI_xHqqkZx_ -----
		if (roughlesseq(mmX + eChar.m_mmfPreSpace +
						eChar.m_mmfWidth - eChar.m_mmfAbcC, mmMostRight))
		//----- _xZkqqHx_jFlGiOjKiCmMiJeFjCfLiCkKiJeFiMmAiCmMjDoAjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
		{
			if (roughlesseq(mmX + eChar.m_mmfPreSpace +
							eChar.m_mmfWidth + tw2mm(eChar.m_nAfterSpace),
							mmMostRight))
			//----- _xZkqqHx_jFlGiOjKiBhLiMoDiLpDiKnEiCkKiJeFiMmAiCmMjDoAjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				eChar.m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiBeC_xHqqkZx_
			} else
			//----- _xZkqqHx_jFlGiOjKiBhLiMoDiLpDiKnEiCkKiJeFiMmAiCmMiKePjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				eChar.m_byCrossStat = FDWR_CROSS_ONLINE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAiPoDiBeC_xHqqkZx_
			}
		} else
		//----- _xZkqqHx_jFlGiOjKiCmMiJeFjCfLiCkKiJeFiMmAiCmMiKePjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
		{
			eChar.m_byCrossStat = FDWR_CROSS_OUTSIDE;		// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAiKePiBeC_xHqqkZx_
		}
		// mmX_xZkqqHx_iCpAiOjPiCnGjBjHiCoJiBeC_xHqqkZx_
		mmX += eChar.m_mmfPreSpace +
				eChar.m_mmfWidth + tw2mm(eChar.m_nAfterSpace);
	}
	// _xZkqqHx_jFmAiCnHiClNjFlGiOjKjAjEiCkKiCePiCmIiCoHiCmOiBeB_xHqqkZx_FTWR_END_NORMAL_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
	if (lCharCount == 0) return FTWR_END_NORMAL;
	//----- mmMinCharX_xZkqqHx_iBeB_xHqqkZx_mmMaxCharX_xZkqqHx_iCkKjAnNjCoIiClDiCoKiCmEiCkCiCmIiCkCiBgJiLpDjEjCiNhDiCmIiCmHiBgKiPoKiNiHiCmNiBeBiNmFiPiJiCmMjFlGiOjKiCmFiPiJiKpKiJlL_xHqqkZx_ -----
	if (mmMinCharX == mmRightLimit)
		mmMinCharX = mmMostLeft + mmAlignGap + edLine.m_vEditChar.front().m_mmfPreSpace +
					edLine.m_vEditChar.front().m_mmfAbcA;
	if (mmMaxCharX == mmLeftLimit)
		mmMaxCharX = mmMostLeft + mmAlignGap + edLine.m_vEditChar.front().m_mmfPreSpace +
					edLine.m_vEditChar.front().m_mmfWidth - edLine.m_vEditChar.front().m_mmfAbcC;
	//----- _xZkqqHx_iNhDiCmMjBkOjAkLiCpAiMhGiOfKiBeBjAnNjCoI_xHqqkZx_ -----
	edLine.m_mmfTMHeight = mmTMAscent + mmTMDescent;
	edLine.m_mmfTMAscent = mmTMAscent;
	edLine.m_mmfTMExternalLeading = mmTMExternalLeading;
	// _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiCmMiDhGiDiMiDfIiDhJiBfLiDfIiCmJiBeBjHfMiCnPiPiJiKpKjCgMiCmJjBjNiClFiCmEiCkAiCmBiClN_xHqqkZx_
	// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHjHhAiCmMiNlGiDeNiDiDiDgCiDhGiCmGiBeBjAoGjDkKiLpDjEjCiCmMiDfEiDeDiDfJiCpAiJmBiOfKiClFiCmEjFoCjAlDiClHiCoJiBeC_xHqqkZx_
	edLine.m_vEditChar.front().m_mmfPreSpace += mmAlignGap + mmHeadSpace;
	// _xZkqqHx_iNlGjBkEiDeNiDiDiDgCiDhGiCpAiMhGiOfKiBeC_xHqqkZx_
	mmLeftGap = mmMinCharX - mmMostLeft;
	// _xZkqqHx_iJeFjBkEiDeNiDiDiDgCiDhGiCpAiMhGiOfKiBeC_xHqqkZx_
	mmRightGap = mmMostRight - mmMaxCharX;
	return endType;
} // CFCWndRichEdit::CalcAlignLeftSimple.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::IsWrapedWordE
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjFlGiOjKiImKjChFiCkKiJhAjFlGjCfAiMoKiLkLiKeFiCkJiCmHiCkEiCkJiCpAjClCiCnHiCoJiBeCjCfAiMoKiLkLiKeFiCmF_xHqqkZx_
 *			_xZkqqHx_iCmIiCkCiPoKiNiHiCmNiBeBjFlGiOjKiImKjChFiCoGiCoIiCoAjBePiKiOiCmCiNmFiCoAiMoDiCoLiCmMjCfAiMoKiLkLiKeFiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lNewCount	:_xZkqqHx_jCfAiMoKiLkLiKeFiImKjChF_xHqqkZx_(_xZkqqHx_iLkLiKeFiCmMiJeFiCmMjFlGiOjK_xHqqkZx_idx)_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *			vEditChar	:_xZkqqHx_jClCiCnHiCoJiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lCharCount	:_xZkqqHx_jClCiCnHiCoJjFlGiOjKiImKjChF_xHqqkZx_(_xZkqqHx_iLkLiKeFiCmMiJeFiCmMjFlGiOjK_xHqqkZx_idx)_xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jCfAiMoKiLkLiKeFiCmMiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_jDpKjGhLiMoKiDfCiBfLiDgIiCoAiNkMiClGiCmBiCmEiCkCiCkCiCoJiCmMiCmFiBeBjFlGiOjKjEoEiKhCiCmNiPgPjHiIiCoJiClOiCkP_xHqqkZx_ == _xZkqqHx_iCmF_xHqqkZx_
 *			_xZkqqHx_iNhDiCkEiClBiCmGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.28 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::IsWrapedWordE (long& lNewCount, const FCEditCharVector& vEditChar,
									long lCharCount) const
{
	// _xZkqqHx_iJhAiMoKjAkOiMgAiDiLiBfLiDiLiCfAiCkKjGlDiMpIiCmIiCoHiCmOiBeBjAfOiCpAjFnEiClHiBeC_xHqqkZx_
	if (!g_pReg->GetIsTextFormE1()) return TRUE;
	if (lCharCount <= 0 || vEditChar.size() <= lCharCount) return TRUE;
	long lChar = lCharCount;
	for (;;)
	{
		if (lChar < 0)
		{
			lNewCount = 0;
			break;
		}
		if (vEditChar[lChar].m_wChar == FDRCH_RETURN ||
			vEditChar[lChar].m_wChar == L'.' ||
			vEditChar[lChar].m_wChar == L',' ||
			vEditChar[lChar].m_wChar == L'?' ||
			vEditChar[lChar].m_wChar == L'!' ||
			vEditChar[lChar].m_wChar == L';' ||
			vEditChar[lChar].m_wChar == L':')
		{
			lChar--;
			for (; 0 <= lChar; lChar--)
			{
				if (vEditChar[lChar].m_wChar == L'.' ||
					vEditChar[lChar].m_wChar == L',' ||
					vEditChar[lChar].m_wChar == L'?' ||
					vEditChar[lChar].m_wChar == L'!' ||
					vEditChar[lChar].m_wChar == L';' ||
					vEditChar[lChar].m_wChar == L':') continue;

				break;
			}
		} else
		if (vEditChar[lChar].m_wChar == WCH_TAB ||
			vEditChar[lChar].m_wChar == WCH_SPC)
		{
			long lTmp;
			for (lTmp = lChar + 1; lTmp < vEditChar.size(); lTmp++)
			{
				if (vEditChar[lTmp].m_wChar == WCH_TAB ||
					vEditChar[lTmp].m_wChar == WCH_SPC) continue;
				break;
			}
			if (lTmp < vEditChar.size() &&
				(vEditChar[lTmp].m_wChar == FDRCH_RETURN ||
				 vEditChar[lTmp].m_wChar == L'.' ||
				 vEditChar[lTmp].m_wChar == L',' ||
				 vEditChar[lTmp].m_wChar == L'?' ||
				 vEditChar[lTmp].m_wChar == L'!' ||
				 vEditChar[lTmp].m_wChar == L';' ||
				 vEditChar[lTmp].m_wChar == L':'))
			{
				for (; 0 <= lChar; lChar--)
				{
					if (vEditChar[lChar].m_wChar == WCH_TAB ||
						vEditChar[lChar].m_wChar == WCH_SPC) continue;
						break;
				}
			} else
			{
				lNewCount = lChar;
				break;
			}
		} else
		{
			lChar--;
			for (; 0 <= lChar; lChar--)
			{
				if (vEditChar[lChar].m_wChar == WCH_TAB ||
					vEditChar[lChar].m_wChar == WCH_SPC ||
					vEditChar[lChar].m_wChar == L'-' ||
					vEditChar[lChar].m_wChar == L'.' ||
					vEditChar[lChar].m_wChar == L',' ||
					vEditChar[lChar].m_wChar == L'?' ||
					vEditChar[lChar].m_wChar == L'!' ||
					vEditChar[lChar].m_wChar == L';' ||
					vEditChar[lChar].m_wChar == L':')
					break;
				// ANSI_xZkqqHx_iDfCiBfLiDgIiImIiKePiCmIiCoHiCmOiBeBjGlDiPpAiMiPiCmJiPeJjHlJiBeC_xHqqkZx_
				if (FDCK_ANSI_END < FFGetCharKind(vEditChar[lChar].m_wChar)) break;
			}
			lNewCount = lChar + 1;
			break;
		}
	}
	return (lNewCount == lCharCount);
} // CFCWndRichEdit::IsWrapedWordE.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::IsWrapedWordJ
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjFlGiOjKiImKjChFiCkKjIgBjFlGiLkLiKeFiCkJiCmHiCkEiCkJiCpAjClCiCnHiCoJiBeCiLkLiKeFiCmF_xHqqkZx_
 *			_xZkqqHx_iCmIiCkCiPoKiNiHiCmNiBeBjFlGiOjKiImKjChFiCoGiCoIiCoAjBePiKiOiCmCiNmFiCoAiMoDiCoLiCmMiLkLiKeFiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lNewCount	:_xZkqqHx_jIgBjFlGiLkLiKeFiImKjChF_xHqqkZx_(_xZkqqHx_iLkLiKeFiCmMiJeFiCmMjFlGiOjK_xHqqkZx_idx)_xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *			vEditChar	:_xZkqqHx_jClCiCnHiCoJiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lCharCount	:_xZkqqHx_jClCiCnHiCoJjFlGiOjKiImKjChF_xHqqkZx_(_xZkqqHx_iLkLiKeFiCmMiJeFiCmMjFlGiOjK_xHqqkZx_idx)_xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jIgBjFlGiLkLiKeFiCmMiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iJhAiMoKiDfCiBfLiDgIiCoAiNkMiClGiCmBiCmEiCkCiCkCiCoJiCmMiCmFiBeBjFlGiOjKjEoEiKhCiCmNiPgPjHiIiCoJiClOiCkP_xHqqkZx_ == _xZkqqHx_iCmF_xHqqkZx_
 *			_xZkqqHx_iNhDiCkEiClBiCmGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.28 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::IsWrapedWordJ (long& lNewCount, const FCEditCharVector& vEditChar,
									long lCharCount) const
{
	// _xZkqqHx_jDpKjGhLiMoKjAkOiMgAiDiLiBfLiDiLiCfAiCkKjGlDiMpIiCmIiCoHiCmOiBeBjAfOiCpAjFnEiClHiBeC_xHqqkZx_
	if (!g_pReg->GetIsTextFormJ1()) return TRUE;
	if (lCharCount <= 0 || vEditChar.size() <= lCharCount) return TRUE;
	long lChar = lCharCount;
	for (;;)
	{
		if (lChar < 0)
		{
			lNewCount = 0;
			break;
		}
		if (vEditChar[lChar].m_wChar == FDRCH_RETURN ||
			vEditChar[lChar].m_wChar == WCH_ZEN_TOUTEN ||
			vEditChar[lChar].m_wChar == WCH_ZEN_KUTEN ||
//----- 06.05.03 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
			vEditChar[lChar].m_wChar == WCH_ZEN_COMMA ||
			vEditChar[lChar].m_wChar == WCH_ZEN_PERIOD ||
//----- 06.05.03 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
			vEditChar[lChar].m_wChar == WCH_HAN_TOUTEN ||
			vEditChar[lChar].m_wChar == WCH_HAN_KUTEN)
		{
			lChar--;
			for (; 0 <= lChar; lChar--)
			{
				if (vEditChar[lChar].m_wChar == WCH_ZEN_TOUTEN ||
					vEditChar[lChar].m_wChar == WCH_ZEN_KUTEN ||
//----- 06.05.03 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
					vEditChar[lChar].m_wChar == WCH_ZEN_COMMA ||
					vEditChar[lChar].m_wChar == WCH_ZEN_PERIOD ||
//----- 06.05.03 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
					vEditChar[lChar].m_wChar == WCH_HAN_TOUTEN ||
					vEditChar[lChar].m_wChar == WCH_HAN_KUTEN) continue;
				break;
			}
		} else
		if (vEditChar[lChar].m_wChar == WCH_TAB ||
			vEditChar[lChar].m_wChar == WCH_SPC ||
			vEditChar[lChar].m_wChar == WCH_ZEN_SPC)
		{
			long lTmp;
			for (lTmp = lChar + 1; lTmp < vEditChar.size(); lTmp++)
			{
				if (vEditChar[lTmp].m_wChar == WCH_TAB ||
					vEditChar[lTmp].m_wChar == WCH_SPC ||
					vEditChar[lTmp].m_wChar == WCH_ZEN_SPC) continue;
				break;
			}
			if (lTmp < vEditChar.size() &&
				(vEditChar[lTmp].m_wChar == FDRCH_RETURN ||
				 vEditChar[lTmp].m_wChar == WCH_ZEN_TOUTEN ||
				 vEditChar[lTmp].m_wChar == WCH_ZEN_KUTEN ||
//----- 06.05.03 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
				vEditChar[lTmp].m_wChar == WCH_ZEN_COMMA ||
				vEditChar[lTmp].m_wChar == WCH_ZEN_PERIOD ||
//----- 06.05.03 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
				 vEditChar[lTmp].m_wChar == WCH_HAN_TOUTEN ||
				 vEditChar[lTmp].m_wChar == WCH_HAN_KUTEN))
			{
				for (; 0 <= lChar; lChar--)
				{
					if (vEditChar[lChar].m_wChar == WCH_TAB ||
						vEditChar[lChar].m_wChar == WCH_SPC ||
						vEditChar[lChar].m_wChar == WCH_ZEN_SPC) continue;
						break;
				}
			} else
			{
				lNewCount = lChar;
				break;
			}
		} else
		{
			FDCharKind cKind = FFGetCharKind(vEditChar[lChar].m_wChar);
			lChar--;
			// _xZkqqHx_jBfDiKhAiDeBiDiLiDhEiDeAiDhIiDgCiDgHiCpAiDiPiBfLiDgIiDiJiDgCiDhGjBmOiPnLiCmJiBeC_xHqqkZx_
			// _xZkqqHx_iDeKiDfOiDeKiDgJiCmNiBeBjBfDjFjEiDeKiDfOiDeKiDgJiCmMjFlGiPmNiCmMiPoKiNiHiCpAiNgMjHlGiClFiCmEiBeB_xHqqkZx_
			// _xZkqqHx_iDiPiBfLiDgIiDiJiDgCiDhGiCmMjBmOiPnLiKePiCmGiClHiCoJiBeC_xHqqkZx_
			// _xZkqqHx_iDeNiDiKiDfGiDiDiBeBiDiNiDfGiDeBjFlGiOjKiCmNiBeBiDiPiBfLiDgIiDiJiDgCiDhGiCmMjBmOiPnLiCmGiClFiCmEiCoA_xHqqkZx_
			// _xZkqqHx_iOmAjHhAjAkLiCkKjCoBiCkCiBeCiCnMiClNiBeB_xHqqkZx_UNICODE_xZkqqHx_iCmJiCkIiCkCiCmEiCmNjBfDiKhAiDfCiBfLiDgIiCmFiCmNjGlDiCkCiBeC_xHqqkZx_
			if (cKind == FDCK_ZENK_ALPHABET)
			{
				for (; 0 <= lChar; lChar--)
				{
					if (cKind != FFGetCharKind(vEditChar[lChar].m_wChar)) break;
				}
			}
			lNewCount = lChar + 1;
			break;
		}
	}
	return (lNewCount == lCharCount);
} // CFCWndRichEdit::IsWrapedWordJ.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineAlignRight
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiCmMiOhHjCoIiClDiCoKiClNjFlGiOjKiImKjChFiCkJiCoHiBeBiNhDjDkKiCmJiMpMiCkJiCmBiCmEiJeFiKpBiClJ_xHqqkZx_
 *			_xZkqqHx_iCmGiClFiCmEjFlGiOjKiImKjChFiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	edLine	:_xZkqqHx_iMhGiOfKiClHiCoJiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lCharSz	:_xZkqqHx_iMhGiOfKiClHiCoJjFlGiOjKjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iNhDiCmJiOpLiCnMiCmBiClNjFlGiOjKjAjEiCpAjFnEiClHiBeC_xHqqkZx_lCharSz_xZkqqHx_iCpAiJhKiCkGiCoJiClBiCmGiCmNjGlDiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	edLine = "ABCDEFGHIJK" lCharSz = 5 _xZkqqHx_iCmMiPoKiNiHiBeC_xHqqkZx_
 *			"E"_xZkqqHx_iCkJiCoHiNlGiBgJ_xHqqkZx_"E"_xZkqqHx_iCpAiKnMiCnOiBgKiCpAiBeBiJeFiLgMiCnPiCmJiClHiCoJiClNiCnPiCmMiMhGiOfKiCpAiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iNhDiCmM_xHqqkZx_m_mmY_xZkqqHx_iCpAiKoOiPiAiCmJiMhGiOfKiClHiCoJiBeCiClBiCmMjCgMiCmNjFmPiNfIiClFiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.21 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::CalcLineAlignRight (FCEditLine& edLine, long lCharSz)
{
	//----- _xZkqqHx_iNhDiCmMiNiCiClDiPoOjFpB_xHqqkZx_ -----
	mmetol	mmTMAscent = -1.0;
	mmetol	mmTMDescent = -1.0;
	mmetol	mmTMExternalLeading = -1.0;
	FCEditCharVector& evChar = edLine.m_vEditChar;
	long lC;
	//----- _xZkqqHx_iNhDjDkKiCkJiCoH_xHqqkZx_lCharSz_xZkqqHx_iCnMiCmFiCmMjFlGiOjKiCkJiCoHiBeBiNhDiCmMiNiCiClDiPoOjFpBiCpAiMhGiOfK_xHqqkZx_ -----
	for (lC = 0; lC < lCharSz; lC++)
	{
		/*----- FONT_xZkqqHx_iPoDjFjEiCkKiNmFjBoFiCmMiOjOiCmNiPoDjHfNjEjCiCoAiClBiCoKiCmJiPfNiCkE_xHqqkZx_ -----*/
		if (mmTMAscent < g_pEnv->GetSFontRec(evChar[lC].m_foidFont)->GetAscent(evChar[lC].m_wOffset))
		{
			mmTMAscent = g_pEnv->GetSFontRec(evChar[lC].m_foidFont)->GetAscent(evChar[lC].m_wOffset);
		}
		/*----- FONT_xZkqqHx_iJlKjFjEiCkKiNmFjBoFiCmMiOjOiCmNiJlKjHfNjEjCiCoAiClBiCoKiCmJiPfNiCkE_xHqqkZx_ -----*/
		if (mmTMDescent < g_pEnv->GetSFontRec(evChar[lC].m_foidFont)->GetDescent(evChar[lC].m_wOffset))
		{
			mmTMDescent = g_pEnv->GetSFontRec(evChar[lC].m_foidFont)->GetDescent(evChar[lC].m_wOffset);
			mmTMExternalLeading = g_pEnv->GetSFontRec(evChar[lC].m_foidFont)->GetExternalLeading(evChar[lC].m_wOffset);
		}
	}
	edLine.m_mmfTMHeight			= mmTMAscent + mmTMDescent;
	edLine.m_mmfTMAscent			= mmTMAscent;
	edLine.m_mmfTMExternalLeading	= mmTMExternalLeading;

	// _xZkqqHx_iDhMiDiKiDfDiDjDiCmMjAiFjFlNiDfIiDeMiDiDiDjDiDgGiBfLiDfOiCmMiKgJjEfLjHhAjFmPjAjEiBeC_xHqqkZx_
	mmetolVector mmvaCrossX[3]; // _xZkqqHx_iDeOiDiJiDfIjEhKjHpBiCmFiCoAiDfCiDjDiDfIiDgHiDiJiDeOiDfOiCmNiMmEiCmOiCoKiCoJiBeC_xHqqkZx_
	// _xZkqqHx_jAiFjFlNjFpLiMpMiCmJiDfIiDeMiDiDiDjDiBeC_xHqqkZx_
	::PolyCrossHoriz(m_vmmptPoly.begin(), m_vmmptPoly.size(), TRUE, edLine.m_mmY, mmvaCrossX[0]);
	::PolyCrossHoriz(m_vmmptPoly.begin(), m_vmmptPoly.size(), TRUE,
				edLine.m_mmY + (mmTMAscent + mmTMDescent) / 2.0, mmvaCrossX[1]);
	::PolyCrossHoriz(m_vmmptPoly.begin(), m_vmmptPoly.size(), TRUE,
				edLine.m_mmY + mmTMAscent + mmTMDescent, mmvaCrossX[2]);
//----- 05.02.18 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	// _xZkqqHx_iDhNiBfLiDfHiDjDjFkKiLlHiCnPiCoJiBeC_xHqqkZx_
//	CrossHorizReduce(mmvaCrossX[0], m_mmMarginL, m_mmMarginR);
//	CrossHorizReduce(mmvaCrossX[1], m_mmMarginL, m_mmMarginR);
//	CrossHorizReduce(mmvaCrossX[2], m_mmMarginL, m_mmMarginR);
//----- 05.02.18 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	// _xZkqqHx_iDfIiDeMiDiDiDjDiClFiClNiCfCiCmCiCmMjAiFjFlNjApMiCpAiIoKiCmCiCmJiCnMiCmGiCnPiCoJiBeC_xHqqkZx_
	mmetolVector mmvCrossX;
	FFMakeCommonInside(mmvCrossX, mmvaCrossX, 3);
	// _xZkqqHx_iDhNiBfLiDfHiDjDjFkKiLlHiCnPiCoJiBeC_xHqqkZx_
	CrossHorizReduce(mmvCrossX, m_mmMarginL, m_mmMarginR);
//----- 05.02.18 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

	//----- _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiImKjChFiCpAjCoIiCnPiCoJ_xHqqkZx_ -----
	// _xZkqqHx_iJeFjBkEiCmMiMmAjDhIiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	const mmetol mmRightLimit = m_mmrtWindow.Width() -
								m_mmMarginR - edLine.m_mmRightIndent;
	// _xZkqqHx_iNlGjBkEiCmMiMmAjDhIiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	mmetol mmLeftLimit;
	if (edLine.m_byLineType == FDRC_LT_HEAD)
		mmLeftLimit = m_mmMarginL + edLine.m_mmStartIndent;
	else	// FDRC_LT_CONTINUE.
		mmLeftLimit = m_mmMarginL + edLine.m_mmStartIndent + edLine.m_mmOffset;
	// _xZkqqHx_iDhMiDiKiDfDiDjDjCiGiCmMiNmFiCoAiJeFiCmJiCkAiCoJjFjNiCePiCmMiLpDiCkLiDfIiDhJiBfLiDfIiCpAiMhGiOfKiBeC_xHqqkZx_
	mmetol mmMostRight;
	if (!GetMostRight(mmMostRight, 0.0, mmRightLimit, mmvCrossX))
		return 0;
	// _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiImKjChFiBeC_xHqqkZx_
	mmetol mmX = mmMostRight;

	FCEditChar eDummy;
	FCEditChar* pCharR;	// _xZkqqHx_iMlLiNnNiMhGiOfKjCiGiCmMjFlGiOjKiCmMiJeFjHnHiCoIiCmMjFlGiOjKiCmMiDhMiDeDiDjDiDfOiBeC_xHqqkZx_
	//----- lCharSz_xZkqqHx_iCkKiNhDjBfDjFjEiCmIiCoHiCmOiBeBiJeFjHnHiCoIjFlGiOjKiDhMiDeDiDjDiDfOiCmJiDfPiDhOiBfLiCpAjAnNjCoI_xHqqkZx_ -----
	if (lCharSz < evChar.size())
		pCharR = &evChar[lCharSz];
	else
		pCharR = &eDummy;

	//----- _xZkqqHx_iNhDjGjGiCmJjFmAiCnEiLpDjEjCiCpAiDfIiDeMiDgCiDhGiClFiCmEiCkIiCkN_xHqqkZx_ -----
	long lLastChar;
	for (lLastChar = lCharSz - 1; 0 <= lLastChar; lLastChar--)
	{
		if (evChar[lLastChar].m_wChar != FDRCH_RETURN &&
			evChar[lLastChar].m_wChar != FDRCH_CONTINUE &&
			evChar[lLastChar].m_wChar != WCH_SPC) break;
	}
	// _xZkqqHx_iLpDjEjCiClOiCkPiCmMiNhDiCmIiCoHiCmOiBeBiNlGiLgMiCnPiCmMiCnMiCnMiPeJjHlJiBeC_xHqqkZx_
	if (lLastChar < 0) return lCharSz;

	//--------------------------------------------------------------
	// A         B         C
	//  |<->|<->| |<->|<->| |<->|  
    //    p   q  r        x
	// p:A_xZkqqHx_iCmM_xHqqkZx_nAfterSpace
	// q:B_xZkqqHx_iCmM_xHqqkZx_mmPreSpace
	// r:B_xZkqqHx_iCmM_xHqqkZx_mmfWidth
	//
	// _xZkqqHx_iJlKiLeMiDiLiBfLiDhGiCmFiBeB_xHqqkZx_evChar[lC] = B _xZkqqHx_iCmMiPoKiNiHiBeB_xHqqkZx_mmX _xZkqqHx_iCmN_xHqqkZx_ x _xZkqqHx_iCmMiImKjChFiCmJiCkAiCoJiBeC_xHqqkZx_
	//--------------------------------------------------------------

	// _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiCkJiBeIiBgJiJpMiNhDiBeBiMhAjBlBiNhDiDfCiBfLiDgIiCmNiPjMiCkNiBgK_xHqqkZx_
	BOOL bFirst = TRUE;
	mmetol mmNewX;
	for (lC = lLastChar; 0 <= lC; lC--)
	{
		switch (evChar[lC].m_wChar)
		{
		case FDRCH_RETURN:
		case FDRCH_CONTINUE:
			break;
		case WCH_TAB:	//----- _xZkqqHx_iDfOiDhFiCmMiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
		  {
			// _xZkqqHx_iNmFiCoAiLnPiCkCiDfOiDhFiCmMiImKjChFiCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
			mmNewX = edLine.CalcTabRPos(mmX - m_mmMarginL) + m_mmMarginL;
			// _xZkqqHx_iDfOiDhFiImKjChFiCoGiCoIiNlGiKiOiCmCiNmFiCoAiJeFiCmMiBgJjFjN_xHqqkZx_0_xZkqqHx_iCoGiCoIjBoFiCkLiCkCiBgKiLpDiCkLiImKjChFiCpAiMjPiNlIiBeC_xHqqkZx_
			if (GetMostRight(mmNewX, 0.0, mmNewX, mmvCrossX))
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iJeFjHnHjFlGiOjKiCmMjBePiLpDjEjCiCpAjAnNjCoIiBeC_xHqqkZx_
				pCharR->m_mmfPreSpace = 0.0;
				evChar[lC].m_mmfWidth = mmX - mmNewX - tw2mm(evChar[lC].m_nAfterSpace);
				evChar[lC].m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				evChar[lC].m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				mmX = mmNewX;
			} else
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
			{
				return lCharSz - 1 - lC;
			}
			bFirst = FALSE;
			break;
		  }
		default:	//----- _xZkqqHx_iDfOiDhFiImIiKePiCmMiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
		  {
			// _xZkqqHx_iLpDjEjCiCmMiPoKiNiHiBeBjFfHiPiAjFjNiCpAiOoGjDlOiBjFjAnNjCoIiBeC_xHqqkZx_
			if (evChar[lC].m_wChar == WCH_SPC)
				evChar[lC].m_mmfWidth = g_pEnv->GetSFontRec(evChar[lC].m_foidFont)->
													GetStdSpaceWidth();
			// _xZkqqHx_iMlLiNnNiCmM_xHqqkZx_X_xZkqqHx_iImKjChFiCoGiCoIiNlGiKiOiCmCiNmFiCoAiJeFiCmMiBgJ_xHqqkZx_mmfAbcB_xZkqqHx_iCkKiOpLiCnMiCoJjFjNiCmMiBgKiLpDiCkLiImKjChFiCpAiMjPiNlIiBeC_xHqqkZx_
			fmmetol mmfAbcB = evChar[lC].m_mmfWidth - evChar[lC].m_mmfAbcA - evChar[lC].m_mmfAbcC;
			BOOL bR;
			if (bFirst)
				bR = GetMostRight(mmNewX, mmfAbcB, mmX, mmvCrossX);
			else
				bR = GetMostRight(mmNewX, mmfAbcB,
								mmX - evChar[lC].m_mmfAbcC - tw2mm(evChar[lC].m_nAfterSpace),
								mmvCrossX);
			if (bR)
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iJeFjHnHjFlGiOjKiCmMjBePiLpDjEjCiCpAjAnNjCoIiBeC_xHqqkZx_
				pCharR->m_mmfPreSpace = mmX - (mmNewX + evChar[lC].m_mmfAbcC +
												tw2mm(evChar[lC].m_nAfterSpace));
				mmX -= pCharR->m_mmfPreSpace +
						tw2mm(evChar[lC].m_nAfterSpace) + evChar[lC].m_mmfWidth;
			} else
			//----- _xZkqqHx_iLpDiCkLiImKjChFiCkKiCmIiCkCiPoKiNiH_xHqqkZx_ -----
			{
				return lCharSz - 1 - lC;
			}
			bFirst = FALSE;
		  }
		}
		// _xZkqqHx_iJeFjHnHjFlGiOjKiCmJiMlLiNnNiCmMjFlGiOjKiCpAjAnNjCoIiBeCiOjPiCmMiDiLiBfLiDhGiCnGiBeCiBeC_xHqqkZx_
		pCharR = &evChar[lC];
	}
	// _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiCmMjBePiLpDjEjCiCpAjCoIiCnPiCoJiBeC_xHqqkZx_
	pCharR->m_mmfPreSpace = mmX - mmLeftLimit;
	//----- _xZkqqHx_jFlGiOjKiIoMiCoKiPpDjBnEiCpAjAnNjCoI_xHqqkZx_ -----
	// _xZkqqHx_iNmFiPiJiCmMjFlGiOjKiImKjChFiBeC_xHqqkZx_
	mmX = mmLeftLimit;
	for (lC = 0; lC < lCharSz; lC++)
	{
		if (roughlesseq(mmX + evChar[lC].m_mmfPreSpace +
						evChar[lC].m_mmfWidth - evChar[lC].m_mmfAbcC, mmMostRight))
		//----- _xZkqqHx_jFlGiOjKiCmMiJeFjCfLiCkKiJeFiMmAiCmMjDoAjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
		{
			if (roughlesseq(mmX + evChar[lC].m_mmfPreSpace +
							evChar[lC].m_mmfWidth + tw2mm(evChar[lC].m_nAfterSpace),
							mmMostRight))
			//----- _xZkqqHx_jFlGiOjKiBhLiMoDiLpDiKnEiCkKiJeFiMmAiCmMjDoAjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				evChar[lC].m_byCrossStat = FDWR_CROSS_INSIDE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAjDoAiBeC_xHqqkZx_
			} else
			//----- _xZkqqHx_jFlGiOjKiBhLiMoDiLpDiKnEiCkKiJeFiMmAiCmMiKePjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
			{
				evChar[lC].m_byCrossStat = FDWR_CROSS_ONLINE;	// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAiPoDiBeC_xHqqkZx_
			}
		} else
		//----- _xZkqqHx_jFlGiOjKiCmMiJeFjCfLiCkKiJeFiMmAiCmMiKePjBkEiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
		{
			evChar[lC].m_byCrossStat = FDWR_CROSS_OUTSIDE;		// _xZkqqHx_jFlGiOjKiCkKiDhEiDiMiBfLiDiAiKePiBeC_xHqqkZx_
		}
		// mmX_xZkqqHx_iCpAiOjPiCnGjBjHiCoJiBeC_xHqqkZx_
		mmX += evChar[lC].m_mmfPreSpace +
				evChar[lC].m_mmfWidth + tw2mm(evChar[lC].m_nAfterSpace);
	}
	//----- _xZkqqHx_iNhDjGjGiCmJjFmAiCnEiLpDjEjCiCmMjBePiLpDiKnEiCpA_xHqqkZx_0_xZkqqHx_iCmJiClFiCmEiCkIiCkN_xHqqkZx_ -----
	for (lC = lLastChar + 1; lC < lCharSz; lC++)
	{
		// _xZkqqHx_iNhDjGjGiLpDjEjCiCmMjBePiLpDjEjCiCmN_xHqqkZx_0_xZkqqHx_iCmJiBeC_xHqqkZx_
		evChar[lC].m_mmfPreSpace = 0.0;
	}
	return lCharSz;
} // CFCWndRichEdit::CalcLineAlignRight.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcLineAlignLeftright
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiNhDiCmMiNhDjDkKiCkJiCoHiBeBiOhHjCoIiCmMjFlGiOjKjAjEiCpAiLmPjDjJiCmJjEhKjChFiClHiCoJiCoGiCkEiCmJ_xHqqkZx_
 *			_xZkqqHx_iMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	edLine		:_xZkqqHx_iMhGiOfKiClHiCoJiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lCharSz		:_xZkqqHx_iMhGiOfKiClHiCoJjFlGiOjKjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmRightGap	:_xZkqqHx_iNlGiLgMiCnPiCmFiMhGiOfKiClFiClNiPoKiNiHiCmJiBeBiJeFiCmJjAlGiClGiClNiDeNiDiDiDgCiDhGiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jHlMjCfLjBlFiCkGiCkKjAkMiMpHiClFiClNiCoH_xHqqkZx_ TRUE_xZkqqHx_iBeCiOlIjEhDiClHiCoJiClBiCmGiCmNjHeMiCoIiCkGiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jEhKjChFiCmMiLmPjDjJiJlLiCmNiBeBiLpDjEjCiCmMjFjNiCmFjClCjAkOiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iNhDiCmMiNmFiMoDiCmMiJpMiNhDiBeBiLpDjEjCiBeBiDfOiDhFjFlGiOjKiCmNiLmPjDjJiJlLiCmMjBmOiPnLiCmGiClFiCmIiCkCiBeC_xHqqkZx_
 *			_xZkqqHx_iDfOiDhFjFlGiOjKiCkKiKnMiCnMiCoKiCoJiPoKiNiHiCmNiBeBiDfOiDhFjFlGiOjKiImIiNhOiCmFiNmFiPiJiCmJjDgPiPoKiClHiCoJjFiBjCmKjFlGiOjK_xHqqkZx_
 *			_xZkqqHx_iImIiNhOiCpAjHlMjCfLjBlFiCkGiCmGiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iNhDjCiGiCmJiKnMiCnMiCoKiCoJiLpDjEjCiCmMjFjNiCkKjFmPiNfIiClDiCoKiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iNhDiCmM_xHqqkZx_m_mmY,m_mmAscent,m_mmfTMHeight,mmTMExternalLeading_xZkqqHx_iCpAiKoOiPiAiCmJ_xHqqkZx_
 *			_xZkqqHx_iMhGiOfKiClHiCoJiBeCiClBiCmMjCgMiCmNjFmPiNfIiClFiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.02.09 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::CalcLineAlignLeftright (FCEditLine& edLine, long lCharSz,
											mmetol mmRightGap)
{
	long lC;	// _xZkqqHx_jEmEjHhAiDeKiDeFiDjDiDfOiBeC_xHqqkZx_
	//----- _xZkqqHx_iCnMiClIiBeBjHeMiMpIiCmIjFlGiOjKjEmNiImNiCpAiOoGjDlOiClHiCoJ_xHqqkZx_ -----------------
	// _xZkqqHx_iNmFiPiJiCmMiLpDjEjCiCpAiPjMiCkNiBeCiDfOiDhFiImKjChFiImIiNhOiBeBiNmFiMoDiCmMiLpDjEjCiJpMiNhDiCpAiPjMiCkNiBeC_xHqqkZx_
	// _xZkqqHx_jHoBiCkGiCmO_xHqqkZx_  "    ABCD	EFG X    " _xZkqqHx_iCmMiPoKiNiH_xHqqkZx_
	// "EFG X"_xZkqqHx_iCkKjHeMiMpIiCmIjFlGiOjKjEmNiImNiBeC_xHqqkZx_
	//------------------------------------------------------
	long lFirst = -1;	// _xZkqqHx_iNmFiPiJiCmMjFiBjCmKiCmMjFlGiOjKiBeC_xHqqkZx_
	long lLast = -1;	// _xZkqqHx_iNmFiMoDiCmMjFiBjCmKiCmMjFlGiOjKiBeC_xHqqkZx_
	for (lC = 0; lC < lCharSz; lC++)
	{
		switch (edLine.m_vEditChar[lC].m_wChar)
		{
		case FDRCH_CONTINUE:	// _xZkqqHx_iMhAjBlBjFlGiOjKiBeCjHeMiCoIiCkGiCmIiCkCiCkKiBeCiBeC_xHqqkZx_
		case FDRCH_RETURN:		// _xZkqqHx_iJpMiNhDiBeC_xHqqkZx_
		case WCH_SPC:			// _xZkqqHx_iLpDjEjCiBeC_xHqqkZx_
			break;
		case WCH_TAB:			// _xZkqqHx_iDfOiDhFiBeC_xHqqkZx_
			// _xZkqqHx_jFlGiOjKjEmNiImNiCmMiNmFiPiJiCpAiDiKiDfKiDgCiDgHiBeC_xHqqkZx_
			lFirst = -1;
			break;
		default:				// _xZkqqHx_jFiBjCmKiCmMjFlGiOjKiBeC_xHqqkZx_
			if (lFirst < 0) lFirst = lC;
			lLast = lC;
		}
	}
	// _xZkqqHx_jFiBjCmKiCmMjFlGiOjKiCkKjGlDiCkCiPoKiNiHiBeBiIlNiCkCiCmNiNmFiMoDiCmMjFpLiCmJiDfOiDhFiCkKiCkAiCoJiPoKiNiHiCmNjClCjAkOjFhDjHhGiBeC_xHqqkZx_
	if (lFirst < 0) return TRUE;

	//----- _xZkqqHx_jHeMiMpIiCmIjFlGiOjKjEmNiImNiCmJiKnMiCnMiCoKiCoJiLpDjEjCiCmMjAjEiCpAiDeKiDeFiDjDiDgH_xHqqkZx_ -----
	long lSpcC = 0;
	for (lC = lFirst; lC <= lLast; lC++)
		if (edLine.m_vEditChar[lC].m_wChar == WCH_SPC) lSpcC++;
	// _xZkqqHx_iLpDjEjCiCkKjGlDiCkCiPoKiNiHiCmNjFjMiLeBiBeC_xHqqkZx_
	if (lSpcC == 0) return TRUE;
	// _xZkqqHx_iLpDjEjCiCfAjFlGiOjKjDjGiClNiCoIiCmMiJmBiOfKjFjNiCpAiOfKiPgPiBeC_xHqqkZx_
	mmetol mmGapInc = mmRightGap / double(lSpcC);
	// _xZkqqHx_iPkNiClFiClOiCkPiIpIiCkCiCmEiCkIiCkNiBeCiNiHiMhGiClFiClNiOjOiBeBiJeFiMmAiCoGiCoIjEpHjGkNiCmJiPkMiClDiCkNiCmIiCoJiCoGiCkEiCmJiBeC_xHqqkZx_
	mmGapInc -= MY_DBL_ABOUT_EPSILON;

	mmetol mmTMAscent = edLine.m_mmfTMAscent;
	mmetol mmTMDescent = edLine.m_mmfTMHeight - edLine.m_mmfTMAscent;
	mmetol mmTMExternalLeading = edLine.m_mmfTMExternalLeading;
	mmetol mmLeft;
	mmetol mmRight;
	long lCharCount = -1;
	int endCode = CalcAlignLeftSimple(edLine, lCharCount, mmLeft, mmRight,
									mmTMAscent, mmTMDescent, mmTMExternalLeading,
									0.0, lCharSz, lFirst, lLast + 1, mmGapInc);
	// _xZkqqHx_iInJiPoNiPeJjHlJiCmIiCoHiCmOiBeBiPeJjHlJiBeC_xHqqkZx_
	if (endCode != FTWR_END_NORMAL) return FALSE;
	// _xZkqqHx_jBfDjFjEiOpLiCnMiCmBiClNiPoKiNiHiCmNiBeBiPeJjHlJiBeC_xHqqkZx_
	if (lCharSz <= lCharCount) return TRUE;

	mmetol mmSucceedMin = 0.0;
	mmetol mmFailMax = mmGapInc;
	for (lC = 0; lC < 10; lC++)
	{
		mmGapInc = (mmSucceedMin + mmFailMax) / 2.0;
		lCharCount = -1;
		endCode = CalcAlignLeftSimple(edLine, lCharCount, mmLeft, mmRight,
										mmTMAscent, mmTMDescent, mmTMExternalLeading,
										0.0, lCharSz, lFirst, lLast + 1, mmGapInc);
		// _xZkqqHx_iInJiPoNiPeJjHlJiCmIiCoHiCmOiBeBiPeJjHlJiBeC_xHqqkZx_
		if (endCode != FTWR_END_NORMAL) return FALSE;
		if (lCharSz <= lCharCount)
		//----- _xZkqqHx_jBfDjFjEiOpLiCnMiCmBiClNiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jBfDjFjEiOpLiCnMiCoIiBeBiJeFjHfNjEjCiCkKiPfMjFkKiPkMiClDiCkCiPoKiNiHiCmNjAlDiPoNiPeJjHlJiBeC_xHqqkZx_
			if (mmRight < 1.0) return TRUE;
			// _xZkqqHx_jAkMiMpHiClFiClNiJmBiOfKjFjNiCmMiNmFiPkMjCgMiCpAiNfIjAfGiBeC_xHqqkZx_
			mmSucceedMin = mmGapInc;
		} else
		//----- _xZkqqHx_jBfDjFjEiCmNiOpLiCnMiCoHiCmIiCkJiCmBiClNiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_iOlIjEhDiClFiClNiJmBiOfKjFjNiCmMiNmFjBoFjCgMiCpAiNfIjAfGiBeC_xHqqkZx_
			mmFailMax = mmGapInc;
		}
	}
	lCharCount = -1;
	CalcAlignLeftSimple(edLine, lCharCount, mmLeft, mmRight,
						mmTMAscent, mmTMDescent, mmTMExternalLeading,
						0.0, lCharSz, lFirst, lLast + 1, mmSucceedMin);
	return TRUE;
} // CFCWndRichEdit::CalcLineAlignLeftright.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ResetCurFormat
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAiMlLiNnNiCmMiDeKiBfLiDfMiDiLiImKjChFiCmMjClMjBePiCmMjFlGiOjKiCmFiPiJiKpKiJlL_xHqqkZx_
 *			_xZkqqHx_iClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *			00.01.28 Fukushiro M. _xZkqqHx_jEmNiImNiOhHjCoIiCmMiPoKiNiHiCpAjAkOjEpFiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::ResetCurFormat ()
{
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
////----- 01.02.12 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
////	FCEditChar rc;
////	if (0 <= m_lSelFrom)
////	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
////	{
////		long lSelFrom, lSelTo;
////		GetSelectNormal(lSelFrom, lSelTo);
////		if (lSelTo == m_lCurIndex)
////		//----- _xZkqqHx_iDeKiBfLiDfMiDiLiCkKjBeJjBpAjEmNiImNiCmMiNmFiMoDiCmJiCkAiCoJiPoKiNiH_xHqqkZx_ -----
////		{
////			// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiMoDiCmMjFlGiOjKiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
////			rc = GetChar(lSelTo - 1);
////		} else
////		{
////			// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiPiJiCmMjFlGiOjKiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
////			rc = GetChar(lSelFrom);
////		}
////	} else if (m_lCurIndex == 0)
////	//----- _xZkqqHx_jClMjBePiCmJjFlGiOjKiCkKjGlDiCkCiPoKiNiH_xHqqkZx_ -----
////	{
////		// _xZkqqHx_jClMjBePiCmJjFlGiOjKiCkKjGlDiCkCiPoKiNiHiCmNjClMiMoDiCmMjFlGiOjKiCpAiOoGjDlOiBeC_xHqqkZx_
////		rc = GetChar(m_lCurIndex);
////	} else
////	//----- _xZkqqHx_jClMjBePiCmJjFlGiOjKiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
////	{
////		rc = GetChar(m_lCurIndex - 1);
////		if (rc.m_wChar == FDRCH_RETURN) rc = GetChar(m_lCurIndex);
////	}
////----- 01.02.12 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
//	const FCEditChar& eChar = GetCaretChar();
////----- 01.02.12 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
////----- 01.01.31 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
////	g_pEnv->GetSFontRec(rc.m_foidFont)->ReqInit(m_fciCurExtCodeFormat);
////	m_fciCurExtCodeFormat.yOffset = mm2tw(rc.m_mmfOffset);
////	m_fciCurExtCodeFormat.crTextColor = g_pEnv->scid2cref(rc.m_crColor);
////
////	if (m_fciCurStdCodeFormat.cbSize == 0)
////	//----- _xZkqqHx_iMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCkKiPiJiKpKiJlLiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiH_xHqqkZx_ -----
////	{
////		// _xZkqqHx_iMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCpAjFfHiPiAiDhEiDeIiDjDiDgHiCmFiNfIjAfGiBeC_xHqqkZx_
////		g_pEnv->GetSFontRec(0)->ReqInit(m_fciCurStdCodeFormat);
////		m_fciCurStdCodeFormat.yOffset = mm2tw(rc.m_mmfOffset);
////		m_fciCurStdCodeFormat.crTextColor = g_pEnv->scid2cref(rc.m_crColor);
////	}
////	::CHARFORMATCopySjis(m_fciCurStdCodeFormat, m_fciCurExtCodeFormat);
////----- 01.01.31 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
////----- 01.02.15 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
////	// _xZkqqHx_iMlLiNnNiCmMjFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCpAjFfHiPiAiDhEiDeIiDjDiDgHiCmFiNfIjAfGiBeC_xHqqkZx_
////	g_pEnv->GetSFontRec(0)->ReqInit(m_fciCurExtCodeFormat);
////	// _xZkqqHx_iMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCpAjFfHiPiAiDhEiDeIiDjDiDgHiCmFiNfIjAfGiBeC_xHqqkZx_
////	g_pEnv->GetSFontRec(0)->ReqInit(m_fciCurStdCodeFormat);
////----- 01.02.15 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
//	//----- _xZkqqHx_jClMjBePjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCmFiBeBiNfIiCmJiPiJiKpKiJlL_xHqqkZx_ -----
//	FCFontCharInfo fciCur;
//	g_pEnv->GetSFontRec(eChar.m_foidFont)->ReqInit(fciCur);
//	eChar.ReqOverwrite(fciCur);
//	// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCkJiCmHiCkEiCkJiCmFiPiJiKpKiJlLjAoGiCpAjFmPiCkGiCoJiBeC_xHqqkZx_
//// 01.04.19 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
////	if (FFIsStdCode(eChar.m_wChar, fciCur.byCharSet))
//	if (FFIsStdFontChar(eChar.m_wChar))
//	{
//		FFOverwrite(m_fciCurStdCodeFormat, fciCur, FDFI_FLAG_ALL);
//		FFOverwrite(m_fciCurExtCodeFormat, fciCur, 
//				FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
//				FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
//	} else
//	{
//		FFOverwrite(m_fciCurExtCodeFormat, fciCur, FDFI_FLAG_ALL);
//		FFOverwrite(m_fciCurStdCodeFormat, fciCur, 
//				FDFI_FLAG_HEIGHT|FDFI_FLAG_OFFSET|FDFI_FLAG_COLORREF|
//				FDFI_FLAG_UNDERLINE|FDFI_FLAG_STRIKEOUT|FDFI_FLAG_CHARAFTER);
//	}
////----- 01.02.10 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
////	if (m_fciCurExtCodeFormat.dwMask == 0)
////	//----- _xZkqqHx_iMlLiNnNiCmMjFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCkKiPiJiKpKiJlLiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiH_xHqqkZx_ -----
////	{
////		// _xZkqqHx_iMlLiNnNiCmMjFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCpAjFfHiPiAiDhEiDeIiDjDiDgHiCmFiNfIjAfGiBeC_xHqqkZx_
////		g_pEnv->GetSFontRec(0)->ReqInit(m_fciCurExtCodeFormat);
////		rc.ReqOverwrite(m_fciCurExtCodeFormat);
////	}
////	if (m_fciCurStdCodeFormat.dwMask == 0)
////	//----- _xZkqqHx_iMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCkKiPiJiKpKiJlLiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiH_xHqqkZx_ -----
////	{
////		// _xZkqqHx_iMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiDjDiDgHiCpAjFfHiPiAiDhEiDeIiDjDiDgHiCmFiNfIjAfGiBeC_xHqqkZx_
////		g_pEnv->GetSFontRec(0)->ReqInit(m_fciCurStdCodeFormat);
////		rc.ReqOverwrite(m_fciCurStdCodeFormat);
////	}
////----- 01.02.10 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
////----- 01.01.31 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
	// _xZkqqHx_iMlLiNnNiCmMjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAiBeBiDeKiDiMiDgCiDgHiImKjChFiCmMjFlGiOjKiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
	OverwriteFormat(m_fciCurExtCodeFormat, m_fciCurStdCodeFormat, GetCaretChar());
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhGiClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkCiBeC_xHqqkZx_)-----
} // CFCWndRichEdit::ResetCurFormat.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetNextBoundary
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiImKjChFiCkJiCoHiMoDjFpLiCmMjCfAiMoKiCmMiLkLjGnKiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lCurLine	:_xZkqqHx_jClCiCnHiOgOiCnPiCoJiDeKiBfLiDfMiDiLiImKjChFiCmMiNhD_xHqqkZx_
 *			lCurChar	:_xZkqqHx_jClCiCnHiOgOiCnPiCoJiDeKiBfLiDfMiDiLiImKjChFiCmMjHpB_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiDeKiBfLiDfMiDiLiImKjChFiCmMjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBjCfAiMoKiCmMiLkLiKeF_xHqqkZx_
 *			_xZkqqHx_iImKjChFiCmMjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCnGiCmMiDeJiDhEiDfKiDgCiDgH_xHqqkZx_.
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiImKjChFiCmMjFlGiOjKiCmMiOoNjHnOiCpAiLeMjIfOiClFiBeBiClLiCmMiOoNjHnOiCmGjDkPiClGjFlGiOjKiCpA_xHqqkZx_
 *			_xZkqqHx_iMoDjFpLiCmJiClNiCmHiCmBiCmEiNhDiCkNiBeCiInJiCmIiCoJiOoNjHnOiCmMjFlGiOjKiCkKiPgPiMlLiClFiClNiCoHiBeBiClLiClBiCkK_xHqqkZx_
 *			_xZkqqHx_jCfAiMoKiCmMiLkLiCmFiCkAiCoJiBeCjHoBiCkGiCmOiBeB_xHqqkZx_0_xZkqqHx_iNhDjGnKiCmMjFlGiOjKjHpBiCkKiImIiJlKiCmFiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
 *			"ABCDE FG"
 *			lLine = 0, lChar = 2_xZkqqHx_iBeBjBkGiClP_xHqqkZx_"C"_xZkqqHx_iCmMjFlGiOjKiCkJiCoHiMoDjFpLiCpAjClCiCnHiClNiPoKiNiHiBeB_xHqqkZx_
 *			" "_xZkqqHx_iImKjChFiCnMiCmFiCmMiDeJiDhEiDfKiDgCiDgHjCgM_xHqqkZx_ _xZkqqHx_iCfCiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.03 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::GetNextBoundary (long lCurLine, long lCurChar) const
{
	// _xZkqqHx_iOhHjCoIiImKjChFiCpAiDeKiDeFiDjDiDfOiCmJiLeMjIfO_xHqqkZx_.
	long lLine = lCurLine;
	long lChar = lCurChar;
	// _xZkqqHx_iOhHjCoIiImKjChFiCmMjFlGiOjKiCmMiOoNjHnOiCpAiLeMjIfO_xHqqkZx_.
	FDCharKind	ckindCur;
	ckindCur = FFGetCharKind(m_vEditLine[lLine].m_vEditChar[lChar].m_wChar);
	// _xZkqqHx_iOhHjCoIiNhDiCmMiNmFjBoFjFlGiOjKjAjEiCpAiLiBiCnPiCoJ_xHqqkZx_.
	long lCharMax;
	if (m_vEditLine[lLine].m_vEditChar.back().m_wChar == FDRCH_RETURN)
		lCharMax = m_vEditLine[lLine].m_vEditChar.size();
	else	// if FDRCH_CONTINUE.
		lCharMax = m_vEditLine[lLine].m_vEditChar.size() - 1;

	FDCharKind	ckindNew;

	long lOffset = 0;

	for (;;)
	{
		lOffset++;
		lChar++;
		if (lCharMax <= lChar)
		/*----- _xZkqqHx_iNmFjBoFjFlGiOjKjAjEiCpAjClEiCkGiClNiPoKiNiHiBeBiNhDiCpAjBjHiCoJiPiIjHjNiCpAiNhDiCkE_xHqqkZx_ -----*/
		{
			lLine++;
			if (m_vEditLine.size() <= lLine) break;
			lChar = 0;
			// _xZkqqHx_jAfGiClFiCkCiNhDiCmMiNmFjBoFjFlGiOjKjAjEiCpAiLiBiCnPiCoJ_xHqqkZx_.
			if (m_vEditLine[lLine].m_vEditChar.back().m_wChar == FDRCH_RETURN)
				lCharMax = m_vEditLine[lLine].m_vEditChar.size();
			else	// if FDRCH_CONTINUE.
				lCharMax = m_vEditLine[lLine].m_vEditChar.size() - 1;
		}
		// _xZkqqHx_jAfGiClFiCkCiImKjChFiCmMjFlGiOjKiCmMiOoNjHnOiCpAiLiBiCnPiCoJ_xHqqkZx_.
		ckindNew = FFGetCharKind(m_vEditLine[lLine].m_vEditChar[lChar].m_wChar);
		// _xZkqqHx_jFlGiOjKiCmMiOoNjHnOiCkKjFmPiCoNiCmBiCmEiCkCiCoKiCmOiPeJjHlJ_xHqqkZx_.
		if (ckindNew != ckindCur) break;
	}
	return lOffset;

} // CFCWndRichEdit::GetNextBoundary.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetPrevBoundary
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiImKjChFiCkJiCoHjBePjFpLiCmMjCfAiMoKiCmMiLkLjGnKiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lCurLine	:_xZkqqHx_jClCiCnHiOgOiCnPiCoJiDeKiBfLiDfMiDiLiImKjChFiCmMiNhD_xHqqkZx_
 *			lCurChar	:_xZkqqHx_jClCiCnHiOgOiCnPiCoJiDeKiBfLiDfMiDiLiImKjChFiCmMjHpB_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiDeKiBfLiDfMiDiLiImKjChFiCmMjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBjCfAiMoKiCmMiLkLiKeF_xHqqkZx_
 *			_xZkqqHx_iImKjChFiCmMjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCnGiCmMiDeJiDhEiDfKiDgCiDgH_xHqqkZx_.
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNiImKjChFiCmMjFlGiOjKiCmMiOoNjHnOiCpAiLeMjIfOiClFiBeBiClLiCmMiOoNjHnOiCmGjDkPiClGjFlGiOjKiCpA_xHqqkZx_
 *			_xZkqqHx_jBePjFpLiCmJiClNiCmHiCmBiCmEiNhDiCkNiBeCiInJiCmIiCoJiOoNjHnOiCmMjFlGiOjKiCkKiPgPiMlLiClFiClNiCoHiBeBiClLiClBiCkK_xHqqkZx_
 *			_xZkqqHx_jCfAiMoKiCmMiLkLiCmFiCkAiCoJiBeCjHoBiCkGiCmOiBeB_xHqqkZx_0_xZkqqHx_iNhDjGnKiCmMjFlGiOjKjHpBiCkKiImIiJlKiCmFiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
 *			"Z ABCDE FG"
 *			lLine = 0, lChar = 5_xZkqqHx_iBeBjBkGiClP_xHqqkZx_"D"_xZkqqHx_iCmMjFlGiOjKiCkJiCoHjBePjFpLiCpAjClCiCnHiClNiPoKiNiHiBeB_xHqqkZx_
 *			" "_xZkqqHx_iImKjChFiCnMiCmFiCmMiDeJiDhEiDfKiDgCiDgHjCgM_xHqqkZx_ -3 _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.03 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::GetPrevBoundary (long lCurLine, long lCurChar) const
{
	// _xZkqqHx_iOhHjCoIiImKjChFiCpAiDeKiDeFiDjDiDfOiCmJiLeMjIfO_xHqqkZx_.
	long lLine = lCurLine;
	long lChar = lCurChar;
	// _xZkqqHx_iOhHjCoIiImKjChFiCmMjFlGiOjKiCmMiOoNjHnOiCpAiLeMjIfO_xHqqkZx_.
	FDCharKind	ckindCur;
	ckindCur = FFGetCharKind(m_vEditLine[lLine].m_vEditChar[lChar].m_wChar);
	// _xZkqqHx_iOhHjCoIiNhDiCmMiNmFjBoFjFlGiOjKjAjEiCpAiLiBiCnPiCoJ_xHqqkZx_.

	FDCharKind	ckindNew;

	long lOffset = 0;

	for (;;)
	{
		lChar--;
		if (lChar < 0)
		{
			lLine--;
			if (lLine < 0) break;
			if (m_vEditLine[lLine].m_vEditChar.back().m_wChar == FDRCH_RETURN)
				lChar = m_vEditLine[lLine].m_vEditChar.size() - 1;
			else
				lChar = m_vEditLine[lLine].m_vEditChar.size() - 2;
		}
		// _xZkqqHx_jAfGiClFiCkCiImKjChFiCmMjFlGiOjKiCmMiOoNjHnOiCpAiLiBiCnPiCoJ_xHqqkZx_.
		ckindNew = FFGetCharKind(m_vEditLine[lLine].m_vEditChar[lChar].m_wChar);
		// _xZkqqHx_jFlGiOjKiCmMiOoNjHnOiCkKjFmPiCoNiCmBiCmEiCkCiCoKiCmOiPeJjHlJ_xHqqkZx_.
		if (ckindNew != ckindCur) break;
		lOffset--;
	}
	return lOffset;

} // CFCWndRichEdit::GetPrevBoundary.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SendRgnRedraw
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFlGiOjKiCkKiInKjDkOiClFiClNiPoKiPiKiCmMiCnNiCpAiNmEjFgAiJoGiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	TRUE	: _xZkqqHx_jAlDiClFiCkNiNmEjFgAiJoGiClDiCoKiClNiCmGiCkL_xHqqkZx_
 *			FALSE	: _xZkqqHx_iNmEjFgAiJoGiClDiCoKiCmIiCkJiCmBiClNiCmGiCkL_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
BOOL CFCWndRichEdit::SendRgnRedraw ()
{
// 05.03.01 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	if (!IsWindowVisible()) return FALSE;
	if (!::IsWindow(m_hWnd) || !IsWindowVisible()) return FALSE;
	//----- m_mmCaretX_xZkqqHx_iCpAiMhGiOfKiClHiCoJ_xHqqkZx_ -----
	mmetol	mmX, mmY, mmH;
	CalcCaret(mmX, mmY, mmH);
	// _xZkqqHx_iDeKiDiMiDgCiDgHiCkKiBeBjAhNiMgAiCmMiJlKiCmJiCmNiCnNiPgPiClFiClNiOjOiCmNiPmBiLiOiClFiCmIiCkCiBeC_xHqqkZx_
	// _xZkqqHx_iClBiCmMiDeFiDeCiDjDiDgIiDeFiCmJiDhEiDeIiBfLiDeKiDfIiCkKjHeMiCoJiPoKiNiHiCmMiCnNiBeBiDeKiDiMiDgCiDgHiCmNjFfMiOkGiClDiCoKiCmEiCkCiCoJiCmMiCmFiBeB_xHqqkZx_
	// _xZkqqHx_iDfJiBfLiDiAiCmIiCmHiCmJiCoGiCoJiNmEjFgAiJoGiCmFiCmNiBeB_xHqqkZx_
	// _xZkqqHx_iClBiCmMiDeFiDeCiDjDiDgIiDeFiCmJiDhEiDeIiBfLiDeKiDfIiCkKjHeMiCoJiPoKiNiHiCmMiCnNiBeBiDeKiDiMiDgCiDgHiCpAiIoKiOjOjDeJiCmJiPmBiLiOiClHiCoJiBeC_xHqqkZx_
	if (mmY + mmH <= m_mmrtWindow.Height() - m_mmMarginB)
		if (GetFocus() == this) HideCaret();
	CClientDC dc(this); // _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
	FillBackAndMarkUpdate(&dc);
	RedrawUpdate(&dc);

	// _xZkqqHx_iDeKiDiMiDgCiDgHiCkKiBeBjAhNiMgAiCmMiJlKiCmJiCmNiCnNiPgPiClFiClNiOjOiCmNjFfMiOkGiClFiCmIiCkCiBeC_xHqqkZx_
	if (mmY + mmH <= m_mmrtWindow.Height() - m_mmMarginB)
		if (GetFocus() == this) ShowCaret();

	return TRUE;
} // CFCWndRichEdit::SendRgnRedraw.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::FillBackAndMarkUpdate
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAnNjCoIiClDiCoKiCmEiCkCiCoJiPmBiLiOjHmMiIoGiCmGiBeBjBePiJpBiCmMjFgAiJoGiOjOiCmMiOjOiCkJiCoHiImKjChFiCpAiInKjDkOiClFiClN_xHqqkZx_
 *			_xZkqqHx_jFlGiOjKiCmMjHmMiIoGiCpAiBeBjEhHiMgJiCmFjDgIjCnHiClHiBeC_xHqqkZx_
 *			_xZkqqHx_jDkPiOjOiCmJiBeBiInKjDkOiClFiClNjFlGiOjKiCmJiBeBiNmEjFgAiJoGiCmMiDhNiBfLiDeOiCpAiCmCiCkPiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pDC	:_xZkqqHx_jFgAiJoGjHhAiDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::FillBackAndMarkUpdate (CDC* pDC)
{
	// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
	FCAutoDC atDC(pDC, FALSE, 0, 0);
do {
	// _xZkqqHx_jFlGiOjKiCkKiLpDiCmIiCoHiCmOjBjHiCoJiBeC_xHqqkZx_
	if (m_vEditLine.size() == 1 &&
		m_vEditLine.front().m_vEditChar.size() == 1) break;

	FCEditLineVector::iterator iLine = m_vEditLine.begin();
	FCEditCharVector::iterator iChar = (*iLine).m_vEditChar.begin();

//----- 02.08.13 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ (_xZkqqHx_iDlPiBeBiDmKiCmIiCmHiCmMjFlGiOjKiCpAiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmFjDpMjHmNiClFiBeBiDhEiDeIiDjDiDgHiCpA_xHqqkZx_Times New Roman_xZkqqHx_iCmJiClHiCoJiCmGiBeBjFfMiOkGiCkKiJlLiCkPiCoJ_xHqqkZx_)-----
//	SFontID	foidCurFont = (*iChar).m_foidFont;		// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiBeC_xHqqkZx_
//	WORD	wCurOffset = (*iChar).m_wOffset;		// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
//
//	LOGFONT logFont;
//	// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAiNoMjAkMiBeC_xHqqkZx_
//	g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
//	atDC.SetFont(&logFont);					// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
//----- 02.08.13 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ (_xZkqqHx_iDlPiBeBiDmKiCmIiCmHiCmMjFlGiOjKiCpAiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmFjDpMjHmNiClFiBeBiDhEiDeIiDjDiDgHiCpA_xHqqkZx_Times New Roman_xZkqqHx_iCmJiClHiCoJiCmGiBeBjFfMiOkGiCkKiJlLiCkPiCoJ_xHqqkZx_)-----

	long lIndex = 0;
	for (iLine = m_vEditLine.begin(); iLine != m_vEditLine.end(); iLine++)
	{
		mmetol mmX;
		// _xZkqqHx_iDgFiDeMiDfIiDgHiNlGiNmAjFfHiCmJ_xHqqkZx_[_xZkqqHx_jFjEjFgJiNlGiNmAjFfHiBhLiNlGiDhNiBfLiDfHiDjD_xHqqkZx_]_xZkqqHx_iCpAjAnNjCoIiBeC_xHqqkZx_
		if ((*iLine).m_byLineType == FDRC_LT_HEAD)
			mmX = m_mmMarginL + (*iLine).m_mmStartIndent;
		else	// FDRC_LT_CONTINUE.
			mmX = m_mmMarginL + (*iLine).m_mmStartIndent + (*iLine).m_mmOffset;

		mmetol mmY = (*iLine).m_mmY;

		mmetol mmBaseLine = mmY + (*iLine).m_mmfTMAscent;

		for (long lChar = 0; lChar < (*iLine).m_vEditChar.size(); lChar++)
		{
			FCEditChar& eChar = (*iLine).m_vEditChar[lChar];
//----- 02.08.13 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ (_xZkqqHx_iDlPiBeBiDmKiCmIiCmHiCmMjFlGiOjKiCpAiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmFjDpMjHmNiClFiBeBiDhEiDeIiDjDiDgHiCpA_xHqqkZx_Times New Roman_xZkqqHx_iCmJiClHiCoJiCmGiBeBjFfMiOkGiCkKiJlLiCkPiCoJ_xHqqkZx_)-----
//			//----- _xZkqqHx_iDhEiDeIiDjDiDgHiCkKjFmPiCoNiCmBiClNiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
//			// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiCmGiIoBiCkEiBeC_xHqqkZx_
//			if (eChar.m_foidFont != foidCurFont || wCurOffset != eChar.m_wOffset)
//			{
//				// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiCpAjFmPiNfIiBeC_xHqqkZx_
//				foidCurFont = eChar.m_foidFont;
//				// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
//				wCurOffset = eChar.m_wOffset;
//				// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAiNoMjAkMiBeC_xHqqkZx_
//				g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
//				atDC.SetFont(&logFont);					// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
//			}
//----- 02.08.13 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ (_xZkqqHx_iDlPiBeBiDmKiCmIiCmHiCmMjFlGiOjKiCpAiDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiCmFjDpMjHmNiClFiBeBiDhEiDeIiDjDiDgHiCpA_xHqqkZx_Times New Roman_xZkqqHx_iCmJiClHiCoJiCmGiBeBjFfMiOkGiCkKiJlLiCkPiCoJ_xHqqkZx_)-----

			FCShortRect nrRect;
			switch (eChar.m_wChar)
			{
			case FDRCH_RETURN:
				lIndex++;
				break;
			case FDRCH_CONTINUE:
				break;
			case WCH_TAB:	// _xZkqqHx_iDfOiDhFiBeC_xHqqkZx_
				lIndex++;
				break;
			case WCH_SPC:	// _xZkqqHx_iLpDjEjCiBeC_xHqqkZx_
			default:		// _xZkqqHx_jCmKiPoNiCmMjFlGiOjKiBeC_xHqqkZx_
				nrRect.SetRect(
						mm2lg(mmX + eChar.m_mmfPreSpace + eChar.m_mmfAbcA),
						mm2lg(mmBaseLine - g_pEnv->GetSFontRec(eChar.m_foidFont)->
											GetAscent(eChar.m_wOffset)),
						mm2lg(mmX + eChar.m_mmfPreSpace +
								eChar.m_mmfWidth - eChar.m_mmfAbcC),
						mm2lg(mmY + (*iLine).m_mmfTMHeight +
								(*iLine).m_mmfTMExternalLeading));
				nrRect |= FCShortRect(
						mm2lg(mmX + eChar.m_mmfPreSpace),
						mm2lg(mmBaseLine - g_pEnv->GetSFontRec(eChar.m_foidFont)->
											GetAscent(eChar.m_wOffset)),
						mm2lg(mmX + eChar.m_mmfPreSpace +
								eChar.m_mmfWidth + tw2mm(eChar.m_nAfterSpace)),
						mm2lg(mmY + (*iLine).m_mmfTMHeight +
								(*iLine).m_mmfTMExternalLeading));
				// X_xZkqqHx_jFpLiMpMiCmJiDgIiDgCiDgHiKgHjBoFiBeC_xHqqkZx_
				myGetExtentWidth(nrRect);
				if (eChar.m_nrRect != nrRect)
				{
					// _xZkqqHx_iNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
					RegisterClearRgn(&eChar);
					// _xZkqqHx_jFlGiOjKjHmMiIoGiCpAiNmEjFgAiJoGjDgPjIfOiBeC_xHqqkZx_
					eChar.m_nrRect.Empty();
				}
				lIndex++;
				break;
			}
			mmX += eChar.m_mmfPreSpace + eChar.m_mmfWidth + tw2mm(eChar.m_nAfterSpace);
		}
	}
} while (FALSE);
	//----- _xZkqqHx_iNmEjFgAiJoGiDiKiBfLiDfHiDiHiDjDiCpAiBeBiJoGjGmKiCmMiDeOiDiJiDeDiDeBiDjDiDgHjHmMiIoGiCmGiPgEiCmIiCoJjHmMiIoGiCmJiNgJiCoIiNjOiCnO_xHqqkZx_ -----
	// _xZkqqHx_iDfIiDeOiDiKiBfLiDjDiNmAjFfHiMgOiCmFiPgEiCmIiCoIiCpAiOfKiPgPiClFiCmEiBeBiDeOiDiJiDeDiDeBiDjDiDgHiNmAjFfHiMgOiCmJjGnPiClHiBeC_xHqqkZx_
	CRect rtClient;
	g_pView->GetClientRect(rtClient);
	g_pView->ClientToScreen(rtClient);
	// _xZkqqHx_iNmEjFgAiJoGiDiKiBfLiDfHiDiHiDjDiBeC_xHqqkZx_
	CRect rtRgn(m_nrtClearRgn.left, m_nrtClearRgn.top, m_nrtClearRgn.right, m_nrtClearRgn.bottom);
	ClientToScreen(rtRgn);
	rtRgn &= rtClient;
	ScreenToClient(rtRgn);
	// _xZkqqHx_iDiKiBfLiDfHiDiHiDjDiCpAjAnNjCoIiBeC_xHqqkZx_
	m_nrtClearRgn.SetRect(rtRgn.left, rtRgn.top, rtRgn.right, rtRgn.bottom);
	// _xZkqqHx_iDhJiDjDiCmN_xHqqkZx_ NULL _xZkqqHx_iCmFiPiJiKpKiJlLiBeC_xHqqkZx_
	atDC.SetStockPen(NULL_PEN);
	//----- _xZkqqHx_iDhFiDiJiDfGiCpAjEhHiMgJjAeGiCmFiPiJiKpKiJlL_xHqqkZx_ -----
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	COLORREF crBack;
//	if (m_scidBrushBackSColor == FD_S_COLOR_TRANSPARENT)
//		crBack = ::g_pReg->GetOptiSheetColor();
//	else
//		crBack = ::OptiColor(g_pEnv->scid2cref(m_scidBrushBackSColor));
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	atDC.SetBrush(m_crBackground);
	// _xZkqqHx_iNmEjFgAiJoGiOjOiCmJiPmBiLiOiClHiCoJjHmMiIoGiBeC_xHqqkZx_
	atDC.Rectangle(m_nrtClearRgn.left, m_nrtClearRgn.top,
					m_nrtClearRgn.right + 1, m_nrtClearRgn.bottom + 1);
} // CFCWndRichEdit::FillBackAndMarkUpdate.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedrawUpdate
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNmEjFgAiJoGiCmMiDhNiBfLiDeOiCkKjFhEiCkCiCmEiCkCiCoJjFlGiOjKiCpAiNmEjFgAiJoGiClHiCoJiBeCjDkPiOjOiCmJ_xHqqkZx_
 *			_xZkqqHx_iNmEjFgAiJoGiDhNiBfLiDeOiCpAiPmBiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pDC	:_xZkqqHx_jFgAiJoGjHhAiDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.07.31 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedrawUpdate (CDC* pDC)
{
do {
	// _xZkqqHx_jFlGiOjKiCkKiLpDiCmIiCoHiCmOjBjHiCoJiBeC_xHqqkZx_
	if (m_vEditLine.size() == 1 &&
		m_vEditLine.front().m_vEditChar.size() == 1) break;

	// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
	FCAutoDC atDC(pDC, FALSE, 0, 0);

	FCEditLineVector::iterator iLine;
	FCEditCharVector::iterator iChar;

	mmetol	mmX = 0.0;
	mmetol	mmY = 0.0;
	mmetol	mmBaseLine;

	iLine = m_vEditLine.begin();
	iChar = (*iLine).m_vEditChar.begin();

	SFontID  foidCurFont = (*iChar).m_foidFont;		// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiBeC_xHqqkZx_
	WORD	 wCurOffset = (*iChar).m_wOffset;		// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	COLORREF crefCurColor = (*iChar).m_crColor;	// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMjAeGiBeC_xHqqkZx_

	LOGFONT logFont;
// 02.09.15 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ (CodePage_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)
	WORD	wCodePage;
	// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAiNoMjAkM_xHqqkZx_.
	g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
// 02.09.15 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ (CodePage_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)
	wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
	atDC.SetFont(&logFont);					// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_.

	// _xZkqqHx_jAfGiClFiCkCjAeGiCpAjAnNjCoIiBeC_xHqqkZx_
// 01.02.16 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	atDC.SetTextColor(::OptiColor(g_pEnv->scid2cref(crefCurColor)));
	atDC.SetTextColor(::OptiColor(crefCurColor));
	atDC.SetBkMode(TRANSPARENT);

	long lIndex = 0;
	for (iLine = m_vEditLine.begin(); iLine != m_vEditLine.end(); iLine++)
	{
		// _xZkqqHx_iDgFiDeMiDfIiDgHiNlGiNmAjFfHiCmJ_xHqqkZx_[_xZkqqHx_jFjEjFgJiNlGiNmAjFfHiBhLiNlGiDhNiBfLiDfHiDjD_xHqqkZx_]_xZkqqHx_iCpAjAnNjCoIiBeC_xHqqkZx_
		if ((*iLine).m_byLineType == FDRC_LT_HEAD)
			mmX = m_mmMarginL + (*iLine).m_mmStartIndent;
		else	// FDRC_LT_CONTINUE.
			mmX = m_mmMarginL + (*iLine).m_mmStartIndent + (*iLine).m_mmOffset;

		mmY = (*iLine).m_mmY;
		if (m_mmrtWindow.Height() - m_mmMarginB <
			mmY + (*iLine).m_mmfTMHeight + (*iLine).m_mmfTMExternalLeading) break;

		mmBaseLine = mmY + (*iLine).m_mmfTMAscent;

		for (iChar = (*iLine).m_vEditChar.begin();
			 iChar != (*iLine).m_vEditChar.end(); iChar++)
		{
			//----- _xZkqqHx_iDhEiDeIiDjDiDgHiCkKjFmPiCoNiCmBiClNiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
			// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiCmGiIoBiCkEiBeC_xHqqkZx_
			if ((*iChar).m_foidFont != foidCurFont || wCurOffset != (*iChar).m_wOffset)
			{
				// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiCpAjFmPiNfIiBeC_xHqqkZx_
				foidCurFont = (*iChar).m_foidFont;
				// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
				wCurOffset = (*iChar).m_wOffset;
				// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAiNoMjAkMiBeC_xHqqkZx_
				g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
// 02.09.15 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ (CodePage_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)
				wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
				atDC.SetFont(&logFont);					// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
			}

			//----- _xZkqqHx_jAeGiCkKjFmPiCoNiCmBiClNiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
			if ((*iChar).m_crColor != crefCurColor)	// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMjAeGiCmGiIoBiCkEiBeC_xHqqkZx_
			{
				crefCurColor = (*iChar).m_crColor;	// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMjAeGiCpAjFmPiNfIiBeC_xHqqkZx_
				atDC.SetTextColor(::OptiColor(crefCurColor));
														// _xZkqqHx_iMlLiNnNiCmMjAeGiCpAjAnNjCoIiBeC_xHqqkZx_
			}

// 02.02.08 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//			_TCHAR szStr[3];
// 02.02.08 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ ()
//			long lStrLen;
			switch ((*iChar).m_wChar)
			{
			case FDRCH_RETURN:
				lIndex++;
				break;
			case FDRCH_CONTINUE:
				break;
			case WCH_TAB:	// _xZkqqHx_iDfOiDhFiBeC_xHqqkZx_
				lIndex++;
				break;
			case WCH_SPC:	// _xZkqqHx_iLpDjEjCiBeC_xHqqkZx_
			default:		// _xZkqqHx_jFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
			  do
			  {
				// _xZkqqHx_jFgAiJoGjHmMiIoGiKePiCmMiPoKiNiHiCmNiBeBjFlGiOjKjAjEiCpAiDeKiDeFiDjDiDgHiClFiCmEiPeJjHlJiBeC_xHqqkZx_
				if ((*iChar).m_byCrossStat == FDWR_CROSS_OUTSIDE) break;
				// _xZkqqHx_iNmEjFgAiJoGjHmMiIoGiCmFiCmNiCmIiCkCiPoKiNiHiCmNiBeBjFlGiOjKjAjEiCpAiDeKiDeFiDjDiDgHiClFiCmEiPeJjHlJiBeC_xHqqkZx_
				if (!(*iChar).m_nrRect.IsRectEmpty() &&
					(m_nrtClearRgn & (*iChar).m_nrRect).IsRectEmpty()) break;
				// _xZkqqHx_jFgAiJoGjHmMiIoGiCpAiMhGiOfKiBjFjAnNjCoIiBeCiNmEjFgAiJoGiDhNiBfLiDeOiCkKiPmBiCkGiCoJiBeC_xHqqkZx_
				(*iChar).m_nrRect.SetRect(
						mm2lg(mmX + (*iChar).m_mmfPreSpace + (*iChar).m_mmfAbcA),
						mm2lg(mmBaseLine - g_pEnv->GetSFontRec((*iChar).m_foidFont)->
											GetAscent((*iChar).m_wOffset)),
						mm2lg(mmX + (*iChar).m_mmfPreSpace +
								(*iChar).m_mmfWidth - (*iChar).m_mmfAbcC),
						mm2lg(mmY + (*iLine).m_mmfTMHeight +
								(*iLine).m_mmfTMExternalLeading));
				(*iChar).m_nrRect |= FCShortRect(
						mm2lg(mmX + (*iChar).m_mmfPreSpace),
						mm2lg(mmBaseLine - g_pEnv->GetSFontRec((*iChar).m_foidFont)->
											GetAscent((*iChar).m_wOffset)),
						mm2lg(mmX + (*iChar).m_mmfPreSpace +
								(*iChar).m_mmfWidth + tw2mm((*iChar).m_nAfterSpace)),
						mm2lg(mmY + (*iLine).m_mmfTMHeight +
								(*iLine).m_mmfTMExternalLeading));
				// X_xZkqqHx_jFpLiMpMiCmJiDgIiDgCiDgHiKgHjBoFiBeC_xHqqkZx_
				myGetExtentWidth((*iChar).m_nrRect);
				//----- _xZkqqHx_jFlGiOjKiCpAjFgAiJoG_xHqqkZx_ -----
//----- 02.02.08 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//				(void)GetTChar(szStr, lStrLen, (*iChar).m_wChar);
//				atDC.ExtTextOut(mm2lg(mmX + (*iChar).m_mmfPreSpace),
//								mm2lg(mmBaseLine - g_pEnv->GetSFontRec((*iChar).m_foidFont)->
//													GetAscent((*iChar).m_wOffset)),
//								ETO_CLIPPED,
//								(*iChar).m_nrRect.left, (*iChar).m_nrRect.top,
//								(*iChar).m_nrRect.right, (*iChar).m_nrRect.bottom,
//								szStr, lStrLen, NULL);
//----- 02.02.08 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
//----- 02.09.15 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (CodePage_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)-----
//				atDC.ExtTextOut(mm2lg(mmX + (*iChar).m_mmfPreSpace),
//								mm2lg(mmBaseLine - g_pEnv->GetSFontRec((*iChar).m_foidFont)->
//													GetAscent((*iChar).m_wOffset)),
//								ETO_CLIPPED,
//								(*iChar).m_nrRect.left, (*iChar).m_nrRect.top,
//								(*iChar).m_nrRect.right, (*iChar).m_nrRect.bottom,
//								&(*iChar).m_wChar, 1, NULL);
//----- 02.09.15 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (CodePage_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)-----
				atDC.ExtTextOut(mm2lg(mmX + (*iChar).m_mmfPreSpace),
								mm2lg(mmBaseLine - g_pEnv->GetSFontRec((*iChar).m_foidFont)->
													GetAscent((*iChar).m_wOffset)),
								ETO_CLIPPED,
								(*iChar).m_nrRect.left, (*iChar).m_nrRect.top,
								(*iChar).m_nrRect.right, (*iChar).m_nrRect.bottom,
								&(*iChar).m_wChar, 1, wCodePage, NULL);
//----- 02.09.15 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (CodePage_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)-----
//----- 02.02.08 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
				// _xZkqqHx_iOoGiPmBiClFjApMiCoAiJlKjApMiCoAjGlDiCkCiPoKiNiHiCmNiPeJjHlJiBeC_xHqqkZx_
				if (!(*iChar).m_byUnderline && !(*iChar).m_byStrikeOut) break;

				//----- _xZkqqHx_iJlKjApMiBeFiOoGiPmBiClFjApMiCpAjFgAiJoG_xHqqkZx_ -----
				long lLineL;
				long lLineR;
				if ((*iChar).m_byCrossStat == FDWR_CROSS_ONLINE)
				//----- _xZkqqHx_jFlGiOjKiCkKjAhNiMgAjApMiCmJiCkJiCkJiCmBiCmEiCoJiPoKiNiH_xHqqkZx_ -----
				{
					lLineL = mm2lg(mmX + (*iChar).m_mmfPreSpace);
					lLineR = mm2lg(mmX + (*iChar).m_mmfPreSpace +
									(*iChar).m_mmfWidth - (*iChar).m_mmfAbcC);
				} else
				//----- _xZkqqHx_jFlGiOjKiCkKjAhNiMgAjApMiCmMiKkOjBfDiCmIjDoAjBkEiCmMiPoKiNiH_xHqqkZx_ -----
				{
					lLineL = mm2lg(mmX + (*iChar).m_mmfPreSpace);
					lLineR = mm2lg(mmX + (*iChar).m_mmfPreSpace +
								(*iChar).m_mmfWidth + tw2mm((*iChar).m_nAfterSpace));
				}
				if ((*iChar).m_byUnderline)
				//----- _xZkqqHx_iJlKjApMiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
				{
					mmetol mmUnderlineWidth = g_pEnv->GetSFontRec((*iChar).m_foidFont)->
												GetUnderlineWidth((*iChar).m_wOffset);
					mmetol mmUnderlineOffset = g_pEnv->GetSFontRec((*iChar).m_foidFont)->
												GetUnderlineOffset(0, (*iChar).m_wOffset);
					// _xZkqqHx_jApMiCmMjFjNiCmGjCiGjAfDiNmAjFfHiBeC_xHqqkZx_
					long lLineW = mm2lg(mmUnderlineWidth);
					long lLineY = mm2lg(mmBaseLine - g_pEnv->GetSFontRec((*iChar).m_foidFont)->
											GetAscent((*iChar).m_wOffset) + mmUnderlineOffset);
					// _xZkqqHx_jApMiCpAjFgAiJoGiBeC_xHqqkZx_
					FCTextOut::DrawLineHorz(atDC, lLineL, lLineR, lLineW, lLineY);
				}
				if ((*iChar).m_byStrikeOut)
				//----- _xZkqqHx_iJlKjApMiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
				{
					mmetol mmStrikeOutWidth = g_pEnv->GetSFontRec((*iChar).m_foidFont)->
												GetStrikeOutWidth((*iChar).m_wOffset);
					mmetol mmStrikeOutOffset = g_pEnv->GetSFontRec((*iChar).m_foidFont)->
												GetStrikeOutOffset(0, (*iChar).m_wOffset);
					// _xZkqqHx_jApMiCmMjFjNiCmGjCiGjAfDiNmAjFfHiBeC_xHqqkZx_
					long lLineW = mm2lg(mmStrikeOutWidth);
					long lLineY = mm2lg(mmBaseLine - g_pEnv->GetSFontRec((*iChar).m_foidFont)->
											GetAscent((*iChar).m_wOffset) + mmStrikeOutOffset);
					// _xZkqqHx_jApMiCpAjFgAiJoGiBeC_xHqqkZx_
					FCTextOut::DrawLineHorz(atDC, lLineL, lLineR, lLineW, lLineY);
				}
			  } while (FALSE);
				lIndex++;
				break;
			}
			mmX += (*iChar).m_mmfPreSpace + (*iChar).m_mmfWidth + tw2mm((*iChar).m_nAfterSpace);
		}
	}
} while (FALSE);
	//----- _xZkqqHx_iDhNiDfIiDeOiCkKiCkAiCoJiPoKiNiHiCmNiDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAjFgAiJoG_xHqqkZx_ -----
// 02.05.30 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)
//	if (!m_vlgptPoly.empty())
	if (!m_vmmptPoly.empty())
	{
		FCDraw draw(pDC, g_->eDrawWhich, g_->dZoom, 0, 0);
		//----- _xZkqqHx_iDhJiDjDiCmMiPiJiKpKiJlL_xHqqkZx_ -----
		if (m_psidPenStyle == FD_PEN_STYLE_UNUSE ||
			m_scidPenBackSColor == FD_S_COLOR_TRANSPARENT)
			draw.PenInit(FD_PEN_STYLE_SOLID, 0.0, FD_S_COLOR_BLACK);
		else
			draw.PenInit(m_psidPenStyle, m_mmfPenWeight, m_scidPenBackSColor);
		// _xZkqqHx_iDhFiDiJiDfGiCmNiLpDiCmJiBeC_xHqqkZx_
		draw.BrushInitNull();
		// _xZkqqHx_iDhNiDfIiDeOiCmMiLkLiKeFjApMjFgAiJoGjHhAiDiKiBfLiDfHiDiHiDjDiCpAjAnNjCoIiBeC_xHqqkZx_
		pDC->IntersectClipRect(m_nrtClearRgn.left, m_nrtClearRgn.top, m_nrtClearRgn.right, m_nrtClearRgn.bottom);
//----- 02.05.30 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
//		// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAjFgAiJoGiBeC_xHqqkZx_
//		draw.Polyline(m_vlgptPoly.begin(), m_vlgptPoly.size());
//----- 02.05.30 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
		// _xZkqqHx_iDhNiDfIiDeOiDhMiDiKiDfDiDjDiCpAjFgAiJoGiBeC_xHqqkZx_
		CPointVector vlgptPoly;
		mm2lg(vlgptPoly, m_vmmptPoly);
		draw.Polyline(vlgptPoly.begin(), vlgptPoly.size());
//----- 02.05.30 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
	}
	// _xZkqqHx_iNmEjFgAiJoGiOjOiCmJiPmBiLiOiClHiCoJjHmMiIoGiCpAiPiJiKpKiJlLiBeC_xHqqkZx_
	m_nrtClearRgn.Empty();
} // CFCWndRichEdit::RedrawUpdate.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RegisterClearRgn
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iPmBiLiOjHmMiIoGiCmJjDgPjIfOiClHiCoJiBeC_xHqqkZx_[pCharFirst, pCharLast)_xZkqqHx_iCkKjDgPjIfOiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pCharFirst	:_xZkqqHx_jDgPjIfOiClHiCoJjHmMiIoGiCmMjFlGiOjKiCmMiNmFiPiJiCpAiOhHjCoIiBeC_xHqqkZx_
 *			pCharLast	:_xZkqqHx_jDgPjIfOiClHiCoJjHmMiIoGiCmMjFlGiOjKiCmMiNmFiMoDiCpAiOhHjCoIiBeCiCfAjFlGiOjKiClOiCkP_xHqqkZx_
 *						 _xZkqqHx_jDgPjIfOiClHiCoJiPoKiNiHiCmNiBeB_xHqqkZx_NULL _xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RegisterClearRgn (const FCEditChar* pCharFirst,
											const FCEditChar* pCharLast)
{
	const FCEditChar* pChar;
	for (pChar = pCharFirst; pChar != pCharLast; pChar++)
	{
		if (!pChar->m_nrRect.IsRectEmpty())
			m_nrtClearRgn |= pChar->m_nrRect;
		if (pCharLast == NULL) break;
	}
} // CFCWndRichEdit::RegisterClearRgn.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RegisterClearRgn
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iPmBiLiOjHmMiIoGiCmJjDgPjIfOiClHiCoJiBeC_xHqqkZx_[pLineFirst, pLineLast)_xZkqqHx_iCkKjDgPjIfOiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pLineFirst	:_xZkqqHx_jDgPjIfOiClHiCoJjHmMiIoGiCmMiNhDiCmMiNmFiPiJiCpAiOhHjCoIiBeC_xHqqkZx_
 *			pLineLast	:_xZkqqHx_jDgPjIfOiClHiCoJjHmMiIoGiCmMiNhDiCmMiNmFiMoDiCpAiOhHjCoIiBeCiCfAiNhDiClOiCkP_xHqqkZx_
 *						 _xZkqqHx_jDgPjIfOiClHiCoJiPoKiNiHiCmNiBeB_xHqqkZx_NULL _xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RegisterClearRgn (const FCEditLine* pLineFirst,
											const FCEditLine* pLineLast)
{
	const FCEditLine* pLine;
	for (pLine = pLineFirst; pLine != pLineLast; pLine++)
	{
		RegisterClearRgn(pLine->m_vEditChar.begin(), pLine->m_vEditChar.end());
		if (pLineLast == NULL) break;
	}
} // CFCWndRichEdit::RegisterClearRgn.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::Redo1Session
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iCfAiDfKiDgCiDfGiDiHiDjDjFkK_xHqqkZx_ Redo _xZkqqHx_iClHiCoJiBeCiNhDiCmMiNmEiMhGiOfKiCmNiNhDiCoNiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lMinLine	:_xZkqqHx_iNhDiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_Redo_xZkqqHx_jCiGiCmFiClBiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCoGiCoI_xHqqkZx_
 *						 _xZkqqHx_iPkMiClDiCkCiNhDiCkKiCkAiCmBiClNiCoHiBeBiClLiCmMjCgMiCmJiNfIjAfGiClFiCmEjFnEiClHiBeC_xHqqkZx_
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
// *			lMinIdx		:_xZkqqHx_jFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_Redo_xZkqqHx_jCiGiCmFiClBiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCoGiCoI_xHqqkZx_
// *						 _xZkqqHx_iPkMiClDiCkCjFlGiOjKiCkKiCkAiCmBiClNiCoHiBeBiClLiCmMjCgMiCmJiNfIjAfGiClFiCmEjFnEiClHiBeC_xHqqkZx_
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
 *			lCurIdx		:_xZkqqHx_iNmFiMoDiCmM_xHqqkZx_ Redo _xZkqqHx_iDfCiDhNiDjDiDgIiCmMjBmOiPnLiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	Redo_xZkqqHx_iCmFiCkLiClNiPoKiNiHiCmN_xHqqkZx_TRUE_xZkqqHx_iBeBiDeMiDiFiBfLiCmJiOgDiCoIiCkKiCmIiCkCiPoKiNiHiCmN_xHqqkZx_ FALSE_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iDeKiDiMiDgCiDgHiImKjChFiCmMiNmEjAnNjCoIiCmNiNhDiCoNiCmIiCkCiCmMiCmFiBeBiMmEiCnBiPgPiClFiMlDiCmFjAnNjCoIiClHiCoJjFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.02.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//BOOL CFCWndRichEdit::Redo1Session (long& lMinLine, long& lMinIdx, long& lCurIdx)
BOOL CFCWndRichEdit::Redo1Session (long& lMinLine, long& lCurIdx)
{
	// _xZkqqHx_iDeMiDiFiBfLiCmJiOgDiCoIiCkKiCmIiCkN_xHqqkZx_FALSE_xZkqqHx_iBeC_xHqqkZx_
	if (GetCmdQueuePos() == GetCmdQueueSize())
		return FALSE;

	// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiNmFiMoDiCnMiCmFiDiLiBfLiDhGiBeC_xHqqkZx_
	while (GetCmdQueuePos() != GetCmdQueueSize())
	{
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		const DWORD dwSizeBn = ReadVSizeUCmdQueue();
		// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCmJiCnEiCmCiCkJiCmBiClNiCoHiDiLiBfLiDhGiCpAjElCiCkPiCoJiBeC_xHqqkZx_
		if (dwSizeBn == 0) break;
		// _xZkqqHx_iDfCiDhNiDjDiDgIiPeJjCfLiImKjChFiCpAiOfKiPgPiBeC_xHqqkZx_
		const long lCmdEnd = GetCmdQueuePos() + dwSizeBn;
		// _xZkqqHx_iDfCiDhNiDjDiDgIjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
		BYTE byCmd;
		ReadCmdQueue(byCmd);
		// _xZkqqHx_jFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		lCurIdx = ReadVSizeUCmdQueue();
		//----- _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfK_xHqqkZx_ -----
		long lLine;
		long lChar;
		IndexToCharPos(lLine, lChar, lCurIdx);
		// lLine_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
		(void)JoinLineBelow(lLine);
		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
		IndexToCharPos(lLine, lChar, lCurIdx);
		// _xZkqqHx_iPeDjAlDiCmMjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
		if (lLine < lMinLine) lMinLine = lLine;
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		// _xZkqqHx_iPeDjAlDiCmMjDpMiCmBiClNiDeDiDjDiDgGiDgCiDeOiDfIiCmMiNmFiPkMjCgMiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
//		if (lCurIdx < lMinIdx) lMinIdx = lCurIdx;
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		switch (byCmd)
		{
		case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
			RedoCmdDeleteThinLine(lLine, lChar);
			break;
		case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
			RedoCmdInsertThinLine(lLine, lChar);
			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		case FDECMD_DELETE_LINES:		// _xZkqqHx_jFkBjAjEiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
//			RedoCmdDeleteLines(lLine, lChar);
//			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
			RedoCmdReplaceChars(lLine, lChar);
			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		case FDECMD_INSERT_LINE:		// _xZkqqHx_iCfAiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
//			RedoCmdInsertLine(lLine, lChar);
//			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			RedoCmdFormatLine(lLine, lChar);
			break;
		case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			RedoCmdFormatChars(lLine, lChar);
			break;
		case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			RedoCmdModifyMargin(lLine, lChar);
			break;
		case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			RedoCmdModifyVertAlign(lLine, lChar);
			break;
		default:
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//			// _xZkqqHx_iDhEiDeAiDeDiDiLiCkKiJpDiCoKiCmEiCkCiCnMiClHiBeC_xHqqkZx_
//			::FFErrorBox(IDS_ERR_FILE_DESTROIED);
//			return FALSE;
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
			// _xZkqqHx_iDhEiDeAiDeDiDiLiCkKiJpDiCoKiCmEiCkCiCnMiClHiBeC_xHqqkZx_
			FFThrowMiscException(IDS_ERR_FILE_DESTROIED);
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
		}
		// _xZkqqHx_iDhMiDeDiDjDiDfOiCpAiDfCiDhNiDjDiDgIiPeJjCfLiCmJjAgJiCnPiCoJiBeC_xHqqkZx_
		SetCmdQueuePos(lCmdEnd);
		// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_jFkKiBgJiDfCiDhNiDjDiDgIiDfEiDeDiDfJjFkKiBgKjAgJiCnPiCoJiBeC_xHqqkZx_
		(void)ReadVSizeUCmdQueue();
	}
	return TRUE;
} // CFCWndRichEdit::Redo1Session.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::Undo1Session
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iCfAiDfKiDgCiDfGiDiHiDjDjFkK_xHqqkZx_ Undo _xZkqqHx_iClHiCoJiBeCiNhDiCmMiNmEiMhGiOfKiCmNiNhDiCoNiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lMinLine	:_xZkqqHx_iNhDiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_Undo_xZkqqHx_jCiGiCmFiClBiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCoGiCoI_xHqqkZx_
 *						 _xZkqqHx_iPkMiClDiCkCiNhDiCkKiCkAiCmBiClNiCoHiBeBiClLiCmMjCgMiCmJiNfIjAfGiClFiCmEjFnEiClHiBeC_xHqqkZx_
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
// *			lMinIdx		:_xZkqqHx_jFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_Undo_xZkqqHx_jCiGiCmFiClBiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCoGiCoI_xHqqkZx_
// *						 _xZkqqHx_iPkMiClDiCkCjFlGiOjKiCkKiCkAiCmBiClNiCoHiBeBiClLiCmMjCgMiCmJiNfIjAfGiClFiCmEjFnEiClHiBeC_xHqqkZx_
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
 *			lCurIdx		:_xZkqqHx_iNmFiMoDiCmM_xHqqkZx_ Undo _xZkqqHx_iDfCiDhNiDjDiDgIiCmMjBmOiPnLiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDfKiDgCiDfGiDiHiDjDiCpA_xHqqkZx_Undo_xZkqqHx_iCmFiCkLiClNiPoKiNiHiCmN_xHqqkZx_ TRUE_xZkqqHx_iBeBiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiNmFiPiJiCmF_xHqqkZx_
 *			Undo_xZkqqHx_iCmFiCkLiCmIiCkCiPoKiNiHiCmN_xHqqkZx_ FALSE _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iDeKiDiMiDgCiDgHiImKjChFiCmMiNmEjAnNjCoIiCmNiNhDiCoNiCmIiCkCiCmMiCmFiBeBiMmEiCnBiPgPiClFiMlDiCmFjAnNjCoIiClHiCoJjFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.02.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.28 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//BOOL CFCWndRichEdit::Undo1Session (long& lMinLine, long& lMinIdx, long& lCurIdx)
BOOL CFCWndRichEdit::Undo1Session (long& lMinLine, long& lCurIdx)
{
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiNmFiPiJiCmIiCoHiCmO_xHqqkZx_ FALSE _xZkqqHx_iCpAjFnEiClHiBeC_xHqqkZx_
	if (GetCmdQueuePos() == 0) return FALSE;

	// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_jFkKiBgJiDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOjFkKiBgKjGnPiClHiBeC_xHqqkZx_
	(void)RReadVSizeUCmdQueue();
	do
	{
		// _xZkqqHx_iDfCiDhNiDjDiDgIiDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
		DWORD dwSizeBn = RReadVSizeUCmdQueue();
		// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCmMiPoKiNiHiCmNiPeJjHlJiBeC_xHqqkZx_
		if (dwSizeBn == 0)
		{
			// _xZkqqHx_iDhMiDeDiDjDiDfOiCpAiDfKiDgCiDfGiDiHiDjDiLkLiKeFiCmJjGnPiClHiBeC_xHqqkZx_
			(void)ReadVSizeUCmdQueue();
			break;
		}
		// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCnJiCmHjGnPiClHiBeCiDfCiDhNiDjDiDgIiCmMjAoGjDkKiCmJiInKjDkOiBeC_xHqqkZx_
		long lCmdTop = SeekCmdQueuePos(-long(dwSizeBn));
		// _xZkqqHx_iDfCiDhNiDjDiDgIjDmHiCnNiNjOiCnNiBeC_xHqqkZx_
		BYTE byCmd;
		ReadCmdQueue(byCmd);
		// _xZkqqHx_jFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
		lCurIdx = ReadVSizeUCmdQueue();
		//----- _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfK_xHqqkZx_ -----
		long lLine;
		long lChar;
		IndexToCharPos(lLine, lChar, lCurIdx);
		// lLine_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
		(void)JoinLineBelow(lLine);
		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
		IndexToCharPos(lLine, lChar, lCurIdx);
		// _xZkqqHx_iPeDjAlDiCmMjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
		if (lLine < lMinLine) lMinLine = lLine;
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		// _xZkqqHx_iPeDjAlDiCmMjDpMiCmBiClNiDeDiDjDiDgGiDgCiDeOiDfIiCmMiNmFiPkMjCgMiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
//		if (lCurIdx < lMinIdx) lMinIdx = lCurIdx;
//----- 06.02.28 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

		switch (byCmd)
		{
		case FDECMD_DELETE_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
			UndoCmdDeleteThinLine(lLine, lChar);
			break;
		case FDECMD_INSERT_THIN_LINE:	// _xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
			UndoCmdInsertThinLine(lLine, lChar);
			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		case FDECMD_DELETE_LINES:		// _xZkqqHx_jFkBjAjEiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
//			UndoCmdDeleteLines(lLine, lChar);
//			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		case FDECMD_REPLACE_CHARS:		// _xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
			UndoCmdReplaceChars(lLine, lChar);
			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		case FDECMD_INSERT_LINE:		// _xZkqqHx_iCfAiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
//			UndoCmdInsertLine(lLine, lChar);
//			break;
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		case FDECMD_FORMAT_LINE:		// _xZkqqHx_iCfAiNhDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			UndoCmdFormatLine(lLine, lChar);
			break;
		case FDECMD_FORMAT_CHARS:		// _xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			UndoCmdFormatChars(lLine, lChar);
			break;
		case FDECMD_MODIFY_MARGIN:		// _xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			UndoCmdModifyMargin(lLine, lChar);
			break;
		case FDECMD_MODIFY_VERT_ALIGN:	// _xZkqqHx_jAiCjClMjFpLiMpMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
			UndoCmdModifyVertAlign(lLine, lChar);
			break;
		default:
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//			// _xZkqqHx_iDhEiDeAiDeDiDiLiCkKiJpDiCoKiCmEiCkCiCnMiClHiBeC_xHqqkZx_
//			::FFErrorBox(IDS_ERR_FILE_DESTROIED);
//			return FALSE;
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
			// _xZkqqHx_iDhEiDeAiDeDiDiLiCkKiJpDiCoKiCmEiCkCiCnMiClHiBeC_xHqqkZx_
			FFThrowMiscException(IDS_ERR_FILE_DESTROIED);
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
		}
		// _xZkqqHx_iDhMiDeDiDjDiDfOiCpAiDfCiDhNiDjDiDgIjAoGjDkKiCmJjGnPiClHiBeC_xHqqkZx_
		SetCmdQueuePos(lCmdTop);
		// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_jFkKiBgJiDfCiDhNiDjDiDgIiDfEiDeDiDfJjFkKiBgKjGnPiClHiBeC_xHqqkZx_
		(void)RReadVSizeUCmdQueue();
	} while (GetCmdQueuePos() != 0);
	return TRUE;
} // CFCWndRichEdit::Undo1Session.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SessionBegin
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiCpAiKeKiOgOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SessionBegin ()
{
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiImIiNhOiCmMiDfKiDgCiDfGiDiHiDjDiDgGiBfLiDfOiCpAiPmBiLiOiClHiCoJiBeC_xHqqkZx_
	m_byvCmdQueue.resize(m_lCmdPos);
	ASSERT(m_byvCmdQueue.empty() || m_byvCmdQueue.back() == 0);
} // CFCWndRichEdit::SessionBegin.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SessionEnd
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiCpAiPeJjHlJiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SessionEnd ()
{
	// _xZkqqHx_jBePiJpBiCmMiDfKiDgCiDfGiDiHiDjDiImIiNhOiCmJiDfCiDhNiDjDiDgIiCkKiLeMjIfOiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiHiCmNiPeJjHlJiBeC_xHqqkZx_
	if (m_byvCmdQueue.empty() || m_byvCmdQueue.back() == 0) return;
	// _xZkqqHx_iDfKiDgCiDfGiDiHiDjDiDfKiDhAiDiMiBfLiDfOiCpAiLeMjIfOiBeC_xHqqkZx_
// 06.02.18 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	WriteCmdQueue(BYTE(FDECMD_SEPARATER));
	WriteVSizeUCmdQueue(0);
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiCpAiDeMiDiFiBfLiNmFiMoDiCmJiInKjDkOiBeC_xHqqkZx_
	m_lCmdPos = m_byvCmdQueue.size();
} // CFCWndRichEdit::SessionEnd.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::ReadVSizeUCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCkJiCoHiDfEiDeDiDfJiCgBiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jDmHiCnNiPgPiClFiClNjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
DWORD CFCWndRichEdit::ReadVSizeUCmdQueue ()
{
	// _xZkqqHx_iMlLiNnNiImKjChFiCmMiDhMiDeDiDjDiDfOiCpAiMhGiOfKiBeC_xHqqkZx_
	const BYTE* pData = GetCmdQueuePtr();
	// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiDfEiDeDiDfJiCgBiCpAjDmHiCnNiNjOiCnOiBeCiMlLiNnNiImKjChFiCoAjAgJiCnPiCoHiCoKiCoJiBeC_xHqqkZx_
	DWORD dwB = ::ReadVSizeU(pData);
	// _xZkqqHx_jAfGiClFiCkCiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	SetCmdQueuePtr(pData);
	return dwB;
} // CFCWndRichEdit::ReadVSizeUCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RReadVSizeUCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCkJiCoHiDfEiDeDiDfJiCgBiCpAiLhEiMpMiCkLiCmJjDmHiCnNiPgPiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jDmHiCnNiPgPiClFiClNjCgMiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
DWORD CFCWndRichEdit::RReadVSizeUCmdQueue ()
{
	// _xZkqqHx_iMlLiNnNiImKjChFiCmMiDhMiDeDiDjDiDfOiCpAiMhGiOfKiBeC_xHqqkZx_
	const BYTE* pData = GetCmdQueuePtr();
	// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiLhEiMpMiCkLiCmJiDfEiDeDiDfJiCgBiCpAjDmHiCnNiNjOiCnOiBeCiMlLiNnNiImKjChFiCoAjGnPiClDiCoKiCoJiBeC_xHqqkZx_
	DWORD dwB = ::RReadVSizeU(pData);
	// _xZkqqHx_jAfGiClFiCkCiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	SetCmdQueuePtr(pData);
	return dwB;
} // CFCWndRichEdit::RReadVSizeUCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::WriteVSizeUCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmJiDfEiDeDiDfJiCgBiCpAiPjBiCkLiNjOiCnOiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	dwB	:_xZkqqHx_iPjBiCkLiNjOiCnOjCgMiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::WriteVSizeUCmdQueue (DWORD dwB)
{
	::WriteVSizeU(m_byvCmdQueue, dwB);
} // CFCWndRichEdit::WriteVSizeUCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::InsertVSizeUCmdQueue
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiOhHjCoIiClDiCoKiClNiImKjChFiCmJiDfEiDeDiDfJiCgBiCpAiPjBiCkLiNjOiCnOiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lPos:_xZkqqHx_iPjBiCkLiNjOiCnOiImKjChFiCpAiOhHjCoIiBeC_xHqqkZx_
 *			dwB	:_xZkqqHx_iPjBiCkLiNjOiCnOjCgMiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.18 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::InsertVSizeUCmdQueue (long lPos, DWORD dwB)
{
	::InsertVSizeU(m_byvCmdQueue, lPos, dwB);
} // CFCWndRichEdit::InsertVSizeUCmdQueue.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SeekCmdQueuePos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiCpAiInKjDkOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lSize	:_xZkqqHx_iInKjDkOiClHiCoJiLjHjHkDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iInKjDkOiMoDiCmMiImKjChFiCpAjFnEiClHiBeCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.12 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::SeekCmdQueuePos (long lSize)
{
	m_lCmdPos += lSize;
	return m_lCmdPos;
} // CFCWndRichEdit::SeekCmdQueuePos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCmdQueuePos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChF_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::GetCmdQueuePos () const
{
	return m_lCmdPos;
} // CFCWndRichEdit::GetCmdQueuePos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCmdQueuePos
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lPos	:_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiCpAjAnNjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCmdQueuePos (long lPos)
{
	m_lCmdPos = lPos;
} // CFCWndRichEdit::SetCmdQueuePos.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::GetCmdQueuePtr
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiImKjChFiCpAjFnEiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.15 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
const BYTE* CFCWndRichEdit::GetCmdQueuePtr () const
{
	return m_byvCmdQueue.begin() + m_lCmdPos;
} // CFCWndRichEdit::GetCmdQueuePtr.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::SetCmdQueuePtr
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDfCiDhNiDjDiDgIiDeMiDiFiBfLiCmMiMlLiNnNiImKjChFiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pPtr	:_xZkqqHx_iMlLiNnNiImKjChFiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.15 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::SetCmdQueuePtr (const BYTE* pPtr)
{
	m_lCmdPos = pPtr - m_byvCmdQueue.begin();
} // CFCWndRichEdit::SetCmdQueuePtr.

//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdDeleteLines
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFkBjAjEiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxFrom	:_xZkqqHx_iNoNiPjMiKeKiOgOiClHiCoJiNhDiCmMjAoGjDkKjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
// *			lSize		:_xZkqqHx_iNoNiPjMiClHiCoJiNhDjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeB_xHqqkZx_lIdxFrom_xZkqqHx_iCkKjBkOiClHiCoJiNhDiCmNiMhAjBlBiNhDiCkK_xHqqkZx_
// *			_xZkqqHx_jIeBiMiLiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
// *			lIdxFrom_xZkqqHx_iCmMjBkOiClHiCoJiNhDiCmGiBeB_xHqqkZx_lIdxFrom+lSize_xZkqqHx_iCmMjBkOiClHiCoJiNhDiCmNjDkPiClGiNhDiCmF_xHqqkZx_
// *			_xZkqqHx_iCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNhDiNoNiPjMiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
// *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
// *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAiNoNiPjMiKeKiOgOiEkAiNoNiPjM_xHqqkZx_  _xZkqqHx_iEkAiNhDiBjFjFlGiOjKiEkAiNhDiBjFjFlGiOjKiEkA_xHqqkZx_      _xZkqqHx_iEkAiNhDiBjFjFlGiOjKiEkAiDfEiDeDiDfJiEkA_xHqqkZx_
// *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_Index   _xZkqqHx_iEkAiNhDjAjE_xHqqkZx_  _xZkqqHx_iEkAiPoOjFpBiCfA_xHqqkZx_  _xZkqqHx_iEkAiPoOjFpBiCfB_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiPoOjFpBiCiO_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
// *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
// *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
// *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJiEjP_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiEjPiJmCjFmPiEjPiEkJiEjPiJmCjFmPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiEjPiJmCjFmPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
// *                 _xZkqqHx_iEkA_xHqqkZx_                      _xZkqqHx_iEkA_xHqqkZx_                                    _xZkqqHx_iEkA_xHqqkZx_
// *                 _xZkqqHx_iEkA_xHqqkZx_                      _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiNoNiPjMiNhDjAjEiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
// *                 _xZkqqHx_iEkA_xHqqkZx_                                                            _xZkqqHx_iEkA_xHqqkZx_
// *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::CmdDeleteLines (long lIdxFrom, long lSize)
//{
//	long lLineFrom;
//	long lChar;
//	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
//	IndexToCharPos(lLineFrom, lChar, lIdxFrom);
//	long lLineTo = lLineFrom + lSize;
//	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
//	const long lSize0 = GetCmdQueueSize();
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
//	WriteCmdQueue(BYTE(FDECMD_DELETE_LINES));
//	// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
//	WriteVSizeUCmdQueue(lIdxFrom);
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDjAjEiCpAiLeMjIfOiBeC_xHqqkZx_
//	WriteVSizeUCmdQueue(lSize);
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiLeMjIfOiBeC_xHqqkZx_
//	for (long lC = lLineFrom; lC != lLineTo; lC++)
//		m_vEditLine[lC].OutLinChrStream(m_byvCmdQueue);
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
//	const long lCmdSize = GetCmdQueueSize() - lSize0;
//	InsertVSizeUCmdQueue(lSize0, lCmdSize);
//	WriteVSizeUCmdQueue(lCmdSize);
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
//	RegisterClearRgn(m_vEditLine.begin() + lLineFrom, m_vEditLine.begin() + lLineTo); 
//	// _xZkqqHx_iNhDiCpAiNoNiPjMiBeC_xHqqkZx_
//	m_vEditLine.erase(m_vEditLine.begin() + lLineFrom, m_vEditLine.begin() + lLineTo); 
//} // CFCWndRichEdit::CmdDeleteLines.
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdDeleteThinLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iLpDiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxFrom	:_xZkqqHx_iNoNiPjMiKeKiOgOiClHiCoJiNhDiCmMjAoGjDkKjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeB_xHqqkZx_lIdxFrom_xZkqqHx_iCkKjBkOiClHiCoJiNhDiCmNiMhAjBlBiNhDiCkK_xHqqkZx_
 *			_xZkqqHx_jIeBiMiLiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *			lIdxFrom_xZkqqHx_iCmMjBkOiClHiCoJiNhDiCmNiLpDiBgJ_xHqqkZx_FDRCH_RETURN_xZkqqHx_iCmMiCnNiBgKiCmFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNhDiNoNiPjMiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAiNoNiPjMiKeKiOgOiEkAiNhDiBjFjFlGiOjKiEkAiDfEiDeDiDfJiEkA_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_Index   _xZkqqHx_iEkAiPoOjFpB_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJiEjP_xHqqkZx_SizU_xZkqqHx_iEjPiEkFiEjPiJmCjFmPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                        _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//void CFCWndRichEdit::CmdDeleteThinLine (long lIdxFrom)
long CFCWndRichEdit::CmdDeleteThinLine (long lIdxFrom)
{
	long lLineFrom;
	long lChar;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLineFrom, lChar, lIdxFrom);

	ASSERT(lChar == 0);
	ASSERT(m_vEditLine[lLineFrom].m_vEditChar.size() == 1);
	ASSERT(m_vEditLine[lLineFrom].m_vEditChar[0].m_wChar == FDRCH_RETURN);

	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
	const long lSize0 = GetCmdQueueSize();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteCmdQueue(BYTE(FDECMD_DELETE_THIN_LINE));
	// _xZkqqHx_iNoNiPjMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lIdxFrom);
	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiLeMjIfOiBeC_xHqqkZx_
	m_vEditLine[lLineFrom].OutLinChrStream(m_byvCmdQueue);
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
	const long lCmdSize = GetCmdQueueSize() - lSize0;
	InsertVSizeUCmdQueue(lSize0, lCmdSize);
	WriteVSizeUCmdQueue(lCmdSize);
	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
	RegisterClearRgn(m_vEditLine.begin() + lLineFrom, NULL); 
	// _xZkqqHx_iNhDiCpAiNoNiPjMiBeC_xHqqkZx_
	m_vEditLine.erase(m_vEditLine.begin() + lLineFrom, m_vEditLine.begin() + lLineFrom + 1); 
	// _xZkqqHx_iNoNiPjMiNhDiCpAjFnEiClHiBeC_xHqqkZx_
	return lLineFrom;
} // CFCWndRichEdit::CmdDeleteThinLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdInsertThinLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iLpDiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxTo	:_xZkqqHx_jBhNjDpMiImKjChFiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			eLine	:_xZkqqHx_jBhNjDpMiClHiCoJiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeB_xHqqkZx_lIdxTo_xZkqqHx_iCkKjBkOiClHiCoJiNhDiCmNiMhAjBlBiNhDiCkK_xHqqkZx_
 *			_xZkqqHx_jIeBiMiLiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *			eLine_xZkqqHx_iCmNiLpDiBgJ_xHqqkZx_FDRCH_RETURN_xZkqqHx_iCmMiCnNiBgKiCmFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNhDjBhNjDpMiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAjBhNjDpMiKeKiOgOiEkAiNhDiBjFjFlGiOjKiEkAiDfEiDeDiDfJiEkA_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_Index   _xZkqqHx_iEkAiPoOjFpB_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJiEjP_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiEjPiJmCjFmPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                        _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//void CFCWndRichEdit::CmdInsertThinLine (long lIdxTo, const FCEditLine& eLine)
long CFCWndRichEdit::CmdInsertThinLine (long lIdxTo, const FCEditLine& eLine)
{
	long lLineTo;
	long lChar;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLineTo, lChar, lIdxTo);
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iNhDiCmMiDfOiDeDiDhGiCmNjAoGjDkKiCmFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_OutLinChrStream _xZkqqHx_iCmNiNhDiDfOiDeDiDhGiCpAiPgPjHmNiClFiCmIiCkCiClNiCnPiBeC_xHqqkZx_
	ASSERT(eLine.m_byLineType == FDRC_LT_HEAD);
	ASSERT(eLine.m_vEditChar.size() == 1);
	ASSERT(eLine.m_vEditChar[0].m_wChar == FDRCH_RETURN);
	ASSERT(lLineTo == m_vEditLine.size() || m_vEditLine[lLineTo].m_byLineType == FDRC_LT_HEAD);
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
	const long lSize0 = GetCmdQueueSize();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteCmdQueue(BYTE(FDECMD_INSERT_THIN_LINE));
	// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lIdxTo);
	// _xZkqqHx_jBhNjDpMiClHiCoJiNhDiCpAiLeMjIfOiBeC_xHqqkZx_
	eLine.OutLinChrStream(m_byvCmdQueue);
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
	const long lCmdSize = GetCmdQueueSize() - lSize0;
	InsertVSizeUCmdQueue(lSize0, lCmdSize);
	WriteVSizeUCmdQueue(lCmdSize);
	// _xZkqqHx_iNhDiCpAjBhNjDpMiBeC_xHqqkZx_
	m_vEditLine.insert(m_vEditLine.begin() + lLineTo, eLine); 
	// _xZkqqHx_jBhNjDpMiNhDiCpAjFnEiClHiBeC_xHqqkZx_
	return lLineTo;
} // CFCWndRichEdit::CmdInsertThinLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdReplaceChars
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iCfAiNhDjCiGiCmMjFkBjAjEiCmMjFlGiOjKiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxFrom:_xZkqqHx_jDpMiCoKjBnGiCkGiCoJiImKjChFiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lDelSz	:_xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *			pInsChar:_xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjEhKjHpBiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lInsSz	:pChar_xZkqqHx_iCmMjEhKjHpBiDfEiDeDiDfJiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeB_xHqqkZx_lIdxFrom_xZkqqHx_iCkKjBkOiClHiCoJiNhDiCmNiMhAjBlBiNhDiCkK_xHqqkZx_
 *			_xZkqqHx_jIeBiMiLiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jFlGiOjKjChFiKlHiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAjChFiKlHiKeKiOgOiEkAiNoNiPjM_xHqqkZx_  _xZkqqHx_iEkAjFlGiOjK_xHqqkZx_  _xZkqqHx_iEkAjFlGiOjK_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAjFlGiOjK_xHqqkZx_  _xZkqqHx_iEkAjBhNjDpM_xHqqkZx_  _xZkqqHx_iEkAjFlGiOjK_xHqqkZx_  _xZkqqHx_iEkAjFlGiOjK_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAjFlGiOjK_xHqqkZx_  _xZkqqHx_iEkAiDfEiDeDiDfJiEkA_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_Index   _xZkqqHx_iEkAjFlGiOjKjAjEiEkAiPoOjFpBiCfAiEkAiPoOjFpBiCfBiEkA_xHqqkZx_      _xZkqqHx_iEkAiPoOjFpBiCiOiEkAjFlGiOjKjAjEiEkAiPoOjFpBiCfAiEkAiPoOjFpBiCfBiEkA_xHqqkZx_      _xZkqqHx_iEkAiPoOjFpBiCiNiEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJiEjP_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiMmFjCoIiEjPiEkJiMmFjCoIiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiMmFjCoIiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiMmFjCoIiEjPiEkJiMmFjCoIiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiMmFjCoIiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                      _xZkqqHx_iEkA_xHqqkZx_                              _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_                              _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                      _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiNoNiPjMjFlGiOjKjAjEiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPjBhNjDpMjFlGiOjKjAjEiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                                                                                              _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.15 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//void CFCWndRichEdit::CmdReplaceChars (	long lIdxFrom,
//										long lDelSz,
//										const FCEditChar* pInsChar,
//										long lInsSz)
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
long CFCWndRichEdit::CmdReplaceChars (	long lIdxFrom,
										long lDelSz,
										const FCEditChar* pInsChar,
										long lInsSz)
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
{
	long lLine;
	long lCharFrom;
	long lC;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLine, lCharFrom, lIdxFrom);
	long lCharTo = lCharFrom + lDelSz;
	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
	const long lSize0 = GetCmdQueueSize();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteCmdQueue(BYTE(FDECMD_REPLACE_CHARS));
	// _xZkqqHx_jDpMiCoKjBnGiCkGiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lIdxFrom);
	// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lDelSz);
	// _xZkqqHx_iImIiNhOiPiIjHjNiCmMjHjIjFnGiCmMiInHiBeBjFmPjAjEiCmJjBoDjDpMiBeC_xHqqkZx_
	FCEditCharVector& vChar = m_vEditLine[lLine].m_vEditChar;
	// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjHpBiCpAiLeMjIfOiBeC_xHqqkZx_
	for (lC = lCharFrom; lC < lCharTo; lC++) WriteCmdQueue(vChar[lC]);
	// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lInsSz);
	// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjHpBiCpAiLeMjIfOiBeC_xHqqkZx_
	for (lC = 0; lC < lInsSz; lC++) WriteCmdQueue(pInsChar[lC]);
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
	const long lCmdSize = GetCmdQueueSize() - lSize0;
	InsertVSizeUCmdQueue(lSize0, lCmdSize);
	WriteVSizeUCmdQueue(lCmdSize);
	// _xZkqqHx_jFlGiOjKjHpBiCpAiNoNiPjMiBeC_xHqqkZx_
	if (0 < lDelSz)
	{
		// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
		RegisterClearRgn(vChar.begin() + lCharFrom, vChar.begin() + lCharTo); 
		vChar.erase(vChar.begin() + lCharFrom, vChar.begin() + lCharTo);
	}
	// _xZkqqHx_jFlGiOjKjHpBiCpAjBhNjDpMiBeC_xHqqkZx_
	if (0 < lInsSz)
		vChar.insert(vChar.begin() + lCharFrom, pInsChar, pInsChar + lInsSz);
	return lLine;
} // CFCWndRichEdit::CmdReplaceChars.

//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdInsertLine
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iCfAiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxTo	:_xZkqqHx_jBhNjDpMiImKjChFiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
// *			eLine	:_xZkqqHx_jBhNjDpMiClHiCoJiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeB_xHqqkZx_lIdxTo_xZkqqHx_iCkKjBkOiClHiCoJiNhDiCmNiMhAjBlBiNhDiCkK_xHqqkZx_
// *			_xZkqqHx_jIeBiMiLiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNhDjBhNjDpMiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
// *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
// *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAjBhNjDpMiKeKiOgOiEkAiNhDiBjFjFlGiOjKiEkAiDfEiDeDiDfJiEkA_xHqqkZx_
// *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_Index   _xZkqqHx_iEkAiPoOjFpB_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
// *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
// *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
// *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJiEjP_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiEjPiJmCjFmPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
// *                 _xZkqqHx_iEkA_xHqqkZx_                        _xZkqqHx_iEkA_xHqqkZx_
// *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.15 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::CmdInsertLine (long lIdxTo, const FCEditLine& eLine)
//{
//	long lLineTo;
//	long lChar;
//	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
//	IndexToCharPos(lLineTo, lChar, lIdxTo);
////----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iNhDiCmMiDfOiDeDiDhGiCmNjAoGjDkKiCmFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_OutLinChrStream _xZkqqHx_iCmNiNhDiDfOiDeDiDhGiCpAiPgPjHmNiClFiCmIiCkCiClNiCnPiBeC_xHqqkZx_
//	ASSERT(eLine.m_byLineType == FDRC_LT_HEAD);
//	ASSERT(lLineTo == m_vEditLine.size() || m_vEditLine[lLineTo].m_byLineType == FDRC_LT_HEAD);
////----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
//	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
//	const long lSize0 = GetCmdQueueSize();
//	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
//	WriteCmdQueue(BYTE(FDECMD_INSERT_LINE));
//	// _xZkqqHx_jBhNjDpMiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
//	WriteVSizeUCmdQueue(lIdxTo);
//	// _xZkqqHx_jBhNjDpMiClHiCoJiNhDiCpAiLeMjIfOiBeC_xHqqkZx_
//	eLine.OutLinChrStream(m_byvCmdQueue);
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
//	const long lCmdSize = GetCmdQueueSize() - lSize0;
//	InsertVSizeUCmdQueue(lSize0, lCmdSize);
//	WriteVSizeUCmdQueue(lCmdSize);
//	// _xZkqqHx_iNhDiCpAjBhNjDpMiBeC_xHqqkZx_
//	m_vEditLine.insert(m_vEditLine.begin() + lLineTo, eLine); 
//} // CFCWndRichEdit::CmdInsertLine.
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdFormatLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iCfAiNhDiCmMiPoOjFpBiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxTo	:_xZkqqHx_jFmPiNfIiClHiCoJiNhDiCpAiOkGiClHiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			eLine	:_xZkqqHx_jFmPiNfIiClHiCoJiPoOjFpBiCpAiOpLiCnPiClNiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jFmPiNfIiClFiClNiNhDiBeCjFmPiNfIiCkKjFhDjHhGiCmMiPoKiNiHiCmN_xHqqkZx_ -1_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNhDiPoOjFpBjFmPiNfIiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAiNhDiCmMjFlGiOjKiEkAjFmPiNfIjBeP_xHqqkZx_  _xZkqqHx_iEkAjFmPiNfIiMoD_xHqqkZx_  _xZkqqHx_iEkAiDfEiDeDiDfJiEkA_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_Index   _xZkqqHx_iEkAiNhDiPoOjFpB_xHqqkZx_  _xZkqqHx_iEkAiNhDiPoOjFpB_xHqqkZx_  _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJiEjP_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiEjPiJmCjFmPiEjPiEkJiEjPiJmCjFmPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                                  _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//void CFCWndRichEdit::CmdFormatLine (long lIdxTo, const FCEditLine& eLine)
long CFCWndRichEdit::CmdFormatLine (long lIdxTo, const FCEditLine& eLine)
{
	long lLine;
	long lChar;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLine, lChar, lIdxTo);
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iNhDiCmMiDfOiDeDiDhGiCmNjAoGjDkKiCmFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_OutLinStream _xZkqqHx_iCmNiNhDiDfOiDeDiDhGiCpAiPgPjHmNiClFiCmIiCkCiClNiCnPiBeC_xHqqkZx_
	ASSERT(m_vEditLine[lLine].m_byLineType == FDRC_LT_HEAD);
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKjFmPiNfIjAoGiCmGjDkPiClGiPoKiNiHiCpAjClCiNlIiBeCjDkPiClGiPoKiNiHiCmNiPiIjHjNiClJiClIjFjMiLeBiBeC_xHqqkZx_
	if (m_vEditLine[lLine] == eLine)
		return -1;
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
	const long lSize0 = GetCmdQueueSize();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteCmdQueue(BYTE(FDECMD_FORMAT_LINE));
	// _xZkqqHx_jFmPiNfIiClHiCoJiNhDiCmMjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lIdxTo);
	// _xZkqqHx_jFmPiNfIjBePiNhDiPoOjFpBiCpAiLeMjIfOiBeC_xHqqkZx_
	m_vEditLine[lLine].OutLinStream(m_byvCmdQueue);
	// _xZkqqHx_jFmPiNfIiMoDiNhDiPoOjFpBiCpAiLeMjIfOiBeC_xHqqkZx_
	eLine.OutLinStream(m_byvCmdQueue);
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
	const long lCmdSize = GetCmdQueueSize() - lSize0;
	InsertVSizeUCmdQueue(lSize0, lCmdSize);
	WriteVSizeUCmdQueue(lCmdSize);
	// _xZkqqHx_iNhDiPoOjFpBiCpAjFmPiNfIiBeC_xHqqkZx_
	m_vEditLine[lLine].CopyProperty(eLine);
	return lLine;
} // CFCWndRichEdit::CmdFormatLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdFormatChars
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFkBjAjEiNhDiCmJjDgOiCoJjFkBjAjEjFlGiOjKiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxFrom:_xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCmMjFmPiNfIiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lSize	:_xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *			pChar	:_xZkqqHx_jFmPiNfIiMoDiCmMiDhEiDeIiBfLiDhNiDgCiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeBiNhDiCkKjIeBiMiLiClDiCoKiCmEiCkCiCoJjFeLjHhGiCmNjGlDiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jFlGiOjKiPoOjFpBjFmPiNfIiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkGiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEkGiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkGiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAjFmPiNfIiKeKiOgOiEkAjFmPiNfI_xHqqkZx_  _xZkqqHx_iEkAjFmPiNfIjBeP_xHqqkZx_    _xZkqqHx_iEkAjFmPiNfIjBeP_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAjFmPiNfIjBeP_xHqqkZx_    _xZkqqHx_iEkAjFmPiNfIiMoD_xHqqkZx_    _xZkqqHx_iEkAjFmPiNfIiMoD_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAjFmPiNfIiMoD_xHqqkZx_    _xZkqqHx_iEkAiDfEiDeDiDfJiEkA_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_Index   _xZkqqHx_iEkAjFlGiOjKjAjEiEkAjFlGiOjKiPoOjFpBiCfAiEkAjFlGiOjKiPoOjFpBiCfBiEkA_xHqqkZx_      _xZkqqHx_iEkAjFlGiOjKiPoOjFpBiCiOiEkAjFlGiOjKiPoOjFpBiCfAiEkAjFlGiOjKiPoOjFpBiCfBiEkA_xHqqkZx_      _xZkqqHx_iEkAjFlGiOjKiPoOjFpBiCiOiEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkIiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEkIiBgD_xHqqkZx_  _xZkqqHx_iBgDiEkIiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_        _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_          _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJiEjP_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkJiEjPiMmFjCoIiEjPiEjPiEkJiEjPiMmFjCoIiEjPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiEjPiMmFjCoIiEjPiEjPiEkJiEjPiMmFjCoIiEjPiEjPiEkJiEjPiMmFjCoIiEjPiEjPiEkH_xHqqkZx_      _xZkqqHx_iEkFiEjPiMmFjCoIiEjPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                      _xZkqqHx_iEkA_xHqqkZx_                                          _xZkqqHx_iEkA_xHqqkZx_                                          _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                      _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPjFmPiNfIjFlGiOjKjAjEiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkJiEjPiEjPiEjPiEjPiEjPiEjPiEjPjFmPiNfIjFlGiOjKjAjEiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                                                                                                              _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CmdFormatChars (	long lIdxFrom, long lSize,
										const FCEditChar* pChar)
{
	long lLine;
	long lChar;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLine, lChar, lIdxFrom);
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKjFmPiNfIjAoGiCmGjDkPiClGiPoKiNiHiCpAjClCiNlIiBeCjDkPiClGiPoKiNiHiCmNiPiIjHjNiClJiClIjFjMiLeBiBeC_xHqqkZx_
	long lC;
	long lLn;
	long lCh;
	for (lLn = lLine, lCh = lChar, lC = 0; lC != lSize; lC++)
	{
		if (m_vEditLine[lLn].m_vEditChar[lCh] != pChar[lC]) break;
		(void)NextChar(lLn, lCh);
	}
	// _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiCkKjDkPiClGiPoKiNiHiCmNiPiIjHjNiClJiClIjFjMiLeBiBeC_xHqqkZx_
	if (lC == lSize) return;
//----- 05.07.01 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
	const long lSize0 = GetCmdQueueSize();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteCmdQueue(BYTE(FDECMD_FORMAT_CHARS));
	// _xZkqqHx_jFmPiNfIiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lIdxFrom);
	// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKjAjEiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(lSize);
	//----- _xZkqqHx_jFmPiNfIjBePjFlGiOjKiDgGiBfLiDfOiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	for (lLn = lLine, lCh = lChar, lC = 0; lC < lSize; lC++)
	{
		WriteCmdQueue(m_vEditLine[lLn].m_vEditChar[lCh]);
		(void)NextChar(lLn, lCh);
	}
	// _xZkqqHx_jFmPiNfIiMoDjFlGiOjKiDgGiBfLiDfOiCpAiPjBiCkLiPgPiClHiBeC_xHqqkZx_
	for (lC = 0; lC < lSize; lC++) WriteCmdQueue(pChar[lC]);
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
	const long lCmdSize = GetCmdQueueSize() - lSize0;
	InsertVSizeUCmdQueue(lSize0, lCmdSize);
	WriteVSizeUCmdQueue(lCmdSize);
	//----- _xZkqqHx_jFlGiOjKiDgGiBfLiDfOiCpAjFmPiNfIiClHiCoJ_xHqqkZx_ -----
	for (lLn = lLine, lCh = lChar, lC = 0; lC != lSize; lC++)
	{
		// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
		RegisterClearRgn(&(m_vEditLine[lLn].m_vEditChar[lCh]));
		m_vEditLine[lLn].m_vEditChar[lCh] = pChar[lC];
		m_vEditLine[lLn].m_vEditChar[lCh].m_nrRect.Empty();
		(void)NextChar(lLn, lCh);
	}
} // CFCWndRichEdit::CmdFormatChars.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdModifyMargin
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jHfNjEjCiCpAjFmPiNfIiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	mmMarginL	:_xZkqqHx_jHfNjEjCiNlGiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmMarginT	:_xZkqqHx_jHfNjEjCiPoDiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmMarginR	:_xZkqqHx_jHfNjEjCiJeFiCpAiOhHjCoIiBeC_xHqqkZx_
 *			mmMarginB	:_xZkqqHx_jHfNjEjCiJlKiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeBiNhDiCkKjIeBiMiLiClDiCoKiCmEiCkCiCoJjFeLjHhGiCmNjGlDiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jHfNjEjCjFmPiNfIiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAiCeP_xHqqkZx_  _xZkqqHx_iEkAjFmPiNfIjBePiEkAjFmPiNfIjBePiEkAjFmPiNfIjBePiEkAjFmPiNfIjBePiEkAjFmPiNfIiMoDiEkAjFmPiNfIiMoDiEkAjFmPiNfIiMoDiEkAjFmPiNfIiMoDiEkAiDfEiDeDiDfJiEkA_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_    _xZkqqHx_iEkAiNlGjHfNjEjCiEkAiPoDjHfNjEjCiEkAiJeFjHfNjEjCiEkAiJlKjHfNjEjCiEkAiNlGjHfNjEjCiEkAiPoDjHfNjEjCiEkAiJeFjHfNjEjCiEkAiJlKjHfNjEjCiEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJ_xHqqkZx_SizU_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_mmetol_xZkqqHx_iEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                                                                          _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.03.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CmdModifyMargin (	mmetol mmMarginL, mmetol mmMarginT,
										mmetol mmMarginR, mmetol mmMarginB)
{
	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
	const long lSize0 = GetCmdQueueSize();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteCmdQueue(BYTE(FDECMD_MODIFY_MARGIN));
	// _xZkqqHx_jFmPiNfIiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeCiPoNiCmJiCePiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(0);
	//----- _xZkqqHx_jFmPiNfIjBePjHfNjEjCiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	WriteCmdQueue(m_mmMarginL);
	WriteCmdQueue(m_mmMarginT);
	WriteCmdQueue(m_mmMarginR);
	WriteCmdQueue(m_mmMarginB);
	//----- _xZkqqHx_jFmPiNfIiMoDjHfNjEjCiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	WriteCmdQueue(mmMarginL);
	WriteCmdQueue(mmMarginT);
	WriteCmdQueue(mmMarginR);
	WriteCmdQueue(mmMarginB);
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
	const long lCmdSize = GetCmdQueueSize() - lSize0;
	InsertVSizeUCmdQueue(lSize0, lCmdSize);
	WriteVSizeUCmdQueue(lCmdSize);
	m_mmMarginL = mmMarginL;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginT = mmMarginT;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginR = mmMarginR;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginB = mmMarginB;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKjHfNjEjCiBeC_xHqqkZx_
} // CFCWndRichEdit::CmdModifyMargin.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CmdModifyVertAlign
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jAiCjClMjFpLiMpMiCmMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjAnNjCoIiClHiCoJiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	byAlign	:_xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeBiNhDiCkKjIeBiMiLiClDiCoKiCmEiCkCiCoJjFeLjHhGiCmNjGlDiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jAiCjClMiDeBiDiJiDeDiDjDiDiBiDjDiDgHjFmPiNfIiDfCiDhNiDjDiDgI_xHqqkZx_ _xZkqqHx_iDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
 *         _xZkqqHx_iEkGiEjPiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkGiEjPiEjPiEjPiEkG_xHqqkZx_
 *         _xZkqqHx_iEkAiDfEiDeDiDfJiEkAiDfCiDhNiEkAiCeP_xHqqkZx_  _xZkqqHx_iEkAjFmPiNfIjBeP_xHqqkZx_        _xZkqqHx_iEkAjFmPiNfIiMoD_xHqqkZx_        _xZkqqHx_iEkAiDfEiDeDiDfJiEkA_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkAiDjDiDgIiEkA_xHqqkZx_    _xZkqqHx_iEkAiDeBiDiJiDeDiDjDiDiBiDjDiDgHiEkAiDeBiDiJiDeDiDjDiDiBiDjDiDgHiEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkIiEjPiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkIiEjPiEjPiEjPiEkI_xHqqkZx_
 *         _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_    _xZkqqHx_iEkA_xHqqkZx_              _xZkqqHx_iEkA_xHqqkZx_              _xZkqqHx_iEkA_xHqqkZx_      _xZkqqHx_iEkA_xHqqkZx_
 *         _xZkqqHx_iEkF_xHqqkZx_SizU_xZkqqHx_iEjPiEkJ_xHqqkZx_BYTE_xZkqqHx_iEkJ_xHqqkZx_SizU_xZkqqHx_iEkJiEjPiEjP_xHqqkZx_BYTE_xZkqqHx_iEjPiEjPiEjPiEkJiEjPiEjP_xHqqkZx_BYTE_xZkqqHx_iEjPiEjPiEjPiEkJ_xHqqkZx_SizU_xZkqqHx_iEjPiEkH_xHqqkZx_
 *                 _xZkqqHx_iEkA_xHqqkZx_                                          _xZkqqHx_iEkA_xHqqkZx_
 *                 _xZkqqHx_iEkFiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiDfEiDeDiDfJiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEjPiEkH_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CmdModifyVertAlign (BYTE byAlign)
{
	// _xZkqqHx_iIoKiOjOiDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAiLeMiJkPiBeC_xHqqkZx_
	const long lSize0 = GetCmdQueueSize();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfCiBfLiDgIiCpAiLeMjIfOiBeC_xHqqkZx_
	WriteCmdQueue(BYTE(FDECMD_MODIFY_VERT_ALIGN));
	// _xZkqqHx_jFmPiNfIiCpAiKeKiOgOiClHiCoJjFlGiOjKiDeDiDjDiDgGiDgCiDeOiDfIiCpAiLeMjIfOiBeCiPoNiCmJiCePiBeC_xHqqkZx_
	WriteVSizeUCmdQueue(0);
	//----- _xZkqqHx_jFmPiNfIjBePiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	WriteCmdQueue(m_byVertAlign);
	//----- _xZkqqHx_jFmPiNfIiMoDiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAiPjBiCkLiPgPiClH_xHqqkZx_ -----
	WriteCmdQueue(byAlign);
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCmMiLeMjIfOiBeC_xHqqkZx_
	const long lCmdSize = GetCmdQueueSize() - lSize0;
	InsertVSizeUCmdQueue(lSize0, lCmdSize);
	WriteVSizeUCmdQueue(lCmdSize);
	m_byVertAlign = byAlign;	// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiCmMjAnNjCoIiBeC_xHqqkZx_
} // CFCWndRichEdit::CmdModifyVertAlign.

//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdDeleteLines
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdDeleteLines_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPeDjAlDiCkKjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::RedoCmdDeleteLines (long lLine, long lChar)
//{
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
//	long lSize = ReadVSizeUCmdQueue();
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiPoOjFpBiCpAjBjHiCoJiBeC_xHqqkZx_
//	for (long lC = 0; lC < lSize; lC++)
//	{
//		FCEditLine el;
//		const BYTE* bypHead = GetCmdQueuePtr();
//		el.InLinChrStream(bypHead);
//		SetCmdQueuePtr(bypHead);
//	}
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
//	RegisterClearRgn(m_vEditLine.begin() + lLine, m_vEditLine.begin() + lLine + lSize); 
//	// _xZkqqHx_iNhDiCpAiNoNiPjMiBeC_xHqqkZx_
//	m_vEditLine.erase(m_vEditLine.begin() + lLine, m_vEditLine.begin() + lLine + lSize); 
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex--;
//} // CFCWndRichEdit::RedoCmdDeleteLines.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdDeleteLines
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdDeleteLines_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPeDjAlDiCkKjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::UndoCmdDeleteLines (long lLine, long lChar)
//{
//	// _xZkqqHx_iNoNiPjMiClFiClNiNhDjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
//	long lSize = ReadVSizeUCmdQueue();
//	// _xZkqqHx_iNoNiPjMiClFiClNiNhDiPoOjFpBiCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
//	FCEditLineVector vTmp;
//	for (long lC = 0; lC < lSize; lC++)
//	{
//		vTmp.push_back(FCEditLine());
//		const BYTE* bypHead = GetCmdQueuePtr();
//		vTmp.back().InLinChrStream(bypHead);
//		SetCmdQueuePtr(bypHead);
//	}
//	// _xZkqqHx_iNhDiCpAjBhNjDpMiBeC_xHqqkZx_
//	m_vEditLine.insert(m_vEditLine.begin() + lLine, vTmp.begin(), vTmp.end());
//} // CFCWndRichEdit::UndoCmdDeleteLines.
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdReplaceChars
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdReplaceChars_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.15 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdReplaceChars (long lLine, long lChar)
{
	// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lDelSz = ReadVSizeUCmdQueue();
	// _xZkqqHx_jFlGiOjKjHpBiCpAjBjHiCoJiBeC_xHqqkZx_
	SeekCmdQueuePos(lDelSz * FCEditChar::SizeOfStream());
	// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lInsSz = ReadVSizeUCmdQueue();
	// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjHpBiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	FCEditCharVector vTmp;
	for (long lC = 0; lC < lInsSz; lC++)
	{
		vTmp.push_back(FCEditChar());
		ReadCmdQueue(vTmp.back());
	}
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iImIiNhOiPiIjHjNiCmMjHjIjFnGiCmMiInHiBeBjFmPjAjEiCmJjBoDjDpMiBeC_xHqqkZx_
	FCEditCharVector& vChar = m_vEditLine[lLine].m_vEditChar;
	// _xZkqqHx_jFlGiOjKjHpBiCpAiNoNiPjMiBeC_xHqqkZx_
	if (0 < lDelSz)
	{
		// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
		RegisterClearRgn(vChar.begin() + lChar, vChar.begin() + lChar + lDelSz);
		vChar.erase(vChar.begin() + lChar, vChar.begin() + lChar + lDelSz);
	}
	// _xZkqqHx_jFlGiOjKjHpBiCpAjBhNjDpMiBeC_xHqqkZx_
	if (0 < lInsSz)
		vChar.insert(vChar.begin() + lChar, vTmp.begin(), vTmp.end());
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex = m_lCurIndex + lInsSz;
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::RedoCmdReplaceChars.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdReplaceChars
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdReplaceChars_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.15 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdReplaceChars (long lLine, long lChar)
{
	// _xZkqqHx_iNoNiPjMiClFiClNjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lDelSz = ReadVSizeUCmdQueue();
	// _xZkqqHx_iNoNiPjMiClFiClNjFlGiOjKjHpBiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	FCEditCharVector vTmp;
	for (long lC = 0; lC < lDelSz; lC++)
	{
		vTmp.push_back(FCEditChar());
		ReadCmdQueue(vTmp.back());
	}
	// _xZkqqHx_jBhNjDpMiClFiClNjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lInsSz = ReadVSizeUCmdQueue();
	// _xZkqqHx_iImIiNhOiPiIjHjNiCmMjHjIjFnGiCmMiInHiBeBjFmPjAjEiCmJjBoDjDpMiBeC_xHqqkZx_
	FCEditCharVector& vChar = m_vEditLine[lLine].m_vEditChar;
	// _xZkqqHx_jFlGiOjKjHpBiCpAiNoNiPjMiBeC_xHqqkZx_
	if (0 < lInsSz)
	{
		// _xZkqqHx_iNoNiPjMiClHiCoJjFlGiOjKiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
		RegisterClearRgn(vChar.begin() + lChar, vChar.begin() + lChar + lInsSz);
		vChar.erase(vChar.begin() + lChar, vChar.begin() + lChar + lInsSz);
	}
	// _xZkqqHx_jFlGiOjKjHpBiCpAjBhNjDpMiBeC_xHqqkZx_
	if (0 < lDelSz)
		vChar.insert(vChar.begin() + lChar, vTmp.begin(), vTmp.end());
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex = m_lCurIndex + lDelSz;
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::UndoCmdReplaceChars.

//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdInsertLine
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdInsertLine_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPeDjAlDiCkKjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::RedoCmdInsertLine (long lLine, long lChar)
//{
//	// _xZkqqHx_jBhNjDpMiClFiClNiNhDiPoOjFpBiCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
//	FCEditLine el;
//	const BYTE* bypHead = GetCmdQueuePtr();
//	el.InLinChrStream(bypHead);
//	SetCmdQueuePtr(bypHead);
////----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
////	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
////	(void)ReadVSizeUCmdQueue();
////----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
//	// _xZkqqHx_iNhDiCpAjBhNjDpMiBeC_xHqqkZx_
//	m_vEditLine.insert(m_vEditLine.begin() + lLine, el);
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex += el.m_vEditChar.size();
//} // CFCWndRichEdit::RedoCmdInsertLine.
//
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdInsertLine
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdInsertLine_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPeDjAlDiCkKjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
// *************************************************************************/
//void CFCWndRichEdit::UndoCmdInsertLine (long lLine, long lChar)
//{
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
//	RegisterClearRgn(m_vEditLine.begin() + lLine); 
//	// _xZkqqHx_iNhDiCpAiNoNiPjMiBeC_xHqqkZx_
//	m_vEditLine.erase(m_vEditLine.begin() + lLine);
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex--;
//} // CFCWndRichEdit::UndoCmdInsertLine.
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdFormatLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdFormatLine_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPeDjAlDiCkKjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdFormatLine (long lLine, long lChar)
{
	FCEditLine el;
	const BYTE* bypHead = GetCmdQueuePtr();
	// _xZkqqHx_jFmPiNfIjBePiNhDiPoOjFpBiCpAiDfIiDeMiDgCiDhGiBeC_xHqqkZx_
	el.InLinStream(bypHead);
	// _xZkqqHx_jFmPiNfIiMoDiNhDiPoOjFpBiCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
	el.InLinStream(bypHead);
	SetCmdQueuePtr(bypHead);
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iNhDiPoOjFpBiCpAjFmPiNfIiBeC_xHqqkZx_
	m_vEditLine[lLine].CopyProperty(el);
} // CFCWndRichEdit::RedoCmdFormatLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdFormatLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdFormatLine_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPeDjAlDiCkKjDpMiCmBiClNiNhDiCmMiNmFiPkMjCgMiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.13 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdFormatLine (long lLine, long lChar)
{
	FCEditLine el;
	const BYTE* bypHead = GetCmdQueuePtr();
	// _xZkqqHx_jFmPiNfIjBePiNhDiPoOjFpBiCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
	el.InLinStream(bypHead);
	// _xZkqqHx_iNhDiPoOjFpBiCpAjFmPiNfIiBeC_xHqqkZx_
	m_vEditLine[lLine].CopyProperty(el);
} // CFCWndRichEdit::UndoCmdFormatLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdFormatChars
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdFormatChars_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdFormatChars (long lLine, long lChar)
{
	// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lSize = ReadVSizeUCmdQueue();
	// _xZkqqHx_jFlGiOjKjHpBiCpAjBjHiCoJiBeC_xHqqkZx_
	SeekCmdQueuePos(lSize * FCEditChar::SizeOfStream());
	// _xZkqqHx_jFmPiNfIiMoDiCmMjFlGiOjKjHpBiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lC;
	FCEditCharVector vTmp;
	for (lC = 0; lC < lSize; lC++)
	{
		vTmp.push_back(FCEditChar());
		ReadCmdQueue(vTmp.back());
	}
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	//----- _xZkqqHx_jFlGiOjKiDgGiBfLiDfOiCpAjFmPiNfIiClHiCoJ_xHqqkZx_ -----
	long lLn;
	long lCh;
	for (lLn = lLine, lCh = lChar, lC = 0; lC < lSize; lC++)
	{
		// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
		RegisterClearRgn(&(m_vEditLine[lLn].m_vEditChar[lCh]));
		m_vEditLine[lLn].m_vEditChar[lCh] = vTmp[lC];
		m_vEditLine[lLn].m_vEditChar[lCh].m_nrRect.Empty();
		(void)NextChar(lLn, lCh);
	}
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex += lSize;
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::RedoCmdFormatChars.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdFormatChars
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdFormatChars_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.16 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdFormatChars (long lLine, long lChar)
{
	// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKjAjEiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lSize = ReadVSizeUCmdQueue();
	// _xZkqqHx_jFmPiNfIjBePiCmMjFlGiOjKjHpBiCpAjDmHiCnNiPgPiClHiBeC_xHqqkZx_
	long lC;
	FCEditCharVector vTmp;
	for (lC = 0; lC < lSize; lC++)
	{
		vTmp.push_back(FCEditChar());
		ReadCmdQueue(vTmp.back());
	}
	//----- _xZkqqHx_jFlGiOjKiDgGiBfLiDfOiCpAjFmPiNfIiClHiCoJ_xHqqkZx_ -----
	long lLn;
	long lCh;
	for (lLn = lLine, lCh = lChar, lC = 0; lC < lSize; lC++)
	{
		// _xZkqqHx_jFmPiNfIiClHiCoJjFlGiOjKiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
		RegisterClearRgn(&(m_vEditLine[lLn].m_vEditChar[lCh]));
		m_vEditLine[lLn].m_vEditChar[lCh] = vTmp[lC];
		m_vEditLine[lLn].m_vEditChar[lCh].m_nrRect.Empty();
		(void)NextChar(lLn, lCh);
	}
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex += lSize;
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::UndoCmdFormatChars.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdModifyMargin
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdModifyMargin_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.03.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdModifyMargin (long lLine, long lChar)
{
	mmetol mmMarginL, mmMarginT, mmMarginR, mmMarginB;
	// _xZkqqHx_jFmPiNfIjBePjHfNjEjCiCpAjBjHiCoJiBeC_xHqqkZx_
	SeekCmdQueuePos(4 * sizeof(mmMarginL));
	// _xZkqqHx_jFmPiNfIiMoDjHfNjEjCiCpAiOoGiCoIiPgPiClHiBeC_xHqqkZx_
	ReadCmdQueue(mmMarginL);
	ReadCmdQueue(mmMarginT);
	ReadCmdQueue(mmMarginR);
	ReadCmdQueue(mmMarginB);
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_jHfNjEjCiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
	m_mmMarginL = mmMarginL;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginT = mmMarginT;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginR = mmMarginR;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginB = mmMarginB;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKjHfNjEjCiBeC_xHqqkZx_
} // CFCWndRichEdit::RedoCmdModifyMargin.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdModifyMargin
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdModifyMargin_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.03.05 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdModifyMargin (long lLine, long lChar)
{
	mmetol mmMarginL, mmMarginT, mmMarginR, mmMarginB;
	// _xZkqqHx_jFmPiNfIjBePjHfNjEjCiCpAiOoGiCoIiPgPiClHiBeC_xHqqkZx_
	ReadCmdQueue(mmMarginL);
	ReadCmdQueue(mmMarginT);
	ReadCmdQueue(mmMarginR);
	ReadCmdQueue(mmMarginB);
	// _xZkqqHx_jFmPiNfIiMoDjHfNjEjCiCpAjBjHiCoJiBeC_xHqqkZx_
	SeekCmdQueuePos(4 * sizeof(mmMarginL));
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
	(void)ReadVSizeUCmdQueue();
	// _xZkqqHx_jHfNjEjCiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
	m_mmMarginL = mmMarginL;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginT = mmMarginT;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginR = mmMarginR;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFjHfNjEjCiBeC_xHqqkZx_
	m_mmMarginB = mmMarginB;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKjHfNjEjCiBeC_xHqqkZx_
} // CFCWndRichEdit::UndoCmdModifyMargin.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdModifyVertAlign
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdModifyVertAlign_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdModifyVertAlign (long lLine, long lChar)
{
	BYTE byAlign;
	// _xZkqqHx_jFmPiNfIjBePiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjBjHiCoJiBeC_xHqqkZx_
	SeekCmdQueuePos(sizeof(byAlign));
	// _xZkqqHx_jFmPiNfIiMoDiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAiOoGiCoIiPgPiClHiBeC_xHqqkZx_
	ReadCmdQueue(byAlign);
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
	m_byVertAlign = byAlign;
} // CFCWndRichEdit::RedoCmdModifyVertAlign.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdModifyVertAlign
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdModifyVertAlign_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.01 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdModifyVertAlign (long lLine, long lChar)
{
	BYTE byAlign;
	// _xZkqqHx_jFmPiNfIjBePiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAiOoGiCoIiPgPiClHiBeC_xHqqkZx_
	ReadCmdQueue(byAlign);
	// _xZkqqHx_jFmPiNfIiMoDiDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjBjHiCoJiBeC_xHqqkZx_
	SeekCmdQueuePos(sizeof(byAlign));
	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
	(void)ReadVSizeUCmdQueue();
	// _xZkqqHx_iDeBiDiJiDeDiDjDiDiBiDjDiDgHiCpAjAnNjCoIiClHiCoJiBeC_xHqqkZx_
	m_byVertAlign = byAlign;
} // CFCWndRichEdit::UndoCmdModifyVertAlign.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdDeleteThinLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdDeleteThinLine_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdDeleteThinLine (long lLine, long lChar)
{
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiPoOjFpBiCpAjBjHiCoJiBeC_xHqqkZx_
//	const BYTE* bypHead = GetCmdQueuePtr();
//	FCEditLine().InLinChrStream(bypHead);
//	SetCmdQueuePtr(bypHead);
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
	RegisterClearRgn(m_vEditLine.begin() + lLine, NULL); 
	// _xZkqqHx_iNhDiCpAiNoNiPjMiBeC_xHqqkZx_
	m_vEditLine.erase(m_vEditLine.begin() + lLine, m_vEditLine.begin() + lLine + 1); 
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex--;
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::RedoCmdDeleteThinLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdDeleteThinLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdDeleteThinLine_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdDeleteThinLine (long lLine, long lChar)
{
	// _xZkqqHx_iNoNiPjMiClFiClNiNhDiPoOjFpBiCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
	FCEditLine el;
	const BYTE* bypHead = GetCmdQueuePtr();
	el.InLinChrStream(bypHead);
	SetCmdQueuePtr(bypHead);
	// _xZkqqHx_iNhDiCpAjBhNjDpMiBeC_xHqqkZx_
	m_vEditLine.insert(m_vEditLine.begin() + lLine, &el, &el + 1);
} // CFCWndRichEdit::UndoCmdDeleteThinLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::RedoCmdInsertThinLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdInsertThinLine_xZkqqHx_iCmMiPiHiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::RedoCmdInsertThinLine (long lLine, long lChar)
{
	// _xZkqqHx_jBhNjDpMiClFiClNiNhDiPoOjFpBiCpAjDmHiCnNiNjOiCnOiBeC_xHqqkZx_
	FCEditLine el;
	const BYTE* bypHead = GetCmdQueuePtr();
	el.InLinChrStream(bypHead);

	// _xZkqqHx_iNhDiCmMiDfOiDeDiDhGiCmNjAoGjDkKiCmFiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_OutLinChrStream _xZkqqHx_iCmNiNhDiDfOiDeDiDhGiCpAiPgPjHmNiClFiCmIiCkCiClNiCnPiBeC_xHqqkZx_
	ASSERT(el.m_byLineType == FDRC_LT_HEAD);
	ASSERT(el.m_vEditChar.size() == 1);
	ASSERT(el.m_vEditChar[0].m_wChar == FDRCH_RETURN);

	SetCmdQueuePtr(bypHead);
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iDfEiDeDiDfJ_xHqqkZx_Bn_xZkqqHx_iCpAiDfIiDeMiDgCiDhGiClHiCoJiBeC_xHqqkZx_
//	(void)ReadVSizeUCmdQueue();
//----- 06.02.19 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	// _xZkqqHx_iNhDiCpAjBhNjDpMiBeC_xHqqkZx_
	m_vEditLine.insert(m_vEditLine.begin() + lLine, el);
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex += el.m_vEditChar.size();
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::RedoCmdInsertThinLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::UndoCmdInsertThinLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	CmdInsertThinLine_xZkqqHx_iCmMiLhEiDfCiDhNiDjDiDgIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::UndoCmdInsertThinLine (long lLine, long lChar)
{
	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiNmEjFgAiJoGiNfIjAfGjHmMiIoGiCmJjDgPjIfOiBeC_xHqqkZx_
	RegisterClearRgn(m_vEditLine.begin() + lLine); 
	// _xZkqqHx_iNhDiCpAiNoNiPjMiBeC_xHqqkZx_
	m_vEditLine.erase(m_vEditLine.begin() + lLine);
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNfIjAfGiBeC_xHqqkZx_
//	m_lCurIndex--;
//----- 06.02.24 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
} // CFCWndRichEdit::UndoCmdInsertThinLine.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::MCmdDeleteSelection
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBeJjBpAjFjEjFkKiCpAiNoNiPjMiClHiCoJiBeCiNhDiCmMiNmEiMhGiOfKiBeFiNmEjFfMiOkGiCmNiClFiCmIiCkC_xHqqkZx_.
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iNoNiPjMiClFiClNiPoKiNiH_xHqqkZx_	:_xZkqqHx_iNoNiPjMiClDiCoKiClNjFjEjFkKiCmMiNmFiPiJiCmMiNhD_xHqqkZx_.
 *			_xZkqqHx_iNoNiPjMiClFiCmIiCkJiCmBiClNiPoKiNiH_xHqqkZx_ :-1
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBeJjBpAjFjEjFkKiCpAiNoNiPjMiClFiBeBiMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNoNiPjMjFjEjFkKiCmMiNmFiPiJiCmJ_xHqqkZx_
 *			_xZkqqHx_iInKjDkOiClHiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jCfAjBmMiCmMiDfCiDhNiDjDiDgIiCmFiCmNiCmIiCkNiBeBjDoAjFjEiCmFjFkBjAjEiCmMiDfCiDhNiDjDiDgIiCpAjEkNiNhDiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.04 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *			99.11.12 Fukushiro M. _xZkqqHx_iDfCiDhNiDjDiDgIiCmJjFmPiNfIiBeC_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::MCmdDeleteSelection ()
{
	if (m_lSelFrom < 0) return -1;

	long	lLineFrom, lLineTo;
	long	lCharFrom, lCharTo;
	long lSelFrom, lSelTo;
	GetSelectNormal(lSelFrom, lSelTo);
	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiNoNiPjMiImKjChFiCmMjAoGjDkKiCmJiInKjDkOiBeC_xHqqkZx_
	m_lCurIndex = lSelFrom;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLineFrom, lCharFrom, lSelFrom);
	// lLineFrom_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
	(void)JoinLineBelow(lLineFrom);
	// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLineFrom, lCharFrom, lSelFrom);
	IndexToCharPos(lLineTo, lCharTo, lSelTo);

	if (lLineFrom == lLineTo)
	{
		CmdReplaceChars(lSelFrom, lSelTo - lSelFrom, NULL, 0);
	} else
	{
		FCEditCharVector& vCharFrom = m_vEditLine[lLineFrom].m_vEditChar;
		FCEditCharVector& vCharTo = m_vEditLine[lLineTo].m_vEditChar;
		FCEditCharVector vCharTmp;
		// _xZkqqHx_iCnMiClIiBeBiNoNiPjMiPeJjHlJiNhDiCmMiNoNiPjMiPeJjHlJiImKjChFiImIiNhOiBeBiNhDjGjGiBgJiJpMiNhDiKnMiCnOiBgKiCnMiCmFiCpAiDgPiDgCiDeOiDeBiDgCiDhGiBeC_xHqqkZx_
		vCharTmp.insert(vCharTmp.end(), vCharTo.begin() + lCharTo, vCharTo.end());
		// _xZkqqHx_iNoNiPjMiKeKiOgOiNhDiCmMiOjPiCmMiNhDiCkJiCoHiNoNiPjMiPeJjHlJiNhDiBgJiKnMiCnOiBgKiCnMiCmFiNoNiPjMiBeC_xHqqkZx_
// 06.02.19 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//		CmdDeleteLines(lSelFrom - lCharFrom + vCharFrom.size(), lLineTo - lLineFrom);
		MCmdDeleteLines(lSelFrom - lCharFrom + vCharFrom.size(), lLineTo - lLineFrom);
		// _xZkqqHx_iNoNiPjMiKeKiOgOiNhDiCmMiKeKiOgOjFlGiOjKiImKjChFiCkJiCoHiNhDjGjGiBgJiJpMiNhDiKnMiCnOiBgKiCnMiCmFiCpAjDpMiCoKjBnGiCkGiCoJiBeC_xHqqkZx_
		CmdReplaceChars(lSelFrom, vCharFrom.size() - lCharFrom,
						vCharTmp.begin(), vCharTmp.size());
	}

	m_lSelFrom = m_lSelTo = -1;
	return lLineFrom;
} // CFCWndRichEdit::MCmdDeleteSelection.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::MCmdInsertText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMjFlGiOjKiImKjChFiCmJiCfAiNhDiCmMiDgFiDeMiDfIiDgHiCpAjBhNjDpMiClHiCoJiBeCjBhNjDpMiClHiCoJiDgFiDeMiDfIiDgHiCmN_xHqqkZx_
 *			_xZkqqHx_iNmFiMoDiCmMjFlGiOjKiImIiKePiCmJiJpMiNhDjFlGiOjKiCpAiOjNiCmBiCmEiCkCiCmEiCmNiCmIiCoHiCmIiCkCiBeCiNmFiMoDiCmJiJpMiNhDiCkK_xHqqkZx_
 *			_xZkqqHx_iCkAiCoJiPoKiNiHiCmNiBeBjBhNjDpMiImKjChFiImIiNhOiCmMjFlGiOjKjHpBiCkKiOjPiCmMiNhDiCnGiInKjDkOiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	vChar	: _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjHpB_xHqqkZx_
 *			pfpForm	: _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKjHpBiCmMiNhDiPoOjFpB_xHqqkZx_.NULL_xZkqqHx_iCmIiCoHiCmOiPoOjFpBjGlDiClF_xHqqkZx_.
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jBhNjDpMiClFiClNiPoKiNiH_xHqqkZx_		:_xZkqqHx_jBhNjDpMiClDiCoKiClNjFjEjFkKiCmMiNhDiBeC_xHqqkZx_
 *			_xZkqqHx_jBhNjDpMiClFiCmIiCkJiCmBiClNiPoKiNiH_xHqqkZx_	:-1
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	CalcLine_xZkqqHx_iCmNiOmAiNhDiClFiCmIiCkCiBeC_xHqqkZx_Redraw_xZkqqHx_iPiIjHjNiCpAiNhDiCoNiCmIiCkCiBeC_xHqqkZx_m_mmCaretX_xZkqqHx_iCpA_xHqqkZx_
 *			_xZkqqHx_iMhGiOfKiClFiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iJlKjAhNiCmMiPoKiNiHiCpAiNgMiCkGiCoJiBeC_xHqqkZx_
 *
 *          abcdefg     _xZkqqHx_iBkJ_xHqqkZx_ d_xZkqqHx_iCmG_xHqqkZx_e_xZkqqHx_iCmMiKnEiCmJ_xHqqkZx_"XYZ\n"_xZkqqHx_iCpAjBhNjDpMiBeC_xHqqkZx_
 *             _xZkqqHx_iBkL_xHqqkZx_
 *          abcdXYZ
 *          efg
 *
 *			OptimizeCmdQueue_xZkqqHx_iKnGjAjEiCmFiNmFjDeLiJlLiClFiCoCiClHiCkCjFpLjGeAiCmNiBeBjBhNjDpMiCmNjBeP_xHqqkZx_(_xZkqqHx_iPoD_xHqqkZx_)_xZkqqHx_iCkJiCoH_xHqqkZx_
 *			_xZkqqHx_iMoDiCoL_xHqqkZx_(_xZkqqHx_iJlK_xHqqkZx_)_xZkqqHx_iCmJiMpMiCkJiCmBiCmEiNhDiCkCiBeBiNoNiPjMiCmNiMoDiCoL_xHqqkZx_(_xZkqqHx_iJlK_xHqqkZx_)_xZkqqHx_iCkJiCoHjBeP_xHqqkZx_(_xZkqqHx_iPoD_xHqqkZx_)_xZkqqHx_iCmJiMpMiCkJiCkEjFpLjGeA_xHqqkZx_
 *			_xZkqqHx_iCmFiCkAiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iPoDjHoBiCmFiCmNiBeBiCnMiClI_xHqqkZx_ "efg\n" _xZkqqHx_iCpA_xHqqkZx_ "XYZ\n" _xZkqqHx_iCmJjChFiKlHiClFiBeBiOjPiCmJiLpDiNhDiCpAjBhNjDpMiClFiCmE_xHqqkZx_
 *			"efg\n" _xZkqqHx_iCpAjBhNjDpMiClHiCoJiCmMiCkKjHmHiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.15 Fukushiro M. _xZkqqHx_iPfHiNiHiDfCiDhNiDjDiDgIiCmJjFmPiNfIiBeC_xHqqkZx_
 *************************************************************************/
long CFCWndRichEdit::MCmdInsertText (	const FCEditCharVector& vChar,
										const FCTextLineInfo* tli)
{
#define CURLINE m_vEditLine[lLine]
	long lLine;
	long lChar;
	// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKiCkKjGlDiCkPiCoKiCmOjFjMiLeBiBeC_xHqqkZx_
	if (vChar.empty()) return -1;
	// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	GetCurCharPos(lLine, lChar);
	// lLineFrom_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
	(void)JoinLineBelow(lLine);
	// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
	GetCurCharPos(lLine, lChar);

	if (vChar.back().m_wChar == FDRCH_RETURN)
	//----- _xZkqqHx_iJpMiNhDjFhEiCkLiCmMjFlGiOjKjHpBiCpAjBhNjDpMiClHiCoJiPoKiNiH_xHqqkZx_ -----
	{
		//----- _xZkqqHx_jAfGiClFiCkCiNhDiCpAiNoMjAkM_xHqqkZx_(_xZkqqHx_iPoDjAhNjHoBiCmFiCmN_xHqqkZx_"efg\n") -----
		FCEditLine el;
		el.CopyProperty(CURLINE);
		el.m_byLineType = FDRC_LT_HEAD;
		el.m_vEditChar.insert(	el.m_vEditChar.begin(),
								CURLINE.m_vEditChar.begin() + lChar,
								CURLINE.m_vEditChar.end());
		// _xZkqqHx_jFlGiOjKjHpBiCpAjChFiKlH_xHqqkZx_(_xZkqqHx_iPoDjAhNjHoBiCmFiCmNiBeB_xHqqkZx_"efg\n" -> "XYZ\n")
		CmdReplaceChars(m_lCurIndex,
						CURLINE.m_vEditChar.size() - lChar,
						vChar.begin(),
						vChar.size());
		//----- _xZkqqHx_jAfGiClFiCkCiNhDiCpAjBhNjDpM_xHqqkZx_ -----
		// _xZkqqHx_iNhDjAoGjDkKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOfKiPgPiBeC_xHqqkZx_
		long lCharIndex = CharPosToIndex(lLine + 1, 0);
		MCmdInsertLine(lCharIndex, el);
	} else
	//----- _xZkqqHx_iJpMiNhDjGlDiClFiCmMjFlGiOjKjHpBiCpAjBhNjDpMiClHiCoJiPoKiNiH_xHqqkZx_ -----
	{
		//----- _xZkqqHx_jBhNjDpMjFlGiOjKjHpBiCpAiNhDiCmJjBhNjDpM_xHqqkZx_ -----
		CmdReplaceChars(m_lCurIndex, 0, vChar.begin(), vChar.size());
	}
	//----- _xZkqqHx_iNhDiPoOjFpBiCmMjAnNjCoI_xHqqkZx_ -----
	if (tli != NULL)
	//----- _xZkqqHx_iNhDiPoOjFpBiCkKiCkAiCoJiPoKiNiH_xHqqkZx_ -----
	{
		FCEditLine el;
		// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
		el.CopyProperty(CURLINE);
		// _xZkqqHx_iNhDiPoOjFpBiCpAiPoDiPjBiCkLjFmPiNfIiBeC_xHqqkZx_
		el.SetFormat(*tli);
		// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
		CmdFormatLine(m_lCurIndex - lChar, el);
	}
	// _xZkqqHx_iMlLiNnNiImKjChFiCpAjBhNjDpMjFlGiOjKiDfEiDeDiDfJjFkKiMoDjFpLiCnGiInKjDkOiBeC_xHqqkZx_
	m_lCurIndex += vChar.size();
	return lLine;
#undef CURLINE
} // CFCWndRichEdit::MCmdInsertText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::MCmdReplaceText
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iOhHjCoIiClDiCoKiClNjEmNiImNiCmMjFlGiOjKiCpAjChFiKlHiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lFrom	:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiPiJiCmMjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lTo		:_xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiMoDiCmMjFlGiOjKiCmMiOjPiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			wcpStr	:_xZkqqHx_jChFiKlHiClHiCoJjFlGiOjKjHpB_xHqqkZx_(wchar_t_xZkqqHx_iMfOjFlGiOjKjHpB_xHqqkZx_)_xZkqqHx_iCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_jBeJjBpAiClDiCoKiCoJjEmNiImNiCmNiBeB_xHqqkZx_[lFrom, lTo)_xZkqqHx_iCmMjFlGiOjKiCmFiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iDfKiDgCiDfGiDiHiDjDiCpAiDeJiBfLiDhGiDjDiClFiCmIiCkCiBeBiNhDiNmEiMhGiOfKiCoAiClFiCmIiCkCiClBiCmGiCmJjCiNiInDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.01.20 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//void CFCWndRichEdit::MCmdReplaceText (long lFrom, long lTo, const wchar_t* wcpStr)
long CFCWndRichEdit::MCmdReplaceText (long lFrom, long lTo, const wchar_t* wcpStr)
{
//----- 06.02.24 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_jFmPiNfIiKeKiOgOiImKjChFiCmMiNhDiBeC_xHqqkZx_
	long lLine = LONG_MAX;
//----- 06.02.24 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
	ASSERT(lFrom <= lTo);
	ASSERT(0 <= lFrom);
	// _xZkqqHx_jAfGiClFiCkCiDgFiDeMiDfIiDgHiCpAjBhNjDpMiClHiCoJiImKjChFiCmJiDeKiBfLiDfMiDiLiCpAiInKjDkOiBeC_xHqqkZx_
	m_lCurIndex = lFrom;
	if (lFrom != lTo)
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjHeMiCoJiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_jEmNiImNiCpAjBeJjBpAiBeC_xHqqkZx_
		SetSelect(lFrom, lTo);
	}
	// _xZkqqHx_jBhNjDpMiClHiCoJjFlGiOjKiCmMjBkOjAkLiBeC_xHqqkZx_
	FCEditChar eChar = GetCaretChar();
	if (lFrom != lTo)
	//----- _xZkqqHx_jBeJjBpAjEmNiImNiCkKjHeMiCoJiPoKiNiH_xHqqkZx_ -----
	{
		//----- _xZkqqHx_jFlGiOjKjHpBiCmMjChFiKlHjEmNiImNiCpAiCnMiClIiNoNiPjM_xHqqkZx_ -----
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
		DrawSelect();
		// _xZkqqHx_jEmNiImNiCpAiNoNiPjMiBeC_xHqqkZx_
		long lTmpLine = MCmdDeleteSelection();
		if (lTmpLine < lLine) lLine = lTmpLine;
	}
	// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
	FCFontCharInfo fciStdCodeFormat = m_fciCurStdCodeFormat;
	// _xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
	FCFontCharInfo fciExtCodeFormat = m_fciCurExtCodeFormat;
	// _xZkqqHx_jFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiCpAiBeBiOhHjCoIiCmMjFlGiOjKiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
	OverwriteFormat(fciExtCodeFormat, fciStdCodeFormat, eChar);

	//----- _xZkqqHx_jFlGiOjKjFjNiMhGiOfKjHhAiCmJiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_ -----
	// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
	CClientDC dc(this); // _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
	FCAutoDC atDC(&dc, FALSE, 0, 0);
//----- 06.05.22 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	LOGFONT logFont = { 0 };
//----- 06.05.22 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	// memset _xZkqqHx_iCmFiPiJiKpKiJlLiClHiCoJiClBiCmGiBeC_xHqqkZx_ = {0} _xZkqqHx_iCmFiCmNiCkEiCnMiCkNiPiJiKpKiJlLiCmFiCkLiCmIiCkCiPoKiNiHiCkKiCkAiCmBiClNiBeC_xHqqkZx_
	LOGFONT logFont;
	memset(&logFont, 0, sizeof(logFont));
//----- 06.05.22 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

	WORD wCodePage = CP_ACP;
	SFontID foidDCFont = SFontID(-1);		// _xZkqqHx_iClBiCoKiCpAiClFiCmIiCkCiCmGiBeBiNmFiPiJiCmMiDhEiDeIiDjDiDgHiPiJiKpKiJlLiCkKiClDiCoKiCmIiCkCiBeC_xHqqkZx_
//----- 06.06.23 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_jFmPiNfIiClDiCoKiCoJiPoKiNiHiCmNjGlDiCkCiCmGiOhGiCoNiCoKiCoJiCkKiBeBjEePiCmMiClNiCnPiBeCiPoDiJlKiInKjDkOiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
	WORD wDCOffset = WORD(-1);				// _xZkqqHx_jHeMiCoIjDlOiCmIiCkCjCgMiCpAjAnNjCoIiBeC_xHqqkZx_
//----- 06.06.23 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

	FCEditCharVector vCharTmp;
	for (long lC = 0; wcpStr[lC] != L'\0'; lC++)
	{
		// "\r\n"_xZkqqHx_iCmMiPoKiNiHiCmNiBeBiDhMiDeDiDjDiDfOiCpA_xHqqkZx_'\n'_xZkqqHx_iCmMiImKjChFiCnGiBeC_xHqqkZx_
		if (wcpStr[lC] == WCH_LF && wcpStr[lC + 1] == WCH_CR) lC++;
		FCSFontRec fntRec;
		// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiHiCmNiBeBjFfHiPiAjFlGiOjKiDfCiBfLiDgIjAoKjHhAiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
		if (FFIsStdFontChar(wcpStr[lC]))
		//----- _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
		{
			fntRec.Init(fciStdCodeFormat);
			eChar.Overread(fciStdCodeFormat);
		} else
		//----- _xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
		{
			fntRec.Init(fciExtCodeFormat);
			eChar.Overread(fciExtCodeFormat);
		}
		// Times New Roman _xZkqqHx_iCmM_xHqqkZx_ "ABC"_xZkqqHx_iCmM_xHqqkZx_B_xZkqqHx_iCpAjBeJjBpAiClFiCmEiBeBiDgFiDeMiDfIiDgH_xHqqkZx_"_xZkqqHx_iCkAiCkCiCkE_xHqqkZx_"_xZkqqHx_iCpAiBhFiDgFiDeMiDfIiDgHiCmGiClFiCmEjDfMiCoIjFhEiCkPiBhG_xHqqkZx_
		// _xZkqqHx_iClHiCoJiCmGiCkEiCnMiCkNiCkCiCkJiCmIiCkJiCmBiClNiCmMiCmFiBeB_xHqqkZx_vCharSet_xZkqqHx_iCpAiOhHjCoIiClHiCoJiCoGiCkEiCmJiClFiClNiBeC_xHqqkZx_
		// _xZkqqHx_iOhHjCoIiCmMjFlGiOjKiCkKjBkOiClHiCoJ_xHqqkZx_Charset_xZkqqHx_iCmMiPfHiNiHiCpAiOoGjDlOiBeC_xHqqkZx_
		WORDVector vCharSet;
		FFUnicodeToCharSet(vCharSet, wcpStr[lC], fntRec.GetCharSet());
		// FCSFontRec_xZkqqHx_iNfMjBkCjBmMiCkJiCoH_xHqqkZx_FontID_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
		SFontID foidFont = g_pEnv->FindNearestSFont(fntRec, &vCharSet);
		// _xZkqqHx_jGlDiCkCiPoKiNiHiCmNjDgPjIfOiClHiCoJiBeC_xHqqkZx_
		if (foidFont == FD_S_FONT_UNSPECIFY)
			g_pDoc->CmdInsert1SFont(foidFont, fntRec);

		if (wcpStr[lC] == WCH_LF || wcpStr[lC] == WCH_CR)
		//----- _xZkqqHx_iJpMiNhDiDfCiBfLiDgIiCmMiPoKiNiH_xHqqkZx_ -----
		{
			eChar.m_wChar = FDRCH_RETURN;
			eChar.m_foidFont = foidFont;
			// _xZkqqHx_iJpMiNhDiCmMjFfHiPiAjFjNiCpAjAnNjCoIiBeC_xHqqkZx_
			eChar.m_mmfWidth = FDWR_RETURN_WIDTH;
			eChar.m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
			eChar.m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
			vCharTmp.push_back(eChar);
			// _xZkqqHx_jFlGiOjKjHpBiCpAjBhNjDpMiBeCiJpMiNhDiClCiCmGiCmJjBhNjDpMiCkKjFeLjHhGiBeC_xHqqkZx_
			long lTmpLine = MCmdInsertText(vCharTmp);
			if (lTmpLine < lLine) lLine = lTmpLine;
			// _xZkqqHx_jBhNjDpMiPiIjHjNiCkKiPeJiCoNiCmBiClNiCmMiCmFiBeBiDgPiDgCiDhEiDeAiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
			vCharTmp.clear();
		} else
		if (wcpStr[lC] == WCH_SPC || wcpStr[lC] == WCH_TAB)
		//----- _xZkqqHx_iLpDjEjCiBeBiDfOiDhFiCmMiPoKiNiH_xHqqkZx_ -----
		{
			eChar.m_wChar = wcpStr[lC];
			eChar.m_foidFont = foidFont;
			// _xZkqqHx_iLpDjEjCiCmMjFfHiPiAjFjNiCpAiOoGjDlOiBjFjAnNjCoIiBeCiDfOiDhFiCmMiPoKiNiHiCmNiJlMjAnNjCoIiBeC_xHqqkZx_
			eChar.m_mmfWidth= g_pEnv->GetSFontRec(eChar.m_foidFont)->GetStdSpaceWidth();
			eChar.m_mmfAbcA	= 0.0;
			eChar.m_mmfAbcC	= 0.0;
			vCharTmp.push_back(eChar);
		} else
		//----- _xZkqqHx_iJpMiNhDiDfCiBfLiDgIiImIiKePiCmMiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJ_xHqqkZx_Zoom_xZkqqHx_iCpAiCfFiCfDjEhLiCmJjAnNjCoIiClHiCoJiBeC_xHqqkZx_
//----- 06.06.23 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//			const double dCurZoom = g_->dZoom;
//			g_->dZoom = g_->dDisplayPPM * 64;
//----- 06.06.23 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
			const FCAutoBackup<double> backupZoom(g_->dZoom, g_->dDisplayPPM * 64);
//----- 06.06.23 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

// 06.06.23 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//			if (foidDCFont != foidFont)
			if (foidDCFont != foidFont || wDCOffset != eChar.m_wOffset)
			//----- _xZkqqHx_iDhEiDeIiDjDiDgHiBeFiDeJiDhEiDfKiDgCiDgHiCkKjFmPiNfIiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
			{
				foidDCFont = foidFont;
// 06.06.23 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ ()
				wDCOffset = eChar.m_wOffset;
				g_pEnv->GetSFontRec(foidFont)->ReqInit(logFont, 0.0, eChar.m_wOffset);
				// _xZkqqHx_iDfCiBfLiDgIiDhJiBfLiDfHiCpAiOoGjDlOiBeC_xHqqkZx_
				wCodePage = ::CharSetToCodePage(logFont.lfCharSet);
				atDC.SetFont(&logFont);
			}

			eChar.m_wChar = wcpStr[lC];
			eChar.m_foidFont = foidFont;
			//----- _xZkqqHx_jFlGiOjKiBgJiDfCiBfLiDgI_xHqqkZx_m_wChar_xZkqqHx_iBgKiCmMjFjNiCpAiOoGjDlO_xHqqkZx_ -----
			ABC abc;
			// _xZkqqHx_iDfCiBfLiDgIiDhJiBfLiDfHiCpAjAnNjCoIiClFiCmIiCkCiCmGiBeBiDfOiDeDiMoKiCmIiCmHiCmFjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkCiBeC_xHqqkZx_
			atDC.GetCharABCWidth(eChar.m_wChar, abc, wCodePage);
			eChar.m_mmfWidth = fmmetol(lg2mm(abc.abcA + abc.abcB + abc.abcC));
			eChar.m_mmfAbcA = fmmetol(lg2mm(abc.abcA));
			eChar.m_mmfAbcC = fmmetol(lg2mm(abc.abcC));
//----- 06.06.23 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//			// Zoom_xZkqqHx_iCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_
//			g_->dZoom = dCurZoom;
//----- 06.06.23 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
			vCharTmp.push_back(eChar);
//----- 06.06.23 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//			// Zoom_xZkqqHx_iCpAiMlDiCmJjGnPiClHiBeC_xHqqkZx_
//			g_->dZoom = dCurZoom;
//----- 06.06.23 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		}
	}
	// _xZkqqHx_jFlGiOjKjHpBiCpAjBhNjDpMiBeC_xHqqkZx_
	long lTmpLine = MCmdInsertText(vCharTmp);
	if (lTmpLine < lLine) lLine = lTmpLine;
	// _xZkqqHx_iPeJjCfLiJpMiNhDiCpAiJhKiCkGiCoJiPoKiNiHiCkKiCkAiCoJiCmMiCmFiBeBiClLiCoKiCpAjGgIiOhOiBeC_xHqqkZx_
	const long lIdxSz = GetIndexSize();
	if (lIdxSz < m_lCurIndex) m_lCurIndex = lIdxSz;
	// _xZkqqHx_jFmPiNfIiKeKiOgOiNhDiCpAjFnEiClHiBeC_xHqqkZx_
	return lLine;
} // CFCWndRichEdit::MCmdReplaceText.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::MCmdDeleteLines
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFkBjAjEiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxFrom	:_xZkqqHx_iNoNiPjMiKeKiOgOiClHiCoJiNhDiCmMjAoGjDkKjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			lSize		:_xZkqqHx_iNoNiPjMiClHiCoJiNhDjAjEiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeB_xHqqkZx_lIdxFrom_xZkqqHx_iCkKjBkOiClHiCoJiNhDiCmNiMhAjBlBiNhDiCkK_xHqqkZx_
 *			_xZkqqHx_jIeBiMiLiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *			lIdxFrom_xZkqqHx_iCmMjBkOiClHiCoJiNhDiCmGiBeB_xHqqkZx_lIdxFrom+lSize_xZkqqHx_iCmMjBkOiClHiCoJiNhDiCmNjDkPiClGiNhDiCmF_xHqqkZx_
 *			_xZkqqHx_iCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iJlKjAhNiCmMjHoBiCmFiBeBiNhD_xHqqkZx_3_xZkqqHx_iBgAiNhD_xHqqkZx_5_xZkqqHx_iCpAiNoNiPjMiClHiCoJiPoKiNiHiCmNiBeB_xHqqkZx_lIdxFrom _xZkqqHx_iCmJiNhD_xHqqkZx_3_xZkqqHx_iCmM_xHqqkZx_
 *			_xZkqqHx_jAoGjDkKjFlGiOjKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeB_xHqqkZx_lSize _xZkqqHx_iCmJ_xHqqkZx_ 3 _xZkqqHx_iCpAiOhHjCoIiClHiCoJiBeC_xHqqkZx_
 *                 :
 *          _xZkqqHx_iNhD_xHqqkZx_3:  abc
 *          _xZkqqHx_iNhD_xHqqkZx_4:  efg
 *          _xZkqqHx_iNhD_xHqqkZx_5:  hij
 *                 :
 *			_xZkqqHx_iClBiCmMiPoKiNiHiBeBiNhD_xHqqkZx_3->_xZkqqHx_iNhD_xHqqkZx_5_xZkqqHx_iCmMjFpLiMpMiCmJiNoNiPjMiClHiCoJjFpLjGeAiCmGiNhD_xHqqkZx_5->_xZkqqHx_iNhD_xHqqkZx_3_xZkqqHx_iCmMjFpLiMpMiCmJ_xHqqkZx_
 *			_xZkqqHx_iNoNiPjMiClHiCoJjFpLjGeAiCkKiCkAiCoJiCkKiBeB_xHqqkZx_OptimizeCmdQueue_xZkqqHx_iKnGjAjEiCmFiNmFjDeLiJlLiClFiCoCiClHiCkC_xHqqkZx_
 *			_xZkqqHx_iCmMiCmNiNhD_xHqqkZx_5->_xZkqqHx_iNhD_xHqqkZx_3_xZkqqHx_iBeC_xHqqkZx_
 *			_xZkqqHx_jCmKiPoNiCmMjDpMjHmNiCmFiCmNiBeBiNhDiCmMjBhNjDpMiCmNiNhD_xHqqkZx_3->_xZkqqHx_iNhD_xHqqkZx_5_xZkqqHx_iCmJiMpMiCkJiCmBiCmEiNhDiCoNiCoKiCoJiCkKiBeB_xHqqkZx_
 *			_xZkqqHx_iNhD_xHqqkZx_5->_xZkqqHx_iNhD_xHqqkZx_3_xZkqqHx_iCmMjFpLiMpMiCmJiNoNiPjMiClHiCoJiCmGiNhD_xHqqkZx_5_xZkqqHx_iCmMjBhNjDpMiCmGiNhD_xHqqkZx_5_xZkqqHx_iCmMiNoNiPjMiCkKjHnHjAnKiClHiCoJ_xHqqkZx_
 *			_xZkqqHx_iCmMiCmFiNmFjDeLiJlLiClFiCoCiClHiCkCiCmNiClIiBeC_xHqqkZx_
 *			_xZkqqHx_iNhDiCmMiNoNiPjMiCmNiBeBiNhDiCmMjFlGiOjKjHpBiCpAjBfDiCmEiNoNiPjMiClFiClNiCmMiClPiBeBiLpDiCmJiCmIiCmBiClNiNhDiCpAiNoNiPjMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//void CFCWndRichEdit::MCmdDeleteLines (long lIdxFrom, long lSize)
long CFCWndRichEdit::MCmdDeleteLines (long lIdxFrom, long lSize)
{
	long lLineFrom;
	long lChar;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lLineFrom, lChar, lIdxFrom);
	ASSERT(lChar == 0);
	// _xZkqqHx_iNoNiPjMiClHiCoJiNhDiCpAiLeMjIfOiBeC_xHqqkZx_
	for (long lLine = lLineFrom + lSize - 1; lLineFrom <= lLine; lLine--)
	{
		// _xZkqqHx_iNhDiCmMiJpMiNhDiImIiKePiCmMjFlGiOjKjAjEiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
		long lCharCount = m_vEditLine[lLine].m_vEditChar.size() - 1;
		// _xZkqqHx_iNhDjAoGjDkKiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOfKiPgPiBeC_xHqqkZx_
		long lCharIndex = CharPosToIndex(lLine, 0);
		// _xZkqqHx_iJpMiNhDiImIiKePiCmJjFlGiOjKiCkKiCkAiCoJiPoKiNiHiCmNiBeBjFlGiOjKiCpAjBfDiCmEiNoNiPjMiBeC_xHqqkZx_
		if (lCharCount != 0)
			CmdReplaceChars(lCharIndex, lCharCount, NULL, 0);
		// _xZkqqHx_iLpDiCmJiCmIiCmBiClNiNhDiCpAiNoNiPjMiBeC_xHqqkZx_
		CmdDeleteThinLine(lCharIndex);
	}
	return lLineFrom;
} // CFCWndRichEdit::MCmdDeleteLines.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::MCmdInsertLine
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iCfAiNhDiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lIdxTo	:_xZkqqHx_jBhNjDpMiImKjChFiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiOhHjCoIiBeC_xHqqkZx_
 *			eLine	:_xZkqqHx_jBhNjDpMiClHiCoJiNhDiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiOjOiCmNiBeB_xHqqkZx_lIdxTo_xZkqqHx_iCkKjBkOiClHiCoJiNhDiCmNiMhAjBlBiNhDiCkK_xHqqkZx_
 *			_xZkqqHx_jIeBiMiLiClDiCoKiCmEiCkCiCmIiCkPiCoKiCmOiCmIiCoHiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	_xZkqqHx_iNhDiCmMjBhNjDpMiCmNiBeBiLpDiCmMiNhDiCpAjBhNjDpMiClFiClNiMoDiBeBiNhDiCmJjFlGiOjKjHpBiCpAjBhNjDpMiClHiCoJiBeC_xHqqkZx_
 *
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.02.19 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//void CFCWndRichEdit::MCmdInsertLine (long lIdxTo, const FCEditLine& eLine)
long CFCWndRichEdit::MCmdInsertLine (long lIdxTo, const FCEditLine& eLine)
{
	// eLine _xZkqqHx_iCmMiDhGiDiNiDhAiDgFiDeCiCmGiJpMiNhDiCmMiCnNiCmMiNhDiCpAjHhAiInDiBeC_xHqqkZx_
	FCEditLine el;
	el.CopyProperty(eLine);
	el.m_vEditChar.push_back(eLine.m_vEditChar.back());
	// _xZkqqHx_iLpDiCmMiNhDiCpAjBhNjDpMiBeC_xHqqkZx_
	long lLine = CmdInsertThinLine(lIdxTo, el);
	// _xZkqqHx_iNhDiCmJjFlGiOjKjHpBiCpAjBhNjDpMiBeCiBgJiNmFiMoDiCmMiJpMiNhDiCmNjBhNjDpMiClFiCmIiCkCiBgK_xHqqkZx_
	if (eLine.m_vEditChar.size() != 1)
		CmdReplaceChars(lIdxTo, 0, &eLine.m_vEditChar[0], eLine.m_vEditChar.size() - 1);
	return lLine;
} // CFCWndRichEdit::MCmdInsertLine.

/////////////////////////////////////////////////////////////////////////////
// CFCWndRichEdit _xZkqqHx_iDiBiDgCiDfKiBfLiDfH_xHqqkZx_ _xZkqqHx_iDgOiDjDiDgIiDiJ_xHqqkZx_

//----- 05.06.03 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::PreTranslateMessage
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iKgFiOoNiDiBiDgCiDfKiBfLiDfHiCpAiPiIjHjNiClHiCoJiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pMsg	: _xZkqqHx_iDiBiDgCiDfKiBfLiDfH_xHqqkZx_
// *************************************************************************/
//BOOL CFCWndRichEdit::PreTranslateMessage (MSG* pMsg)
//{
//	if (pMsg->message == WM_KEYDOWN)
//	{
//		switch (pMsg->wParam)
//		{
//		case VK_ESCAPE:
//			if (m_fncCallback != NULL)
//			{
//				(*m_fncCallback)(VK_ESCAPE);
//				// _xZkqqHx_jBlMiCmMiDeFiDeCiDjDiDgIiDeFiCmJiDiBiDgCiDfKiBfLiDfHiCkKiNhDiCkJiCmIiCkCiCoGiCkEiCmJ_xHqqkZx_.
//				return TRUE;
//			}
//			break;
//
//		case VK_DELETE:
//			TRACE(_T("EDIT DELETE\n"));
//			OnDelete();
//			// _xZkqqHx_jBlMiCmMiDeFiDeCiDjDiDgIiDeFiCmJiDiBiDgCiDfKiBfLiDfHiCkKiNhDiCkJiCmIiCkCiCoGiCkEiCmJ_xHqqkZx_.
//			return TRUE;
//		}
//	}
//	
//	return CWnd::PreTranslateMessage(pMsg);
//} // CFCWndRichEdit::PreTranslateMessage.
//----- 05.06.03 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnCreate
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	Create_xZkqqHx_jClMiMoDiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	lpCreateStruct
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	
 *************************************************************************/
int CFCWndRichEdit::OnCreate (LPCREATESTRUCT lpCreateStruct)
{
	TRACE(_T("OnCreate\n"));
	if (CWnd::OnCreate(lpCreateStruct) == -1)
		return -1;
	
	/*----- _xZkqqHx_iDfCiDhDiBfL_xHqqkZx_&_xZkqqHx_iDhJiBfLiDfIiDgHiDiPiBfLiDeOjHhAiCmM_xHqqkZx_RichEditCtrl_xZkqqHx_iCpAiNoMjAkM_xHqqkZx_ -----*/
	if (m_nEditCtrlCount == 0)
	{
		m_richpEditCtrl = new FCRichEditBuffer();
	}
	m_nEditCtrlCount++;

	/*----- _xZkqqHx_iNmFiPiJiCmMiCfAiNhDiCpAjAlGjAkMiClHiCoJ_xHqqkZx_ -----*/
	m_lCurIndex = 0;
	m_mmCaretX = 0.0;
	m_lSelFrom	= -1;
	m_lSelTo	= -1;
	m_vEditLine.push_back(FCEditLine());

	/*----- _xZkqqHx_iNmFiPiJiCmMiCfAiNhDiCmMiNmFiPiJiCmMiCfAjFlGiOjKiBgJiJpMiNhDiBgKiCpAjAlGjAkMiClHiCoJ_xHqqkZx_ -----*/
//----- 01.02.13 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	m_vEditLine[0].m_vEditChar.push_back(
//					FCEditChar(FDRCH_RETURN, 0, 0.0, 0, FD_S_COLOR_BLACK,
//					FDWR_RETURN_WIDTH, 0.0, 0.0, 0.0));
//----- 01.02.13 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	m_vEditLine[0].m_vEditChar.push_back(
					FCEditChar(FDRCH_RETURN, FD_S_FONT_STANDARD, 0.0, 0, FD_COLREF_BLACK, 0, 0,
					FDWR_RETURN_WIDTH, 0.0, 0.0, 0.0, FDWR_CROSS_INSIDE));
//----- 01.02.13 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----

	// _xZkqqHx_iDhNiDfIiDeOiDgGiBfLiDfOiCpAiPmBiLiO_xHqqkZx_.
	m_vmmptPoly.clear();
// 02.05.30 Fukushiro M. 1_xZkqqHx_iNhDiNoNiPjM_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)
//	m_vlgptPoly.clear();

	// _xZkqqHx_iNmEjFgAiJoGiOjOiCmJiPmBiLiOiClHiCoJjHmMiIoGiBeC_xHqqkZx_
// 00.08.06 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	m_vnrClearRgn.clear();
	m_nrtClearRgn.Empty();

	//-----_xZkqqHx_jEhHiMgJjFgAiJoGjHhAiDhJiDjDiBeFiDhFiDiJiDfGiCpAiDeOiDiKiDeB_xHqqkZx_ -----
	m_psidPenStyle			= FD_PEN_STYLE_UNUSE;
	m_mmfPenWeight			= 0.0;
	m_scidPenBackSColor		= FD_S_COLOR_TRANSPARENT;
	m_scidBrushBackSColor	= FD_S_COLOR_TRANSPARENT;
//----- 06.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iDeHiDgGiDeCiDfOjEhHiMgJjAeGiCpAjAnNjCoIiBeC_xHqqkZx_
	m_crBackground = g_pReg->GetOptiSheetColor();
//----- 06.03.25 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----

	m_bIsBtnDown = FALSE;		// _xZkqqHx_iDhNiDeFiDfIiDhLiDfOiDjDiCmMiPpDjBnE_xHqqkZx_.
	m_lDblClkInterval = 500;	// _xZkqqHx_iDfPiDhFiDiLiDeOiDiKiDgCiDeOiCmMiKnEiKhFiCpA_xHqqkZx_500msec_xZkqqHx_iCmJ_xHqqkZx_.
	m_clkLBtnDown = 0;			// _xZkqqHx_iDfPiDhFiDiLiDeOiDiKiDgCiDeOiCmMiOjOiKnE_xHqqkZx_.
	m_iClickCount = 0;			// _xZkqqHx_jIeBjBlBiDeOiDiKiDgCiDeOiCmMiDeKiDeFiDjDiDfO_xHqqkZx_.
// 05.11.24 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ ()
	m_lgIndentLine = LONG_MAX;	// _xZkqqHx_iDeLiDeDiDgIjApMiCmMiNmAjFfHiCpAiDeOiDiKiDeBiBeC_xHqqkZx_

	m_mmMarginL = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiNlGiDhNiBfLiDfHiDjD_xHqqkZx_.
	m_mmMarginT = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiPoDiDhNiBfLiDfHiDjD_xHqqkZx_.
	m_mmMarginR = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJeFiDhNiBfLiDfHiDjD_xHqqkZx_.
	m_mmMarginB = 0.0;	// _xZkqqHx_iDgFiDeMiDfIiDgHjHmMiIoGiCmMiJlKiDhNiBfLiDfHiDjD_xHqqkZx_.

	m_byVertAlign = FDRC_AL_TOP;	// _xZkqqHx_jAiCjClMjFpLiMpMiCmMiDeBiDiJiDeDiDjDiDiBiDjDiDgHiBeC_xHqqkZx_

//----- 98.10.15 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	/*-----_xZkqqHx_iBkLiIoKiOjOjDeJ_xHqqkZx_ -----*/
//	BOOL bIsPaste = m_richpEditCtrl->CanPaste(g_cfRTF);
//	CString	str;
//	str.Format("IsPaste RTF %d\n", bIsPaste);
//	MessageBox(str);
//
//	bIsPaste = m_richpEditCtrl->CanPaste(CF_TEXT);
//	str.Format("IsPaste TEXT %d\n", bIsPaste);
//	MessageBox(str);
//
//	str.Format("1.4999 = %d\n", static_cast<__int64>(1.4999));
//	MessageBox(str);
//	str.Format("1.5001 = %d\n", static_cast<__int64>(1.5001));
//	MessageBox(str);
//	str.Format("-1.4999 = %d\n", static_cast<__int64>(-1.4999));
//	MessageBox(str);
//	str.Format("-1.5001 = %d\n", static_cast<__int64>(-1.5001));
//	MessageBox(str);
//
//	/*-----_xZkqqHx_iBkKiIoKiOjOjDeJ_xHqqkZx_ -----*/
//----- 98.10.15 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----

#if defined(_IME_ON)
	/*----- IME_xZkqqHx_iCpAiKgNjFnL_xHqqkZx_&_xZkqqHx_iKiEjFhEiCkP_xHqqkZx_ -----*/
    HIMC hIMC = ImmCreateContext();
	ImmAssociateContext(m_hWnd, hIMC);
#endif // defined(_IME_ON)

	return 0;
} // CFCWndRichEdit::OnCreate.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnDestroy
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	DestroyWindow_xZkqqHx_jClMiMoDiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnDestroy ()
{
	TRACE(_T("OnDestroy\n"));
	CWnd::OnDestroy();

#if defined(_IME_ON)
	/*----- IME_xZkqqHx_iCpAiJpAjFpK_xHqqkZx_ -----*/
	HIMC hIMC = ImmGetContext(m_hWnd);
	ImmDestroyContext(hIMC);
#endif // defined(_IME_ON)

	m_nEditCtrlCount--;
	if (m_nEditCtrlCount == 0)
	{
		delete m_richpEditCtrl;
		m_richpEditCtrl = NULL;	// static_xZkqqHx_jFmPjAjEiClOiCkJiCoHiPiJiKpKiJlLjFeLjAhL_xHqqkZx_.
	}
} // CFCWndRichEdit::OnDestroy.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnPaint
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNmEjFgAiJoGiOjOiCmJiMmEiCmOiCoKiCoJiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnPaint ()
{
	CPaintDC dc(this);		// _xZkqqHx_jFgAiJoGjHhAiCmMiDgGiDgPiDeDiDfI_xHqqkZx_ _xZkqqHx_iDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
	// _xZkqqHx_iNmEjFgAiJoGiOjOiCmMiNfIjAfGjHmMiIoGiCmJiBeBjBfDjHmMiIoGiCpAiOhHjCoIiBeC_xHqqkZx_
	m_nrtClearRgn.SetRect(0, 0, mm2lg(m_mmrtWindow.Width()),
								mm2lg(m_mmrtWindow.Height()));
	// _xZkqqHx_iNfIjAfGjHmMiIoGiCpAjEhHiMgJiCmFjDgIjCnHiClFiBeBjFlGiOjKiCmMjHmMiIoGiCpAiNmEiMhGiOfKiClHiCoJiBeC_xHqqkZx_
	FillBackAndMarkUpdate(&dc);
	// _xZkqqHx_iNfIjAfGiClDiCoKiClNjHmMiIoGiCmMiCnNiNmEjFgAiJoGiBeC_xHqqkZx_
	RedrawUpdate(&dc);
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect(&dc);

	// _xZkqqHx_iDeLiDeDiDgIjApMiCkKjAnNjCoIiClDiCoKiCmEiCkCiCoJiPoKiNiHiCmNjFgAiJoGiBeC_xHqqkZx_
	if (m_lgIndentLine != LONG_MAX)
	//----- _xZkqqHx_iDeLiDeDiDgIjApMiCkKjAnNjCoIiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
	{
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//		COLORREF crBack;
//		if (m_scidBrushBackSColor == FD_S_COLOR_TRANSPARENT)
//			crBack = ::g_pReg->GetOptiSheetColor();
//		else
//			crBack = ::OptiColor(g_pEnv->scid2cref(m_scidBrushBackSColor));
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
		FCEditDraw eDraw(&dc, 0, g_pReg->GetOptiRegColor(FDCL_EDIT_LINE) ^ m_crBackground, -1, 0, 0);
		eDraw.Line(	&CPoint(m_lgIndentLine, 0),
					&CPoint(m_lgIndentLine, mm2lg(m_mmrtWindow.Height())));
	}
} // CFCWndRichEdit::OnPaint.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnSetFocus
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhEiDeIiBfLiDeKiDfIiCpAjDlOiCoJiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pOldWnd	: _xZkqqHx_iDhEiDeIiBfLiDeKiDfIiCpAiOlIiCkEiDeFiDeCiDjDiDgIiDeF_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnSetFocus (CWnd* pOldWnd)
{
	CWnd::OnSetFocus(pOldWnd);
	
	//----- _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiNoMjAkMiClHiCoJ_xHqqkZx_ -----
	mmetol	mmX, mmY, mmH;
	CalcCaret(mmX, mmY, mmH);
	CreateSolidCaret(2, mm2lg(mmH));
	SetCaretPos(CPoint(mm2lg(mmX), mm2lg(mmY)));
	ShowCaret();

	m_clkLBtnDown = 0;	// _xZkqqHx_iDfPiDhFiDiLiDeOiDiKiDgCiDeOiCmMiOjOiKnE_xHqqkZx_.
	m_iClickCount = 0;	// _xZkqqHx_jIeBjBlBiDeOiDiKiDgCiDeOiCmMiDeKiDeFiDjDiDfO_xHqqkZx_.

	//----- _xZkqqHx_iDfCiDjDiDhAiDgMiCkJiCoHiDfPiDhFiDiLiDeOiDiKiDgCiDeOiCmMiKnEiKhFiCpAiPeFiCkE_xHqqkZx_ -----
	HKEY hKey;
	if (RegOpenKeyEx(HKEY_CURRENT_USER,  _T("Control Panel\\Mouse"),
					0, KEY_QUERY_VALUE, &hKey) == ERROR_SUCCESS)
	{
		TCHAR szData[128];
		DWORD dwKeyDataType;
// 02.02.08 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//		DWORD dwDataBufSize = sizeof(szData) / sizeof(szData[0]);
		DWORD dwDataBufSize = sizeof(szData);
		if (RegQueryValueEx(hKey, _T("DoubleClickSpeed"), NULL,
			&dwKeyDataType, (LPBYTE)&szData, &dwDataBufSize) == ERROR_SUCCESS)
		{
			m_lDblClkInterval = _tcstoul(szData, NULL, 10);
		}
		RegCloseKey(hKey);
	}
} // CFCWndRichEdit::OnSetFocus.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnKillFocus
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhEiDeIiBfLiDeKiDfIiCpAiOlIiCmBiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pNewWnd	: _xZkqqHx_iOjPiCmJiDhEiDeIiBfLiDeKiDfIiCpAjDlOiCoJiDeFiDeCiDjDiDgIiDeF_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnKillFocus (CWnd* pNewWnd)
{
	CWnd::OnKillFocus(pNewWnd);
	
	TRACE(_T("OnKillFocus\n"));

	// _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiPmBiLiOiClHiCoJ_xHqqkZx_.
	HideCaret();
	::DestroyCaret();
	TRACE(_T("HideCaret\n"));
	
} // CFCWndRichEdit::OnKillFocus.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnLButtonDown
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNlGiDhLiDfOiDjDiCpAiJjPiClDiCoKiClNiOjOiCmJiOmAiNhDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nFlags	:_xZkqqHx_jDkPiOjOiCmJiJjPiClDiCoKiClNiDeMiBfLiCmMiPoOjFpBiBeC_xHqqkZx_
 *			point	:_xZkqqHx_iDhNiDeFiDfIiNmAjFfHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.01.28 Fukushiro M. _xZkqqHx_iNhDjBeJjBpAiOjOiCmMiDeKiBfLiDfMiDiLiImKjChFiCpAiNmFiMoDiCmJiClHiCoJiBeC_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnLButtonDown (UINT nFlags, CPoint point)
{
	TRACE(_T("OnLButtonDown\n"));
//----- 06.04.13 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
	// _xZkqqHx_iCoAiClFiDhLiDfOiDjDiCkKiJjPiClDiCoKiClNiPpDjBnEiCmFiMmEiCmOiCoKiClNiCoHiDeHiDiJiBfLiBeC_xHqqkZx_
	if (m_bIsBtnDown)
		FFThrowMiscUnknown();
//----- 06.04.13 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
//----- 02.05.30 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
	// _xZkqqHx_iDfJiBfLiDiAjDjJiCmFiOgHiCkEiClNiCnPiBeBiDhNiDeFiDfIiNmAjFfHiCpAiDhCiDiFiBfLiCmJiLeMjIfOiBeC_xHqqkZx_
	g_pView->SetLastPoint(lg2mm(point) + DBLPoint(m_mmrtWindow.left, m_mmrtWindow.top));
//----- 02.05.30 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)-----
	::FFSetCapture(m_hWnd);	// OnLButtonUp_xZkqqHx_iCnMiCmFiClBiCmM_xHqqkZx_Window_xZkqqHx_iCmJiDeDiDhIiDjDiDgHiBeC_xHqqkZx_
	m_bIsBtnDown = TRUE;	// _xZkqqHx_iDhNiDeFiDfIiDhLiDfOiDjDiCmMiPpDjBnEiBeC_xHqqkZx_

	// _xZkqqHx_iDhGiDiNiDfKiDfIiLeOjDkOiOjOiCkJiCoHiCmMiMgPiJnPiOjOiKnE_xHqqkZx_.
	clock_t	clkDblClicked = ::clock() * (1000.0 / CLOCKS_PER_SEC);
	long	lMSecAfter = static_cast<long>(clkDblClicked - m_clkLBtnDown);

	if (0 <= lMSecAfter && lMSecAfter <= m_lDblClkInterval)
	//----- _xZkqqHx_iMgPiJnPiOjOiKnEiCkKiLeLjCoIiOjOiKnEiImIjDoAiBeBjBkGiClPjIeBjBlBiDeOiDiKiDgCiDeOiCmMiPoKiNiH_xHqqkZx_ -----
	{
		// _xZkqqHx_iMlLiNnNiCmMiNhDiBeFjHpBiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
		long lCurLine;
		long lCurChar;
		GetCurCharPos(lCurLine, lCurChar);

		long lSelFrom;
		long lSelTo;

		m_iClickCount++;
		if (m_iClickCount == 2)		// _xZkqqHx_iDfPiDhFiDiLiDeOiDiKiDgCiDeOiBeC_xHqqkZx_
		{
			// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBjCfAiMoKiLkLiKeFiCnGiCmMiDeJiDhEiDfKiDgCiDgHiCpAiLiBiCnPiCoJ_xHqqkZx_.
			lSelFrom = m_lCurIndex + GetPrevBoundary(lCurLine, lCurChar);
			lSelTo = m_lCurIndex + GetNextBoundary(lCurLine, lCurChar);
			if (GetIndexSize() < lSelTo) lSelTo = GetIndexSize();

		} else if (m_iClickCount == 3)	// _xZkqqHx_iDgHiDiKiDhGiDiLiDeOiDiKiDgCiDeOiBeC_xHqqkZx_
		{
			long lLineFrom = lCurLine;
			long lLineTo = lCurLine;
			/*----- _xZkqqHx_iMhAjBlBiNhDiCmMiPoKiNiHiBeBjAoGjDkKiCmMiNhDiCnMiCmFiImKjChFiCpAjGnPiClH_xHqqkZx_ -----*/
			while (m_vEditLine[lLineFrom].m_byLineType == FDRC_LT_CONTINUE)
				lLineFrom--;
			/*----- _xZkqqHx_iMhAjBlBiNhDiCmMiPoKiNiHiBeBiNmFiMoDiCmMiNhDiCnMiCmFiImKjChFiCpAjGnPiClH_xHqqkZx_ -----*/
			while (m_vEditLine[lLineTo].m_vEditChar.back().m_wChar == FDRCH_CONTINUE)
				lLineTo++;

			lSelFrom = CharPosToIndex(lLineFrom, 0L);
			if (lLineTo + 1 < m_vEditLine.size())
				lSelTo = CharPosToIndex(lLineTo + 1, 0L);
			else
				lSelTo = GetIndexSize();

		} else if (m_iClickCount == 4)	// 4_xZkqqHx_iJpBiDeOiDiKiDgCiDeO_xHqqkZx_.
		{
			lSelFrom = 0;
			lSelTo = GetIndexSize();
		} else
		{
			m_iClickCount = 0;
			// _xZkqqHx_jBeJjBpAiCpAiJpAiPjM_xHqqkZx_.
			lSelFrom = -1;
			lSelTo = -1;
		}
		// _xZkqqHx_iNhDiLkLiKeFiCmMiKnEiCpAjBeJjBpAiPpDjBnEiCmJiClHiCoJiBeC_xHqqkZx_
		SetSelect(lSelFrom, lSelTo);
		if (0 <= lSelTo)
		{
			// _xZkqqHx_iMlLiNnNiCmMiDeDiDjDiDgGiDgCiDeOiDfIiCpAiInKjDkOiBeC_xHqqkZx_
			m_lCurIndex = lSelTo;
			m_mmCaretX = RepositionCaret();
			// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
			ResetCurFormat();
		}
		// _xZkqqHx_iDhGiDiNiDfKiDfIiLeOjDkOiOjOiCkJiCoHiCmMiMgPiJnPiOjOiKnEiBeC_xHqqkZx_
		m_clkLBtnDown = clkDblClicked;
	} else
	{
		m_iClickCount = 0;
	}

	if (m_iClickCount == 0)
	{
		// _xZkqqHx_iDhGiDiNiDfKiDfIiLeOjDkOiOjOiCkJiCoHiCmMiMgPiJnPiOjOiKnEiBeC_xHqqkZx_
		m_clkLBtnDown = clkDblClicked;
		// _xZkqqHx_iDeOiDiKiDgCiDeOiDeKiDeFiDjDiDfOiCmJiCfAiCpAjAnNjCoIiBeC_xHqqkZx_
		m_iClickCount = 1;

		DBLPoint mmpt = lg2mm(point);
		// _xZkqqHx_iDfGiDhEiDgHiDeMiBfLiCmMiPoKiNiHiCmJjEpFiCkGiCmEiBeB_xHqqkZx_m_lCurIndex_xZkqqHx_jFmPiNfIjBePiCmJiLeMjIfOiClFiCmEiCkIiCkNiBeC_xHqqkZx_
		long lSelFrom = (0 <= m_lSelFrom) ? m_lSelFrom : m_lCurIndex;
		// Y_xZkqqHx_iNmAjFfHiCkJiCoHiNhDiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
		long lCurLine = CoordToLine(mmpt.y);
		if (lCurLine < 0)
		// _xZkqqHx_iChIiNmAjFfHiCkKiCePiNhDiCoGiCoIiCoAiPoDiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		{
			m_lCurIndex = 0;
		} else if (m_vEditLine.size() <= lCurLine)
		// _xZkqqHx_iChIiNmAjFfHiCkKiNmFjBoFiNhDiCoGiCoIiCoAiJlKiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		{
			m_lCurIndex = GetIndexSize();
		} else
		// _xZkqqHx_iChIiNmAjFfHiCkKiCePiNhDiCmGiNmFjBoFiNhDiCmMiKnEiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		{
			m_lCurIndex = CharPosToIndex(lCurLine, CoordToGapX(lCurLine, mmpt.x));
		}
		// _xZkqqHx_iDeKiDiMiDgCiDgHiCmM_xHqqkZx_X_xZkqqHx_iNmAjFfHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
		m_mmCaretX = RepositionCaret();
		// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
		ResetCurFormat();
		if (nFlags & MK_SHIFT)
		//----- SHIFT_xZkqqHx_iDeMiBfLiCkKjDkPiOjOiCmJiJjPiClDiCoKiCmEiCkCiClNiPoKiNiH_xHqqkZx_ -----
		{
			if (lSelFrom != m_lCurIndex)
				SetSelect(lSelFrom, m_lCurIndex);
			else
				SetSelect(-1, -1);
		} else
		{
			SetSelect(-1, -1);
		}
	}

	CWnd::OnLButtonDown(nFlags, point);
} // CFCWndRichEdit::OnLButtonDown.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnLButtonUp
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iNlGiDhLiDfOiDjDiCpAjHkDiClFiClNiCmGiCkLiCmJiOmAiNhDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nFlags	:_xZkqqHx_jDkPiOjOiCmJiJjPiClDiCoKiClNiDeMiBfLiCmMiPoOjFpB_xHqqkZx_.
 *			point	:_xZkqqHx_iDhNiDeFiDfIiNmAjFfH_xHqqkZx_.
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnLButtonUp (UINT nFlags, CPoint point)
{
	TRACE(_T("OnLButtonUp\n"));
	// _xZkqqHx_iDfPiDhFiDiLiDeOiDiKiDgCiDeOiCmIiCmHiBeB_xHqqkZx_LButtonDown_xZkqqHx_iCkKiMmEiCmOiCoKiClIiCmJ_xHqqkZx_LButtonUp_xZkqqHx_iCmMiCnN_xHqqkZx_
	// _xZkqqHx_iMmEiCmOiCoKiCoJiPoKiNiHiCkKiCkAiCoJiClNiCnPiBeBjFeLiClI_xHqqkZx_m_bIsBtnDown_xZkqqHx_iCpAiDgAiDeGiDgCiDeOiClHiCoJiBeC_xHqqkZx_
// 06.04.13 Fukushiro M. 1_xZkqqHx_iNhDjCmHiJmB_xHqqkZx_ ()
	if (m_bIsBtnDown)
	//----- _xZkqqHx_iDhNiDeFiDfIiDhLiDfOiDjDiCmMiPpDjBnE_xHqqkZx_ -----
	{
		::FFReleaseCapture();	// LButtonDown_xZkqqHx_iCmJiCoGiCmBiCmEiOgOiCnMiCmBiClNiDhNiDeFiDfIiCmM_xHqqkZx_
								// _xZkqqHx_jFnPiKgMiCpAiJpAiPjMiClFiCnMiClHiBeC_xHqqkZx_
		m_bIsBtnDown = FALSE;	// _xZkqqHx_iDhNiDeFiDfIiDhLiDfOiDjDiCmMiPpDjBnE_xHqqkZx_.
	}
	CWnd::OnLButtonUp(nFlags, point);
} // CFCWndRichEdit::OnLButtonUp.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnMouseMove
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhNiDeFiDfIiCpAiInKjDkOiClFiClNiCmGiCkLiCmJiOmAiNhDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nFlags	:_xZkqqHx_jDkPiOjOiCmJiJjPiClDiCoKiClNiDeMiBfLiCmMiPoOjFpB_xHqqkZx_.
 *			point	:_xZkqqHx_iDhNiDeFiDfIiNmAjFfH_xHqqkZx_.
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.11.02 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnMouseMove (UINT nFlags, CPoint point)
{
	if (m_bIsBtnDown && m_iClickCount == 1)
	//----- _xZkqqHx_iDfGiDjDiDePiDiLiDeOiDiKiDgCiDeOiMoDiCmMiDhNiDeFiDfIiInKjDkO_xHqqkZx_ -----
	{
		DBLPoint mmpt = lg2mm(point);
		// m_lCurIndex_xZkqqHx_jFmPiNfIjBePiCmJiLeMjIfOiClFiCmEiCkIiCkNiBeC_xHqqkZx_
		long lSelFrom = (0 <= m_lSelFrom) ? m_lSelFrom : m_lCurIndex;
		// Y_xZkqqHx_iNmAjFfHiCkJiCoHiNhDiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
		long lCurLine = CoordToLine(mmpt.y);
		if (lCurLine < 0)
		// _xZkqqHx_iChIiNmAjFfHiCkKiCePiNhDiCoGiCoIiCoAiPoDiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		{
			m_lCurIndex = 0;
		} else if (m_vEditLine.size() <= lCurLine)
		// _xZkqqHx_iChIiNmAjFfHiCkKiNmFjBoFiNhDiCoGiCoIiCoAiJlKiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		{
			m_lCurIndex = GetIndexSize();
		} else
		// _xZkqqHx_iChIiNmAjFfHiCkKiCePiNhDiCmGiNmFjBoFiNhDiCmMiKnEiCmJiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		{
			m_lCurIndex = CharPosToIndex(lCurLine, CoordToGapX(lCurLine, mmpt.x));
		}
		// _xZkqqHx_iDeKiDiMiDgCiDgHiCmM_xHqqkZx_X_xZkqqHx_iNmAjFfHiCpAiNmEiMhGiOfKiBeC_xHqqkZx_
		m_mmCaretX = RepositionCaret();
		// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
		ResetCurFormat();
		if (lSelFrom != m_lCurIndex)
			SetSelect(lSelFrom, m_lCurIndex);
		else
			SetSelect(-1, -1);
	}

	CWnd::OnMouseMove(nFlags, point);
} // CFCWndRichEdit::OnMouseMove.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnGetDlgCode
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iClBiCmMiDeFiDeCiDjDiDgIiDeFiCmFiPiIjHjNiCmFiCkLiCoJiDeMiBfLiCpAjAnNjCoIiClHiCoJiBeCiDeMiBfLiCkKiJjPiClDiCoKiCoJjDhIiCmJ_xHqqkZx_
 *			_xZkqqHx_iClBiCmMiKnGjAjEiCkKiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_CDialog_xZkqqHx_iCmMiOhBiDeFiDeCiDjDiDgIiDeFiCmGiClFiCmEjDgPjIfOiClFiClNiOjOiCmJ_xHqqkZx_
 *			_xZkqqHx_jHeMiMpIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iClBiCmMiDeFiDeCiDjDiDgIiDeFiCmFiPiIjHjNiCmFiCkLiCoJiDeMiBfL_xHqqkZx_.
 *************************************************************************/
UINT CFCWndRichEdit::OnGetDlgCode ()
{
	// _xZkqqHx_jFpLiMpMiDeMiBfLiCpAiPiIjHjNiClHiCoJiCoGiCkEiCmJjFmPiNfIiBeC_xHqqkZx_
		return DLGC_WANTALLKEYS | CWnd::OnGetDlgCode();
} // CFCWndRichEdit::OnGetDlgCode.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnKeyDown
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDeMiBfLiCkKiJjPiClDiCoKiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nChar	:_xZkqqHx_iOhHjCoIiClDiCoKiClNiDeMiBfLiCmMiJlMjBhKiDeMiBfLiDfCiBfLiDgIiCpAiOhHjCoIiClFiCnMiClHiBeC_xHqqkZx_
 *			nRepCnt	:_xZkqqHx_iDiKiDhDiBfLiDgHiDeKiDeFiDjDiDgH_xHqqkZx_(_xZkqqHx_iDiGiBfLiDfFiBfLiCkKiDeMiBfLiCpAiJjPiClFjBlBiCkPiClNiCmGiCkLiCmJ_xHqqkZx_
 *					 _xZkqqHx_iMeKiCoIjFnEiClHiDeMiBfLjBiAiNoMiCmMiJpBjAjE_xHqqkZx_) _xZkqqHx_iCpAiOhHjCoIiClFiCnMiClHiBeC_xHqqkZx_
 *			nFlags	:_xZkqqHx_iDfIiDeMiDiDiDjDiDfCiBfLiDgIiBeBiDeMiBfLjFmPiKlHiDfCiBfLiDgIiBeBjClMjBePiCmMiDeMiBfLiPpDjBnEiBeB_xHqqkZx_
 *					 _xZkqqHx_iCkIiCoGiCnBiDfCiDjDiDgFiDeMiDfIiDgH_xHqqkZx_ _xZkqqHx_iDfCiBfLiDgIiCpAiOhHjCoIiClFiCnMiClHiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	OnGetDlgCode()_xZkqqHx_iCmFiBeBjGoOiIpDiDeMiBfLiCpAjHeMiMpIiCmJiClFiCmEiCkAiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.22 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHjCmHiJmB_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnKeyDown (UINT nChar, UINT nRepCnt, UINT nFlags)
{
	long lCurLine, lCurChar;
	GetCurCharPos(lCurLine, lCurChar);

	long lSelFrom, lSelTo;
	if (m_lSelFrom < 0)
		lSelFrom = m_lCurIndex;
	else
		lSelFrom = m_lSelFrom;

	switch (nChar)
	{
	case VK_LEFT:	// _xZkqqHx_iNlGjGoOiIpDiCmMiPoKiNiHiBeC_xHqqkZx_
		if (0 < m_lCurIndex)
		{
			if (GetKeyState(VK_CONTROL) < 0)
			//----- CONTROL_xZkqqHx_iDeMiBfLiCkKjDkPiOjOiCmJiJjPiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
			{
				// _xZkqqHx_iMlLiNnNiImKjChFiCkJiCoHiBeBiIoKiCmCjBePiCmMjCfAiMoKiLkLiKeFiCnGiCmMiDeJiDhEiDfKiDgCiDgHiCpAiOfKiPgPiBeC_xHqqkZx_
				long lCharOffset = GetPrevBoundary(lCurLine, lCurChar);
				// GetPrevBoundary_xZkqqHx_iCmNiBeBiMlLiNnNiImKjChFiCkKjCfAiMoKiLkLiKeFiCmMiPoKiNiHiCmNiCePiCpAjFnEiClHiBeC_xHqqkZx_
				if (lCharOffset == 0)
				//----- _xZkqqHx_iMlLiNnNiImKjChFiCkKjCfAiMoKiLkLiKeFiCmMiPoKiNiH_xHqqkZx_ -----
				{
					// _xZkqqHx_iCfAjFlGiOjKjBePiCmMiImKjChFiCpAiOoGjDlOiBeC_xHqqkZx_
					long lCurLinePrev, lCurCharPrev;
					IndexToCharPos(lCurLinePrev, lCurCharPrev, m_lCurIndex - 1);
					// _xZkqqHx_iCfAjFlGiOjKjBePiCmMiImKjChFiCkJiCoHiBeBiIoKiCmCjBePiCmMjCfAiMoKiLkLiKeFiCnGiCmMiDeJiDhEiDfKiDgCiDgHiCpAiOfKiPgPiBeC_xHqqkZx_
					lCharOffset = GetPrevBoundary(lCurLinePrev, lCurCharPrev) - 1;
				}
				// _xZkqqHx_iCnAiCmGiCmCjBePiCmMjCfAiMoKiLkLiKeFiCnMiCmFiInKjDkOiBeC_xHqqkZx_
				m_lCurIndex += lCharOffset;
			} else
			//----- CONTROL_xZkqqHx_iDeMiBfLiCkKjDkPiOjOiCmJiJjPiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiH_xHqqkZx_ -----
			{
				m_lCurIndex--;
			}
		}
		break;
	case VK_UP:		// _xZkqqHx_iPoDjGoOiIpDiCmMiPoKiNiHiBeC_xHqqkZx_
		if (0 < lCurLine)
		{
			lCurLine--;
			long lGapX = CoordToGapX(lCurLine, m_mmCaretX);
			if (m_vEditLine[lCurLine].m_vEditChar[lGapX].m_wChar == FDRCH_CONTINUE)
				lGapX--;
			m_lCurIndex = CharPosToIndex(lCurLine, lGapX);
		}
		break;
	case VK_RIGHT:	// _xZkqqHx_iJeFjGoOiIpDiCmMiPoKiNiHiBeC_xHqqkZx_
		if (m_lCurIndex < GetIndexSize())
		{
			if (GetKeyState(VK_CONTROL) < 0)
			//----- CONTROL_xZkqqHx_iDeMiBfLiCkKjDkPiOjOiCmJiJjPiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
			{
				// GetNextBoundary_xZkqqHx_iCmNiBeBiMlLiNnNiImKjChFiCkKjCfAiMoKiLkLiKeFiCmMiPoKiNiHiCmFiCkAiCmBiCmEiCoA_xHqqkZx_
				// _xZkqqHx_iCePiCpAjFnEiClHiClBiCmGiCmNiCmIiCkCiBeCiOjPiCmMiLkLiKeFiCnMiCmFiCmMiDeJiDhEiDfKiDgCiDgHjCgMiCpAjFnEiClHiBeC_xHqqkZx_
				// _xZkqqHx_iCnAiCmGiCmCiMoDiCmMjCfAiMoKiLkLiKeFiCnMiCmFiInKjDkOiBeC_xHqqkZx_
				m_lCurIndex += GetNextBoundary(lCurLine, lCurChar);
			} else
			//----- CONTROL_xZkqqHx_iDeMiBfLiCkKjDkPiOjOiCmJiJjPiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiH_xHqqkZx_ -----
			{
				m_lCurIndex++;
			}
		}
		break;
	case VK_DOWN:	// _xZkqqHx_iJlKjGoOiIpDiCmMiPoKiNiHiBeC_xHqqkZx_
		if (lCurLine < m_vEditLine.size() - 1)
		{
			lCurLine++;
			long lGapX = CoordToGapX(lCurLine, m_mmCaretX);
			if (m_vEditLine[lCurLine].m_vEditChar[lGapX].m_wChar == FDRCH_CONTINUE)
				lGapX--;
			m_lCurIndex = CharPosToIndex(lCurLine, lGapX);
		}
		break;
	case VK_HOME:	// Home_xZkqqHx_iDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
		if (GetKeyState(VK_CONTROL) < 0)	// _xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiDeMiBfLjDkPiOjOiCmMiPoKiNiHiBeC_xHqqkZx_
			m_lCurIndex = 0;
		else
			m_lCurIndex -= lCurChar;
		break;
	case VK_END:	// End_xZkqqHx_iDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
		if (GetKeyState(VK_CONTROL) < 0)	// _xZkqqHx_iDfCiDjDiDgHiDiNiBfLiDiLiDeMiBfLjDkPiOjOiCmMiPoKiNiHiBeC_xHqqkZx_
		{
			m_lCurIndex = GetIndexSize();
		} else
		{
			m_lCurIndex += m_vEditLine[lCurLine].m_vEditChar.size() - lCurChar - 1;
			if (m_vEditLine[lCurLine].m_vEditChar.back().m_wChar == FDRCH_CONTINUE)
				m_lCurIndex--;
		}
		break;
	case VK_PRIOR:	// PgaeUp_xZkqqHx_iDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
//----- 05.07.27 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
		if (0 < lCurLine)
		{
			// _xZkqqHx_iDhJiBfLiDfH_xHqqkZx_UP/DOWN_xZkqqHx_iCmMiDfIiDeOiDiNiBfLiDiLjHmKiBeC_xHqqkZx_
			lCurLine -= FD_TED_PAGE_SCROLL_NUM;
			if (lCurLine < 0) lCurLine = 0;
			long lGapX = CoordToGapX(lCurLine, m_mmCaretX);
			if (m_vEditLine[lCurLine].m_vEditChar[lGapX].m_wChar == FDRCH_CONTINUE)
				lGapX--;
			m_lCurIndex = CharPosToIndex(lCurLine, lGapX);
		}
//----- 05.07.27 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
		break;
	case VK_NEXT:	// PgaeDown_xZkqqHx_iDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
//----- 05.07.27 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ ()-----
		if (lCurLine < m_vEditLine.size() - 1)
		{
			// _xZkqqHx_iDhJiBfLiDfH_xHqqkZx_UP/DOWN_xZkqqHx_iCmMiDfIiDeOiDiNiBfLiDiLjHmKiBeC_xHqqkZx_
			lCurLine += FD_TED_PAGE_SCROLL_NUM;
			if (m_vEditLine.size() - 1 < lCurLine)
				lCurLine = m_vEditLine.size() - 1;
			long lGapX = CoordToGapX(lCurLine, m_mmCaretX);
			if (m_vEditLine[lCurLine].m_vEditChar[lGapX].m_wChar == FDRCH_CONTINUE)
				lGapX--;
			m_lCurIndex = CharPosToIndex(lCurLine, lGapX);
		}
//----- 05.07.27 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ ()-----
		break;
	case VK_INSERT:	// Insert_xZkqqHx_iDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
		FFGetMainWnd()->SetOvrMode(!FFGetMainWnd()->IsOvrMode());
		break;

	default:	// _xZkqqHx_jFiBjCmKiCmMiDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
		return;
	}

	// _xZkqqHx_jClMjBeP_xHqqkZx_(_xZkqqHx_iIlNiCkCiCmNjClMiMoD_xHqqkZx_)_xZkqqHx_iCmMjFlGiOjKiCmMiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_.
	ResetCurFormat();

	if (GetKeyState(VK_SHIFT) < 0)
	//----- SHIFT_xZkqqHx_iDeMiBfLiCkKjDkPiOjOiCmJiJjPiClDiCoKiCmEiCkCiCoJiPoKiNiH_xHqqkZx_ -----
	{
		lSelTo = m_lCurIndex;
	} else
	//----- SHIFT_xZkqqHx_iDeMiBfLiCkKjDkPiOjOiCmJiJjPiClDiCoKiCmEiCkCiCmIiCkCiPoKiNiH_xHqqkZx_ -----
	{
		lSelFrom = lSelTo = -1;
	}
	SetSelect(lSelFrom, lSelTo);

	switch (nChar)
	{
	case VK_LEFT:	// _xZkqqHx_iNlGjGoOiIpDiCmMiPoKiNiHiBeC_xHqqkZx_
	case VK_RIGHT:	// _xZkqqHx_iJeFjGoOiIpDiCmMiPoKiNiHiBeC_xHqqkZx_
	case VK_HOME:	// Home_xZkqqHx_iDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
	case VK_END:	// End_xZkqqHx_iDeMiBfLiCmMiPoKiNiHiBeC_xHqqkZx_
		m_mmCaretX = RepositionCaret();
		break;
	default:
		(void)RepositionCaret();
	}
	// Baseclass_xZkqqHx_iKnGjAjEiOmAiNhDiBeC_xHqqkZx_
	CWnd::OnKeyDown(nChar, nRepCnt, nFlags);
} // CFCWndRichEdit::OnKeyDown.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnChar
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jFlGiOjKiDeMiBfLiCkKiJjPiClDiCoKiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_OnKeyDown_xZkqqHx_iMoDiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_jGoOiIpDjDjJiCmMjFlGiOjKiDeMiBfLiImIiKePiCmMiDeMiBfLiCkKiJjPiClDiCoKiClNiOjOiCmNiOmAiNhDiClDiCoKiCmIiCkCiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nChar	:_xZkqqHx_jFlGiOjKiDfCiBfLiDgIiBeCiJpMiNhDiCmMiPoKiNiHiCmN_xHqqkZx_0x0d_xZkqqHx_iCkKiCfAjFlGiOjKiBeB_xHqqkZx_Shift+_xZkqqHx_iJpMiNhDiCmF_xHqqkZx_
 *					 0x0a_xZkqqHx_iCkKiCfAjFlGiOjKjBhNjDpMiClDiCoKiCoJiBeC_xHqqkZx_
 *			nRepCnt	: 
 *			nFlags
 *************************************************************************/
void CFCWndRichEdit::OnChar (UINT nChar, UINT nRepCnt, UINT nFlags)
{
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	if (nChar == WCH_BS)	OnBackspace();
//	else					OnChar(CodeToWChar(nChar, CP_ACP));
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	if (nChar == WCH_BS)
	//----- Backspace_xZkqqHx_iCmMiPoKiNiH_xHqqkZx_ -----
	{
		OnBackspace();
	} else
//----- 06.04.04 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//	if (0x000d <= nChar)
//	//----- 0x20_xZkqqHx_iImIiPoDiCmMjFlGiOjKiCmMiCnNjDpMjHmNiJmCiBeC_xHqqkZx_^B_xZkqqHx_iCmGiCkJiCmNjDpMiCoKiCoKiCmIiCkC_xHqqkZx_ -----
//	{
//		FD_BEGIN_CHECK_TIME(L"CFCWndRichEdit::OnChar");
//		wchar_t w[2] = { L'\0', L'\0' };
//		w[0] = CodeToWChar(nChar, CP_ACP);
//		OnChars(w);
//		FD_END_CHECK_TIME;
//	}
//----- 06.04.04 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
	if (nChar == WCH_TAB ||	// _xZkqqHx_iDfOiDhFjFlGiOjKiBeC_xHqqkZx_
		nChar == WCH_CR ||	// _xZkqqHx_iJpMiNhDiBeC_xHqqkZx_
		nChar == WCH_LF ||	// _xZkqqHx_jFjMiLeBiBeC_xHqqkZx_
		WCH_SPC <= nChar)	// _xZkqqHx_iLpDjEjCiImIiPoDiCmMjFlGiOjKiBeC_xHqqkZx_
	{
		FD_BEGIN_CHECK_TIME(L"CFCWndRichEdit::OnChar");
		wchar_t w[2] = { L'\0', L'\0' };
		w[0] = CodeToWChar(nChar, CP_ACP);
		OnChars(w);
		FD_END_CHECK_TIME;
	}
//----- 06.04.04 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
//----- 06.02.24 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
	// Baseclass_xZkqqHx_iKnGjAjEiOmAiNhDiBeC_xHqqkZx_
	CWnd::OnChar(nChar, nRepCnt, nFlags);
} // CFCWndRichEdit::OnChar.

//----- 02.09.11 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoKiBeBjCiGiNjBiMoKjDjJiCmM_xHqqkZx_UNICODE_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)-----
///*************************************************************************
// * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnImeChar (WPARAM wParam, LPARAM lParam)
// *
// * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	IME_xZkqqHx_iCmFiBeBjDpMjHmNiCkKiKgNjCoIiClFiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wParam	:_xZkqqHx_iCfBiDgPiDeDiDgHiDfCiBfLiDgIiCpAiOhHjCoIiBeCiDhHiDiLiDhGiOfBiPmGiBeC_xHqqkZx_
// *			lparam	:_xZkqqHx_iDhCiDgCiDgHiClCiCmGiCmJiPoOjFpBiOhHjCoIiBeCiDhHiDiLiDhGiOfBiPmGiBeC_xHqqkZx_
// *
// * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmFiBeBjDpMjHmNjFlGiOjKiCpAiKgNjCoIiClFiClNiPoKiNiHiBeBiIlNiCkCiCmNjFmPiKlHiMoD_xHqqkZx_
// *			_xZkqqHx_iKgNjCoIiDeMiBfLiCpAiJjPiClDiClIiCmJjBlBiCkPiCmEjDpMjHmNiClFiClNiPoKiNiHiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
// *			_xZkqqHx_jHoBiCkGiCmOiBhFjDiMiLjOjDhDiBhGiCkKiKgNjCoIiClDiCoKiCoKiCmOiCfCiJpBjIeBjBlBiCmFiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
// *
// * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.22 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkMiBeB_xHqqkZx_IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmM_xHqqkZx_
// *								_xZkqqHx_iNmAjFfHjAnNjCoIiPiIjHjNiCpAjCmHiJmBiBeC_xHqqkZx_
// *************************************************************************/
//LRESULT CFCWndRichEdit::OnImeChar (WPARAM wParam, LPARAM lParam)
//{
//#if defined(_IME_ON)
//	TRACE(_T("OnImeChar\n"));
//	OnChar(CodeToWChar(wParam));
//
//	// _xZkqqHx_iKgNjCoIiDeMiBfLiCpAiJjPiClDiClIiCmJjBlBiCkPiCmEjDpMjHmNiClFiClNiOjOiCmJiCmNiBeB_xHqqkZx_OnImeStartcomposition_xZkqqHx_iCkK_xHqqkZx_
//	// _xZkqqHx_iOmAiNhDiClDiCoKiCmIiCkCiClNiCnPiBeBiClBiClBiCmF_xHqqkZx_IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoIiClHiCoJ_xHqqkZx_
//	// _xZkqqHx_jFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_
//
//	// _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNmAjFfHiCpAiOoGjDlOiBeC_xHqqkZx_
//	mmetol	mmX, mmY, mmH;
//	CalcCaret(mmX, mmY, mmH);
//
//	// IME_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
//	HIMC hIMC = ImmGetContext(m_hWnd);
//	if (!hIMC) return 1;
//	//----- IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoI_xHqqkZx_ -----
//	COMPOSITIONFORM	CompForm;
//	CompForm.dwStyle = CFS_POINT;
//	CompForm.ptCurrentPos.x = mm2lg(mmX);
//	CompForm.ptCurrentPos.y = mm2lg(mmY);
//	ImmSetCompositionWindow(hIMC, &CompForm);
//	// IME_xZkqqHx_iCpAiKeKjFpKiBeC_xHqqkZx_
//	ImmReleaseContext(m_hWnd, hIMC);
//#endif // defined(_IME_ON)
//
//	return 1;
//} // CFCWndRichEdit::OnImeChar.
//----- 02.09.11 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoKiBeBjCiGiNjBiMoKjDjJiCmM_xHqqkZx_UNICODE_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnImeStartcomposition
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	IME_xZkqqHx_iCmMiDeMiBfLjDpMjHmNiCkKiKeKiOgOiClDiCoKiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	_xZkqqHx_jGlDiClF_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jGlDiClFiBgJjGlDiMpIiBgK_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	IME_xZkqqHx_iCmMiNmFiPiJiCmMiDeMiBfLjDpMjHmNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_IME_xZkqqHx_iCpAjHeMiMpIiCmJiClFiClNiOjOiCmFiCmN_xHqqkZx_
 *			_xZkqqHx_iCmIiCkCiClBiCmGiCmJjCiNiInDiBeCiCnMiClNiBeBiKgNjCoIiDeMiBfLiCpAiJjPiClDiClIiCmJjBlBiCkPiCmEjDpMjHmNiClFiClN_xHqqkZx_
 *			_xZkqqHx_iOjOiCmJiCoAiOmAiNhDiClDiCoKiCmIiCkCiClBiCmGiCmJjCiNiInDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.22 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
LRESULT CFCWndRichEdit::OnImeStartcomposition (WPARAM wParam, LPARAM lParam)
{
#if defined(_IME_ON)
	TRACE(_T("OnImeStartcomposition\n"));

	//----- _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiPmBiLiOiClHiCoJ_xHqqkZx_ -----
// 02.05.31 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)
//	HideCaret();
	if (GetFocus() == this) HideCaret();
	::DestroyCaret();

//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----
//	//----- _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNmAjFfHiCpAjClCiCnHiCoJ_xHqqkZx_ -----
//	mmetol	mmX, mmY, mmH;
//	CalcCaret(mmX, mmY, mmH);
//	// IME_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
//	HIMC hIMC = ImmGetContext(m_hWnd);
//	if (!hIMC) return 1;
//
//	//----- IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoI_xHqqkZx_ -----
//	COMPOSITIONFORM	CompForm;
//	CompForm.dwStyle = CFS_POINT;
//	CompForm.ptCurrentPos.x = mm2lg(mmX);
//	CompForm.ptCurrentPos.y = mm2lg(mmY);
//	ImmSetCompositionWindow(hIMC, &CompForm);
//
//	LOGFONT lf;
//	//----- _xZkqqHx_jFlGiOjKjBkOjAkLiCkJiCoH_xHqqkZx_FCSFontRec_xZkqqHx_iNfMjBkCjBmMiCpAjAlGjAkM_xHqqkZx_ -----
//	FCSFontRec fp(m_fciCurStdCodeFormat);
//	fp.ReqInit(lf, 0.0, m_fciCurStdCodeFormat.wOffset);
//	// IME_xZkqqHx_iCmJiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
//	ImmSetCompositionFont(hIMC, &lf);
//	// IME_xZkqqHx_iCpAiKeKjFpKiBeC_xHqqkZx_
//	ImmReleaseContext(m_hWnd, hIMC);
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----
	// IME_xZkqqHx_iCnGiCmMjDpMjHmNiKeKiOgOiCkJiBeI_xHqqkZx_
	m_bStartImeComposition = TRUE;
//----- 02.09.11 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----
#endif // defined(_IME_ON)

	return Default();
} // CFCWndRichEdit::OnImeStartcomposition.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnImeEndcomposition
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	IME_xZkqqHx_iCmMjDpMjHmNiCkKiKgNjCoIiClDiCoKiClNiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	_xZkqqHx_jGlDiClF_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_jGlDiClFiBgJjGlDiMpIiBgK_xHqqkZx_
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	IME_xZkqqHx_iCmMjDpMjHmNiCkKiKgNjCoIiDeMiBfLiCmFiKgNjCoIiClDiCoKiClNiMoDiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *			_xZkqqHx_iKgNjCoIiDeMiBfLiCpAiJjPiClDiClIiCmJjBlBiCkPiCmEjDpMjHmNiClFiClNiOjOiCmJiCmNiOmAiNhDiClDiCoKiCmIiCkCiClBiCmGiCmJjCiNiInDiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	99.11.22 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
LRESULT CFCWndRichEdit::OnImeEndcomposition (WPARAM wParam, LPARAM lParam)
{
	TRACE(_T("OnImeEndcomposition\n"));
	/*----- _xZkqqHx_iDeKiDiMiDgCiDgHiCpAiNoMjAkMiClHiCoJ_xHqqkZx_ -----*/
	mmetol	mmX, mmY, mmH;
	CalcCaret(mmX, mmY, mmH);
	CreateSolidCaret(2, mm2lg(mmH));
	SetCaretPos(CPoint(mm2lg(mmX), mm2lg(mmY)));
// 02.05.31 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHjFnCiPfHjCiGiCmJjCiGiDhLiDfOiDjDiCmFiDfJiBfLiDiAiClHiCoJiCmGiBeBiDeHiDgGiDeCiDfOiCkKiClLiCmMiCnMiCnM_xHqqkZx_)
//	ShowCaret();
	if (GetFocus() == this) ShowCaret();

	return Default();
} // CFCWndRichEdit::OnImeEndcomposition.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnRulerMarker
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDiLiBfLiDiJiBfLiPoDiCmMiDhNiBfLiDeKiBfLiInKjDkOiOjOiCmJiOmAiNhDiClDiCoKiCoJiBeCiDeLiDeDiDgIjApMiCpAjFgAiCkCiClNiCoIiBeB_xHqqkZx_
 *			_xZkqqHx_iNhDiCmMiNmEiMhGiOfKiCpAiNhDiCkEiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wParam	:_xZkqqHx_iDhNiBfLiDeKiBfLiInKjDkOiCmMiOoNjHnO_xHqqkZx_.
 *			lParam	:_xZkqqHx_iDhNiBfLiDeKiBfLiInKjDkOiCmMiImKjChFiPoOjFpB_xHqqkZx_.
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPoNiCmJ_xHqqkZx_1.
 *
 * <_xZkqqHx_iJpAjAoA_xHqqkZx_>	WM_USER_RULER_MARKER_xZkqqHx_iDiBiDgCiDfKiBfLiDfHiCmJiCoGiCmBiCmEiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *			CFCCtlBrHRuler::OnLButtonDown _xZkqqHx_iBgA_xHqqkZx_ OnLButtonUp _xZkqqHx_iCkJiCoHiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	98.10.28 Fukushiro M. _xZkqqHx_iDfCiDiBiDjDiDgHiNoMjAkM_xHqqkZx_
 *************************************************************************/
LRESULT CFCWndRichEdit::OnRulerMarker (WPARAM wParam, LPARAM lParam)
{
	CClientDC dc(this); // _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
	//------ _xZkqqHx_jFgAiJoGiDiCiBfLiDgIiCmMjAnNjCoI_xHqqkZx_ -----
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiOgO_xHqqkZx_ ()-----
//	COLORREF crBack;
//	if (m_scidBrushBackSColor == FD_S_COLOR_TRANSPARENT)
//		crBack = ::g_pReg->GetOptiSheetColor();
//	else
//		crBack = ::OptiColor(g_pEnv->scid2cref(m_scidBrushBackSColor));
//----- 06.03.25 Fukushiro M. _xZkqqHx_iNoNiPjMiPeJ_xHqqkZx_ ()-----
	FCEditDraw eDraw(&dc, 0, g_pReg->GetOptiRegColor(FDCL_EDIT_LINE) ^ m_crBackground, -1, 0, 0);

	long lgX = long(lParam) + mm2lg(m_mmMarginL);

	switch (FTMarkStat(wParam))
	{
	case FDHR_MARKER_MOVE_BEGIN:		// _xZkqqHx_iDhNiBfLiDeKiBfLiInKjDkOiKeKiOgOiBeC_xHqqkZx_
		// _xZkqqHx_jAfGiClFiCkCiDeLiDeDiDgIjApMiCmMiNmAjFfHiCpAjAnNjCoIiBeC_xHqqkZx_
		m_lgIndentLine = lgX;
		//----- _xZkqqHx_iDeLiDeDiDgIjApMiCpAjFgAiJoG_xHqqkZx_ -----
		eDraw.Line(	&CPoint(m_lgIndentLine, 0),
					&CPoint(m_lgIndentLine, mm2lg(m_mmrtWindow.Height())));
		break;

	case FDHR_MARKER_MOVING:			// _xZkqqHx_iDhNiBfLiDeKiBfLiInKjDkOjCiGiBeC_xHqqkZx_
		//----- _xZkqqHx_iDeLiDeDiDgIjApMiCpAiPmBiClH_xHqqkZx_ -----
		eDraw.Line(	&CPoint(m_lgIndentLine, 0),
					&CPoint(m_lgIndentLine, mm2lg(m_mmrtWindow.Height())));
		// _xZkqqHx_jAfGiClFiCkCiDeLiDeDiDgIjApMiCmMiNmAjFfHiCpAjAnNjCoIiBeC_xHqqkZx_
		m_lgIndentLine = lgX;
		//----- _xZkqqHx_iDeLiDeDiDgIjApMiCpAjFgAiJoG_xHqqkZx_ -----
		eDraw.Line(	&CPoint(m_lgIndentLine, 0),
					&CPoint(m_lgIndentLine, mm2lg(m_mmrtWindow.Height())));
		break;

	case FDHR_MARKER_MOVE_END:		// _xZkqqHx_iDhNiBfLiDeKiBfLiInKjDkOiPeJjHlJiBeC_xHqqkZx_
	  {
		//----- _xZkqqHx_iDeLiDeDiDgIjApMiCpAiPmBiClH_xHqqkZx_ -----
		eDraw.Line(	&CPoint(m_lgIndentLine, 0),
					&CPoint(m_lgIndentLine, mm2lg(m_mmrtWindow.Height())));
		// _xZkqqHx_iDeLiDeDiDgIjApMiCmMiNmAjFfHiCpAiDeOiDiKiDeBiBeC_xHqqkZx_
		m_lgIndentLine = LONG_MAX;
		break;
	  }
	}
	return 1;
} // CFCWndRichEdit::OnRulerMarker.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnCurrentLineUpdated
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iMlLiNnNiCmMiNhDiPoOjFpBiCkKiNfIjAfGiClDiCoKiClNiClBiCmGiCpAjCmKjCgNiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	wParam	:_xZkqqHx_jGkCiOgHjHhAiBeC_xHqqkZx_
 *			lParam	:_xZkqqHx_jGkCiOgHjHhAiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jFnEjCgM_xHqqkZx_>	_xZkqqHx_iPoNiCmJ_xHqqkZx_1_xZkqqHx_iBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	00.08.07 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
LRESULT CFCWndRichEdit::OnCurrentLineUpdated (WPARAM wParam, LPARAM lParam)
{
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAiPmBiLiOiBeC_xHqqkZx_
	DrawSelect();
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiKeKiOgOiBeC_xHqqkZx_
	SessionBegin();

	long lCurLine, lCurChar;
	// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lCurLine, lCurChar, m_lCurIndex);
	// lCurLine_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
	(void)JoinLineBelow(lCurLine);
	// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
	IndexToCharPos(lCurLine, lCurChar, m_lCurIndex);
	// _xZkqqHx_iNmEiMhGiOfKiCkKjFeLjHhGiCmIiNhDiCmMiNmFiPkMjCgMiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
	long lMinLine = lCurLine;
	//----- _xZkqqHx_iNhDiCmJjBkOjAkLjAnNjCoI_xHqqkZx_ -----
	FCEditLine el;
	// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
	el.CopyProperty(m_vEditLine[lCurLine]);
	// _xZkqqHx_iNhDiPoOjFpBiCpAiPoDiPjBiCkLjFmPiNfIiBeC_xHqqkZx_
	el.m_mmStartIndent	= FFGetMainWnd()->HRuler()->GetLeftIndent();
	el.m_mmOffset		= FFGetMainWnd()->HRuler()->GetOffsetIndent();
	el.m_mmRightIndent	= FFGetMainWnd()->HRuler()->GetRightIndent();
	el.m_mmvTabs		= FFGetMainWnd()->HRuler()->GetTabs();
	// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
	CmdFormatLine(m_lCurIndex - lCurChar, el);

	// _xZkqqHx_jBeJjBpAjEmNiImNiCkKiCkAiCoJiPoKiNiHiCmNjFmKiCmJiPiIjHjNiClHiCoJiBeCjBeJjBpAjEmNiImNiCmGiDeKiDiMiDgCiDgHiImKjChFiCkK_xHqqkZx_
	// _xZkqqHx_jFmKiCmMiNhDiCmFiCkAiCoJiPoKiNiHiCoAiCkAiCoJiClNiCnPiBeBjDmGjHkHiCmJiPiIjHjNiClFiClNjFpLiCkKjHmHiCkCiBeC_xHqqkZx_
	if (0 <= m_lSelFrom)
	{
//----- 01.01.26 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		long lSelFrom= (m_lSelFrom < m_lSelTo) ? m_lSelFrom : m_lSelTo;
//		long lSelTo	 = (m_lSelFrom < m_lSelTo) ? m_lSelTo : m_lSelFrom;
//----- 01.01.26 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		long lSelFrom, lSelTo;
		GetSelectNormal(lSelFrom, lSelTo);
//----- 01.01.26 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
		long lLineFrom, lLineTo;
		long lCharFrom, lCharTo;
		// _xZkqqHx_iKpJiCmJjIeBiMiLiPiIjHjNiClFiClNiNhDiCoGiCoIiCoAjBeJjBpAjEmNiImNiCkKiPkMiClDiCkCiNhDiCkJiCoHiCmMiJmCjEfMjAkLiCkKiCkAiCoJiPoKiNiHiBeC_xHqqkZx_
		if (lSelFrom < m_lCurIndex)
		{
			// _xZkqqHx_iDeDiDjDiDgGiDgCiDeOiDfIiCkJiCoHiBeBiNhDiCmGjFlGiOjKiImKjChFiCpAiMhGiOfKiBeC_xHqqkZx_
			IndexToCharPos(lLineFrom, lCharFrom, lSelFrom);
			// lLineFrom_xZkqqHx_iImIiNhOiCmMiNhDiCmMiMhAjBlBiNhDiCpAjAoGjDkKiNhDiCmJjIeBiMiLiClHiCoJiBeC_xHqqkZx_
			(void)JoinLineBelow(lLineFrom);
		}
		// _xZkqqHx_iMhAjBlBiNhDiCpAjIeBiMiLiPiIjHjNiClFiClNiMoDiCmMiNhDiCmGjFlGiOjKiImKjChFiCpAiNmEjDhIiMhGiOfKiBeC_xHqqkZx_
		IndexToCharPos(lLineFrom, lCharFrom, lSelFrom);
		// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiNmFiMoDiCmMjFlGiOjK_xHqqkZx_(lSelTo_xZkqqHx_iCmNiNmFiMoDiCmMiOjPiCmMjFlGiOjK_xHqqkZx_)_xZkqqHx_iCmMiNhDiCpAiMhGiOfKiBeC_xHqqkZx_
		IndexToCharPos(lLineTo, lCharTo, lSelTo - 1);
		// _xZkqqHx_iNmEiMhGiOfKiCkKjFeLjHhGiCmIiNhDiCmMiNmFiPkMjCgMiCpAiLiBiCnPiCoJiBeC_xHqqkZx_
		if (lLineFrom < lMinLine) lMinLine = lLineFrom;
		// _xZkqqHx_jBeJjBpAjEmNiImNiNmFiPiJiCmMjFlGiOjKiCmMiNhDiCkJiCoHiNmFiMoDiCmMjFlGiOjKiCmMiNhDiCnMiCmFiCpAiDiLiBfLiDhGiBeC_xHqqkZx_
		for (long lLn = lLineFrom; lLn <= lLineTo; lLn++)
		{
			//----- _xZkqqHx_iNhDiCmJjBkOjAkLjAnNjCoI_xHqqkZx_ -----
			// _xZkqqHx_iNhDiPoOjFpBiCpAiDfCiDhDiBfLiBeC_xHqqkZx_
			el.CopyProperty(m_vEditLine[lLn]);
			// _xZkqqHx_iNhDiPoOjFpBiCpAiPoDiPjBiCkLjFmPiNfIiBeC_xHqqkZx_
			el.m_mmStartIndent	= FFGetMainWnd()->HRuler()->GetLeftIndent();
			el.m_mmOffset		= FFGetMainWnd()->HRuler()->GetOffsetIndent();
			el.m_mmRightIndent	= FFGetMainWnd()->HRuler()->GetRightIndent();
			el.m_mmvTabs		= FFGetMainWnd()->HRuler()->GetTabs();
			// _xZkqqHx_iMlLiNnNiCmMiNhDiCmJiNhDiPoOjFpBiCpAjAnNjCoIiBeC_xHqqkZx_
			CmdFormatLine(CharPosToIndex(lLn, 0), el);
		}
	}
	// _xZkqqHx_iDfCiDhNiDjDiDgIiDfKiDgCiDfGiDiHiDjDiPeJjHlJiBeC_xHqqkZx_
	SessionEnd();

	//----- _xZkqqHx_iPeDjAlDiNhDiImIiNhOiCpAiNmEiMhGiOfK_xHqqkZx_ -----
	CalcLineBelow(lMinLine);
	m_mmCaretX = RepositionCaret();
	// _xZkqqHx_iNmEjFfMiOkGiBeC_xHqqkZx_
	SendRgnRedraw();
	// _xZkqqHx_jBeJjBpAjEmNiImNiCmMiDhNiBfLiDeOiCpAjFgAiJoGiBeC_xHqqkZx_
	DrawSelect();
	return 1;
} // CFCWndRichEdit::OnCurrentLineUpdated.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnContextMenu
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iJeFiDhLiDfOiDjDiDeOiDiKiDgCiDeOiBeBiIlNiCkCiCmNiDiBiDgKiDiFiBfLiDeMiBfLiCmJiCoGiCmBiCmEiLeOjDkOiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iJeFiDhLiDfOiDjDiDeOiDiKiDgCiDeOiCmFiMmEiCnBiPgPiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	pWnd	:_xZkqqHx_iJeFiDhLiDfOiDjDiCkKiDeOiDiKiDgCiDeOiClDiCoKiClNiDeFiDeCiDjDiDgIiDeFiCmMiDgOiDjDiDgIiDiLiCpAiOhHjCoIiBeC_xHqqkZx_
 *			point	:_xZkqqHx_iDeOiDiKiDgCiDeOiClFiClNiNmAjFfHiBgJiDfIiDeOiDiKiBfLiDjDiNmAjFfHiBgKiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jCiNiInD_xHqqkZx_>	_xZkqqHx_iDeHiDgGiDeCiDfOiPoDiCmFiCmMiDeOiDiKiDgCiDeOiCmMiPoKiNiHiCmNiClBiClBiCmJjHiIiCoJiCkKiBeBiDhCiDiFiBfLiPoDiCmFiCmM_xHqqkZx_
 *			_xZkqqHx_iDeOiDiKiDgCiDeOiCmMiPoKiNiHiBeB_xHqqkZx_Tool_xZkqqHx_iCmJiNhDiCkNiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	01.04.27 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnContextMenu (CWnd* pWnd, CPoint point)
{
	// _xZkqqHx_iDfEiDhFiDiBiDgKiDiFiBfLiCpAiDhMiDgCiDhGiDeBiDgCiDhGiBeC_xHqqkZx_
// 06.02.24 Fukushiro M. 1_xZkqqHx_iNhDjFmPiNfI_xHqqkZx_ ()
//	FFPopupSubmenu(point, IDR_RBTN_TOOL, FD_MENU_TOOL_RICH_EDIT, AfxGetMainWnd());
	FFPopupSubmenu(point, IDR_RBTN_TOOL, FD_MENU_TOOL_RICH_EDIT, FFGetMainWnd()->GetWnd());
} // CFCWndRichEdit::OnContextMenu.

//----- 02.06.24 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoKiBeBjCiGiNjBiMoKjDjJiCmM_xHqqkZx_UNICODE_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnImeComposition
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	IME_xZkqqHx_iCmMjFlGiOjKjDpMjHmNiOjOiBeBiKgNjCoIiOjOjDjJiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	_xZkqqHx_iDeJiDjDiDiJiDeDiDjDiDhHiDiLiDhGiOfBiPmGiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iPnKiNnH_xHqqkZx_>	95_xZkqqHx_iImIiKePiCmM_xHqqkZx_OS_xZkqqHx_iCmFiCmNiBeBjClMjAnK_xHqqkZx_ UNICODE_xZkqqHx_jFlGiOjKjHpBiCkKiOoGjDlOiCmFiCkLiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	02.06.25 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
LRESULT CFCWndRichEdit::OnImeComposition (WPARAM wParam, LPARAM lParam)
{
#if defined(_IME_ON)
	TRACE(_T("CFCWndRichEdit::OnImeComposition %x\n"), lParam);

//----- 02.08.31 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----
	if (m_bStartImeComposition)
	//----- IME_xZkqqHx_iCnGiCmMjDpMjHmNiKeKiOgOiCmMiPoKiNiH_xHqqkZx_ -----
	{
		//----- _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNmAjFfHiCpAjClCiCnHiCoJ_xHqqkZx_ -----
		mmetol	mmX, mmY, mmH;
		CalcCaret(mmX, mmY, mmH);
		// IME_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
		HIMC hIMC = ImmGetContext(m_hWnd);
		if (!hIMC) return 1;

		//----- IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoI_xHqqkZx_ -----
		COMPOSITIONFORM	CompForm;
		CompForm.dwStyle = CFS_POINT;
		CompForm.ptCurrentPos.x = mm2lg(mmX);
		CompForm.ptCurrentPos.y = mm2lg(mmY);
		ImmSetCompositionWindow(hIMC, &CompForm);

		//----- IME_xZkqqHx_iCmJiDhEiDeIiDjDiDgHiCpAjAnNjCoI_xHqqkZx_ -----
		// _xZkqqHx_iHeA_xHqqkZx_ IME_xZkqqHx_iCmFiOgHiCoNiCoKiCmEiCkCiCoJiMlLiNnNiCmM_xHqqkZx_CharSet_xZkqqHx_iCpAiOoGiCoIiPgPiClHiBeC_xHqqkZx_
		// _xZkqqHx_iHeB_xHqqkZx_ _xZkqqHx_iMlLiNnNiCmM_xHqqkZx_CharSet_xZkqqHx_iCmJiNiHiCoNiClJiCmEiBeBjFlGiOjKiCkKjDpMjHmNiClDiCoKiClNiOjOiCmJjAlGjAkMiClDiCoKiCoJ_xHqqkZx_
		//    _xZkqqHx_iDhEiDeIiDjDiDgHiPoOjFpBiCpAiNoMjAkMiClHiCoJiBeC_xHqqkZx_
		// _xZkqqHx_iHeC_xHqqkZx_ _xZkqqHx_iNoMjAkMiClFiClNiDhEiDeIiDjDiDgHiPoOjFpBiCpA_xHqqkZx_IME_xZkqqHx_iCmJjAnNjCoIiClHiCoJiBeC_xHqqkZx_
		// DD3_xZkqqHx_iCmMjFfHiPiAiCmJiDgOiDjDiDePiDiLiBeB_xHqqkZx_IME_xZkqqHx_iCmJjDpKjGhLiMoKiCpAiOhHjCoIiClFiClNiPoKiNiHiBeBiClBiCmMiOoIiPiHiCmFiCmN_xHqqkZx_
		// m_fciCurExtCodeFormat _xZkqqHx_iCpAiMlDiCmJiDhEiDeIiDjDiDgHiCkKiNoMjAkMiClDiCoKiCoJiBeC_xHqqkZx_
		// _xZkqqHx_iClFiCkJiClFiBeBiOmAiNnLiCmJiCmNiBeBjDpMjHmNiClDiCoKiClNjFlGiOjK_xHqqkZx_(_xZkqqHx_iCnAiCoHiCkKiCmIiBeBiKlPiOjKjDjJ_xHqqkZx_)_xZkqqHx_iCmNiBeB_xHqqkZx_
		// _xZkqqHx_iDgOiDjDiDePiDiLiCmM_xHqqkZx_CharSet_xZkqqHx_jEmNoBgFiCmJiCoAjDpMiCmBiCmEiClFiCnMiCkEiClNiCnPiBeB_xHqqkZx_
		// _xZkqqHx_jDpMjHmNiClDiCoKiClNjFlGiOjKiCmN_xHqqkZx_ m_fciCurStdCodeFormat _xZkqqHx_iCmFiPiJiKpKiJlLiClDiCoKiCmEiClFiCnMiCkEiBeC_xHqqkZx_
		LOGFONT lf;
		ImmGetCompositionFont(hIMC, &lf);
		// IME_xZkqqHx_jHhAjFlGiOjKiDfCiBfLiDgIiDhEiDeIiBfLiDhNiDgCiDgHiBeC_xHqqkZx_
		FCFontCharInfo fciImeCodeFormat;
		if (lf.lfCharSet == g_pReg->GetStdFontCharset())
		//----- IME_xZkqqHx_iCmMjAnNjCoIiCkKiBeB_xHqqkZx_DD3_xZkqqHx_iCmMiMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfKiDgCiDgHiCmGjDjJiClFiCkCiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jFfHiPiAjFlGiOjKiDfCiBfLiDgIiCmFiPiJiKpKiJlLiBeC_xHqqkZx_
			fciImeCodeFormat = m_fciCurStdCodeFormat;
		} else
		//----- IME_xZkqqHx_iCmMjAnNjCoIiCkKiBeB_xHqqkZx_DD3_xZkqqHx_iCmMiMlLiNnNiCmMjFfHiPiAjFlGiOjKiDfKiDgCiDgHiCmGiInJiCmIiCoJiPoKiNiH_xHqqkZx_ -----
		{
			// _xZkqqHx_jFfHiPiAiKePjFlGiOjKiDfCiBfLiDgIiCmFiPiJiKpKiJlLiBeC_xHqqkZx_CharSet _xZkqqHx_iCmN_xHqqkZx_IME_xZkqqHx_iCmMiCoAiCmMiCpAiOgHiCkEiBeC_xHqqkZx_
			fciImeCodeFormat = m_fciCurExtCodeFormat;
			fciImeCodeFormat.byCharSet = lf.lfCharSet;
		}
		FCSFontRec fntRec(fciImeCodeFormat);
		// _xZkqqHx_iNmFiCoAiLnPiCkCiDhEiDeIiDjDiDgHiPoOjFpBiCpAiNoMjAkMiBeC_xHqqkZx_
		(void)g_pEnv->FindNearestSFont(fntRec, NULL);
		fntRec.ReqInit(lf, 0.0, fciImeCodeFormat.wOffset);
		// IME_xZkqqHx_iCmJiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
		ImmSetCompositionFont(hIMC, &lf);
		// IME_xZkqqHx_iCpAiKeKjFpKiBeC_xHqqkZx_
		ImmReleaseContext(m_hWnd, hIMC);
		// IME_xZkqqHx_iCnGiCmMjDpMjHmNjDhCjCiGiBeC_xHqqkZx_
		m_bStartImeComposition = FALSE;

		TRACE(_T("IME FONT %s\n"), lf.lfFaceName);
	}
//----- 02.08.31 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----

	WString wstrText;
	HIMC hIMC;
	if (lParam & GCS_RESULTSTR)
	//----- _xZkqqHx_jDpMjHmNjFlGiOjKiCkKiKgNjCoIiClFiClNiPoKiNiH_xHqqkZx_ -----
	{
		TRACE(_T("GCS_RESULTSTR ImmGetContext\n"));

		hIMC = ImmGetContext(m_hWnd);
		if (!hIMC) return 1;

		// [FFVersionInfo().dwMajorVersion]
		//   WindowsNT3.51	3
		//   WindowsNT4.0	4
		//   Windows2000	5
		//   Windows95		4
		//   Windows98		4
		//   WindowsMe		4
		//
		// [FFVersionInfo().dwMinorVersion]
		//   WindowsNT3.51	51
		//   WindowsNT4.0	0
		//   Windows2000	0
		//   Windows95		0
		//   Windows98		10
		//   WindowsMe		90
		//
		// [FFVersionInfo().dwPlatformId]
		//   WindowsNT3.51	VER_PLATFORM_WIN32_NT
		//   WindowsNT4.0	VER_PLATFORM_WIN32_NT
		//   Windows2000	VER_PLATFORM_WIN32_NT
		//   Windows95		VER_PLATFORM_WIN32_WINDOWS

		if (FFVersionInfo().dwMajorVersion == 4 &&
			FFVersionInfo().dwMinorVersion == 0 &&
			FFVersionInfo().dwPlatformId == VER_PLATFORM_WIN32_WINDOWS)
		//----- Windows 95 _xZkqqHx_iCmMiPoKiNiH_xHqqkZx_ ------
		{
			// IME_xZkqqHx_iCmM_xHqqkZx_MBCS_xZkqqHx_jFlGiOjKjHpBiCmMiDgPiDeDiDgHjClHiCpAiOoGjDlOiBeC_xHqqkZx_
			DWORD dwTextLen = ImmGetCompositionString(hIMC, GCS_RESULTSTR, NULL, 0);
			// _xZkqqHx_iLpDjFlGiOjKjFkKiCpAiJmBiOfKiClFiCmEiDgPiDgCiDhEiDeAiKgNjFnLiBeC_xHqqkZx_
			astring astrText;
			astrText.resize(dwTextLen + 1);
			// IME_xZkqqHx_iCkJiCoH_xHqqkZx_MBCS_xZkqqHx_jFlGiOjKjHpBiCpAiOoGjDlOiBeC_xHqqkZx_
			ImmGetCompositionString(hIMC, GCS_RESULTSTR, astrText.begin(),
									dwTextLen + 1);
			// _xZkqqHx_iDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAjDeLjAnIiCmJiBgJiNmFiMoDiCmMiLpDjFlGiOjKiCpAiNoNiPjMiBgK_xHqqkZx_
			astrText.resize(dwTextLen);
			wstrText = (const wchar_t*)AStrToWStr(astrText.c_str());
		} else
		//----- Windows 95 _xZkqqHx_iImIiKePiCmMiPoKiNiH_xHqqkZx_ ------
		{
			// IME_xZkqqHx_iCmM_xHqqkZx_Unicode_xZkqqHx_jFlGiOjKjHpBiCmMiDgPiDeDiDgHjClHiCpAiOoGjDlOiBeC_xHqqkZx_
			DWORD dwTextLen = ImmGetCompositionStringW(hIMC, GCS_RESULTSTR, NULL, 0);
			dwTextLen /= 2;
			// _xZkqqHx_iLpDjFlGiOjKjFkKiCpAiJmBiOfKiClFiCmEiDgPiDgCiDhEiDeAiKgNjFnLiBeC_xHqqkZx_
			wstrText.resize(dwTextLen + 1);
			// IME_xZkqqHx_iCkJiCoH_xHqqkZx_Unicode_xZkqqHx_jFlGiOjKjHpBiCpAiOoGjDlOiBeC_xHqqkZx_
			ImmGetCompositionStringW(hIMC, GCS_RESULTSTR, wstrText.begin(),
									(dwTextLen + 1) * sizeof(wchar_t));
			// _xZkqqHx_iDgPiDgCiDhEiDeAiCmMiDfEiDeDiDfJiCpAjDeLjAnIiCmJiBgJiNmFiMoDiCmMiLpDjFlGiOjKiCpAiNoNiPjMiBgK_xHqqkZx_
			wstrText.resize(dwTextLen);
		}

//----- 06.02.23 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ ()-----
//		ImmReleaseContext(m_hWnd, hIMC);
//		// Unicode_xZkqqHx_jFlGiOjKjHpBiCpAjBhNjDpMiBeC_xHqqkZx_
//		OnChars(wstrText.c_str());
//
////----- 02.08.31 Fukushiro M. _xZkqqHx_jFmPiNfIjBeP_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----
////		// _xZkqqHx_iKgNjCoIiDeMiBfLiCpAiJjPiClDiClIiCmJjBlBiCkPiCmEjDpMjHmNiClFiClNiOjOiCmJiCmNiBeB_xHqqkZx_OnImeStartcomposition_xZkqqHx_iCkK_xHqqkZx_
////		// _xZkqqHx_iOmAiNhDiClDiCoKiCmIiCkCiClNiCnPiBeBiClBiClBiCmF_xHqqkZx_IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoIiClHiCoJ_xHqqkZx_
////		// _xZkqqHx_jFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_
////
////		// _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNmAjFfHiCpAiOoGjDlOiBeC_xHqqkZx_
////		mmetol mmX, mmY, mmH;
////		CalcCaret(mmX, mmY, mmH);
////		// IME_xZkqqHx_iCpAiOoGjDlOiBeC_xHqqkZx_
////		HIMC hIMC = ImmGetContext(m_hWnd);
////		if (!hIMC) return 1;
////		//----- IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoI_xHqqkZx_ -----
////		COMPOSITIONFORM	CompForm;
////		CompForm.dwStyle = CFS_POINT;
////		CompForm.ptCurrentPos.x = mm2lg(mmX);
////		CompForm.ptCurrentPos.y = mm2lg(mmY);
////		ImmSetCompositionWindow(hIMC, &CompForm);
////		TRACE(_T("OnImeComposition2 %d %d\n"), CompForm.ptCurrentPos.x, CompForm.ptCurrentPos.y);
////
////		// IME_xZkqqHx_iCpAiKeKjFpKiBeC_xHqqkZx_
////		ImmReleaseContext(m_hWnd, hIMC);
////----- 02.08.31 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----
//		// _xZkqqHx_iKgNjCoIiDeMiBfLiCpAiJjPiClDiClIiCmJjBlBiCkPiCmEjDpMjHmNiClFiClNiOjOiCmJiCmNiBeB_xHqqkZx_OnImeStartcomposition_xZkqqHx_iCkK_xHqqkZx_
//		// _xZkqqHx_iOmAiNhDiClDiCoKiCmIiCkCiClNiCnPiBeBiOjPiCmMiNmFiPiJiCmM_xHqqkZx_OnImeComposition_xZkqqHx_iCmFiBeB_xHqqkZx_IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmM_xHqqkZx_
//		// _xZkqqHx_iNmAjFfHiCpAjAnNjCoIiClHiCoJjFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_
//		// IME_xZkqqHx_iCnGiCmMjDpMjHmNiKeKiOgOiCkJiBeI_xHqqkZx_
//		m_bStartImeComposition = TRUE;
////----- 02.08.31 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkC_xHqqkZx_)-----
//----- 06.02.23 Fukushiro M. _xZkqqHx_jFmPiNfIiMoD_xHqqkZx_ ()-----
		// Unicode_xZkqqHx_jFlGiOjKjHpBiCpAjBhNjDpMiBeC_xHqqkZx_
		OnChars(wstrText.c_str());

		//----- _xZkqqHx_iImIiJlKiCmNiKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkCiCkNiCmIiCoJiCmMiCmFjEhCiPjMiClFiCmEiCkCiClNiCkKiBeB_xHqqkZx_
		//		_xZkqqHx_jDpKjGhLiMoKiCmFiKgNjCoIiMoDjIeBjBlBiClFiCmEjFlGiOjKiCpAjDpMjHmNiClFiClNiPoKiNiHiBeBjFfMiOkGiCkKiNjFiCkNiCmIiCoJiClNiCnPiBeBiNmEiCnBiMlDiCmJjGnPiClH_xHqqkZx_ -----
		// _xZkqqHx_iKgNjCoIiDeMiBfLiCpAiJjPiClDiClIiCmJjBlBiCkPiCmEjDpMjHmNiClFiClNiOjOiCmJiCmNiBeB_xHqqkZx_OnImeStartcomposition_xZkqqHx_iCkK_xHqqkZx_
		// _xZkqqHx_iOmAiNhDiClDiCoKiCmIiCkCiClNiCnPiBeBiClBiClBiCmF_xHqqkZx_IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoIiClHiCoJ_xHqqkZx_
		// _xZkqqHx_jFeLjHhGiCkKiCkAiCoJiBeC_xHqqkZx_

		// _xZkqqHx_iDeKiDiMiDgCiDgHiCmMiNmAjFfHiCpAiOoGjDlOiBeC_xHqqkZx_
		mmetol mmX, mmY, mmH;
		CalcCaret(mmX, mmY, mmH);

		//----- IME_xZkqqHx_jDpMjHmNiDeFiDeCiDjDiDgIiDeFiCmMiNmAjFfHiCpAjAnNjCoI_xHqqkZx_ -----
		COMPOSITIONFORM	CompForm;
		CompForm.dwStyle = CFS_POINT;
		CompForm.ptCurrentPos.x = mm2lg(mmX);
		CompForm.ptCurrentPos.y = mm2lg(mmY);
		ImmSetCompositionWindow(hIMC, &CompForm);
		TRACE(_T("OnImeComposition2 %d %d\n"), CompForm.ptCurrentPos.x, CompForm.ptCurrentPos.y);

		// IME_xZkqqHx_iCpAiKeKjFpKiBeC_xHqqkZx_
		ImmReleaseContext(m_hWnd, hIMC);
		//----- _xZkqqHx_iClBiClBiCnMiCmFiCkKiKnIiNjBiMoK_xHqqkZx_IME_xZkqqHx_iCmFjDkOiNoMiCkKiCkIiCkJiClFiCkCiPoKiPiK_xHqqkZx_ -----

//----- 06.02.23 Fukushiro M. _xZkqqHx_jFmPiNfIiPeJ_xHqqkZx_ ()-----
		return 1;
	}
#endif//defined(_IME_ON)
	return Default();
} // CFCWndRichEdit::OnImeComposition.
//----- 02.06.24 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_ (_xZkqqHx_iKnIiNjBiMoKiBeBjCiGiNjBiMoKjDjJiCmM_xHqqkZx_UNICODE_xZkqqHx_iCmJjBmOiJjO_xHqqkZx_)-----

//----- 02.08.29 Fukushiro M. _xZkqqHx_jCmHiJmBiOgO_xHqqkZx_ (_xZkqqHx_iDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiDiCiBfLiDgIiCmFiBeBiDhNiDeFiDfIiCmMjCiGiDhLiDfOiDjDiCpAiOgHiCkGiCoJiCoGiCkEiCmJiClFiClN_xHqqkZx_)-----
/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnMButtonDown
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhNiDeFiDfIjCiGiDhLiDfOiDjDiCkKiJjPiClDiCoKiClNiCmGiCkLiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nFlags	:_xZkqqHx_jDkPiOjOiCmJiJjPiClDiCoKiClNiDeMiBfLiCmMiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
 *			point	:_xZkqqHx_iDhNiDeFiDfIiNmAjFfHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	02.08.29 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnMButtonDown (UINT nFlags, CPoint point)
{
	// View_xZkqqHx_iCmMiDeDiDhIiDjDiDgHiKnGjAjEiCpAiOmAiNhDiClHiCoJiBeC_xHqqkZx_
	CPoint ptView = point;
	MapWindowPoints(g_pView, &ptView, 1);
	MSG msg = *GetCurrentMessage();
	msg.lParam = MAKELONG(ptView.x, ptView.y);
	g_pView->SendMessage(msg.message, msg.wParam, msg.lParam);
	// Superclass_xZkqqHx_iKnGjAjEiOmAiNhDiBeC_xHqqkZx_
	CWnd::OnMButtonDown(nFlags, point);
} // CFCWndRichEdit::OnMButtonDown.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnMButtonUp
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhNiDeFiDfIjCiGiDhLiDfOiDjDiCkKjHkDiClDiCoKiClNiCmGiCkLiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nFlags	:_xZkqqHx_jDkPiOjOiCmJiJjPiClDiCoKiClNiDeMiBfLiCmMiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
 *			point	:_xZkqqHx_iDhNiDeFiDfIiNmAjFfHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	02.08.29 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnMButtonUp (UINT nFlags, CPoint point)
{
	// View_xZkqqHx_iCmMiDeDiDhIiDjDiDgHiKnGjAjEiCpAiOmAiNhDiClHiCoJiBeC_xHqqkZx_
	CPoint ptView = point;
	MapWindowPoints(g_pView, &ptView, 1);
	MSG msg = *GetCurrentMessage();
	msg.lParam = MAKELONG(ptView.x, ptView.y);
	g_pView->SendMessage(msg.message, msg.wParam, msg.lParam);
	// Superclass_xZkqqHx_iKnGjAjEiOmAiNhDiBeC_xHqqkZx_
	CWnd::OnMButtonUp(nFlags, point);
} // CFCWndRichEdit::OnMButtonUp.

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::OnMButtonDblClk
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_iDhNiDeFiDfIjCiGiDhLiDfOiDjDiCkKiDfPiDhFiDiLiDeOiDiKiDgCiDeOiClDiCoKiClNiCmGiCkLiCmJiOmAiNhDiClDiCoKiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_iIpIjAjE_xHqqkZx_>	nFlags	:_xZkqqHx_jDkPiOjOiCmJiJjPiClDiCoKiClNiDeMiBfLiCmMiPoOjFpBiCpAiOhHjCoIiBeC_xHqqkZx_
 *			point	:_xZkqqHx_iDhNiDeFiDfIiNmAjFfHiCpAiOhHjCoIiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	02.08.29 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::OnMButtonDblClk (UINT nFlags, CPoint point)
{
	// View_xZkqqHx_iCmMiDeDiDhIiDjDiDgHiKnGjAjEiCpAiOmAiNhDiClHiCoJiBeC_xHqqkZx_
	CPoint ptView = point;
	MapWindowPoints(g_pView, &ptView, 1);
	MSG msg = *GetCurrentMessage();
	msg.lParam = MAKELONG(ptView.x, ptView.y);
	g_pView->SendMessage(msg.message, msg.wParam, msg.lParam);
	// Superclass_xZkqqHx_iKnGjAjEiOmAiNhDiBeC_xHqqkZx_
	CWnd::OnMButtonDblClk(nFlags, point);
} // CFCWndRichEdit::OnMButtonDblClk.
//----- 02.08.29 Fukushiro M. _xZkqqHx_jCmHiJmBiPeJ_xHqqkZx_  (_xZkqqHx_iDgFiDeMiDfIiDgHiDeHiDgGiDeCiDfOiDiCiBfLiDgIiCmFiBeBiDhNiDeFiDfIiCmMjCiGiDhLiDfOiDjDiCpAiOgHiCkGiCoJiCoGiCkEiCmJiClFiClN_xHqqkZx_)-----

/*************************************************************************
 * <_xZkqqHx_iKnGjAjE_xHqqkZx_>	CFCWndRichEdit::CalcCharWidthAll
 *
 * <_xZkqqHx_iLeAjEfM_xHqqkZx_>	_xZkqqHx_jBfDiCmEiCmMjFlGiOjKiCmMjFlGiOjKjFjN_xHqqkZx_(A,B,C)_xZkqqHx_iCpAiMhGiOfKiClHiCoJiBeC_xHqqkZx_
 *
 * <_xZkqqHx_jHjKjHpA_xHqqkZx_>	06.06.22 Fukushiro M. _xZkqqHx_iNoMjAkM_xHqqkZx_
 *************************************************************************/
void CFCWndRichEdit::CalcCharWidthAll ()
{
	// CDC_xZkqqHx_iCpA_xHqqkZx_Auto_xZkqqHx_iCmFiDiJiDgCiDhGiBeC_xHqqkZx_
	CClientDC dc(this); // _xZkqqHx_iDgGiDgPiDeDiDfIiDfCiDjDiDgFiDeMiDfIiDgHiBeC_xHqqkZx_
	FCAutoDC atDC(&dc, FALSE, 0, 0);
	SFontID foidCurFont = SFontID(-1);	// _xZkqqHx_iClBiCoKiCpAiClFiCmIiCkCiCmGiBeBiNmFiPiJiCmMiDhEiDeIiDjDiDgHiPiJiKpKiJlLiCkKiClDiCoKiCmIiCkCiBeC_xHqqkZx_
	WORD wCurOffset = WORD(-1);			// _xZkqqHx_jHeMiCoIjDlOiCmIiCkCjCgMiCpAjAnNjCoIiBeC_xHqqkZx_
	WORD wCurCodePage = CP_ACP;

	FCEditLineVector::iterator iLine;
	for (iLine = m_vEditLine.begin(); iLine != m_vEditLine.end(); iLine++)
	{
		FCEditCharVector::iterator iChar;
		for (iChar = (*iLine).m_vEditChar.begin();
			 iChar != (*iLine).m_vEditChar.end(); iChar++)
		{
			switch ((*iChar).m_wChar)
			{
			case FDRCH_RETURN:
				(*iChar).m_mmfWidth = FDWR_RETURN_WIDTH;	// _xZkqqHx_iJpMiNhDiCmMjFfHiPiAjFjNiCpAjAnNjCoIiBeC_xHqqkZx_
				(*iChar).m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				(*iChar).m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				break;
			case FDRCH_CONTINUE:
				(*iChar).m_mmfWidth = 0.0;
				(*iChar).m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				(*iChar).m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				break;
			case WCH_TAB:	// _xZkqqHx_iDfOiDhFiBeC_xHqqkZx_
			case WCH_SPC:	// _xZkqqHx_iLpDjEjCiBeC_xHqqkZx_
				// _xZkqqHx_iLpDjEjCiCmMjFfHiPiAjFjNiCpAiOoGjDlOiBjFjAnNjCoIiBeCiDfOiDhFiCmMiPoKiNiHiCmNiJlMjAnNjCoIiBeC_xHqqkZx_
				(*iChar).m_mmfWidth = g_pEnv->GetSFontRec((*iChar).m_foidFont)->GetStdSpaceWidth();
				(*iChar).m_mmfAbcA = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcA_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				(*iChar).m_mmfAbcC = 0.0;		// ABC_xZkqqHx_iNfMjBkCjBmMiCmM_xHqqkZx_abcC_xZkqqHx_iCmMjCgMiBeC_xHqqkZx_
				break;
			default:		// _xZkqqHx_jFlGiOjKiCmMiPoKiNiHiBeC_xHqqkZx_
			  {
				// _xZkqqHx_jFlGiOjKjFjNjDjJiCmMiMhGiOfKjHhAiCmJ_xHqqkZx_Zoom_xZkqqHx_iCpAiCfFiCfDjEhLiCmJjAnNjCoIiClHiCoJiBeC_xHqqkZx_
				const FCAutoBackup<double> backupZoom(g_->dZoom, g_->dDisplayPPM * 64);
				//----- _xZkqqHx_iDhEiDeIiDjDiDgHiCkKjFmPiCoNiCmBiClNiPoKiNiHiCmMiPiIjHjN_xHqqkZx_ -----
				if ((*iChar).m_foidFont != foidCurFont || wCurOffset != (*iChar).m_wOffset)
				{
					// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiDhEiDeIiDjDiDgHiCpAjFmPiNfIiBeC_xHqqkZx_
					foidCurFont = (*iChar).m_foidFont;
					// _xZkqqHx_iMlLiNnNjAnNjCoIjCiGiCmMiPoDiJlKiDeJiDhEiDfKiDgCiDgHiBeC_xHqqkZx_
					wCurOffset = (*iChar).m_wOffset;
					// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAiNoMjAkMiBeC_xHqqkZx_
					LOGFONT logFont;
					g_pEnv->GetSFontRec(foidCurFont)->ReqInit(logFont, 0.0, wCurOffset);
					// _xZkqqHx_iDfCiBfLiDgIiDhJiBfLiDfHiCpAiOoGjDlOiBeC_xHqqkZx_
					wCurCodePage = ::CharSetToCodePage(logFont.lfCharSet);
					atDC.SetFont(&logFont);					// _xZkqqHx_jAfGiClFiCkCiDhEiDeIiDjDiDgHiCpAjAnNjCoIiBeC_xHqqkZx_
				}
				//----- _xZkqqHx_jFlGiOjKiBgJiDfCiBfLiDgI_xHqqkZx_m_wChar_xZkqqHx_iBgKiCmMjFjNiCpAiOoGjDlO_xHqqkZx_ -----
				ABC abc;
				// _xZkqqHx_iDfCiBfLiDgIiDhJiBfLiDfHiCpAjAnNjCoIiClFiCmIiCkCiCmGiBeBiDfOiDeDiMoKiCmIiCmHiCmFjFlGiOjKjFjNiCkKjAlDiClFiCkNiOfKiPgPiClDiCoKiCmIiCkCiBeC_xHqqkZx_
				atDC.GetCharABCWidth((*iChar).m_wChar, abc, wCurCodePage);
				(*iChar).m_mmfWidth = fmmetol(lg2mm(abc.abcA + abc.abcB + abc.abcC));
				(*iChar).m_mmfAbcA = fmmetol(lg2mm(abc.abcA));
				(*iChar).m_mmfAbcC = fmmetol(lg2mm(abc.abcC));
			  }
			}
		}
	}
} // CFCWndRichEdit::CalcCharWidthAll.

