GTK+ Forums

Discussion forum for GTK+ and Programming. Ask questions, troubleshoot problems, view and post example code, or express your opinions.
It is currently Fri Oct 31, 2014 12:52 pm

All times are UTC




Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: Is there a way to make GTK Notebook look nicer?
PostPosted: Mon Oct 31, 2011 3:59 pm 
Offline
Familiar Face

Joined: Thu Aug 18, 2011 8:26 am
Posts: 16
Ok, I know I can use themes to make things look different, but I don't want to change my users environment, can I build my application in a way that the tabs will look different in my application, without changing their other applications?

This is probably a noob question, but my research online has gotten me so confused on the topic, that I feel I have no choice but to ask.

Thanks in advance.


Top
 Profile  
 
 Post subject: Re: Is there a way to make GTK Notebook look nicer?
PostPosted: Mon Oct 31, 2011 7:43 pm 
Offline
Familiar Face

Joined: Fri Jul 01, 2011 6:40 pm
Posts: 48
Location: Croatia
This can be a huge and general problem.
How to make nicer something what is nice enough?


Top
 Profile  
 
 Post subject: Re: Is there a way to make GTK Notebook look nicer?
PostPosted: Tue Nov 01, 2011 9:18 am 
Offline
Familiar Face

Joined: Thu Aug 18, 2011 8:26 am
Posts: 16
So, is there a way to make only my application use a theme, and not upset the user's environment?


Top
 Profile  
 
 Post subject: Re: Is there a way to make GTK Notebook look nicer?
PostPosted: Wed Nov 02, 2011 11:46 pm 
Offline
Never Seen the Sunlight

Joined: Thu Mar 24, 2011 2:10 pm
Posts: 328
Location: Sydney, Australia
Yes gtk3 can implement css for styling http://developer.gnome.org/gtk3/3.0/GtkCssProvider.html. As this is cascading there is a hierarchy where the more specialised instances (e.g. css provided in your code for just your program) have precedence over the more general (e.g. those defined by your OS's themes).
Note however that even though you won't break the style of your OS by using gtkcssprovider, it will mean that your program's appearance is not consistent with the rest of the desktop environment. Probably not that big a deal as the rest of the desktop environment isn't necessarily self consistent anyway. One thing to watch out for is to try and not change style issues that tend to vary between platforms and OS's. e.g. netbooks and desktops ideally should have differently styled environments and if you set any of these particular style then you lose the ability for this to automatically vary for your program on the environment level.


Top
 Profile  
 
 Post subject: Re: Is there a way to make GTK Notebook look nicer?
PostPosted: Thu Nov 03, 2011 11:01 am 
Offline
Familiar Face

Joined: Thu Aug 18, 2011 8:26 am
Posts: 16
Thanks, I will look at this after work tonight, its not like I wan't to vastly change the look, I want the tabs to be smaller, more like firefox's etc, you know, more sleek, because GTK is very bulky by default appearance.

Thanks again

-Leam


Top
 Profile  
 
 Post subject: Re: Is there a way to make GTK Notebook look nicer?
PostPosted: Fri Dec 16, 2011 9:18 pm 
Offline
GTK+ Guru

Joined: Fri Mar 25, 2011 5:16 pm
Posts: 177
Location: USA
I just posted an example of styling a GtkNotebook with Gtk3 and CSS. It's in the forum Section: "Gtk+ Tutorials & Resources"


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group