找回密码
 加入
搜索
楼主: heroxianf

[GUI管理] 天空这种切换界面是如何实现的呢[已解决]

 火... [复制链接]
 楼主| 发表于 2016-4-21 09:16:02 | 显示全部楼层
回复 14# afan


    A大能提供一下数组储存按钮,和循环隐藏的的列子吗?
发表于 2016-4-21 09:19:17 | 显示全部楼层
本帖最后由 131738 于 2016-4-21 09:21 编辑
回复  131738


    TAB的话  光_GUICtrlTab_SetCurSel焦点了  但实际并未切换页面  必须_GUICtrlTab_C ...
afan 发表于 2016-4-21 02:06


应该是 GUICtrlSetState 选中吧, 我没做过, 但见过这样的脚本.........
 楼主| 发表于 2016-4-21 09:23:54 | 显示全部楼层
回复 17# 131738


    GUICtrlSetState($Tab1)    这样?
发表于 2016-4-21 09:35:26 | 显示全部楼层
回复  131738


    GUICtrlSetState($Tab1)    这样?
heroxianf 发表于 2016-4-21 09:23

这是外码的一个创建tab的语句 位置/大小全为 1
GUICtrlCreateTab(1, 1, 1, 1, $TCS_FOCUSNEVER)

  GUICtrlSetState($tab1, $GUI_SHOW)
发表于 2016-4-21 09:46:06 | 显示全部楼层
回复 18# heroxianf

關注中~~ 希望解決  可以有個簡單的範例 觀摩一下
发表于 2016-4-21 10:04:31 | 显示全部楼层
实用,信息量大的界面设计,收藏并关注.....
 楼主| 发表于 2016-4-21 10:46:21 | 显示全部楼层
回复 19# 131738

这写的乱七八糟的  指点一下哈
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <TabConstants.au3>
#include <WindowsConstants.au3>

Opt("GUIOnEventMode", 1)

#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 846, 452, 246, 132)
GUISetOnEvent($GUI_EVENT_CLOSE, "_exit")
$Button1 = GUICtrlCreateButton("显示1", 16, 96, 75, 25)
GUICtrlSetOnEvent($Button1, "test")
$Button2 = GUICtrlCreateButton("返回", 16, 136, 75, 25)
GUICtrlSetOnEvent($Button2, "fanhui")
$Tab1 = GUICtrlCreateTab(160, 16, 673, 417)
GUICtrlCreateTabItem("")
$Label1 = GUICtrlCreateLabel("Label1", 288, 112, 412, 17)
$Button3 = GUICtrlCreateButton("界面1", 288, 136, 75, 25)
GUICtrlSetOnEvent($Button3, "jiemian1")
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
        Sleep(100)
WEnd

Func test()
        GUICtrlCreateTab(1, 1, 1, 1, $TCS_FOCUSNEVER)
        $Label2 = GUICtrlCreateLabel("Label2", 288, 112, 412, 17)
        $Button4 = GUICtrlCreateButton("界面2", 288, 136, 75, 25)
    GUICtrlSetOnEvent($Button3, "jiemian2")
        GUICtrlSetState($Tab1, $GUI_SHOW)
EndFunc   ;==>test

Func fanhui()
        GUICtrlCreateTab(1, 1, 1, 1, $TCS_FOCUSNEVER)
        GUICtrlSetState($Tab1, $GUI_SHOW)
EndFunc   ;==>test

Func jiemian1()
MsgBox(0, "", "界面1")
EndFunc   ;==>test

Func jiemian2()
MsgBox(0, "", "界面2")
EndFunc   ;==>test

Func _exit()
        Exit
EndFunc   ;==>_exit
发表于 2016-4-21 10:59:20 | 显示全部楼层
水木子版主有这么漂亮的界面,楼主你看不到么。。。
http://www.autoitx.com/forum.php ... 7366&highlight=
http://www.autoitx.com/forum.php ... 9035&highlight=
发表于 2016-4-21 11:17:17 | 显示全部楼层
水木子版主有这么漂亮的界面,楼主你看不到么。。。
haijie1223 发表于 2016-4-21 10:59



    木子的不错,但LZ提到的我觉得更符合该软件严谨的风格和内容。
发表于 2016-4-21 11:44:38 | 显示全部楼层
回复  131738

这写的乱七八糟的  指点一下哈
heroxianf 发表于 2016-4-21 10:46



     不要在触发的时候再 GUICtrlCreateTab 创建标签,应该先将界面内的所有标签及相应内容都创建好。触发时只是切换而已。
 楼主| 发表于 2016-4-21 11:48:33 | 显示全部楼层
回复 24# afan


    A大 你这是在夸我呢?
 楼主| 发表于 2016-4-21 11:48:51 | 显示全部楼层
回复 23# haijie1223

就是整的太漂亮了  一时半会消化不了啊~
发表于 2016-4-21 12:24:40 | 显示全部楼层
回复 1# heroxianf
GUICtrlCreateTreeView与GUICtrlCreateList







本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?加入

×
 楼主| 发表于 2016-4-21 13:42:59 | 显示全部楼层
回复 28# chzj589


    这个可以有  了解一下卡看。
发表于 2016-4-21 13:52:19 | 显示全部楼层
回复 29# heroxianf
说错了。是GUICtrlCreateTreeView与子窗口
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-5-17 02:38 , Processed in 0.073910 second(s), 14 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表