aboutsummaryrefslogtreecommitdiff
path: root/src/Screen.cc
diff options
context:
space:
mode:
authormathias <mathias>2005-06-03 07:25:48 (GMT)
committermathias <mathias>2005-06-03 07:25:48 (GMT)
commitef76b45ab1857af1b12f0c336bfb8c0f19140aeb (patch)
treee380d87f9e4c5e1b27f7aeb8d3aa8acbe0e09d2c /src/Screen.cc
parent9c27e2e7993c9ccd604f77219a1f07c1be22e75a (diff)
downloadfluxbox-ef76b45ab1857af1b12f0c336bfb8c0f19140aeb.zip
fluxbox-ef76b45ab1857af1b12f0c336bfb8c0f19140aeb.tar.bz2
- Usage of xft-fonts is prefered, except a font-description starts with '-'
- Removed "antialias"-option completly, to enable/disable "antialias" use either <fontname>:antialias=<bool> in the style or use Xft.antialias: <bool> in your .Xdefaults - Added new styleresources: *.font.effect: <halo|shadow> *.font.shadow.x : <int> - shadow x offset *.font.shadow.y : <int> - shadow y offset *.font.shadow.color : <color> - color of shadow *.font.halo.color : <color> - color of halo - Removed 'shadow' and 'halo' options from fontdefinitions: !! Style authors have to update their styles !! - Simplified XmbFontImp to not try all possible fonts to match locale - Style authors may specify multiple fonts: <font1>|<font2>|<font3> if loading of font1 fails, fluxbox probes <font2>, etc. The last font is "fixed". Hints for style authors: - if xft tries to load a font it will _ALWAYS_ return a valid font, it doesnt have to look like the one you want to have, read more about it: http://fontconfig.org/fontconfig-user.html - export XFT_DEBUG=1 before running fluxbox helps to see which fonts are picked. eg: *.font: Verdana,Arial-12:antialias=true|-artwiz-snap-*- if fluxbox is compiled with xft this will NEVER try to load "-artwiz-snap-*-" since xft gives for sure a font, most likely Verdana or Arial but noone knows. So, if fluxbox has no xft support the first fontpattern fails and fluxbox tries the next one, which might be successful. if everything fails, it will use "fixed" - Added caching of fonts, fonts are only loaded once. - Fixed #1090902 (slow utf8 start)
Diffstat (limited to 'src/Screen.cc')
-rw-r--r--src/Screen.cc29
1 files changed, 2 insertions, 27 deletions
diff --git a/src/Screen.cc b/src/Screen.cc
index 7996587..8de0345 100644
--- a/src/Screen.cc
+++ b/src/Screen.cc
@@ -310,14 +310,6 @@ BScreen::BScreen(FbTk::ResourceManager &rm,
310 310
311 imageControl().setDither(*resource.image_dither); 311 imageControl().setDither(*resource.image_dither);
312 312
313 // setup windowtheme for antialias
314 // before we load the theme
315
316 winFrameTheme().font().setAntialias(*resource.antialias);
317 menuTheme().titleFont().setAntialias(*resource.antialias);
318 menuTheme().frameFont().setAntialias(*resource.antialias);
319
320
321 winFrameTheme().reconfigSig().attach(this);// for geom window 313 winFrameTheme().reconfigSig().attach(this);// for geom window
322 314
323 315
@@ -343,7 +335,8 @@ BScreen::BScreen(FbTk::ResourceManager &rm,
343 // own resources we must do this. 335 // own resources we must do this.
344 fluxbox->load_rc(*this); 336 fluxbox->load_rc(*this);
345 337
346 m_configmenu.reset(createMenu(_FBTEXT(Menu, Configuration, "Configuration", "Title of configuration menu"))); 338 m_configmenu.reset(createMenu(_FBTEXT(Menu, Configuration,
339 "Configuration", "Title of configuration menu")));
347 setupConfigmenu(*m_configmenu.get()); 340 setupConfigmenu(*m_configmenu.get());
348 m_configmenu->setInternalMenu(); 341 m_configmenu->setInternalMenu();
349 342
@@ -673,11 +666,6 @@ void BScreen::reconfigure() {
673 m_menutheme->setDelayOpen(*resource.menu_delay); 666 m_menutheme->setDelayOpen(*resource.menu_delay);
674 m_menutheme->setDelayClose(*resource.menu_delay_close); 667 m_menutheme->setDelayClose(*resource.menu_delay_close);
675 668
676 // setup windowtheme, toolbartheme for antialias
677 winFrameTheme().font().setAntialias(*resource.antialias);
678 m_menutheme->titleFont().setAntialias(*resource.antialias);
679 m_menutheme->frameFont().setAntialias(*resource.antialias);
680
681 renderGeomWindow(); 669 renderGeomWindow();
682 renderPosWindow(); 670 renderPosWindow();
683 671
@@ -849,13 +837,6 @@ void BScreen::removeClient(WinClient &client) {
849 837
850} 838}
851 839
852void BScreen::setAntialias(bool value) {
853 if (*resource.antialias == value)
854 return;
855 resource.antialias = value;
856 reconfigure();
857}
858
859int BScreen::addWorkspace() { 840int BScreen::addWorkspace() {
860 841
861 bool save_name = getNameOfWorkspace(m_workspaces_list.size()) != "" ? false : true; 842 bool save_name = getNameOfWorkspace(m_workspaces_list.size()) != "" ? false : true;
@@ -1812,12 +1793,6 @@ void BScreen::setupConfigmenu(FbTk::Menu &menu) {
1812 _BOOLITEM(Configmenu, ClickRaises, 1793 _BOOLITEM(Configmenu, ClickRaises,
1813 "Click Raises", "Click Raises", 1794 "Click Raises", "Click Raises",
1814 *resource.click_raises, saverc_cmd); 1795 *resource.click_raises, saverc_cmd);
1815#ifdef USE_XFT
1816 // setup antialias cmd to reload style and save resource on toggle
1817 _BOOLITEM(Configmenu, AntiAlias,
1818 "AntiAlias", "Use Anti-aliased fonts",
1819 *resource.antialias, save_and_reconfigure);
1820#endif // USE_XFT
1821 1796
1822#ifdef HAVE_XRENDER 1797#ifdef HAVE_XRENDER
1823 if (FbTk::Transparent::haveRender() || 1798 if (FbTk::Transparent::haveRender() ||