Active window switching oddity with multiple workspaces and applications in full screen mode - ubuntu-16.04

In Ubuntu 16.04 with workspaces enabled I'm having trouble getting applications switcher/workspaces to behave in a friendly manner if some windows are in full screen mode.
Say I have two workspaces A and B.
A has two windows open: browser and terminal 1 in full screen mode.
B has one window open: another terminal 2 in full screen mode.
I leave workspace A with browser window being active and move to workspace B to work in a terminal 2.
Then I move back to A but end up in a state where (1) no particular window is active, (2) terminal 1 is at the foreground, NOT the browser.
Then I need to either Alt-Tab to make terminal 1 active or click in it, and Alt-Tab to get back to the browser.
This does not seem to be the property of the application switcher --- I've tried the default plugin one, "applications switcher" and "static application switcher" with no luck.
The problem does not occur if applications are not in full screen mode --- if they are in maximized state everything is fine.

Related

How to get editors restored when reopening a closed VS Code window?

I am using VSCode on my Mac (Latest version) and when I hit the "Red X" on the top left of VSCode it closes my entire workspace and open editors. I want it to just close the window out of my view but keep everything open when I re-open the app (it is still running as it still has the white dot below).. I am getting the welcome page everytime I just "close window" and re-open.
Now if I were to two click and hit Quit, then yes, I'd expect my workspace and editors to all close and get the startup menu on re-opening.
I have tried searching in the settings and cannot find anything.
GUI Red X - VSCODE
Example. When playing music on iTunes and press the "RedX" on the GUI music keeps playing and everything opens as it was when it was closed. Thatis what I am trying to acheive on VSCode. Keep my "sandbox" and open files as is when pressing it..
To VS Code, I'm pretty sure that red x button and quit are the same thing (although it may be possible for it to treat them differently). Ie. I'm not aware of a way that you can get different behaviour for the red x button and the application quit action.
As for choosing whether the previous workspace should be reopened automatically, you can use the window.restoreWindows setting.
Controls how windows are being reopened after starting for the first time. This setting has no effect when the application is already running.
The values to choose from and their descriptions at the time of this writing are:
value
description
"all"(default value)
Reopen all windows unless a folder, workspace or file is opened (e.g. from the command line).
"folders"
Reopen all windows that had folders or workspaces opened unless a folder, workspace or file is opened (e.g. from the command line).
"none"
Never reopen a window. Unless a folder or workspace is opened (e.g. from the command line), an empty window will appear.
"one"
Reopen the last active window unless a folder, workspace or file is opened (e.g. from the command line).
"preserve"
Always reopen all windows. If a folder or workspace is opened (e.g. from the command line) it opens as a new window unless it was opened before. If files are opened they will open in one of the restored windows.
If you want open editors to be remembered and the previous workspace to be reopened automatically when you reopen VS Code,
You may also want to set something for the workbench.startupEditor setting, such as:
"workbench.startupEditor": "welcomePage", // or "none" or "newUntitledFile"
Also, loosely related is the "workbench.editor.restoreViewState setting, but the default value is true, so you only need to touch it if you don't want view state info like scroll position to be resotred on reopening closed editors.

Chrome dev tools upper console automatically closes bottom console/cannot move to bottom/top

I have somehow managed, that my console tab is locked in Chrome dev tools and I am not able to open console in top windows simultaneously with bottom console. It automatically collapses the opposite console tab and I cannot even right click and move to bottom/top.
I think, I used some shortcut accidentally, but cannot find how to reverse this behavior.

Import/export Chrome devtools breakpoints & settings between computers

Quoting the original idea:
I came across a problem where I need to share all my debugger breakpoints to my colleague to debug the issue at his end. So thought of implementing something like export the debugger points from one system and import at other system.
Since devtools doesn't provide a built-in import/export feature, is there another way?
Use devtools-on-devtools:
open devtools and switch its Dock side in the menu to a detached (floating) window
in the now detached devtools press CtrlShifti or ⌘⌥i on MacOS,
which will open devtools-on-devtools in a new window
UI method:
in this new window switch to Application tab, expand Local Storage, then devtools://devtools on the left
double-click breakpoints value on the right and copypaste it
Now do the same on the target computer and reopen the main devtools window afterwards.
Console method (especially useful if the value is too long):
run copy(localStorage.breakpoints) in devtools-on-devtools console on the source computer to copy the value to clipboard
run localStorage.breakpoints=prompt() on the target computer
(the prompt will appear in the main devtools window).
Console method to export everything:
run copy(JSON.stringify(localStorage)) in devtools-on-devtools console on the source computer to copy the value to clipboard
run Object.assign(localStorage, JSON.parse(prompt())) on the target computer
(the prompt will appear in the main devtools window).
P.S. Next time you can quickly toggle the detached state of devtools by pressing CtrlShiftD

Is there a way to open Chrome Dev tools to a new window right away?

Anyone know of a way to open Chrome Dev tools to a new window upon open?
I know that I can click F12 and then click the 'customize' button and change orientation or pop out the dev tools window. But that's an extra step, and often a window resize is necessary, and when you do it 50 times a day, it gets to be tedious.
Also, sometimes, on pages I'm testing, pressing F12 will change the layout of the elements on the page and even popping out the dev tools leaves the page layout different than before I opened dev tools. This can make it hard to tell if an element is visible or not, which makes troubleshooting Webdriver more difficult.
Ideally, CTRL+F12 or something to open dev tools as a separate window would be super handy. (to any Chromium devs that might be listening ;) But if anyone has another solution, I'd love to hear it.
If you have your DevTools un-docked, the dock mode, size and position of your DevTools window will remain the same as you previously set it. For example, I just set mine to be maximised on my other monitor. Every time I open up DevTools, it's an un-docked, maximised window, and there's no change to the layout of the inspected window other than the fact it's no longer in focus.
You could alternatively launch Chrome using the --auto-open-devtools-for-tabs flag, which will automatically open DevTools in the dock mode, size and position you had it previously. You can use:
Mac:/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --auto-open-devtools-for-tabs
Windows: "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --auto-open-devtools-for-tabs
In WebDriver, you can set flags for how Chrome opens. However, after looking into this further, it turns out Chrome currently do not support multiple clients connected to the protocol simultaneously.
As for speeding things up, you can switch between dock positions with Cmd+Shift+D (Mac) or Ctrl+Shift+D (Windows). This toggles between the last two modes you have used, so say you have it docked at the bottom, you then pop it out, using the shortcut now will toggle between the two.
Here's how you do it. On opening the developer tools, with the developer tools window in focus, press F1. This will open a settings page. Check the "Auto-open DevTools for popups".
Originally documented here -- https://newbedev.com/automatically-open-chrome-developer-tools-when-new-tab-new-window-is-opened.

Open Chrome Developer Tools tabs in a new window to show on multiple monitors

Is there a way where one can open a specific tab of the Chrome Developer Tools in a separate window? I have got 3 monitors and would like to have the Sources tab on one screen and the Elements on another screen. Is this possible?
I find this limitation frustrating too, all those other monitors are wasted! Here is poor man's solution:
launch your chrome with --remote-debugging-port=9999 command line parameter
right click on your page to debug and select 'Inspect Element' - this is your debug window #1
open a separate chrome window and navigate to chrome://inspect
click 'Configure...' and add localhost:9999
within a couple of seconds under 'Remote Targets' you should see tabs you can inspect from your other chrome instance
click on the tab, and now this is your debug window #2
Unrelated tip: system wide nightmode experience: http://danielsokolowski.blogspot.com/2018/11/windows-10-8-7-night-mode.html