summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorCharles Bos2019-11-17 19:59:26 +0000
committerCharles Bos2019-11-17 19:59:26 +0000
commite2a233d74fba25126b210c47bd59ad23e8dcb890 (patch)
tree983a88c9e1fbc1f1ec166925b2048784b026e6f8
parent1027589694aa5da4dd107d79161ef2325fd09e00 (diff)
downloadaur-e2a233d74fba25126b210c47bd59ad23e8dcb890.tar.gz
Add ccsm-escape-fix.patch - thanks rharish
-rw-r--r--.SRCINFO6
-rw-r--r--PKGBUILD13
-rw-r--r--ccsm-escape-fix.patch138
3 files changed, 151 insertions, 6 deletions
diff --git a/.SRCINFO b/.SRCINFO
index c24fc15162e..3dbec541c4f 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = compiz-git
pkgdesc = Composite manager for Aiglx and Xgl, with plugins and CCSM (development version)
- pkgver = 0.9.14.0.r0.gb340cc413
- pkgrel = 2
+ pkgver = 0.9.14.0.r1.gfac27fe9a
+ pkgrel = 1
url = https://launchpad.net/compiz
arch = i686
arch = x86_64
@@ -50,12 +50,14 @@ pkgbase = compiz-git
source = reverse-unity-config.patch
source = screenshot-launch-fix.patch
source = no-compile-gschemas.patch
+ source = ccsm-escape-fix.patch
sha256sums = SKIP
sha256sums = f4897590b0f677ba34767a29822f8f922a750daf66e8adf47be89f7c2550cf4b
sha256sums = 16ddb6311ce42d958505e21ca28faae5deeddce02cb558d55e648380274ba4d9
sha256sums = 6ec9c04540ca1649c687d9ab2c8311caea7075831e2cffe719ec7958c9ebab7b
sha256sums = 89ee91a8ea6b1424ef76661ea9a2db43412366aacddc12d24a7adf5e04bfbc61
sha256sums = 4ab3277da201314b3f65e30128bc30704ddee584fdbbfc8d0d83c7e0de91fa9a
+ sha256sums = 033c3be1f54238d07b4ed400d34b2260247ed7269fa281e98eb551b08b9a9188
pkgname = compiz-git
diff --git a/PKGBUILD b/PKGBUILD
index 25eb6d6b575..8cc4737d904 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,8 +5,8 @@
# Contributor: Nathan Hulse <nat.hulse@gmail.com>
pkgname=compiz-git
-pkgver=0.9.14.0.r0.gb340cc413
-pkgrel=2
+pkgver=0.9.14.0.r1.gfac27fe9a
+pkgrel=1
_gitname=compiz
pkgdesc="Composite manager for Aiglx and Xgl, with plugins and CCSM (development version)"
arch=('i686' 'x86_64')
@@ -25,13 +25,15 @@ source=("git+https://git.launchpad.net/${_gitname}"
"gtk-extents.patch"
"reverse-unity-config.patch"
"screenshot-launch-fix.patch"
- "no-compile-gschemas.patch")
+ "no-compile-gschemas.patch"
+ "ccsm-escape-fix.patch")
sha256sums=('SKIP'
'f4897590b0f677ba34767a29822f8f922a750daf66e8adf47be89f7c2550cf4b'
'16ddb6311ce42d958505e21ca28faae5deeddce02cb558d55e648380274ba4d9'
'6ec9c04540ca1649c687d9ab2c8311caea7075831e2cffe719ec7958c9ebab7b'
'89ee91a8ea6b1424ef76661ea9a2db43412366aacddc12d24a7adf5e04bfbc61'
- '4ab3277da201314b3f65e30128bc30704ddee584fdbbfc8d0d83c7e0de91fa9a')
+ '4ab3277da201314b3f65e30128bc30704ddee584fdbbfc8d0d83c7e0de91fa9a'
+ '033c3be1f54238d07b4ed400d34b2260247ed7269fa281e98eb551b08b9a9188')
pkgver() {
cd "${_gitname}"
@@ -55,6 +57,9 @@ prepare() {
# Don't try to compile gschemas during make install
patch -p1 -i "${srcdir}/no-compile-gschemas.patch"
+
+ # Fix HTML-escaping related ccsm crashes
+ patch -p1 -i "${srcdir}/ccsm-escape-fix.patch"
}
build() {
diff --git a/ccsm-escape-fix.patch b/ccsm-escape-fix.patch
new file mode 100644
index 00000000000..a1d20492fb7
--- /dev/null
+++ b/ccsm-escape-fix.patch
@@ -0,0 +1,138 @@
+diff --unified --recursive --text compiz-0.9.14.0/compizconfig/ccsm/ccm/Pages.py compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Pages.py
+--- compiz-0.9.14.0/compizconfig/ccsm/ccm/Pages.py 2019-02-16 18:14:41.000000000 +0530
++++ compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Pages.py 2019-11-17 10:36:48.719451182 +0530
+@@ -33,7 +33,7 @@
+ from ccm.Utils import gtk_process_events, getScreens, Image, PrettyButton, Label, NotFoundBox, GlobalUpdater, CategoryKeyFunc, GroupIndexKeyFunc, PluginKeyFunc, GetSettings, GetAcceleratorName
+ from ccm.Widgets import ClearEntry, PluginView, GroupView, SelectorButtons, ScrolledList, Popup, KeyGrabber, AboutDialog, PluginWindow
+
+-from cgi import escape as protect_pango_markup
++from html import escape as protect_pango_markup
+
+ import os
+
+@@ -397,7 +397,7 @@
+ for index, n in enumerate(context.Plugins):
+ plugin = context.Plugins[n]
+ bar.set_fraction((index+1)/float(length))
+- label.set_markup("<i>%s</i>" %protect_pango_markup(plugin.ShortDesc))
++ label.set_markup("<i>%s</i>" %protect_pango_markup(plugin.ShortDesc, quote=False))
+ gtk_process_events()
+
+ groups = []
+@@ -1383,7 +1383,7 @@
+ self.VisibleAreas = self.subGroupAreas = []
+ self.Label = Gtk.Alignment(xalign=0.0, yalign=0.5)
+ self.Label.set_padding(4, 4, 4, 4)
+- label = Gtk.Label(label="<b>%s</b>" % (protect_pango_markup(name or _('General'))))
++ label = Gtk.Label(label="<b>%s</b>" % (protect_pango_markup(name or _('General'), quote=False)))
+ label.set_use_markup(True)
+ label.set_xalign(0.0)
+ self.Label.add(label)
+diff --unified --recursive --text compiz-0.9.14.0/compizconfig/ccsm/ccm/Settings.py compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Settings.py
+--- compiz-0.9.14.0/compizconfig/ccsm/ccm/Settings.py 2019-02-16 18:14:41.000000000 +0530
++++ compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Settings.py 2019-11-17 10:36:48.719451182 +0530
+@@ -29,7 +29,7 @@
+ from ccm.Widgets import CellRendererColor, ModifierSelector, SingleEdgeSelector, KeyGrabber, MatchButton, FileButton, ErrorDialog
+ from ccm.Utils import Image, ActionImage, SizedButton, GlobalUpdater, PureVirtualError, SettingKeyFunc, EnumSettingKeyFunc, HasOnlyType, GetSettings, GetAcceleratorName
+
+-from cgi import escape as protect_pango_markup
++from html import escape as protect_pango_markup
+
+ import locale
+ import gettext
+@@ -110,7 +110,7 @@
+ return
+
+ label = Gtk.Label()
+- desc = protect_pango_markup (self.Setting.ShortDesc)
++ desc = protect_pango_markup (self.Setting.ShortDesc, quote=False)
+ style = "%s"
+ if self.Setting.Integrated:
+ style = "<i>%s</i>"
+@@ -966,7 +966,7 @@
+ def HandleDialogText (self, accel):
+ name = self.ReorderKeyString (accel)
+ if len (accel) != len (name):
+- accel = protect_pango_markup (accel)
++ accel = protect_pango_markup (accel, quote=False)
+ ErrorDialog (self.Widget.get_toplevel (),
+ _("\"%s\" is not a valid shortcut") % accel)
+ return
+@@ -1149,7 +1149,7 @@
+
+ def HandleDialogText (self, button):
+ def ShowErrorDialog (button):
+- button = protect_pango_markup (button)
++ button = protect_pango_markup (button, quote=False)
+ ErrorDialog (self.Widget.get_toplevel (),
+ _("\"%s\" is not a valid button") % button)
+ if button.lower ().strip () in ("", "disabled", "none"):
+@@ -1330,7 +1330,7 @@
+ valid = False
+ break
+ if not valid:
+- mask = protect_pango_markup (mask)
++ mask = protect_pango_markup (mask, quote=False)
+ ErrorDialog (self.Widget.get_toplevel (),
+ _("\"%s\" is not a valid edge mask") % mask)
+ return
+diff --unified --recursive --text compiz-0.9.14.0/compizconfig/ccsm/ccm/Utils.py compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Utils.py
+--- compiz-0.9.14.0/compizconfig/ccsm/ccm/Utils.py 2019-02-16 18:14:41.000000000 +0530
++++ compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Utils.py 2019-11-17 10:36:48.719451182 +0530
+@@ -27,7 +27,7 @@
+ import weakref
+
+ from ccm.Constants import ImageNone, ImagePlugin, ImageCategory, ImageThemed, ImageStock, DataDir, IconDir
+-from cgi import escape as protect_pango_markup
++from html import escape as protect_pango_markup
+ import operator
+
+ import locale
+@@ -57,7 +57,7 @@
+ return Gdk.Screen.get_default().get_number()
+
+ def protect_markup_dict (dict_):
+- return dict((k, protect_pango_markup (v)) for (k, v) in dict_.items())
++ return dict((k, protect_pango_markup (v, quote=False)) for (k, v) in dict_.items())
+
+ class Image (Gtk.Image):
+
+@@ -187,7 +187,7 @@
+ box = Gtk.HBox()
+ self.Warning = Gtk.Label()
+ self.Markup = _("<span size=\"large\"><b>No matches found.</b> </span><span>\n\n Your filter \"<b>%s</b>\" does not match any items.</span>")
+- value = protect_pango_markup(value)
++ value = protect_pango_markup(value, quote=False)
+ self.Warning.set_markup(self.Markup % value)
+ image = Image("face-surprise", ImageThemed, 48)
+
+@@ -196,7 +196,7 @@
+ self.add(box)
+
+ def update(self, value):
+- value = protect_pango_markup(value)
++ value = protect_pango_markup(value, quote=False)
+ self.Warning.set_markup(self.Markup % value)
+
+ class IdleSettingsParser:
+diff --unified --recursive --text compiz-0.9.14.0/compizconfig/ccsm/ccm/Widgets.py compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Widgets.py
+--- compiz-0.9.14.0/compizconfig/ccsm/ccm/Widgets.py 2019-02-16 18:14:41.000000000 +0530
++++ compiz-0.9.14.0-new/compizconfig/ccsm/ccm/Widgets.py 2019-11-17 10:36:48.719451182 +0530
+@@ -27,7 +27,7 @@
+ from gi.repository import PangoCairo
+ from gi.repository import GdkPixbuf
+ import cairo
+-from cgi import escape as protect_pango_markup
++from html import escape as protect_pango_markup
+ from math import pi, sqrt
+ import time
+ import os
+@@ -295,7 +295,7 @@
+ def add_item(self, item, callback, markup="%s", image=None, info=None):
+ button = Gtk.Button()
+ label = Label(wrap=170)
+- text = protect_pango_markup(item)
++ text = protect_pango_markup(item, quote=False)
+ label.set_markup(markup % text or _("General"))
+ labelBox = Gtk.VBox()
+ labelBox.set_spacing(5) \ No newline at end of file