Autoit Gui maximize und noch etwas...

03/24/2010 20:07 Nico001#16
GEIL DICKES FETTES THX
~THX~
jetzt muss ich nurnoch das so hinbekommen das er unten an der ecke ist also die maus unten an dem gui
03/24/2010 22:15 93lucas#17
PHP Code:
$Gui GUICreate ("hi",100,100,100,100
GUISetState (@SW_SHOW
while 

$pos 
MouseGetPos() 
WinMove ("hi","",$pos[0]-100,$pos[1]-100)  ;Man muss die y Koords noch anpassen vom jeweiligen betriebssystem da der obere balken eine verschieden große höhe hat
WEnd 
also bei mir (xp) wäre es dann so

PHP Code:
WinMove ("hi","",$pos[0]-105,$pos[1]-130
03/25/2010 07:30 Nico001#18
Jo thx und wie kann ich butonns moven also auch an der Maus ???
03/25/2010 07:54 93lucas#19
ja kannst bin grad psp deswegen kann ich dir den befehl ned sagen aber gib einfach ma gui in die hilfe datei ein
03/25/2010 08:12 Nico001#20
da sind soo viele themen kannst du mir noch ein anhaltspunkt geben pls?
03/25/2010 08:27 93lucas#21
wahrscheinlich was mit move und ich glaub ohne ctrl
Edit: doch mit ctrl
guictrlgetpos
03/25/2010 09:04 Nico001#22
ok thx mein code sieht so aus funktioniert aber net wirklich:


#include <GuiConstantsEx.au3>
#include <GuiReBar.au3>
#include <GuiToolBar.au3>
#include <GuiComboBox.au3>
#include <WindowsConstants.au3>
#include <Constants.au3>
#include <Misc.au3>



HotKeySet("{ESC}","ex")
HotKeySet("{F1}","st")
HotKeySet("{F2}","st2")


$Gui = GUICreate ("hi",150,150,150,150,BitOR($WS_MINIMIZEBOX, $WS_CAPTION, $WS_POPUP, $WS_SYSMENU,$WS_SIZEBOX))
$button = GUICtrlCreateButton("TEST",50,50,50,50)
GUISetState (@SW_SHOW)

$stand = 1

while 1
If $stand = 1 Then
$pos = MouseGetPos()
WinMove ("hi","",$pos[0],$pos[1])
EndIf
If $stand = 2 Then
$pos = MouseGetPos()
$go = GUICtrlSetPos($button,$pos[0],$pos[1])
$coords = WinGetPos($Gui)
_MouseTrap($coords[0], $coords[1], $coords[0] + $coords[2], $coords[1] + $coords[3])

EndIf
WEnd

Func ex()
Exit
EndFunc

Func st()
$stand = 2
EndFunc

Func st2()
$stand = 3
EndFunc

kannst du den nachher mal anguken und verbessern pls
03/25/2010 09:40 93lucas#23
was geht da ned? kommt ne Fehlermeldung?
03/25/2010 09:44 Nico001#24
also ne hab es noch alleine hinbekommen bekommst noch n thx
und noch n thx wenn du mir sagen könntest wie ich jetzt die koordinaten des buttons im gui durch eine msgbox gesagt bekomme


EDIT:
Habe es herausgefunden xD
03/25/2010 10:19 93lucas#25
also keine fragen mehr or?
03/25/2010 10:41 Nico001#26
mmh momentan nicht aber wenn ich welche habe kann ich die dir dann per pn schreiben ?
03/25/2010 11:21 93lucas#27
jo ok