Hiding scrollbars for GtkScrolledWindow

2013-06-07 Thread Felix Möller
Hey there,
I'm trying to use a GtkScrolledWindow with the capability of scrolling,
but not displaying scroll bars (so the content has the appropriate
height). I need this behaviour, because I am using a small touch display
and handle the scrolled with bigger and easier to push buttons.

This is what I come up with, besides several other failed test, but it
does not work:
gtk_widget_hide(gtk_scrolled_window_get_vscrollbar(window));

I tried emulating some code [1] that seems to have worked for someone
working with PyGTK
Somebody has a clue on how to achieve this?
Thanks
 Felix Möller

[1] http://python.6.x6.nabble.com/Hide-scrollbar-tp1941146p1941149.html
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Hiding scrollbars for GtkScrolledWindow

2013-06-07 Thread Stefan Salewski
On Fri, 2013-06-07 at 10:13 +0200, Felix Möller wrote:
> Hey there,
> I'm trying to use a GtkScrolledWindow with the capability of scrolling,
> but not displaying scroll bars

GTK3 or GTK2? Called from C or Python?

This may help:

https://developer.gnome.org/gtk3/stable/GtkScrolledWindow.html#gtk-scrolled-window-set-policy


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

Re: Hiding scrollbars for GtkScrolledWindow

2013-06-07 Thread Felix Möller
Sorry for being unprecise.
GTK3 in combination with C.

If I set the scrollbars' policy to never, the scrollbar is not
displayed, but the window is not as small as it should be, but as big as
its content. I want it to have the same size as with scrollbars, but
without displaying them.

On 06/07/13 13:48, Stefan Salewski wrote:
> On Fri, 2013-06-07 at 10:13 +0200, Felix Möller wrote:
>> Hey there,
>> I'm trying to use a GtkScrolledWindow with the capability of scrolling,
>> but not displaying scroll bars
>
> GTK3 or GTK2? Called from C or Python?
>
> This may help:
>
> https://developer.gnome.org/gtk3/stable/GtkScrolledWindow.html#gtk-scrolled-window-set-policy
>
>
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: Hiding scrollbars for GtkScrolledWindow

2013-06-07 Thread Stefan Salewski
On Fri, 2013-06-07 at 19:05 +0200, Felix Möller wrote:
> Sorry for being unprecise.
> GTK3 in combination with C.
> 
> If I set the scrollbars' policy to never, the scrollbar is not
> displayed, but the window is not as small as it should be, but as big as
> its content. I want it to have the same size as with scrollbars, but
> without displaying them.
> 

Sorry, I can not really help you in this case.

Have you seen this old post

http://python.6.x6.nabble.com/Hide-scrollbar-td1941146.html

But it may be for GTK2 only.

Of course one can use scrolling without a GtkScrolledWindow  -- I have
used a GTK Drawing area long time ago
(http://www.ssalewski.de/PetEd-Demo.html.en) but of course that is not
what you want. If no one can answer you question here, you may ask at
gtk-l...@gnome.org.



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

Re: Hiding scrollbars for GtkScrolledWindow

2013-06-07 Thread Felix Möller
Yes that's the post I linked in my original question.
Sorry but your example is in Ruby.
Thanks though.

Any further help is appreciated.

On 06/07/13 19:46, Stefan Salewski wrote:
> On Fri, 2013-06-07 at 19:05 +0200, Felix Möller wrote:
>> Sorry for being unprecise.
>> GTK3 in combination with C.
>>
>> If I set the scrollbars' policy to never, the scrollbar is not
>> displayed, but the window is not as small as it should be, but as big as
>> its content. I want it to have the same size as with scrollbars, but
>> without displaying them.
>>
> 
> Sorry, I can not really help you in this case.
> 
> Have you seen this old post
> 
> http://python.6.x6.nabble.com/Hide-scrollbar-td1941146.html
> 
> But it may be for GTK2 only.
> 
> Of course one can use scrolling without a GtkScrolledWindow  -- I have
> used a GTK Drawing area long time ago
> (http://www.ssalewski.de/PetEd-Demo.html.en) but of course that is not
> what you want. If no one can answer you question here, you may ask at
> gtk-l...@gnome.org.
> 
> 
> 
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: Hiding scrollbars for GtkScrolledWindow

2013-06-09 Thread Stefan Salewski
On Fri, 2013-06-07 at 19:05 +0200, Felix Möller wrote:
> Sorry for being unprecise.
> GTK3 in combination with C.
> 
> If I set the scrollbars' policy to never, the scrollbar is not
> displayed, but the window is not as small as it should be, but as big as
> its content. I want it to have the same size as with scrollbars, but
> without displaying them.
> 

Have you got any helpful advice already?

I think that using a GtkScrolledWindow may be not a good choice if you
do not want the visible scrollbars -- a GtkViewport may be what you
want? But still I wonder why hiding the Scrollbars of a
GtkScrolledWindow is not possible. Of course there may exists good
reasons for that. Would be nice to know them. I have not found a C
example code for GTK3 GtkScrolledWindow, so I have not examined that
problem (Ruby bindings work not really well for GTK3 yet) -- maybe when
I have more time.

Best regards

Stefan Salewski


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