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

Window initialization bug #32

Open
RodenLuo opened this issue Aug 2, 2024 · 2 comments
Open

Window initialization bug #32

RodenLuo opened this issue Aug 2, 2024 · 2 comments

Comments

@RodenLuo
Copy link
Collaborator

RodenLuo commented Aug 2, 2024

image

The window is set to be maximized on initialization. But it goes to the upper left of the display and shows an artifact, indicated by the blue arrow. After moving the window, or click the red arrow pointed button, everything is fine.

The bug is introduced somewhere after v0.2.3.

@RodenLuo
Copy link
Collaborator Author

RodenLuo commented Aug 2, 2024

It is introduced somewhere in the code below.

DiffFit/src/tool.py

Lines 820 to 860 in 3a4b597

# slider for ClusterSphere offset
CS_offset_label = QLabel()
CS_offset_label.setText("Offset: ")
CS_offset = QSlider(Qt.Horizontal)
spheres_default_offset = 100
CS_offset.setValue(spheres_default_offset)
CS_offset.setMinimum(0)
CS_offset.setMaximum(300)
CS_offset.valueChanged.connect(self.CS_offset_changed)
self.CS_offset = CS_offset
CS_offset_value_label = QLabel()
CS_offset_value_label.setText(str(CS_offset.value()))
self.CS_offset_value_label = CS_offset_value_label
layout.addWidget(CS_offset_label, row, 0)
layout.addWidget(CS_offset, row, 1)
layout.addWidget(CS_offset_value_label, row, 2)
row = row + 1
# slider for ClusterSphere scale factor
CS_scale_label = QLabel()
CS_scale_label.setText("Diff Scale: ")
CS_scale = QSlider(Qt.Horizontal)
spheres_default_scale = 40
CS_scale.setValue(spheres_default_scale)
CS_scale.setMinimum(20)
CS_scale.setMaximum(100)
CS_scale.valueChanged.connect(self.CS_scale_changed)
self.CS_scale = CS_scale
CS_scale_value_label = QLabel()
CS_scale_value_label.setText(str(CS_scale.value()))
self.CS_scale_value_label = CS_scale_value_label
layout.addWidget(CS_scale_label, row, 0)
layout.addWidget(CS_scale, row, 1)
layout.addWidget(CS_scale_value_label, row, 2)
row = row + 1

RodenLuo added a commit that referenced this issue Aug 2, 2024
@RodenLuo
Copy link
Collaborator Author

RodenLuo commented Aug 2, 2024

With the current temporary code base, switching the toggle in the following line to False will bypass this bug.

debug_toggle = True

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant