[Gtk-sharp-list] Background color of Notebook page

Andy York andy at brdstudio.net
Thu Oct 20 20:33:42 EDT 2011


With Gtk# being a mostly *nix platform they don't put a lot of friendly 
GUI access, it is considered by some to be in bad taste for an 
application to override the users selected theme. I disagree with this 
but nobody asked me hehe.

Notebook pages can be almost any container widget, I would suggest a 
"roll your own" method and add the pages at run time. Start with a 
Gtk.Fixed control and add you background image to that. After that you 
can put the remaining controls anywhere you want. If you want to use the 
gui designer in Monodevelop you could create a custom widget, put all 
your controls you need in it and add it to the Gtk.Fixed at run time. 
Its not 100% drag-n-drop development but it is not to far from it.

You could all this in the Monodevelop gui 100% but I have had issues in 
the past with the order the widgets are rendered. Which could be 
something I'm doing wrong but I find it easier to just "roll my own".

I hope this helps, if you need more clarification I'll try to work up a 
quick and dirty example to help.

Spoody

On 10/20/2011 3:06 PM, TheSHEEEP wrote:
> Hey,
>
> How can you change teh background color of a container that is a page in a
> notebook?
>
> Normally, the background color is that usual light grey - which is fine.
> But inside a notebook page, all background color suddenly changes to white,
> which IMHO looks pretty awkward, especially considering that some elements
> (a table, for example) remains light grey.
>
> How can you change that BG color?
>
> ModifyBase and ModifyBG on any of the elements and their containers do not
> seem to have any impact.
> Do you have to call something after you call the Modify*-functions?
> Do you have to call them on the container AND all the containing elements at
> once?
> Or can this be solved completely different?
>
>
> --
> View this message in context: http://mono.1490590.n4.nabble.com/Background-color-of-Notebook-page-tp3923129p3923129.html
> Sent from the Mono - Gtk# mailing list archive at Nabble.com.
> _______________________________________________
> Gtk-sharp-list maillist  -  Gtk-sharp-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
>
>
> -----
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 2012.0.1831 / Virus Database: 2092/4563 - Release Date: 10/20/11
>
>





More information about the Gtk-sharp-list mailing list