aboutsummaryrefslogtreecommitdiff
path: root/src/Slit.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/Slit.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/Slit.cc')
-rw-r--r--src/Slit.cc54
1 files changed, 27 insertions, 27 deletions
diff --git a/src/Slit.cc b/src/Slit.cc
index 9e69ce2..c676f30 100644
--- a/src/Slit.cc
+++ b/src/Slit.cc
@@ -219,8 +219,8 @@ public:
219 std::string reallabel = m_label + " " + 219 std::string reallabel = m_label + " " +
220 ( m_slit.direction() == Slit::HORIZONTAL ? 220 ( m_slit.direction() == Slit::HORIZONTAL ?
221 221
222 _FBTEXT(Align, Horizontal, "Horizontal", "Horizontal"): 222 _FB_XTEXT(Align, Horizontal, "Horizontal", "Horizontal"):
223 _FBTEXT(Align, Vertical, "Vertical", "Vertical")); 223 _FB_XTEXT(Align, Vertical, "Vertical", "Vertical"));
224 FbTk::MenuItem::setLabel(reallabel); 224 FbTk::MenuItem::setLabel(reallabel);
225 } 225 }
226private: 226private:
@@ -294,7 +294,7 @@ Slit::Slit(BScreen &scr, FbTk::XLayer &layer, const char *filename)
294 scr.resizeSig().attach(this); 294 scr.resizeSig().attach(this);
295 scr.reconfigureSig().attach(this); // if alpha changed (we disablethis signal when we get theme change sig) 295 scr.reconfigureSig().attach(this); // if alpha changed (we disablethis signal when we get theme change sig)
296 296
297 scr.addConfigMenu(_FBTEXT(Slit, Slit, "Slit", "The Slit"), m_slitmenu); 297 scr.addConfigMenu(_FB_XTEXT(Slit, Slit, "Slit", "The Slit"), m_slitmenu);
298 298
299 frame.pixmap = None; 299 frame.pixmap = None;
300 // move the frame out of sight for a moment 300 // move the frame out of sight for a moment
@@ -322,7 +322,7 @@ Slit::Slit(BScreen &scr, FbTk::XLayer &layer, const char *filename)
322 getLayer(Layer::MENU), 322 getLayer(Layer::MENU),
323 this, 323 this,
324 true)); 324 true));
325 m_layermenu->setLabel(_FBTEXT(Slit, Layer, "Slit Layer", "Title of Slit Layer Menu")); 325 m_layermenu->setLabel(_FB_XTEXT(Slit, Layer, "Slit Layer", "Title of Slit Layer Menu"));
326 326
327 moveToLayer((*m_rc_layernum).getNum()); 327 moveToLayer((*m_rc_layernum).getNum());
328 328
@@ -1162,12 +1162,12 @@ void Slit::updateClientmenu() {
1162 1162
1163 // clear old items 1163 // clear old items
1164 m_clientlist_menu.removeAll(); 1164 m_clientlist_menu.removeAll();
1165 m_clientlist_menu.setLabel(_FBTEXT(Slit, ClientsMenu, "Clients", "Slit client menu")); 1165 m_clientlist_menu.setLabel(_FB_XTEXT(Slit, ClientsMenu, "Clients", "Slit client menu"));
1166 1166
1167 FbTk::RefCount<FbTk::Command> cycle_up(new FbTk::SimpleCommand<Slit>(*this, &Slit::cycleClientsUp)); 1167 FbTk::RefCount<FbTk::Command> cycle_up(new FbTk::SimpleCommand<Slit>(*this, &Slit::cycleClientsUp));
1168 FbTk::RefCount<FbTk::Command> cycle_down(new FbTk::SimpleCommand<Slit>(*this, &Slit::cycleClientsDown)); 1168 FbTk::RefCount<FbTk::Command> cycle_down(new FbTk::SimpleCommand<Slit>(*this, &Slit::cycleClientsDown));
1169 m_clientlist_menu.insert(_FBTEXT(Slit, CycleUp, "Cycle Up", "Cycle clients upwards"), cycle_up); 1169 m_clientlist_menu.insert(_FB_XTEXT(Slit, CycleUp, "Cycle Up", "Cycle clients upwards"), cycle_up);
1170 m_clientlist_menu.insert(_FBTEXT(Slit, CycleDown, "Cycle Down", "Cycle clients downwards"), cycle_down); 1170 m_clientlist_menu.insert(_FB_XTEXT(Slit, CycleDown, "Cycle Down", "Cycle clients downwards"), cycle_down);
1171 1171
1172 m_clientlist_menu.insert(new FbTk::MenuSeparator()); 1172 m_clientlist_menu.insert(new FbTk::MenuSeparator());
1173 1173
@@ -1180,7 +1180,7 @@ void Slit::updateClientmenu() {
1180 1180
1181 m_clientlist_menu.insert(new FbTk::MenuSeparator()); 1181 m_clientlist_menu.insert(new FbTk::MenuSeparator());
1182 FbTk::RefCount<FbTk::Command> savecmd(new FbTk::SimpleCommand<Slit>(*this, &Slit::saveClientList)); 1182 FbTk::RefCount<FbTk::Command> savecmd(new FbTk::SimpleCommand<Slit>(*this, &Slit::saveClientList));
1183 m_clientlist_menu.insert(_FBTEXT(Slit, 1183 m_clientlist_menu.insert(_FB_XTEXT(Slit,
1184 SaveSlitList, 1184 SaveSlitList,
1185 "Save SlitList", "Saves the current order in the slit"), 1185 "Save SlitList", "Saves the current order in the slit"),
1186 savecmd); 1186 savecmd);
@@ -1242,37 +1242,37 @@ void Slit::setupMenu() {
1242 1242
1243 1243
1244 // setup base menu 1244 // setup base menu
1245 m_slitmenu.setLabel(_FBTEXT(Slit, Slit, "Slit", "The Slit")); 1245 m_slitmenu.setLabel(_FB_XTEXT(Slit, Slit, "Slit", "The Slit"));
1246 m_slitmenu.insert(_FBTEXT(Menu, Placement, "Placement", "Title of Placement menu"), 1246 m_slitmenu.insert(_FB_XTEXT(Menu, Placement, "Placement", "Title of Placement menu"),
1247 placement_menu); 1247 placement_menu);
1248 1248
1249 m_slitmenu.insert(_FBTEXT(Menu, Layer, "Layer...", "Title of Layer menu"), m_layermenu.get()); 1249 m_slitmenu.insert(_FB_XTEXT(Menu, Layer, "Layer...", "Title of Layer menu"), m_layermenu.get());
1250 1250
1251#ifdef XINERAMA 1251#ifdef XINERAMA
1252 if (screen().hasXinerama()) { 1252 if (screen().hasXinerama()) {
1253 m_slitmenu.insert(_FBTEXT(Menu, OnHead, "On Head...", "Title of On Head menu"), 1253 m_slitmenu.insert(_FB_XTEXT(Menu, OnHead, "On Head...", "Title of On Head menu"),
1254 new XineramaHeadMenu<Slit>( 1254 new XineramaHeadMenu<Slit>(
1255 screen().menuTheme(), 1255 screen().menuTheme(),
1256 screen(), 1256 screen(),
1257 screen().imageControl(), 1257 screen().imageControl(),
1258 *screen().layerManager().getLayer(::Layer::MENU), 1258 *screen().layerManager().getLayer(::Layer::MENU),
1259 *this, 1259 *this,
1260 _FBTEXT(Slit, OnHead, "Slit on Head", "Title of Slits On Head menu") 1260 _FB_XTEXT(Slit, OnHead, "Slit on Head", "Title of Slits On Head menu")
1261 )); 1261 ));
1262 } 1262 }
1263#endif //XINERAMA 1263#endif //XINERAMA
1264 1264
1265 m_slitmenu.insert(new BoolMenuItem(_FBTEXT(Common, AutoHide, "Auto hide", "This thing automatically hides when not close by"), 1265 m_slitmenu.insert(new BoolMenuItem(_FB_XTEXT(Common, AutoHide, "Auto hide", "This thing automatically hides when not close by"),
1266 *m_rc_auto_hide, 1266 *m_rc_auto_hide,
1267 save_and_reconfigure_slit)); 1267 save_and_reconfigure_slit));
1268 1268
1269 m_slitmenu.insert(new BoolMenuItem(_FBTEXT(Common, MaximizeOver,"Maximize Over", "Maximize over this thing when maximizing"), 1269 m_slitmenu.insert(new BoolMenuItem(_FB_XTEXT(Common, MaximizeOver,"Maximize Over", "Maximize over this thing when maximizing"),
1270 *m_rc_maximize_over, 1270 *m_rc_maximize_over,
1271 save_and_reconfigure_slit)); 1271 save_and_reconfigure_slit));
1272 1272
1273 // this saves resources and clears the slit window to update alpha value 1273 // this saves resources and clears the slit window to update alpha value
1274 FbTk::MenuItem *alpha_menuitem = 1274 FbTk::MenuItem *alpha_menuitem =
1275 new IntResMenuItem(_FBTEXT(Common, Alpha, "Alpha", "Transparency level"), 1275 new IntResMenuItem(_FB_XTEXT(Common, Alpha, "Alpha", "Transparency level"),
1276 m_rc_alpha, 1276 m_rc_alpha,
1277 0, 255, m_slitmenu); 1277 0, 255, m_slitmenu);
1278 // setup command for alpha value 1278 // setup command for alpha value
@@ -1285,14 +1285,14 @@ void Slit::setupMenu() {
1285 1285
1286 m_slitmenu.insert(alpha_menuitem); 1286 m_slitmenu.insert(alpha_menuitem);
1287 1287
1288 m_slitmenu.insert(new SlitDirMenuItem(_FBTEXT(Slit, Direction, "Slit Direction", "Orientation of slit"), 1288 m_slitmenu.insert(new SlitDirMenuItem(_FB_XTEXT(Slit, Direction, "Slit Direction", "Orientation of slit"),
1289 *this, 1289 *this,
1290 save_and_reconfigure)); 1290 save_and_reconfigure));
1291 m_slitmenu.insert(_FBTEXT(Slit, ClientsMenu, "Clients", "Slit client menu"), &m_clientlist_menu); 1291 m_slitmenu.insert(_FB_XTEXT(Slit, ClientsMenu, "Clients", "Slit client menu"), &m_clientlist_menu);
1292 m_slitmenu.updateMenu(); 1292 m_slitmenu.updateMenu();
1293 1293
1294 // setup sub menu 1294 // setup sub menu
1295 placement_menu->setLabel(_FBTEXT(Slit, Placement, "Slit Placement", "Slit Placement")); 1295 placement_menu->setLabel(_FB_XTEXT(Slit, Placement, "Slit Placement", "Slit Placement"));
1296 placement_menu->setMinimumSublevels(3); 1296 placement_menu->setMinimumSublevels(3);
1297 m_layermenu->setInternalMenu(); 1297 m_layermenu->setInternalMenu();
1298 m_clientlist_menu.setInternalMenu(); 1298 m_clientlist_menu.setInternalMenu();
@@ -1303,15 +1303,15 @@ void Slit::setupMenu() {
1303 Placements place_menu; 1303 Placements place_menu;
1304 1304
1305 // menu is 3 wide, 5 down 1305 // menu is 3 wide, 5 down
1306 place_menu.push_back(PlacementP(_FBTEXT(Align, TopLeft, "Top Left", "Top Left"), Slit::TOPLEFT)); 1306 place_menu.push_back(PlacementP(_FB_XTEXT(Align, TopLeft, "Top Left", "Top Left"), Slit::TOPLEFT));
1307 place_menu.push_back(PlacementP(_FBTEXT(Align, LeftCenter, "Left Center", "Left Center"), Slit::LEFTCENTER)); 1307 place_menu.push_back(PlacementP(_FB_XTEXT(Align, LeftCenter, "Left Center", "Left Center"), Slit::LEFTCENTER));
1308 place_menu.push_back(PlacementP(_FBTEXT(Align, BottomLeft, "Bottom Left", "Bottom Left"), Slit::BOTTOMLEFT)); 1308 place_menu.push_back(PlacementP(_FB_XTEXT(Align, BottomLeft, "Bottom Left", "Bottom Left"), Slit::BOTTOMLEFT));
1309 place_menu.push_back(PlacementP(_FBTEXT(Align, TopCenter, "Top Center", "Top Center"), Slit::TOPCENTER)); 1309 place_menu.push_back(PlacementP(_FB_XTEXT(Align, TopCenter, "Top Center", "Top Center"), Slit::TOPCENTER));
1310 place_menu.push_back(PlacementP("", Slit::TOPLEFT)); 1310 place_menu.push_back(PlacementP("", Slit::TOPLEFT));
1311 place_menu.push_back(PlacementP(_FBTEXT(Align, BottomCenter, "Bottom Center", "Bottom Center"), Slit::BOTTOMCENTER)); 1311 place_menu.push_back(PlacementP(_FB_XTEXT(Align, BottomCenter, "Bottom Center", "Bottom Center"), Slit::BOTTOMCENTER));
1312 place_menu.push_back(PlacementP(_FBTEXT(Align, TopRight, "Top Right", "Top Right"), Slit::TOPRIGHT)); 1312 place_menu.push_back(PlacementP(_FB_XTEXT(Align, TopRight, "Top Right", "Top Right"), Slit::TOPRIGHT));
1313 place_menu.push_back(PlacementP(_FBTEXT(Align, RightCenter, "Right Center", "Right Center"), Slit::RIGHTCENTER)); 1313 place_menu.push_back(PlacementP(_FB_XTEXT(Align, RightCenter, "Right Center", "Right Center"), Slit::RIGHTCENTER));
1314 place_menu.push_back(PlacementP(_FBTEXT(Align, BottomRight, "Bottom Right", "Bottom Right"), Slit::BOTTOMRIGHT)); 1314 place_menu.push_back(PlacementP(_FB_XTEXT(Align, BottomRight, "Bottom Right", "Bottom Right"), Slit::BOTTOMRIGHT));
1315 1315
1316 1316
1317 // create items in sub menu 1317 // create items in sub menu