diff options
author | Slávek Banko <[email protected]> | 2024-01-28 21:11:46 +0100 |
---|---|---|
committer | Slávek Banko <[email protected]> | 2024-01-31 13:19:09 +0100 |
commit | 1825d1c2f638107ca5202ed66491d7d3407539f3 (patch) | |
tree | 82593294eed95a7f0623cbba664c460d090f1626 | |
parent | 10f0a51a1784f390ef81bf59ab5ffc9342de3c81 (diff) | |
download | tde-guidance-1825d1c2f638107ca5202ed66491d7d3407539f3.tar.gz tde-guidance-1825d1c2f638107ca5202ed66491d7d3407539f3.zip |
Fix invalid escape sequences.
Signed-off-by: Slávek Banko <[email protected]>
(cherry picked from commit 13bfea6aff1ffed3aa172b5e7ae5540b7e2c3a4a)
-rwxr-xr-x | mountconfig/mountconfig.py | 4 | ||||
-rwxr-xr-x | serviceconfig/serviceconfig.py | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/mountconfig/mountconfig.py b/mountconfig/mountconfig.py index 260f215..eb28cae 100755 --- a/mountconfig/mountconfig.py +++ b/mountconfig/mountconfig.py @@ -2617,7 +2617,7 @@ class MountEntryDialog(KDialogBase): and not os.path.isfile(self.currentMountEntry.getMountPoint()) and not self.currentMountEntry.mounttype == 'swap'): ask = KMessageBox.warningYesNoCancel(self, - i18n("""The mountpoint '%1' does not exist. You will not be able to enable it until it is created.\ + i18n("""The mountpoint '%1' does not exist. You will not be able to enable it until it is created.\ \nShould I create the mountpoint?""").arg(self.currentMountEntry.getMountPoint()), i18n("Mountpoint does not exist")) if ask==KMessageBox.Cancel: @@ -2626,7 +2626,7 @@ class MountEntryDialog(KDialogBase): os.mkdir(self.currentMountEntry.getMountPoint()) elif os.path.isfile(self.currentMountEntry.getMountPoint()): if KMessageBox.warningContinueCancel(self, - i18n("""The mountpoint '%1' is a file, but it has to be a directory. You will probably not \ + i18n("""The mountpoint '%1' is a file, but it has to be a directory. You will probably not \ be able to enable it.\nContinue?""").arg(self.currentMountEntry.getMountPoint()), i18n("Invalid mountpoint"))!=KMessageBox.Continue: return diff --git a/serviceconfig/serviceconfig.py b/serviceconfig/serviceconfig.py index 1a0c802..42bb543 100755 --- a/serviceconfig/serviceconfig.py +++ b/serviceconfig/serviceconfig.py @@ -1437,9 +1437,9 @@ class CommandRunner(KDialogBase): def slotReadyReadStdout(self): # Remove the colors used by some programs. # FIXME: this probably isn't neccessary anymore. - uncolor = lambda text: re.compile('\\x1b\[[0-9]+;01m').sub("", \ - re.compile('\\x1b\[0m').sub("", re.compile('\\033\[1;[0-9]+m').sub("", \ - re.compile('\\033\[0m').sub("", text)))) + uncolor = lambda text: re.compile('\\x1b\\[[0-9]+;01m').sub("", \ + re.compile('\\x1b\\[0m').sub("", re.compile('\\033\\[1;[0-9]+m').sub("", \ + re.compile('\\033\\[0m').sub("", text)))) self.output += uncolor(str(self.kid.readStdout())) self.outputtextview.setText(self.output) self.outputtextview.ensureVisible(0,self.outputtextview.contentsHeight()) |