Questions tagged [gdk]

Used to tag things that relate to the GIMP Drawing Kit. The GIMP Drawing Kit is the low-level library that provides platform abstraction for the GTK+ widget toolkit.

Best used to tag things that relate to the GIMP Drawing Kit.

Unfortunately there's some overlap with which deals with the (Google) Glass Development Kit.

317 questions
0
votes
1 answer

How to set bg image of a window in a GTK3 application

I found this way: GdkPixmap *backPixMap = gdk_pixmap_create_from_xpm ( window , NULL , NULL , fileName ); gdk_window_set_back_pixmap( GTK_WIDGET( window )->window , backPixMap , FALSE ); but it seems that GdkPixmap is obsolete now... So, with GTK3,…
Serdar Sanli
  • 1,064
  • 1
  • 11
  • 20
0
votes
1 answer

How do I get the title of the current active window using gdk and Rust?

I'm trying to get the title of the active window using Rust and gdk but I can only find gtk::set_title without gtk::get_title.
Baron Leonardo
  • 329
  • 3
  • 13
0
votes
0 answers

How do I check whether a GDKWindow obtained previously is still valid in GTK+-3?

I wrote a screenshot program in GTK+-3 using the GDK library, it mostly works but I find sometimes the program crashes randomly with X11 errors. I realized that the crashes are triggered if a window is opened and closed instantly, and I was able to…
比尔盖子
  • 2,693
  • 5
  • 37
  • 53
0
votes
1 answer

Converting a Surface back to Pixbuf

I have the following code to draw on a Pixbuf: private Pixbuf drawOnPixbuf(Pixbuf original) { Surface surface = new ImageSurface(Format.Argb32, original.Width, original.Height); Context ctx = new Context(surface); …
Bobface
  • 2,782
  • 4
  • 24
  • 61
0
votes
1 answer

What event can I hook in to that fires as soons as my Gtk3 window *has already* closed?

I'm looking to execute some code just after my Gtk3 window closes. I've tried delete-event, destroy, and destroy-event which seems to not fire at all. I get that there's some difference between Gdk and Gtk, but I'm not exactly sure about what that…
Duncan Marshall
  • 530
  • 1
  • 6
  • 15
0
votes
1 answer

Gnome Keybinder doesn't bind properly to XF86AudioPlay

I've successfully managed to get a Python program to listen for Control+Alt+P and Control+Alt+O even when the window doesn't have focus. However I can't seem to capture events even though the succesfully bind (if spelled…
WinEunuuchs2Unix
  • 1,801
  • 1
  • 17
  • 34
0
votes
1 answer

How to Scroll a ScrolledWindow with arrow keys in Gtk 3.24.5?

I have a gtk entry right below the scrolled window which has the default focus , left and right keys move the cursor in the entry ,I am able to catch the key press events for up and down arrow keys but don't know how to scroll the scrolled window,…
Archith
  • 17
  • 7
0
votes
0 answers

GTK3: Detect SHIFT was pressed during application start

I'm writing a simple GTK3 application and I need to detect, that SHIFT key is pressed during while application is loading. I want to quit as early as possible, if SHIFT is not pressed. So I have no application window at this point How can I query…
dmzkrsk
  • 2,011
  • 2
  • 20
  • 30
0
votes
0 answers

Use functionality of GdkWindow for GtkWindow

I have a GtkWindow and want to use the functionality of gdk_window_get_visible_region() and gdk_window_shape_combine_region_() on them in order to create a custom shaped window. I understand that GtkWindow and GdkWindow are very different objects. I…
Natjo
  • 2,005
  • 29
  • 75
0
votes
1 answer

Gtk3 textView does not display entire file (of a certain size) - last lines are invisible

Gtk3 textView does not display entire file (of a certain size) - last lines are invisible. The demo code was abstracted from an app I am developing. All error handling code, extraneous widgets etc. removed. Loading the sample file "zs.txt" - only…
Stephen
  • 1
  • 1
0
votes
2 answers

Put Gdk.RGBA into Gtk.ListStore, get it back, found a different color

I put a Gdk.RGBA into a Gtk.ListStore, and tried to get it back: import gi gi.require_version('Gtk', '3.0') from gi.repository import Gtk, Gdk model = Gtk.ListStore(int, int, Gdk.RGBA) bgcolor = Gdk.RGBA(red=1, green=0, blue=0) model.append([0, 10,…
johnchen902
  • 9,531
  • 1
  • 27
  • 69
0
votes
0 answers

C++ GDK3.0 What are these pixel values?

I am trying to get pixel rgb values from previously captured screen area. After saving gdk_pixbuf_get_pixels() data to a file I just get weird signs insted of rgb pixel value. I have no idea what is it and how to read it. In python I was getting…
0
votes
1 answer

Linux - Eclipse cpp 2019 06 - unhandled event loop exception when opening files

When I install a fresh Eclipse, I can open the program, but when I attempt to create a new blank cpp file or open a file, the program stalls, I get a popup as seen below, and the terminal from which I launched the application looks like the 2nd…
Totem
  • 7,189
  • 5
  • 39
  • 66
0
votes
1 answer

When writing an installer for my gtk app, how should I deal with gtk dependencies?

I have installed gtk on my centos 7 machine and developed a simple gui app that uses gtk. I would now like to write an installer that installs both my app and the required gtk dependencies so that it is easy for the end user to install and run. But…
Altair
  • 117
  • 8
0
votes
1 answer

How to connect a cursor motion signal to a function (GTK)

I'm writing a C program using the GTK libraries that reads the position of the cursor and writes it out to another function. I've written code that's able to accurately read the cursor position data, but I can't figure out how to connect a cursor…
newothegreat
  • 103
  • 4