diff -r 27f636beebad -r 2c730d5fd177 eric6/Plugins/WizardPlugins/QRegularExpressionWizard/QRegularExpressionWizardServer.py --- a/eric6/Plugins/WizardPlugins/QRegularExpressionWizard/QRegularExpressionWizardServer.py Mon Mar 01 17:48:43 2021 +0100 +++ b/eric6/Plugins/WizardPlugins/QRegularExpressionWizard/QRegularExpressionWizardServer.py Tue Mar 02 17:17:09 2021 +0100 @@ -22,21 +22,29 @@ """ try: from PyQt5.QtCore import QRegularExpression - rxOptions = QRegularExpression.NoPatternOption + rxOptions = QRegularExpression.PatternOption.NoPatternOption if "CaseInsensitiveOption" in options: - rxOptions |= QRegularExpression.CaseInsensitiveOption + rxOptions |= QRegularExpression.PatternOption.CaseInsensitiveOption if "MultilineOption" in options: - rxOptions |= QRegularExpression.MultilineOption + rxOptions |= QRegularExpression.PatternOption.MultilineOption if "DotMatchesEverythingOption" in options: - rxOptions |= QRegularExpression.DotMatchesEverythingOption + rxOptions |= ( + QRegularExpression.PatternOption.DotMatchesEverythingOption + ) if "ExtendedPatternSyntaxOption" in options: - rxOptions |= QRegularExpression.ExtendedPatternSyntaxOption + rxOptions |= ( + QRegularExpression.PatternOption.ExtendedPatternSyntaxOption + ) if "InvertedGreedinessOption" in options: - rxOptions |= QRegularExpression.InvertedGreedinessOption + rxOptions |= ( + QRegularExpression.PatternOption.InvertedGreedinessOption + ) if "UseUnicodePropertiesOption" in options: - rxOptions |= QRegularExpression.UseUnicodePropertiesOption + rxOptions |= ( + QRegularExpression.PatternOption.UseUnicodePropertiesOption + ) if "DontCaptureOption" in options: - rxOptions |= QRegularExpression.DontCaptureOption + rxOptions |= QRegularExpression.PatternOption.DontCaptureOption error = "" errorOffset = -1 @@ -71,21 +79,27 @@ return valid, error, errorOffset from PyQt5.QtCore import QRegularExpression - rxOptions = QRegularExpression.NoPatternOption + rxOptions = QRegularExpression.PatternOption.NoPatternOption if "CaseInsensitiveOption" in options: - rxOptions |= QRegularExpression.CaseInsensitiveOption + rxOptions |= QRegularExpression.PatternOption.CaseInsensitiveOption if "MultilineOption" in options: - rxOptions |= QRegularExpression.MultilineOption + rxOptions |= QRegularExpression.PatternOption.MultilineOption if "DotMatchesEverythingOption" in options: - rxOptions |= QRegularExpression.DotMatchesEverythingOption + rxOptions |= ( + QRegularExpression.PatternOption.DotMatchesEverythingOption + ) if "ExtendedPatternSyntaxOption" in options: - rxOptions |= QRegularExpression.ExtendedPatternSyntaxOption + rxOptions |= ( + QRegularExpression.PatternOption.ExtendedPatternSyntaxOption + ) if "InvertedGreedinessOption" in options: - rxOptions |= QRegularExpression.InvertedGreedinessOption + rxOptions |= QRegularExpression.PatternOption.InvertedGreedinessOption if "UseUnicodePropertiesOption" in options: - rxOptions |= QRegularExpression.UseUnicodePropertiesOption + rxOptions |= ( + QRegularExpression.PatternOption.UseUnicodePropertiesOption + ) if "DontCaptureOption" in options: - rxOptions |= QRegularExpression.DontCaptureOption + rxOptions |= QRegularExpression.PatternOption.DontCaptureOption matched = False captures = []