Safari's dock icon includes right-click commands for "New Window" and "New Private Window" -- see screenshot.
Since Mozilla rather negligently left these shortcuts off of the Firefox dock icon, is there any way (i.e., via AppleScript?) to add the same commands to Firefox's icon in the dock?
Edit: It has come to my attention that, currently, both Firefox and Safari act identically in this matter. If either application is open, the "New Window" and "New Private Window" commands appear in its dock icon's context menu. When either Safari or Firefox is closed, no such commands can be seen. This may be an across-the-board restriction in macOS regarding what commands may be seen when Command-Clicking on pinned icons in the dock for applications that are not running. If so, it's a pity; in Windows, if Firefox is pinned to the taskbar, these commands are always available via right-clicking whether Firefox is open or closed.
Not without modifying the Firefox application itself. (Good luck… it's a scary place in there.)
Dock menu items have to be created from native code running within an application. They can't be set by another process.
Applescript can do some interesting things in general, but it can only interact with existing functionality of an application (and even then, only with functionality that's explicitly been made scriptable). It can't add completely new features to an existing application.
Related
I've currently connected two monitors via a dock to my notebook.
When I'm running my console application, the console window always pops up on the first monitor. How can I change that it's automatically opened on another monitor, e.g. on monitor 3? Maybe there is a property I need to modify?
It's very annoying to always drag the console window onto the monitor on which my IDE is opened.
Console applications (unlike GUI applications) don't create their own window; that's done by Windows, and in the case when you're running in an already created console, then you kinda inherit, e.g., cmd's window.
What you can do, though, is to find your window and move it to a different monitor.
Another option is to change the window manager settings for that application in the properties of the console window under Layout. Especially the check box »Let system position window«. To do so, first move the window where you'd like it to appear, then open the properties, go to the Layout tab, and just click »OK«.
Is there a way to get vscode show navigation menu i.e Code|File|Edit|... and the project name in a full screen mode on MAC. It's almost impossible to see the name of the project when having multiple instances of code open in full screen mode.
v1.42 has a new option that may help:
Controls if native full-screen should be used on macOS.
Disable this option to prevent macOS from creating a new space when going full-screen.
"window.nativeFullScreen": true,
I believe this is not what the full screen mode is made for. If you go full screen you are supposed to work almost exclusively in that application (only occasionally switching to other apps like mail, e.g. via command+tab). You can always have the menu bar (and the window title) appear when you move the mouse pointer to the top of the screen, however.
The name of the project is visible in the file explorer.
In this example, the project name (i.e. root folder) is testgit
You can always quickly show the file explorer using the keyboard shortcut Shift-Cmd-E.
How do I dock the Browser Console window in Firefox?
The Browser Console currently opens in a separate window. I'd prefer for it to be docked to the bottom of the main window.
There's a similar question for Firebug.
There is no stock way to dock the Browser Console to a specific window. The Browser Console is for the entirety of the Firefox browser. What it shows is not limited to a single window. Thus, from a user interface point of view, it does not make sense to have it be docked to a single window.
It might be possible to create an add-on which opens an equivalent page that is in a bottom bar.
The best I could do was manually to dock Browser Console window and Firefox window in my desktop environment (Gnome on Fedora) so that they are both visible when debugging.
I don't know of any way with the built-in console. However, the 'Web Developer Extension' add-on console has toggles to dock to a window, but also several additional useful layouts.
I'm using PyCharm with multiple monitors on Mac OSX (10.10.5), normally you can drag windows off to a separate monitor. In PyCharm that works, but they (and in particular the Run window) snap back to the main monitor.
I've only seen this on the latest PyCharm 5 CE though its possible older versions also had the problem. I've searched all the settings and searched online, but can't find a setting that makes the window stay where it was placed.
Right click on the tab and select View Mode as Window.
Then you can move the window to another monitor.
It's crappy behaviour from the best python IDE out there.
There is a OSX solution but i'm not sure if you will like it:
You can enable old style multiple screen support again in OSX by going to System Preferences, Mission Control and uncheck "Displays have separate spaces". Now your floating windows will not snap back and you can even extend your PyCharm main window over the screens.
The downside of this solution is that you'll have the OSX dock and main menu only on your main monitor. I hope Jetbrains will fix this behaviour soon.
Another way to achieve what you want is to open multiple instances of the project. When you try to open the project for the second time you can choose "open project in new window". You can drag the new window to the second screen; it won't snap back to your primary monitor.
For Ubuntu and Windows users landing up here:
Press Shift + F4 or
Right-click and select 'Move Tab to New Window'
Drag the newly created window to the next screen
The best option is to detach an editor window and drag it to your second monitor.
I am building a Cocoa application that allows you to drag and drop files from a NSTableView to your computer. Personally, and I know I'm not alone, when I use applications like this I grab the files, invoke the "Show Desktop" hotkey which makes all my windows go away and then I drop the files on my Desktop.
However, if the files already exist on my Desktop, or wherever I'm dropping them, an Alert sheet comes up asking if I want to overwrite the files. But since I'm in Mission Control/Exposé "Show Desktop" mode, the sheet is floating in the middle of my Desktop instead of attached to my NSWindow...
Ideally, if my application has to show an alert sheet, while all the windows are offscreen, I would like to bring my window forward and out of this mode so the sheet is attached to it and not floating in the middle of my desktop but I cannot find much information on the subject. I've tried the standard makeKey and orderFront tactics but no dice. I've also looked into NSWindows setCollectionBehavior but none of these options seem applicable unless i just want my window to just always stay out and ignore this mode.
Does anyone know how to bring a NSWindow out of Exposé when in "Show Desktop" mode?