//--------------------------------------------------------------------------
        //  オプションに対応する時の手順
        //  1. 既定値
        //     TerminalState の初期化子に既定値を設定する。
        //  2. 処理
        //     RosaTerminal に、そのオプションを使用した処理を書く。
        //  3. 変化の通知
        //     値が変化した瞬間に、何らかの処理をする必要があるオプションについては、
        //     変化の通知を行う。具体的には、
        //     1. 先ず、Terminal 側に変化の通知を受け取る為の関数 (internal) を定義し、
        //     2. 次に TerminalState のプロパティに、その関数の呼出を追加する。
        //     3. DEC なら RestoreDec にも値の変更を明示的に書く。
        //--------------------------------------------------------------------------
        private TerminalState(TerminalState state)
        {
            this.term = state.term;

            //this.vdec1=state.vdec1;
            //this.vdecX=state.vdecX;
            this.bits = (System.Collections.BitArray)state.bits.Clone();
        }
        internal TerminalState(RosaTerminal term)
        {
            this.term = term;
            this.bits = new System.Collections.BitArray((int)DecsetBitIndex.COUNT);

            this.emuterm = TerminalType.Cygwin;
            this.SmIrm   = false;
            this.DecAwm  = true;
            this.DecNkm  = false;
            this.DecTcem = true;
            this.DecOm   = false;
        }