Comments (6)
It worked after a clean install.
from sticky-window-snapping.
Do the following files and directories exist?
~/.local/share/kwin/scripts/sticky-window-snapping/
~/.local/share/kservices5/kwin-script-sticky-window-snapping.desktop
% tree ~/.local/share/kwin/scripts/sticky-window-snapping/
├── contents/
│ ├── code/
│ │ └── main.js
│ ├── config/
│ │ └── main.xml
│ └── ui/
│ └── config.ui
├── gpl-2.0.txt
└── metadata.desktop
You can start KWin with log output enabled:
sticky-window-snapping/kwin-with-scripting-logging.bash
Lines 1 to 3 in a65c31e
Maybe you find some helpful output. (You can adapt the
QT_LOGGING_RULES
to your needs.)
If you are not sure if the script is actually loaded, try adding a debug print at the beginning of ~/.local/share/kwin/scripts/sticky-window-snapping/contents/code/main.js
and restart KWin as shown above.
print('Hello World!');
from sticky-window-snapping.
This my folder structure:
% tree ~/.local/share/kwin/scripts/sticky-window-snapping/
├── contents
│ ├── code
│ │ ├── main.js
│ │ └── old.js
│ ├── config
│ │ └── main.xml
│ └── ui
│ └── config.ui
├── gpl-2.0.txt
└── metadata.desktop
I restarted kwin and got this message:
$ QT_LOGGING_RULES='*=false; kwin_scripting=true' exec kwin_x11 --replace
OpenGL vendor string: AMD
OpenGL renderer string: Radeon RX 580 Series (POLARIS10, DRM 3.35.0, 5.4.0-66-generic, LLVM 11.0.1)
OpenGL version string: 4.6 (Compatibility Profile) Mesa 20.3.4 - kisak-mesa PPA
OpenGL shading language version string: 4.60
Driver: RadeonSI
GPU class: Arctic Islands
OpenGL version: 4.6
GLSL version: 4.60
Mesa version: 20.3.4
X server version: 1.20.9
Linux kernel version: 5.4
Requires strict binding: yes
GLSL shaders: yes
Texture NPOT support: yes
Virtual Machine: no
kwin_scripting: /home/rosostolato/.local/share/kwin/scripts/sticky-window-snapping/contents/code/main.js:38: error: enabledCurrently is not defined
from sticky-window-snapping.
So looking at the code, I saw that the enabledCurrently
variable was not defined inside the code.
So I changed it from
enabledCurrently = config.enabledUsually;
to:
var enabledCurrently = config.enabledUsually;
It's not throwing error anymore but it still doesn't work... probably that variable should be global for kwin scripts, I'm not sure.
from sticky-window-snapping.
Hmm. Strange. My KWin (5.21.1) does not complain about the missing var
. Anyways, some more var
s were already added in the current development version. Can you try if it works with that version?
https://github.com/Flupp/sticky-window-snapping/blob/master/contents/code/main.js
from sticky-window-snapping.
It did not work... I believe it has something related to my kde installation.
What happened was that I installed kde neon developer edition a couple of months ago but then when plasma 5.21.1 came out, I ran a script to switch back to the user edition. It seems that it worked but I see that I still have the beta version of kwin:
But it's weird that while I was using developer edition, sticky window was working just fine and it stopped working after I changed it, but it seems that kwin kept the same version but stopped working.
Maybe I'll need to reinstall kde neon =(
from sticky-window-snapping.
Related Issues (20)
- Across desktops... HOT 2
- Not working on plasma 5.22 beta HOT 4
- new release for plasma 5.22 HOT 6
- How to debug non-working script HOT 1
- Don't work with Force Blur HOT 2
- Configuration file not in "expected location" HOT 7
- Incompatible with nclarius/tile-gaps HOT 3
- Do not resize over lapping windows HOT 2
- Idea: Instant sticking if there's already a non-default-sized tiled window. HOT 1
- Only consider window edges that transitively touch each other
- Incompatible with KWin Wayland HOT 3
- Not working with Plasma 5.26 beta HOT 1
- Shortcuts not appearing in Global Shortcuts HOT 1
- Update for KDE Plasma 6 HOT 1
- Resizing a window to cover two screens impossible HOT 1
- resizing windows over screen edge to second monitor fails
- Not displaying blue overlay HOT 4
- Resizing from another kwin script / wmctrl HOT 1
- Ctrl + Shift + S is already reserved for “save as” HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sticky-window-snapping.