Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
QTextBrowserPrivate Class Reference
+ Inheritance diagram for QTextBrowserPrivate:
+ Collaboration diagram for QTextBrowserPrivate:

Classes

struct  HistoryEntry
 

Public Member Functions

 QTextBrowserPrivate ()
 
void init ()
 
HistoryEntry history (int i) const
 
HistoryEntry createHistoryEntry () const
 
void restoreHistoryEntry (const HistoryEntry &entry)
 
QString findFile (const QUrl &name) const
 
void _q_documentModified ()
 
void _q_activateAnchor (const QString &href)
 
void _q_highlightLink (const QString &href)
 
void setSource (const QUrl &url, QTextDocument::ResourceType type)
 
virtual QUrl resolveUrl (const QUrl &url) const override
 
QUrl resolveUrl (const QString &url) const
 
void emitHighlighted (const QUrl &url)
 
- Public Member Functions inherited from QTextEditPrivate
 QTextEditPrivate ()
 
void init (const QString &html=QString())
 
void paint (QPainter *p, QPaintEvent *e)
 
void _q_repaintContents (const QRectF &contentsRect)
 
QPoint mapToContents (const QPoint &point) const
 
void _q_adjustScrollbars ()
 
void _q_ensureVisible (const QRectF &rect)
 
void relayoutDocument ()
 
void createAutoBulletList ()
 
void pageUpDown (QTextCursor::MoveOperation op, QTextCursor::MoveMode moveMode)
 
int horizontalOffset () const
 
int verticalOffset () const
 
void sendControlEvent (QEvent *e)
 
void _q_currentCharFormatChanged (const QTextCharFormat &format)
 
void _q_cursorPositionChanged ()
 
void _q_hoveredBlockWithMarkerChanged (const QTextBlock &block)
 
void updateDefaultTextOption ()
 
virtual QUrl resolveUrl (const QUrl &url) const
 

Public Attributes

QStack< HistoryEntrystack
 
QStack< HistoryEntryforwardStack
 
QUrl home
 
QUrl currentURL
 
QStringList searchPaths
 
bool textOrSourceChanged
 
bool forceLoadOnSourceChange
 
bool openExternalLinks
 
bool openLinks
 
QTextDocument::ResourceType currentType
 
QCursor oldCursor
 
- Public Attributes inherited from QTextEditPrivate
QWidgetTextControlcontrol
 
QTextEdit::AutoFormatting autoFormatting
 
bool tabChangesFocus
 
QBasicTimer autoScrollTimer
 
QPoint autoScrollDragPos
 
QTextEdit::LineWrapMode lineWrap
 
int lineWrapColumnOrWidth
 
QTextOption::WrapMode wordWrap
 
uint ignoreAutomaticScrollbarAdjustment: 1
 
uint preferRichText: 1
 
uint showCursorOnInitialShow: 1
 
uint inDrag: 1
 
uint clickCausedFocus: 1
 
Qt::TextFormat textFormat
 
QString anchorToScrollToWhenVisible
 
QString placeholderText
 
Qt::CursorShape cursorToRestoreAfterHover = Qt::IBeamCursor
 

Detailed Description

Definition at line 38 of file qtextbrowser.cpp.

Constructor & Destructor Documentation

◆ QTextBrowserPrivate()

QTextBrowserPrivate::QTextBrowserPrivate ( )
inline

Definition at line 42 of file qtextbrowser.cpp.

Member Function Documentation

◆ _q_activateAnchor()

void QTextBrowserPrivate::_q_activateAnchor ( const QString href)

Definition at line 193 of file qtextbrowser.cpp.

References currentURL, emit, QString::isEmpty(), QUrl::isRelative(), oldCursor, openExternalLinks, openLinks, QDesktopServices::openUrl(), resolveUrl(), QUrl::scheme(), textOrSourceChanged, url, and viewport().

Referenced by init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ _q_documentModified()

void QTextBrowserPrivate::_q_documentModified ( )
inline

Definition at line 106 of file qtextbrowser.cpp.

References QString::isEmpty(), and QUrl::path().

Referenced by init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ _q_highlightLink()

void QTextBrowserPrivate::_q_highlightLink ( const QString href)

Definition at line 234 of file qtextbrowser.cpp.

References emitHighlighted(), QString::isEmpty(), oldCursor, Qt::PointingHandCursor, resolveUrl(), url, and viewport().

Referenced by init().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ createHistoryEntry()

QTextBrowserPrivate::HistoryEntry QTextBrowserPrivate::createHistoryEntry ( ) const

Definition at line 553 of file qtextbrowser.cpp.

References QTextEditPrivate::control, cursor, QWidgetTextControl::cursorIsFocusIndicator(), and QWidgetTextControl::textCursor().

+ Here is the call graph for this function:

◆ emitHighlighted()

void QTextBrowserPrivate::emitHighlighted ( const QUrl url)
inline

Definition at line 127 of file qtextbrowser.cpp.

References emit, and url.

Referenced by _q_highlightLink(), restoreHistoryEntry(), and setSource().

+ Here is the caller graph for this function:

◆ findFile()

QString QTextBrowserPrivate::findFile ( const QUrl name) const

Definition at line 135 of file qtextbrowser.cpp.

References fileName, QFileInfo::isReadable(), and searchPaths.

+ Here is the call graph for this function:

◆ history()

HistoryEntry QTextBrowserPrivate::history ( int  i) const
inline

Definition at line 64 of file qtextbrowser.cpp.

References i.

◆ init()

void QTextBrowserPrivate::init ( )

Definition at line 663 of file qtextbrowser.cpp.

References _q_activateAnchor(), _q_documentModified(), _q_highlightLink(), QObject::connect(), QTextEditPrivate::control, oldCursor, QWidgetTextControl::setTextInteractionFlags(), shouldEnableInputMethod(), SIGNAL, SLOT, Qt::TextBrowserInteraction, viewport(), and Qt::WA_InputMethodEnabled.

+ Here is the call graph for this function:

◆ resolveUrl() [1/2]

QUrl QTextBrowserPrivate::resolveUrl ( const QString url) const
inline

Definition at line 119 of file qtextbrowser.cpp.

References url.

◆ resolveUrl() [2/2]

QUrl QTextBrowserPrivate::resolveUrl ( const QUrl url) const
overridevirtual

Reimplemented from QTextEditPrivate.

Definition at line 168 of file qtextbrowser.cpp.

References QFileInfo::absolutePath(), currentURL, QFileInfo::exists(), fi, QUrl::fromLocalFile(), QUrl::hasFragment(), QFileInfo::isAbsolute(), QString::isEmpty(), QUrl::isRelative(), QUrl::path(), QUrl::resolved(), QUrl::scheme(), QDir::separator(), QUrl::toLocalFile(), and url.

Referenced by _q_activateAnchor(), _q_highlightLink(), restoreHistoryEntry(), and setSource().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ restoreHistoryEntry()

void QTextBrowserPrivate::restoreHistoryEntry ( const HistoryEntry entry)

Definition at line 572 of file qtextbrowser.cpp.

References QTextEditPrivate::control, cursor, QWidgetTextControl::document(), emitHighlighted(), QTextCursor::KeepAnchor, resolveUrl(), QWidgetTextControl::setCursorIsFocusIndicator(), setSource(), QWidgetTextControl::setTextCursor(), QWidgetTextControl::textCursor(), and url.

+ Here is the call graph for this function:

◆ setSource()

Member Data Documentation

◆ currentType

QTextDocument::ResourceType QTextBrowserPrivate::currentType

Definition at line 98 of file qtextbrowser.cpp.

Referenced by setSource().

◆ currentURL

QUrl QTextBrowserPrivate::currentURL

Definition at line 85 of file qtextbrowser.cpp.

Referenced by _q_activateAnchor(), resolveUrl(), and setSource().

◆ forceLoadOnSourceChange

bool QTextBrowserPrivate::forceLoadOnSourceChange

Definition at line 93 of file qtextbrowser.cpp.

Referenced by setSource().

◆ forwardStack

QStack<HistoryEntry> QTextBrowserPrivate::forwardStack

Definition at line 83 of file qtextbrowser.cpp.

◆ home

QUrl QTextBrowserPrivate::home

Definition at line 84 of file qtextbrowser.cpp.

Referenced by setSource().

◆ oldCursor

QCursor QTextBrowserPrivate::oldCursor

Definition at line 101 of file qtextbrowser.cpp.

Referenced by _q_activateAnchor(), _q_highlightLink(), and init().

◆ openExternalLinks

bool QTextBrowserPrivate::openExternalLinks

Definition at line 95 of file qtextbrowser.cpp.

Referenced by _q_activateAnchor().

◆ openLinks

bool QTextBrowserPrivate::openLinks

Definition at line 96 of file qtextbrowser.cpp.

Referenced by _q_activateAnchor().

◆ searchPaths

QStringList QTextBrowserPrivate::searchPaths

Definition at line 87 of file qtextbrowser.cpp.

Referenced by findFile().

◆ stack

QStack<HistoryEntry> QTextBrowserPrivate::stack

Definition at line 82 of file qtextbrowser.cpp.

◆ textOrSourceChanged

bool QTextBrowserPrivate::textOrSourceChanged

Definition at line 92 of file qtextbrowser.cpp.

Referenced by _q_activateAnchor(), and setSource().


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