When I choose View>Fullscreen in Purr Data on OS X Yosemite my patch goes all the way to all four edges of the screen, but in Raspbian on a Pi3 the File-Edit menubar options stay across the top when I choose View>Fullscreen. Is there any way of hiding that and getting my patch to dominate the whole screen?
-
Fullscreen/Menubar in Purr Data, no GEM
-
@itcoil Unfortunately that is a bit tricky. If I remember correctly, OSX behavior is actually to reveal the menu when you mouse up to the top of the screen.
I could temporarily remove the menu on the other platforms when full-screen mode is chosen, but then it wouldn't show back up when you mouse to the top. Implementing the "autohide" functionality is probably doable but a bit tricky to get right.
Gem does not currently ship with Purr Data on OSX atm.
-
@jancsika My goal is to be able to use all 800 x 480 pixels for the GUI patch I'm creating with Purr Data on a Pi3 with 5" HDMI touchscreen. That strip across the top (the menubar) is valuable real estate that I can't currently use, and also, the menubar options will be irrelevant to the final functionality of the patch. Everything else is going very well functionality-wise. Is there any message I could send to the window or to pd or any other technique to hide the menubar or cover it? It'd be useful to be able to toggle the menubar on and off during development. I could deal with just hiding or covering it if that were the only option though.
-
@itcoil Maybe........ https://stackoverflow.com/questions/5973371/setting-window-styles-with-tkinter-tcl-no-exit-button
or
https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=69010root.overrideredirect(True)
or False to reinstate.
David. -
Try this:
- Click "Help" and choose "Show DevTools".
- In the DevTools window click "Console" to show the console.
- Paste the following:
myWin = nw.Window.get(); myMenu = myWin.menu; myWin.menu = null;
At least on Windows that removes the window menu from the view while all its various shortcuts remain active.
-
Thanks, guys! @jancsika Your approach is exactly what I was looking for, and it works on Raspbian.
Slight follow up:- Can I get that code to execute automatically somehow as a script instead of typing it into the DevTools Console every time?
- Is there a similar method to remove the side and bottom scrollbars?
-
- Can I get that code to execute automatically somehow as a script instead of typing it into the DevTools Console every time?
I don't have a way to do that atm. If you're in a pitch you could paste it into /usr/lib/pd-l2ork/bin/pd_canvas.js and wrap it in a timed callback. Here's a very untested hack:
var toggleMenu = (function(myWin) { var myMenu = myWin.menu; return function() { myWin.menu = myWin.menu ? null : myMenu; }; }(nw.Window.get())); setTimeout(toggleMenu, 1000);
- Is there a similar method to remove the side and bottom scrollbars?
Another hack to add to the ones above:
setTimeout(function() { document.body.style.overflow = "hidden"; }, 1000);