PushButton not showing in Dark mode on Mojave when PushButton.Default = True

  1. 5 months ago

    Mark F

    Jun 11 Byron Bay, Australia

    I'm not sure what's causing this but I have a couple of windows in my app that won't show the PushButton when PushButton.Default = True when the app is running on Mojave in Dark mode - only occurs the first time the window is shown/created. If the window is hidden and re-shown the problem isn't there.

    I can reproduce the issue on my system for one of the windows. To fix it I simply hide and show the window again when app is running in dark mode and all is good. For the other window this problem only occurs for one of my beta testers. Hiding the window and reshowing doesn't fix the issue. Short of setting the PushButton.Default to false in dark mode and accepting enter keys in the window KeyDown event handler has anyone else seen anything like this or have any suggestions?

    Thanks,

    Mark

    Dev system: macOS 10.13.6 Xojo 2018r3
    Test system macOS 10.14.4

    @Mark F I'm not sure what's causing this but I have a couple of windows in my app that won't show the PushButton when PushButton.Default = True when the app is running on Mojave in Dark mode - only occurs the first time the window is shown/created. If the window is hidden and re-shown the problem isn't there.

    I can reproduce the issue on my system for one of the windows. To fix it I simply hide and show the window again when app is running in dark mode and all is good. For the other window this problem only occurs for one of my beta testers. Hiding the window and reshowing doesn't fix the issue. Short of setting the PushButton.Default to false in dark mode and accepting enter keys in the window KeyDown event handler has anyone else seen anything like this or have any suggestions?

    Thanks,

    Mark

    Dev system: macOS 10.13.6 Xojo 2018r3
    Test system macOS 10.14.4

    Build with 2018r4 or higher. We had the same problem with the 2018r3 IDE.

  2. I just checked some apps of mine using PushButton.default= true, but I cannot reproduce the problem you are facing.
    macOS 10.14.5
    Xojo 2019r1 and 1.1

  3. Greg O

    Jun 11 Xojo Inc Answer scout.galaxy.barn
    Edited 5 months ago

    @Mark F I'm not sure what's causing this but I have a couple of windows in my app that won't show the PushButton when PushButton.Default = True when the app is running on Mojave in Dark mode - only occurs the first time the window is shown/created. If the window is hidden and re-shown the problem isn't there.

    I can reproduce the issue on my system for one of the windows. To fix it I simply hide and show the window again when app is running in dark mode and all is good. For the other window this problem only occurs for one of my beta testers. Hiding the window and reshowing doesn't fix the issue. Short of setting the PushButton.Default to false in dark mode and accepting enter keys in the window KeyDown event handler has anyone else seen anything like this or have any suggestions?

    Thanks,

    Mark

    Dev system: macOS 10.13.6 Xojo 2018r3
    Test system macOS 10.14.4

    Build with 2018r4 or higher. We had the same problem with the 2018r3 IDE.

  4. Mark F

    Jun 11 Byron Bay, Australia

    @Greg OLone - Thanks. Unfortunately I currently can't go past 2018r3 as I need the build to use the 10.13 SDK. I need this so that I can wrap my app bundle with some software that currently doesn't like apps created with the 10.14 SDK (I know Xojo doesn't support this kinds of thing)

    Hopefully I can update soon to fix this issue.

    Thanks for letting me know.

  5. Norman P

    Jun 11 Pre-Release Testers, Xojo Pro Outside

    If you're using 2018r3 its using the 10.9 SDK

  6. Mark F

    Jun 11 Byron Bay, Australia

    Okay thanks Norman

  7. Jürg O

    Jun 12 Pre-Release Testers, Xojo Pro

    @Mark F anyone else seen anything like this or have any suggestions?

    Hmm… hasn't the workaround for 2018r3 been something like this?

    • don't set PushButton.Default = true in IDE's Layout Editor
    • set PushButton.Default = true in Code, once the Window is shown

or Sign Up to reply!