Participer au site avec un Tip
Rechercher
 

Améliorations / Corrections

Vous avez des améliorations (ou des corrections) à proposer pour ce document : je vous remerçie par avance de m'en faire part, cela m'aide à améliorer le site.

Emplacement :

Description des améliorations :

Module « PySide2.QtGui »

Classe « QTextDocument »

Informations générales

Héritage

builtins.object
    Object
        QObject
            QTextDocument

Définition

class QTextDocument(QObject):

Description [extrait de QTextDocument.__doc__]

QTextDocument(self, parent: typing.Union[PySide2.QtCore.QObject, NoneType] = None)
QTextDocument(self, text: str, parent: typing.Union[PySide2.QtCore.QObject, NoneType] = None)

Constructeur(s)

Signature du constructeur Description
__new__(*args, **kwargs) Create and return a new object. See help(type) for accurate signature. [extrait de __new__.__doc__]
__init__(self, /, *args, **kwargs) Initialize self. See help(type(self)) for accurate signature. [extrait de __init__.__doc__]

Liste des attributs statiques

Nom de l'attribut Valeur
DocumentTitlePySide2.QtGui.QTextDocument.MetaInformation.DocumentTitle
DocumentUrlPySide2.QtGui.QTextDocument.MetaInformation.DocumentUrl
FindBackwardPySide2.QtGui.QTextDocument.FindFlag.FindBackward
FindCaseSensitivelyPySide2.QtGui.QTextDocument.FindFlag.FindCaseSensitively
FindWholeWordsPySide2.QtGui.QTextDocument.FindFlag.FindWholeWords
HtmlResourcePySide2.QtGui.QTextDocument.ResourceType.HtmlResource
ImageResourcePySide2.QtGui.QTextDocument.ResourceType.ImageResource
MarkdownDialectCommonMarkPySide2.QtGui.QTextDocument.MarkdownFeature.MarkdownDialectCommonMark
MarkdownDialectGitHubPySide2.QtGui.QTextDocument.MarkdownFeature.MarkdownDialectGitHub
MarkdownNoHTMLPySide2.QtGui.QTextDocument.MarkdownFeature.MarkdownNoHTML
MarkdownResourcePySide2.QtGui.QTextDocument.ResourceType.MarkdownResource
RedoStackPySide2.QtGui.QTextDocument.Stacks.RedoStack
staticMetaObject<PySide2.QtCore.QMetaObject object at 0x7efe36a7a8c0>
StyleSheetResourcePySide2.QtGui.QTextDocument.ResourceType.StyleSheetResource
UndoAndRedoStacksPySide2.QtGui.QTextDocument.Stacks.UndoAndRedoStacks
UndoStackPySide2.QtGui.QTextDocument.Stacks.UndoStack
UnknownResourcePySide2.QtGui.QTextDocument.ResourceType.UnknownResource
UserResourcePySide2.QtGui.QTextDocument.ResourceType.UserResource

Liste des opérateurs

Opérateurs hérités de la classe object

__eq__, __ge__, __gt__, __le__, __lt__, __ne__

Liste des méthodes

Toutes les méthodes Méthodes d'instance Méthodes statiques Méthodes dépréciées
Signature de la méthodeDescription
__delattr__(self, name) Implement delattr(self, name). [extrait de __delattr__.__doc__]
__setattr__(self, name, value) Implement setattr(self, name, value). [extrait de __setattr__.__doc__]
addResource(self, type: int, name: PySide2.QtCore.QUrl, resource: typing.Any) addResource(self, type: int, name: PySide2.QtCore.QUrl, resource: typing.Any) [extrait de addResource.__doc__]
adjustSize(self) adjustSize(self) [extrait de adjustSize.__doc__]
allFormats(self) -> typing.List[PySide2.QtGui.QTextFormat] allFormats(self) -> typing.List[PySide2.QtGui.QTextFormat] [extrait de allFormats.__doc__]
availableRedoSteps(self) -> int availableRedoSteps(self) -> int [extrait de availableRedoSteps.__doc__]
availableUndoSteps(self) -> int availableUndoSteps(self) -> int [extrait de availableUndoSteps.__doc__]
baseUrl(self) -> PySide2.QtCore.QUrl baseUrl(self) -> PySide2.QtCore.QUrl [extrait de baseUrl.__doc__]
baseUrlChanged
begin(self) -> PySide2.QtGui.QTextBlock begin(self) -> PySide2.QtGui.QTextBlock [extrait de begin.__doc__]
blockCount(self) -> int blockCount(self) -> int [extrait de blockCount.__doc__]
blockCountChanged
characterAt(self, pos: int) -> str characterAt(self, pos: int) -> str [extrait de characterAt.__doc__]
characterCount(self) -> int characterCount(self) -> int [extrait de characterCount.__doc__]
clear(self) clear(self) [extrait de clear.__doc__]
clearUndoRedoStacks(self, historyToClear: PySide2.QtGui.QTextDocument.Stacks = PySide2.QtGui.QTextDocument.Stacks.UndoAndRedoStacks) clearUndoRedoStacks(self, historyToClear: PySide2.QtGui.QTextDocument.Stacks = PySide2.QtGui.QTextDocument.Stacks.UndoAndRedoStacks) [extrait de clearUndoRedoStacks.__doc__]
clone(self, parent: typing.Union[PySide2.QtCore.QObject, NoneType] = None) -> PySide2.QtGui.QTextDocument clone(self, parent: typing.Union[PySide2.QtCore.QObject, NoneType] = None) -> PySide2.QtGui.QTextDocument [extrait de clone.__doc__]
contentsChange
contentsChanged
createObject(self, f: PySide2.QtGui.QTextFormat) -> PySide2.QtGui.QTextObject createObject(self, f: PySide2.QtGui.QTextFormat) -> PySide2.QtGui.QTextObject [extrait de createObject.__doc__]
cursorPositionChanged
defaultCursorMoveStyle(self) -> PySide2.QtCore.Qt.CursorMoveStyle defaultCursorMoveStyle(self) -> PySide2.QtCore.Qt.CursorMoveStyle [extrait de defaultCursorMoveStyle.__doc__]
defaultFont(self) -> PySide2.QtGui.QFont defaultFont(self) -> PySide2.QtGui.QFont [extrait de defaultFont.__doc__]
defaultStyleSheet(self) -> str defaultStyleSheet(self) -> str [extrait de defaultStyleSheet.__doc__]
defaultTextOption(self) -> PySide2.QtGui.QTextOption defaultTextOption(self) -> PySide2.QtGui.QTextOption [extrait de defaultTextOption.__doc__]
destroyed
documentLayout(self) -> PySide2.QtGui.QAbstractTextDocumentLayout documentLayout(self) -> PySide2.QtGui.QAbstractTextDocumentLayout [extrait de documentLayout.__doc__]
documentLayoutChanged
documentMargin(self) -> float documentMargin(self) -> float [extrait de documentMargin.__doc__]
drawContents(self, painter: PySide2.QtGui.QPainter, rect: PySide2.QtCore.QRectF = Default(QRectF)) drawContents(self, painter: PySide2.QtGui.QPainter, rect: PySide2.QtCore.QRectF = Default(QRectF)) [extrait de drawContents.__doc__]
end(self) -> PySide2.QtGui.QTextBlock end(self) -> PySide2.QtGui.QTextBlock [extrait de end.__doc__]
find find(self, expr: PySide2.QtCore.QRegExp, cursor: PySide2.QtGui.QTextCursor, options: PySide2.QtGui.QTextDocument.FindFlags = Default(QTextDocument.FindFlags)) -> PySide2.QtGui.QTextCursor [extrait de find.__doc__]
findBlock(self, pos: int) -> PySide2.QtGui.QTextBlock findBlock(self, pos: int) -> PySide2.QtGui.QTextBlock [extrait de findBlock.__doc__]
findBlockByLineNumber(self, blockNumber: int) -> PySide2.QtGui.QTextBlock findBlockByLineNumber(self, blockNumber: int) -> PySide2.QtGui.QTextBlock [extrait de findBlockByLineNumber.__doc__]
findBlockByNumber(self, blockNumber: int) -> PySide2.QtGui.QTextBlock findBlockByNumber(self, blockNumber: int) -> PySide2.QtGui.QTextBlock [extrait de findBlockByNumber.__doc__]
FindFlag
FindFlags
firstBlock(self) -> PySide2.QtGui.QTextBlock firstBlock(self) -> PySide2.QtGui.QTextBlock [extrait de firstBlock.__doc__]
frameAt(self, pos: int) -> PySide2.QtGui.QTextFrame frameAt(self, pos: int) -> PySide2.QtGui.QTextFrame [extrait de frameAt.__doc__]
idealWidth(self) -> float idealWidth(self) -> float [extrait de idealWidth.__doc__]
indentWidth(self) -> float indentWidth(self) -> float [extrait de indentWidth.__doc__]
isEmpty(self) -> bool isEmpty(self) -> bool [extrait de isEmpty.__doc__]
isModified(self) -> bool isModified(self) -> bool [extrait de isModified.__doc__]
isRedoAvailable(self) -> bool isRedoAvailable(self) -> bool [extrait de isRedoAvailable.__doc__]
isUndoAvailable(self) -> bool isUndoAvailable(self) -> bool [extrait de isUndoAvailable.__doc__]
isUndoRedoEnabled(self) -> bool isUndoRedoEnabled(self) -> bool [extrait de isUndoRedoEnabled.__doc__]
lastBlock(self) -> PySide2.QtGui.QTextBlock lastBlock(self) -> PySide2.QtGui.QTextBlock [extrait de lastBlock.__doc__]
lineCount(self) -> int lineCount(self) -> int [extrait de lineCount.__doc__]
loadResource(self, type: int, name: PySide2.QtCore.QUrl) -> typing.Any loadResource(self, type: int, name: PySide2.QtCore.QUrl) -> typing.Any [extrait de loadResource.__doc__]
markContentsDirty(self, from_: int, length: int) markContentsDirty(self, from_: int, length: int) [extrait de markContentsDirty.__doc__]
MarkdownFeature
MarkdownFeatures
maximumBlockCount(self) -> int maximumBlockCount(self) -> int [extrait de maximumBlockCount.__doc__]
MetaInformation
metaInformation(self, info: PySide2.QtGui.QTextDocument.MetaInformation) -> str metaInformation(self, info: PySide2.QtGui.QTextDocument.MetaInformation) -> str [extrait de metaInformation.__doc__]
modificationChanged
object(self, objectIndex: int) -> PySide2.QtGui.QTextObject object(self, objectIndex: int) -> PySide2.QtGui.QTextObject [extrait de object.__doc__]
objectForFormat(self, arg__1: PySide2.QtGui.QTextFormat) -> PySide2.QtGui.QTextObject objectForFormat(self, arg__1: PySide2.QtGui.QTextFormat) -> PySide2.QtGui.QTextObject [extrait de objectForFormat.__doc__]
objectNameChanged
pageCount(self) -> int pageCount(self) -> int [extrait de pageCount.__doc__]
pageSize(self) -> PySide2.QtCore.QSizeF pageSize(self) -> PySide2.QtCore.QSizeF [extrait de pageSize.__doc__]
print_(self, printer: PySide2.QtGui.QPagedPaintDevice) print_(self, printer: PySide2.QtGui.QPagedPaintDevice) [extrait de print_.__doc__]
redo redo(self) [extrait de redo.__doc__]
redoAvailable
resource(self, type: int, name: PySide2.QtCore.QUrl) -> typing.Any resource(self, type: int, name: PySide2.QtCore.QUrl) -> typing.Any [extrait de resource.__doc__]
ResourceType
revision(self) -> int revision(self) -> int [extrait de revision.__doc__]
rootFrame(self) -> PySide2.QtGui.QTextFrame rootFrame(self) -> PySide2.QtGui.QTextFrame [extrait de rootFrame.__doc__]
setBaseUrl(self, url: PySide2.QtCore.QUrl) setBaseUrl(self, url: PySide2.QtCore.QUrl) [extrait de setBaseUrl.__doc__]
setDefaultCursorMoveStyle(self, style: PySide2.QtCore.Qt.CursorMoveStyle) setDefaultCursorMoveStyle(self, style: PySide2.QtCore.Qt.CursorMoveStyle) [extrait de setDefaultCursorMoveStyle.__doc__]
setDefaultFont(self, font: PySide2.QtGui.QFont) setDefaultFont(self, font: PySide2.QtGui.QFont) [extrait de setDefaultFont.__doc__]
setDefaultStyleSheet(self, sheet: str) setDefaultStyleSheet(self, sheet: str) [extrait de setDefaultStyleSheet.__doc__]
setDefaultTextOption(self, option: PySide2.QtGui.QTextOption) setDefaultTextOption(self, option: PySide2.QtGui.QTextOption) [extrait de setDefaultTextOption.__doc__]
setDocumentLayout(self, layout: PySide2.QtGui.QAbstractTextDocumentLayout) setDocumentLayout(self, layout: PySide2.QtGui.QAbstractTextDocumentLayout) [extrait de setDocumentLayout.__doc__]
setDocumentMargin(self, margin: float) setDocumentMargin(self, margin: float) [extrait de setDocumentMargin.__doc__]
setHtml(self, html: str) setHtml(self, html: str) [extrait de setHtml.__doc__]
setIndentWidth(self, width: float) setIndentWidth(self, width: float) [extrait de setIndentWidth.__doc__]
setMarkdown(self, markdown: str, features: PySide2.QtGui.QTextDocument.MarkdownFeatures = PySide2.QtGui.QTextDocument.MarkdownFeature.MarkdownDialectGitHub) setMarkdown(self, markdown: str, features: PySide2.QtGui.QTextDocument.MarkdownFeatures = PySide2.QtGui.QTextDocument.MarkdownFeature.MarkdownDialectGitHub) [extrait de setMarkdown.__doc__]
setMaximumBlockCount(self, maximum: int) setMaximumBlockCount(self, maximum: int) [extrait de setMaximumBlockCount.__doc__]
setMetaInformation(self, info: PySide2.QtGui.QTextDocument.MetaInformation, arg__2: str) setMetaInformation(self, info: PySide2.QtGui.QTextDocument.MetaInformation, arg__2: str) [extrait de setMetaInformation.__doc__]
setModified(self, m: bool = True) setModified(self, m: bool = True) [extrait de setModified.__doc__]
setPageSize(self, size: PySide2.QtCore.QSizeF) setPageSize(self, size: PySide2.QtCore.QSizeF) [extrait de setPageSize.__doc__]
setPlainText(self, text: str) setPlainText(self, text: str) [extrait de setPlainText.__doc__]
setTextWidth(self, width: float) setTextWidth(self, width: float) [extrait de setTextWidth.__doc__]
setUndoRedoEnabled(self, enable: bool) setUndoRedoEnabled(self, enable: bool) [extrait de setUndoRedoEnabled.__doc__]
setUseDesignMetrics(self, b: bool) setUseDesignMetrics(self, b: bool) [extrait de setUseDesignMetrics.__doc__]
size(self) -> PySide2.QtCore.QSizeF size(self) -> PySide2.QtCore.QSizeF [extrait de size.__doc__]
Stacks
textWidth(self) -> float textWidth(self) -> float [extrait de textWidth.__doc__]
toHtml(self, encoding: PySide2.QtCore.QByteArray = Default(QByteArray)) -> str toHtml(self, encoding: PySide2.QtCore.QByteArray = Default(QByteArray)) -> str [extrait de toHtml.__doc__]
toMarkdown(self, features: PySide2.QtGui.QTextDocument.MarkdownFeatures = PySide2.QtGui.QTextDocument.MarkdownFeature.MarkdownDialectGitHub) -> str toMarkdown(self, features: PySide2.QtGui.QTextDocument.MarkdownFeatures = PySide2.QtGui.QTextDocument.MarkdownFeature.MarkdownDialectGitHub) -> str [extrait de toMarkdown.__doc__]
toPlainText(self) -> str toPlainText(self) -> str [extrait de toPlainText.__doc__]
toRawText(self) -> str toRawText(self) -> str [extrait de toRawText.__doc__]
undo undo(self) [extrait de undo.__doc__]
undoAvailable
undoCommandAdded
useDesignMetrics(self) -> bool useDesignMetrics(self) -> bool [extrait de useDesignMetrics.__doc__]

Méthodes héritées de la classe QObject

__getattribute__, __init_subclass__, __repr__, __subclasshook__, blockSignals, childEvent, children, connect, connectNotify, customEvent, deleteLater, disconnect, disconnectNotify, dumpObjectInfo, dumpObjectTree, dynamicPropertyNames, emit, event, eventFilter, findChild, findChildren, inherits, installEventFilter, isSignalConnected, isWidgetType, isWindowType, killTimer, metaObject, moveToThread, objectName, parent, property, receivers, registerUserData, removeEventFilter, sender, senderSignalIndex, setObjectName, setParent, setProperty, signalsBlocked, startTimer, thread, timerEvent, tr

Méthodes héritées de la classe Object

__init_subclass__, __subclasshook__

Méthodes héritées de la classe object

__dir__, __format__, __getattribute__, __hash__, __reduce__, __reduce_ex__, __repr__, __sizeof__, __str__