Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
|
#include <qlineedit_p.h>
Classes | |
struct | SideWidgetEntry |
struct | SideWidgetParameters |
Static Public Member Functions | |
static QLineEditPrivate * | get (QLineEdit *lineEdit) |
Static Public Member Functions inherited from QWidgetPrivate | |
static QWidgetPrivate * | get (QWidget *w) |
static const QWidgetPrivate * | get (const QWidget *w) |
static void | checkRestoredGeometry (const QRect &availableGeometry, QRect *restoredGeometry, int frameHeight) |
static void | adjustFlags (Qt::WindowFlags &flags, QWidget *w=nullptr) |
static QWidget * | parentGraphicsView (const QWidget *widget) |
static QRect | screenGeometry (const QWidget *widget) |
static QRect | availableScreenGeometry (const QWidget *widget) |
static QScreen * | screen (const QWidget *widget, const QPoint &globalPosition, bool hasPosition=true) |
static QRect | screenGeometry (const QWidget *widget, const QPoint &globalPosition, bool hasPosition=true) |
static QRect | availableScreenGeometry (const QWidget *widget, const QPoint &globalPosition, bool hasPosition=true) |
static void | sendComposeStatus (QWidget *w, bool end) |
static void | setWidgetParentHelper (QObject *widgetAsObject, QObject *newParent) |
static bool | insertIntoFocusChain (const QWidgetList &toBeInserted, FocusDirection direction, QWidget *position) |
static QWidgetList | takeFromFocusChain (QWidget *from, QWidget *to, FocusDirection direction=FocusDirection::Next) |
Static Public Member Functions inherited from QObjectPrivate | |
static bool | removeConnection (Connection *c) |
static QObjectPrivate * | get (QObject *o) |
static const QObjectPrivate * | get (const QObject *o) |
template<typename Func1 , typename Func2 > | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1 , typename Func2 > | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot) |
static QMetaObject::Connection | connectImpl (const QObject *sender, int signal_index, const QObject *receiver, void **slot, QtPrivate::QSlotObjectBase *slotObj, int type, const int *types, const QMetaObject *senderMetaObject) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static QMetaObject::Connection | connect (const QObject *sender, int signal_index, const QObject *receiver, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type) |
static bool | disconnect (const QObject *sender, int signal_index, void **slot) |
static bool | disconnect (const QObject *sender, int signal_index, const QObject *receiver, void **slot) |
Static Public Attributes | |
static const int | verticalMargin |
static const int | horizontalMargin |
Static Public Attributes inherited from QWidgetPrivate | |
static QWidgetMapper * | mapper = nullptr |
static QWidgetSet * | allWidgets = nullptr |
static int | instanceCounter = 0 |
static int | maxInstances = 0 |
Friends | |
class | QTypeInfo< SideWidgetLocation > |
Definition at line 96 of file qlineedit_p.h.
typedef std::vector<SideWidgetEntry> QLineEditPrivate::SideWidgetEntryList |
Definition at line 113 of file qlineedit_p.h.
Enumerator | |
---|---|
SideWidgetFadeInWithText | |
SideWidgetCreatedByWidgetAction | |
SideWidgetClearButton |
Definition at line 100 of file qlineedit_p.h.
|
inline |
Definition at line 122 of file qlineedit_p.h.
|
inline |
Definition at line 131 of file qlineedit_p.h.
QRect QLineEditPrivate::adjustedContentsRect | ( | ) | const |
Definition at line 251 of file qlineedit_p.cpp.
References effectiveTextMargins(), QRect::marginsRemoved(), opt, and QStyle::SE_LineEditContents.
Referenced by adjustedControlRect(), inSelection(), and xToPos().
Definition at line 38 of file qlineedit_p.cpp.
References adjustedContentsRect(), QWidgetLineControl::ascent(), control, fontMetrics, horizontalMargin, hscroll, QRect::isEmpty(), rect, vscroll, and QRect::x().
Referenced by cursorRect(), and updateNeeded().
void QLineEditPrivate::clearButtonClicked | ( | ) |
Definition at line 477 of file qlineedit_p.cpp.
QIcon QLineEditPrivate::clearButtonIcon | ( | ) | const |
Definition at line 505 of file qlineedit_p.cpp.
References QStyle::SP_LineEditClearButton.
void QLineEditPrivate::controlEditingFinished | ( | ) |
Definition at line 486 of file qlineedit_p.cpp.
References emit.
Referenced by init().
void QLineEditPrivate::cursorPositionChanged | ( | int | from, |
int | to ) |
Definition at line 135 of file qlineedit_p.cpp.
References emit.
Referenced by init().
QRect QLineEditPrivate::cursorRect | ( | ) | const |
Definition at line 71 of file qlineedit_p.cpp.
References adjustedControlRect(), control, and QWidgetLineControl::cursorRect().
Referenced by setCursorVisible().
QMargins QLineEditPrivate::effectiveTextMargins | ( | ) | const |
Definition at line 687 of file qlineedit_p.cpp.
References effectiveTextMargin().
Referenced by adjustedContentsRect().
|
inlinestatic |
Definition at line 171 of file qlineedit_p.h.
References lineEdit.
void QLineEditPrivate::handleWindowActivate | ( | ) |
Definition at line 116 of file qlineedit_p.cpp.
References control, QWidgetLineControl::deselect(), and QWidgetLineControl::hasSelectedText().
|
inline |
Definition at line 227 of file qlineedit_p.h.
Definition at line 175 of file qlineedit_p.cpp.
References QPalette::Base, QObject::connect(), QObjectPrivate::connect(), control, controlEditingFinished(), cursorPositionChanged(), QWidgetLineControl::cursorPositionChanged(), QWidgetLineControl::displayTextChanged(), QWidgetLineControl::editingFinished(), QSizePolicy::Expanding, QSizePolicy::Fixed, Qt::IBeamCursor, initMouseYThreshold(), QLineEdit::inputRejected(), QWidgetLineControl::inputRejected(), QSizePolicy::LineEdit, opt, selectionChanged(), QWidgetLineControl::selectionChanged(), QWidgetLineControl::setFont(), QObject::setParent(), QWidgetLineControl::setPasswordCharacter(), QWidgetLineControl::setPasswordMaskDelay(), QStyle::SH_LineEdit_PasswordCharacter, QStyle::SH_LineEdit_PasswordMaskDelay, Qt::StrongFocus, QLineEdit::textChanged(), QWidgetLineControl::textChanged(), textEdited(), QWidgetLineControl::textEdited(), txt, QWidget::update(), QWidgetLineControl::updateMicroFocus(), updateNeeded(), QWidgetLineControl::updateNeeded(), Qt::WA_InputMethodEnabled, Qt::WA_KeyCompression, and Qt::WA_MacShowFocusRect.
void QLineEditPrivate::initMouseYThreshold | ( | ) |
Definition at line 246 of file qlineedit_p.cpp.
References QGuiApplication::styleHints().
Referenced by init().
bool QLineEditPrivate::inSelection | ( | int | x | ) | const |
Definition at line 65 of file qlineedit_p.cpp.
References adjustedContentsRect(), control, horizontalMargin, hscroll, QWidgetLineControl::inSelection(), and QRect::x().
|
inline |
Definition at line 228 of file qlineedit_p.h.
References Qt::LeftToRight.
void QLineEditPrivate::positionSideWidgets | ( | ) |
Definition at line 527 of file qlineedit_p.cpp.
References QRect::height(), Q_UNUSED, and QRect::width().
void QLineEditPrivate::resetInputMethod | ( | ) |
Definition at line 286 of file qlineedit_p.cpp.
References QGuiApplication::inputMethod(), and qApp.
|
inline |
Definition at line 230 of file qlineedit_p.h.
References Qt::LeftToRight.
void QLineEditPrivate::selectionChanged | ( | ) |
Definition at line 150 of file qlineedit_p.cpp.
References control, QWidgetLineControl::cursorPosition(), emit, QWidgetLineControl::hasSelectedText(), QString::isEmpty(), opt, QWidgetLineControl::preeditAreaText(), QWidgetLineControl::selectionEnd(), QWidgetLineControl::selectionStart(), setCursorVisible(), and QStyle::SH_BlinkCursorWhenTextSelected.
Referenced by init().
bool QLineEditPrivate::sendMouseEventToInputContext | ( | QMouseEvent * | e | ) |
This function is not intended as polymorphic usage.
Just a shared code fragment that calls QInputMethod::invokeAction for this class.
Definition at line 299 of file qlineedit_p.cpp.
References QInputMethod::Click, QWidgetLineControl::composeMode(), control, QWidgetLineControl::cursor(), QGuiApplication::inputMethod(), QEvent::MouseButtonRelease, QSinglePointEvent::position(), QWidgetLineControl::preeditAreaText(), Q_UNUSED, QString::size(), QPointF::toPoint(), QEvent::type(), and xToPos().
void QLineEditPrivate::setClearButtonEnabled | ( | bool | enabled | ) |
Definition at line 513 of file qlineedit_p.cpp.
References Q_UNUSED.
void QLineEditPrivate::setCursorVisible | ( | bool | visible | ) |
Definition at line 261 of file qlineedit_p.cpp.
References control, cursorRect(), cursorVisible, QWidgetLineControl::inputMask(), and QString::isEmpty().
Referenced by selectionChanged().
Definition at line 273 of file qlineedit_p.cpp.
References control, edited, QWidgetLineControl::setText(), and text.
|
inline |
Definition at line 157 of file qlineedit_p.h.
References QWidgetLineControl::isReadOnly().
Referenced by updatePasswordEchoEditing().
|
inline |
Definition at line 165 of file qlineedit_p.h.
References Qt::AlignHCenter, alignment, QString::isEmpty(), QWidgetLineControl::preeditAreaText(), and QWidgetLineControl::text().
QLineEditPrivate::SideWidgetParameters QLineEditPrivate::sideWidgetParameters | ( | ) | const |
Definition at line 494 of file qlineedit_p.cpp.
References QLineEditPrivate::SideWidgetParameters::iconSize, QStyle::PM_LineEditIconMargin, and QStyle::PM_LineEditIconSize.
QString QLineEditPrivate::textAfterCursor | ( | int | curPos | ) | const |
Definition at line 59 of file qlineedit_p.cpp.
References control, QString::mid(), text, and QWidgetLineControl::text().
QString QLineEditPrivate::textBeforeCursor | ( | int | curPos | ) | const |
Definition at line 53 of file qlineedit_p.cpp.
References control, QString::mid(), text, and QWidgetLineControl::text().
Definition at line 462 of file qlineedit_p.cpp.
References QString::size(), and text.
Definition at line 123 of file qlineedit_p.cpp.
References control, edited, emit, QCompleter::InlineCompletion, and text.
Referenced by init().
Definition at line 170 of file qlineedit_p.cpp.
References adjustedControlRect(), and rect.
Referenced by init().
void QLineEditPrivate::updatePasswordEchoEditing | ( | bool | editing | ) |
Definition at line 279 of file qlineedit_p.cpp.
References control, shouldEnableInputMethod(), QWidgetLineControl::updatePasswordEchoEditing(), and Qt::WA_InputMethodEnabled.
int QLineEditPrivate::xToPos | ( | int | x, |
QTextLine::CursorPosition | betweenOrOn = QTextLine::CursorBetweenCharacters ) const |
Definition at line 46 of file qlineedit_p.cpp.
References adjustedContentsRect(), control, horizontalMargin, hscroll, QRect::x(), and QWidgetLineControl::xToPos().
Referenced by sendMouseEventToInputContext().
|
friend |
Definition at line 233 of file qlineedit_p.h.
uint QLineEditPrivate::alignment |
Definition at line 185 of file qlineedit_p.h.
uint QLineEditPrivate::clickCausedFocus |
Definition at line 181 of file qlineedit_p.h.
uint QLineEditPrivate::contextMenuEnabled |
Definition at line 178 of file qlineedit_p.h.
QWidgetLineControl* QLineEditPrivate::control |
Definition at line 135 of file qlineedit_p.h.
Referenced by adjustedControlRect(), cursorRect(), handleWindowActivate(), init(), inSelection(), selectionChanged(), sendMouseEventToInputContext(), setCursorVisible(), setText(), textAfterCursor(), textBeforeCursor(), textEdited(), updatePasswordEchoEditing(), and xToPos().
uint QLineEditPrivate::cursorVisible |
Definition at line 179 of file qlineedit_p.h.
Referenced by setCursorVisible().
uint QLineEditPrivate::dragEnabled |
Definition at line 180 of file qlineedit_p.h.
uint QLineEditPrivate::edited |
Definition at line 182 of file qlineedit_p.h.
Referenced by setText(), and textEdited().
uint QLineEditPrivate::frame |
Definition at line 177 of file qlineedit_p.h.
|
static |
Definition at line 187 of file qlineedit_p.h.
Referenced by adjustedControlRect(), inSelection(), QLineEdit::minimumSizeHint(), QLineEdit::paintEvent(), QLineEdit::sizeHint(), and xToPos().
int QLineEditPrivate::hscroll |
Definition at line 183 of file qlineedit_p.h.
Referenced by adjustedControlRect(), inSelection(), and xToPos().
QPoint QLineEditPrivate::mousePressPos |
Definition at line 206 of file qlineedit_p.h.
QString QLineEditPrivate::placeholderText |
Definition at line 217 of file qlineedit_p.h.
Definition at line 138 of file qlineedit_p.h.
QMargins QLineEditPrivate::textMargins |
Definition at line 215 of file qlineedit_p.h.
QPoint QLineEditPrivate::tripleClick |
Definition at line 175 of file qlineedit_p.h.
QBasicTimer QLineEditPrivate::tripleClickTimer |
Definition at line 176 of file qlineedit_p.h.
|
static |
Definition at line 186 of file qlineedit_p.h.
Referenced by QLineEdit::minimumSizeHint(), QLineEdit::paintEvent(), and QLineEdit::sizeHint().
int QLineEditPrivate::vscroll |
Definition at line 184 of file qlineedit_p.h.
Referenced by adjustedControlRect().