Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


make full-screen! work on mac #85

wants to merge 1 commit into from

2 participants


Hi Dave,

I found I needed to add this code to make seesaw.core/full-screen! work properly on the mac. I believe this should also work fine on Windows.



hmmm. So was the problem that if the window isn't already undecorated, full-screen! fails? The reason I ask is that I only ever tested full screen on Mac, so it at least works for me. I'm a little hesitant to assume that full screen automatically strips decorations or puts them back. For example, if you wanted your window to always be undecorated, this change would break that I think. Maybe we need functions for decorating/undecorating windows and then make the docs for full screen clear that it only works with undecorated windows? Thoughts?


Yeah, that's an option. We could use seesaw.meta to remember the desired decoration state across calls. That seems like a reasonable compromise.


I created a more general fix based off your pull request. It's in 15e33bb. Give it a try and let me know if it helps.

@daveray daveray closed this

It works great! Thanks, Dave!



Cool! I'm always surprised when things work :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 2, 2012
  1. @arthuredelstein
This page is out of date. Refresh to see the latest.
Showing with 12 additions and 1 deletion.
  1. +12 −1 src/seesaw/core.clj
13 src/seesaw/core.clj
@@ -2673,7 +2673,18 @@
"Make the given window/frame full-screen. Pass nil to return all windows
to normal size."
([^java.awt.GraphicsDevice device window]
- (.setFullScreenWindow device (to-root window))
+ (if window
+ (let [root (to-root window)]
+ (when (not= (.getFullScreenWindow device) root)
+ (.dispose root)
+ (.setUndecorated root true)
+ (.setFullScreenWindow device root)
+ (.show root)))
+ (when-let [root (.getFullScreenWindow device)]
+ (.dispose root)
+ (.setFullScreenWindow device nil)
+ (.setUndecorated root false)
+ (.show root)))
(full-screen! (default-screen-device) window)))
Something went wrong with that request. Please try again.