/// <summary>
        /// シンボルをカタログに追加します.
        /// Add symbol to catalog.
        /// </summary>
        void AddSymbol(SymbolCatalog.SymbolStyle style)
        {
            // 新しいシンボルを作成します.
            // Create new symbol.
            SymbolCatalog.Symbol symbol = new SymbolCatalog.Symbol()
            {
                style = style
            };
            switch (style)
            {
            case SymbolCatalog.SymbolStyle.Symbol:
                symbol.name        = "SYMBOL_NAME";
                symbol.description = "symbol description(<i>ritch-text is available</i>)";
                break;

            case SymbolCatalog.SymbolStyle.Header:
                symbol.name = "Header(<i>ritch-text is available</i>)";
                break;

            case SymbolCatalog.SymbolStyle.Separator:
                break;
            }

            // シンボルをカタログに追加します.
            // Add symbol to catalog.
            catalog.list.Add(symbol);

            // シンボル名の編集にフォーカス.
            // Focus to input field.
            focus = string.Format("symbol neme {0}", catalog.list.IndexOf(symbol));

            EditorUtility.SetDirty(catalog);
        }
 /// <summary>
 /// シンボルをカタログに追加します.
 /// Add symbol to catalog.
 /// </summary>
 void RemoveSymbol(SymbolCatalog.Symbol symbol)
 {
     EditorApplication.delayCall += () =>
     {
         catalog.list.Remove(symbol);
         ro.index = Mathf.Clamp(ro.index, 0, catalog.list.Count - 1);
         EditorUtility.SetDirty(catalog);
         Repaint();
     };
 }
        /// <summary>
        /// ヘッダーを描画します.
        /// Draw header.
        /// </summary>
        /// <param name="rect">描画座標.</param>
        /// <param name="index">シンボルインデックス.</param>
        /// <param name="symbol">表示するシンボル.</param>
        void DrawHeader(Rect rect, SymbolCatalog.Symbol symbol)
        {
            int index = catalog.list.IndexOf(symbol);

            // シンボル名を描画します.
            // Draw symbol name(editable).
            GUI.contentColor = Color.black;
            string symbolNameId = string.Format("symbol neme {0}", index);

            GUI.SetNextControlName(symbolNameId);
            styleHeader.richText = GUI.GetNameOfFocusedControl() != symbolNameId;
            symbol.name          = GUI.TextField(new Rect(rect.x - 19, rect.y + rect.height - 24, rect.width + 23, 20), symbol.name, styleHeader);
            GUI.contentColor     = Color.white;
        }
        /// <summary>
        /// 通常シンボルを描画します.
        /// Draw default symbol.
        /// </summary>
        /// <param name="rect">描画座標.</param>
        /// <param name="index">シンボルインデックス.</param>
        /// <param name="symbol">表示するシンボル.</param>
        void DrawDefaultSymbol(Rect rect, SymbolCatalog.Symbol symbol)
        {
            int index = catalog.list.IndexOf(symbol);

            // シンボル説明を描画します.
            // Draw symbol description(editable).
            string symbolDescriptionId = string.Format("symbol desctription {0}", index);

            GUI.SetNextControlName(symbolDescriptionId);
            styleDescription.richText = GUI.GetNameOfFocusedControl() != symbolDescriptionId;
            symbol.description        = GUI.TextArea(new Rect(rect.x, rect.y + 12, rect.width, rect.height - 13), symbol.description, styleDescription);

            // 背景を描画します.
            // Draw symbol name background.
            GUI.color = symbol.enabled ? EnableStyleColor : DisableStyleColor;
            GUI.Label(new Rect(rect.x, rect.y, rect.width, 16), GUIContent.none, "ShurikenEffectBg");            //"flow node flow" + (int)symbol.style);
            GUI.color = Color.white;

            // トグルを描画します.
            // Draw toggle.
            symbol.enabled = GUI.Toggle(new Rect(rect.x + 5, rect.y, 15, 16), symbol.enabled, GUIContent.none);

            // シンボル名を描画します.
            // Draw symbol name(editable).
            string symbolNameId = string.Format("symbol neme {0}", index);

            GUI.SetNextControlName(symbolNameId);
            GUI.color           = symbol.enabled ? EnableTextColor : DisableTextColor;
            styleName.fontStyle = GUI.GetNameOfFocusedControl() != symbolNameId ? FontStyle.Bold : FontStyle.Normal;
            symbol.name         = GUI.TextField(new Rect(rect.x + 20, rect.y, rect.width - 40, 16), symbol.name, styleName);
            GUI.color           = Color.white;

            // シンボル削除ボタンを描画します.
            // Draw delete button.
            if (GUI.Button(new Rect(rect.x + rect.width - 20, rect.y, 20, 20), EditorGUIUtility.FindTexture("treeeditor.trash"), EditorStyles.label))
            {
                RemoveSymbol(symbol);
            }
        }
        /// <summary>
        /// シンボルを描画します.
        /// Draw symbol.
        /// </summary>
        void DrawSymbol(Rect rect, int index, bool isActive, bool isFocused)
        {
            SymbolCatalog.Symbol symbol = ro.list[index] as SymbolCatalog.Symbol;

            // シンボルスタイルに応じて描画します.
            // Draw symbol based on style.
            switch (symbol.style)
            {
            case SymbolCatalog.SymbolStyle.Symbol:
                DrawDefaultSymbol(rect, symbol);
                break;

            case SymbolCatalog.SymbolStyle.Separator:
                GUI.Label(new Rect(rect.x + 10, rect.y + 24, rect.width - 20, 16), GUIContent.none, "sv_iconselector_sep");
                break;

            case SymbolCatalog.SymbolStyle.Header:
                DrawHeader(rect, symbol);
                break;
            }

            GUI.color        = Color.white;
            GUI.contentColor = Color.white;
        }