Skip to content

Commit 2906bf8

Browse files
committed
l10n: Avoid use of pango tags in msgids
1 parent ce0b3f2 commit 2906bf8

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

action-layout-editor/nemo_action_layout_editor.py

+5-4
Original file line numberDiff line numberDiff line change
@@ -915,12 +915,13 @@ def validate_accelerator(self, key, mods):
915915
# Check nemo's built-ins (copy, paste, etc...)
916916
for shortcut in self.builtin_shortcuts:
917917
if shortcut.key == key and shortcut.mods == mods:
918+
label = f"<b>{shortcut.label}</b>"
918919
dialog = Gtk.MessageDialog(
919920
transient_for=self.main_window,
920921
modal=True,
921922
message_type=Gtk.MessageType.ERROR,
922923
buttons=Gtk.ButtonsType.OK,
923-
text=_("This key combination is already in use by Nemo (<b>%s</b>). It cannot be changed.") % shortcut.label,
924+
text=_("This key combination is already in use by Nemo (%s). It cannot be changed.") % label,
924925
use_markup=True
925926
)
926927
dialog.run()
@@ -941,14 +942,14 @@ def check_for_action_conflict(iter):
941942
if accel_string is not None:
942943
row_key, row_mod = Gtk.accelerator_parse(accel_string)
943944
if row_key == key and row_mod == mods:
945+
label = f"\n\n<b>{row.get_label()}</b>\n\n"
944946
dialog = Gtk.MessageDialog(
945947
transient_for=self.main_window,
946948
modal=True,
947949
message_type=Gtk.MessageType.WARNING,
948950
buttons=Gtk.ButtonsType.YES_NO,
949-
text=_("This key combination is already in use by another action:"
950-
"\n\n<b>%s</b>\n\n"
951-
"Do you want to replace it?") % row.get_label(),
951+
text=_("This key combination is already in use by another action:") +
952+
label + _("Do you want to replace it?"),
952953
use_markup=True
953954
)
954955
resp = dialog.run()

0 commit comments

Comments
 (0)