Skip to content

Commit

Permalink
Fix colors panel (#345)
Browse files Browse the repository at this point in the history
Sliders need `int` value.
  • Loading branch information
speleo3 authored Mar 15, 2024
1 parent 795e664 commit 545e594
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions modules/pmg_qt/pymol_qt_gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -573,9 +573,9 @@ def update_gui(*args):
R = form.input_R.value()
G = form.input_G.value()
B = form.input_B.value()
form.slider_R.setValue(R * 100)
form.slider_G.setValue(G * 100)
form.slider_B.setValue(B * 100)
form.slider_R.setValue(round(R * 100))
form.slider_G.setValue(round(G * 100))
form.slider_B.setValue(round(B * 100))
form.frame_color.setStyleSheet(
"background-color: rgb(%d,%d,%d)" % (
R * 0xFF, G * 0xFF, B * 0xFF))
Expand Down

0 comments on commit 545e594

Please sign in to comment.