scrolled window adjustment 'changed' signal question
Hi, As from my previous email, I require the dimensions of the scrolled window. I decided to detect when they change (due to the top level window being resized) by using the 'changed' signal emitted by the hadjustment and vadjustment respectively. So I create two user functions one for when window width is changed, and the other for when window height is changed. Using g_signal_connect I connect the scrolled window's hadjustment and vadjustments respectively (to the user functions). The behaviour seems a little odd though: if I only change width OR height (NOT both) then BOTH adjustments emit the 'changed' signal. Is this supposed to happen like this? (gtk version 2.20) Thanks, James. ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: obtaining current viewport/scrolled window dimensions
On 22 September 2010 23:49, James Morris wrote: > Hi, > > I have a GtkDrawingArea within a GtkViewport within a > GtkScrolledWindow. I need the viewport dimensions so I can center the > contents of the drawing area when the drawn contents are smaller than > the viewport/window. There is a vague mention of "page_size" in the > documentation for scrolled window but no other clues. > > How do I get these dimensions please? Sorry for the noise, I figured it out once I wrote the email and clicked send: width = gtk_adjustment_get_page_size(gtk_scrolled_window_get_hadjustment(my_scrolled_window)); height = gtk_adjustment_get_page_size(gtk_scrolled_window_get_vadjustment(my_scrolled_window)); ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
obtaining current viewport/scrolled window dimensions
Hi, I have a GtkDrawingArea within a GtkViewport within a GtkScrolledWindow. I need the viewport dimensions so I can center the contents of the drawing area when the drawn contents are smaller than the viewport/window. There is a vague mention of "page_size" in the documentation for scrolled window but no other clues. How do I get these dimensions please? Cheers, James. -- _ : http://jwm-art.net/ -audio/image/text/code ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
How to know if a window got a child window?
Hi, i am trying to save power in my gpxview geocaching app. Thus i keep track whenever the main window looses focus and disable the GPS receiver after some time. Unfortunately this also happens if dialogs are being shown as this also causes the main window to loose focus. I could now add some code to each dialog to inform the main window that there's now a child window and thus to keep the GPS enabled. It would be easier if my main window could somehow deterimine if it lost focus to a subwindow all by itself. How could this be accomplished? Is there some signal emitted if a window gets a subwindow? Thanks, Till -- Dr. Till Harbaum ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
[ann] gsettings support in waf
Hi everyone! I wrote a patch to add gsettings support to waf, which has just been merged into SVN. Here is how it is used: http://code.google.com/p/waf/source/browse/trunk/demos/glib2/wscript Presumably it will be released in waf 1.6.0, whenever that is released, or you can easily use waf SVN (but be warned you have a few changes to do to old wscript files to make them work with the 1.6 branch) hope this is useful! Sam ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
GtkSocket in GtkNotebook
Hi everyone! I am currently developing an application where I have one component that is basically a GtkNotebook, where every page contains a GtkSocket as the widget. On creating many pages, at some point something starts terribly misbehaving: The newly created GtkSocket steadily gets plug-added and plug-removed signals (alternating), with seemingly random memory addresses (curiously, they are normally 110 bytes appart) as child widgets (all valid GdkWindows though). I extracted the problematic code to a simple example program: http://gist.github.com/565078 Compile with: "g++ gtknotebook-gtksocket_bug.cpp `pkg-config --cflags --libs gtk+-2.0` -o gtknotebook-gtksocket_bug" I am completely baffled by this behaviour, no idea what is going on. All help is greatly appreciated. Regards, Prof. MAAD ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: Take part in gkt+ development
Alexander Kuleshov wrote: 1) If i write patch, where must i send it? gtk-devel might be a more appropriate list. This list is for developers of GTK applications and not for GTK development. :) 2) What version of gtk+, must i use for development? From git? I am not a gtk developer (I am a gtk app developer), but yes, I would think you should start with the latest GTK+ git checkout. Special note: GTK+ 1.x is deprecated - do not look at this. GTK+ 2.x is in the process of being deprecated. GTK+ 3.x is where the majority of development is happening. ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Take part in gkt+ development
Hello list, First of all let me introduce myself. My name is Alexander Kuleshov. Now I m student, programmer. I have some expirience in C/gtk+ programming (i took part in Google summer of Code in this year) And I want to take part in gtk+/glib development. I have some question: 1) If i write patch, where must i send it? 2) What version of gtk+, must i use for development? From git? Thank you. ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: Getting native colors in GTK/GDK?
(Sending a copy also to the gtk-app-devel-list. Please keep discussions that start on a public mailing list public unless you specifically have private personal or confidential matters to discuss in some messages.). > I just found libwimp.dll off in some subfolder, but I don't think I added > that folder to my path, therefor it wasn't loaded at runtime. You have misunderstood. You don't need to add the "some subfolder" where libwimp.dll or other theme engines are to PATH for them to be found when required. Note the "when required". I.e., when your gtkrc file tells GTK+ to use a theme that uses such an engine. The gtk-theme-name line in the gtkrc file points GTK+ to *another* gtkrc file, in share/themes//gtk-2.0/gtkrc , which then contains lots of settings for the theme, and an "engine" line that tells the name of the engine module (DLL) to load. GTK+ knows where the engine modules are. > Initially I thought I only had to add ./bin, which would explain the lack of > "theme". No, you don't necessarily have to have the bin folder (where the GTK+ stack "normal" DLLs, i.e. those used by applications, are). If you run an executable that is located in the same bin folder (like gtk-demo.exe or your own executable you have copied into the same folder), it will find its DLLs. --tml ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list