At first this sounds pretty abstract and that is true: theming facility is abstracted as much as possible.
Today, themed can be everything: widget look, behavior, sound events, icons and wallpapers, fonts and etc. Some toolkits and environments provides something so called metatheme, a theme that has a bunch of other, unrelated themes like themes for icons or GUI look. edelib theming implementation behaves (at some point) as metatheme too.
To allow this, edelib::Theme implements a Scheme-like language to load, parse and eventually transform theme code. Actually, edelib::Theme provides a full Scheme language (based on TinyScheme engine), but you will often see only the small parts of it.
Each styles in the same theme must have a unique name. In the case of duplicate names, first found style will be used.
To simplify the things, scheme is for FLTK as engines for GTK+. Schemes are implemented in C++ and uses FLTK low level drawing facility to paint widget elements.
Currently schemes can't be extended and theme loader uses a few of them already built in FLTK code.
;; this is a comment ; a comment too (theme.name "Sample Theme") (theme.author "John Foo <john@foo.com>") (theme.sample "img.jpg") (theme.style "ede" [ (scheme "gtk+") (background_color "#ffffff") (background_color2 "#043456") (foreground_color "#fff") (font_normal "-schumacher-*-medium-*-*-*-12-*-*-*-*-*-*-*") (icon_theme "edeneu") ])