Re: liststore manipulation question

2010-07-08 Thread Wallace . Owen
Thanks. That looks like what I want. // Wally On Thu, 2010-07-08 at 20:50 +0200, Tadej Borovšak wrote: > Hi. > > You'll probably want to do something like this in your functions (replace my > data parameter with whatever you're using to get widget's inside callback): > > static void > move_

liststore manipulation question

2010-07-08 Thread Wallace . Owen
How do I ask for the previous entry in a list store given the current selection? Here's what I'm trying to do: I've got a list store that I want the user to be able to reorder. The list has two fields: It's ordinal rank and it's name. I'm allowing the user to sort on any field so he can peruse

Re: Locale definitions, dots and commas

2008-03-13 Thread wallace . owen
On Thu, 2008-03-13 at 16:46 +, Dave Howorth wrote: > Martin (OpenGeoMap) wrote: > > > Yes 22 m is the same as 22.000 m > > No, they are not the same. The second one says that something is known > to within a mm. The first does not. > > > PERL Regular expresions are great in C also, but bette

Re: Locale definitions, dots and commas

2008-03-13 Thread wallace . owen
On Thu, 2008-03-13 at 15:48 +, Dave Howorth wrote: > Martin (OpenGeoMap) wrote: > > I am building an intermediate unit system for engineeres in Gobject and > > i hope publish this library soon. > > With this system you always work in lineal measures in meters (double), > > and you can input

Re: Signal emission in multi-threading environment

2007-11-29 Thread wallace . owen
On Thu, 2007-11-29 at 20:07 +0800, Ben Lau wrote: > hi all, > >I am implementing a GObject (a simple video player) that creates a > GStreamer pipeline for video processing. Soon it receives a new > GstBuffer of video frame from the pipeline, it will emit a signal. As > GStreamer processes the

Re: Strange interaction between GtkDialog and a GThread

2007-11-26 Thread wallace . owen
>From the man page for sleep(3): BUGS sleep() may be implemented using SIGALRM; mixing calls to alarm() and sleep() is a bad idea. My guess is that the file dialog has set up something to let it know if some part of it is taking too long, and is using alarm() for that. I

Re: Cannot get realize() events on GtkViewport created by libglade

2007-07-23 Thread wallace . owen
On Mon, 2007-07-23 at 13:28 -0500, [EMAIL PROTECTED] wrote: > > On Mon, 2007-07-23 at 12:34 -0500, [EMAIL PROTECTED] wrote: > ... > > Yeah I said come by during the _week_ ! :D I'm around monday through > *blink* Looks at watch. Looks at calendar. Looks at definition of "week" - > I thought Monday

Re: glade_xml_signal_autoconnect cannot find functions NOT in shared libs?

2007-07-19 Thread wallace . owen
I remember libglade's FAQ/howto has a clue on this topic: there's a link option or something that tells the executable to export it's symbols so they can be seen by the dynamic loader. I don't remember what it is, but I remember your symptoms. // Wally On Thu, 2007-07-19 at 15:19 -0500, [EMAI

Re: Multiple threads and gtk_main()

2007-07-10 Thread wallace . owen
On Tue, 2007-07-10 at 17:44 +0200, Gabriele Greco wrote: > I've a few threads (more than one) doing some work (not accessing GTK > functions), I'd like to have a general way to make them notify their > work to the main loop. > > I used the g_idle_add() in the previous context where I had only a

Re: type-punning warnings with optimizations turned on?

2007-07-06 Thread wallace . owen
On Fri, 2007-07-06 at 08:00 -0700, Alan M. Evans wrote: > On Fri, 2007-07-06 at 09:27 +0200, Jonathan Winterflood wrote: > > Wouldn't that be > > typedef struct MyMutex MyMutex; > > rather? > > > > Or for short : > > typedex struct _MyMutex { > > GStaticMutex mutex; > > } MyMutex; > > Hi. Tha

Re: multi thread app and often variable accessing

2007-06-11 Thread wallace . owen
On Fri, 2007-06-08 at 19:41 -0600, Jim George wrote: > > Begin Curiosity: > > > Also, the hardware must have something like the Pentium CMPXCHG8B [...] > > Is it not > > sufficient to be able to write an int in one single bus access? ie > > have a 32-bit wide data bus > > Or is that exactly the poi

Re: How to get the titles for all top level windows

2007-05-22 Thread wallace . owen
On Tue, 2007-05-22 at 16:33 -0700, Sreeram Akella wrote: > Hi, > I am using GTK version 2.8.9 on Fedora Core 6. > I need to develop an application that lists all top level windows along > with the corresponding titles. I tried using the method > gdk_windows_get_toplevels() to return the GList of al

Re: libglade frustration

2007-02-14 Thread wallace . owen
I just love this car analogy! CARS The technical service manual is available for those that need to service the car. It doesn't come with the assembled car. Maybe it comes with the car if you buy it in kit form. Your repair mechanic needs to refer to it, but if the car's well-made, the user sho

Re: GtkComboBox question

2006-12-19 Thread wallace . owen
On Wed, 2006-12-20 at 02:31 +0200, Paul Pogonyshev wrote: > Russell Markus wrote: > > I am trying to work on an application which has a combo box. I want to > > restrict the user to values that are included in the drop down list only. > > My thought was to prevent the user from editing the value i

Re: events description

2006-12-08 Thread wallace . owen
On Fri, 2006-12-08 at 22:57 +0100, giovanni gherdovich wrote: > Hello. > > Where can I find a description for each event I can > handle with Gtk? > > example: > > the "configure_event" occurs when widget changes size, > the "expose_event" occurs when a widget ... > > and so on. gtk widgets ha

Re: gtk notebook

2006-09-27 Thread Wallace Owen
On Wed, 2006-09-27 at 16:33 -0400, [EMAIL PROTECTED] wrote: > Is it possible to put a list of non-modal gtk dialogs inside a gtk notebook? > I > get this error > > Gtk-ERROR **: file gtkcontainer.c: line 2450 (gtk_container_propagate_expose): > assertion failed: (child->parent == GTK_WIDGET (con

Re: g_spawn_async_with_pipes() and kill()

2006-09-12 Thread Wallace Owen
On Tue, 2006-09-12 at 23:19 +0100, Rui Tiago Cação Matos wrote: > On Ter, 2006-09-12 at 22:37 +0100, Chris Vine wrote: > > Yes, in Linux (and probably most other Unix-like OSs), SIGTERM is defined > > as > > 15. > > Maybe I haven't explained myself clearly. I know SIGTERM is defined as > 15. Ok,

Re: GTK for win32 cannot use stdio???

2006-08-07 Thread Wallace Owen
On Wed, 2006-08-02 at 10:48 +0800, u821417 wrote: > I just download GTK for win32 , developing win32 GTK > applications using VC++ GUI. > But what i am wondering is ... many stdio functions cannot > work??? > (It's ok to compile , but no reaction for running!) > > Such like ... printf、file read/w

Re: file chooser dialog

2006-07-31 Thread Wallace Owen
You need to normalize the paths, then you can string compare them. Given that the current directory were /tmp/barb, normalizing the path will transform ./../file and /tmp/barb/file into ./file. // Wally On Mon, 2006-07-31 at 23:36 +0200, Roland Koebler wrote: > hi, > > > Does anybody also ha

Re: Application runs slowly, crashes when wiggling the mouse quickly

2006-06-16 Thread Wallace Owen
On Thu, 2006-06-15 at 16:28 -0400, [EMAIL PROTECTED] wrote: > No, it's not in a seperate thread, it's a function that gets called > asynchronously by the kernel. But that function *does* then make GTK > calls. Would it be safer to tie my serial port routines to one of those > GDK IO callbacks, th

Re: Application runs slowly, crashes when wiggling the mouse quickly

2006-06-16 Thread Wallace Owen
It sounds like lightening the load merely reduces the chance of hitting some race condition. You say your app makes heavy use of the serial port. Are you doing this in a separate thread? If so, is that thread also making gtk calls (in addition to the main thread)? // Wally On Thu, 2006-06-1

Re: Combo question

2006-04-27 Thread Wallace Owen
You need to allocate storage to hold the strings pointed at by the 2nd parm to g_list_append(). The glist isn't responsible for allocating fresh string space to hold the various strings pointed at by that 2nd parm, so if you keep using the same pointer in calls to g_list_append(), and at the end a

Re: Notification area application

2006-04-06 Thread Wallace Owen
Bob, I'd suggest steering clear of the cvs repository unless you really need the bleeding edge latest stuff. Building gnome isn't for the uninitiated. Don't you have the Fedora CDs? The gnome development RPMs are on one of them, pre-built. Everything you should need. // Wally On Wed, 2006

Re: Segmentation Fault

2006-04-04 Thread Wallace Owen
On Tue, 2006-04-04 at 19:38 -0400, John Vetterli wrote: > On Tue, 4 Apr 2006, Sandeep KS wrote: > > I have written a program using GTK which executes some shellscripts in > > the background...After the shellscripts complete executing, a window is > > displayed showing the completion details A

Re: Theme not affecting titlebar on windows xp... help needed

2006-03-17 Thread Wallace Owen
On Fri, 2006-03-17 at 15:29 -0700, Michael L Torrie wrote: > On Fri, 2006-03-17 at 14:26 -0700, Plummer, Jeff-P56711 wrote: > > I am using the C# port of GTK+ on Windows XP, and I'm trying to write an > > app that is skinnable. Below is my simple test code that attempts to > > set the theme of the

Re: what's the best way to handle variables and objects?

2006-03-15 Thread Wallace Owen
My reply's in the body (I ain't no top-poster!): On Wed, 2006-03-15 at 22:57 +0100, Andreas Kotowicz wrote: > On Wed, 2006-03-15 at 13:44 -0500, John (J5) Palmieri wrote: > > You can create a generic struct but more often than not there is an > > application object or struct that the application d

RE: Closing Main window with out Closing the child window

2006-03-10 Thread Wallace Owen
On Fri, 2006-03-10 at 11:16 -0500, Prabhakar Muthuswamy wrote: > Thanks Yeti, How do I destroy first the firstwindow when I don't have > that pointer when I pop up the second window? By default glade creates > the first window pointer in main.c. In my callbacks.c I don't have > access to this point

Re: Program to Record Multiple Sound Input

2006-03-06 Thread Wallace Owen
On Sat, 2006-03-04 at 15:09 -0500, Tony Freeman wrote: > I wonder if you can help me find a program that may be suitable for what > I need. I'm hoping that there is already a GTK/GNOME based program out > there that does what I want. Search on freshmeat.net for what you want. There are expensive

Re: box around a GtkLabel

2006-03-06 Thread Wallace Owen
t look and feel of Gtk, first rethink (users expectations get perturbed, users get confused, users gets angry with you). Still here? Check out Themes/Styles: http://developer.gnome.org/doc/API/2.0/gtk/GtkStyle.html > - Original Message - > From: "Wallace Owen" &

Re: box around a GtkLabel

2006-03-03 Thread Wallace Owen
On Fri, 2006-03-03 at 19:14 +0100, David Necas (Yeti) wrote: > On Fri, Mar 03, 2006 at 01:09:39PM -0500, Zvi Sebrow wrote: > > I'm trying to draw a box around one or more GtkLabels. > > when i use a GtkDrawingArea, the box comes out fine, > > but the labels are covered by the inside of the box. >

Re: Selection in Radiobutton

2006-03-03 Thread Wallace Owen
On Fri, 2006-03-03 at 12:27 +0600, sadhees kumar wrote: > Friends, > > In my GTK application I am using five Radiobuttons. At any > point of time, only one will be selected. How to identify the selected > Radiobutton? It will look depressed. It's not your fault, and there's nothing to b

Re: GtkSelectionMode

2006-02-21 Thread Wallace Owen
On Tue, 2006-02-21 at 12:03 -0800, Alan M. Evans wrote: > Is there a way to allow the user to select *any* number of elements from > a treeview, including zero? GTK_SELECTION_MULTIPLE almost does, but if > there's a way to unselect the last selected element, I can't figure out > what it is. I hold

Re: Threads and waits

2006-02-15 Thread Wallace Owen
On Wed, 2006-02-15 at 16:26 +0100, Fernando Apesteguía wrote: > Hi, > ... > Under some conditions I would like the collector thread to make a pause. I > don't know how to do it with POSIX functions. I've seen Glib's API > documentation and I'm not sure how could I make this. ¿Should I use a Gcond?

Re: gobject + diacanvas = i really please for help here

2005-12-27 Thread Wallace Owen
On Tue, 2005-12-27 at 13:52 +0100, Przemysław Staniszewski wrote: > Hello > > First of all, sorry for my poor English. It is understandable. > I want write an application. I try, but I create a monster not a > program. So I decide to start once again. When I was writing first > version of it,

Re: Reference to a C++ object in GTK+ callbacks

2005-12-14 Thread Wallace Owen
On Wed, 2005-12-14 at 20:47 +, Chris Vine wrote: > On Wednesday 14 December 2005 20:38, Wallace Owen wrote: > > [snip] > Your version isn't portable either. GTK+ callbacks required C linkage, so to > be portable your code should provide C linkage, and static member func

Re: Reference to a C++ object in GTK+ callbacks

2005-12-14 Thread Wallace Owen
On Wed, 2005-12-14 at 11:28 -0800, Brian J. Tarricone wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > ... > > IIRC, I believe the functions only have to be static in this case if > they're actually C++ class methods. Plain old C global functions don't > need to be static, though if th

Re: Reference to a C++ object in GTK+ callbacks

2005-12-14 Thread Wallace Owen
On Wed, 2005-12-14 at 12:49 -0700, Daryl Lee wrote: > Well, thanks for the correction. I will have to go back through my > projects to understand why I thought that. > > On Wed, 2005-12-14 at 11:19 -0800, Stephen Pollei wrote: > > On 12/13/05, Daryl Lee <[EMAIL PROTECTED]> wrote: > ... > > > C++

Re: Reference to a C++ object in GTK+ callbacks

2005-12-13 Thread Wallace Owen
AnimationFile must have a public virtual function void start(), and m_animation must actually point to an Hbafile, so that when you cast the void* to AnimationFile* it's going to find a vtable slot for start(). If AnimationFile's start() isn't declared virtual, it won't go through the vtable. With

Re: libglade-WARNING **: could not find signal handler

2005-11-10 Thread Wallace Owen
On Thu, 2005-11-10 at 16:26 -0500, Andrew J. Montalenti wrote: > Dear Wallace, > > Thanks for the tip, this patch to my Makefile fixed it: > ... > Shouldn't this be made clear in some of the GTK+/Glade documentation? I > have the official GNOME developers guide, and had all the major web > docume

Re: libglade-WARNING **: could not find signal handler

2005-11-10 Thread Wallace Owen
If it's just one handler that isn't being found but others are, and the others are in a separately linked lib, make sure when you link you use -Wl,-export-dynamic to export the symbols in your app so libglade can find it. // Wally On Thu, 2005-11-10 at 14:15 -0500, Andrew J. Montalenti wrote:

Re: Programming style

2005-10-31 Thread Wallace Owen
On Mon, 2005-10-24 at 17:21 -0400, Tristan Van Berkom wrote: > ... > I just wanted to point out that the user data argument is usable and > efficient (since nobody had mentioned that yet). > > Ofcourse there are cases where it isn't convenient to use the user_data; > I might as well also note that

Re: another magnificant display of GTK software

2005-09-06 Thread Wallace Owen
On Tue, 2005-09-06 at 12:18 -0400, Matthew Yaconis wrote: > Perhaps I'm the only one to follow the link in this email and not be > suspicious but the site has a virus which it attempts to download on your > system. (VBS Soraci B). In other words, "Best^h^h^h^hSafest if viewed with Linux". /

TreeView expander questions (again)

2005-09-01 Thread Wallace Owen
I'd like all the data I put in a treeview visible all the time (fully expanded). Is there a way to make new child rows in my treeview expended when the model tells the view that the row has been added, or must I call gtk_tree_view_expand_all()? Is there a way to make the expanders not show up? A

TreeView expander questions

2005-08-30 Thread Wallace Owen
I'd like all the data I put in a treeview visible all the time (fully expanded). Is there a way to make new child rows in my treeview expended when the model tells the view that the row has been added, or must I call gtk_tree_view_expand_all()? Is there a way to make the expanders not show up? A

Re: stdin redirection help...

2005-08-23 Thread Wallace Owen
It's because /dev/null will only feed you EOF when you try to read from it. On Tue, 2005-08-23 at 17:07 -0300, John Coppens wrote: > Hello all. > > I'm trying to run SPICE from inside a GTK program. I've redirected stdin, > stdout and stderr via pipes. The problem I have is with stdin: > > How c

How do I remove one row from a GtkTreeStore?

2005-08-18 Thread Wallace Owen
I used the function gtk_tree_store_set () to put some data into the treestore. I've got half a dozen root nodes, and several of them have child nodes. All looks spiffy. Now I want to remove the 4th item from the tree. When I put things into the tree I made a path from the new iter, made a row r

Re: gobject reference question

2005-08-15 Thread Wallace Owen
On Mon, 2005-08-15 at 16:29 -0400, Tristan Van Berkom wrote: > Wallace Owen wrote: > > How can I see what the current reference count is, so I can be sure I'm > > using g_object_ref() and g_object_unref() correctly? > > You can check G_OBJECT (object)->ref_count, no

gobject reference question

2005-08-15 Thread Wallace Owen
How can I see what the current reference count is, so I can be sure I'm using g_object_ref() and g_object_unref() correctly? // Wally ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-deve

Re: g_spawn_async_with_pipes: Still no luck

2005-08-04 Thread Wallace Owen
On Thu, 2005-08-04 at 16:00 -0300, John Coppens wrote: > Hello all. > > Could someone please indicate what I doing wrong, or indicate some > example of g_spawn_async_with_pipes where both channels are redirected? Just an aside, but would it help to remember that printf output is buffered, and tha

GtkEntry widget in a MenuItem not getting button_press_event signals

2005-07-29 Thread Wallace Owen
Am I doing something wrong? the online ref. man for GtkMenuItem says: "As it derives from GtkBin it can hold any valid child widget, altough only a few are really useful." .. so I put a GtkTable in it, then put a 2D array of GtkEntry widgets in that, and then connected the GtkEventBoxes to the