Skip to content

Buggy sliders on macos when throttling #63

@shunlog

Description

@shunlog

Hi, thanks for the nice lib!

I noticed that sliders on macos are buggy when throttling is involved.
It works fine on windows and linux however.

Here is a demo:

2025-08-12.14-52-16.mp4
#lang racket/base

(require racket/gui/easy
         racket/gui/easy/operator)

(define @a (@ 0))
(define @b (@ 0))
(define @b2 (obs-throttle @b))

(render
 (window
  (hpanel
   (text "Slider on @a")
   (slider @a #:min-value 0 #:max-value 100
           (λ (v) (:= @a v)))
   (text (obs-map @a number->string)))

  (hpanel
   (text "Slider on @b")
   (slider @b #:min-value 0 #:max-value 100
           (λ (v) (:= @b v)))
   (text (obs-map @b number->string))
   (text (obs-map @b2 number->string)))
  
  (hpanel
   (text "Slider on throttled @b")
   (slider @b2 #:min-value 0 #:max-value 100
           (λ (v) (:= @b v)))
   (text (obs-map @b number->string))
   (text (obs-map @b2 number->string)))
  ))

When the slider value is the throttled observable, there is only 1 bug: the observable value is not updated during sliding.

On the other hand, when the slider value is the original observable, there is one additional bug: the value is set to where the cursor started sliding.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions