[polari/backtick-troubles: 1/2] Work around xgettext bug



commit b4482f63d6e4083c5c259a44264331fa1bf36cd2
Author: Florian Müllner <fmuellner gnome org>
Date:   Wed Sep 5 19:30:31 2018 +0200

    Work around xgettext bug
    
    Since commit 7fdbaf0020738, we now use backtick strings where possible;
    however as it turns out, xgettext not only doesn't support extracting
    backtick strings, but in fact chokes up completely on backtick strings
    that contain slashes[0]. Work around the issue by escaping affected
    strings until the underlying bug is fixed.
    
    [0] https://savannah.gnu.org/bugs/?50920#comment5
    
    https://gitlab.gnome.org/GNOME/polari/merge_requests/72

 src/accountsMonitor.js | 2 +-
 src/application.js     | 2 +-
 src/mainWindow.js      | 2 +-
 src/roomList.js        | 4 ++--
 src/userList.js        | 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/src/accountsMonitor.js b/src/accountsMonitor.js
index b45371f..5d2bb11 100644
--- a/src/accountsMonitor.js
+++ b/src/accountsMonitor.js
@@ -54,7 +54,7 @@ var AccountsMonitor = class {
         if (settings)
             return settings;
 
-        let path = `/org/gnome/Polari/Accounts/${account.get_path_suffix()}/`;
+        let path = `/org/gnome/Polari/Accounts/${account.get_path_suffix()}${'/'}`;
         settings = new Gio.Settings({ schema_id: 'org.gnome.Polari.Account',
                                       path: path });
         this._accountSettings.set(accountPath, settings);
diff --git a/src/application.js b/src/application.js
index ae371ba..5363467 100644
--- a/src/application.js
+++ b/src/application.js
@@ -19,7 +19,7 @@ const MAX_RETRIES = 3;
 
 const IRC_SCHEMA_REGEX = /^(irc?:\/\/)([\da-z.-]+):?(\d+)?\/(?:%23)?([\w.+-]+)/i;
 
-const AUTOSTART_DIR = `${GLib.get_user_config_dir()}/autostart`;
+const AUTOSTART_DIR = `${GLib.get_user_config_dir()}${'/'}autostart`;
 const AUTOSTART_FILE = '/org.gnome.Polari.Autostart.desktop';
 
 var Application = GObject.registerClass({
diff --git a/src/mainWindow.js b/src/mainWindow.js
index bd5f7a7..13bc030 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -397,7 +397,7 @@ var MainWindow = GObject.registerClass({
                     this._room.topic.substr(pos, url.pos - pos), -1
                 );
                 let urlText = GLib.markup_escape_text(url.url, -1);
-                subtitle += `${text} <a href="${urlText}">${urlText}</a>`;
+                subtitle += `${text} <a href="${urlText}">${urlText}<${'/'}a>`;
                 pos = url.pos + url.url.length;
             }
             subtitle += GLib.markup_escape_text(this._room.topic.substr(pos), -1);
diff --git a/src/roomList.js b/src/roomList.js
index eabde62..40429d0 100644
--- a/src/roomList.js
+++ b/src/roomList.js
@@ -360,12 +360,12 @@ var RoomListHeader = GObject.registerClass({
                server address, e.g. "GNOME (irc.gnome.org)" */
             let fullTitle = _("%s (%s)").format(accountName, server);
             this._popoverTitle.label = (accountName == server) ? accountName : fullTitle;
-            this._popoverStatus.label = `<sup>${this._getStatusLabel()}</sup>`;
+            this._popoverStatus.label = `<sup>${this._getStatusLabel()}<${'/'}sup>`;
         } else {
             let styleContext = this._popoverStatus.get_style_context();
             styleContext.remove_class('dim-label');
 
-            this._popoverTitle.label = `<b>${_("Connection Problem")}</b>`;
+            this._popoverTitle.label = `<b>${_("Connection Problem")}<${'/'}b>`;
             this._popoverStatus.label = this._getErrorLabel();
         }
     }
diff --git a/src/userList.js b/src/userList.js
index 3dc6b13..7863772 100644
--- a/src/userList.js
+++ b/src/userList.js
@@ -513,7 +513,7 @@ class UserListRow extends Gtk.ListBoxRow {
             let preMatch = this._user.alias.substring(0, filterIndex);
             let theMatch = this._user.alias.substring(filterIndex, filterIndex + this._filter.length);
             let postMatch = this._user.alias.substring(filterIndex + this._filter.length);
-            this._label.label = `${preMatch} <b> ${theMatch} </b> ${postMatch}`;
+            this._label.label = `${preMatch} <b> ${theMatch} <${'/'}b> ${postMatch}`;
         }
     }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]