Since you are just changing various GtkSettings, it would be better to
use the GtkSettings API:
g_object_set (gtk_settings_get_default (),
"gtk-theme-name", "HighContrastInverse",
"gtk-font-name", "Sans 10",
NULL);
Your original approach may not be working
On 9 Jul 2010, at 11:26, Tadej Borovšak wrote:
>
> From API docs about gdk_window_get_origin():
> ---
> Obtains the position of a window in root window coordinates. (Compare
> with gdk_window_get_position() and gdk_window_get_geometry() which
> return the position of a window relative to its par
On Fri, 2010-07-09 at 11:54 +0200, Miroslav Rajcic wrote:
> I am trying to write a code to set a custom GTK theme for my program (should
> affect only my application).
>
> The problem is that this sample code works fine on Windows, but not on
> Linux:
>
> char *pszStyle = "gtk-theme-name = \"Hi
Hi.
> Thanks Tadej. I looked at gdk_window_get_origin() but it seems to return x
> and y co-ordinates relative to the parent window. What I'm trying to find
> out is which monitor contains (or mostly contains) a given window. Therefore
> I need the screen co-ordinates. I'll try get_frame_ex
On 9 Jul 2010, at 11:09, Tadej Borovšak wrote:
>
> I would probably use gdk_window_get_origin() and
> gdk_drawable_get_size() to obtain the geometry of the window, since
> _get_frame_extents() may include window manager decorations if they
> are present.
>
Thanks Tadej. I looked at gdk_window
Hi.
> Suppose I have two monitors, each of resolution 1024x768. The monitors are
> placed side-by-side to cover a total screen size of 2048x768. I have a
> GdkWindow of some description situated at co-ordinates 900 pixels (x) and 0
> pixels (y).
>
> If the window is (say) 600x600 pixels, it's
I am trying to write a code to set a custom GTK theme for my program (should
affect only my application).
The problem is that this sample code works fine on Windows, but not on
Linux:
char *pszStyle = "gtk-theme-name = \"HighContrastInverse\"\nstyle \"custom\"
{\nfont_name="Sans 10"\n} widge
On 9 Jul 2010, at 10:24, Tor Lillqvist wrote:
>> Ah, maybe I've misunderstood is that in fact what
>> gdk_screen_get_monitor_geometry() will tell me?
>
> Yes. Also note that there can be "holes" in the screen that no monitor covers.
>
Thanks Tor. One more question if I may
Suppose
> Ah, maybe I've misunderstood is that in fact what
> gdk_screen_get_monitor_geometry() will tell me?
Yes. Also note that there can be "holes" in the screen that no monitor covers.
--tml
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome
Many thanks guys. I think I understand it now.
John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Hi.
> "Can I tell how many monitors span the screen horizontally and vertically?"
>
> I've found a function called get_screen_n_monitors() but if it returned (say)
> 4 monitors, would it be possible to tell if they were in a 2x2 array or a 4x1
> array?
You can get the layout of monitors by insp
On 9 Jul 2010, at 10:11, John Emmas wrote:
> Thanks for the quick replies. Actually, I did mean the full geometry of the
> screen, regardless of how many physical monitors it spanned. However, my
> next question was going to be:- "Can I tell how many monitors span the screen
> horizontally a
Thanks for the quick replies. Actually, I did mean the full geometry of the
screen, regardless of how many physical monitors it spanned. However, my next
question was going to be:- "Can I tell how many monitors span the screen
horizontally and vertically?"
I've found a function called get_scr
> Does gtk+ have an API call for obtaining the user's screen resolution (in
> pixels) ?
(Please, avoid the terms "screen" or "display", as they have specific
meanings in X11 and gtk+ which don't match what you probably mean,
which I assume is an individual monitor of potentially several that
are
On 9.7.2010, at 10:18, John Emmas wrote:
> Does gtk+ have an API call for obtaining the user's screen resolution (in
> pixels) ?
Do you mean this?
http://library.gnome.org/devel/gdk/2.90/GdkScreen.html#gdk-screen-get-width
Jaroslav
___
gtk-app-devel
Does gtk+ have an API call for obtaining the user's screen resolution (in
pixels) ?
John
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
16 matches
Mail list logo