예제 #1
0
// See #189
func fixPopupMenusWithoutFocus() {
	prov, _ := gtk.CssProviderNew()
	prov.LoadFromData("GtkMenu { margin: 0; }")

	// It must be added to the screen.
	// Adding to the main window has the same effect as putting the CSS in
	// gtk-keys.css (it is overwritten by the theme)
	screen, _ := gdk.ScreenGetDefault()
	gtk.AddProviderForScreen(screen, prov, gtk.STYLE_PROVIDER_PRIORITY_USER)
}
예제 #2
0
파일: real_gtk.go 프로젝트: twstrike/coyim
func (*RealGtk) AddProviderForScreen(s gdki.Screen, provider gtki.StyleProvider, prio uint) {
	gtk.AddProviderForScreen(gdka.UnwrapScreen(s), unwrapStyleProvider(provider), prio)
}