Wed, 28 Apr 2021 19:42:28 +0200
Modernized some code.
--- a/eric6/APIs/Python3/eric6.api Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/APIs/Python3/eric6.api Wed Apr 28 19:42:28 2021 +0200 @@ -1019,9 +1019,9 @@ eric6.E5Graphics.E5ArrowItem.E5ArrowItem.setEndPoint?4(x, y) eric6.E5Graphics.E5ArrowItem.E5ArrowItem.setPoints?4(xa, ya, xb, yb) eric6.E5Graphics.E5ArrowItem.E5ArrowItem.setStartPoint?4(x, y) -eric6.E5Graphics.E5ArrowItem.E5ArrowItem?1(origin=None, end=None, filled=False, arrowType=NormalArrow, colors=None, parent=None) -eric6.E5Graphics.E5ArrowItem.NormalArrow?7 -eric6.E5Graphics.E5ArrowItem.WideArrow?7 +eric6.E5Graphics.E5ArrowItem.E5ArrowItem?1(origin=None, end=None, filled=False, arrowType=E5ArrowType.NORMAL, colors=None, parent=None) +eric6.E5Graphics.E5ArrowItem.E5ArrowType.NORMAL?7 +eric6.E5Graphics.E5ArrowItem.E5ArrowType.WIDE?7 eric6.E5Graphics.E5GraphicsView.E5GraphicsView.ZoomLevelDefault?7 eric6.E5Graphics.E5GraphicsView.E5GraphicsView.ZoomLevels?7 eric6.E5Graphics.E5GraphicsView.E5GraphicsView._getDiagramRect?5(border=0) @@ -1143,7 +1143,7 @@ eric6.E5Gui.E5Led.E5ClickableLed.clicked?7 eric6.E5Gui.E5Led.E5ClickableLed.middleClicked?7 eric6.E5Gui.E5Led.E5ClickableLed.mouseReleaseEvent?4(evt) -eric6.E5Gui.E5Led.E5ClickableLed?1(parent=None, color=None, shape=E5LedCircular, rectRatio=1) +eric6.E5Gui.E5Led.E5ClickableLed?1(parent=None, color=None, shape=E5LedType.CIRCULAR, rectRatio=1) eric6.E5Gui.E5Led.E5Led.color?4() eric6.E5Gui.E5Led.E5Led.darkFactor?4() eric6.E5Gui.E5Led.E5Led.isFramed?4() @@ -1162,12 +1162,10 @@ eric6.E5Gui.E5Led.E5Led.shape?4() eric6.E5Gui.E5Led.E5Led.sizeHint?4() eric6.E5Gui.E5Led.E5Led.toggle?4() -eric6.E5Gui.E5Led.E5Led?1(parent=None, color=None, shape=E5LedCircular, rectRatio=1) -eric6.E5Gui.E5Led.E5LedCircular?7 -eric6.E5Gui.E5Led.E5LedRectangular?7 -eric6.E5Gui.E5LineEdit.E5ClearableLineEdit?1(parent=None, inactiveText="", side=E5LineEdit.RightSide) -eric6.E5Gui.E5LineEdit.E5LineEdit.LeftSide?7 -eric6.E5Gui.E5LineEdit.E5LineEdit.RightSide?7 +eric6.E5Gui.E5Led.E5Led?1(parent=None, color=None, shape=E5LedType.CIRCULAR, rectRatio=1) +eric6.E5Gui.E5Led.E5LedType.CIRCULAR?7 +eric6.E5Gui.E5Led.E5LedType.RECTANGULAR?7 +eric6.E5Gui.E5LineEdit.E5ClearableLineEdit?1(parent=None, inactiveText="", side=E5LineEditSide.RIGHT) eric6.E5Gui.E5LineEdit.E5LineEdit._updateTextMargins?5() eric6.E5Gui.E5LineEdit.E5LineEdit.addWidget?4(widget, position) eric6.E5Gui.E5LineEdit.E5LineEdit.event?4(evt) @@ -1180,6 +1178,8 @@ eric6.E5Gui.E5LineEdit.E5LineEdit.textMargin?4(position) eric6.E5Gui.E5LineEdit.E5LineEdit.widgetSpacing?4() eric6.E5Gui.E5LineEdit.E5LineEdit?1(parent=None, inactiveText="") +eric6.E5Gui.E5LineEdit.E5LineEditSide.LEFT?7 +eric6.E5Gui.E5LineEdit.E5LineEditSide.RIGHT?7 eric6.E5Gui.E5LineEdit.E5LineEditSideWidget.event?4(evt) eric6.E5Gui.E5LineEdit.E5LineEditSideWidget.sizeHintChanged?7 eric6.E5Gui.E5LineEdit.E5LineEditSideWidget?1(parent=None) @@ -1414,11 +1414,7 @@ eric6.E5Gui.E5ProgressDialog.E5ProgressDialog.format?4() eric6.E5Gui.E5ProgressDialog.E5ProgressDialog.setFormat?4(labelFormat) eric6.E5Gui.E5ProgressDialog.E5ProgressDialog?1(labelText, cancelButtonText, minimum, maximum, labelFormat=None, parent=None, flags=None) -eric6.E5Gui.E5SideBar.E5SideBar.East?7 -eric6.E5Gui.E5SideBar.E5SideBar.North?7 -eric6.E5Gui.E5SideBar.E5SideBar.South?7 eric6.E5Gui.E5SideBar.E5SideBar.Version?7 -eric6.E5Gui.E5SideBar.E5SideBar.West?7 eric6.E5Gui.E5SideBar.E5SideBar.addTab?4(widget, iconOrLabel, label=None) eric6.E5Gui.E5SideBar.E5SideBar.clear?4() eric6.E5Gui.E5SideBar.E5SideBar.count?4() @@ -1458,6 +1454,10 @@ eric6.E5Gui.E5SideBar.E5SideBar.tabWhatsThis?4(index) eric6.E5Gui.E5SideBar.E5SideBar.widget?4(index) eric6.E5Gui.E5SideBar.E5SideBar?1(orientation=None, delay=200, parent=None) +eric6.E5Gui.E5SideBar.E5SideBarSide.EAST?7 +eric6.E5Gui.E5SideBar.E5SideBarSide.NORTH?7 +eric6.E5Gui.E5SideBar.E5SideBarSide.SOUTH?7 +eric6.E5Gui.E5SideBar.E5SideBarSide.WEST?7 eric6.E5Gui.E5SimpleHelpDialog.E5SimpleHelpDialog?1(title="", label="", helpStr="", parent=None) eric6.E5Gui.E5SingleApplication.E5SingleApplicationClient.processArgs?4(args) eric6.E5Gui.E5SingleApplication.E5SingleApplicationClient?1() @@ -1507,13 +1507,17 @@ eric6.E5Gui.E5TableView.E5TableView.keyPressEvent?4(evt) eric6.E5Gui.E5TableView.E5TableView.removeAll?4() eric6.E5Gui.E5TableView.E5TableView.removeSelected?4() -eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget.attachTextEdit?4(textedit, editType="QTextEdit") +eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget.attachTextEdit?4(textedit, editType=E5TextEditType.QTEXTEDIT) eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget.keyPressEvent?4(event) eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget.on_findNextButton_clicked?4() eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget.on_findPrevButton_clicked?4() eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget.on_findtextCombo_editTextChanged?4(txt) eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget.setWidthForHeight?4(widthForHeight) eric6.E5Gui.E5TextEditSearchWidget.E5TextEditSearchWidget?1(parent=None, widthForHeight=True) +eric6.E5Gui.E5TextEditSearchWidget.E5TextEditType.QTEXTBROWSER?7 +eric6.E5Gui.E5TextEditSearchWidget.E5TextEditType.QTEXTEDIT?7 +eric6.E5Gui.E5TextEditSearchWidget.E5TextEditType.QWEBENGINEVIEW?7 +eric6.E5Gui.E5TextEditSearchWidget.E5TextEditType.UNKNOWN?7 eric6.E5Gui.E5TextInputDialog.E5TextInputDialog.labelText?4() eric6.E5Gui.E5TextInputDialog.E5TextInputDialog.setLabelText?4(text) eric6.E5Gui.E5TextInputDialog.E5TextInputDialog.setTextEchoMode?4(echoMode) @@ -1583,9 +1587,6 @@ eric6.E5Gui.E5ToolBox.E5HorizontalToolBox.setItemToolTip?4(index, toolTip) eric6.E5Gui.E5ToolBox.E5HorizontalToolBox?1(parent=None) eric6.E5Gui.E5ToolBox.E5VerticalToolBox?1(parent=None) -eric6.E5Gui.E5ToolButton.E5ToolButton.NoOptions?7 -eric6.E5Gui.E5ToolButton.E5ToolButton.ShowMenuInsideOption?7 -eric6.E5Gui.E5ToolButton.E5ToolButton.ToolBarLookOption?7 eric6.E5Gui.E5ToolButton.E5ToolButton.aboutToHideMenu?7 eric6.E5Gui.E5ToolButton.E5ToolButton.aboutToShowMenu?7 eric6.E5Gui.E5ToolButton.E5ToolButton.badgeText?4() @@ -1604,14 +1605,15 @@ eric6.E5Gui.E5ToolButton.E5ToolButton.showMenuInside?4() eric6.E5Gui.E5ToolButton.E5ToolButton.toolbarButtonLook?4() eric6.E5Gui.E5ToolButton.E5ToolButton?1(parent=None) +eric6.E5Gui.E5ToolButton.E5ToolButtonOptions.DEFAULT?7 +eric6.E5Gui.E5ToolButton.E5ToolButtonOptions.SHOW_MENU_INSIDE?7 +eric6.E5Gui.E5ToolButton.E5ToolButtonOptions.TOOLBAR_LOOKUP?7 eric6.E5Gui.E5TreeSortFilterProxyModel.E5TreeSortFilterProxyModel.filterAcceptsRow?4(sourceRow, sourceParent) eric6.E5Gui.E5TreeSortFilterProxyModel.E5TreeSortFilterProxyModel.hasChildren?4(parent=None) eric6.E5Gui.E5TreeSortFilterProxyModel.E5TreeSortFilterProxyModel?1(parent=None) eric6.E5Gui.E5TreeView.E5TreeView.keyPressEvent?4(evt) eric6.E5Gui.E5TreeView.E5TreeView.removeAll?4() eric6.E5Gui.E5TreeView.E5TreeView.removeSelected?4() -eric6.E5Gui.E5TreeWidget.E5TreeWidget.ItemsCollapsed?7 -eric6.E5Gui.E5TreeWidget.E5TreeWidget.ItemsExpanded?7 eric6.E5Gui.E5TreeWidget.E5TreeWidget.addTopLevelItem?4(item) eric6.E5Gui.E5TreeWidget.E5TreeWidget.addTopLevelItems?4(items) eric6.E5Gui.E5TreeWidget.E5TreeWidget.allItems?4() @@ -1628,6 +1630,8 @@ eric6.E5Gui.E5TreeWidget.E5TreeWidget.prependToParentItem?4(parent, item) eric6.E5Gui.E5TreeWidget.E5TreeWidget.setDefaultItemShowMode?4(mode) eric6.E5Gui.E5TreeWidget.E5TreeWidget?1(parent=None) +eric6.E5Gui.E5TreeWidget.E5TreeWidgetItemsState.COLLAPSED?7 +eric6.E5Gui.E5TreeWidget.E5TreeWidgetItemsState.EXPANDED?7 eric6.E5Gui.E5ZoomWidget.E5ZoomWidget._sliderValueChanged?5(value) eric6.E5Gui.E5ZoomWidget.E5ZoomWidget.default?4() eric6.E5Gui.E5ZoomWidget.E5ZoomWidget.isMapped?4() @@ -1732,13 +1736,13 @@ eric6.E5Network.E5SslCertificatesInfoWidget.E5SslCertificatesInfoWidget.showCertificate?4(certificate) eric6.E5Network.E5SslCertificatesInfoWidget.E5SslCertificatesInfoWidget.showCertificateChain?4(certificateChain) eric6.E5Network.E5SslCertificatesInfoWidget.E5SslCertificatesInfoWidget?1(parent=None) -eric6.E5Network.E5SslErrorHandler.E5SslErrorHandler.NotIgnored?7 -eric6.E5Network.E5SslErrorHandler.E5SslErrorHandler.SystemIgnored?7 -eric6.E5Network.E5SslErrorHandler.E5SslErrorHandler.UserIgnored?7 eric6.E5Network.E5SslErrorHandler.E5SslErrorHandler.sslErrors?4(errors, server, port=-1) eric6.E5Network.E5SslErrorHandler.E5SslErrorHandler.sslErrorsReply?4(reply, errors) eric6.E5Network.E5SslErrorHandler.E5SslErrorHandler.sslErrorsReplySlot?4(reply, errors) eric6.E5Network.E5SslErrorHandler.E5SslErrorHandler?1(parent=None) +eric6.E5Network.E5SslErrorHandler.E5SslErrorState.NOT_IGNORED?7 +eric6.E5Network.E5SslErrorHandler.E5SslErrorState.SYSTEM_IGNORED?7 +eric6.E5Network.E5SslErrorHandler.E5SslErrorState.USER_IGNORED?7 eric6.E5Network.E5SslInfoWidget.E5SslInfoWidget.accept?4() eric6.E5Network.E5SslInfoWidget.E5SslInfoWidget.showAt?4(pos) eric6.E5Network.E5SslInfoWidget.E5SslInfoWidget?1(url, configuration, parent=None) @@ -1757,15 +1761,6 @@ eric6.E5Network.E5TldExtractor.E5TldHostParts?1() eric6.E5Network.E5TldExtractor._TLDExtractor?8 eric6.E5Network.E5TldExtractor.instance?4(withPrivate=False) -eric6.E5Network.E5UrlInfo.E5UrlInfo.ExeGroup?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.ExeOther?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.ExeOwner?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.ReadGroup?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.ReadOther?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.ReadOwner?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.WriteGroup?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.WriteOther?7 -eric6.E5Network.E5UrlInfo.E5UrlInfo.WriteOwner?7 eric6.E5Network.E5UrlInfo.E5UrlInfo.group?4() eric6.E5Network.E5UrlInfo.E5UrlInfo.isDir?4() eric6.E5Network.E5UrlInfo.E5UrlInfo.isExecutable?4() @@ -1793,6 +1788,15 @@ eric6.E5Network.E5UrlInfo.E5UrlInfo.setWritable?4(isWritable) eric6.E5Network.E5UrlInfo.E5UrlInfo.size?4() eric6.E5Network.E5UrlInfo.E5UrlInfo?1() +eric6.E5Network.E5UrlInfo.E5UrlPermission.EXE_GROUP?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.EXE_OTHER?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.EXE_OWNER?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.READ_GROUP?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.READ_OTHER?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.READ_OWNER?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.WRITE_GROUP?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.WRITE_OTHER?7 +eric6.E5Network.E5UrlInfo.E5UrlPermission.WRITE_OWNER?7 eric6.E5Network.E5XmlRpcClient.E5XmlRpcClient.abort?4() eric6.E5Network.E5XmlRpcClient.E5XmlRpcClient.call?4(method, args, responseCallback, errorCallback) eric6.E5Network.E5XmlRpcClient.E5XmlRpcClient.setUrl?4(url) @@ -2745,7 +2749,7 @@ eric6.Network.IRC.IrcMessageEdit.IrcMessageEdit.keyPressEvent?4(evt) eric6.Network.IRC.IrcMessageEdit.IrcMessageEdit.setText?4(text) eric6.Network.IRC.IrcMessageEdit.IrcMessageEdit.wheelEvent?4(evt) -eric6.Network.IRC.IrcMessageEdit.IrcMessageEdit?1(parent=None, inactiveText="", side=E5LineEdit.RightSide) +eric6.Network.IRC.IrcMessageEdit.IrcMessageEdit?1(parent=None, inactiveText="", side=E5LineEditSide.RIGHT) eric6.Network.IRC.IrcNetworkEditDialog.IrcNetworkEditDialog.getNetwork?4() eric6.Network.IRC.IrcNetworkEditDialog.IrcNetworkEditDialog.on_addChannelButton_clicked?4() eric6.Network.IRC.IrcNetworkEditDialog.IrcNetworkEditDialog.on_channelList_itemActivated?4(item, column)
--- a/eric6/APIs/Python3/eric6.bas Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/APIs/Python3/eric6.bas Wed Apr 28 19:42:28 2021 +0200 @@ -169,6 +169,7 @@ E5AnimatedWidget QWidget E5Application QApplication E5ArrowItem QAbstractGraphicsShapeItem +E5ArrowType enum.Enum E5ClearableComboBox E5ComboBox E5ClearableLineEdit E5LineEdit E5ClickableLabel QLabel @@ -190,8 +191,10 @@ E5GraphicsView QGraphicsView E5HorizontalToolBox E5TabWidget E5Led QWidget +E5LedType enum.Enum E5LineEdit QLineEdit E5LineEditButton QAbstractButton +E5LineEditSide enum.Enum E5LineEditSideWidget QWidget E5ListSelectionDialog QDialog Ui_E5ListSelectionDialog E5ListView QListView @@ -218,6 +221,7 @@ E5ProcessDialog QDialog Ui_E5ProcessDialog E5ProgressDialog QProgressDialog E5SideBar QWidget +E5SideBarSide enum.Enum E5SimpleHelpDialog QDialog Ui_E5SimpleHelpDialog E5SingleApplicationClient SingleApplicationClient E5SingleApplicationServer SingleApplicationServer @@ -228,21 +232,26 @@ E5SslCertificatesInfoDialog QDialog Ui_E5SslCertificatesInfoDialog E5SslCertificatesInfoWidget QWidget Ui_E5SslCertificatesInfoWidget E5SslErrorHandler QObject +E5SslErrorState enum.Enum E5SslInfoWidget QMenu E5StringListCompleter QCompleter E5StringListEditWidget QWidget Ui_E5StringListEditWidget E5TabWidget QTabWidget E5TableView QTableView E5TextEditSearchWidget QWidget +E5TextEditType enum.Enum E5TextInputDialog QDialog E5TextSpinBox QSpinBox E5TldExtractor QObject E5ToolBarDialog QDialog Ui_E5ToolBarDialog E5ToolBarManager QObject E5ToolButton QToolButton +E5ToolButtonOptions enum.IntEnum E5TreeSortFilterProxyModel QSortFilterProxyModel E5TreeView QTreeView E5TreeWidget QTreeWidget +E5TreeWidgetItemsState enum.Enum +E5UrlPermission enum.IntEnum E5VerticalToolBox QToolBox E5WheelTabBar QTabBar E5XmlRpcClient QObject
--- a/eric6/Documentation/Help/source.qhp Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Help/source.qhp Wed Apr 28 19:42:28 2021 +0200 @@ -4012,6 +4012,7 @@ <keyword name="E5ArrowItem.setEndPoint" id="E5ArrowItem.setEndPoint" ref="eric6.E5Graphics.E5ArrowItem.html#E5ArrowItem.setEndPoint" /> <keyword name="E5ArrowItem.setPoints" id="E5ArrowItem.setPoints" ref="eric6.E5Graphics.E5ArrowItem.html#E5ArrowItem.setPoints" /> <keyword name="E5ArrowItem.setStartPoint" id="E5ArrowItem.setStartPoint" ref="eric6.E5Graphics.E5ArrowItem.html#E5ArrowItem.setStartPoint" /> + <keyword name="E5ArrowType" id="E5ArrowType" ref="eric6.E5Graphics.E5ArrowItem.html#E5ArrowType" /> <keyword name="E5Cache" id="E5Cache" ref="eric6.E5Utilities.E5Cache.html#E5Cache" /> <keyword name="E5Cache (Constructor)" id="E5Cache (Constructor)" ref="eric6.E5Utilities.E5Cache.html#E5Cache.__init__" /> <keyword name="E5Cache (Module)" id="E5Cache (Module)" ref="eric6.E5Utilities.E5Cache.html" /> @@ -4175,6 +4176,7 @@ <keyword name="E5Led.shape" id="E5Led.shape" ref="eric6.E5Gui.E5Led.html#E5Led.shape" /> <keyword name="E5Led.sizeHint" id="E5Led.sizeHint" ref="eric6.E5Gui.E5Led.html#E5Led.sizeHint" /> <keyword name="E5Led.toggle" id="E5Led.toggle" ref="eric6.E5Gui.E5Led.html#E5Led.toggle" /> + <keyword name="E5LedType" id="E5LedType" ref="eric6.E5Gui.E5Led.html#E5LedType" /> <keyword name="E5LineEdit" id="E5LineEdit" ref="eric6.E5Gui.E5LineEdit.html#E5LineEdit" /> <keyword name="E5LineEdit (Constructor)" id="E5LineEdit (Constructor)" ref="eric6.E5Gui.E5LineEdit.html#E5LineEdit.__init__" /> <keyword name="E5LineEdit (Module)" id="E5LineEdit (Module)" ref="eric6.E5Gui.E5LineEdit.html" /> @@ -4197,6 +4199,7 @@ <keyword name="E5LineEditButton.paintEvent" id="E5LineEditButton.paintEvent" ref="eric6.E5Gui.E5LineEditButton.html#E5LineEditButton.paintEvent" /> <keyword name="E5LineEditButton.setIcon" id="E5LineEditButton.setIcon" ref="eric6.E5Gui.E5LineEditButton.html#E5LineEditButton.setIcon" /> <keyword name="E5LineEditButton.setMenu" id="E5LineEditButton.setMenu" ref="eric6.E5Gui.E5LineEditButton.html#E5LineEditButton.setMenu" /> + <keyword name="E5LineEditSide" id="E5LineEditSide" ref="eric6.E5Gui.E5LineEdit.html#E5LineEditSide" /> <keyword name="E5LineEditSideWidget" id="E5LineEditSideWidget" ref="eric6.E5Gui.E5LineEdit.html#E5LineEditSideWidget" /> <keyword name="E5LineEditSideWidget (Constructor)" id="E5LineEditSideWidget (Constructor)" ref="eric6.E5Gui.E5LineEdit.html#E5LineEditSideWidget.__init__" /> <keyword name="E5LineEditSideWidget.event" id="E5LineEditSideWidget.event" ref="eric6.E5Gui.E5LineEdit.html#E5LineEditSideWidget.event" /> @@ -4503,6 +4506,7 @@ <keyword name="E5SideBar.tabToolTip" id="E5SideBar.tabToolTip" ref="eric6.E5Gui.E5SideBar.html#E5SideBar.tabToolTip" /> <keyword name="E5SideBar.tabWhatsThis" id="E5SideBar.tabWhatsThis" ref="eric6.E5Gui.E5SideBar.html#E5SideBar.tabWhatsThis" /> <keyword name="E5SideBar.widget" id="E5SideBar.widget" ref="eric6.E5Gui.E5SideBar.html#E5SideBar.widget" /> + <keyword name="E5SideBarSide" id="E5SideBarSide" ref="eric6.E5Gui.E5SideBar.html#E5SideBarSide" /> <keyword name="E5SimpleHelpDialog" id="E5SimpleHelpDialog" ref="eric6.E5Gui.E5SimpleHelpDialog.html#E5SimpleHelpDialog" /> <keyword name="E5SimpleHelpDialog (Constructor)" id="E5SimpleHelpDialog (Constructor)" ref="eric6.E5Gui.E5SimpleHelpDialog.html#E5SimpleHelpDialog.__init__" /> <keyword name="E5SimpleHelpDialog (Module)" id="E5SimpleHelpDialog (Module)" ref="eric6.E5Gui.E5SimpleHelpDialog.html" /> @@ -4584,6 +4588,7 @@ <keyword name="E5SslErrorHandler.sslErrors" id="E5SslErrorHandler.sslErrors" ref="eric6.E5Network.E5SslErrorHandler.html#E5SslErrorHandler.sslErrors" /> <keyword name="E5SslErrorHandler.sslErrorsReply" id="E5SslErrorHandler.sslErrorsReply" ref="eric6.E5Network.E5SslErrorHandler.html#E5SslErrorHandler.sslErrorsReply" /> <keyword name="E5SslErrorHandler.sslErrorsReplySlot" id="E5SslErrorHandler.sslErrorsReplySlot" ref="eric6.E5Network.E5SslErrorHandler.html#E5SslErrorHandler.sslErrorsReplySlot" /> + <keyword name="E5SslErrorState" id="E5SslErrorState" ref="eric6.E5Network.E5SslErrorHandler.html#E5SslErrorState" /> <keyword name="E5SslInfoWidget" id="E5SslInfoWidget" ref="eric6.E5Network.E5SslInfoWidget.html#E5SslInfoWidget" /> <keyword name="E5SslInfoWidget (Constructor)" id="E5SslInfoWidget (Constructor)" ref="eric6.E5Network.E5SslInfoWidget.html#E5SslInfoWidget.__init__" /> <keyword name="E5SslInfoWidget (Module)" id="E5SslInfoWidget (Module)" ref="eric6.E5Network.E5SslInfoWidget.html" /> @@ -4640,6 +4645,7 @@ <keyword name="E5TextEditSearchWidget.on_findPrevButton_clicked" id="E5TextEditSearchWidget.on_findPrevButton_clicked" ref="eric6.E5Gui.E5TextEditSearchWidget.html#E5TextEditSearchWidget.on_findPrevButton_clicked" /> <keyword name="E5TextEditSearchWidget.on_findtextCombo_editTextChanged" id="E5TextEditSearchWidget.on_findtextCombo_editTextChanged" ref="eric6.E5Gui.E5TextEditSearchWidget.html#E5TextEditSearchWidget.on_findtextCombo_editTextChanged" /> <keyword name="E5TextEditSearchWidget.setWidthForHeight" id="E5TextEditSearchWidget.setWidthForHeight" ref="eric6.E5Gui.E5TextEditSearchWidget.html#E5TextEditSearchWidget.setWidthForHeight" /> + <keyword name="E5TextEditType" id="E5TextEditType" ref="eric6.E5Gui.E5TextEditSearchWidget.html#E5TextEditType" /> <keyword name="E5TextInputDialog" id="E5TextInputDialog" ref="eric6.E5Gui.E5TextInputDialog.html#E5TextInputDialog" /> <keyword name="E5TextInputDialog (Constructor)" id="E5TextInputDialog (Constructor)" ref="eric6.E5Gui.E5TextInputDialog.html#E5TextInputDialog.__init__" /> <keyword name="E5TextInputDialog (Module)" id="E5TextInputDialog (Module)" ref="eric6.E5Gui.E5TextInputDialog.html" /> @@ -4755,6 +4761,7 @@ <keyword name="E5ToolButton.setToolbarButtonLook" id="E5ToolButton.setToolbarButtonLook" ref="eric6.E5Gui.E5ToolButton.html#E5ToolButton.setToolbarButtonLook" /> <keyword name="E5ToolButton.showMenuInside" id="E5ToolButton.showMenuInside" ref="eric6.E5Gui.E5ToolButton.html#E5ToolButton.showMenuInside" /> <keyword name="E5ToolButton.toolbarButtonLook" id="E5ToolButton.toolbarButtonLook" ref="eric6.E5Gui.E5ToolButton.html#E5ToolButton.toolbarButtonLook" /> + <keyword name="E5ToolButtonOptions" id="E5ToolButtonOptions" ref="eric6.E5Gui.E5ToolButton.html#E5ToolButtonOptions" /> <keyword name="E5TreeSortFilterProxyModel" id="E5TreeSortFilterProxyModel" ref="eric6.E5Gui.E5TreeSortFilterProxyModel.html#E5TreeSortFilterProxyModel" /> <keyword name="E5TreeSortFilterProxyModel (Constructor)" id="E5TreeSortFilterProxyModel (Constructor)" ref="eric6.E5Gui.E5TreeSortFilterProxyModel.html#E5TreeSortFilterProxyModel.__init__" /> <keyword name="E5TreeSortFilterProxyModel (Module)" id="E5TreeSortFilterProxyModel (Module)" ref="eric6.E5Gui.E5TreeSortFilterProxyModel.html" /> @@ -4783,6 +4790,7 @@ <keyword name="E5TreeWidget.mousePressEvent" id="E5TreeWidget.mousePressEvent" ref="eric6.E5Gui.E5TreeWidget.html#E5TreeWidget.mousePressEvent" /> <keyword name="E5TreeWidget.prependToParentItem" id="E5TreeWidget.prependToParentItem" ref="eric6.E5Gui.E5TreeWidget.html#E5TreeWidget.prependToParentItem" /> <keyword name="E5TreeWidget.setDefaultItemShowMode" id="E5TreeWidget.setDefaultItemShowMode" ref="eric6.E5Gui.E5TreeWidget.html#E5TreeWidget.setDefaultItemShowMode" /> + <keyword name="E5TreeWidgetItemsState" id="E5TreeWidgetItemsState" ref="eric6.E5Gui.E5TreeWidget.html#E5TreeWidgetItemsState" /> <keyword name="E5UrlInfo" id="E5UrlInfo" ref="eric6.E5Network.E5UrlInfo.html#E5UrlInfo" /> <keyword name="E5UrlInfo (Constructor)" id="E5UrlInfo (Constructor)" ref="eric6.E5Network.E5UrlInfo.html#E5UrlInfo.__init__" /> <keyword name="E5UrlInfo (Module)" id="E5UrlInfo (Module)" ref="eric6.E5Network.E5UrlInfo.html" /> @@ -4812,6 +4820,7 @@ <keyword name="E5UrlInfo.setSymLink" id="E5UrlInfo.setSymLink" ref="eric6.E5Network.E5UrlInfo.html#E5UrlInfo.setSymLink" /> <keyword name="E5UrlInfo.setWritable" id="E5UrlInfo.setWritable" ref="eric6.E5Network.E5UrlInfo.html#E5UrlInfo.setWritable" /> <keyword name="E5UrlInfo.size" id="E5UrlInfo.size" ref="eric6.E5Network.E5UrlInfo.html#E5UrlInfo.size" /> + <keyword name="E5UrlPermission" id="E5UrlPermission" ref="eric6.E5Network.E5UrlInfo.html#E5UrlPermission" /> <keyword name="E5Utilities (Package)" id="E5Utilities (Package)" ref="index-eric6.E5Utilities.html" /> <keyword name="E5VerticalToolBox" id="E5VerticalToolBox" ref="eric6.E5Gui.E5ToolBox.html#E5VerticalToolBox" /> <keyword name="E5VerticalToolBox (Constructor)" id="E5VerticalToolBox (Constructor)" ref="eric6.E5Gui.E5ToolBox.html#E5VerticalToolBox.__init__" />
--- a/eric6/Documentation/Source/eric6.E5Graphics.E5ArrowItem.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Graphics.E5ArrowItem.html Wed Apr 28 19:42:28 2021 +0200 @@ -28,7 +28,7 @@ <h3>Global Attributes</h3> <table> -<tr><td>ArrowheadAngleFactor</td></tr><tr><td>NormalArrow</td></tr><tr><td>WideArrow</td></tr> +<tr><td>ArrowheadAngleFactor</td></tr> </table> <h3>Classes</h3> @@ -38,6 +38,10 @@ <td><a href="#E5ArrowItem">E5ArrowItem</a></td> <td>Class implementing an arrow graphics item subclass.</td> </tr> +<tr> +<td><a href="#E5ArrowType">E5ArrowType</a></td> +<td>Class defining the arrow types.</td> +</tr> </table> <h3>Functions</h3> @@ -101,7 +105,7 @@ <a NAME="E5ArrowItem.__init__" ID="E5ArrowItem.__init__"></a> <h4>E5ArrowItem (Constructor)</h4> -<b>E5ArrowItem</b>(<i>origin=None, end=None, filled=False, arrowType=NormalArrow, colors=None, parent=None</i>) +<b>E5ArrowItem</b>(<i>origin=None, end=None, filled=False, arrowType=E5ArrowType.NORMAL, colors=None, parent=None</i>) <p> Constructor @@ -120,7 +124,7 @@ <dd> flag indicating a filled arrow head </dd> -<dt><i>arrowType</i> (int, one of NormalArrow, WideArrow)</dt> +<dt><i>arrowType</i> (E5ArrowType)</dt> <dd> arrow type </dd> @@ -241,4 +245,36 @@ </dl> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5ArrowType" ID="E5ArrowType"></a> +<h2>E5ArrowType</h2> + +<p> + Class defining the arrow types. +</p> +<h3>Derived from</h3> +enum.Enum +<h3>Class Attributes</h3> + +<table> +<tr><td>NORMAL</td></tr><tr><td>WIDE</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.E5Gui.E5Led.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Gui.E5Led.html Wed Apr 28 19:42:28 2021 +0200 @@ -31,7 +31,7 @@ <h3>Global Attributes</h3> <table> -<tr><td>E5LedCircular</td></tr><tr><td>E5LedRectangular</td></tr> +<tr><td>None</td></tr> </table> <h3>Classes</h3> @@ -45,6 +45,10 @@ <td><a href="#E5Led">E5Led</a></td> <td>Class implementing a LED widget.</td> </tr> +<tr> +<td><a href="#E5LedType">E5LedType</a></td> +<td>Class defining the LED types.</td> +</tr> </table> <h3>Functions</h3> @@ -106,28 +110,28 @@ <a NAME="E5ClickableLed.__init__" ID="E5ClickableLed.__init__"></a> <h4>E5ClickableLed (Constructor)</h4> -<b>E5ClickableLed</b>(<i>parent=None, color=None, shape=E5LedCircular, rectRatio=1</i>) +<b>E5ClickableLed</b>(<i>parent=None, color=None, shape=E5LedType.CIRCULAR, rectRatio=1</i>) <p> Constructor </p> <dl> -<dt><i>parent</i></dt> +<dt><i>parent</i> (QWidget)</dt> <dd> -reference to parent widget (QWidget) +reference to parent widget </dd> -<dt><i>color</i></dt> +<dt><i>color</i> (QColor)</dt> <dd> -color of the LED (QColor) +color of the LED </dd> -<dt><i>shape</i></dt> +<dt><i>shape</i> (E5LedType)</dt> <dd> -shape of the LED (E5LedCircular, E5LedRectangular) +shape of the LED </dd> -<dt><i>rectRatio</i></dt> +<dt><i>rectRatio</i> (float)</dt> <dd> -ratio width to height, if shape is rectangular (float) +ratio width to height, if shape is rectangular </dd> </dl> <a NAME="E5ClickableLed.mouseReleaseEvent" ID="E5ClickableLed.mouseReleaseEvent"></a> @@ -266,28 +270,28 @@ <a NAME="E5Led.__init__" ID="E5Led.__init__"></a> <h4>E5Led (Constructor)</h4> -<b>E5Led</b>(<i>parent=None, color=None, shape=E5LedCircular, rectRatio=1</i>) +<b>E5Led</b>(<i>parent=None, color=None, shape=E5LedType.CIRCULAR, rectRatio=1</i>) <p> Constructor </p> <dl> -<dt><i>parent</i></dt> +<dt><i>parent</i> (QWidget)</dt> <dd> -reference to parent widget (QWidget) +reference to parent widget </dd> -<dt><i>color</i></dt> +<dt><i>color</i> (QColor)</dt> <dd> -color of the LED (QColor) +color of the LED </dd> -<dt><i>shape</i></dt> +<dt><i>shape</i> (E5LedType)</dt> <dd> -shape of the LED (E5LedCircular, E5LedRectangular) +shape of the LED </dd> -<dt><i>rectRatio</i></dt> +<dt><i>rectRatio</i> (float)</dt> <dd> -ratio width to height, if shape is rectangular (float) +ratio width to height, if shape is rectangular </dd> </dl> <a NAME="E5Led.__getBestRoundSize" ID="E5Led.__getBestRoundSize"></a> @@ -410,13 +414,6 @@ paint event object </dd> </dl> -<dl> - -<dt>Raises <b>TypeError</b>:</dt> -<dd> -The E5Led has an unsupported shape type. -</dd> -</dl> <a NAME="E5Led.ratio" ID="E5Led.ratio"></a> <h4>E5Led.ratio</h4> <b>ratio</b>(<i></i>) @@ -509,9 +506,9 @@ </p> <dl> -<dt><i>shape</i></dt> +<dt><i>shape</i> (E5LedType)</dt> <dd> -new LED shape (E5LedCircular, E5LedRectangular) +new LED shape </dd> </dl> <a NAME="E5Led.shape" ID="E5Led.shape"></a> @@ -524,7 +521,13 @@ <dl> <dt>Return:</dt> <dd> -LED shape (E5LedCircular, E5LedRectangular) +LED shape +</dd> +</dl> +<dl> +<dt>Return Type:</dt> +<dd> +E5LedType </dd> </dl> <a NAME="E5Led.sizeHint" ID="E5Led.sizeHint"></a> @@ -549,4 +552,36 @@ </p> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5LedType" ID="E5LedType"></a> +<h2>E5LedType</h2> + +<p> + Class defining the LED types. +</p> +<h3>Derived from</h3> +enum.Enum +<h3>Class Attributes</h3> + +<table> +<tr><td>CIRCULAR</td></tr><tr><td>RECTANGULAR</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.E5Gui.E5LineEdit.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Gui.E5LineEdit.html Wed Apr 28 19:42:28 2021 +0200 @@ -43,6 +43,10 @@ <td>Class implementing a line edit widget showing some inactive text.</td> </tr> <tr> +<td><a href="#E5LineEditSide">E5LineEditSide</a></td> +<td>Class defining the line edit sides.</td> +</tr> +<tr> <td><a href="#E5LineEditSideWidget">E5LineEditSideWidget</a></td> <td>Class implementing the side widgets for the line edit class.</td> </tr> @@ -94,32 +98,24 @@ <a NAME="E5ClearableLineEdit.__init__" ID="E5ClearableLineEdit.__init__"></a> <h4>E5ClearableLineEdit (Constructor)</h4> -<b>E5ClearableLineEdit</b>(<i>parent=None, inactiveText="", side=E5LineEdit.RightSide</i>) +<b>E5ClearableLineEdit</b>(<i>parent=None, inactiveText="", side=E5LineEditSide.RIGHT</i>) <p> Constructor </p> <dl> -<dt><i>parent</i></dt> +<dt><i>parent</i> (QWidget)</dt> <dd> -reference to the parent widget (QWidget) +reference to the parent widget </dd> -<dt><i>inactiveText</i></dt> +<dt><i>inactiveText</i> (str)</dt> <dd> -text to be shown on inactivity (string) +text to be shown on inactivity </dd> -<dt><i>side</i></dt> +<dt><i>side</i> (E5LineEditSide)</dt> <dd> side the clear button should be shown at - (E5LineEdit.RightSide, E5LineEdit.LeftSide) -</dd> -</dl> -<dl> - -<dt>Raises <b>ValueError</b>:</dt> -<dd> -raised to indicate a bad parameter value </dd> </dl> <a NAME="E5ClearableLineEdit.__textChanged" ID="E5ClearableLineEdit.__textChanged"></a> @@ -150,7 +146,7 @@ <h3>Class Attributes</h3> <table> -<tr><td>LeftSide</td></tr><tr><td>RightSide</td></tr> +<tr><td>None</td></tr> </table> <h3>Class Methods</h3> @@ -250,14 +246,13 @@ </p> <dl> -<dt><i>widget</i></dt> +<dt><i>widget</i> (QWidget)</dt> <dd> -reference to the widget to add (QWidget) +reference to the widget to add </dd> -<dt><i>position</i></dt> +<dt><i>position</i> (E5LineEditSide)</dt> <dd> -position to add to (E5LineEdit.LeftSide, - E5LineEdit.RightSide) +position to add to </dd> </dl> <a NAME="E5LineEdit.event" ID="E5LineEdit.event"></a> @@ -315,9 +310,9 @@ </p> <dl> -<dt><i>widget</i></dt> +<dt><i>widget</i> (QWidget)</dt> <dd> -reference to the widget to remove (QWidget) +reference to the widget to remove </dd> </dl> <a NAME="E5LineEdit.setInactiveText" ID="E5LineEdit.setInactiveText"></a> @@ -371,16 +366,21 @@ </p> <dl> -<dt><i>position</i></dt> +<dt><i>position</i> (E5LineEditSide)</dt> <dd> -side to get margin for (E5LineEdit.LeftSide, - E5LineEdit.RightSide) +side to get margin for </dd> </dl> <dl> <dt>Return:</dt> <dd> -text margin (integer) +text margin +</dd> +</dl> +<dl> +<dt>Return Type:</dt> +<dd> +int </dd> </dl> <a NAME="E5LineEdit.widgetSpacing" ID="E5LineEdit.widgetSpacing"></a> @@ -399,6 +399,38 @@ <div align="right"><a href="#top">Up</a></div> <hr /> <hr /> +<a NAME="E5LineEditSide" ID="E5LineEditSide"></a> +<h2>E5LineEditSide</h2> + +<p> + Class defining the line edit sides. +</p> +<h3>Derived from</h3> +enum.Enum +<h3>Class Attributes</h3> + +<table> +<tr><td>LEFT</td></tr><tr><td>RIGHT</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> +<hr /> <a NAME="E5LineEditSideWidget" ID="E5LineEditSideWidget"></a> <h2>E5LineEditSideWidget</h2>
--- a/eric6/Documentation/Source/eric6.E5Gui.E5ProcessDialog.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Gui.E5ProcessDialog.html Wed Apr 28 19:42:28 2021 +0200 @@ -53,9 +53,9 @@ Class implementing a dialog starting a process and showing its output. </p> <p> - It starts a QProcess and displays a dialog that - shows the output of the process. The dialog is modal, - which causes a synchronized execution of the process. + It starts a QProcess and displays a dialog that shows the output of the + process. The dialog is modal, which causes a synchronized execution of + the process. </p> <h3>Derived from</h3> QDialog, Ui_E5ProcessDialog
--- a/eric6/Documentation/Source/eric6.E5Gui.E5SideBar.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Gui.E5SideBar.html Wed Apr 28 19:42:28 2021 +0200 @@ -38,6 +38,10 @@ <td><a href="#E5SideBar">E5SideBar</a></td> <td>Class implementing a sidebar with a widget area, that is hidden or shown, if the current tab is clicked again.</td> </tr> +<tr> +<td><a href="#E5SideBarSide">E5SideBarSide</a></td> +<td>Class defining the sidebar sides.</td> +</tr> </table> <h3>Functions</h3> @@ -58,7 +62,7 @@ <h3>Class Attributes</h3> <table> -<tr><td>East</td></tr><tr><td>North</td></tr><tr><td>South</td></tr><tr><td>Version</td></tr><tr><td>West</td></tr> +<tr><td>Version</td></tr> </table> <h3>Class Methods</h3> @@ -269,19 +273,17 @@ </p> <dl> -<dt><i>orientation</i></dt> +<dt><i>orientation</i> (E5SideBarSide)</dt> <dd> -orientation of the sidebar widget (North, East, - South, West) +orientation of the sidebar widget </dd> -<dt><i>delay</i></dt> +<dt><i>delay</i> (int)</dt> <dd> value for the expand/shrink delay in milliseconds - (integer) </dd> -<dt><i>parent</i></dt> +<dt><i>parent</i> (QWidget)</dt> <dd> -parent widget (QWidget) +parent widget </dd> </dl> <a NAME="E5SideBar.__appFocusChanged" ID="E5SideBar.__appFocusChanged"></a> @@ -617,7 +619,13 @@ <dl> <dt>Return:</dt> <dd> -orientation of the sidebar (North, East, South, West) +orientation of the sidebar +</dd> +</dl> +<dl> +<dt>Return Type:</dt> +<dd> +E5SideBarSide </dd> </dl> <a NAME="E5SideBar.prevTab" ID="E5SideBar.prevTab"></a> @@ -728,9 +736,9 @@ </p> <dl> -<dt><i>orient</i></dt> +<dt><i>orient</i> (E5SideBarSide)</dt> <dd> -orientation of the sidebar (North, East, South, West) +orientation of the sidebar </dd> </dl> <a NAME="E5SideBar.setSplitter" ID="E5SideBar.setSplitter"></a> @@ -958,4 +966,36 @@ </dl> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5SideBarSide" ID="E5SideBarSide"></a> +<h2>E5SideBarSide</h2> + +<p> + Class defining the sidebar sides. +</p> +<h3>Derived from</h3> +enum.Enum +<h3>Class Attributes</h3> + +<table> +<tr><td>EAST</td></tr><tr><td>NORTH</td></tr><tr><td>SOUTH</td></tr><tr><td>WEST</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.E5Gui.E5TextEditSearchWidget.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Gui.E5TextEditSearchWidget.html Wed Apr 28 19:42:28 2021 +0200 @@ -38,6 +38,10 @@ <td><a href="#E5TextEditSearchWidget">E5TextEditSearchWidget</a></td> <td>Class implementing a horizontal search widget for QTextEdit.</td> </tr> +<tr> +<td><a href="#E5TextEditType">E5TextEditType</a></td> +<td>Class defining the supported text edit types.</td> +</tr> </table> <h3>Functions</h3> @@ -296,7 +300,7 @@ </dl> <a NAME="E5TextEditSearchWidget.attachTextEdit" ID="E5TextEditSearchWidget.attachTextEdit"></a> <h4>E5TextEditSearchWidget.attachTextEdit</h4> -<b>attachTextEdit</b>(<i>textedit, editType="QTextEdit"</i>) +<b>attachTextEdit</b>(<i>textedit, editType=E5TextEditType.QTEXTEDIT</i>) <p> Public method to attach a QTextEdit widget. @@ -307,18 +311,11 @@ <dd> reference to the edit widget to be attached </dd> -<dt><i>editType</i> (str (one of "QTextEdit", "QWebEngineView" or "QWebView"))</dt> +<dt><i>editType</i> (E5TextEditType)</dt> <dd> type of the attached edit widget </dd> </dl> -<dl> - -<dt>Raises <b>ValueError</b>:</dt> -<dd> -raised to indicate a bad parameter value -</dd> -</dl> <a NAME="E5TextEditSearchWidget.keyPressEvent" ID="E5TextEditSearchWidget.keyPressEvent"></a> <h4>E5TextEditSearchWidget.keyPressEvent</h4> <b>keyPressEvent</b>(<i>event</i>) @@ -377,4 +374,36 @@ </dl> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5TextEditType" ID="E5TextEditType"></a> +<h2>E5TextEditType</h2> + +<p> + Class defining the supported text edit types. +</p> +<h3>Derived from</h3> +enum.Enum +<h3>Class Attributes</h3> + +<table> +<tr><td>QTEXTBROWSER</td></tr><tr><td>QTEXTEDIT</td></tr><tr><td>QWEBENGINEVIEW</td></tr><tr><td>UNKNOWN</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.E5Gui.E5ToolButton.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Gui.E5ToolButton.html Wed Apr 28 19:42:28 2021 +0200 @@ -38,6 +38,10 @@ <td><a href="#E5ToolButton">E5ToolButton</a></td> <td>Class implementing a specialized tool button subclass.</td> </tr> +<tr> +<td><a href="#E5ToolButtonOptions">E5ToolButtonOptions</a></td> +<td>Class defining the tool button options.</td> +</tr> </table> <h3>Functions</h3> @@ -83,7 +87,7 @@ <h3>Class Attributes</h3> <table> -<tr><td>NoOptions</td></tr><tr><td>ShowMenuInsideOption</td></tr><tr><td>ToolBarLookOption</td></tr> +<tr><td>None</td></tr> </table> <h3>Class Methods</h3> @@ -381,4 +385,36 @@ </dl> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5ToolButtonOptions" ID="E5ToolButtonOptions"></a> +<h2>E5ToolButtonOptions</h2> + +<p> + Class defining the tool button options. +</p> +<h3>Derived from</h3> +enum.IntEnum +<h3>Class Attributes</h3> + +<table> +<tr><td>DEFAULT</td></tr><tr><td>SHOW_MENU_INSIDE</td></tr><tr><td>TOOLBAR_LOOKUP</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.E5Gui.E5TreeWidget.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Gui.E5TreeWidget.html Wed Apr 28 19:42:28 2021 +0200 @@ -38,6 +38,10 @@ <td><a href="#E5TreeWidget">E5TreeWidget</a></td> <td>Class implementing an extended tree widget.</td> </tr> +<tr> +<td><a href="#E5TreeWidgetItemsState">E5TreeWidgetItemsState</a></td> +<td>Class defining the items expansion state.</td> +</tr> </table> <h3>Functions</h3> @@ -71,7 +75,7 @@ <h3>Class Attributes</h3> <table> -<tr><td>ItemsCollapsed</td></tr><tr><td>ItemsExpanded</td></tr> +<tr><td>None</td></tr> </table> <h3>Class Methods</h3> @@ -405,18 +409,43 @@ </p> <dl> -<dt><i>mode</i></dt> +<dt><i>mode</i> (E5TreeWidgetItemsState)</dt> <dd> -default mode (ItemsCollapsed, ItemsExpanded) -</dd> -</dl> -<dl> - -<dt>Raises <b>ValueError</b>:</dt> -<dd> -raised to indicate a bad parameter value +default mode </dd> </dl> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5TreeWidgetItemsState" ID="E5TreeWidgetItemsState"></a> +<h2>E5TreeWidgetItemsState</h2> + +<p> + Class defining the items expansion state. +</p> +<h3>Derived from</h3> +enum.Enum +<h3>Class Attributes</h3> + +<table> +<tr><td>COLLAPSED</td></tr><tr><td>EXPANDED</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.E5Network.E5SslErrorHandler.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Network.E5SslErrorHandler.html Wed Apr 28 19:42:28 2021 +0200 @@ -38,6 +38,10 @@ <td><a href="#E5SslErrorHandler">E5SslErrorHandler</a></td> <td>Class implementing a handler for SSL errors.</td> </tr> +<tr> +<td><a href="#E5SslErrorState">E5SslErrorState</a></td> +<td>Class defining the SSL error handling states.</td> +</tr> </table> <h3>Functions</h3> @@ -61,7 +65,7 @@ <h3>Class Attributes</h3> <table> -<tr><td>NotIgnored</td></tr><tr><td>SystemIgnored</td></tr><tr><td>UserIgnored</td></tr> +<tr><td>None</td></tr> </table> <h3>Class Methods</h3> @@ -159,25 +163,30 @@ </p> <dl> -<dt><i>errors</i></dt> +<dt><i>errors</i> (list of QSslError)</dt> <dd> -list of SSL errors (list of QSslError) +list of SSL errors </dd> -<dt><i>server</i></dt> +<dt><i>server</i> (str)</dt> <dd> -name of the server (string) +name of the server </dd> -<dt><i>port</i></dt> +<dt><i>port</i> (int)</dt> <dd> -value of the port (integer) +value of the port </dd> </dl> <dl> <dt>Return:</dt> <dd> -tuple indicating to ignore the SSL errors (one of NotIgnored, - SystemIgnored or UserIgnored) and indicating a change of the - default SSL configuration (boolean) +tuple indicating to ignore the SSL errors and indicating a + change of the default SSL configuration +</dd> +</dl> +<dl> +<dt>Return Type:</dt> +<dd> +tuple of (E5SslErrorState, bool) </dd> </dl> <a NAME="E5SslErrorHandler.sslErrorsReply" ID="E5SslErrorHandler.sslErrorsReply"></a> @@ -226,4 +235,36 @@ </dl> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5SslErrorState" ID="E5SslErrorState"></a> +<h2>E5SslErrorState</h2> + +<p> + Class defining the SSL error handling states. +</p> +<h3>Derived from</h3> +enum.Enum +<h3>Class Attributes</h3> + +<table> +<tr><td>NOT_IGNORED</td></tr><tr><td>SYSTEM_IGNORED</td></tr><tr><td>USER_IGNORED</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.E5Network.E5UrlInfo.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.E5Network.E5UrlInfo.html Wed Apr 28 19:42:28 2021 +0200 @@ -38,6 +38,10 @@ <td><a href="#E5UrlInfo">E5UrlInfo</a></td> <td>Class implementing a replacement for QUrlInfo.</td> </tr> +<tr> +<td><a href="#E5UrlPermission">E5UrlPermission</a></td> +<td>Class defining the URL permissions.</td> +</tr> </table> <h3>Functions</h3> @@ -57,7 +61,7 @@ <h3>Class Attributes</h3> <table> -<tr><td>ExeGroup</td></tr><tr><td>ExeOther</td></tr><tr><td>ExeOwner</td></tr><tr><td>ReadGroup</td></tr><tr><td>ReadOther</td></tr><tr><td>ReadOwner</td></tr><tr><td>WriteGroup</td></tr><tr><td>WriteOther</td></tr><tr><td>WriteOwner</td></tr> +<tr><td>None</td></tr> </table> <h3>Class Methods</h3> @@ -542,4 +546,36 @@ </dl> <div align="right"><a href="#top">Up</a></div> <hr /> +<hr /> +<a NAME="E5UrlPermission" ID="E5UrlPermission"></a> +<h2>E5UrlPermission</h2> + +<p> + Class defining the URL permissions. +</p> +<h3>Derived from</h3> +enum.IntEnum +<h3>Class Attributes</h3> + +<table> +<tr><td>EXE_GROUP</td></tr><tr><td>EXE_OTHER</td></tr><tr><td>EXE_OWNER</td></tr><tr><td>READ_GROUP</td></tr><tr><td>READ_OTHER</td></tr><tr><td>READ_OWNER</td></tr><tr><td>WRITE_GROUP</td></tr><tr><td>WRITE_OTHER</td></tr><tr><td>WRITE_OWNER</td></tr> +</table> +<h3>Class Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> +<h3>Static Methods</h3> + +<table> +<tr><td>None</td></tr> +</table> + +<div align="right"><a href="#top">Up</a></div> +<hr /> </body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.Network.IRC.IrcMessageEdit.html Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Documentation/Source/eric6.Network.IRC.IrcMessageEdit.html Wed Apr 28 19:42:28 2021 +0200 @@ -101,25 +101,24 @@ <a NAME="IrcMessageEdit.__init__" ID="IrcMessageEdit.__init__"></a> <h4>IrcMessageEdit (Constructor)</h4> -<b>IrcMessageEdit</b>(<i>parent=None, inactiveText="", side=E5LineEdit.RightSide</i>) +<b>IrcMessageEdit</b>(<i>parent=None, inactiveText="", side=E5LineEditSide.RIGHT</i>) <p> Constructor </p> <dl> -<dt><i>parent</i></dt> +<dt><i>parent</i> (QWidget)</dt> <dd> -reference to the parent widget (QWidget) +reference to the parent widget </dd> -<dt><i>inactiveText</i></dt> +<dt><i>inactiveText</i> (str)</dt> <dd> -text to be shown on inactivity (string) +text to be shown on inactivity </dd> -<dt><i>side</i></dt> +<dt><i>side</i> (E5LineEditSide)</dt> <dd> side the clear button should be shown at - (E5LineEdit.RightSide, E5LineEdit.LeftSide) </dd> </dl> <a NAME="IrcMessageEdit.__addHistory" ID="IrcMessageEdit.__addHistory"></a>
--- a/eric6/E5Graphics/E5ArrowItem.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Graphics/E5ArrowItem.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,25 +7,31 @@ Module implementing a graphics item subclass for an arrow. """ +import enum import math from PyQt5.QtCore import QPointF, QRectF, QSizeF, QLineF, Qt from PyQt5.QtGui import QPen, QPolygonF, QColor from PyQt5.QtWidgets import QAbstractGraphicsShapeItem, QGraphicsItem, QStyle -NormalArrow = 1 -WideArrow = 2 - ArrowheadAngleFactor = 0.26179938779914941 # That is: 0.5 * math.atan(math.sqrt(3.0) / 3.0) +class E5ArrowType(enum.Enum): + """ + Class defining the arrow types. + """ + NORMAL = 1 + WIDE = 2 + + class E5ArrowItem(QAbstractGraphicsShapeItem): """ Class implementing an arrow graphics item subclass. """ def __init__(self, origin=None, end=None, - filled=False, arrowType=NormalArrow, colors=None, + filled=False, arrowType=E5ArrowType.NORMAL, colors=None, parent=None): """ Constructor @@ -37,7 +43,7 @@ @param filled flag indicating a filled arrow head @type bool @param arrowType arrow type - @type int, one of NormalArrow, WideArrow + @type E5ArrowType @param colors tuple containing the foreground and background colors @type tuple of (QColor, QColor) @param parent reference to the parent object @@ -48,7 +54,7 @@ self._origin = QPointF() if origin is None else QPointF(origin) self._end = QPointF() if end is None else QPointF(end) self._filled = filled - self._type = arrowType + self.__type = arrowType if colors is None: self._colors = (QColor(Qt.GlobalColor.black), @@ -129,7 +135,11 @@ painter.drawLine(line) # draw the arrow head - arrowAngle = self._type * ArrowheadAngleFactor + arrowAngle = ( + ArrowheadAngleFactor + if self.__type == E5ArrowType.NORMAL else + 2 * ArrowheadAngleFactor + ) slope = math.atan2(line.dy(), line.dx()) # Calculate left arrow point
--- a/eric6/E5Gui/E5ErrorMessage.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5ErrorMessage.py Wed Apr 28 19:42:28 2021 +0200 @@ -10,8 +10,8 @@ import contextlib from PyQt5.QtCore import ( - qInstallMessageHandler, QtDebugMsg, QtWarningMsg, QtCriticalMsg, - QtFatalMsg, QThread, QMetaObject, Qt, Q_ARG, QSettings + qInstallMessageHandler, Qt, Q_ARG, QSettings, QtMsgType, QThread, + QMetaObject ) from PyQt5.QtWidgets import QErrorMessage, QDialog @@ -97,7 +97,6 @@ dlg = E5ErrorMessageFilterDialog( Globals.toList(_filterSettings.value( "MessageFilters", []))) -## _defaultFilters) if dlg.exec() == QDialog.DialogCode.Accepted: filters = dlg.getFilters() _filterSettings.setValue("MessageFilters", filters) @@ -121,13 +120,15 @@ return with contextlib.suppress(RuntimeError): - if msgType == QtDebugMsg: + if msgType == QtMsgType.QtDebugMsg: messageType = "Debug Message:" - elif msgType == QtWarningMsg: + elif msgType == QtMsgType.QtInfoMsg: + messageType = "Info Message:" + elif msgType == QtMsgType.QtWarningMsg: messageType = "Warning:" - elif msgType == QtCriticalMsg: + elif msgType == QtMsgType.QtCriticalMsg: messageType = "Critical:" - elif msgType == QtFatalMsg: + elif msgType == QtMsgType.QtFatalMsg: messageType = "Fatal Error:" if isinstance(message, bytes): message = Utilities.decodeBytes(message) @@ -161,13 +162,15 @@ _origMsgHandler(msgType, message) return - if msgType == QtDebugMsg: + if msgType == QtMsgType.QtDebugMsg: messageType = "Debug Message" - elif msgType == QtWarningMsg: + elif msgType == QtMsgType.QtInfoMsg: + messageType = "Info Message:" + elif msgType == QtMsgType.QtWarningMsg: messageType = "Warning" - elif msgType == QtCriticalMsg: + elif msgType == QtMsgType.QtCriticalMsg: messageType = "Critical" - elif msgType == QtFatalMsg: + elif msgType == QtMsgType.QtFatalMsg: messageType = "Fatal Error" if isinstance(message, bytes): message = message.decode()
--- a/eric6/E5Gui/E5Led.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5Led.py Wed Apr 28 19:42:28 2021 +0200 @@ -9,27 +9,38 @@ It was inspired by KLed. """ +import enum + from PyQt5.QtCore import pyqtSignal, Qt, QSize, QPoint from PyQt5.QtGui import QColor, QRadialGradient, QPalette, QPainter, QBrush from PyQt5.QtWidgets import QWidget -E5LedRectangular = 0 -E5LedCircular = 1 + +class E5LedType(enum.Enum): + """ + Class defining the LED types. + """ + RECTANGULAR = 0 + CIRCULAR = 1 class E5Led(QWidget): """ Class implementing a LED widget. """ - def __init__(self, parent=None, color=None, shape=E5LedCircular, + def __init__(self, parent=None, color=None, shape=E5LedType.CIRCULAR, rectRatio=1): """ Constructor - @param parent reference to parent widget (QWidget) - @param color color of the LED (QColor) - @param shape shape of the LED (E5LedCircular, E5LedRectangular) - @param rectRatio ratio width to height, if shape is rectangular (float) + @param parent reference to parent widget + @type QWidget + @param color color of the LED + @type QColor + @param shape shape of the LED + @type E5LedType + @param rectRatio ratio width to height, if shape is rectangular + @type float """ super().__init__(parent) @@ -52,14 +63,10 @@ @param evt paint event object @type QPaintEvent - @exception TypeError The E5Led has an unsupported shape type. """ - if self.__shape not in (E5LedCircular, E5LedRectangular): - raise TypeError("Unsupported shape type for E5Led.") - - if self.__shape == E5LedCircular: + if self.__shape == E5LedType.CIRCULAR: self.__paintRound() - elif self.__shape == E5LedRectangular: + elif self.__shape == E5LedType.RECTANGULAR: self.__paintRectangular() def __getBestRoundSize(self): @@ -139,7 +146,8 @@ """ Public method to return the LED shape. - @return LED shape (E5LedCircular, E5LedRectangular) + @return LED shape + @rtype E5LedType """ return self.__shape @@ -173,7 +181,8 @@ """ Public method to set the LED shape. - @param shape new LED shape (E5LedCircular, E5LedRectangular) + @param shape new LED shape + @type E5LedType """ if self.__shape != shape: self.__shape = shape @@ -286,15 +295,19 @@ clicked = pyqtSignal(QPoint) middleClicked = pyqtSignal(QPoint) - def __init__(self, parent=None, color=None, shape=E5LedCircular, + def __init__(self, parent=None, color=None, shape=E5LedType.CIRCULAR, rectRatio=1): """ Constructor - @param parent reference to parent widget (QWidget) - @param color color of the LED (QColor) - @param shape shape of the LED (E5LedCircular, E5LedRectangular) - @param rectRatio ratio width to height, if shape is rectangular (float) + @param parent reference to parent widget + @type QWidget + @param color color of the LED + @type QColor + @param shape shape of the LED + @type E5LedType + @param rectRatio ratio width to height, if shape is rectangular + @type float """ super().__init__(parent, color, shape, rectRatio)
--- a/eric6/E5Gui/E5LineEdit.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5LineEdit.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,6 +7,8 @@ Module implementing specialized line edits. """ +import enum + from PyQt5.QtCore import pyqtSignal, Qt, QEvent from PyQt5.QtWidgets import ( QLineEdit, QWidget, QHBoxLayout, QBoxLayout, QLayout, QApplication, @@ -44,13 +46,18 @@ return QWidget.event(self, evt) +class E5LineEditSide(enum.Enum): + """ + Class defining the line edit sides. + """ + LEFT = 0 + RIGHT = 1 + + class E5LineEdit(QLineEdit): """ Class implementing a line edit widget showing some inactive text. """ - LeftSide = 0 - RightSide = 1 - def __init__(self, parent=None, inactiveText=""): """ Constructor @@ -165,19 +172,20 @@ """ Public method to add a widget to a side. - @param widget reference to the widget to add (QWidget) - @param position position to add to (E5LineEdit.LeftSide, - E5LineEdit.RightSide) + @param widget reference to the widget to add + @type QWidget + @param position position to add to + @type E5LineEditSide """ if widget is None: return if self.isRightToLeft(): - if position == self.LeftSide: - position = self.RightSide + if position == E5LineEditSide.LEFT: + position = E5LineEditSide.RIGHT else: - position = self.LeftSide - if position == self.LeftSide: + position = E5LineEditSide.LEFT + if position == E5LineEditSide.LEFT: self.__leftLayout.addWidget(widget) else: self.__rightLayout.insertWidget(1, widget) @@ -186,7 +194,8 @@ """ Public method to remove a widget from a side. - @param widget reference to the widget to remove (QWidget) + @param widget reference to the widget to remove + @type QWidget """ if widget is None: return @@ -217,15 +226,16 @@ """ Public method to get the text margin for a side. - @param position side to get margin for (E5LineEdit.LeftSide, - E5LineEdit.RightSide) - @return text margin (integer) + @param position side to get margin for + @type E5LineEditSide + @return text margin + @rtype int """ spacing = self.__rightLayout.spacing() w = 0 w = ( self.__leftWidget.sizeHint().width() - if position == self.LeftSide else + if position == E5LineEditSide.LEFT else self.__rightWidget.sizeHint().width() ) if w == 0: @@ -255,19 +265,17 @@ clear button, if it has some contents. """ def __init__(self, parent=None, inactiveText="", - side=E5LineEdit.RightSide): + side=E5LineEditSide.RIGHT): """ Constructor - @param parent reference to the parent widget (QWidget) - @param inactiveText text to be shown on inactivity (string) + @param parent reference to the parent widget + @type QWidget + @param inactiveText text to be shown on inactivity + @type str @param side side the clear button should be shown at - (E5LineEdit.RightSide, E5LineEdit.LeftSide) - @exception ValueError raised to indicate a bad parameter value + @type E5LineEditSide """ - if side not in [E5LineEdit.RightSide, E5LineEdit.LeftSide]: - raise ValueError("Bad value for 'side' parameter.") - super().__init__(parent, inactiveText) from E5Gui.E5LineEditButton import E5LineEditButton
--- a/eric6/E5Gui/E5PassivePopup.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5PassivePopup.py Wed Apr 28 19:42:28 2021 +0200 @@ -19,6 +19,7 @@ @signal clicked emitted to indicate a mouse button click """ + # TODO: covert to Enum Boxed = 0 Custom = 128
--- a/eric6/E5Gui/E5ProcessDialog.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5ProcessDialog.py Wed Apr 28 19:42:28 2021 +0200 @@ -27,9 +27,9 @@ """ Class implementing a dialog starting a process and showing its output. - It starts a QProcess and displays a dialog that - shows the output of the process. The dialog is modal, - which causes a synchronized execution of the process. + It starts a QProcess and displays a dialog that shows the output of the + process. The dialog is modal, which causes a synchronized execution of + the process. """ def __init__(self, outputTitle="", windowTitle="", showProgress=False, parent=None):
--- a/eric6/E5Gui/E5SideBar.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5SideBar.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,6 +7,8 @@ Module implementing a sidebar class. """ +import enum + from PyQt5.QtCore import ( QEvent, QSize, Qt, QByteArray, QDataStream, QIODevice, QTimer ) @@ -19,6 +21,16 @@ import UI.PixmapCache +class E5SideBarSide(enum.Enum): + """ + Class defining the sidebar sides. + """ + NORTH = 0 + EAST = 1 + SOUTH = 2 + WEST = 3 + + class E5SideBar(QWidget): """ Class implementing a sidebar with a widget area, that is hidden or shown, @@ -26,20 +38,16 @@ """ Version = 2 - North = 0 - East = 1 - South = 2 - West = 3 - def __init__(self, orientation=None, delay=200, parent=None): """ Constructor - @param orientation orientation of the sidebar widget (North, East, - South, West) + @param orientation orientation of the sidebar widget + @type E5SideBarSide @param delay value for the expand/shrink delay in milliseconds - (integer) - @param parent parent widget (QWidget) + @type int + @param parent parent widget + @type QWidget """ super().__init__(parent) @@ -89,9 +97,9 @@ self.__tabBar.installEventFilter(self) - self.__orientation = E5SideBar.North + self.__orientation = E5SideBarSide.NORTH if orientation is None: - orientation = E5SideBar.North + orientation = E5SideBarSide.NORTH self.setOrientation(orientation) self.__tabBar.currentChanged[int].connect( @@ -168,7 +176,7 @@ """ self.__minimized = True self.__bigSize = self.size() - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in (E5SideBarSide.NORTH, E5SideBarSide.SOUTH): self.__minSize = self.minimumSizeHint().height() self.__maxSize = self.maximumHeight() else: @@ -179,7 +187,7 @@ self.__stackedWidget.hide() - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in (E5SideBarSide.NORTH, E5SideBarSide.SOUTH): self.setFixedHeight(self.__tabBar.minimumSizeHint().height()) else: self.setFixedWidth(self.__tabBar.minimumSizeHint().width()) @@ -201,7 +209,7 @@ self.__minimized = False self.__stackedWidget.show() self.resize(self.__bigSize) - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in (E5SideBarSide.NORTH, E5SideBarSide.SOUTH): minSize = max(self.__minSize, self.minimumSizeHint().height()) self.setMinimumHeight(minSize) self.setMaximumHeight(self.__maxSize) @@ -280,7 +288,7 @@ index = self.__tabBar.addTab(iconOrLabel) self.__tabBar.setTabToolTip(index, iconOrLabel) self.__stackedWidget.addWidget(widget) - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in (E5SideBarSide.NORTH, E5SideBarSide.SOUTH): self.__minSize = self.minimumSizeHint().height() else: self.__minSize = self.minimumSizeHint().width() @@ -303,7 +311,7 @@ index = self.__tabBar.insertTab(index, iconOrLabel) self.__tabBar.setTabToolTip(index, iconOrLabel) self.__stackedWidget.insertWidget(index, widget) - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in (E5SideBarSide.NORTH, E5SideBarSide.SOUTH): self.__minSize = self.minimumSizeHint().height() else: self.__minSize = self.minimumSizeHint().width() @@ -316,7 +324,7 @@ """ self.__stackedWidget.removeWidget(self.__stackedWidget.widget(index)) self.__tabBar.removeTab(index) - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in (E5SideBarSide.NORTH, E5SideBarSide.SOUTH): self.__minSize = self.minimumSizeHint().height() else: self.__minSize = self.minimumSizeHint().width() @@ -428,7 +436,8 @@ """ Public method to get the orientation of the sidebar. - @return orientation of the sidebar (North, East, South, West) + @return orientation of the sidebar + @rtype E5SideBarSide """ return self.__orientation @@ -436,9 +445,10 @@ """ Public method to set the orientation of the sidebar. - @param orient orientation of the sidebar (North, East, South, West) + @param orient orientation of the sidebar + @type E5SideBarSide """ - if orient == E5SideBar.North: + if orient == E5SideBarSide.NORTH: self.__tabBar.setShape(QTabBar.Shape.RoundedNorth) self.__tabBar.setSizePolicy( QSizePolicy.Policy.Expanding, QSizePolicy.Policy.Preferred) @@ -446,14 +456,14 @@ self.layout.setDirection(QBoxLayout.Direction.TopToBottom) self.layout.setAlignment(self.barLayout, Qt.AlignmentFlag.AlignLeft) - elif orient == E5SideBar.East: + elif orient == E5SideBarSide.EAST: self.__tabBar.setShape(QTabBar.Shape.RoundedEast) self.__tabBar.setSizePolicy( QSizePolicy.Policy.Preferred, QSizePolicy.Policy.Expanding) self.barLayout.setDirection(QBoxLayout.Direction.TopToBottom) self.layout.setDirection(QBoxLayout.Direction.RightToLeft) self.layout.setAlignment(self.barLayout, Qt.AlignmentFlag.AlignTop) - elif orient == E5SideBar.South: + elif orient == E5SideBarSide.SOUTH: self.__tabBar.setShape(QTabBar.Shape.RoundedSouth) self.__tabBar.setSizePolicy( QSizePolicy.Policy.Expanding, QSizePolicy.Policy.Preferred) @@ -461,7 +471,7 @@ self.layout.setDirection(QBoxLayout.Direction.BottomToTop) self.layout.setAlignment(self.barLayout, Qt.AlignmentFlag.AlignLeft) - elif orient == E5SideBar.West: + elif orient == E5SideBarSide.WEST: self.__tabBar.setShape(QTabBar.Shape.RoundedWest) self.__tabBar.setSizePolicy( QSizePolicy.Policy.Preferred, QSizePolicy.Policy.Expanding) @@ -561,7 +571,9 @@ if self.splitter: self.splitterSizes = self.splitter.sizes() self.__bigSize = self.size() - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in ( + E5SideBarSide.NORTH, E5SideBarSide.SOUTH + ): self.__minSize = self.minimumSizeHint().height() self.__maxSize = self.maximumHeight() else: @@ -594,7 +606,7 @@ if state.isEmpty(): return False - if self.__orientation in [E5SideBar.North, E5SideBar.South]: + if self.__orientation in (E5SideBarSide.NORTH, E5SideBarSide.SOUTH): minSize = self.layout.minimumSize().height() maxSize = self.maximumHeight() else:
--- a/eric6/E5Gui/E5TextEditSearchWidget.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5TextEditSearchWidget.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,6 +7,8 @@ Module implementing a horizontal search widget for QTextEdit. """ +import enum + from PyQt5.QtCore import pyqtSlot, Qt, QMetaObject, QSize from PyQt5.QtGui import QPalette, QBrush, QColor, QTextDocument, QTextCursor from PyQt5.QtWidgets import ( @@ -19,6 +21,16 @@ import UI.PixmapCache +class E5TextEditType(enum.Enum): + """ + Class defining the supported text edit types. + """ + UNKNOWN = 0 + QTEXTEDIT = 1 + QTEXTBROWSER = 2 + QWEBENGINEVIEW = 3 + + class E5TextEditSearchWidget(QWidget): """ Class implementing a horizontal search widget for QTextEdit. @@ -38,7 +50,7 @@ self.__setupUi(widthForHeight) self.__textedit = None - self.__texteditType = "" + self.__texteditType = E5TextEditType.UNKNOWN self.__findBackwards = True self.__defaultBaseColor = ( @@ -179,19 +191,15 @@ self.__widthForHeight = widthForHeight - def attachTextEdit(self, textedit, editType="QTextEdit"): + def attachTextEdit(self, textedit, editType=E5TextEditType.QTEXTEDIT): """ Public method to attach a QTextEdit widget. @param textedit reference to the edit widget to be attached @type QTextEdit, QWebEngineView or QWebView @param editType type of the attached edit widget - @type str (one of "QTextEdit", "QWebEngineView" or "QWebView") - @exception ValueError raised to indicate a bad parameter value + @type E5TextEditType """ - if editType not in ["QTextEdit", "QWebEngineView", "QWebView"]: - raise ValueError("Bad value for 'editType' parameter.") - self.__textedit = textedit self.__texteditType = editType @@ -275,10 +283,12 @@ self.findtextCombo.clear() self.findtextCombo.addItems(self.findHistory) - if self.__texteditType == "QTextEdit": + if self.__texteditType in ( + E5TextEditType.QTEXTBROWSER, E5TextEditType.QTEXTEDIT + ): ok = self.__findPrevNextQTextEdit(backwards) self.__findNextPrevCallback(ok) - elif self.__texteditType == "QWebEngineView": + elif self.__texteditType == E5TextEditType.QWEBENGINEVIEW: self.__findPrevNextQWebEngineView(backwards) def __findPrevNextQTextEdit(self, backwards):
--- a/eric6/E5Gui/E5ToolButton.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5ToolButton.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,6 +7,8 @@ Module implementing a specialized tool button subclass. """ +import enum + from PyQt5.QtCore import pyqtSlot, pyqtSignal, Qt, QTimer, QSize from PyQt5.QtWidgets import ( QToolButton, QStyle, QStyleOptionToolButton, QStyleOption, QApplication, @@ -14,6 +16,15 @@ ) +class E5ToolButtonOptions(enum.IntEnum): + """ + Class defining the tool button options. + """ + DEFAULT = 0 + SHOW_MENU_INSIDE = 1 + TOOLBAR_LOOKUP = 2 + + class E5ToolButton(QToolButton): """ Class implementing a specialized tool button subclass. @@ -26,10 +37,6 @@ @signal doubleClicked() emitted when the left mouse button was double clicked """ - NoOptions = 0 - ShowMenuInsideOption = 1 - ToolBarLookOption = 2 - aboutToShowMenu = pyqtSignal() aboutToHideMenu = pyqtSignal() middleClicked = pyqtSignal() @@ -48,7 +55,7 @@ self.setMinimumWidth(16) self.__menu = None - self.__options = E5ToolButton.NoOptions + self.__options = E5ToolButtonOptions.DEFAULT self.__badgeLabel = QLabel(self) font = self.__badgeLabel.font() @@ -104,7 +111,7 @@ @return flag indicating that the menu edge shall be aligned @rtype bool """ - return bool(self.__options & E5ToolButton.ShowMenuInsideOption) + return bool(self.__options & E5ToolButtonOptions.SHOW_MENU_INSIDE) def setShowMenuInside(self, enable): """ @@ -115,9 +122,9 @@ @type bool """ if enable: - self.__options |= E5ToolButton.ShowMenuInsideOption + self.__options |= E5ToolButtonOptions.SHOW_MENU_INSIDE else: - self.__options &= ~E5ToolButton.ShowMenuInsideOption + self.__options &= ~E5ToolButtonOptions.SHOW_MENU_INSIDE @pyqtSlot() def __showMenu(self): @@ -129,7 +136,7 @@ self.aboutToShowMenu.emit() - if self.__options & E5ToolButton.ShowMenuInsideOption: + if self.__options & E5ToolButtonOptions.SHOW_MENU_INSIDE: pos = self.mapToGlobal(self.rect().bottomRight()) if ( QApplication.layoutDirection() == @@ -162,7 +169,7 @@ @return flag indicating toolbar look @rtype bool """ - return bool(self.__options & E5ToolButton.ToolBarLookOption) + return bool(self.__options & E5ToolButtonOptions.TOOLBAR_LOOKUP) def setToolbarButtonLook(self, enable): """ @@ -172,7 +179,7 @@ @type bool """ if enable: - self.__options |= E5ToolButton.ToolBarLookOption + self.__options |= E5ToolButtonOptions.TOOLBAR_LOOKUP opt = QStyleOption() opt.initFrom(self) @@ -180,7 +187,7 @@ QStyle.PixelMetric.PM_ToolBarIconSize, opt, self) self.setIconSize(QSize(size, size)) else: - self.__options &= ~E5ToolButton.ToolBarLookOption + self.__options &= ~E5ToolButtonOptions.TOOLBAR_LOOKUP self.setProperty("toolbar-look", enable) self.style().unpolish(self)
--- a/eric6/E5Gui/E5TreeWidget.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Gui/E5TreeWidget.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,10 +7,20 @@ Module implementing specialized tree views. """ +import enum + from PyQt5.QtCore import pyqtSignal, Qt from PyQt5.QtWidgets import QTreeWidget, QTreeWidgetItem, QAbstractItemView +class E5TreeWidgetItemsState(enum.Enum): + """ + Class defining the items expansion state. + """ + COLLAPSED = 0 + EXPANDED = 1 + + class E5TreeWidget(QTreeWidget): """ Class implementing an extended tree widget. @@ -20,9 +30,6 @@ @signal itemMiddleButtonClicked(QTreeWidgetItem) emitted after a click of the middle button on an item """ - ItemsCollapsed = 0 - ItemsExpanded = 1 - itemControlClicked = pyqtSignal(QTreeWidgetItem) itemMiddleButtonClicked = pyqtSignal(QTreeWidgetItem) @@ -36,7 +43,7 @@ self.__refreshAllItemsNeeded = True self.__allTreeItems = [] - self.__showMode = E5TreeWidget.ItemsCollapsed + self.__showMode = E5TreeWidgetItemsState.COLLAPSED self.setVerticalScrollMode(QAbstractItemView.ScrollMode.ScrollPerPixel) @@ -46,13 +53,9 @@ """ Public method to set the default item show mode. - @param mode default mode (ItemsCollapsed, ItemsExpanded) - @exception ValueError raised to indicate a bad parameter value + @param mode default mode + @type E5TreeWidgetItemsState """ - if mode not in [E5TreeWidget.ItemsCollapsed, - E5TreeWidget.ItemsExpanded]: - raise ValueError("Bad value for 'mode' parameter.") - self.__showMode = mode def allItems(self): @@ -229,7 +232,7 @@ itm.setHidden(False) for index in range(self.topLevelItemCount()): self.topLevelItem(index).setHidden(False) - if self.__showMode == E5TreeWidget.ItemsCollapsed: + if self.__showMode == E5TreeWidgetItemsState.COLLAPSED: self.collapseAll() def clear(self):
--- a/eric6/E5Network/E5Ftp.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Network/E5Ftp.py Wed Apr 28 19:42:28 2021 +0200 @@ -39,6 +39,8 @@ pass +# TODO: convert to Enum +# note: it is used as a preference item as well => IntEnum class E5FtpProxyType: """ Class defining the supported FTP proxy types.
--- a/eric6/E5Network/E5SslErrorHandler.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Network/E5SslErrorHandler.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,8 +7,9 @@ Module implementing a SSL error handler. """ +import contextlib +import enum import platform -import contextlib from PyQt5.QtCore import QObject, QByteArray from PyQt5.QtNetwork import ( @@ -22,6 +23,15 @@ import Globals +class E5SslErrorState(enum.Enum): + """ + Class defining the SSL error handling states. + """ + NOT_IGNORED = 0 + SYSTEM_IGNORED = 1 + USER_IGNORED = 2 + + class E5SslErrorHandler(QObject): """ Class implementing a handler for SSL errors. @@ -29,10 +39,6 @@ It also initializes the default SSL configuration with certificates permanently accepted by the user already. """ - NotIgnored = 0 - SystemIgnored = 1 - UserIgnored = 2 - def __init__(self, parent=None): """ Constructor @@ -105,12 +111,15 @@ """ Public method to handle SSL errors. - @param errors list of SSL errors (list of QSslError) - @param server name of the server (string) - @param port value of the port (integer) - @return tuple indicating to ignore the SSL errors (one of NotIgnored, - SystemIgnored or UserIgnored) and indicating a change of the - default SSL configuration (boolean) + @param errors list of SSL errors + @type list of QSslError + @param server name of the server + @type str + @param port value of the port + @type int + @return tuple indicating to ignore the SSL errors and indicating a + change of the default SSL configuration + @rtype tuple of (E5SslErrorState, bool) """ caMerge = {} certificateDict = Globals.toDict( @@ -135,7 +144,7 @@ if cert not in caNew: caNew.append(cert) if not errorStrings: - return E5SslErrorHandler.SystemIgnored, False + return E5SslErrorState.SYSTEM_IGNORED, False errorString = '.</li><li>'.join(errorStrings) ret = E5MessageBox.yesNo( @@ -192,10 +201,10 @@ "Ssl/CaCertificatesDict", certificateDict) - return E5SslErrorHandler.UserIgnored, caRet + return E5SslErrorState.USER_IGNORED, caRet else: - return E5SslErrorHandler.NotIgnored, False + return E5SslErrorState.NOT_IGNORED, False def __certToString(self, cert): """
--- a/eric6/E5Network/E5UrlInfo.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Network/E5UrlInfo.py Wed Apr 28 19:42:28 2021 +0200 @@ -7,23 +7,30 @@ Module implementing a class replacing QUrlInfo. """ +import enum + from PyQt5.QtCore import QDateTime +class E5UrlPermission(enum.IntEnum): + """ + Class defining the URL permissions. + """ + READ_OWNER = 0o0400 + WRITE_OWNER = 0o0200 + EXE_OWNER = 0o0100 + READ_GROUP = 0o0040 + WRITE_GROUP = 0o0020 + EXE_GROUP = 0o0010 + READ_OTHER = 0o0004 + WRITE_OTHER = 0o0002 + EXE_OTHER = 0o0001 + + class E5UrlInfo: """ Class implementing a replacement for QUrlInfo. """ - ReadOwner = 0o0400 - WriteOwner = 0o0200 - ExeOwner = 0o0100 - ReadGroup = 0o0040 - WriteGroup = 0o0020 - ExeGroup = 0o0010 - ReadOther = 0o0004 - WriteOther = 0o0002 - ExeOther = 0o0001 - def __init__(self): """ Constructor
--- a/eric6/E5Network/E5XmlRpcClient.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/E5Network/E5XmlRpcClient.py Wed Apr 28 19:42:28 2021 +0200 @@ -17,7 +17,7 @@ from E5Network.E5NetworkProxyFactory import proxyAuthenticationRequired try: - from E5Network.E5SslErrorHandler import E5SslErrorHandler + from E5Network.E5SslErrorHandler import E5SslErrorHandler, E5SslErrorState SSL_AVAILABLE = True except ImportError: SSL_AVAILABLE = False @@ -107,7 +107,7 @@ QEventLoop.ProcessEventsFlag.ExcludeUserInputEvents) ignored = self.__sslErrorHandler.sslErrorsReply(reply, errors)[0] - if ignored == E5SslErrorHandler.NotIgnored and reply in self.__callmap: + if ignored == E5SslErrorState.NOT_IGNORED and reply in self.__callmap: self.__callmap[reply][1](xmlrpc.TRANSPORT_ERROR, self.tr( "SSL Error"))
--- a/eric6/Graphics/AssociationItem.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Graphics/AssociationItem.py Wed Apr 28 19:42:28 2021 +0200 @@ -10,16 +10,17 @@ from PyQt5.QtCore import QPointF, QRectF, QLineF from PyQt5.QtWidgets import QGraphicsItem -from E5Graphics.E5ArrowItem import E5ArrowItem, NormalArrow, WideArrow +from E5Graphics.E5ArrowItem import E5ArrowItem, E5ArrowType import Utilities +# TODO: convert to Enum Normal = 0 Generalisation = 1 Imports = 2 - +# TODO: convert to Enum NoRegion = 0 West = 1 North = 2 @@ -61,10 +62,10 @@ @type QGraphicsItem """ if assocType in (Normal, Imports): - arrowType = NormalArrow + arrowType = E5ArrowType.NORMAL arrowFilled = True elif assocType == Generalisation: - arrowType = WideArrow + arrowType = E5ArrowType.WIDE arrowFilled = False E5ArrowItem.__init__(self, QPointF(0, 0), QPointF(100, 100),
--- a/eric6/Graphics/ClassItem.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Graphics/ClassItem.py Wed Apr 28 19:42:28 2021 +0200 @@ -131,6 +131,8 @@ self.header.setPos(x, y) y += self.header.boundingRect().height() + self.margin if not self.noAttrs and not self.external: + # TODO: add class attributes next to the instance attributes + # separate class and instance attributes by dashed line if attrs: txt = "\n".join(attrs) else:
--- a/eric6/Network/IRC/IrcMessageEdit.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Network/IRC/IrcMessageEdit.py Wed Apr 28 19:42:28 2021 +0200 @@ -9,7 +9,7 @@ from PyQt5.QtCore import Qt -from E5Gui.E5LineEdit import E5LineEdit, E5ClearableLineEdit +from E5Gui.E5LineEdit import E5LineEditSide, E5ClearableLineEdit class IrcMessageEdit(E5ClearableLineEdit): @@ -19,14 +19,16 @@ MaxHistory = 100 def __init__(self, parent=None, inactiveText="", - side=E5LineEdit.RightSide): + side=E5LineEditSide.RIGHT): """ Constructor - @param parent reference to the parent widget (QWidget) - @param inactiveText text to be shown on inactivity (string) + @param parent reference to the parent widget + @type QWidget + @param inactiveText text to be shown on inactivity + @type str @param side side the clear button should be shown at - (E5LineEdit.RightSide, E5LineEdit.LeftSide) + @type E5LineEditSide """ super().__init__(parent, inactiveText, side)
--- a/eric6/Network/IRC/IrcWidget.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Network/IRC/IrcWidget.py Wed Apr 28 19:42:28 2021 +0200 @@ -17,7 +17,7 @@ from PyQt5.QtNetwork import QTcpSocket, QAbstractSocket try: from PyQt5.QtNetwork import QSslSocket, QSslConfiguration - from E5Network.E5SslErrorHandler import E5SslErrorHandler + from E5Network.E5SslErrorHandler import E5SslErrorHandler, E5SslErrorState SSL_AVAILABLE = True except ImportError: SSL_AVAILABLE = False @@ -918,7 +918,7 @@ """ ignored, defaultChanged = self.__sslErrorHandler.sslErrors( errors, self.__server.getName(), self.__server.getPort()) - if ignored == E5SslErrorHandler.NotIgnored: + if ignored == E5SslErrorState.NOT_IGNORED: self.networkWidget.addErrorMessage( self.tr("SSL Error"), self.tr( @@ -932,7 +932,7 @@ if defaultChanged: self.__socket.setSslConfiguration( QSslConfiguration.defaultConfiguration()) - if ignored == E5SslErrorHandler.UserIgnored: + if ignored == E5SslErrorState.USER_IGNORED: self.networkWidget.addErrorMessage( self.tr("SSL Error"), self.tr(
--- a/eric6/PluginManager/PluginManager.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/PluginManager/PluginManager.py Wed Apr 28 19:42:28 2021 +0200 @@ -27,7 +27,7 @@ from E5Network.E5NetworkProxyFactory import proxyAuthenticationRequired try: - from E5Network.E5SslErrorHandler import E5SslErrorHandler + from E5Network.E5SslErrorHandler import E5SslErrorHandler, E5SslErrorState SSL_AVAILABLE = True except ImportError: SSL_AVAILABLE = False @@ -1388,7 +1388,7 @@ @param errors list of SSL errors (list of QSslError) """ ignored = self.__sslErrorHandler.sslErrorsReply(reply, errors)[0] - if ignored == E5SslErrorHandler.NotIgnored: + if ignored == E5SslErrorState.NOT_IGNORED: self.__downloadCancelled = True ########################################################################
--- a/eric6/PluginManager/PluginRepositoryDialog.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/PluginManager/PluginRepositoryDialog.py Wed Apr 28 19:42:28 2021 +0200 @@ -33,7 +33,7 @@ from E5Network.E5NetworkProxyFactory import proxyAuthenticationRequired try: - from E5Network.E5SslErrorHandler import E5SslErrorHandler + from E5Network.E5SslErrorHandler import E5SslErrorHandler, E5SslErrorState SSL_AVAILABLE = True except ImportError: SSL_AVAILABLE = False @@ -689,7 +689,7 @@ @param errors list of SSL errors (list of QSslError) """ ignored = self.__sslErrorHandler.sslErrorsReply(reply, errors)[0] - if ignored == E5SslErrorHandler.NotIgnored: + if ignored == E5SslErrorState.NOT_IGNORED: self.__downloadCancel(reply) def getDownloadedPlugins(self):
--- a/eric6/Plugins/CheckerPlugins/CodeStyleChecker/Annotations/AnnotationsEnums.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Plugins/CheckerPlugins/CodeStyleChecker/Annotations/AnnotationsEnums.py Wed Apr 28 19:42:28 2021 +0200 @@ -13,6 +13,7 @@ import enum + class FunctionType(enum.Enum): """ Class representing the various function types.
--- a/eric6/UI/CodeDocumentationViewer.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/UI/CodeDocumentationViewer.py Wed Apr 28 19:42:28 2021 +0200 @@ -15,7 +15,7 @@ QLineEdit, QTextBrowser, QToolTip ) -from E5Gui.E5TextEditSearchWidget import E5TextEditSearchWidget +from E5Gui.E5TextEditSearchWidget import E5TextEditSearchWidget, E5TextEditType from E5Gui.E5Application import e5App import Preferences @@ -87,11 +87,11 @@ self.__contents.settings().setAttribute( QWebEngineSettings.WebAttribute.FocusOnNavigationEnabled, False) - self.__viewerType = "QWebEngineView" + self.__viewerType = E5TextEditType.QWEBENGINEVIEW except ImportError: self.__contents = QTextBrowser(self) self.__contents.setOpenExternalLinks(True) - self.__viewerType = "QTextEdit" + self.__viewerType = E5TextEditType.QTEXTBROWSER sizePolicy = QSizePolicy(QSizePolicy.Policy.Preferred, QSizePolicy.Policy.Expanding) @@ -102,7 +102,7 @@ self.__contents.setSizePolicy(sizePolicy) self.__contents.setContextMenuPolicy( Qt.ContextMenuPolicy.NoContextMenu) - if self.__viewerType != "QTextEdit": + if self.__viewerType != E5TextEditType.QTEXTBROWSER: self.__contents.setUrl(QUrl("about:blank")) self.__verticalLayout.addWidget(self.__contents) @@ -112,7 +112,7 @@ self.__verticalLayout.addWidget(self.__searchWidget) self.__searchWidget.attachTextEdit( - self.__contents, self.__viewerType) + self.__contents, editType=self.__viewerType) @pyqtSlot(str) def __showLink(self, urlStr): @@ -139,7 +139,7 @@ """ Public method to clear the shown contents. """ - if self.__viewerType == "QTextEdit": + if self.__viewerType == E5TextEditType.QTEXTBROWSER: self.__contents.clear() else: if e5App().usesDarkPalette():
--- a/eric6/UI/UserInterface.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/UI/UserInterface.py Wed Apr 28 19:42:28 2021 +0200 @@ -60,7 +60,7 @@ E5NetworkProxyFactory, proxyAuthenticationRequired ) try: - from E5Network.E5SslErrorHandler import E5SslErrorHandler + from E5Network.E5SslErrorHandler import E5SslErrorHandler, E5SslErrorState SSL_AVAILABLE = True except ImportError: SSL_AVAILABLE = False @@ -1028,19 +1028,19 @@ @param debugServer reference to the debug server object """ - from E5Gui.E5SideBar import E5SideBar + from E5Gui.E5SideBar import E5SideBar, E5SideBarSide logging.debug("Creating Sidebars Layout...") delay = Preferences.getUI("SidebarDelay") # Create the left sidebar - self.leftSidebar = E5SideBar(E5SideBar.West, delay) + self.leftSidebar = E5SideBar(E5SideBarSide.WEST, delay) # Create the bottom sidebar - self.bottomSidebar = E5SideBar(E5SideBar.South, delay) + self.bottomSidebar = E5SideBar(E5SideBarSide.SOUTH, delay) # Create the right sidebar - self.rightSidebar = E5SideBar(E5SideBar.East, delay) + self.rightSidebar = E5SideBar(E5SideBarSide.EAST, delay) #################################################### ## Populate the left side bar @@ -7287,7 +7287,7 @@ @param errors list of SSL errors (list of QSslError) """ ignored = self.__sslErrorHandler.sslErrorsReply(reply, errors)[0] - if ignored == E5SslErrorHandler.NotIgnored: + if ignored == E5SslErrorState.NOT_IGNORED: self.__downloadCancelled = True #######################################
--- a/eric6/Utilities/FtpUtilities.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/Utilities/FtpUtilities.py Wed Apr 28 19:42:28 2021 +0200 @@ -11,7 +11,7 @@ from PyQt5.QtCore import QObject, QDate, QDateTime, QTime -from E5Network.E5UrlInfo import E5UrlInfo +from E5Network.E5UrlInfo import E5UrlInfo, E5UrlPermission class FtpDirLineParserError(Exception): @@ -80,23 +80,23 @@ permission = 0 if modeString[1] != '-': - permission |= E5UrlInfo.ReadOwner + permission |= E5UrlPermission.READ_OWNER if modeString[2] != '-': - permission |= E5UrlInfo.WriteOwner + permission |= E5UrlPermission.WRITE_OWNER if modeString[3] != '-': - permission |= E5UrlInfo.ExeOwner + permission |= E5UrlPermission.EXE_OWNER if modeString[4] != '-': - permission |= E5UrlInfo.ReadGroup + permission |= E5UrlPermission.READ_GROUP if modeString[5] != '-': - permission |= E5UrlInfo.WriteGroup + permission |= E5UrlPermission.WRITE_GROUP if modeString[6] != '-': - permission |= E5UrlInfo.ExeGroup + permission |= E5UrlPermission.EXE_GROUP if modeString[7] != '-': - permission |= E5UrlInfo.ReadOther + permission |= E5UrlPermission.READ_OTHER if modeString[8] != '-': - permission |= E5UrlInfo.WriteOther + permission |= E5UrlPermission.WRITE_OTHER if modeString[9] != '-': - permission |= E5UrlInfo.ExeOther + permission |= E5UrlPermission.EXE_OTHER urlInfo.setPermissions(permission) if modeString[0] == "d": @@ -292,12 +292,16 @@ ext = os.path.splitext(name.lower())[1] urlInfo.setSymLink(ext == ".lnk") - permissions = (E5UrlInfo.ReadOwner | E5UrlInfo.WriteOwner | - E5UrlInfo.ReadGroup | E5UrlInfo.WriteGroup | - E5UrlInfo.ReadOther | E5UrlInfo.WriteOther) + permissions = ( + E5UrlPermission.READ_OWNER | E5UrlPermission.WRITE_OWNER | + E5UrlPermission.READ_GROUP | E5UrlPermission.WRITE_GROUP | + E5UrlPermission.READ_OTHER | E5UrlPermission.WRITE_OTHER + ) if ext in [".exe", ".com", ".bat", ".cmd"]: permissions |= ( - E5UrlInfo.ExeOwner | E5UrlInfo.ExeGroup | E5UrlInfo.ExeOther + E5UrlPermission.EXE_OWNER | + E5UrlPermission.EXE_GROUP | + E5UrlPermission.EXE_OTHER ) urlInfo.setPermissions(permissions)
--- a/eric6/VCS/StatusMonitorLed.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/VCS/StatusMonitorLed.py Wed Apr 28 19:42:28 2021 +0200 @@ -12,7 +12,7 @@ from PyQt5.QtGui import QColor from PyQt5.QtWidgets import QWidget, QInputDialog, QMenu, QHBoxLayout, QLabel -from E5Gui.E5Led import E5ClickableLed, E5LedRectangular +from E5Gui.E5Led import E5ClickableLed, E5LedType import Preferences @@ -30,7 +30,7 @@ @param parent reference to the parent object (QWidget) """ super().__init__( - parent, shape=E5LedRectangular, rectRatio=1.0) + parent, shape=E5LedType.RECTANGULAR, rectRatio=1.0) self.__vcsClean = True self.project = project
--- a/eric6/WebBrowser/AdBlock/AdBlockTreeWidget.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/WebBrowser/AdBlock/AdBlockTreeWidget.py Wed Apr 28 19:42:28 2021 +0200 @@ -14,7 +14,7 @@ QApplication ) -from E5Gui.E5TreeWidget import E5TreeWidget +from E5Gui.E5TreeWidget import E5TreeWidget, E5TreeWidgetItemsState from E5Gui.E5OverrideCursor import E5OverrideCursor @@ -39,7 +39,7 @@ self.__itemChangingBlock = False self.setContextMenuPolicy(Qt.ContextMenuPolicy.CustomContextMenu) - self.setDefaultItemShowMode(E5TreeWidget.ItemsExpanded) + self.setDefaultItemShowMode(E5TreeWidgetItemsState.EXPANDED) self.setHeaderHidden(True) self.setAlternatingRowColors(True)
--- a/eric6/WebBrowser/UrlBar/UrlBar.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/WebBrowser/UrlBar/UrlBar.py Wed Apr 28 19:42:28 2021 +0200 @@ -16,7 +16,7 @@ except ImportError: QSslCertificate = None # __IGNORE_WARNING__ -from E5Gui.E5LineEdit import E5LineEdit +from E5Gui.E5LineEdit import E5LineEdit, E5LineEditSide from E5Gui.E5LineEditButton import E5LineEditButton from WebBrowser.WebBrowserWindow import WebBrowserWindow @@ -55,28 +55,28 @@ self.__bmActiveIcon.pixmap(16, 16, QIcon.Mode.Disabled)) self.__safeBrowsingLabel = SafeBrowsingLabel(self) - self.addWidget(self.__safeBrowsingLabel, E5LineEdit.LeftSide) + self.addWidget(self.__safeBrowsingLabel, E5LineEditSide.LEFT) self.__safeBrowsingLabel.setVisible(False) self.__favicon = FavIconLabel(self) - self.addWidget(self.__favicon, E5LineEdit.LeftSide) + self.addWidget(self.__favicon, E5LineEditSide.LEFT) self.__sslLabel = SslLabel(self) - self.addWidget(self.__sslLabel, E5LineEdit.LeftSide) + self.addWidget(self.__sslLabel, E5LineEditSide.LEFT) self.__sslLabel.setVisible(False) self.__rssButton = E5LineEditButton(self) self.__rssButton.setIcon(UI.PixmapCache.getIcon("rss16")) - self.addWidget(self.__rssButton, E5LineEdit.RightSide) + self.addWidget(self.__rssButton, E5LineEditSide.RIGHT) self.__rssButton.setVisible(False) self.__bookmarkButton = E5LineEditButton(self) - self.addWidget(self.__bookmarkButton, E5LineEdit.RightSide) + self.addWidget(self.__bookmarkButton, E5LineEditSide.RIGHT) self.__bookmarkButton.setVisible(False) self.__clearButton = E5LineEditButton(self) self.__clearButton.setIcon(UI.PixmapCache.getIcon("clearLeft")) - self.addWidget(self.__clearButton, E5LineEdit.RightSide) + self.addWidget(self.__clearButton, E5LineEditSide.RIGHT) self.__clearButton.setVisible(False) self.__safeBrowsingLabel.clicked.connect(self.__showThreatInfo)
--- a/eric6/WebBrowser/WebBrowserWebSearchWidget.py Tue Apr 27 17:42:00 2021 +0200 +++ b/eric6/WebBrowser/WebBrowserWebSearchWidget.py Wed Apr 28 19:42:28 2021 +0200 @@ -18,7 +18,7 @@ import Preferences -from E5Gui.E5LineEdit import E5ClearableLineEdit +from E5Gui.E5LineEdit import E5ClearableLineEdit, E5LineEditSide from .WebBrowserPage import WebBrowserPage @@ -42,7 +42,6 @@ """ super().__init__(parent) - from E5Gui.E5LineEdit import E5LineEdit from E5Gui.E5LineEditButton import E5LineEditButton from .OpenSearch.OpenSearchManager import OpenSearchManager @@ -59,11 +58,11 @@ self.__engineButton = E5LineEditButton(self) self.__engineButton.setMenu(self.__enginesMenu) - self.addWidget(self.__engineButton, E5LineEdit.LeftSide) + self.addWidget(self.__engineButton, E5LineEditSide.LEFT) self.__searchButton = E5LineEditButton(self) self.__searchButton.setIcon(UI.PixmapCache.getIcon("webSearch")) - self.addWidget(self.__searchButton, E5LineEdit.LeftSide) + self.addWidget(self.__searchButton, E5LineEditSide.LEFT) self.__model = QStandardItemModel(self) self.__completer = QCompleter()