隐藏TAB控件表头

import win.ui;
/*DSG{{*/
var winform = ..win.form(text="AAuto Form";right=599;bottom=399;parent=...)
winform.add(
button={cls=
"button";text="切换到第二页";left=224;top=340;right=364;bottom=368;z=2};
tab={cls=
"tab";left=16;top=12;right=588;bottom=320;z=1}
)
/*}}*/

var page1 = winform.tab.add( mode="child";bottom=207;parent=...;right=427;text="AAuto Form" );
page1.add(
   button={ bottom=144;text=
"页面一";left=76;top=60;z=1;right=320;cls="button" }
);
var page2 = winform.tab.add( mode="child";bottom=207;parent=...;right=427;text="AAuto Form" );
page2.add(
   button={ bottom=154;text=
"页面二";left=86;top=70;z=1;right=330;cls="button" }
);

// 隐藏表头
winform.tab.modifyStyle(, 0x100|0x400|0x8000/*_TCS_BUTTONS|_TCS_FIXEDWIDTH|_TCS_FOCUSNEVER*/);
::SendMessageInt(winform.tab.hwnd, 0x1329
/*_TCM_SETITEMSIZE*/, 0, ::MAKELONG(0, 1));

winform.button.oncommand =
function(id,event){
   winform.tab.selIndex = 2;
}

winform.show();
win.loopMessage();



你可能感兴趣的:(tab控件)