Re: GtkTextView - The “extend-selection” signal

2018-01-20 Thread Lucky B.C
Well I did it, thank you very much! void cb_gtk_handle_selection (GtkTextBuffer *buffer) { GtkTextIter start; GtkTextIter end; gtk_text_buffer_get_selection_bounds (buffer, , ); } int main () { ... g_signal_connect_swapped (buffer, "notify::has-selection",

Re: GtkTextView - The “extend-selection” signal

2018-01-20 Thread Lucky B.C
Hi, I don't know how to give a good answer in this case. I'm using the gtk3 too, but I also have a small project in the gtk1.2. I only change gtk version when I think it should be changed. Most first open sources the developer used gtk2 for now! On Fri, Jan 19, 2018 at 9:11 PM, Karan Ahuja

Re: GtkTextView - The “extend-selection” signal

2018-01-20 Thread Karan Ahuja
upgrading is fun rarely. :) especially if - it works for now. On Fri, Jan 19, 2018 at 9:40 PM, Lucky B.C wrote: > Hi, I don't know how to give a good answer in this case. I'm using the > gtk3 too, but I also have a small project in the gtk1.2. I only change > gtk version

Re: GtkTextView - The “extend-selection” signal

2018-01-19 Thread Karan Ahuja
Hi , On a related note - I have about a 1000 lines of code working well and using gtk source view. All this is in gtk 3+ I probably have another work of 500 lines to go before I start trying to demo/release to users. should I be prioritizing about : a) upgrading to gtk 4 b) getting the

Re: GtkTextView - The “extend-selection” signal

2018-01-19 Thread Florian Müllner
On Wed, Jan 17, 2018 at 3:19 PM, Lucky B.C wrote: > I'm trying to get the range of the selected word by > gtk_text_iter_get_offset (start) and gtk_text_ter_get_offset (end) on > the “extend-selection” signal, Right, that doesn't work. There is no selected word when the

GtkTextView - The “extend-selection” signal

2018-01-18 Thread Lucky B.C
Hi all, gboolean user_function (GtkTextView *text_view, GtkTextExtendSelection granularity, GtkTextIter *location, GtkTextIter *start, GtkTextIter *end, gpointer