Re: cairo_path_t to GdkRegion?

2008-04-14 Thread Brian J. Tarricone
On Mon, 14 Apr 2008 02:38:27 -0700 Brian J. Tarricone wrote: > Anybody know of a way to munge a cairo_path_t into at > least an approximate GdkRegion (i.e. suitable for > gdk_window_shape_combine_region())? Or is there a better way to do > this? Figured out something, in case anyone's interested

Translation domains

2008-04-14 Thread Gorshkov
I'm working on an application, and I keep getting messages from my GtkEntry and GtkTextArea widgets "Input method XXX should not use GTK'S translation domain gtk20" Where/How to I set/change the translation domain? ___ gtk-app-devel-list mailing list g

Re: Location entry in GtkFileChooser

2008-04-14 Thread Luis Menina
Hi Carlos. Well, I'm not familiar with GtkFileChooser, but I think you should retrieve the full filename, and then use g_path_get_basename to get the short filename. Cheers, Luis Carlos Pereira a écrit : > Hullo, > > In a GTkFilechooser, how can I acess the information > on the Location entr

Location entry in GtkFileChooser

2008-04-14 Thread Carlos Pereira
Hullo, In a GTkFilechooser, how can I acess the information on the Location entry? I only find functions to get the full filename and uri but not the actual short filename... Carlos ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http:/

Re: Callback Question

2008-04-14 Thread Matí­as Alejandro Torres
Alexander Semenov escribió: > Hi. Perhaps, this discussion was related to threads? > > >> Thank you all for this! Especialy for the long example, but, it was just >> an example. >> I've made an application that works perfectly on Linux but in Window$ it >> crashes a lot! >> I've been trying

How to draw a primitive with one color and fill it with another?

2008-04-14 Thread Sergey Parhomenko
Hello everyone. I want to draw a red circle filled within with a green color on my pixmap. I've set foreground and background colors and passed TRUE as the "filled" parameter to gdk_draw_arc(). But the circle is filled with the same color as it is drawn, that is with the foreground color - red. H

Re: Draw text to a GdkPixbuf

2008-04-14 Thread Alexander Semenov
Why don't you want to draw the text you need in your "expose" function? You simply redefine the GtkWidgetClass "expose-event" and draw there. On Mon, 2008-04-14 at 12:55 +0200, Francesco Sepic wrote: > On Mon, Apr 14, 2008 at 12:31 PM, Alexander Semenov <[EMAIL PROTECTED]> wrote: > > Hi. > > > >

Re: Draw text to a GdkPixbuf

2008-04-14 Thread Francesco Sepic
On Mon, Apr 14, 2008 at 12:31 PM, Alexander Semenov <[EMAIL PROTECTED]> wrote: > Hi. > > What about drawing GdkPixbuf and then your text on GdkWindow? > I'm drawing a scale bar on a map and I'd like to have different types of scale bar. The position of the text that i have to draw (for example "5

Re: Draw text to a GdkPixbuf

2008-04-14 Thread Alexander Semenov
Hi. What about drawing GdkPixbuf and then your text on GdkWindow? On Mon, 2008-04-14 at 12:05 +0200, Francesco Sepic wrote: > Hello, > is it possible to draw text on a GdkPixbuf using Pango? > gdk_draw_text () takes a GdkDrawable as the destination on which draw > text. Is it possible to get a Gd

Re: Preventing Multiple instance of GTK application

2008-04-14 Thread Carlos Pereira
Liam R E Quin wrote: > On Sat, 2008-04-12 at 15:16 +0100, Carlos Pereira wrote: > > I agree with everything you said. But in some cases lock files can be useful... this is the way vim checks if other instances of the same file are open, so the new instance is open in read-only mode... of course

Draw text to a GdkPixbuf

2008-04-14 Thread Francesco Sepic
Hello, is it possible to draw text on a GdkPixbuf using Pango? gdk_draw_text () takes a GdkDrawable as the destination on which draw text. Is it possible to get a GdkDrawable from a GdkPixbuf? Thanks. -- Francesco Sepic <[EMAIL PROTECTED]> ___ gtk-app-d

cairo_path_t to GdkRegion?

2008-04-14 Thread Brian J. Tarricone
Hi all, I'm writing a semi-transparent window widget that uses cairo for drawing. I'm using an ARGB window, and the window itself isn't necessarily rectangular (sometimes it'll have rounded corners of arbitrary radius, and other non-regular shapes are possible). Since I'm using cairo to do the d

Re: Preventing Multiple instance of GTK application

2008-04-14 Thread Liam R E Quin
On Sat, 2008-04-12 at 15:16 +0100, Carlos Pereira wrote: > You can write a .lock file everytime you start and then remove it when > you close. To know if other instance is running, you just have to check > if your .lock file exists. Please don't do this. If you must, take into account (1) mult

Re: Cant get GtkTextBuffer from GtkTextView widget

2008-04-14 Thread Roman Makurin
В Пнд, 14/04/2008 в 09:59 +0300, Tiberius DULUMAN пишет: > The handler should be: > > static void handler(GtkWidget *widget, GtkTextView *tview) > { > GtkTextBuffer *buffer = NULL; > GtkTextIter iterator; > > buffer = gtk_text_view_get_buffer(tview); > g_assert(buffer != NULL);

Re: Callback Question

2008-04-14 Thread Alexander Semenov
Hi. Perhaps, this discussion was related to threads? > Thank you all for this! Especialy for the long example, but, it was just > an example. > I've made an application that works perfectly on Linux but in Window$ it > crashes a lot! > I've been trying to find a solution (actually a clue of wh

Re: Cant get GtkTextBuffer from GtkTextView widget

2008-04-14 Thread Tiberius DULUMAN
The handler should be: static void handler(GtkWidget *widget, GtkTextView *tview) { GtkTextBuffer *buffer = NULL; GtkTextIter iterator; buffer = gtk_text_view_get_buffer(tview); g_assert(buffer != NULL); <<< assert that it is not null gtk_text_buffer_get_end_iter(b