Posts: 1,769
Threads: 410
Joined: Feb 2003
I have an osd on my monitor at the top that gives me time and date-day and unready email count; but sometimes it's in the way. I'd like to click it to make it move or dive to the bottom of the zorder for about 3 seconds. is this possible?
Posts: 12,140
Threads: 142
Joined: Dec 2002
Macro
Macro2816
OnScreenDisplay "WWWWWWWW" 30 0 0 "" 0 0 1 "QM time email etc"
Check 'filter-function' in Properties.
Function
hide_osd
Trigger
#L 0x1 /QM /hide_osd
;/
function# iid FILTER&f
if(!wintest(f.hwnd "QM time email etc" "QM_OSD_Class")) ret -2
mac "sub.Move" "" f.hwnd
ret -1
err+
#sub Move
function hwnd
;outw hwnd
hid hwnd
3
hid- hwnd
err+
Posts: 1,769
Threads: 410
Joined: Feb 2003
Works great! my macro does update it every second or so, so it's not staying down for very long. any ideas on maybe changing my macro to allow it?
Function
OSD_clock
_monitor=0
int w=win(" - [email protected] - Microsoft Outlook" "rctrl_renwnd32")
Acc a.Find(w "OUTLINEITEM" "Inbox*" "class=NetUIHWND" 0x1005)
str value=" "
#compile "__AudioMixer"
value=a.Value
err+
str s
int z
rep
,AudioMixer x
,s.time("%X %d - %a")
,s.from(" " s " ")
,err-
,w=win(" - [email protected] - Microsoft Outlook" "rctrl_renwnd32")
,a.Find(w "OUTLINEITEM" "Inbox*" "class=NetUIHWND" 0x1005)
,value=a.Value
,err+
,,value="Outlook not connected"
,if len(value)>0
,,value.replacerx(" unread message.*" "")
,s.from(s " " value)
,z=x.GetMute
,if z=1
,,s.from(s " Ѭ" )
,else
,,s.findreplace(" Ѭ" "")
,OnScreenDisplay_Rd s -1 675 -2 "Copperplate Gothic Bold" 14 0x00ffff 25|0x8000 "tim4924" 0x343434
,0.1
Posts: 12,140
Threads: 142
Joined: Dec 2002
Find window win("QM time email etc" "QM_OSD_Class") and don't call OnScreenDisplay if it exists and is hidden.
Posts: 1,769
Threads: 410
Joined: Feb 2003
That is a thing of beauty.
thanks!