summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Compositor.cpp6
-rw-r--r--src/config/ConfigDescriptions.hpp2
-rw-r--r--src/desktop/Window.cpp2
-rw-r--r--src/events/Windows.cpp2
-rw-r--r--src/helpers/AsyncDialogBox.cpp2
-rw-r--r--src/helpers/Monitor.cpp8
-rw-r--r--src/layout/DwindleLayout.cpp2
-rw-r--r--src/layout/MasterLayout.cpp2
-rw-r--r--src/managers/AnimationManager.cpp2
-rw-r--r--src/managers/KeybindManager.cpp12
-rw-r--r--src/managers/KeybindManager.hpp2
-rw-r--r--src/managers/PointerManager.cpp2
-rw-r--r--src/managers/SessionLockManager.cpp2
-rw-r--r--src/managers/XCursorManager.cpp4
-rw-r--r--src/managers/input/InputManager.cpp4
-rw-r--r--src/managers/permissions/DynamicPermissionManager.cpp2
-rw-r--r--src/protocols/ColorManagement.cpp4
-rw-r--r--src/protocols/DRMLease.cpp2
-rw-r--r--src/protocols/DRMSyncobj.cpp2
-rw-r--r--src/protocols/DRMSyncobj.hpp2
-rw-r--r--src/protocols/FocusGrab.cpp20
-rw-r--r--src/protocols/FocusGrab.hpp4
-rw-r--r--src/protocols/GlobalShortcuts.cpp4
-rw-r--r--src/protocols/LinuxDMABUF.cpp20
-rw-r--r--src/protocols/LinuxDMABUF.hpp2
-rw-r--r--src/protocols/Screencopy.cpp4
-rw-r--r--src/protocols/SessionLock.cpp4
-rw-r--r--src/protocols/XXColorManagement.cpp4
-rw-r--r--src/protocols/types/SurfaceState.cpp2
-rw-r--r--src/render/OpenGL.cpp2
-rw-r--r--src/render/Renderer.cpp4
-rw-r--r--src/render/shaders/glsl/border.frag2
-rw-r--r--src/render/shaders/glsl/rounding.glsl2
-rw-r--r--src/xwayland/Server.cpp2
-rw-r--r--src/xwayland/XDataSource.cpp2
35 files changed, 72 insertions, 72 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp
index 77108d04..cf1a7cb4 100644
--- a/src/Compositor.cpp
+++ b/src/Compositor.cpp
@@ -1234,7 +1234,7 @@ void CCompositor::focusSurface(SP<CWLSurfaceResource> pSurface, PHLWINDOW pWindo
return;
if (g_pSeatManager->m_seatGrab && !g_pSeatManager->m_seatGrab->accepts(pSurface)) {
- Debug::log(LOG, "surface {:x} won't receive kb focus becuase grab rejected it", (uintptr_t)pSurface.get());
+ Debug::log(LOG, "surface {:x} won't receive kb focus because grab rejected it", (uintptr_t)pSurface.get());
return;
}
@@ -2861,7 +2861,7 @@ void CCompositor::arrangeMonitors() {
maxYOffsetUp = 0;
maxYOffsetDown = 0;
- // Finds the max and min values of explicitely placed monitors.
+ // Finds the max and min values of explicitly placed monitors.
for (auto const& m : arranged) {
maxXOffsetRight = std::max<double>(m->m_position.x + m->m_size.x, maxXOffsetRight);
maxXOffsetLeft = std::min<double>(m->m_position.x, maxXOffsetLeft);
@@ -3031,7 +3031,7 @@ static void checkDefaultCursorWarp(PHLMONITOR monitor) {
}
}
- // modechange happend check if cursor is on that monitor and warp it to middle to not place it out of bounds if resolution changed.
+ // modechange happened check if cursor is on that monitor and warp it to middle to not place it out of bounds if resolution changed.
if (g_pCompositor->getMonitorFromCursor() == monitor) {
g_pCompositor->warpCursorTo(POS, true);
g_pInputManager->refocus();
diff --git a/src/config/ConfigDescriptions.hpp b/src/config/ConfigDescriptions.hpp
index 219c44c1..852a86d0 100644
--- a/src/config/ConfigDescriptions.hpp
+++ b/src/config/ConfigDescriptions.hpp
@@ -154,7 +154,7 @@ inline static const std::vector<SConfigOptionDescription> CONFIG_OPTIONS = {
},
SConfigOptionDescription{
.value = "decoration:rounding_power",
- .description = "rouding power of corners (2 is a circle)",
+ .description = "rounding power of corners (2 is a circle)",
.type = CONFIG_OPTION_FLOAT,
.data = SConfigOptionDescription::SFloatData{2, 2, 10},
},
diff --git a/src/desktop/Window.cpp b/src/desktop/Window.cpp
index 14c9d4ce..6563727a 100644
--- a/src/desktop/Window.cpp
+++ b/src/desktop/Window.cpp
@@ -1804,7 +1804,7 @@ void CWindow::deactivateGroupMembers() {
auto curr = getGroupHead();
while (curr) {
if (curr != m_self.lock()) {
- // we dont want to deactivate unfocused xwayland windows
+ // we don't want to deactivate unfocused xwayland windows
// because X is weird, keep the behavior for wayland windows
// also its not really needed for xwayland windows
// ref: #9760 #9294
diff --git a/src/events/Windows.cpp b/src/events/Windows.cpp
index 17bf2750..7a741b58 100644
--- a/src/events/Windows.cpp
+++ b/src/events/Windows.cpp
@@ -181,7 +181,7 @@ void Events::listener_mapWindow(void* owner, void* data) {
break;
}
case CWindowRule::RULE_WORKSPACE: {
- // check if it isnt unset
+ // check if it isn't unset
const auto WORKSPACERQ = r->m_rule.substr(r->m_rule.find_first_of(' ') + 1);
if (WORKSPACERQ == "unset")
diff --git a/src/helpers/AsyncDialogBox.cpp b/src/helpers/AsyncDialogBox.cpp
index 4ee5ccca..250b2f5a 100644
--- a/src/helpers/AsyncDialogBox.cpp
+++ b/src/helpers/AsyncDialogBox.cpp
@@ -71,7 +71,7 @@ void CAsyncDialogBox::onWrite(int fd, uint32_t mask) {
m_stdout += std::string_view{(char*)buf.data(), (size_t)ret};
}
- // restore the flags (otherwise libwayland wont give us a hangup)
+ // restore the flags (otherwise libwayland won't give us a hangup)
if (fcntl(fd, F_SETFL, fdFlags) < 0) {
Debug::log(ERR, "CAsyncDialogBox::onWrite: fcntl 2 failed!");
return;
diff --git a/src/helpers/Monitor.cpp b/src/helpers/Monitor.cpp
index 47a7ff46..63f1d147 100644
--- a/src/helpers/Monitor.cpp
+++ b/src/helpers/Monitor.cpp
@@ -237,7 +237,7 @@ void CMonitor::onConnect(bool noRule) {
if (!m_activeMonitorRule.mirrorOf.empty())
setMirror(m_activeMonitorRule.mirrorOf);
- if (!g_pCompositor->m_lastMonitor) // set the last monitor if it isnt set yet
+ if (!g_pCompositor->m_lastMonitor) // set the last monitor if it isn't set yet
g_pCompositor->setActiveMonitor(m_self.lock());
g_pHyprRenderer->arrangeLayersForMonitor(m_id);
@@ -512,7 +512,7 @@ bool CMonitor::applyMonitorRule(SMonitorRule* pMonitorRule, bool force) {
&& m_autoDir == RULE->autoDir /* Auto direction is the same */
/* position is set correctly */
&& ((DELTALESSTHAN(m_position.x, RULE->offset.x, 1) && DELTALESSTHAN(m_position.y, RULE->offset.y, 1)) || RULE->offset == Vector2D(-INT32_MAX, -INT32_MAX))
- /* other properties hadnt changed */
+ /* other properties hadn't changed */
&& m_transform == RULE->transform && RULE->enable10bit == m_enabled10bit && RULE->cmType == m_cmType && RULE->sdrSaturation == m_sdrSaturation &&
RULE->sdrBrightness == m_sdrBrightness && RULE->sdrMinLuminance == m_minLuminance && RULE->sdrMaxLuminance == m_maxLuminance &&
RULE->supportsWideColor == m_supportsWideColor && RULE->supportsHDR == m_supportsHDR && RULE->minLuminance == m_minLuminance && RULE->maxLuminance == m_maxLuminance &&
@@ -618,7 +618,7 @@ bool CMonitor::applyMonitorRule(SMonitorRule* pMonitorRule, bool force) {
return false;
});
- // if the best mode isnt close to requested, then try requested as custom mode first
+ // if the best mode isn't close to requested, then try requested as custom mode first
if (!requestedModes.empty()) {
auto bestMode = requestedModes.back();
if (!DELTALESSTHAN(bestMode->pixelSize.x, RULE->resolution.x, 1) || !DELTALESSTHAN(bestMode->pixelSize.y, RULE->resolution.y, 1) ||
@@ -1329,7 +1329,7 @@ void CMonitor::setSpecialWorkspace(const PHLWORKSPACE& pWorkspace) {
const auto MIDDLE = w->middle();
if (w->m_isFloating && VECNOTINRECT(MIDDLE, m_position.x, m_position.y, m_position.x + m_size.x, m_position.y + m_size.y) && !w->isX11OverrideRedirect()) {
- // if it's floating and the middle isnt on the current mon, move it to the center
+ // if it's floating and the middle isn't on the current mon, move it to the center
const auto PMONFROMMIDDLE = g_pCompositor->getMonitorFromVector(MIDDLE);
Vector2D pos = w->m_realPosition->goal();
if (VECNOTINRECT(MIDDLE, PMONFROMMIDDLE->m_position.x, PMONFROMMIDDLE->m_position.y, PMONFROMMIDDLE->m_position.x + PMONFROMMIDDLE->m_size.x,
diff --git a/src/layout/DwindleLayout.cpp b/src/layout/DwindleLayout.cpp
index 2f51b162..7dd34434 100644
--- a/src/layout/DwindleLayout.cpp
+++ b/src/layout/DwindleLayout.cpp
@@ -190,7 +190,7 @@ void CHyprDwindleLayout::applyNodeDataToWindow(SDwindleNodeData* pNode, bool for
// Calculate pseudo
float scale = 1;
- // adjust if doesnt fit
+ // adjust if doesn't fit
if (PWINDOW->m_pseudoSize.x > calcSize.x || PWINDOW->m_pseudoSize.y > calcSize.y) {
if (PWINDOW->m_pseudoSize.x > calcSize.x) {
scale = calcSize.x / PWINDOW->m_pseudoSize.x;
diff --git a/src/layout/MasterLayout.cpp b/src/layout/MasterLayout.cpp
index c0f8e5a7..384dc884 100644
--- a/src/layout/MasterLayout.cpp
+++ b/src/layout/MasterLayout.cpp
@@ -932,7 +932,7 @@ SWindowRenderLayoutHints CHyprMasterLayout::requestRenderHints(PHLWINDOW pWindow
SWindowRenderLayoutHints hints;
- return hints; // master doesnt have any hints
+ return hints; // master doesn't have any hints
}
void CHyprMasterLayout::moveWindowTo(PHLWINDOW pWindow, const std::string& dir, bool silent) {
diff --git a/src/managers/AnimationManager.cpp b/src/managers/AnimationManager.cpp
index 333111e9..a5ede0e5 100644
--- a/src/managers/AnimationManager.cpp
+++ b/src/managers/AnimationManager.cpp
@@ -104,7 +104,7 @@ static void handleUpdate(CAnimatedVariable<VarType>& av, bool warp) {
if (!PMONITOR)
return;
- // dont damage the whole monitor on workspace change, unless it's a special workspace, because dim/blur etc
+ // don't damage the whole monitor on workspace change, unless it's a special workspace, because dim/blur etc
if (PWORKSPACE->m_isSpecialWorkspace)
g_pHyprRenderer->damageMonitor(PMONITOR);
diff --git a/src/managers/KeybindManager.cpp b/src/managers/KeybindManager.cpp
index 6a08a550..d9b2bc1f 100644
--- a/src/managers/KeybindManager.cpp
+++ b/src/managers/KeybindManager.cpp
@@ -2013,8 +2013,8 @@ SDispatchResult CKeybindManager::moveCurrentWorkspaceToMonitor(std::string args)
PHLMONITOR PMONITOR = g_pCompositor->getMonitorFromString(args);
if (!PMONITOR) {
- Debug::log(ERR, "Ignoring moveCurrentWorkspaceToMonitor: monitor doesnt exist");
- return {.success = false, .error = "Ignoring moveCurrentWorkspaceToMonitor: monitor doesnt exist"};
+ Debug::log(ERR, "Ignoring moveCurrentWorkspaceToMonitor: monitor doesn't exist");
+ return {.success = false, .error = "Ignoring moveCurrentWorkspaceToMonitor: monitor doesn't exist"};
}
// get the current workspace
@@ -2039,8 +2039,8 @@ SDispatchResult CKeybindManager::moveWorkspaceToMonitor(std::string args) {
const auto PMONITOR = g_pCompositor->getMonitorFromString(monitor);
if (!PMONITOR) {
- Debug::log(ERR, "Ignoring moveWorkspaceToMonitor: monitor doesnt exist");
- return {.success = false, .error = "Ignoring moveWorkspaceToMonitor: monitor doesnt exist"};
+ Debug::log(ERR, "Ignoring moveWorkspaceToMonitor: monitor doesn't exist");
+ return {.success = false, .error = "Ignoring moveWorkspaceToMonitor: monitor doesn't exist"};
}
const auto WORKSPACEID = getWorkspaceIDNameFromString(workspace).id;
@@ -2582,7 +2582,7 @@ SDispatchResult CKeybindManager::sendshortcut(std::string args) {
const auto LASTSURFACE = g_pCompositor->m_lastFocus.lock();
//if regexp is not empty, send shortcut to current window
- //else, dont change focus
+ //else, don't change focus
if (!regexp.empty()) {
PWINDOW = g_pCompositor->getWindowByRegex(regexp);
@@ -2924,7 +2924,7 @@ void CKeybindManager::moveWindowIntoGroup(PHLWINDOW pWindow, PHLWINDOW pWindowIn
updateRelativeCursorCoords();
- g_pLayoutManager->getCurrentLayout()->onWindowRemoved(pWindow); // This removes groupped property!
+ g_pLayoutManager->getCurrentLayout()->onWindowRemoved(pWindow); // This removes grouped property!
if (pWindow->m_monitor != pWindowInDirection->m_monitor) {
pWindow->moveToWorkspace(pWindowInDirection->m_workspace);
diff --git a/src/managers/KeybindManager.hpp b/src/managers/KeybindManager.hpp
index be2d114b..7b767d1a 100644
--- a/src/managers/KeybindManager.hpp
+++ b/src/managers/KeybindManager.hpp
@@ -106,7 +106,7 @@ class CKeybindManager {
std::vector<SP<SKeybind>> m_keybinds;
- //since we cant find keycode through keyname in xkb:
+ //since we can't find keycode through keyname in xkb:
//on sendshortcut call, we once search for keyname (e.g. "g") the correct keycode (e.g. 42)
//and cache it in this map to make sendshortcut calls faster
//we also store the keyboard pointer (in the string) to differentiate between different keyboard (layouts)
diff --git a/src/managers/PointerManager.cpp b/src/managers/PointerManager.cpp
index 7d6f58e0..e6a5693d 100644
--- a/src/managers/PointerManager.cpp
+++ b/src/managers/PointerManager.cpp
@@ -527,7 +527,7 @@ SP<Aquamarine::IBuffer> CPointerManager::renderHWCursorBuffer(SP<CPointerManager
if (TR) {
cairo_matrix_rotate(&matrixPre, M_PI_2 * (double)TR);
- // FIXME: this is wrong, and doesnt work for 5, 6 and 7. (flipped + rot)
+ // FIXME: this is wrong, and doesn't work for 5, 6 and 7. (flipped + rot)
// cba to do it rn, does anyone fucking use that??
if (TR >= WL_OUTPUT_TRANSFORM_FLIPPED) {
cairo_matrix_scale(&matrixPre, -1, 1);
diff --git a/src/managers/SessionLockManager.cpp b/src/managers/SessionLockManager.cpp
index 4b6cfbf4..68eee562 100644
--- a/src/managers/SessionLockManager.cpp
+++ b/src/managers/SessionLockManager.cpp
@@ -100,7 +100,7 @@ void CSessionLockManager::onNewSessionLock(SP<CSessionLock> pLock) {
return;
if (g_pCompositor->m_unsafeState || !g_pCompositor->m_aqBackend->hasSession() || !g_pCompositor->m_aqBackend->session->active) {
- // Because the session is inactive, there is a good reason for why the client did't recieve locked or denied.
+ // Because the session is inactive, there is a good reason for why the client did't receive locked or denied.
// We send locked, although this could lead to imperfect frames when we start to render again.
g_pSessionLockManager->m_sessionLock->lock->sendLocked();
g_pSessionLockManager->m_sessionLock->hasSentLocked = true;
diff --git a/src/managers/XCursorManager.cpp b/src/managers/XCursorManager.cpp
index 9bbf531b..626c4250 100644
--- a/src/managers/XCursorManager.cpp
+++ b/src/managers/XCursorManager.cpp
@@ -574,7 +574,7 @@ void CXCursorManager::syncGsettings() {
auto* gSettingsSchemaSource = g_settings_schema_source_get_default();
if (!gSettingsSchemaSource) {
- Debug::log(WARN, "GSettings default schema source does not exist, cant sync GSettings");
+ Debug::log(WARN, "GSettings default schema source does not exist, can't sync GSettings");
return false;
}
@@ -592,7 +592,7 @@ void CXCursorManager::syncGsettings() {
using SettingValue = std::variant<std::string, int>;
auto setValue = [&checkParamExists](std::string const& paramName, const SettingValue& paramValue, std::string const& category) {
if (!checkParamExists(paramName, category)) {
- Debug::log(WARN, "GSettings parameter doesnt exist {} in {}", paramName, category);
+ Debug::log(WARN, "GSettings parameter doesn't exist {} in {}", paramName, category);
return;
}
diff --git a/src/managers/input/InputManager.cpp b/src/managers/input/InputManager.cpp
index 4d5bcb28..eb941502 100644
--- a/src/managers/input/InputManager.cpp
+++ b/src/managers/input/InputManager.cpp
@@ -361,7 +361,7 @@ void CInputManager::mouseMoveUnified(uint32_t time, bool refocus, bool mouse) {
if (!foundSurface)
foundSurface = g_pCompositor->vectorToLayerSurface(mouseCoords, &PMONITOR->m_layerSurfaceLayers[ZWLR_LAYER_SHELL_V1_LAYER_TOP], &surfaceCoords, &pFoundLayerSurface);
- // then, we check if the workspace doesnt have a fullscreen window
+ // then, we check if the workspace doesn't have a fullscreen window
const auto PWORKSPACE = PMONITOR->m_activeSpecialWorkspace ? PMONITOR->m_activeSpecialWorkspace : PMONITOR->m_activeWorkspace;
const auto PWINDOWIDEAL = g_pCompositor->vectorToWindowUnified(mouseCoords, RESERVED_EXTENTS | INPUT_EXTENTS | ALLOW_FLOATING);
if (PWORKSPACE->m_hasFullscreenWindow && !foundSurface && PWORKSPACE->m_fullscreenMode == FSMODE_FULLSCREEN) {
@@ -796,7 +796,7 @@ void CInputManager::processMouseDownNormal(const IPointer::SButtonEvent& e) {
case WL_POINTER_BUTTON_STATE_RELEASED: break;
}
- // notify app if we didnt handle it
+ // notify app if we didn't handle it
g_pSeatManager->sendPointerButton(e.timeMs, e.button, e.state);
if (const auto PMON = g_pCompositor->getMonitorFromVector(mouseCoords); PMON != g_pCompositor->m_lastMonitor && PMON)
diff --git a/src/managers/permissions/DynamicPermissionManager.cpp b/src/managers/permissions/DynamicPermissionManager.cpp
index bfb14c59..235336b7 100644
--- a/src/managers/permissions/DynamicPermissionManager.cpp
+++ b/src/managers/permissions/DynamicPermissionManager.cpp
@@ -193,7 +193,7 @@ eDynamicPermissionAllowMode CDynamicPermissionManager::clientPermissionMode(wl_c
return PERMISSION_RULE_ALLOW_MODE_PENDING;
}
- // if we are here, we need to ask, that's the fallback for all these (keyboards wont come here)
+ // if we are here, we need to ask, that's the fallback for all these (keyboards won't come here)
askForPermission(client, LOOKUP.value_or(""), permission);
return PERMISSION_RULE_ALLOW_MODE_PENDING;
diff --git a/src/protocols/ColorManagement.cpp b/src/protocols/ColorManagement.cpp
index 7cfcbbbc..215ab5ac 100644
--- a/src/protocols/ColorManagement.cpp
+++ b/src/protocols/ColorManagement.cpp
@@ -247,7 +247,7 @@ wl_client* CColorManagementOutput::client() {
}
CColorManagementSurface::CColorManagementSurface(SP<CWLSurfaceResource> surface_) : m_surface(surface_) {
- // only for frog cm untill wayland cm is adopted
+ // only for frog cm until wayland cm is adopted
}
CColorManagementSurface::CColorManagementSurface(SP<CWpColorManagementSurfaceV1> resource, SP<CWLSurfaceResource> surface_) : m_surface(surface_), m_resource(resource) {
@@ -766,7 +766,7 @@ CColorManagementImageDescriptionInfo::CColorManagementImageDescriptionInfo(SP<CW
m_resource->sendTfNamed(m_settings.transferFunction);
m_resource->sendLuminances(std::round(m_settings.luminances.min * 10000), m_settings.luminances.max, m_settings.luminances.reference);
- // send expexted display paramateres
+ // send expected display paramateres
m_resource->sendTargetPrimaries(toProto(m_settings.masteringPrimaries.red.x), toProto(m_settings.masteringPrimaries.red.y), toProto(m_settings.masteringPrimaries.green.x),
toProto(m_settings.masteringPrimaries.green.y), toProto(m_settings.masteringPrimaries.blue.x), toProto(m_settings.masteringPrimaries.blue.y),
toProto(m_settings.masteringPrimaries.white.x), toProto(m_settings.masteringPrimaries.white.y));
diff --git a/src/protocols/DRMLease.cpp b/src/protocols/DRMLease.cpp
index d64555f2..3d958015 100644
--- a/src/protocols/DRMLease.cpp
+++ b/src/protocols/DRMLease.cpp
@@ -137,7 +137,7 @@ CDRMLeaseRequestResource::CDRMLeaseRequestResource(WP<CDRMLeaseDeviceResource> p
PROTO::lease.at(m_parent->m_deviceName)->m_leases.emplace_back(RESOURCE);
- // per protcol, after submit, this is dead.
+ // per protocol, after submit, this is dead.
PROTO::lease.at(m_parent->m_deviceName)->destroyResource(this);
});
}
diff --git a/src/protocols/DRMSyncobj.cpp b/src/protocols/DRMSyncobj.cpp
index 2f5c3e14..762708e5 100644
--- a/src/protocols/DRMSyncobj.cpp
+++ b/src/protocols/DRMSyncobj.cpp
@@ -32,7 +32,7 @@ bool CDRMSyncPointState::addWaiter(const std::function<void()>& waiter) {
return m_timeline->addWaiter(waiter, m_point, 0u);
}
-bool CDRMSyncPointState::comitted() {
+bool CDRMSyncPointState::committed() {
return m_acquireCommitted;
}
diff --git a/src/protocols/DRMSyncobj.hpp b/src/protocols/DRMSyncobj.hpp
index ed15b199..b330818d 100644
--- a/src/protocols/DRMSyncobj.hpp
+++ b/src/protocols/DRMSyncobj.hpp
@@ -21,7 +21,7 @@ class CDRMSyncPointState {
WP<CSyncTimeline> timeline();
Hyprutils::Memory::CUniquePointer<CSyncReleaser> createSyncRelease();
bool addWaiter(const std::function<void()>& waiter);
- bool comitted();
+ bool committed();
Hyprutils::OS::CFileDescriptor exportAsFD();
void signal();
diff --git a/src/protocols/FocusGrab.cpp b/src/protocols/FocusGrab.cpp
index 3ab8d1e2..c6530826 100644
--- a/src/protocols/FocusGrab.cpp
+++ b/src/protocols/FocusGrab.cpp
@@ -35,12 +35,12 @@ bool CFocusGrab::good() {
return m_resource->resource();
}
-bool CFocusGrab::isSurfaceComitted(SP<CWLSurfaceResource> surface) {
+bool CFocusGrab::isSurfaceCommitted(SP<CWLSurfaceResource> surface) {
auto iter = std::ranges::find_if(m_surfaces, [surface](const auto& o) { return o.first == surface; });
if (iter == m_surfaces.end())
return false;
- return iter->second->m_state == CFocusGrabSurfaceState::Comitted;
+ return iter->second->m_state == CFocusGrabSurfaceState::Committed;
}
void CFocusGrab::start() {
@@ -49,7 +49,7 @@ void CFocusGrab::start() {
g_pSeatManager->setGrab(m_grab);
}
- // Ensure new surfaces are focused if under the mouse when comitted.
+ // Ensure new surfaces are focused if under the mouse when committed.
g_pInputManager->simulateMouseMovement();
refocusKeyboard();
}
@@ -92,12 +92,12 @@ void CFocusGrab::eraseSurface(SP<CWLSurfaceResource> surface) {
void CFocusGrab::refocusKeyboard() {
auto keyboardSurface = g_pSeatManager->m_state.keyboardFocus;
- if (keyboardSurface && isSurfaceComitted(keyboardSurface.lock()))
+ if (keyboardSurface && isSurfaceCommitted(keyboardSurface.lock()))
return;
SP<CWLSurfaceResource> surface = nullptr;
for (auto const& [surf, state] : m_surfaces) {
- if (state->m_state == CFocusGrabSurfaceState::Comitted) {
+ if (state->m_state == CFocusGrabSurfaceState::Committed) {
surface = surf.lock();
break;
}
@@ -111,7 +111,7 @@ void CFocusGrab::refocusKeyboard() {
void CFocusGrab::commit(bool removeOnly) {
auto surfacesChanged = false;
- auto anyComitted = false;
+ auto anyCommitted = false;
for (auto iter = m_surfaces.begin(); iter != m_surfaces.end();) {
switch (iter->second->m_state) {
case CFocusGrabSurfaceState::PendingRemoval:
@@ -121,20 +121,20 @@ void CFocusGrab::commit(bool removeOnly) {
continue;
case CFocusGrabSurfaceState::PendingAddition:
if (!removeOnly) {
- iter->second->m_state = CFocusGrabSurfaceState::Comitted;
+ iter->second->m_state = CFocusGrabSurfaceState::Committed;
m_grab->add(iter->first.lock());
surfacesChanged = true;
- anyComitted = true;
+ anyCommitted = true;
}
break;
- case CFocusGrabSurfaceState::Comitted: anyComitted = true; break;
+ case CFocusGrabSurfaceState::Committed: anyCommitted = true; break;
}
iter++;
}
if (surfacesChanged) {
- if (anyComitted)
+ if (anyCommitted)
start();
else
finish(true);
diff --git a/src/protocols/FocusGrab.hpp b/src/protocols/FocusGrab.hpp
index 6fb27b86..f02f97fc 100644
--- a/src/protocols/FocusGrab.hpp
+++ b/src/protocols/FocusGrab.hpp
@@ -20,7 +20,7 @@ class CFocusGrabSurfaceState {
enum State {
PendingAddition,
PendingRemoval,
- Comitted,
+ Committed,
} m_state = PendingAddition;
private:
@@ -35,7 +35,7 @@ class CFocusGrab {
~CFocusGrab();
bool good();
- bool isSurfaceComitted(SP<CWLSurfaceResource> surface);
+ bool isSurfaceCommitted(SP<CWLSurfaceResource> surface);
void start();
void finish(bool sendCleared);
diff --git a/src/protocols/GlobalShortcuts.cpp b/src/protocols/GlobalShortcuts.cpp
index 50e7434d..ee961b74 100644
--- a/src/protocols/GlobalShortcuts.cpp
+++ b/src/protocols/GlobalShortcuts.cpp
@@ -40,9 +40,9 @@ CGlobalShortcutsProtocol::CGlobalShortcutsProtocol(const wl_interface* iface, co
}
void CGlobalShortcutsProtocol::bindManager(wl_client* client, void* data, uint32_t ver, uint32_t id) {
- const auto RESROUCE = m_clients.emplace_back(makeShared<CShortcutClient>(makeShared<CHyprlandGlobalShortcutsManagerV1>(client, ver, id)));
+ const auto RESOURCE = m_clients.emplace_back(makeShared<CShortcutClient>(makeShared<CHyprlandGlobalShortcutsManagerV1>(client, ver, id)));
- if UNLIKELY (!RESROUCE->good()) {
+ if UNLIKELY (!RESOURCE->good()) {
wl_client_post_no_memory(client);
m_clients.pop_back();
return;
diff --git a/src/protocols/LinuxDMABUF.cpp b/src/protocols/LinuxDMABUF.cpp
index a949d6a1..c45da4e0 100644
--- a/src/protocols/LinuxDMABUF.cpp
+++ b/src/protocols/LinuxDMABUF.cpp
@@ -32,14 +32,14 @@ CDMABUFFormatTable::CDMABUFFormatTable(SDMABUFTranche _rendererTranche, std::vec
// insert formats into vec if they got inserted into set, meaning they're unique
size_t i = 0;
- m_rendererTranche.indicies.clear();
+ m_rendererTranche.indices.clear();
for (auto const& fmt : m_rendererTranche.formats) {
for (auto const& mod : fmt.modifiers) {
auto format = std::make_pair<>(fmt.drmFormat, mod);
auto [_, inserted] = formats.insert(format);
if (inserted) {
// if it was inserted into set, then its unique and will have a new index in vec
- m_rendererTranche.indicies.push_back(i++);
+ m_rendererTranche.indices.push_back(i++);
formatsVec.push_back(SDMABUFFormatTableEntry{
.fmt = fmt.drmFormat,
.modifier = mod,
@@ -47,29 +47,29 @@ CDMABUFFormatTable::CDMABUFFormatTable(SDMABUFTranche _rendererTranche, std::vec
} else {
// if it wasn't inserted then find its index in vec
auto it = std::ranges::find_if(formatsVec, [fmt, mod](const SDMABUFFormatTableEntry& oth) { return oth.fmt == fmt.drmFormat && oth.modifier == mod; });
- m_rendererTranche.indicies.push_back(it - formatsVec.begin());
+ m_rendererTranche.indices.push_back(it - formatsVec.begin());
}
}
}
for (auto& [monitor, tranche] : m_monitorTranches) {
- tranche.indicies.clear();
+ tranche.indices.clear();
for (auto const& fmt : tranche.formats) {
for (auto const& mod : fmt.modifiers) {
- // apparently these can implode on planes, so dont use them
+ // apparently these can implode on planes, so don't use them
if (mod == DRM_FORMAT_MOD_INVALID || mod == DRM_FORMAT_MOD_LINEAR)
continue;
auto format = std::make_pair<>(fmt.drmFormat, mod);
auto [_, inserted] = formats.insert(format);
if (inserted) {
- tranche.indicies.push_back(i++);
+ tranche.indices.push_back(i++);
formatsVec.push_back(SDMABUFFormatTableEntry{
.fmt = fmt.drmFormat,
.modifier = mod,
});
} else {
auto it = std::ranges::find_if(formatsVec, [fmt, mod](const SDMABUFFormatTableEntry& oth) { return oth.fmt == fmt.drmFormat && oth.modifier == mod; });
- tranche.indicies.push_back(it - formatsVec.begin());
+ tranche.indices.push_back(it - formatsVec.begin());
}
}
}
@@ -318,8 +318,8 @@ void CLinuxDMABUFFeedbackResource::sendTranche(SDMABUFTranche& tranche) {
m_resource->sendTrancheFlags((zwpLinuxDmabufFeedbackV1TrancheFlags)tranche.flags);
wl_array indices = {
- .size = tranche.indicies.size() * sizeof(tranche.indicies.at(0)),
- .data = tranche.indicies.data(),
+ .size = tranche.indices.size() * sizeof(tranche.indices.at(0)),
+ .data = tranche.indices.data(),
};
m_resource->sendTrancheFormats(&indices);
m_resource->sendTrancheDone();
@@ -421,7 +421,7 @@ CLinuxDMABufV1Protocol::CLinuxDMABufV1Protocol(const wl_interface* iface, const
SDMABUFTranche eglTranche = {
.device = m_mainDevice,
- .flags = 0, // renderer isnt for ds so dont set flag.
+ .flags = 0, // renderer isn't for ds so don't set flag.
.formats = g_pHyprOpenGL->getDRMFormats(),
};
diff --git a/src/protocols/LinuxDMABUF.hpp b/src/protocols/LinuxDMABUF.hpp
index ea2c9457..296ef04d 100644
--- a/src/protocols/LinuxDMABUF.hpp
+++ b/src/protocols/LinuxDMABUF.hpp
@@ -43,7 +43,7 @@ struct SDMABUFTranche {
dev_t device = 0;
uint32_t flags = 0;
std::vector<SDRMFormat> formats;
- std::vector<uint16_t> indicies;
+ std::vector<uint16_t> indices;
};
class CDMABUFFormatTable {
diff --git a/src/protocols/Screencopy.cpp b/src/protocols/Screencopy.cpp
index a86a74d3..e98b216d 100644
--- a/src/protocols/Screencopy.cpp
+++ b/src/protocols/Screencopy.cpp
@@ -26,7 +26,7 @@ CScreencopyFrame::CScreencopyFrame(SP<CZwlrScreencopyFrameV1> resource_, int32_t
m_monitor = CWLOutputResource::fromResource(output)->m_monitor;
if (!m_monitor) {
- LOGM(ERR, "Client requested sharing of a monitor that doesnt exist");
+ LOGM(ERR, "Client requested sharing of a monitor that doesn't exist");
m_resource->sendFailed();
return;
}
@@ -48,7 +48,7 @@ CScreencopyFrame::CScreencopyFrame(SP<CZwlrScreencopyFrameV1> resource_, int32_t
return;
}
- // TODO: hack, we can't bit flip so we'll format flip heh, GL_BGRA_EXT wont work here
+ // TODO: hack, we can't bit flip so we'll format flip heh, GL_BGRA_EXT won't work here
if (m_shmFormat == DRM_FORMAT_XRGB2101010 || m_shmFormat == DRM_FORMAT_ARGB2101010)
m_shmFormat = DRM_FORMAT_XBGR2101010;
diff --git a/src/protocols/SessionLock.cpp b/src/protocols/SessionLock.cpp
index 64c0569b..66e10311 100644
--- a/src/protocols/SessionLock.cpp
+++ b/src/protocols/SessionLock.cpp
@@ -121,8 +121,8 @@ CSessionLock::CSessionLock(SP<CExtSessionLockV1> resource_) : m_resource(resourc
m_events.unlockAndDestroy.emit();
- // if lock tools have hidden it and doesnt restore it, we wont recieve a new cursor until the cursorshape protocol gives us one.
- // so set it to left_ptr so the "desktop/wallpaper" doesnt end up missing a cursor until hover over a window sending us a shape.
+ // if lock tools have hidden it and doesn't restore it, we won't receive a new cursor until the cursorshape protocol gives us one.
+ // so set it to left_ptr so the "desktop/wallpaper" doesn't end up missing a cursor until hover over a window sending us a shape.
g_pHyprRenderer->setCursorFromName("left_ptr");
m_inert = true;
diff --git a/src/protocols/XXColorManagement.cpp b/src/protocols/XXColorManagement.cpp
index d01e367a..08f2fe70 100644
--- a/src/protocols/XXColorManagement.cpp
+++ b/src/protocols/XXColorManagement.cpp
@@ -194,7 +194,7 @@ wl_client* CXXColorManagementOutput::client() {
}
CXXColorManagementSurface::CXXColorManagementSurface(SP<CWLSurfaceResource> surface_) : m_surface(surface_) {
- // only for frog cm untill wayland cm is adopted
+ // only for frog cm until wayland cm is adopted
}
CXXColorManagementSurface::CXXColorManagementSurface(SP<CXxColorManagementSurfaceV4> resource_, SP<CWLSurfaceResource> surface_) : m_surface(surface_), m_resource(resource_) {
@@ -600,7 +600,7 @@ CXXColorManagementImageDescriptionInfo::CXXColorManagementImageDescriptionInfo(S
m_resource->sendTfNamed(m_settings.transferFunction);
m_resource->sendLuminances(std::round(m_settings.luminances.min * 10000), m_settings.luminances.max, m_settings.luminances.reference);
- // send expexted display paramateres
+ // send expected display paramateres
m_resource->sendTargetPrimaries(toProto(m_settings.masteringPrimaries.red.x), toProto(m_settings.masteringPrimaries.red.y), toProto(m_settings.masteringPrimaries.green.x),
toProto(m_settings.masteringPrimaries.green.y), toProto(m_settings.masteringPrimaries.blue.x), toProto(m_settings.masteringPrimaries.blue.y),
toProto(m_settings.masteringPrimaries.white.x), toProto(m_settings.masteringPrimaries.white.y));
diff --git a/src/protocols/types/SurfaceState.cpp b/src/protocols/types/SurfaceState.cpp
index e60bf64d..a1195439 100644
--- a/src/protocols/types/SurfaceState.cpp
+++ b/src/protocols/types/SurfaceState.cpp
@@ -57,7 +57,7 @@ void SSurfaceState::reset() {
// applies only to the buffer that is attached to the surface
acquire = {};
- // wl_surface.commit assings pending ... and clears pending damage.
+ // wl_surface.commit assigns pending ... and clears pending damage.
damage.clear();
bufferDamage.clear();
}
diff --git a/src/render/OpenGL.cpp b/src/render/OpenGL.cpp
index 6737f8c1..3526f622 100644
--- a/src/render/OpenGL.cpp
+++ b/src/render/OpenGL.cpp
@@ -855,7 +855,7 @@ void CHyprOpenGLImpl::end() {
// if we dropped to offMain, release it now.
// if there is a plugin constantly using it, this might be a bit slow,
- // but I havent seen a single plugin yet use these, so it's better to drop a bit of vram.
+ // but I haven't seen a single plugin yet use these, so it's better to drop a bit of vram.
if (m_renderData.pCurrentMonData->offMainFB.isAllocated())
m_renderData.pCurrentMonData->offMainFB.release();
diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp
index 918a6e94..43168837 100644
--- a/src/render/Renderer.cpp
+++ b/src/render/Renderer.cpp
@@ -2414,7 +2414,7 @@ void CHyprRenderer::makeSnapshot(PHLWINDOW pWindow) {
// we need to "damage" the entire monitor
// so that we render the entire window
- // this is temporary, doesnt mess with the actual damage
+ // this is temporary, doesn't mess with the actual damage
CRegion fakeDamage{0, 0, (int)PMONITOR->m_transformedSize.x, (int)PMONITOR->m_transformedSize.y};
PHLWINDOWREF ref{pWindow};
@@ -2447,7 +2447,7 @@ void CHyprRenderer::makeSnapshot(PHLLS pLayer) {
// we need to "damage" the entire monitor
// so that we render the entire window
- // this is temporary, doesnt mess with the actual damage
+ // this is temporary, doesn't mess with the actual damage
CRegion fakeDamage{0, 0, (int)PMONITOR->m_transformedSize.x, (int)PMONITOR->m_transformedSize.y};
makeEGLCurrent();
diff --git a/src/render/shaders/glsl/border.frag b/src/render/shaders/glsl/border.frag
index 38ae24c0..d93773fd 100644
--- a/src/render/shaders/glsl/border.frag
+++ b/src/render/shaders/glsl/border.frag
@@ -127,7 +127,7 @@ void main() {
pixCoord -= fullSize * 0.5 - radius;
pixCoordOuter -= fullSize * 0.5 - radiusOuter;
- // center the pixes dont make it top-left
+ // center the pixes don't make it top-left
pixCoord += vec2(1.0, 1.0) / fullSize;
pixCoordOuter += vec2(1.0, 1.0) / fullSize;
diff --git a/src/render/shaders/glsl/rounding.glsl b/src/render/shaders/glsl/rounding.glsl
index cae34465..472415fd 100644
--- a/src/render/shaders/glsl/rounding.glsl
+++ b/src/render/shaders/glsl/rounding.glsl
@@ -12,7 +12,7 @@ vec4 rounding(vec4 color) {
pixCoord -= topLeft + fullSize * 0.5;
pixCoord *= vec2(lessThan(pixCoord, vec2(0.0))) * -2.0 + 1.0;
pixCoord -= fullSize * 0.5 - radius;
- pixCoord += vec2(1.0, 1.0) / fullSize; // center the pix dont make it top-left
+ pixCoord += vec2(1.0, 1.0) / fullSize; // center the pix don't make it top-left
if (pixCoord.x + pixCoord.y > radius) {
float dist = pow(pow(pixCoord.x, roundingPower) + pow(pixCoord.y, roundingPower), 1.0/roundingPower);
diff --git a/src/xwayland/Server.cpp b/src/xwayland/Server.cpp
index cce325f5..209c2f95 100644
--- a/src/xwayland/Server.cpp
+++ b/src/xwayland/Server.cpp
@@ -149,7 +149,7 @@ static bool openSockets(std::array<CFileDescriptor, 2>& sockets, int display) {
}
#else
if (*CREATEABSTRACTSOCKET) {
- Debug::log(WARN, "The abstract XWayland Unix domain socket might be used only on Linux systems. A regular one'll be created insted.");
+ Debug::log(WARN, "The abstract XWayland Unix domain socket might be used only on Linux systems. A regular one'll be created instead.");
}
path = getSocketPath(display, false);
strncpy(addr.sun_path, path.c_str(), path.length() + 1);
diff --git a/src/xwayland/XDataSource.cpp b/src/xwayland/XDataSource.cpp
index 6b4637e5..7044d5ff 100644
--- a/src/xwayland/XDataSource.cpp
+++ b/src/xwayland/XDataSource.cpp
@@ -87,7 +87,7 @@ void CXDataSource::send(const std::string& mime, CFileDescriptor fd) {
xcb_flush(g_pXWayland->m_wm->getConnection());
- //TODO: make CFileDescriptor setflags take SETFL aswell
+ //TODO: make CFileDescriptor setflags take SETFL as well
fcntl(fd.get(), F_SETFL, O_WRONLY | O_NONBLOCK);
transfer->wlFD = std::move(fd);
m_selection.transfers.emplace_back(std::move(transfer));