How do I set a Gtk.StatusIcon as Text?

0 votes
I want to create a Gtk.StatusIcon with custom text. Ideally, I'd like to append this to an existing image, but text-only is ok, too. How can I achieve this?

I've read about getting a Gtk.Label's pixbuf but those methods seem to be removed from Gtk3. Is there any other solution?
Jul 31, 2019 in Python by ana1504.k
• 7,890 points
39 views

1 answer to this question.

0 votes
I don't think that is possible. The status icon is not a widget and the icon is going to be scaled by the window manager. Even if you used Cairo or PIL to generate an image on the fly to use as the icon pixbuf, it wouldn't have the effect of an embedded label in the system tray. It would instead be tiny, unreadable text smushed into the size of the other icons.
answered Jul 31, 2019 by SDeb
• 13,230 points

Related Questions In Python

0 votes
1 answer
0 votes
1 answer

How do I run a set of code for all the requests in Flask?

Hi, You can use dedicated hooks(decorators) called before ...READ MORE

answered Jun 20, 2019 in Python by Shabnam
• 920 points
42 views
0 votes
2 answers

How do I copy a file in python?

copy a file in python  from shutil ...READ MORE

answered Mar 27, 2019 in Python by rajesh
• 1,230 points
88 views
0 votes
1 answer

How do I sort a dictionary by value?

It is not possible to sort a ...READ MORE

answered Jul 30, 2018 in Python by Priyaj
• 57,510 points
39 views
0 votes
1 answer
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 6, 2019 in Python by Neha
• 330 points

edited Jul 8, 2019 by Kalgi 556 views
0 votes
0 answers
0 votes
1 answer

In Python, how do I read a file line-by-line into a list?

with open(fname) as f:     content = f.readlines() # you ...READ MORE

answered Oct 9, 2018 in Python by SDeb
• 13,230 points
162 views
0 votes
1 answer

How do I convert a Python program to a runnable .exe Windows program?

Understand that every 'freezing' application for Python ...READ MORE

answered Oct 12, 2018 in Python by SDeb
• 13,230 points
76 views