Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-2896

'PySide6.QtGui.QTextLayout' has no attribute 'FormatRange'

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Not Evaluated Not Evaluated
    • None
    • 6.8.0.1
    • PySide
    • None
    • Linux/Wayland

      Install latest PySide6_Essentials (6.8.0.1) from pip, and using QTextLayout.FormatRange such as:

      from PySide6.QtGui import (
          QTextCharFormat,
          QTextOption
      )
      from PySide6.QtGui import *
      from PySide6.QtCore import *
      
      
      if __name__ == '__main__':
          print(QTextLayout.FormatRange()) 

      When running, it failed with 'PySide6.QtGui.QTextLayout' has no attribute 'FormatRange' exception.

      It seems that 6.8 removed `FormatRange`? As 6.7.3 still works.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            crmaurei Cristian Maureira-Fredes
            timxx Weitian Leung
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes