找回密码
 加入
搜索
查看: 2221|回复: 3

[GUI管理] 【已解决】请问怎样才能弄一个跟任务栏类似可以占用屏幕空间的界面?

[复制链接]
发表于 2013-9-1 01:13:41 | 显示全部楼层 |阅读模式
本帖最后由 yinui 于 2013-9-8 00:46 编辑

请问怎样才能弄一个跟任务栏类似可以占用屏幕空间的界面?
效果就像WIN的任务栏一样可以占用普通非置顶的窗口最大化时的空间,也就是通非置顶的窗口最大化时不是跟我这个界面层叠而是并排在一起。
发表于 2013-9-1 02:11:32 | 显示全部楼层
这个问题没有研究过.不过提供个思路大家研究下.
其实这个功能比较难实现的地方不是自身的状态.而是打开的其他窗体的位置.
可以尝试使用WinMove来尝试修改其他窗体的大小以及位置.



Example()

Func Example()
        ; Run Notepad
        Run("notepad.exe")

        ; Wait 10 seconds for the Notepad window to appear.
        Local $hWnd = WinWait("[CLASS:Notepad]", "", 10)

        ; Retrieve the position as well as the height and width of the Notepad window. We will use this when we have to move the window back to the original position.
        Local $aPos = WinGetPos($hWnd)

        ; Move the Notepad to the x, y position of 0, 0 and set the height and width at 200, 200.
        WinMove($hWnd, "", 0, 0, 200, 200)

        ; Wait for 2 seconds to display the new position of the Notepad window.
        Sleep(2000)

        ; Move the Notepad window back to the original position by using the array returned by WinGetPos.
        WinMove($hWnd, "", $aPos[0], $aPos[1], $aPos[2], $aPos[3])

        ; Wait for 2 seconds to display the original position of the Notepad window.
        Sleep(2000)

        ; Close the Notepad window using the handle returned by WinWait.
        WinClose($hWnd)
EndFunc   ;==>Example


不知道对你来讲是否可行.
请楼下大神指正.
发表于 2013-9-7 23:07:53 | 显示全部楼层
这个...没人回复的么?
 楼主| 发表于 2013-9-8 00:45:49 | 显示全部楼层
已经自己解决,先设置工作区域,然后再做个GUI遮住非工作区域就可以了
您需要登录后才可以回帖 登录 | 加入

本版积分规则

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

GMT+8, 2024-6-9 10:55 , Processed in 0.078276 second(s), 24 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

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