MythTV  0.26-pre
Public Types | Public Slots | Signals | Public Member Functions | Protected Member Functions | Protected Attributes
MythUITextEdit Class Reference

A text entry and edit widget. More...

#include <mythuitextedit.h>

Inheritance diagram for MythUITextEdit:
MythUIType StorageUser XMLParseBase

List of all members.

Public Types

enum  MoveDirection { MoveLeft, MoveRight, MoveEnd }

Public Slots

void Select ()
void Deselect ()

Signals

void valueChanged ()

Public Member Functions

 MythUITextEdit (MythUIType *parent, const QString &name)
 ~MythUITextEdit ()
virtual void Pulse (void)
 Pulse is called 70 times a second to trigger a single frame of an animation.
virtual bool keyPressEvent (QKeyEvent *)
 Key event handler.
bool gestureEvent (MythGestureEvent *)
 Mouse click/movement handler, receives mouse gesture events from the QCoreApplication event loop.
virtual void Reset (void)
 Reset the widget to it's original state, should not reset changes made by the theme.
void SetText (const QString &text, bool moveCursor=true)
void InsertText (const QString &text)
QString GetText (void) const
void SetFilter (InputFilter filter)
void SetPassword (bool isPassword)
void SetMaxLength (const int length)
bool MoveCursor (MoveDirection)
void SetKeyboardPosition (PopupPosition pos)
PopupPosition GetKeyboardPosition (void)
void SetDBValue (const QString &text)
QString GetDBValue (void) const

Protected Member Functions

virtual bool ParseElement (const QString &filename, QDomElement &element, bool showWarnings)
 Parse the xml definition of this widget setting the state of the object accordingly.
virtual void CopyFrom (MythUIType *base)
 Copy this widgets state from another.
virtual void CreateCopy (MythUIType *parent)
 Copy the state of this widget to the one given, it must be of the same type.
virtual void Finalize (void)
 Perform any post-xml parsing initialisation tasks.
void Init (void)
void SetInitialStates (void)
bool InsertCharacter (const QString &character)
void RemoveCharacter (int position)
void CutTextToClipboard (void)
void CopyTextToClipboard (void)
void PasteTextFromClipboard (QClipboard::Mode mode=QClipboard::Clipboard)

Protected Attributes

bool m_initialized
int m_blinkInterval
int m_cursorBlinkRate
MythTimer m_lastKeyPress
int m_maxLength
QString m_Message
InputFilter m_Filter
int m_Position
bool m_isPassword
PopupPosition m_keyboardPosition
MythUIStateTypem_backgroundState
MythUIImagem_cursorImage
MythUITextm_Text
int m_composeKey

Detailed Description

A text entry and edit widget.

Definition at line 31 of file mythuitextedit.h.


Member Enumeration Documentation

Enumerator:
MoveLeft 
MoveRight 
MoveEnd 

Definition at line 52 of file mythuitextedit.h.


Constructor & Destructor Documentation

MythUITextEdit::MythUITextEdit ( MythUIType parent,
const QString &  name 
)

Definition at line 24 of file mythuitextedit.cpp.

Referenced by CreateCopy().

Definition at line 57 of file mythuitextedit.cpp.


Member Function Documentation

void MythUITextEdit::Pulse ( void  ) [virtual]

Pulse is called 70 times a second to trigger a single frame of an animation.

This changes the alpha value of the widget

Reimplemented from MythUIType.

Definition at line 78 of file mythuitextedit.cpp.

bool MythUITextEdit::keyPressEvent ( QKeyEvent *  ) [virtual]

Mouse click/movement handler, receives mouse gesture events from the QCoreApplication event loop.

Should not be used directly.

Parameters:
uitypeThe mythuitype receiving the event
eventMouse event

Reimplemented from MythUIType.

Definition at line 510 of file mythuitextedit.cpp.

void MythUITextEdit::Reset ( void  ) [virtual]

Reset the widget to it's original state, should not reset changes made by the theme.

Reimplemented from MythUIType.

Definition at line 73 of file mythuitextedit.cpp.

Referenced by CutTextToClipboard(), ImportIconsWizard::enableControls(), and PhrasePopup::phraseSelected().

void MythUITextEdit::SetText ( const QString &  text,
bool  moveCursor = true 
)

Definition at line 216 of file mythuitextedit.cpp.

Referenced by CustomPriority::addClicked(), EditMetadataDialog::checkClicked(), CustomEdit::clauseClicked(), ImportSettings::Create(), GeneralSettings::Create(), PlayerSettings::Create(), BookmarkEditor::Create(), MythNewsEditor::Create(), RSSEditPopup::Create(), BrowserConfig::Create(), FileSelector::Create(), ImportMusicDialog::Create(), ArchiveFileSelector::Create(), EditPowerSearchPopup::Create(), SearchInputDialog::Create(), MythTextInputDialog::Create(), MythUISearchDialog::Create(), SearchButtonListDialog::Create(), MetadataOptions::Create(), RecMetadataEdit::Create(), ImportMusicDialog::customEvent(), ImportIconsWizard::doLoad(), SelectDestination::fileFinderClosed(), EditMetadataDialog::fillWidgets(), EditRomInfoDialog::fillWidgets(), GalleryFilterDialog::fillWidgets(), VideoFilterDialog::fillWidgets(), InsertCharacter(), SelectDestination::loadConfiguration(), CustomPriority::loadData(), PhrasePopup::phraseSelected(), MetadataOptions::QueryComplete(), RemoveCharacter(), Reset(), CustomPriority::ruleChanged(), CustomEdit::ruleChanged(), Ripper::ScanFinished(), RawSettingsEditor::selectionChanged(), EditMetadataDialog::setAlbum(), Ripper::setAlbum(), EditMetadataDialog::setArtist(), Ripper::setArtist(), EditMetadataDialog::setCompArtist(), EditMetadataDialog::setGenre(), Ripper::setGenre(), ChannelEditor::SetText(), CriteriaRowEditor::setValue(), BookmarkEditor::slotCategoryFound(), RSSEditPopup::slotCheckRedirect(), FileSelector::updateFileList(), MythUIFileBrowser::updateLocalFileList(), MythUIFileBrowser::updateRemoteFileList(), FileAssocDialog::UpdateScreen(), and CriteriaRowEditor::updateValues().

void MythUITextEdit::InsertText ( const QString &  text)

Definition at line 239 of file mythuitextedit.cpp.

Referenced by PasteTextFromClipboard().

QString MythUITextEdit::GetText ( void  ) const [inline]

Definition at line 46 of file mythuitextedit.h.

Referenced by CustomPriority::addClicked(), Ripper::albumChanged(), Ripper::artistChanged(), MetadataOptions::CanSetArtwork(), EditMetadataDialog::checkClicked(), CustomPriority::checkSyntax(), CustomEdit::checkSyntax(), CustomEdit::clauseChanged(), CustomEdit::clauseClicked(), MetadataOptions::customEvent(), CustomPriority::deleteClicked(), ImportMusicDialog::doScan(), NetSearch::doSearch(), LocationDialog::doSearch(), PhrasePopup::editChanged(), SearchInputDialog::editChanged(), MythUIFileBrowser::editLostFocus(), CriteriaRowEditor::enableSaveButton(), SelectDestination::filenameEditLostFocus(), MetadataOptions::FindNetArt(), Ripper::genreChanged(), ChannelEditor::GetText(), MetadataOptions::HandleDownloadedImages(), SelectDestination::handleFind(), CustomPriority::installClicked(), CustomPriority::loadData(), FileSelector::locationEditLostFocus(), ImportMusicDialog::locationPressed(), ImportIconsWizard::manualSearch(), PhrasePopup::okClicked(), EditPowerSearchPopup::okClicked(), EditMetadataDialog::okPressed(), MythUIFileBrowser::OKPressed(), PasswordChange::OldPasswordChanged(), MetadataOptions::OnImageSearchListSelection(), FileAssocDialog::OnPlayerCommandChanged(), RSSEditPopup::parseAndSave(), MetadataOptions::PerformQuery(), CustomEdit::recordClicked(), ManualSchedule::recordClicked(), PhrasePopup::recordClicked(), BookmarkEditor::Save(), MythNewsEditor::Save(), MetadataOptions::Save(), RecMetadataEdit::SaveChanges(), CriteriaRowEditor::saveClicked(), SelectDestination::saveConfiguration(), SearchButtonListDialog::searchChanged(), MythTextInputDialog::sendResult(), PasswordChange::SendResult(), EditRomInfoDialog::SetCountry(), SelectDestination::setDestination(), EditMetadataDialog::SetDirector(), GalleryFilterDialog::setDirFilter(), EditRomInfoDialog::SetGamename(), EditRomInfoDialog::SetGenre(), EditMetadataDialog::SetHomepage(), EditMetadataDialog::SetInetRef(), EditMetadataDialog::SetPlayer(), EditRomInfoDialog::SetPlot(), EditMetadataDialog::SetPlot(), EditRomInfoDialog::SetPublisher(), EditMetadataDialog::SetRating(), EditMetadataDialog::SetSubtitle(), EditMetadataDialog::SetTagline(), VideoFilterDialog::setTextFilter(), EditMetadataDialog::SetTitle(), EditRomInfoDialog::SetYear(), BookmarkEditor::slotFindCategory(), ImportSettings::slotSave(), GeneralSettings::slotSave(), PlayerSettings::slotSave(), BrowserConfig::slotSave(), RSSEditPopup::slotSave(), MythUISearchDialog::slotUpdateList(), CustomEdit::storeClicked(), CustomEdit::storeRule(), CustomEdit::testClicked(), CustomPriority::testSchedule(), CustomPriority::textChanged(), CustomEdit::textChanged(), EditMetadataDialog::updateArtistImage(), EditMetadataDialog::updateGenreImage(), EditMetadataCommon::updateMetadata(), SearchView::updateTracksList(), CriteriaRowEditor::valueButtonClicked(), RawSettingsEditor::valueChanged(), MetadataOptions::ValuesChanged(), Ripper::yearChanged(), and ImportMusicDialog::~ImportMusicDialog().

void MythUITextEdit::SetPassword ( bool  isPassword) [inline]

Definition at line 300 of file mythuitextedit.cpp.

Referenced by InsertCharacter(), keyPressEvent(), RemoveCharacter(), and SetText().

Definition at line 55 of file mythuitextedit.h.

Definition at line 56 of file mythuitextedit.h.

Referenced by MythUIVirtualKeyboard::MythUIVirtualKeyboard().

void MythUITextEdit::SetDBValue ( const QString &  text) [inline, virtual]

Implements StorageUser.

Definition at line 59 of file mythuitextedit.h.

QString MythUITextEdit::GetDBValue ( void  ) const [inline, virtual]

Implements StorageUser.

Definition at line 60 of file mythuitextedit.h.

Referenced by InsertText(), and SetText().

Definition at line 61 of file mythuitextedit.cpp.

Referenced by MythUITextEdit().

Definition at line 67 of file mythuitextedit.cpp.

Referenced by MythUITextEdit().

bool MythUITextEdit::ParseElement ( const QString &  filename,
QDomElement &  element,
bool  showWarnings 
) [protected, virtual]

Parse the xml definition of this widget setting the state of the object accordingly.

Reimplemented from MythUIType.

Definition at line 108 of file mythuitextedit.cpp.

void MythUITextEdit::CopyFrom ( MythUIType base) [protected, virtual]

Copy this widgets state from another.

Reimplemented from MythUIType.

Definition at line 523 of file mythuitextedit.cpp.

Referenced by CreateCopy().

void MythUITextEdit::CreateCopy ( MythUIType parent) [protected, virtual]

Copy the state of this widget to the one given, it must be of the same type.

Reimplemented from MythUIType.

Definition at line 547 of file mythuitextedit.cpp.

void MythUITextEdit::Finalize ( void  ) [protected, virtual]

Perform any post-xml parsing initialisation tasks.

This is called after the widget has been created and it's state established by ParseElement() or CopyFrom(). A derived class should use this to perform any initialisation tasks which should occur after this point.

Reimplemented from MythUIType.

Definition at line 146 of file mythuitextedit.cpp.

void MythUITextEdit::Init ( void  ) [protected]

Definition at line 162 of file mythuitextedit.cpp.

Referenced by CopyFrom(), and Finalize().

bool MythUITextEdit::InsertCharacter ( const QString &  character) [protected]

Definition at line 254 of file mythuitextedit.cpp.

Referenced by InsertText(), and keyPressEvent().

void MythUITextEdit::RemoveCharacter ( int  position) [protected]

Definition at line 286 of file mythuitextedit.cpp.

Referenced by keyPressEvent().

Definition at line 328 of file mythuitextedit.cpp.

Referenced by keyPressEvent().

Definition at line 334 of file mythuitextedit.cpp.

Referenced by CutTextToClipboard(), and keyPressEvent().

void MythUITextEdit::PasteTextFromClipboard ( QClipboard::Mode  mode = QClipboard::Clipboard) [protected]

Definition at line 341 of file mythuitextedit.cpp.

Referenced by gestureEvent(), and keyPressEvent().


Member Data Documentation

Definition at line 86 of file mythuitextedit.h.

Referenced by MythUITextEdit(), and SetInitialStates().

Definition at line 88 of file mythuitextedit.h.

Referenced by CopyFrom(), MythUITextEdit(), and Pulse().

Definition at line 89 of file mythuitextedit.h.

Referenced by CopyFrom(), MythUITextEdit(), and Pulse().

Definition at line 90 of file mythuitextedit.h.

Referenced by keyPressEvent(), MythUITextEdit(), and Pulse().

Definition at line 92 of file mythuitextedit.h.

Referenced by CopyFrom(), InsertCharacter(), MythUITextEdit(), and SetMaxLength().

QString MythUITextEdit::m_Message [protected]

Definition at line 95 of file mythuitextedit.h.

Referenced by CopyFrom(), InsertCharacter(), and MythUITextEdit().

Definition at line 98 of file mythuitextedit.h.

Referenced by MythUITextEdit(), and SetText().

Definition at line 100 of file mythuitextedit.h.

Referenced by CopyFrom(), MythUITextEdit(), and ParseElement().

Definition at line 102 of file mythuitextedit.h.

Referenced by Deselect(), MythUITextEdit(), Select(), and SetInitialStates().

Definition at line 103 of file mythuitextedit.h.

Referenced by Finalize(), MoveCursor(), MythUITextEdit(), Pulse(), and SetInitialStates().

Definition at line 106 of file mythuitextedit.h.

Referenced by keyPressEvent(), and MythUITextEdit().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends