qtile: Mirror widgets do not stretch

The issue:

I want do share the bar on all screens of the system. Because Its a laptop, the number of screens is variable.

Qtile Version: 0.21.0 Qtile Log: does not show a new error.

I began with the following attempt:


common_bar = [widget.Sep(), widget.Image(), widget.GroupBox(),  ..., widget.Promt(), widget.Spacer(), widget.WindowName(), ..., widget.CurrentLayoutIcon(), widget.Systray(),...]

screens = [
    Screen(top=bar.Bar(common_bar), 26, background=background),
    Screen(top=bar.Bar(common_bar), 26, background=background),
]

The bar is shown, but:

  • not correct (stuff is missing)
  • systray crashed
  • some widget are on Screen 1 and two half widgets are on display 0.

Required:

  • I have searched past issues to see if this bug has already been reported.

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 16 (9 by maintainers)

Commits related to this issue

Most upvoted comments

Ah. I see the issue: because you’re using the same widget instances, you get Mirror objects in your second bar.

The WindowName widget in your first bar fills the empty space in the bar but, in the second, as it’s now a Mirror it copies the length from the first bar, rather than filling the space in the second bar (you’ll see they both have widths of 1118).

As a quick fix, you could take out the WindowName widget from your second bar and replace it with a new instance.

That’s a great hint. Helped alot!