{"id":465,"date":"2014-03-12T01:32:39","date_gmt":"2014-03-12T06:32:39","guid":{"rendered":"http:\/\/sunapi386.ca\/wordpress\/?p=465"},"modified":"2015-10-28T03:09:06","modified_gmt":"2015-10-28T08:09:06","slug":"xmonad-regaining-focus-intellij","status":"publish","type":"post","link":"https:\/\/sunapi386.ca\/wordpress\/xmonad-regaining-focus-intellij\/","title":{"rendered":"Xmonad not regaining focus for IntelliJ"},"content":{"rendered":"<p>When using GUIs designed with Java Swing, like IntelliJ Idea, the once the focus changes it is lost and cannot be regained. I.e. you can&#8217;t type again.<\/p>\n<p>In <code>xmonad.hs<\/code> you need to add these:<br \/>\n<code><br \/>\nimport XMonad.Hooks.SetWMName<br \/>\nimport XMonad.Hooks.ICCCMFocus<br \/>\n...<br \/>\nsetWMName \"LG3D\"<br \/>\n...<br \/>\nlogHook = takeTopFocus <+> dynamicLogWithPP xmobarPP {<br \/>\n<\/code><\/p>\n<p>Refer to my <a><\/href=\"https:\/\/github.com\/sunapi386\/xmonad-ubuntu-conf\">xmonad on github<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When using GUIs designed with Java Swing, like IntelliJ Idea, the once the focus changes it is lost and cannot be regained. I.e. you can&#8217;t type again. In xmonad.hs you need to add these: import XMonad.Hooks.SetWMName import XMonad.Hooks.ICCCMFocus &#8230; setWMName &#8220;LG3D&#8221; &#8230; logHook = takeTopFocus dynamicLogWithPP xmobarPP { Refer to my xmonad on github.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-465","post","type-post","status-publish","format-standard","hentry","category-academica"],"_links":{"self":[{"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/posts\/465","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/comments?post=465"}],"version-history":[{"count":1,"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/posts\/465\/revisions"}],"predecessor-version":[{"id":466,"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/posts\/465\/revisions\/466"}],"wp:attachment":[{"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/media?parent=465"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/categories?post=465"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sunapi386.ca\/wordpress\/wp-json\/wp\/v2\/tags?post=465"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}