Home | Trees | Indices | Help |
---|
|
python_qt_binding.QtGui.QMainWindow --+ | SpeakEasyGUI
One instance of this class builds the entire sound play UI. Instance variable that hold widgets of interest to controllers:
speechInputFld
onceOrRepeatDict
voicesRadioButtonsDict
recorderDict
programButtonDict
soundButtonDict
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
{None | string} |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
string |
|
||
PlayLocation |
|
||
|
|||
|
|||
|
|
|||
QGridLayout |
|
|
|||
PROGRAM_BUTTON_HOLD_TIME = 3.0
|
|||
PROGRAM_BUTTON_LOOK_CHANGE_DURATION = 0.2
|
|||
BUTTON_MIN_HEIGHT = 30
|
|||
BUTTON_LABEL_FONT_SIZE = 16
|
|||
RADIO_BUTTON_LABEL_FONT_SIZE = 16
|
|||
EDIT_FIELD_TEXT_SIZE = 18
|
|||
NUM_OF_PROGRAM_BUTTON_COLUMNS = 4
|
|||
NUM_OF_SOUND_BUTTON_COLUMNS = 4
|
|||
voices = {'VOICE_1': 'voice_kal_diphone', 'VOICE_2': 'David',
|
|||
interactionWidgets = {'PLAY_ONCE': 'Play once', 'PLAY_REPEATED
|
|||
veryLightBlue = QColor(230, 255, 255)
|
|||
stylesheetAppBG = 'QDialog {background-color: %s}' % veryLight
|
|||
defaultStylesheet = 'QDialog {background-color: %s}' % veryLig
|
|||
defaultStylesheetName = "Default"
|
|||
editFieldBGColor = QColor(12, 21, 109)
|
|||
editFieldTextColor = QColor(244, 244, 246)
|
|||
inputFldStylesheet = 'TextPanel {background-color: '+ editFiel
|
|||
recorderButtonBGColor = QColor(176, 220, 245)
|
|||
recorderButtonDisabledBGColor = QColor(187, 200, 208)
|
|||
recorderButtonTextColor = QColor(0, 0, 0)
|
|||
programButtonBGColor = QColor(117, 150, 169)
|
|||
programButtonTextColor = QColor(251, 247, 247)
|
|||
soundButtonBGColor = QColor(110, 134, 211)
|
|||
soundButtonTextColor = QColor(251, 247, 247)
|
|||
recorderButtonStylesheet = 'QPushButton {background-color: '+
|
|||
recorderButtonDisabledStylesheet = 'QPushButton {background-co
|
|||
programButtonStylesheet = 'QPushButton {background-color: '+ p
|
|||
programButtonModeTransitionStylesheet = 'QPushButton {backgrou
|
|||
soundButtonStylesheet = 'QPushButton {background-color: '+ sou
|
|||
playOnceRepeatButtonBGColor = QColor(121, 229, 230)
|
|||
voicesButtonBGColor = QColor(97, 164, 165)
|
|||
playOnceRepeatButtonStylesheet = 'font-size: '+ str(RADIO_BUTT
|
|||
playRepeatSpinboxStylesheet = 'font-size: '+ str(RADIO_BUTTON_
|
|||
voiceButtonStylesheet = 'font-size: '+ str(RADIO_BUTTON_LABEL_
|
|||
hideButtonSignal = pyqtSignal(QPushButton)
|
|||
showButtonSignal = pyqtSignal(QPushButton)
|
|
Creates text input field label and text field in a horizontal box layout. Adds that hbox layout to the passed-in layout. Sets instance variables:
|
Creates radio buttons for selecting whether a sound is to play once, or repeatedly until stopped. Also adds radio buttons for selecting voices. Places all in a horizontal box layout. Adds that hbox layout to the passed-in layout. Sets instance variables:
|
Creates tape recorder buttons (Play Text, Stop,etc.). Places all in a row, though the layout is a QGridLayout. Adds QGridLayout to the passed-in layout. Sets instance variables:
|
Creates grid of buttons for saving sounds. Adds the resulting QGridLayout to the passed-in layout. Sets instance variables:
|
Creates grid of buttons for playing canned sounds. Adds the resulting QGridLayout to the passed-in layout. Sets instance variables:
|
Creates buttons meant for accessibility convenience. Example: Paste. Places all in a row, though the layout is a QGridLayout. Adds QGridLayout to the passed-in layout. Sets instance variables:
|
|
Creates a grid of QPushButton widgets. They will be
|
Requests a new button label from the user. Returns None if user canceled out, or a string with the new button label.
|
Return the official name of the voice that is currently checked in the UI. This is the name that will be recognized by the underlying text-to-speech engine(s).
|
Returns which of the play location options is selected: Locally or Robot.
|
Set the option radio button that determines where sound is produced, locally, or at the robot. No action is taken. This method merely sets the appropriate radio button.
|
Used to make a program button blink in some way to indicate that it is changing into programming mode. Since this method is triggered by a timer thread, it cannot make any GUI changes. Instead, it sends a signal to have the GUI thread place the button into an alternative look. It then schedules a call to itself for a short time later. At that point it sends a signal to the GUI thread to return the button to its usual look:
|
|
voices
|
interactionWidgets
|
stylesheetAppBG
|
defaultStylesheet
|
inputFldStylesheet
|
recorderButtonStylesheet
|
recorderButtonDisabledStylesheet
|
programButtonStylesheet
|
programButtonModeTransitionStylesheet
|
soundButtonStylesheet
|
playOnceRepeatButtonStylesheet
|
playRepeatSpinboxStylesheet
|
voiceButtonStylesheet
|
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Mon Nov 26 18:08:31 2012 | http://epydoc.sourceforge.net |