Awesome WM wonky multi-monitor setup - awesome-wm

I have a 3-monitor setup, except that 1 of my monitors is attached to a KVM switch that I switch between my computers. It seems like when Awesome WM starts up without the 3rd monitor accessible to it, it refuses to recognize it from that point on until the next reboot (simply restarting Awesome WM doesn't work).
The odd thing is, xrandr is aware of the monitor, and I can even see my mouse pointer appear there when I move it into the 3rd monitor, but the rest of it is black. Dragging windows there makes them disappear and Awesome WM does not render anything on this screen until the reboot.
I'm assuming this has something to do with how Awesome recomputes the screen geometry available to it but I'm not sure how to force it to recompute it? I've already enabled both secondary monitors via a couple bash commands I use:
xrandr --output DP-2-2 --auto --right-of eDP-1
xrandr --output DP-2-1 --auto --right-of DP-2-2
When I run xrandr --current, it claims all 3 monitors are connected and shows correct resolution for each. I did some searching, but there isn't much help on this issue, I believe it's a similar issue to the one reported here: https://www.reddit.com/r/awesomewm/comments/6rhvp9/switching_monitor_setups
How do I get Awesome to redraw into the 3rd monitor and use it correctly? Also, how can I get Awesome to dynamically handle addition/removal of monitors (this is a laptop connected to a docking station)? I tried screenful, but that repo seems out of date and seems to do more harm than good for me, with monitor flickering if I start with multiple and then unplug from docking station.

If you have a compositor like compton running, try restarting it after turning on the screen with (x|a)randr and optionally refreshing awesome.

Related

Citrix mouse clicks off / not working High DPI / Scaling / Multiple Monitors

gonna answer my own question but this has to be more common and I didn't find anyone answering it. I connect to a lot of different clients running many backend versions of citrix and I try to keep my machine on the latest, resorting to VM's when i need a specific version (becoming more rare thankfully)
Anyway this latest issue I could use citrix light just fine but when i launched the ica file it would open and i could use the keyboard but i couldn't seemingly click things in the session and the i discovered upon closer examination that my mouse was offset when trying to click on UI elements in the session.
Resolution per this knowledge base article:
https://support.citrix.com/article/CTX230286
Was to set all monitors to the same scaling. I use 3 additional monitors to my surface laptop and the surface laptop defaults to 150% scaling and the others were 100%. I set my laptop to be 100% like the others and voila.
Things are really small on that screen now but i don't use it much and would much rather be able to run the citrix session properly on my other monitors.
Hope this is helpful.

Raspbian: javaFX Application is not waking up touchscree display after power safe

I played around with javaFX on a rPi 3 and the official 7" touchscreen. I know that javaFX is not using X11 when showing an application and there are some limitations after all (fullscreen mode, hide cursor, alt-C not workling by default).
But my main problem is the power safe of the touchscreen. After some minutes the display goes black and it is then impossible to reactivate it. Not by touching the screen, nor by clicking with a mouse or typing on a keyboard. It is not limited to my application, every simple hello World with a small UI has the same problem.
Has anybody an idea what to do?
I call my app simply by
sudo java -cp "./lib/myJar.jar" my.pack.Test
Is there some option or varaible that I maybe forgot to set?
Thank you and BR
Stefan

Hide mouse pointer on Chromium kiosk

Web application with xHTML UI is shown on self-service kiosk, using Chromium in fullscreen kiosk mode. As the kiosk display is intended only for visual feedback, there is no mouse/touchscreen connected.
While it's very easy to hide the mouse pointer via the CSS:
html { cursor: none; }
This approach has one essential problem - user MUST move mouse at least few pixels for pointer to disappear. As I mentioned above, this kiosk has no input methods, and, as a result, after UI is loaded, cursor is still visible right in the middle of screen for rest of the time.
I know that it's possible to simply set transparent cursor in OS options, but unfortunately few of these kiosks has already been shipped to clients, so we can only change the displayed HTML/CSS/JS content remotely, not access and configure the underlying OS itself.
Also I googled around and it seems that there is no way to move the mouse via the jQuery. Can anyone suggest how to deal with this problem?
You cant do this only via browser && CSS/JS (belive me, i tried).
For me solution was to install unclutter on the client:
sudo apt-get install unclutter
And turn cursor off, by adding to autostart
nano ~/.config/lxsession/LXDE/autostart
line:
#unclutter -idle 0.1
It will make your coursor disappear after not moving for 0.1s, so if you want to use mouse - you still can.
For those searching for a SO level solution:
I suggest using nano, so on terminal type sudo nano /etc/lightdm/lightdm.conf to edit this file and add this line below:
xserver-command=X -nocursor
Important: You must add this line after [Seat*] declaration.
Solution used in Raspbian linux distribution.

Keep QDialog on top of everything, even fullscreen applications?

On a project I work on, using Python3 + PySide, I try to print a popup-message as some sort of notification.
This popup needs to be on top of everything, this includes fullscreen applications like games or browsers. And that's the point that does not work. It works fine for all windows on my Desktop, normal windows, maximized, but as soon as there is a fullscreen application or a borderless window ("pseudo fullscreen") the popup is created, but "behind" the fullscreen app.
I already use self.setWindowFlags(QtCore.Qt.FramelessWindowHint | QtCore.Qt.WindowStaysOnTopHint) but this flag does get ignored by other fullscreen apps.
How do I fix this? Also without giving focus to the popup.
It is just there to present information, and it is not good when your window looses focus while playing a game.
My code can be found here: https://github.com/GosuSan/PyECM
additional Info:
- my project aims to be cross-platform, so I need a platform-independend solution
- I am running linux, without having a windows machine atm,
so I can't test stuff there.
If you need any more info, let me know!
Edit:
It seems that PySide.QtGui.QSystemTrayIcon.showMessage does what I want, it works on fullscreen as well as on borderless-windows. So I will try to either find out how those messages are displayed on top, or just use them, not sure for now.

Change browser to display retina or webkit-min-device-pixel-ratio: 2 [duplicate]

How can you simulate a retina display (HiDPI mode) in Mac OS X 10.8 Mountain Lion on a non-retina display?
Search for, download, and install Apple's free Additional Tools for Xcode 8 (for previous Xcode releases search for Graphics Tools for Xcode according to your version).
Note: free Apple Developer account required.
Launch Quartz Debug application.
Go to menu: Window ---> UI Resolution.
Check Enable HiDPI display modes.
Quit Quartz Debug.
Open System Preferences.
Select Displays icon.
If using multiple display, select the configuration window on the display you wish to simulate HiDPI mode on.
Under Resolution:, select Scaled radio button.
Find a desired resolution postfixed with (HiDPI) and select it.
Your display is now running in HiDPI mode, simulating a retina display.
Source: High Resolution Guidelines for OS X
I found the following instructions. It seems to work, and it is much easier than the Quartz Debug approach.
"Enable HiDPI mode in Mountain Lion w/o Quartz Debug"
https://gist.github.com/3191869
In brief, run the following commands, log out, log on, and the HiDPI resolutions are available in the display preferences:
sudo defaults write /Library/Preferences/com.apple.windowserver DisplayResolutionEnabled -bool YES
sudo defaults delete /Library/Preferences/com.apple.windowserver DisplayResolutionDisabled
(In my case the first command was enough; the second command just prints an error message.)
Edit: (5/31/2016)
For users trying to do this on El Capitan, please read the FAQ on SwitchRes's website. Also, if something's still not working after you did all the steps in the FAQ, consider uninstalling and reinstalling SwitchResX. That solved the issue I was having on one of my laptops.
Original:
After reading through several forums, websites, blogs.
I am here to present a solution for users with 15" MacBook Pro with Retina display connected to a Thunderbolt Display.
First of all,
Terminal command of modifying plist
Quartz Debug
Holding option and select "Scaled" in System Preferences
ResolutionTab (Mac App Store)
These methods DO NOT work for MBPr with Thunderbolt Display, for whatever reasons.
You will not see the HiDPI options to be selected.
The only tool I found that actually gives us the options is SwitchResX.
However another problem exists here.
Most users with this setup, I believe, are trying to use 1280x720 HiDPI because it's half the native resolution of the TBD.
According SwitchResX's FAQ, in some cases it is not possible to set to this resolution because of a bug within OS X itself.
Here's a screenshot for your reference:
After contacting the developer, he presented a workaround - adding one more pixel - which worked for me.
Install SwitchResX and open it from System Preferences.
Go to Thunderbolt Display tab, and add a Custom Resolutions with Scaled Resolution at 2562 x 1440
Here's a screenshot
Save using command + s. (or simply close the window and use the prompt up)
Restart the laptop.
Go to SwitchResX and select the new custom resolution in the Current Resolution tab. (Sometimes it doesn't show up right away, play around with it and it should.)
Here you go.
I hope this answer gets to users with this setup because it is really frustrating to use 16:10 resolution on a 16:9 display.
For those unable to enable HIDPI on rMBP or new MBA, I experienced the same on my rMBP 15" with Air Display. I solved the problem by installing SwitchResX. With the boolean setting enabled as shown in the referenced gist, the HIDPI setting shows up.
Dragging seems a little laggy in Air Display, but otherwise works great.
Try this
sudo defaults write /Library/Preferences/com.apple.windowserver DisplayResolutionEnabled -bool YES
[from here]
If your monitor supports it, it may also be worth setting the DisplayPort version to 1.1 instead of 1.2.
I have a late 2010 Mac Air with a Samsung S27D850 display and had all sorts of intermittent resolution switching issues until I made that change.
As for me its pretty good app that give you opportunity for changing resolution any that you want.
SwitchResX for Mac and MacBook.
This app resolved all my problems with resolution.

Resources