summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2024-01-28 21:11:46 +0100
committerSlávek Banko <slavek.banko@axis.cz>2024-01-28 21:11:46 +0100
commit13bfea6aff1ffed3aa172b5e7ae5540b7e2c3a4a (patch)
treead7052de7d890187859f27cf0a0ee8ff0531ee78
parentbde8dd4103c094d23e7a96d9754d691e385f1cac (diff)
downloadtde-guidance-13bfea6aff1ffed3aa172b5e7ae5540b7e2c3a4a.tar.gz
tde-guidance-13bfea6aff1ffed3aa172b5e7ae5540b7e2c3a4a.zip
Fix invalid escape sequences.
Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
-rwxr-xr-xmountconfig/mountconfig.py4
-rwxr-xr-xserviceconfig/serviceconfig.py6
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())