Re: Custom Titlebar

2014-08-12 Thread Mahan Marwat
I am using GTK+ 3 on Window XP (SP2).
So, when I call gtk_window_set_titlebar it raises an exception that no
gtk_window_set_titlebar function found.

I know there is one another way to add a custom title-bar to my
application. i.e
Set the decorating to false by calling: set_decorated(False) and add my own
widget on top of my application.
But then the problem is that, I can't add the dragging functionality to my
widget. So, that I drag my application on window screen.
There is also one function for this functionality begin_move_drag(*button*,
*root_x*, *root_y*, *timestamp*) But I don't know, how to use it.


On Tue, Aug 12, 2014 at 12:48 AM, Emmanuele Bassi eba...@gmail.com wrote:

 On 11 August 2014 22:50, Michael Cronenworth m...@cchtml.com wrote:
  On 08/11/2014 04:40 PM, David Nečas wrote:
 
  Unless you are running someting like Gnome 3(?), this will add a
  strangely looking thing to the top of your window, but inside.  It will
  not change the title bar which is controlled by the window manager.

 only if your window manager is actually broken, and does not support
 Motif hints like it should.

  That's why I did not recommend this to the OP.
 
  Is that call even supported on win32?

 yes, and it actually works better than on sub-par window managers for
 Linux.

 http://blogs.gnome.org/nacho/files/2014/07/gedit-windows2.jpeg

 ciao,
  Emmanuele.

 --
 http://www.bassi.io
 [@] ebassi [@gmail.com]
 ___
 gtk-app-devel-list mailing list
 gtk-app-devel-list@gnome.org
 https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

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

Re: Custom Titlebar

2014-08-12 Thread Victor Aurélio Santos
Do you have at least the 3.10 version ?

2014-08-12 3:50 GMT-03:00 Mahan Marwat mahanmar...@gmail.com:
 I am using GTK+ 3 on Window XP (SP2).
 So, when I call gtk_window_set_titlebar it raises an exception that no
 gtk_window_set_titlebar function found.

 I know there is one another way to add a custom title-bar to my
 application. i.e
 Set the decorating to false by calling: set_decorated(False) and add my own
 widget on top of my application.
 But then the problem is that, I can't add the dragging functionality to my
 widget. So, that I drag my application on window screen.
 There is also one function for this functionality begin_move_drag(*button*,
 *root_x*, *root_y*, *timestamp*) But I don't know, how to use it.


 On Tue, Aug 12, 2014 at 12:48 AM, Emmanuele Bassi eba...@gmail.com wrote:

 On 11 August 2014 22:50, Michael Cronenworth m...@cchtml.com wrote:
  On 08/11/2014 04:40 PM, David Nečas wrote:
 
  Unless you are running someting like Gnome 3(?), this will add a
  strangely looking thing to the top of your window, but inside.  It will
  not change the title bar which is controlled by the window manager.

 only if your window manager is actually broken, and does not support
 Motif hints like it should.

  That's why I did not recommend this to the OP.
 
  Is that call even supported on win32?

 yes, and it actually works better than on sub-par window managers for
 Linux.

 http://blogs.gnome.org/nacho/files/2014/07/gedit-windows2.jpeg

 ciao,
  Emmanuele.

 --
 http://www.bassi.io
 [@] ebassi [@gmail.com]
 ___
 gtk-app-devel-list mailing list
 gtk-app-devel-list@gnome.org
 https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

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



-- 
Victor Aurélio Santos
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: Custom Titlebar

2014-08-11 Thread Michael Cronenworth

On 08/09/2014 04:25 PM, Mahan Marwat wrote:

How can I add a custom titlebar to my GUI application?


Are you asking for custom text or a complete replacement with widgets of your 
own?

If the former then it's a simple call. I'll use the C function:

gtk_window_set_title( GTK_WINDOW( window ), Hello this is new title bar text 
);

If the later, GTK does not support that.

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


Re: Custom Titlebar

2014-08-11 Thread Florian Müllner
On Sun, Aug 10, 2014 at 7:31 PM, Michael Cronenworth m...@cchtml.com wrote:
 On 08/09/2014 04:25 PM, Mahan Marwat wrote:

 How can I add a custom titlebar to my GUI application?


 Are you asking for custom text or a complete replacement with widgets of
 your own?

 [...]

 If the later, GTK does not support that.


That is not quite true - since GTK 3.10, there's

  gtk_window_set_titlebar (GTK_WINDOW (window), titlebar_widget);
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Custom Titlebar

2014-08-11 Thread David Nečas
On Mon, Aug 11, 2014 at 11:28:34PM +0200, Florian Müllner wrote:
 That is not quite true - since GTK 3.10, there's
 
   gtk_window_set_titlebar (GTK_WINDOW (window), titlebar_widget);

Unless you are running someting like Gnome 3(?), this will add a
strangely looking thing to the top of your window, but inside.  It will
not change the title bar which is controlled by the window manager.

I've never seen it actually do what is advertised.  Admittely, I didn't
test it much because I consider it broken by intent (not even getting to
broken by design).

Yeti

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

Re: Custom Titlebar

2014-08-11 Thread Michael Cronenworth

On 08/11/2014 04:40 PM, David Nečas wrote:

Unless you are running someting like Gnome 3(?), this will add a
strangely looking thing to the top of your window, but inside.  It will
not change the title bar which is controlled by the window manager.

I've never seen it actually do what is advertised.  Admittely, I didn't
test it much because I consider it broken by intent (not even getting to
broken by design).


That's why I did not recommend this to the OP.

Is that call even supported on win32?
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Re: Custom Titlebar

2014-08-11 Thread Emmanuele Bassi
On 11 August 2014 22:50, Michael Cronenworth m...@cchtml.com wrote:
 On 08/11/2014 04:40 PM, David Nečas wrote:

 Unless you are running someting like Gnome 3(?), this will add a
 strangely looking thing to the top of your window, but inside.  It will
 not change the title bar which is controlled by the window manager.

only if your window manager is actually broken, and does not support
Motif hints like it should.

 That's why I did not recommend this to the OP.

 Is that call even supported on win32?

yes, and it actually works better than on sub-par window managers for Linux.

http://blogs.gnome.org/nacho/files/2014/07/gedit-windows2.jpeg

ciao,
 Emmanuele.

-- 
http://www.bassi.io
[@] ebassi [@gmail.com]
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Custom Titlebar

2014-08-09 Thread Mahan Marwat
How can I add a custom titlebar to my GUI application?
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list