On Thu, 27 Nov 2008 23:46:02 +0100, Colomban Wendling ban-ubuntu@club-internet.fr wrote:
Colomban Wendling a écrit :
Hi all,
I worked a little with close tab buttons, and I've made a little widget (based on gnome-terminal's code) and a demo.
The default behaviour is the same as gnome-terminal. A try could be to remove the +2 at line 112 of geanyclosetabbutton.c to reduce tab height and get back some tab's top decorations with some themes. In the other hand, then border of the icon could cross the button's border. Next thing is to try this under Windows. If any of you could easily compile and test it under Windows, do it, please.
Any comment? If you think it is a good solution, I can try to make a patch to use it or a derivate in Geany.
Regards, Colomban
I've tried my demo under Windows (XP), and it works well, no cropping with both default and Windows GTK+ themes. But if I remove the +2's the images are cropped (but lesser than with 0.15). Finally, the tabs are 2 pixel taller than 0.15 ones with +2's and had the same height than 0.15 without.
I think it is a reasonable compromise between tab height and portability.
Yes. For me this is fine. I just committed some changes based on your code. Tested Linux with GTK 2.14 with the Human theme (this one which is included in Debian) and with my own theme based on some Clearlooks theme. Also tested on Windows 2000 with GTK 2.14 and the Windows theme, bundled with GTK. And everything looks fine now. I hope it will also work for Nick and others.
(I made the changes in src/notebook.c, I think there is no need (yet) to subclass GtkButton.)
Regards, Enrico