diff --git a/src/WinMgr.h b/src/WinMgr.h index bcc396afb..644a5c465 100644 --- a/src/WinMgr.h +++ b/src/WinMgr.h @@ -296,7 +296,7 @@ #define WIN_STATE_ALL (WinStateSticky | WinStateUnmapped |\ WinStateMaximizedBoth | WinStateFullscreen) -/* Win state flags which are also in _NET_WM_STATE: */ +/* Win state flags that are also in _NET_WM_STATE: */ #define WIN_STATE_NET (WIN_STATE_ALL | WinStateModal | WinStateUrgent |\ WinStateSkipPager | WinStateSkipTaskBar |\ WinStateBelow | WinStateAbove | WinStateFocused) diff --git a/src/default.h b/src/default.h index 329d04dac..07f3f59b4 100644 --- a/src/default.h +++ b/src/default.h @@ -262,7 +262,7 @@ cfoption icewm_preferences[] = { OBV("ConsiderHBorder", &considerHorizBorder, "Consider border frames when maximizing horizontally"), OBV("ConsiderVBorder", &considerVertBorder, "Consider border frames when maximizing vertically"), OBV("ConsiderSizeHintsMaximized", &considerSizeHintsMaximized, "Consider XSizeHints if frame is maximized"), - OBV("CenterMaximizedWindows", ¢erMaximizedWindows, "Center maximized windows which can't fit the screen (like terminals)"), + OBV("CenterMaximizedWindows", ¢erMaximizedWindows, "Center maximized windows that can't fit the screen (like terminals)"), OBV("HideBordersMaximized", &hideBordersMaximized, "Hide window borders if window is maximized"), OBV("SizeMaximized", &sizeMaximized, "Maximized windows can be resized"), OBV("ShowMoveSizeStatus", &showMoveSizeStatus, "Show position status window during move/resize"), @@ -471,9 +471,9 @@ cfoption icewm_preferences[] = { OKV("MouseWinRaise", gMouseWinRaise, "Mouse binding to raise window"), OKV("MouseWinLower", gMouseWinLower, "Mouse binding to lower window"), OKV("MouseWinTabbing", gMouseWinTabbing, "Mouse binding to create tabs"), - OKV("KeyWinRaise", gKeyWinRaise, "Raises the window which currently has input focus."), + OKV("KeyWinRaise", gKeyWinRaise, "Raises the window that currently has input focus."), OKV("KeyWinOccupyAll", gKeyWinOccupyAll, "Makes the active window occupy all work spaces."), - OKV("KeyWinLower", gKeyWinLower, "Lowers the window which currently has input focus."), + OKV("KeyWinLower", gKeyWinLower, "Lowers the window that currently has input focus."), OKV("KeyWinClose", gKeyWinClose, "Closes the active window."), OKV("KeyWinRestore", gKeyWinRestore, "Restores the active window to its visible state."), OKV("KeyWinPrev", gKeyWinPrev, "Switches focus to the previous window."), diff --git a/src/icehelp.cc b/src/icehelp.cc index aa3de4bab..d03091454 100644 --- a/src/icehelp.cc +++ b/src/icehelp.cc @@ -163,7 +163,7 @@ class lowbuffer : public cbuffer { } }; -// singly linked list of nodes which have a 'next' pointer. +// singly linked list of nodes that have a 'next' pointer. template class flist { flist(const flist&); diff --git a/src/themes.cc b/src/themes.cc index 49a21c425..86bd9cdd2 100644 --- a/src/themes.cc +++ b/src/themes.cc @@ -161,7 +161,7 @@ void ThemesMenu::findThemes(const upath& path, ObjectMenu* container) { else { // ok, have the position of the related entry - // which needs to be moved to submenu + // that needs to be moved to submenu YMenuItem *relatedItem = container->getItem(relatedItemPos); MSG(("Moving %s to submenu to prepare for %s", relatedItem->getName().c_str(), diff --git a/src/upath.cc b/src/upath.cc index c872cba01..2e46a640f 100644 --- a/src/upath.cc +++ b/src/upath.cc @@ -150,6 +150,10 @@ bool upath::isExecutable() { return access(X_OK) == 0; } +bool upath::isSearchable() { + return access(R_OK | X_OK) == 0; +} + int upath::mkdir(int mode) { return ::mkdir(string(), mode_t(mode)); } diff --git a/src/upath.h b/src/upath.h index b55f73c6a..58c919578 100644 --- a/src/upath.h +++ b/src/upath.h @@ -40,6 +40,7 @@ class upath { bool isReadable(); bool isWritable(); bool isExecutable(); + bool isSearchable(); bool isHttp() const; bool hasProtocol() const; int access(int mode = 0); diff --git a/src/wmconfig.h b/src/wmconfig.h index 2bd761e54..48489b34c 100644 --- a/src/wmconfig.h +++ b/src/wmconfig.h @@ -17,7 +17,7 @@ class WMConfig { static int rewritePrefs(cfoption* startup, const char* config); }; -// functions which are used in preferences options: +// functions that are used in preferences options: void addWorkspace(const char *name, const char *value, bool append); void addKeyboard(const char *name, const char *value, bool append); diff --git a/src/wmmenu.cc b/src/wmmenu.cc index fe0d18191..c193b0f12 100644 --- a/src/wmmenu.cc +++ b/src/wmmenu.cc @@ -77,7 +77,7 @@ static mstring guessIconNameFromExe(const char* exe) } if (path) { char* base = const_cast(my_basename(path)); - // scripts may have a suffix which is not part of the icon name + // scripts may have a suffix that is not part of the icon name char* dot = strchr(base, '.'); if (dot) *dot = '\0'; return base; diff --git a/src/wmprog.h b/src/wmprog.h index d3be54744..306fc8d80 100644 --- a/src/wmprog.h +++ b/src/wmprog.h @@ -164,7 +164,7 @@ class StartMenu: public MenuFileMenu { }; /** - * Management item which wraps DProgram and holds the trigger key information. + * Management item that wraps DProgram and holds the trigger key information. */ class KProgram { public: diff --git a/src/ycollections.cc b/src/ycollections.cc index e380273a5..c434ce2ff 100644 --- a/src/ycollections.cc +++ b/src/ycollections.cc @@ -3,7 +3,7 @@ * License: WTFPL * * Collection of various data structures used to support certain IceWM functionality. - * All of them are made for simple data structures which must be trivially copyable and mem-movable! + * All of them are made for simple data structures that must be trivially copyable and mem-movable! */ #include "config.h" diff --git a/src/ycollections.h b/src/ycollections.h index 03ade6557..27982fbf4 100644 --- a/src/ycollections.h +++ b/src/ycollections.h @@ -3,7 +3,7 @@ * License: WTFPL * * Collection of various data structures used to support certain IceWM functionality. - * All of them are made for simple data structures which must be trivially copyable and mem-movable! + * All of them are made for simple data structures that must be trivially copyable and mem-movable! */ #ifndef __YCOLLECTIONS_H #define __YCOLLECTIONS_H diff --git a/src/yicon.cc b/src/yicon.cc index 90549646b..01746392e 100644 --- a/src/yicon.cc +++ b/src/yicon.cc @@ -392,7 +392,7 @@ class IconPathIndex { // for compaction reasons, the lambdas return true on success, // but the success is only found in _this_ lambda only, - // and this is the only one which touches `result`! + // and this is the only one that touches `result`! auto checkFile = [&](upath path) { return path.fileExists() ? (res = path, true) : false; }; @@ -518,7 +518,7 @@ ref YIcon::loadIcon(unsigned size) { } } - // if the image data which was found in the expected file does not really + // if the image data that was found in the expected file does not really // match the filename, scale the data to fit if (icon != null) { if (size != icon->width() || size != icon->height()) { diff --git a/src/ypointer.h b/src/ypointer.h index 0df76c51d..7fd827e12 100644 --- a/src/ypointer.h +++ b/src/ypointer.h @@ -74,7 +74,7 @@ class ysmart { DataType** operator&() { return &fData; } }; -// For pointers to objects which were allocated with 'new'. +// For pointers to objects that were allocated with 'new'. template class osmart : public ysmart > { typedef ysmart > super; @@ -87,7 +87,7 @@ class osmart : public ysmart > { using super::operator=; }; -// For arrays which were allocated with 'new[]'. +// For arrays that were allocated with 'new[]'. template class asmart : public ysmart > { protected: diff --git a/src/yxtray.cc b/src/yxtray.cc index 1e781adb2..725ab8726 100644 --- a/src/yxtray.cc +++ b/src/yxtray.cc @@ -766,7 +766,7 @@ void YXTray::backgroundChanged() { relayout(true); repaint(); for (IterType ec = fDocked.iterator(); ++ec; ) { - /* something is not clearing which background changes */ + /* something is not clearing the background */ XClearArea(xapp->display(), ec->client_handle(), 0, 0, 0, 0, True); ec->repaint(); }