Skip to content
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

toggle_floating not working #24

Open
nikotidar opened this issue Nov 26, 2019 · 6 comments
Open

toggle_floating not working #24

nikotidar opened this issue Nov 26, 2019 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@nikotidar
Copy link

Hi again! 💃
I'm trying to use Wmderland on Kali Linux, it's works perfectly! But, toggle_floating is not working. Here's the log (maybe)

Nov 27 05:26:41 MacBook-Pro kernel: [41269.431278] traps: Wmderland[256837] trap divide error ip:56531cf4db41 sp:7fff96e586e0 error:0 in Wmderland[56531cf4a000+b000]

Os: Kali 2019.4
Wmderland Build: Latest

@aesophor
Copy link
Owner

Hi there!

I've tried running Wmderland on Kali 2019.4 and floating seems to be working for me.

May I ask how you started the wm? Did you start it via lightdm, or simply via startx?
I started it with startx.

@nikotidar
Copy link
Author

nikotidar commented Nov 28, 2019

Hi there!

I've tried running Wmderland on Kali 2019.4 and floating seems to be working for me.

May I ask how you started the wm? Did you start it via lightdm, or simply via startx?
I started it with startx.

Hi, Marco!

For login manager, i'm using GDM3.
Thanks before.

--
Confirmed, using xinit toggle_floating is working. For now, i've disabled Gdm3 for a while.

@aesophor
Copy link
Owner

I've successfully reproduced the bug by these steps:

  1. spawn a window
  2. press Mod+g (or Mod+v) multiple times
  3. press toggle_floating

The problem is in Workspace::SetTilingDirection, setting tiling direction multiple times will mess up the internal data structures. I'll try to redesign the algorithm here. Thanks!


I tried running grep -r ' / ' to find all statements that could potentially lead to divide-by-zero errors:

int child_width = (dir == TilingDirection::HORIZONTAL) ? w / children.size() : w;
int child_height = (dir == TilingDirection::VERTICAL) ? h / children.size() : h;

@aesophor aesophor self-assigned this Nov 28, 2019
@aesophor aesophor added the critical critical bug(s) label Nov 28, 2019
@nikotidar
Copy link
Author

I'm looking for the next update.
Thanks, Marco!

aesophor added a commit that referenced this issue Nov 28, 2019
Fix issue #24: fix divide by zero in Workspace::DfsTileHelper()
@aesophor
Copy link
Owner

Hello friend,
I've fixed this bug in PR #28 , could you please check if it works on your machine?

Thanks! 😄

@nikotidar
Copy link
Author

toggle_floating still not working with gdm3 and Wmderland latest build, i'm back using xinit (again) 😂

@aesophor aesophor added bug Something isn't working and removed critical critical bug(s) labels Nov 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants