news download themes documentation links










ButtonTheme.cc

00001 #include "ButtonTheme.hh"
00002 #include "FbTk/App.hh"
00003 
00005 ButtonTheme::ButtonTheme(int screen_num, 
00006                          const std::string &name, 
00007                          const std::string &alt_name):
00008     ToolTheme(screen_num, name, alt_name),
00009     m_pic_color(*this, name + ".picColor", alt_name + ".PicColor"),
00010     m_pressed_texture(*this, name + ".pressed", alt_name + ".Pressed"),
00011     m_gc(RootWindow(FbTk::App::instance()->display(), screen_num)) {
00012 
00013 }
00014 
00015 bool ButtonTheme::fallback(FbTk::ThemeItem_base &item) {
00016 
00017     if (item.name().find(".borderWidth") != std::string::npos) {
00018         return FbTk::ThemeManager::instance().loadItem(item, "borderWidth", "BorderWidth");
00019     }
00020 
00021     if (item.name().find(".borderColor") != std::string::npos) {
00022         return FbTk::ThemeManager::instance().loadItem(item, "borderColor", "BorderColor");
00023     }
00024 
00025     return ToolTheme::fallback(item);
00026 }
00027 
00028 void ButtonTheme::reconfigTheme() {
00029     m_gc.setForeground(*m_pic_color);
00030 }
00031 
00032 
00033 

Fluxbox CVS-Jan-2003




      



Got comments about the page? Send them to webmaster.
If you have general Fluxbox related questions ask them on our irc channel or mailing lists.

Show Source








Designed by aLEczapKA