KDEUI
klineedit.h
Go to the documentation of this file.
279 KCompletionBox * completionBox( bool create = true ); // KDE5 TODO: make virtual, so konq can reimplement i
virtual void setCompletedItems(const QStringList &items, bool autoSuggest=true)=0
A pure virtual function that must be implemented by all inheriting classes.
virtual void setCompletedText(const QString &text)=0
A pure virtual function that must be implemented by all inheriting classes.
virtual void setCompletionObject(KCompletion *compObj, bool hsig=true)
Sets up the completion object to be used.
Definition kcompletionbase.cpp:109
KeyBindingType
Constants that represent the items whose short-cut key-binding is programmable.
Definition kcompletion.h:652
A helper widget for "completion-widgets" (KLineEdit, KComboBox))
Definition kcompletionbox.h:44
Completion
This enum describes the completion mode used for by the KCompletion class.
Definition kglobalsettings.h:179
QT_MOC_COMPAT void userTextChanged(const QString &)
Emitted when the text is changed NOT by the suggested autocompletion: either when the user is physica...
virtual void setContextMenuEnabled(bool showMenu)
Enables/disables the popup (context) menu.
Definition klineedit.cpp:1823
void aboutToShowContextMenu(QMenu *menu)
Emitted before the context menu is displayed.
virtual void setCompletionMode(KGlobalSettings::Completion mode)
Re-implemented from KCompletionBase for internal reasons.
Definition klineedit.cpp:400
virtual void resizeEvent(QResizeEvent *)
Re-implemented for internal reasons.
Definition klineedit.cpp:692
void setTrapReturnKey(bool trap)
By default, KLineEdit recognizes Key_Return and Key_Enter and emits the returnPressed() signals,...
Definition klineedit.cpp:1416
void setSqueezedTextEnabled(bool enable)
Enable text squeezing whenever the supplied text is too long.
Definition klineedit.cpp:559
void rotateText(KCompletionBase::KeyBindingType type)
Iterates through all possible matches of the completed text or the history list.
Definition klineedit.cpp:461
KLineEdit(const QString &string, QWidget *parent=0)
Constructs a KLineEdit object with a default text, a parent, and a name.
Definition klineedit.cpp:232
QMenu * createStandardContextMenu()
Re-implemented for internal reasons.
Definition klineedit.cpp:1180
virtual void setText(const QString &)
Re-implemented to enable text squeezing.
Definition klineedit.cpp:569
void setCompletionBox(KCompletionBox *box)
Set the completion-box to be used in completion mode KGlobalSettings::CompletionPopup.
Definition klineedit.cpp:1431
void setUserSelection(bool userSelection)
Sets the widget in userSelection mode or in automatic completion selection mode.
Definition klineedit.cpp:1661
virtual void keyPressEvent(QKeyEvent *)
Re-implemented for internal reasons.
Definition klineedit.cpp:702
void returnPressed(const QString &)
Emitted when the user presses the return key.
virtual void contextMenuEvent(QContextMenuEvent *)
Re-implemented for internal reasons.
Definition klineedit.cpp:1261
bool autoSuggest() const
Whether in current state text should be auto-suggested.
Definition klineedit.cpp:1726
void setClearButtonShown(bool show)
This makes the line edit display an icon on one side of the line edit which, when clicked,...
Definition klineedit.cpp:284
void textRotation(KCompletionBase::KeyBindingType)
Emitted when the text rotation key-bindings are pressed.
void setClickMessage(const QString &msg)
This makes the line edit display a grayed-out hinting text as long as the user didn't enter any text.
Definition klineedit.cpp:1815
void completionBoxActivated(const QString &)
Emitted whenever the completion box is activated.
void completionModeChanged(KGlobalSettings::Completion)
Emitted when the user changed the completion mode by using the popupmenu.
void setCompletionModeDisabled(KGlobalSettings::Completion mode, bool disable=true)
Disables completion modes by makeing them non-checkable.
Definition klineedit.cpp:427
void setUrlDropsEnabled(bool enable)
Enables/Disables handling of URL drops.
Definition klineedit.cpp:1406
void clearButtonClicked()
Emitted when the user clicked on the clear button.
virtual void mouseReleaseEvent(QMouseEvent *)
Re-implemented for internal reasons.
Definition klineedit.cpp:1144
void setSqueezedText(const QString &text)
Squeezes text into the line edit.
Definition klineedit.cpp:553
QString originalText() const
Returns the original text if text squeezing is enabled.
Definition klineedit.cpp:1713
virtual void mousePressEvent(QMouseEvent *)
Re-implemented for internal reasons.
Definition klineedit.cpp:1113
virtual void dropEvent(QDropEvent *)
Re-implemented to handle URI drops.
Definition klineedit.cpp:1321
KCompletionBox * completionBox(bool create=true)
Definition klineedit.cpp:1629
virtual void mouseDoubleClickEvent(QMouseEvent *)
Re-implemented for internal reasons.
Definition klineedit.cpp:1102
void substringCompletion(const QString &)
Emitted when the shortcut for substring completion is pressed.
virtual void copy() const
Reimplemented for internal reasons, the API is not affected.
Definition klineedit.cpp:657
bool isContextMenuEnabled() const
Returns true when the context menu is enabled.
Definition klineedit.cpp:1830
void userCancelled(const QString &cancelText)
Resets the current displayed text.
Definition klineedit.cpp:1465
bool isSqueezedTextEnabled() const
Returns true if text squeezing is enabled.
Definition klineedit.cpp:564
virtual void clear()
Reimplemented to workaround a buggy QLineEdit::clear() (changing the clipboard to the text we just ha...
Definition klineedit.cpp:1698
virtual void makeCompletion(const QString &)
Completes the remaining text with a matching one from a given list.
Definition klineedit.cpp:482
virtual void create(WId=0, bool initializeWindow=true, bool destroyOldWindow=true)
Reimplemented for internal reasons, the API is not affected.
Definition klineedit.cpp:1655
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.14.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.14.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.