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

wx paint demo (and thus probably wxDC) does not work with Wayland #9282

Open
rongcuid opened this issue Jan 11, 2025 · 1 comment
Open

wx paint demo (and thus probably wxDC) does not work with Wayland #9282

rongcuid opened this issue Jan 11, 2025 · 1 comment
Assignees
Labels
bug Issue is reported as a bug team:PS Assigned to OTP team PS

Comments

@rongcuid
Copy link

Describe the bug
When using GDK_BACKEND=wayland, wx paint does not update properly.

To Reproduce

  1. Run erl
  2. wx:demo()
  3. Go to paint example, try to paint
  4. Canvas does not update unless something is done to the window, such as resizing
  5. Run GDK_BACKEND=x11 erl
  6. Try again, this time paint works

Expected behavior
Wayland and X11 backend should behave the same

Affected versions
26.2.1

Additional context
My system: Gentoo Linux with wxGTK-3.2.5 and erlang-26.2.1, running Plasma 6 on Wayland with NVIDIA driver

I tried some wxDC samples directly with C++, and those work. So it's probably something wrong in OTP

@rongcuid rongcuid added the bug Issue is reported as a bug label Jan 11, 2025
@rongcuid
Copy link
Author

I did, however, find this note in Gentoo's wxGTK build:

    # By default, we now build with the GLX GLCanvas because some software like
    # PrusaSlicer does not yet support EGL:
    #
    # https://github.com/prusa3d/PrusaSlicer/issues/9774 .
    #    
    # A solution for this is being developed upstream:
    #
    # https://github.com/wxWidgets/wxWidgets/issues/22325 .
    #
    # Any software that needs to use OpenGL under Wayland can be patched like
    # this to run under xwayland:
    #
    # https://github.com/visualboyadvance-m/visualboyadvance-m/commit/aca206a721265366728222d025fec30ee500de82 .
    #
    # Check that the macro wxUSE_GLCANVAS_EGL is set to 1.
    #
    myeconfargs+=( "--disable-glcanvasegl" )

That is, my wxWidgets would not be able to build with EGL.

@IngelaAndin IngelaAndin added the team:PS Assigned to OTP team PS label Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue is reported as a bug team:PS Assigned to OTP team PS
Projects
None yet
Development

No branches or pull requests

3 participants