Skip to content
Snippets Groups Projects
Commit 692aa02c authored by Oscar Gustafsson's avatar Oscar Gustafsson :bicyclist:
Browse files

Minor doc-string additions

parent 16cef266
No related branches found
No related tags found
No related merge requests found
"""B-ASIC Drag Button Module. """
B-ASIC Drag Button Module.
Contains a GUI class for drag buttons. Contains a GUI class for drag buttons.
""" """
...@@ -16,7 +17,8 @@ from b_asic.GUI.settings import MINBUTTONSIZE ...@@ -16,7 +17,8 @@ from b_asic.GUI.settings import MINBUTTONSIZE
@decorate_class(handle_error) @decorate_class(handle_error)
class DragButton(QPushButton): class DragButton(QPushButton):
"""Drag button class. """
Drag button class.
This class creates a drag button which can be clicked, dragged and dropped. This class creates a drag button which can be clicked, dragged and dropped.
""" """
...@@ -115,9 +117,7 @@ class DragButton(QPushButton): ...@@ -115,9 +117,7 @@ class DragButton(QPushButton):
path_to_image = os.path.join( path_to_image = os.path.join(
os.path.dirname(__file__), os.path.dirname(__file__),
"operation_icons", "operation_icons",
( f"{self.operation_path_name}{'_grey.png' if self.pressed else '.png'}",
f"{self.operation_path_name}{'_grey.png' if self.pressed else '.png'}"
),
) )
self.setIcon(QIcon(path_to_image)) self.setIcon(QIcon(path_to_image))
self.setIconSize(QSize(MINBUTTONSIZE, MINBUTTONSIZE)) self.setIconSize(QSize(MINBUTTONSIZE, MINBUTTONSIZE))
...@@ -141,6 +141,7 @@ class DragButton(QPushButton): ...@@ -141,6 +141,7 @@ class DragButton(QPushButton):
signal.update() signal.update()
def remove(self): def remove(self):
"""Remove button/operation from signal flow graph."""
self._window.logger.info( self._window.logger.info(
f"Removing operation with name {self.operation.name}." f"Removing operation with name {self.operation.name}."
) )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment