-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
QuickTile fails pathologically when encountering panel reservations on edges between monitors #45
Comments
This might be related to #44, but I couldn't tell for sure. |
If QuickTile were missing a dependency, you wouldn't get that far. It'd just exit with an error about missing dependencies. The fact that you're getting that debug output means that your problem has to do with how it's interacting with the desktop. Could you clarify what you mean by "broken window cycling"? Also, try the test I just posted in issue #44 and let me know what result you get. Between those two commits, most of QuickTile's guts were ripped out and outsourced to libwnck to fix certain hard-to-solve bugs. If, by "broken window cycling", you mean that it stops at the 1/2-wide preset and doesn't let you progress to 1/3 and 2/3, then you may be tripping over one of the last major bodges still to be redesigned. (The other being the hard-coded tiling sequences, which require a new config file syntax to be resolved, as explained in #13.) (Currently, QuickTile doesn't actually keep any state. When you ask it to tile a window, it just requests the active window's geometry and guesses its place in the cycle from that... and WMs don't always give it exactly the dimensions it asked for last time you hit the keybind. That old code is the cause of issues #20, #24, and #30 and the hold-up for implementing #10.) |
Sorry for not being clear in the initial report. I got the debug output just because I started QuickTile with the debug flag in order to see why it's behaving like it does. What I am seeing is exactly what the debug messages say: it is trying and does actually resize the window I am trying to tile to the dimension (0, 0, 0, 0), meaning some windows will get resized to a line of 1px by 10-20px while other windows have a minimum size. I will try to run the commands you posted on #44 and will also post a screen capture of the issue in action. Thanks! |
Here's a short recording of the issue I am seeing: https://dl.dropboxusercontent.com/u/1326394/quicktile-1.webm You can see the debug output below when I press I tried running the command from #44, but I get the same result as in the video. |
I thought maybe something got screwed on the installation of Ubuntu, so I decided to try to re-install it again. These were my first commands after a clean install:
The debug output and the visual behaviour is exactly the same as the ones posted in the earlier messages. I can't figure out why it is behaving like this. |
It seems I only get this behaviour when the window I am trying to move is on my main monitor. I have two monitors connected to my computer. If I move the window using |
That shows what a mess my However, the "works on one monitor but not the other" is a very important clue. Later today, I'll try to renovate the |
Alright. Here's how the
|
Here is what I get now with the latest master. Same behaviour as before.
|
Interesting. I'll need to add some more
On the plus side, your monitors are the same size, just as mine are, so that's one less thing I'd have to replicate if I tried to reproduce the problem locally. |
Sure, I'll be happy to run any version you have to help track down this issue. You can create a debug branch on your repo and I'll use that. |
I'll probably just do it in the main branch. The original choice of what to |
Ok, I suspect the problem is in the complex and somewhat under-tested
The newest code should now produce something like this:
I want to try to avoid adding debug output I'm just going to remove later, so I'm going to add new debugging statements bit-by-bit in response to what the previous steps say on your machine. |
|
Ugh. I was hoping it would be some kind of pathological "Oddly-shaped region degenerates into a zero-size rectangle" problem but Here's another update so I can see the raw usable region data being retrieved from X11 window properties on your desktop.
|
The debug is getting quite big, so I'll add them to this gist: https://gist.github.com/avaly/73eb8e6798e46147022e Still same behaviour. Thanks a lot for helping with tracking down this issue! |
No problem. Thank you for helping me track down a tricky bug in my program. As for the behaviour, that's normal. I don't want to alter it until I fully understand what's causing the problem. I'm not sure if I'll have time to inspect that |
Sorry. It's going to have to be tomorrow. Today, I didn't realize how much of the day I'd spent helping my brother in his efforts to learn to program. |
Ok, I haven't tested it yet (partly because I'm running LXPanel and it's not flexible enough to let me take 30 seconds to replicate what I suspect is going on), but I think I know what's going on from those If I'm reading
Am I correct? Either way, that second one is the problem because QuickTile is naïve. If the panel requests to reserve Given how complex that code already is, I'll need some time to think on the best way to add this extra complexity, but I'll put it on my TODO list. |
Yes, what you described seems to be correct. I have the default Ubuntu Launcher bar on the left edge of both screens which should take around 49px and the top title/indicators bar also on both screens which is around 24px. I still can't see why quicktile (with the old git hash I referred to in the first message) used to work fine on the same hardware setup before I re-installed. I have been able to replicate the issue even in a VirtualBox machine with the Ubuntu Live USB, without even installing it (just click Try Ubuntu). |
The old version of QuickTile you were running had no awareness of
The current version of QuickTile only falls back to |
Any updates on this one? |
Weirdly enough, removing the launcher bar from the second monitor was enough to fix the issue I was experiencing. However, I do think the code can still be improved to handle this edge cases. |
Sorry for dropping the ball. My schedule got messed up and I've been struggling to keep the TODO completion rate above the TODO arrival rate. I can't promise anything, but I'll try to push this closer to the front of my TODO list. As for fixing it, that's not weird at all. The problem happens because, when QuickTile receives word that the panel on the second monitor has reserved space, it misinterprets that request as reserving the entire left monitor. You'd have the same problem if you had a panel on the right-hand side of the left monitor. |
Renaming this to the actual problem as part of cleaning up TODOs in preparation to fix them. Sorry for going silent for so long. |
In case anyone's wondering about the root cause of this issue, it's that I was working from the official spec for |
Since I may need to rethink my internal representation of panels so it remembers which edge of the desktop the panel was calculated against (ie. which dimension is length and which is thickness) but I'm imagining something along the lines of "if a panel's thickness covers the entire span of the monitor in question, ignore it." |
No fix yet, but I just converted the numbers from your |
A fix that superficially seems to work is now in my local copy of QuickTile. I'll be pushing it to the |
OK. The version with the fix is now in the Please test and let me know if you encounter any problems. |
Was: Windows get resized to (0,0,0,0) on a clean install of Ubuntu 14.04.1
On a fresh install of Ubuntu 14.04.1 I get the following results when running quicktile on the latest
master
branch (commit 7571ac6).Earlier today, before performing the fresh install of Ubuntu 14.04.1, I was running Ubuntu 14.04.1 which was upgraded from a fresh install of Ubuntu 13.04. On that installation I was running a quicktile fork based on an old commit (7a5bf6f). Everything worked fine.
However, on the fresh install of 14.04.1, when running the old commit 7a5bf6f, I get the following debug output:
Could it be that quicktile depeneds on some library that was available in Ubuntu 13.04, but is not present in 14.04?
Any suggestions to track down the issue and find a workaround would be appreciated!
The text was updated successfully, but these errors were encountered: