aboutsummaryrefslogtreecommitdiff
path: root/src/Toolbar.cc
diff options
context:
space:
mode:
authorsimonb <simonb>2006-06-21 14:41:16 (GMT)
committersimonb <simonb>2006-06-21 14:41:16 (GMT)
commit3ada3b1f0d6d2debaaab48eecf828a406e964c8e (patch)
tree3c2f02462317408ee8604d0c7bb41092ecfd1c3a /src/Toolbar.cc
parent62a298b0b30aa5b4990f462aece224e09e4fafe6 (diff)
downloadfluxbox-3ada3b1f0d6d2debaaab48eecf828a406e964c8e.zip
fluxbox-3ada3b1f0d6d2debaaab48eecf828a406e964c8e.tar.bz2
fix nls... notably classify text on conversion whether its for X or
console, plus handle catalogs better.
Diffstat (limited to 'src/Toolbar.cc')
-rw-r--r--src/Toolbar.cc50
1 files changed, 25 insertions, 25 deletions
diff --git a/src/Toolbar.cc b/src/Toolbar.cc
index ba21af8..26b31c4 100644
--- a/src/Toolbar.cc
+++ b/src/Toolbar.cc
@@ -247,15 +247,15 @@ Toolbar::Toolbar(BScreen &scrn, FbTk::XLayer &layer, size_t width):
247 247
248 moveToLayer((*m_rc_layernum).getNum()); 248 moveToLayer((*m_rc_layernum).getNum());
249 249
250 m_layermenu.setLabel(_FBTEXT(Toolbar, Layer, "Toolbar Layer", "Title of toolbar layer menu")); 250 m_layermenu.setLabel(_FB_XTEXT(Toolbar, Layer, "Toolbar Layer", "Title of toolbar layer menu"));
251 m_placementmenu.setLabel(_FBTEXT(Toolbar, Placement, "Toolbar Placement", "Title of toolbar placement menu")); 251 m_placementmenu.setLabel(_FB_XTEXT(Toolbar, Placement, "Toolbar Placement", "Title of toolbar placement menu"));
252 252
253 m_layermenu.setInternalMenu(); 253 m_layermenu.setInternalMenu();
254 m_placementmenu.setInternalMenu(); 254 m_placementmenu.setInternalMenu();
255 m_toolbarmenu.setInternalMenu(); 255 m_toolbarmenu.setInternalMenu();
256 setupMenus(); 256 setupMenus();
257 // add menu to screen 257 // add menu to screen
258 screen().addConfigMenu(_FBTEXT(Toolbar, Toolbar, "Toolbar", "title of toolbar menu item"), menu()); 258 screen().addConfigMenu(_FB_XTEXT(Toolbar, Toolbar, "Toolbar", "title of toolbar menu item"), menu());
259 259
260 // geometry settings 260 // geometry settings
261 frame.width = width; 261 frame.width = width;
@@ -808,7 +808,7 @@ void Toolbar::setupMenus() {
808 typedef RefCount<Command> RefCommand; 808 typedef RefCount<Command> RefCommand;
809 typedef SimpleCommand<Toolbar> ToolbarCommand; 809 typedef SimpleCommand<Toolbar> ToolbarCommand;
810 810
811 menu().setLabel(_FBTEXT(Toolbar, Toolbar, 811 menu().setLabel(_FB_XTEXT(Toolbar, Toolbar,
812 "Toolbar", "Title of Toolbar menu")); 812 "Toolbar", "Title of Toolbar menu"));
813 813
814 RefCommand reconfig_toolbar(new ToolbarCommand(*this, &Toolbar::reconfigure)); 814 RefCommand reconfig_toolbar(new ToolbarCommand(*this, &Toolbar::reconfigure));
@@ -824,17 +824,17 @@ void Toolbar::setupMenus() {
824 visible_macro->add(reconfig_toolbar); 824 visible_macro->add(reconfig_toolbar);
825 visible_macro->add(save_resources); 825 visible_macro->add(save_resources);
826 RefCommand toggle_visible_cmd(visible_macro); 826 RefCommand toggle_visible_cmd(visible_macro);
827 menu().insert(new BoolMenuItem(_FBTEXT(Common, Visible, 827 menu().insert(new BoolMenuItem(_FB_XTEXT(Common, Visible,
828 "Visible", "Whether this item is visible"), 828 "Visible", "Whether this item is visible"),
829 *m_rc_visible, toggle_visible_cmd)); 829 *m_rc_visible, toggle_visible_cmd));
830 830
831 menu().insert(new BoolMenuItem(_FBTEXT(Common, AutoHide, 831 menu().insert(new BoolMenuItem(_FB_XTEXT(Common, AutoHide,
832 "Auto hide", "Toggle auto hide of toolbar"), 832 "Auto hide", "Toggle auto hide of toolbar"),
833 *m_rc_auto_hide, 833 *m_rc_auto_hide,
834 reconfig_toolbar_and_save_resource)); 834 reconfig_toolbar_and_save_resource));
835 835
836 MenuItem *toolbar_menuitem = 836 MenuItem *toolbar_menuitem =
837 new IntResMenuItem(_FBTEXT(Toolbar, WidthPercent, 837 new IntResMenuItem(_FB_XTEXT(Toolbar, WidthPercent,
838 "Toolbar width percent", 838 "Toolbar width percent",
839 "Percentage of screen width taken by toolbar"), 839 "Percentage of screen width taken by toolbar"),
840 m_rc_width_percent, 840 m_rc_width_percent,
@@ -844,21 +844,21 @@ void Toolbar::setupMenus() {
844 toolbar_menuitem->setCommand(reconfig_toolbar_and_save_resource); 844 toolbar_menuitem->setCommand(reconfig_toolbar_and_save_resource);
845 menu().insert(toolbar_menuitem); 845 menu().insert(toolbar_menuitem);
846 846
847 menu().insert(new BoolMenuItem(_FBTEXT(Common, MaximizeOver, 847 menu().insert(new BoolMenuItem(_FB_XTEXT(Common, MaximizeOver,
848 "Maximize Over", 848 "Maximize Over",
849 "Maximize over this thing when maximizing"), 849 "Maximize over this thing when maximizing"),
850 *m_rc_maximize_over, 850 *m_rc_maximize_over,
851 reconfig_toolbar_and_save_resource)); 851 reconfig_toolbar_and_save_resource));
852 menu().insert(_FBTEXT(Menu, Layer, "Layer...", "Title of Layer menu"), &layerMenu()); 852 menu().insert(_FB_XTEXT(Menu, Layer, "Layer...", "Title of Layer menu"), &layerMenu());
853#ifdef XINERAMA 853#ifdef XINERAMA
854 if (screen().hasXinerama()) { 854 if (screen().hasXinerama()) {
855 menu().insert(_FBTEXT(Menu, OnHead, "On Head...", "Title of On Head menu"), 855 menu().insert(_FB_XTEXT(Menu, OnHead, "On Head...", "Title of On Head menu"),
856 new XineramaHeadMenu<Toolbar>(screen().menuTheme(), 856 new XineramaHeadMenu<Toolbar>(screen().menuTheme(),
857 screen(), 857 screen(),
858 screen().imageControl(), 858 screen().imageControl(),
859 *screen().layerManager().getLayer(::Layer::MENU), 859 *screen().layerManager().getLayer(::Layer::MENU),
860 *this, 860 *this,
861 _FBTEXT(Toolbar, OnHead, "Toolbar on Head", 861 _FB_XTEXT(Toolbar, OnHead, "Toolbar on Head",
862 "Title of toolbar on head menu"))); 862 "Title of toolbar on head menu")));
863 } 863 }
864#endif // XINERAMA 864#endif // XINERAMA
@@ -868,21 +868,21 @@ void Toolbar::setupMenus() {
868 Placements place_menu; 868 Placements place_menu;
869 869
870 // menu is 3 wide, 5 down 870 // menu is 3 wide, 5 down
871 place_menu.push_back(PlacementP(_FBTEXT(Align, TopLeft, "Top Left", "Top Left"), Toolbar::TOPLEFT)); 871 place_menu.push_back(PlacementP(_FB_XTEXT(Align, TopLeft, "Top Left", "Top Left"), Toolbar::TOPLEFT));
872 place_menu.push_back(PlacementP(_FBTEXT(Align, LeftTop, "Left Top", "Left Top"), Toolbar::LEFTTOP)); 872 place_menu.push_back(PlacementP(_FB_XTEXT(Align, LeftTop, "Left Top", "Left Top"), Toolbar::LEFTTOP));
873 place_menu.push_back(PlacementP(_FBTEXT(Align, LeftCenter, "Left Center", "Left Center"), Toolbar::LEFTCENTER)); 873 place_menu.push_back(PlacementP(_FB_XTEXT(Align, LeftCenter, "Left Center", "Left Center"), Toolbar::LEFTCENTER));
874 place_menu.push_back(PlacementP(_FBTEXT(Align, LeftBottom, "Left Bottom", "Left Bottom"), Toolbar::LEFTBOTTOM)); 874 place_menu.push_back(PlacementP(_FB_XTEXT(Align, LeftBottom, "Left Bottom", "Left Bottom"), Toolbar::LEFTBOTTOM));
875 place_menu.push_back(PlacementP(_FBTEXT(Align, BottomLeft, "Bottom Left", "Bottom Left"), Toolbar::BOTTOMLEFT)); 875 place_menu.push_back(PlacementP(_FB_XTEXT(Align, BottomLeft, "Bottom Left", "Bottom Left"), Toolbar::BOTTOMLEFT));
876 place_menu.push_back(PlacementP(_FBTEXT(Align, TopCenter, "Top Center", "Top Center"), Toolbar::TOPCENTER)); 876 place_menu.push_back(PlacementP(_FB_XTEXT(Align, TopCenter, "Top Center", "Top Center"), Toolbar::TOPCENTER));
877 place_menu.push_back(PlacementP("", Toolbar::TOPLEFT)); 877 place_menu.push_back(PlacementP("", Toolbar::TOPLEFT));
878 place_menu.push_back(PlacementP("", Toolbar::TOPLEFT)); 878 place_menu.push_back(PlacementP("", Toolbar::TOPLEFT));
879 place_menu.push_back(PlacementP("", Toolbar::TOPLEFT)); 879 place_menu.push_back(PlacementP("", Toolbar::TOPLEFT));
880 place_menu.push_back(PlacementP(_FBTEXT(Align, BottomCenter, "Bottom Center", "Bottom Center"), Toolbar::BOTTOMCENTER)); 880 place_menu.push_back(PlacementP(_FB_XTEXT(Align, BottomCenter, "Bottom Center", "Bottom Center"), Toolbar::BOTTOMCENTER));
881 place_menu.push_back(PlacementP(_FBTEXT(Align, TopRight, "Top Right", "Top Right"), Toolbar::TOPRIGHT)); 881 place_menu.push_back(PlacementP(_FB_XTEXT(Align, TopRight, "Top Right", "Top Right"), Toolbar::TOPRIGHT));
882 place_menu.push_back(PlacementP(_FBTEXT(Align, RightTop, "Right Top", "Right Top"), Toolbar::RIGHTTOP)); 882 place_menu.push_back(PlacementP(_FB_XTEXT(Align, RightTop, "Right Top", "Right Top"), Toolbar::RIGHTTOP));
883 place_menu.push_back(PlacementP(_FBTEXT(Align, RightCenter, "Right Center", "Right Center"), Toolbar::RIGHTCENTER)); 883 place_menu.push_back(PlacementP(_FB_XTEXT(Align, RightCenter, "Right Center", "Right Center"), Toolbar::RIGHTCENTER));
884 place_menu.push_back(PlacementP(_FBTEXT(Align, RightBottom, "Right Bottom", "Right Bottom"), Toolbar::RIGHTBOTTOM)); 884 place_menu.push_back(PlacementP(_FB_XTEXT(Align, RightBottom, "Right Bottom", "Right Bottom"), Toolbar::RIGHTBOTTOM));
885 place_menu.push_back(PlacementP(_FBTEXT(Align, BottomRight, "Bottom Right", "Bottom Right"), Toolbar::BOTTOMRIGHT)); 885 place_menu.push_back(PlacementP(_FB_XTEXT(Align, BottomRight, "Bottom Right", "Bottom Right"), Toolbar::BOTTOMRIGHT));
886 886
887 887
888 placementMenu().setMinimumSublevels(3); 888 placementMenu().setMinimumSublevels(3);
@@ -901,13 +901,13 @@ void Toolbar::setupMenus() {
901 } 901 }
902 place_menu.pop_front(); 902 place_menu.pop_front();
903 } 903 }
904 menu().insert(_FBTEXT(Menu, Placement, "Placement", "Title of Placement menu"), &placementMenu()); 904 menu().insert(_FB_XTEXT(Menu, Placement, "Placement", "Title of Placement menu"), &placementMenu());
905 placementMenu().updateMenu(); 905 placementMenu().updateMenu();
906 906
907 907
908 // this saves resources and clears the slit window to update alpha value 908 // this saves resources and clears the slit window to update alpha value
909 FbTk::MenuItem *alpha_menuitem = 909 FbTk::MenuItem *alpha_menuitem =
910 new IntResMenuItem(_FBTEXT(Common, Alpha, "Alpha", "Transparency level"), 910 new IntResMenuItem(_FB_XTEXT(Common, Alpha, "Alpha", "Transparency level"),
911 m_rc_alpha, 911 m_rc_alpha,
912 0, 255, menu()); 912 0, 255, menu());
913 // setup command for alpha value 913 // setup command for alpha value