Skip to content

Commit

Permalink
Merge pull request #1110 from bnmajor/llnl-position-buttons
Browse files Browse the repository at this point in the history
Clean up appearance of toggle buttons for template position
  • Loading branch information
bnmajor authored Jan 5, 2022
2 parents 3f1d0f6 + 11f4bf5 commit b19a660
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 5 deletions.
4 changes: 3 additions & 1 deletion hexrd/ui/image_stack_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import numpy as np
from pathlib import Path

from PySide2.QtCore import QObject, Signal
from PySide2.QtCore import QObject, Signal, Qt
from PySide2.QtWidgets import QFileDialog, QMessageBox, QTableWidgetItem

from hexrd.ui.constants import MAXIMUM_OMEGA_RANGE
Expand All @@ -20,6 +20,8 @@ def __init__(self, parent=None, simple_image_series_dialog=None):
super(ImageStackDialog, self).__init__(parent)
loader = UiLoader()
self.ui = loader.load_file('image_stack_dialog.ui', parent)
flags = self.ui.windowFlags()
self.ui.setWindowFlags(flags | Qt.Tool)

self.simple_image_series_dialog = simple_image_series_dialog
self.detectors = HexrdConfig().detector_names
Expand Down
5 changes: 4 additions & 1 deletion hexrd/ui/llnl_import_tool_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import h5py
from pathlib import Path

from PySide2.QtCore import QObject, Signal
from PySide2.QtCore import QObject, Signal, Qt
from PySide2.QtWidgets import QColorDialog, QFileDialog, QMessageBox
from PySide2.QtGui import QColor

Expand Down Expand Up @@ -41,6 +41,9 @@ def __init__(self, cmap=None, parent=None):

loader = UiLoader()
self.ui = loader.load_file('llnl_import_tool_dialog.ui', parent)
flags = self.ui.windowFlags()
self.ui.setWindowFlags(flags | Qt.Tool)

self.it = None
self.instrument = None
self.edited_images = {}
Expand Down
12 changes: 9 additions & 3 deletions hexrd/ui/resources/ui/llnl_import_tool_dialog.ui
Original file line number Diff line number Diff line change
Expand Up @@ -387,9 +387,9 @@
<property name="checked">
<bool>true</bool>
</property>
<property name="flat">
<bool>true</bool>
</property>
<attribute name="buttonGroup">
<string notr="true">positionOutlineButtons</string>
</attribute>
</widget>
</item>
<item row="0" column="1">
Expand All @@ -403,6 +403,9 @@
<property name="checkable">
<bool>true</bool>
</property>
<attribute name="buttonGroup">
<string notr="true">positionOutlineButtons</string>
</attribute>
</widget>
</item>
<item row="1" column="1" alignment="Qt::AlignRight">
Expand Down Expand Up @@ -735,4 +738,7 @@
</hints>
</connection>
</connections>
<buttongroups>
<buttongroup name="positionOutlineButtons"/>
</buttongroups>
</ui>
2 changes: 2 additions & 0 deletions hexrd/ui/simple_image_series_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ def __init__(self, parent=None):

loader = UiLoader()
self.ui = loader.load_file('simple_image_series_dialog.ui', parent)
flags = self.ui.windowFlags()
self.ui.setWindowFlags(flags | Qt.Tool)

self.update_config_variables()

Expand Down

0 comments on commit b19a660

Please sign in to comment.