Posts: 1,271
Threads: 399
Joined: Mar 2003
can be easy done when you know the hwnd of your window.
SetWinStyle hwnd WS_CAPTION 2
but then the window can't be moved anymore. so how to i tell the attached toolbar that it should also
move hwnd?
Posts: 12,073
Threads: 140
Joined: Dec 2002
Toolbar
tb move owner
Trigger
!a"- Notepad" "Notepad"
Function
tb_move_owner
;/
function# hWnd message wParam lParam
sel message
,case WM_INITDIALOG ;;note: in QM < 2.2.0, this message is not sent. Use WM_CREATE instead.
,
,case WM_DESTROY
,
,case WM_MOVE
,RECT r; GetWindowRect hWnd &r
,int ho=GetToolbarOwner(hWnd)
,mov r.left r.bottom ho
,
,;;or this
,;case WM_WINDOWPOSCHANGED
,;WINDOWPOS* wp=+lParam
,;if(wp.flags&SWP_NOMOVE) ret
,;RECT r; GetWindowRect hWnd &r
,;int ho=GetToolbarOwner(hWnd)
,;mov r.left r.bottom ho
This is little tested. Need to test how works when the window is max, min, etc. If window disappears sometimes, try to uncheck "Follow Owner" in tb menu.