Re: Does gtk2 provide a case 'in'-sensitive text search via 'gtk_text_iter_..._search'?

2017-01-26 Thread Eric Cashon via gtk-app-devel-list

 

I worked on this a little more and tried to make it UTF-8 compliant. 
Highlighted the text also. It should still be efficient since it is only doing 
a single pass over each char. I am sure there are things that I haven't 
considered but it does a little more than the first try at it.

https://github.com/cecashon/OrderedSetVelociRaptor/blob/master/Misc/Csamples/search_textbuffer1.c

There are a lot of different functions that you can branch off with this. Most 
are supplied by GTK+ but you never know when you will have need for a special 
purpose function for a text buffer.

Eric
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Screencasting GNOME Under Wayland

2017-01-26 Thread M . Hanny Sabbagh
Hello.


I am working on a simple screen recorder for GNOME under Wayland, built with 
GTK+.


Because Wayland doesn't allow capturing the screen due to security reasons. I 
was trying to capture the desktop in the same way as the built-in screencast 
tool. Using the D-Bus API.


This is the last thing I have reached: https://pastebin.mozilla.org/8969728


However, it gives me only one frame. I thought it would run a loop in the 
background or something until StopScreencast is called again. What's the thing 
I am missing here?


Thank you.
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Prefered way to change the main window initial size

2017-01-26 Thread elboulangero
Hey, maybe I'm asking a very silly question, but still, if anyone who
could point me in the right direction, it would really be appreciated.

Thanks !

___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


caret-color (and caret-width?)

2017-01-26 Thread Richard Shann
I see at

https://developer.gnome.org/gtk3/stable/chap-css-properties.html

that there is a caret-color property. Is it possible to change the
thickness of the text caret?

and, how exactly is caret-color supposed to be set I have:

str = "GtkTextView {caret-color: rgb(255,0,80);}";
gcp= gtk_css_provider_new();
gtk_css_provider_load_from_data(gcp, str, -1, 0);
gtk_style_context_add_provider(gsc, GTK_STYLE_PROVIDER(gcp), 
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);

but this doesn't seem to work (I have other code such as

str =  "GtkTextView:selected {background-color: rgb(200,128,0);}";
gcp= gtk_css_provider_new();
gtk_css_provider_load_from_data(gcp, str, -1, 0);
gtk_style_context_add_provider(gsc, GTK_STYLE_PROVIDER(gcp), 
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);

working nicely).

Richard Shann


___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: gtk_window_set_geometry_hints()

2017-01-26 Thread Kevin Connor Arpe
Hello,

I did not see any replies to this message.  Was it sent to the wrong
mailing list?

On Sun, Jan 22, 2017 at 10:26 PM, Kevin Connor Arpe 
wrote:

> Hello,
>
> Reading the docs/source for v3.22 of gtk_window_set_geometry_hints()
> shows...
> Ref: https://git.gnome.org/browse/gtk+/tree/gtk/
> gtkwindow.c?h=gtk-3-22#n4019
>
> Docs:
> * @geometry_widget: (allow-none): widget the geometry hints used to be
> applied to
>  *   or %NULL. Since 3.20 this argument is ignored and GTK behaves as if
> %NULL was
>  *   set.
>
> Code:
>   if (geometry_widget)
> info->mask &= ~(GDK_HINT_BASE_SIZE | GDK_HINT_RESIZE_INC);
>
> I am confused.  It appears that 'geometry_widget' with non-NULL value will
> change behaviour.
>
> Can you please explain?
>
> Kind regards,
> Kevin Connor ARPE
> Hongkong
>
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list