Hi, c_c wrote: >Mirko Lindner wrote: >>The elm theme we install sets the text color in elm-entries to white rather >>than black. > > Ah! That explains it. Hmmm - Well, it looks like I'll have to see if I can >change over > my entry's (there's only 1) background to black. > But there must be a better way - we surely can't have changes applied > system-wide > based on the theme used for one App.
I think there is some infrastructure already there, working on the edje group level... Please check the Elementary wiki page: http://trac.enlightenment.org/e/wiki/Elementary Quoting the section about elementary envionment variables... > ELM_THEME - This sets the theme(s) to be used in order from most > preferential, to least, just with the theme name (minus the .edj extension) > with a : character delimiting the name. A simple personal theme would be > mytheme. If you wish to primarily use your personal theme, and then fall > back to another, you can do: mytheme:fallback. > This allows as many levels as you like. It is always assumed that the final > fallback theme is the default theme. A complex example would be: > mytheme:fallback:systemfallback:othersystem. Remember theme names > like "mytheme" mean it assumes a mytheme.edj is in $HOME/.elementary/themes > OR if not found here first, it is in $ELM_DATA_DIR/themes under the same > name. > Themes in your users theme dir always take precedence. A Theme name can > ALSO be a relative or full path to a file. In this case the fill filename > including extensions needs to be given. i.e. > /path/to/file.edj:mytheme:fallback: > ../../relative/path/file.edj:./dir/file.edj. With full or relative paths > searching in order > still happens. Note that there is a convenience shortcut for the users home > directory of ~/. So if a theme element is ~/dir/file.edj then ~/ is expanded > to > the the value of $HOME (the users home directory). The way I understand this is that for every edje groud that is needed to render a widget, elementary will check the *.edjes in the order they are listed in the ELM_THEME env variable. If a group is not found, it will check the next *.edj Digging deeper, there are two undocumented API calls in Elementary.h: EAPI void elm_theme_overlay_add(const char *item); EAPI void elm_theme_extension_add(const char *item); I think these allow the application to add their own themes app dependent *.edj, either _before_ ELM_THEME (that would be elm_theme_overlay_add() ) or _after_ ELM_THEME (that would be elm_theme_extension_add() ) The relevant code is at: http://trac.enlightenment.org/e/browser/trunk/TMP/st/elementary/src/lib/elm_theme.c?rev=#L50 I have not tested this, but the code looks as if it would be in working shape. Hope this is usefull nevertheless... Cheers, Thomas -- Excercise 17: If the human brain was simple enough for us to understand we'd be so simple we couldn't understand. Prove this by induction. _______________________________________________ Openmoko community mailing list community@lists.openmoko.org http://lists.openmoko.org/mailman/listinfo/community