[d-feet: 1/2] Fix format string with python3
- From: Thomas Bechtold <toabctl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [d-feet: 1/2] Fix format string with python3
- Date: Sun, 22 Jul 2018 13:07:46 +0000 (UTC)
commit 9820e4e6d01b0cfac2e18d837f0a8580b6e49c68
Author: Guido Günther <agx sigxcpu org>
Date: Sun Jul 22 10:47:23 2018 +0200
Fix format string with python3
See: !4
Spotted-by: Johannes Sasongko
src/dfeet/introspection_helper.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/dfeet/introspection_helper.py b/src/dfeet/introspection_helper.py
index 7edbdc4..d927d96 100644
--- a/src/dfeet/introspection_helper.py
+++ b/src/dfeet/introspection_helper.py
@@ -11,7 +11,7 @@ def fg_color():
if _style_context is None:
_style_context = Gtk.StyleContext()
color = _style_context.get_color(Gtk.StateFlags.NORMAL)
- _fg_color = "#%x%x%x" % (color.red * 255, color.green * 255, color.blue * 255)
+ _fg_color = "#%02x%02x%02x" % (int(color.red) * 255, int(color.green) * 255, int(color.blue) * 255)
return _fg_color
def args_signature_markup(arg_signature):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]