
function initPreferenceMini(){
    // 初期設定ペーンを開く
    var elm = document.getElementById("base");
    elm.innerHTML = "";
    
    // HEADER
    var div = newDIV(elm, "/yellow-header");
    var tbl = newTABLE(div, "/base-table");
    var tr = newTR(tbl, "", "");
    // --- LEFT SIDE ---
    var td = newTD(tr, "/left-side", "");
    // TITLE
    var sp = newSPAN(td, "");
    sp.innerHTML = "初期設定";
    sp.style.fontSize = "10pt";
    // --- RIGHT SIDE ---
    // HELP ICON
    var td = newTD(tr, "/right-side", "");
    td.style.paddingRight = "20px";
    // HELP ICON
    var img = newIMAGE(td, "", "./help.png", "?");
    img.style.height = "17px";
    img.setAttribute("onclick", "openHelp('preferenceHelp.html')");
    img.setAttribute("class", "expandIcon");
    
    // BODY
    var dv = newDIV(elm, "/yellow-body");
    dv.style.fontSize = "10pt";
    
    ///// 画面表示 ===============================
    makeSubTitle(dv, "カルテ画面表示");
    // 水平・垂直 画面型式
    var dv2 = newDIV(dv, "");
    dv2.style.marginTop = "5px";
    dv2.style.marginLeft = "10px";
    var sp = newSPAN(dv2, "");
    sp.innerHTML = "画面のレイアウト型式 ";
    var styles = ["","水平","垂直"];
    var pu = newPopupMenu(dv2, "", styles, frameStyle());
    pu.setAttribute("onchange", "setFrameStyle(this)");
    makeLine(dv, "診療待ち黄色タグをポップアップしない", noCheckWaiting(), "setNoCheckWaiting(this)");
    // OMIT CHECK BOX： setOmitStatus(）は localStorage.js
    makeLine(dv, "黄色タグからカルテを別ウインドーで開く", openEachNOA(), "setOpenEachNOA(this)");
    // スクロール範囲
    var dv2 = newDIV(dv, "");
    dv2.style.marginTop = "5px";
    dv2.style.marginLeft = "10px";
    var fd = newFIELD(dv2, "overFlowF", "カルテ画面のスクロール範囲を ", 3, overFlowHeight());
    fd.setAttribute("onchange", "setOverFlowHeight(this)");
    var sp = newSPAN(dv2, "");
    sp.style.paddingLeft = "5px";
    sp.innerHTML = "px に限定";
    // カルテのフォント・サイズ
    var dv2 = newDIV(dv, "");
    dv2.style.marginTop = "5px";
    dv2.style.marginLeft = "10px";
    var fd = newFIELD(dv2, "overFlowF", "カルテのフォント・サイズを ", 3, cellFontSize());
    fd.setAttribute("onchange", "setCellFontSize(this)");
    var sp = newSPAN(dv2, "");
    sp.style.paddingLeft = "5px";
    sp.innerHTML = "pt に限定";
    // サムネイル・サイズ
    var dv2 = newDIV(dv, "");
    dv2.style.marginTop = "5px";
    dv2.style.marginLeft = "10px";
    var sp = newSPAN(dv2, "");
    sp.innerHTML = "カルテに貼るサムネイル・サイズ ";
    var size = thumbNailSize();
    var pu = newPopupMenu(dv2, "", thumbNailLabels(), thumbNailLabel(size));
    pu.setAttribute("onchange", "set_ThumbNailSize(this)");
    // PROBLEM LIST
    // OMIT CHECK BOX： showProblem(）は localStorage.js
    makeLine(dv, "プロブレム・リストの自動表示せず", omitProblem(), "setOmitProblem(this)");

    ///// HELP =====================================
    makeSubTitle(dv, "NOA 立ち上げ時にヘルプを表示");
    // OMIT CHECK BOX： showHelp(）は localStorage.js
    makeLine(dv, "立ち上げ時のヘルプ表示せず", showHelp(), "setShowHelp(this)");
    
    // FOOTER
    var dv = newDIV(elm, "/yellow-footer");
    dv.innerHTML = "　";

    // iFrame なら toggleButton にツール名を表示
    var bt = tools().elmFor("toggleButton");
    if (bt) bt.innerHTML = "初期設定ツール";
   
    function makeSubTitle(elm, label){
        // サブタイトルを生成
        var dv = newDIV(elm, "");
        dv.style.paddingLeft = "10px";
        dv.style.backgroundColor = "#f7eeb8";
        dv.style.color = "brown";
        dv.style.borderRadius = "10px";
        dv.style.marginTop = "5px";
        dv.innerHTML = label;
    }
}

