summaryrefslogtreecommitdiff
path: root/src/debug/HyprCtl.cpp
Commit message (Collapse)AuthorAgeFilesLines
* internal: introduce new types to avoid unsigned int rollover and signed int ↵Tom Englund2024-08-081-2/+2
| | | | | | | | | | | | | | | | | | | | overflow (#7216) * framebuffer: avoid gluint overflow GLuint was being initialized to -1 and rolling over to unsigned int max, its defined behaviour but very unnecessery. add a bool and use it for checking if allocated or not. * opengl: avoid gluint rollover -1 rolls over to unsigned int max, use 0xFF instead. * core: big uint64_t to int type conversion there were a few uint64_t to int implicit conversions overflowing int and causing UB, make all monitor/workspaces/windows use the new typedefs. also fix the various related 64 to 32 implicit conversions going around found with -Wshorten-64-to-32
* internal: some minor fd/socket cleanups and make logging thread safe (#7123)Tom Englund2024-07-311-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * bezier: dont loop on float values Using a floating-point loop variable with a fixed increment can cause precision errors over time due to the nature of floating-point arithmetic. and cause undesired effects. ex iteration 1 = 0.10000000149011611938 iteration 2 = 0.20000000298023223877 eventually.. iteration 8 = 0.80000001192092895508 iteration 9 = 0.89999997615814208984 * hyprctl: close sockets on destruction store socketpath and close the fd and unlink the socket path on exit. * eventloopmgr: close the timerfd close the timerfd on exit. * debug: make logging thread safe instead of opening and closing the logfile on each write open it on init and close it on compositor exit. also add a mutex so accidently using logging from a thread like the watchdog or similiar doesnt cause issues. * xwl: clean up fd logic check if the fd is actually opened before closing, and close the pipesource FD on exit.
* internal: refactor fullscreen states (#7104)MightyPlaza2024-07-311-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * refactor fullscreen modified: src/Compositor.cpp modified: src/Compositor.hpp modified: src/config/ConfigManager.cpp modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/LayerSurface.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/desktop/Workspace.cpp modified: src/desktop/Workspace.hpp modified: src/events/Windows.cpp modified: src/helpers/Monitor.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/DwindleLayout.hpp modified: src/layout/IHyprLayout.cpp modified: src/layout/IHyprLayout.hpp modified: src/layout/MasterLayout.cpp modified: src/layout/MasterLayout.hpp modified: src/managers/KeybindManager.cpp modified: src/managers/KeybindManager.hpp modified: src/managers/input/IdleInhibitor.cpp modified: src/managers/input/InputManager.cpp modified: src/managers/input/Swipe.cpp modified: src/protocols/ForeignToplevelWlr.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * clean up modified: src/config/ConfigManager.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.hpp modified: src/desktop/Workspace.cpp modified: src/events/Windows.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/input/Swipe.cpp * fix mapWindow fullscreen modified: src/events/Windows.cpp * fix typo modified: src/desktop/Workspace.cpp * add fullscreenstate modified: src/config/ConfigManager.cpp modified: src/events/Windows.cpp * change syncFullscreen to lower modified: src/config/ConfigManager.hpp * initialize fs state modified: src/desktop/Window.hpp
* protocols: Move globalshortcuts impl (#7102)Ikalco2024-07-301-1/+2
| | | | | | | * move global shortcuts to hyprwayland-scanner * remove wayland-scanner from deps * fix the thing
* Core: Move to aquamarine (#6608)Vaxry2024-07-211-96/+87
| | | | | | | | | | | | | | Moves Hyprland from wlroots to aquamarine for the backend. --------- Signed-off-by: Vaxry <vaxry@vaxry.net> Co-authored-by: Mihai Fufezan <mihai@fufexan.net> Co-authored-by: Jan Beich <jbeich@FreeBSD.org> Co-authored-by: vaxerski <vaxerski@users.noreply.github.com> Co-authored-by: UjinT34 <41110182+UjinT34@users.noreply.github.com> Co-authored-by: Tom Englund <tomenglund26@gmail.com> Co-authored-by: Ikalco <73481042+ikalco@users.noreply.github.com> Co-authored-by: diniamo <diniamo53@gmail.com>
* core: Improve handling of window properties (#6776)MightyPlaza2024-07-111-77/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * add mWindowProperties modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp * support int values modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp * create m_sWindowData modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/MasterLayout.cpp modified: src/managers/AnimationManager.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * simplify some properties modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/managers/KeybindManager.cpp * store multiple values in CWindowOverridableVar modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/IHyprLayout.cpp modified: src/managers/AnimationManager.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * clean up modified: src/Compositor.cpp modified: src/Compositor.hpp modified: src/config/ConfigManager.cpp modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/IHyprLayout.hpp modified: src/layout/MasterLayout.cpp modified: src/managers/KeybindManager.cpp * use SET_PROP priority for exec rules modified: src/config/ConfigManager.hpp modified: src/desktop/Window.cpp * add default value modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/IHyprLayout.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * add setprop toggle modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp * add setprop toggle modified: src/debug/HyprCtl.cpp * make window rules functional modified: src/config/ConfigManager.cpp modified: src/desktop/Window.cpp * minor fixes modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.hpp * properly clean layout data modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/IHyprLayout.hpp modified: src/layout/MasterLayout.cpp * remove newline modified: src/events/Windows.cpp * fixes modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp * use CamelCase modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/IHyprLayout.cpp modified: src/managers/AnimationManager.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp
* internal: Add functions to hyprctl header (#6745)Yusuf2024-07-071-35/+41
| | | | | | | | | | | * add functions to hyprctl header * refactor monitor json into own function and add it to header * format hyprctl.hpp * move functions to namespace * move helper functions to class
* debug: add Nvidia driver info (#6715)UjinT342024-06-301-1/+4
| | | | | * add nvidia driver info to systeminfo * check file exists
* window: expose pseudotiled state and add param to dispatcher (#6583)Przegryw3212024-06-191-15/+16
| | | | | | | * Show pseudotiled state of window in hyprctl clients * Add a window as an optional argument for the pseudo dispatcher * change formatting
* hyprctl: avoid using select()Vaxry2024-06-181-6/+11
| | | | | | move to poll() ref #6584
* hyprctl: added --follow option to rolliglog (#6325)Alexander2024-06-141-2/+49
| | | Co-authored-by: Крылов Александр <aleksandr.krylov@hyperus.team>
* binds: Add description to key binds (#6358)Moritz G2024-06-111-4/+10
| | | | | --------- Co-authored-by: Yusuf Duran <firatyusuf.d@gmail.com>
* core: move to hyprutils for utils (#6385)Vaxry2024-06-111-3/+6
| | | | | | | | | | | | | * core: move to hyprutils for utils Nix: add hyprutils dep * Meson: add hyprutils dep * flake.lock: update --------- Co-authored-by: Mihai Fufezan <mihai@fufexan.net>
* hyprctl: Allow setting name for custom/headless outputs (#6319)phonetic1122024-06-051-49/+40
|
* core: fix a few asan reported issues and a coredump on exit (#6285)Tom Englund2024-06-031-1/+6
| | | | | | | | | | | | | | | | | | * xwayland: add destructor to CXWM and free resource the wl_event_resource was running upon destruction of the compositor causing a null pointer segfault in onX11Event so ensure the event is removed upon destruction, also free the memory allocated by xcb_errors_context_new and finally call xcb_disconnect on the connection to free the fd and its memory. * hyprctl: dont leak the fd on destruction add a destructor and properly free the fd on destruction * eventloop: add destructor and free event source properly free the wl_event_source upon destruction.
* config: add tag dispacther and window rule (#6211)giskard2024-05-281-7/+18
|
* hyprctl: Make setcursor better (support XCursor themes, give fail message) ↵Ikalco2024-05-281-1/+2
| | | | | | | | | (#6097) * add support for changing to X cursor themes * use new hyprcursor abi for options * remove unneeded struct
* hyprctl: add delimiter to hyprctl batch command (#6261)Flafy2024-05-271-2/+4
| | | adds a delimiter of 3 newlines to separate different command outputs
* hyprctl: Add Config Flag to `hyprctl systeminfo` (#6160)Gabriel Ford2024-05-251-0/+9
|
* debug: Add ARM GPU info (#6212)System642024-05-231-0/+2
| | | Added a simple way to get basic info about the GPU on ARM based systems
* xdg-shell: move to new implVaxry2024-05-141-6/+6
|
* hyprctl: Add locked cmd to requests (#6042)Paul2024-05-131-0/+13
| | | Co-authored-by: Leftas <info@leftas.dev>
* config: move various cursor-related vars to cursor:Vaxry2024-05-091-1/+1
|
* Tablet: move to new implVaxry2024-05-091-12/+13
| | | | Ring and strip are not implemented. Will I implement this? God fucking knows. Nobody seems to have that anyways.
* cursor: move to a hyprland implVaxry2024-05-091-2/+2
| | | | | | | This moves wlr_cursor to a completely new impl mostly under CPointerManager Also adds beginSimple to OpenGL for simple render passes (e.g. cursor)
* xkb: check value correctly with xkb_state_layout_index_is_active() (#5925)Ikalco2024-05-071-1/+1
|
* internal: new shared_ptr and weak_ptr implementation (#5883)Vaxry2024-05-051-3/+3
| | | | | | | | | | | moves std::shared_ptrs to a new implementation Advantages: - you can dereference a weak_ptr directly. This will obviously segfault on a nullptr deref if it's expired. - this is useful to avoid the .lock() hell where we are 100% sure the pointer _should_ be valid. (and if it isn't, it should throw.) - weak_ptrs are still valid while the SP is being destroyed. - reasoning: while an object (e.g. CWindow) is being destroyed, its `weak_ptr self` should be accessible (the sp is still alive, and so is CWindow), but it's not because by stl it's already expired (to prevent resurrection) - this impl solves it differently. w_p is expired, but can still be dereferenced and used. Creating `s_p`s is not possible anymore, though. - this is useful in destructors and callbacks.
* input: Introduce basic hyprland HID classesVaxry2024-05-031-24/+29
| | | | | | Implements an intermediary HID class for mice, keyboards and touch devices, removing the old structs from WLClasses.hpp Yes, virtual ones are duplicated a bit, but will likely be de-duped once wlr_input_device is not used anymore.
* hyprctl: add missing json string escapes (#5811)Sungyoon Cho2024-04-301-8/+9
|
* hyprctl: make commits wrapped in quotes in jsonVaxry2024-04-291-1/+1
|
* core: Move /tmp/hypr to $XDG_RUNTIME_DIR/hypr (#5788)Vaxry2024-04-281-1/+1
| | | | | | Moves the directory containing sockets and logs. Also restructures lockfiles a bit. For consumers, check if `$XDG_RUNTIME_DIR/hypr` exists. If so, use it. If not, use the old `/tmp/hypr`.
* internal: Window storage rework - part 1 (#5762)Vaxry2024-04-271-21/+21
| | | | | | | | | | | | | | | | | * Window storage rework - part 1 * format * remove useless include * fix pch * format * fix crash in dwindle * fix vram leak * prefer .expired() for bool checks
* hyprctl: fix activewindow request not showing workspace name (#5623)Thomas Lindae2024-04-171-1/+1
|
* hyprctl: print monitor disabled status (#5525)JManch2024-04-101-3/+4
|
* props: Parse border color props as gradient (#5513)SoSeDiK2024-04-091-4/+18
|
* props: Allow setting per-window fullscreen opacity (#5470)SoSeDiK2024-04-071-0/+4
|
* hyprpm: add support for minimum versionsVaxry2024-04-051-2/+3
|
* Workspace/core: Refactor workspace storage (#5380)Vaxry2024-04-021-50/+33
| | | | | * refactor workspaces to use ptrs * clang-format
* hyprctl: fix plugin list on no plugins (#5357)Micovec2024-03-311-1/+4
|
* input: Add options to set tablet's active area (#5199)Khalid2024-03-231-1/+1
| | | | | | | | | * Add options to set tablet's active area * Set tablet's active area in `setTabletConfigs` * Fix formatting for new variables in ConfigManager * Report tablet's physical size with hyprctl
* config: Config error limit/hyprctl (#5165)zakk42232024-03-211-0/+25
| | | | | | | | | | | | | | | | | | | * Add error_limit to limit the number of config error messages shown in notification * Add configerrors hyprctl command * Formatting * Formatting for not my code * Use CVarList, add escapeJSONStrings * Add indication there are more undisplayed errors * Restore suppress_errors; move getErrors() to ConfigManager * Formatting, wtf * Format
* internal: Support libhyprcursor (#5009)Vaxry2024-03-091-10/+2
| | | | | | | woo --------- Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
* hyprctl: hide unmapped windows without -aVaxry2024-03-081-3/+12
|
* windowrules: Make min/maxsize rules dynamic (#4775)Epilepsy Gatherings2024-03-081-5/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * rebase * simplify and remove prop * Stuff - add back win prop - change minsize defaults - change request formatting for setprop * style fix * remove empty line * change defaults * redo string to vec * remove redundant parsing * change to vec * support commas * remove static rules * take out garbage * format * don't allow commas and resize on setprop * use isNumber
* hyprctl: Fix incorrect invalid fontsize kwarg response (#5013)ItsDrike2024-03-071-1/+1
|
* notify: Add custom fontsize support for notifications (#4981)ItsDrike2024-03-061-6/+18
| | | | | | | | | | | | | * Add custom fontsize support for notifications * Remove debug stuff * Use original default font size * Handle fontsize as keyword arg * Use CVarList::join instead of for loop * Use size_t for msgidx
* hyprctl: print format and modesVaxry2024-03-051-4/+39
| | | | fixes #4971
* hyprctl: parse custom types in getoptionVaxry2024-03-041-4/+5
|
* config: improve config value infrastructureVaxry2024-03-031-2/+4
|
* keybinds: Add the 'catchall' keyword that matches all keys (#4930)Tobias Zimmermann2024-03-031-3/+5
| | | | | | | | | | | | | | | | * Add the 'catchall' keyword that matches all keys This keyword can be used to define arbitrary keybinds. The only special behavior that it exhibits is that it matches every key, including modifier keys. Any flags still apply normally. This commit also fixes an issue that keys bound via the code:KEYCODE format were not unbound correctly. * Disallow catchall keybinds outside of submaps A catchall keybind outside a submap would prevent essentially all key events from going through to applications and would be difficult to remove again.