Vuo  0.5.7
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Protected Member Functions | List of all members
VuoInputEditorPoint4d Class Reference

Description

An input editor that displays widgets for editing a VuoPoint4d value, allowing the user either to select the value with a mouse (using a spin box or slider) or to type the value into a text box (line edit).

This input editor recognizes the following keys in the JSON details object:

Example:
{
"suggestedMin" : -1.0,
"suggestedMax" : 1.0,
"suggestedStep" : 0.25
}

Protected Member Functions

void setUpDialog (QDialog &dialog, json_object *originalValue, json_object *details, bool editingSolePortConstantForNode)
 Sets up a dialog containing either a slider and line edit (if details contains both "suggestedMin" and "suggestedMax") or a spin box (which includes a line edit).
 
json_object * getAcceptedValue (void)
 Returns the current text in the line edits.
 
QString convertToLineEditFormat (json_object *value)
 Returns the text that should appear in the line edit to represent value.
 
json_object * convertFromLineEditsFormat (const QString &xValueAsString, const QString &yValueAsString, const QString &zValueAsString, const QString &wValueAsString)
 Formats the value from the line edit to conform to the JSON specification for numbers.
 
bool eventFilter (QObject *object, QEvent *event)
 Filters events on watched objects.
 
- Protected Member Functions inherited from VuoInputEditorWithLineEdit
void setUpLineEdit (QLineEdit *existingLineEdit, json_object *originalValue)
 Configures the provided line edit to display the dialog's initial value.
 
void setFirstTabCycleElement (QWidget *element)
 Sets the provided element as the first tab cycle element within this input editor.
 
void setFinalTabCycleElement (QWidget *element)
 Sets the provided element as the final tab cycle element within this input editor.
 
json_object * getAcceptedValue (void)
 Returns the current text in the line edit.
 
virtual json_object * convertFromLineEditFormat (const QString &valueAsString)
 Returns the value represented when the given text appears in the line edit.
 
bool eventFilter (QObject *object, QEvent *event)
 Filters events on watched objects.
 

Additional Inherited Members

- Signals inherited from VuoInputEditor
void valueChanged (json_object *newValue)
 An input editor can emit this signal to inform the Vuo Editor that the value has been edited.
 
void tabCycleCompleted ()
 An input editor can emit this signal to inform the Vuo Editor that a 'Tab' keypress was received while the final widget in this input editor's tab cycle already had focus.
 
void reverseTabCycleCompleted ()
 An input editor can emit this signal to inform the Vuo Editor that a 'Shift'+'Tab' keypress was received while the first widget in this input editor's tab cycle already had focus.
 
- Public Member Functions inherited from VuoInputEditorWithLineEdit
 VuoInputEditorWithLineEdit (void)
 Creates an input editor whose show function displays a line edit.
 
void setWidth (int width)
 Sets the width of the line edit.
 
bool emitsTabCycleCompletionSignals (void)
 Returns a boolean indicating whether this input editor emits tabCycleCompleted() and reverseTabCycleCompleted() signals when appropriate.
 
- Protected Attributes inherited from VuoInputEditorWithLineEdit
QLineEdit * lineEdit
 The text field widget.
 
QWidget * firstTabCycleElement
 The first widget in this input editor's tab cycle.
 
QWidget * finalTabCycleElement
 The final widget in this input editor's tab cycle.
 
bool editingSolePortConstantForNode
 A boolean indicating whether this input editor is currently being used to edit a node's only port constant.
 

Member Function Documentation

json_object * VuoInputEditorPoint4d::convertFromLineEditsFormat ( const QString &  xValueAsString,
const QString &  yValueAsString,
const QString &  zValueAsString,
const QString &  wValueAsString 
)
protected

Formats the value from the line edit to conform to the JSON specification for numbers.

QString VuoInputEditorPoint4d::convertToLineEditFormat ( json_object *  value)
protectedvirtual

Returns the text that should appear in the line edit to represent value.

Reimplemented from VuoInputEditorWithLineEdit.

bool VuoInputEditorPoint4d::eventFilter ( QObject *  object,
QEvent *  event 
)
protected

Filters events on watched objects.

json_object * VuoInputEditorPoint4d::getAcceptedValue ( void  )
protectedvirtual

Returns the current text in the line edits.

Implements VuoInputEditorWithDialog.

void VuoInputEditorPoint4d::setUpDialog ( QDialog &  dialog,
json_object *  originalValue,
json_object *  details,
bool  editingSolePortConstantForNode 
)
protectedvirtual

Sets up a dialog containing either a slider and line edit (if details contains both "suggestedMin" and "suggestedMax") or a spin box (which includes a line edit).

Reimplemented from VuoInputEditorWithLineEdit.


The documentation for this class was generated from the following files: