Check-in [c4adfede4a]
Overview
| Comment: | Give up. Just use embedded PNG for transparent empty_pixbif. |
|---|---|
| Downloads: | Tarball | ZIP archive | SQL archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
c4adfede4afe78cbbc75ef5b61d3ac96 |
| User & Date: | mario on 2015-04-11 16:09:08 |
| Other Links: | manifest | tags |
Context
|
2015-04-11
| ||
| 16:09 | Safeguard get_data for plugin_meta(), as global or local extras would be found by module_list, but not get_data(). check-in: d781433c78 user: mario tags: trunk | |
| 16:09 | Give up. Just use embedded PNG for transparent empty_pixbif. check-in: c4adfede4a user: mario tags: trunk | |
| 16:08 | Fix bookmarks tab swtich on search completion. check-in: 98f8aea21d user: mario tags: trunk | |
Changes
Modified uikit.py from [88cac9ca23] to [d93cf9191f].
| ︙ | ︙ | |||
42 43 44 45 46 47 48 |
if ver==3:
from gi import pygtkcompat as pygtk
pygtk.enable()
pygtk.enable_gtk(version='3.0')
from gi.repository import Gtk as gtk
from gi.repository import GObject as gobject
from gi.repository import GdkPixbuf
| < < < < < < | 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
if ver==3:
from gi import pygtkcompat as pygtk
pygtk.enable()
pygtk.enable_gtk(version='3.0')
from gi.repository import Gtk as gtk
from gi.repository import GObject as gobject
from gi.repository import GdkPixbuf
__print__(dbg.STAT, gtk)
__print__(dbg.STAT, gobject)
else:
import pygtk
import gtk
import gobject
GdkPixbuf = gtk.gdk
# prepare gtkbuilder data
ui_xml = get_data("gtk3.xml.gz", decode=True, gz=True) #or get_data("gtk3.xml", decode=True)
if ver == 2:
ui_xml = ui_xml.replace('version="3.0"', 'version="2.16"')
# simplified gtk constructors ---------------------------------------------
class uikit:
|
| ︙ | ︙ | |||
508 509 510 511 512 513 514 |
buf = gzip_decode(buf)
if buf:
p.write(buf)
pix = p.get_pixbuf()
p.close()
return pix
| | > > > > > > | 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 |
buf = gzip_decode(buf)
if buf:
p.write(buf)
pix = p.get_pixbuf()
p.close()
return pix
# Transparent png
empty_pixbuf = uikit.pixbuf(
"""iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAACBjSFJNAA
B6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAABmJLR0QA/wD/AP+gvaeTAAAAB3RJTUU
H3wQLEAE6zgxuGAAAABFJREFUOBFjGAWjYBSMAigAAAQQAAFWMn04AAAAAElFTkSuQmCC"""
)
# Text-only dropdown list.
#
# Necessary because gtk.ComboBoxText binding is absent in debian packages
# https://bugzilla.gnome.org/show_bug.cgi?id=660659
#
|
| ︙ | ︙ |