Skip to content

Commit

Permalink
Merge pull request slaclab#13 from MaddyGarske/master
Browse files Browse the repository at this point in the history
Non-Empty pull request -Maddy multiple updates
  • Loading branch information
lisazacarias authored Jun 30, 2020
2 parents 19ca267 + 27e3f7e commit 186ac03
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 1 deletion.
29 changes: 29 additions & 0 deletions Maddy/devPanelMaddy.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
from pydm import Display
from PyQt5 import QtGui, QtCore, QtWidgets
import sys

class devPanelMaddy(Display):



def __init__(self, parent=None, args=None):
super(devPanelMaddy, self).__init__(parent=parent, args=args)
self.ui.WIZARD.clicked.connect(lambda:self.updateOutput("You're a WIZARD, Harry"))
self.ui.what_wizard.stateChanged.connect(self.buttonToggled)


def ui_filename(self):
return 'devPanelMaddy.ui'

def updateOutput(self, output):
print(output)
self.ui.wizard_text.setText(output)

def buttonToggled(self):
self.ui.wizard_text.setText("An amazing one o'course!"
if self.ui.what_wizard.isChecked()
else "I hope you have a Felix Felicis type of day!")

intelclass = devPanelMaddy


42 changes: 42 additions & 0 deletions Maddy/devPanelMaddy.ui
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,16 @@
<string>Form</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="1" column="0">
<widget class="PyDMPushButton" name="WIZARD">
<property name="toolTip">
<string/>
</property>
<property name="text">
<string>Click here to become a Wizard today!</string>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="PyDMShellCommand" name="Maddyshellcommand">
<property name="toolTip">
Expand All @@ -29,14 +39,46 @@
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="PyDMCheckbox" name="what_wizard">
<property name="toolTip">
<string/>
</property>
<property name="text">
<string>What type of wizard are you?</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="PyDMLineEdit" name="wizard_text">
<property name="toolTip">
<string/>
</property>
</widget>
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>PyDMLineEdit</class>
<extends>QLineEdit</extends>
<header>pydm.widgets.line_edit</header>
</customwidget>
<customwidget>
<class>PyDMPushButton</class>
<extends>QPushButton</extends>
<header>pydm.widgets.pushbutton</header>
</customwidget>
<customwidget>
<class>PyDMShellCommand</class>
<extends>QPushButton</extends>
<header>pydm.widgets.shell_command</header>
</customwidget>
<customwidget>
<class>PyDMCheckbox</class>
<extends>QCheckBox</extends>
<header>pydm.widgets.checkbox</header>
</customwidget>
</customwidgets>
<resources/>
<connections/>
Expand Down
2 changes: 1 addition & 1 deletion opsDevPanel.ui
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@
</property>
<property name="filenames" stdset="0">
<stringlist>
<string>Maddy/devPanelMaddy.ui</string>
<string>Maddy/devPanelMaddy.py</string>
</stringlist>
</property>
</widget>
Expand Down

0 comments on commit 186ac03

Please sign in to comment.