{"id":127,"date":"2007-05-12T14:41:56","date_gmt":"2007-05-12T12:41:56","guid":{"rendered":" http:\/\/www.nsonic.de\/blog\/2007\/05\/dragging-a-form-with-no-titlebar\/"},"modified":"2007-05-12T14:41:57","modified_gmt":"2007-05-12T12:41:57","slug":"dragging-a-form-with-no-titlebar","status":"publish","type":"post","link":"https:\/\/www.nsonic.de\/blog\/2007\/05\/dragging-a-form-with-no-titlebar\/","title":{"rendered":"Dragging a form with no titlebar"},"content":{"rendered":"<p>[code lang=&#8221;delphi&#8221;]\/\/ Declare the procedure<br \/>\nprocedure WMCHitTest(var msg : TMessage); message WM_NCHITTEST;<\/p>\n<p>procedure TForm1.WMCHitTest(var msg : TMessage);<br \/>\nbegin<br \/>\ninherited;<br \/>\n\/\/ If the client (form) recieved a &#8220;mousedown&#8221; event<br \/>\n\/\/ then we process it and let Windows think we<br \/>\n\/\/ clicked on the titlebar.<br \/>\n  If msg.Result = htClient Then<br \/>\n     msg.Result := htCaption;<br \/>\nend;<br \/>\n[\/code]<\/p>\n<p>[tags]Delphi, Forms[\/tags]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>[code lang=&#8221;delphi&#8221;]\/\/ Declare the procedure procedure WMCHitTest(var msg : TMessage); message WM_NCHITTEST; procedure TForm1.WMCHitTest(var msg : TMessage); begin inherited; \/\/ If the client&hellip;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"spay_email":""},"categories":[11],"tags":[75,100],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p71Tml-23","_links":{"self":[{"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/posts\/127"}],"collection":[{"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/comments?post=127"}],"version-history":[{"count":0,"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/posts\/127\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/media?parent=127"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/categories?post=127"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.nsonic.de\/blog\/wp-json\/wp\/v2\/tags?post=127"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}