nwg-piotr / nwg-drawer Goto Github PK
View Code? Open in Web Editor NEWApplication drawer for wlroots-based Wayland compositors
License: MIT License
Application drawer for wlroots-based Wayland compositors
License: MIT License
Add an option to select the first application by default when pressing ENTER or the direction arrows after a search. Currently this scenario occurs only when launching nwg-drawer
and without having done a search.
nwg-drawer
ENTER
And
nwg-drawer
nwg-drawer
ENTER
And
nwg-drawer
Keep the current scenario.
nwg-drawer
ENTER
And
nwg-drawer
Hello. I build nwg-drawer for Ubuntu 22.04 in my PPA https://launchpad.net/~ubuntusway-dev/+archive/ubuntu/dev
But program does not run and failed with error:
INFO[0000] term: foot
INFO[0000] lang: ru_RU
INFO[0000] Config dir: /home/sunderland93/.config/nwg-drawer
INFO[0000] Found 0 pinned items
INFO[0000] Found 69 desktop files
INFO[0000] Skipped 0 duplicates; 26 .desktop entries hidden by "NoDisplay=true"
INFO[0000] Found 6 associations in /home/sunderland93/.config/nwg-drawer/preferred-apps.json
INFO[0000] Found 0 search exclusions in /home/sunderland93/.config/nwg-drawer/excluded-dirs
INFO[0000] Preferring dark theme variants
INFO[0000] Using style from /home/sunderland93/.config/nwg-drawer/drawer.css
panic: runtime error: slice bounds out of range [:117] with capacity 72
goroutine 1 [running]:
main.flowBoxButton({{0xc000023858, 0x1d}, {0xc0000174d5, 0x8}, {0xc0002c6411, 0x8}, {0xc0002de448, 0x2f}, {0xc0002a6c6c, 0x7b}, ...})
github.com/nwg-piotr/nwg-drawer/uicomponents.go:263 +0x4f5
main.setUpAppsFlowBox({0x0, 0x0, 0xc0000103e0?}, {0x0, 0x0})
github.com/nwg-piotr/nwg-drawer/uicomponents.go:203 +0x298
main.main()
github.com/nwg-piotr/nwg-drawer/main.go:469 +0x1966
Add a pattern to close nwg-drawer if the command pkill -USR1 nwg-drawer
is called and nwg-drawer is open.
nwg-drawer -r
pkill -USR1 nwg-drawer
pkill -USR1 nwg-drawer
nwg-drawer -r
pkill -USR1 nwg-drawer
pkill -USR1 nwg-drawer
The defaultStringIfBlank
function added in #20 expects the os.Getenv("TERM")
to be blank in order to return the fallback value. However, if we start the drawer from a key binding, the returned value is "linux", so this won't work.
Some apps cause the search results to have smaller icons that are offset. The ones I identified for now are Code - OSS and simplenote.
normal result:
![1694722423_grim](https://github.com/nwg-piotr/nwg-drawer/assets/98901170/e4
125ce7-2cf4-4878-85e1-0d93c2f2127b)
Could you add the --config option to point to a different folder/file?
I like to keep everything in one folder like sway or hyprland.
Then we can have different wayland desktops next to each other.
I'm using nwg-drawer 0.2.8 on NxOS 22.05.
How to reproduce
tor-
In my setup, the program just freezes and freezes my entire Sway desktop. If I hit Escape, the nwg-drawer exits and my desktop is back to normal after some time (around 10 s).
I don't know why Tor Browser in particular triggers this behavior. I have also noticed that nwg-drawer is not very responsive in general. Response to keypresses takes always takes at least half a second.
nwg-drawer output:
time="2022-08-03T23:50:40+02:00" level=info msg="term: foot"
time="2022-08-03T23:50:40+02:00" level=info msg="lang: fr_FR"
time="2022-08-03T23:50:40+02:00" level=info msg="Config dir: /home/olivier/.config/nwg-drawer"
time="2022-08-03T23:50:40+02:00" level=info msg="Copying file: /home/olivier/.config/nwg-drawer/drawer.css"
time="2022-08-03T23:50:40+02:00" level=info msg="Found 0 pinned items"
time="2022-08-03T23:50:40+02:00" level=info msg="Found 136 desktop files"
time="2022-08-03T23:50:40+02:00" level=info msg="Skipped 3 duplicates; 46 .desktop entries hidden by \"NoDisplay=true\""
time="2022-08-03T23:50:40+02:00" level=info msg="/home/olivier/.config/nwg-drawer/preferred-apps.json file not found"
time="2022-08-03T23:50:40+02:00" level=info msg="/home/olivier/.config/nwg-drawer/excluded-dirs file not found"
(nwg-drawer:2624720): dbind-WARNING **: 23:50:40.107: AT-SPI: Error retrieving accessibility bus address: org.freedesktop.DBus.Error.ServiceUnknown: The name org.a11y.Bus was not provided by any .service files
time="2022-08-03T23:50:40+02:00" level=error msg="ERROR: /home/olivier/.config/nwg-drawer/drawer.css css file not found or erroneous. Using GTK styling."
time="2022-08-03T23:50:40+02:00" level=error msg="<broken file>:1:0Failed to import: Erreur lors de l’ouverture du fichier /home/olivier/.config/nwg-drawer/drawer.css\u00a0: No such file or directory"
time="2022-08-03T23:50:40+02:00" level=warning msg="Undefined icon for "
(nwg-drawer:2624720): Gtk-WARNING **: 23:50:40.370: Found an icon but could not load it. Most likely gdk-pixbuf does not provide SVG support.
time="2022-08-03T23:50:40+02:00" level=info msg="Using XDG user dirs from /home/olivier/.config/user-dirs.dirs"
** (nwg-drawer:2624720): WARNING **: 23:50:40.431: gtk-layer-shell v0.6.0 may not work on GTK v3.24.34. If you experience crashes, check https://github.com/wmww/gtk-layer-shell/blob/master/compatibility.md
time="2022-08-03T23:50:40+02:00" level=info msg="UI created in 390 ms. Thank you for your patience."
time="2022-08-03T23:50:44+02:00" level=warning msg="Undefined icon for "
time="2022-08-03T23:50:46+02:00" level=warning msg="Undefined icon for "
time="2022-08-03T23:50:46+02:00" level=warning msg="Undefined icon for "
time="2022-08-03T23:51:08+02:00" level=warning msg="Undefined icon for "
Morning Piotr,
Unironically loving the updates we've been getting on this, but on the latest drawer update. I believe I still have default colors for it, black but slightly transparent. Its a sleek look ngl. But now it appears blue-ish and slightly transparent. I have confirmed it is selected to use preset-0, and the following is the code for that file and a screenshot of what it looks like now.
window {
background-color: rgba (20, 20, 20, 0.95);
color: #eeeeee
}
/* search entry */
entry {
background-color: rgba (0, 0, 0, 0.2)
}
button, image {
background: none;
border: none
}
button:hover {
background-color: rgba (255, 255, 255, 0.1)
}
/* in case you wanted to give category buttons a different look */
#category-button {
margin: 0 10px 0 10px
}
#pinned-box {
padding-bottom: 5px;
border-bottom: 1px dotted gray
}
#files-box {
padding: 5px;
border: 1px dotted gray;
border-radius: 15px
}
Not sure if this is caused by something I did but it shouldn't be as I haven't been making any changes in this area at all lately. Thanks for providing this great suite!
When I launch a chrome app like Stadia or Youtube Music via nwg-drawer, I get a panic error.
OS: Arch Linux x86_64
Host: 20HFCTO1WW ThinkPad T470s
Kernel: 5.13.9-arch1-1
Shell: zsh 5.8
Resolution: 1920x1080
WM: sway
Terminal: alacritty
CPU: Intel i7-7500U (4) @ 3.500GHz
GPU: Intel HD Graphics 620
Memory: 15901MiB
nwg-drawer
and nwg-drawer -o 1 -fm nautilus -ovl
)lang: fr_FR
Found 0 pinned items
Found 221 desktop files
Skipped 49 duplicates; 63 .desktop entries hidden by "NoDisplay=true"
UI created in 444 ms. Thank you for your patience.
panic: runtime error: slice bounds out of range [4:3] [recovered]
panic: closure error: unexpected panic caught: runtime error: slice bounds out of range [4:3]
Closure added at:
main.flowBoxButton at command-line-arguments/uicomponents.go:254
main.setUpAppsFlowBox at command-line-arguments/uicomponents.go:202
main.main at command-line-arguments/main.go:326
goroutine 1 [running]:
github.com/gotk3/gotk3/internal/closure.FuncStack.Panicf(0x557c20bad580, 0xc0001443c0, 0x13, 0xc000121de8, 0x3, 0x3, 0x557c20b265fd, 0x1b, 0xc00021f260, 0x1, ...)
github.com/gotk3/[email protected]/internal/closure/funcstack.go:116 +0xb1f
github.com/gotk3/gotk3/internal/closure.FuncStack.TryRepanic(0x557c20bad580, 0xc0001443c0, 0x13, 0xc000121de8, 0x3, 0x3)
github.com/gotk3/[email protected]/internal/closure/funcstack.go:134 +0xfb
panic(0x557c20bcf4c0, 0xc000148150)
runtime/panic.go:965 +0x1b9
main.launch(0xc0002aa06c, 0x66, 0x0)
command-line-arguments/tools.go:599 +0x80a
main.flowBoxButton.func1(0xc000119290, 0xc00014a5f8, 0x0)
command-line-arguments/uicomponents.go:257 +0xb0
reflect.Value.call(0x557c20bad580, 0xc0001443c0, 0x13, 0x557c20b20223, 0x4, 0xc000144b10, 0x2, 0x2, 0x16, 0x7f331effc678, ...)
reflect/value.go:476 +0x8e7
reflect.Value.Call(0x557c20bad580, 0xc0001443c0, 0x13, 0xc000144b10, 0x2, 0x2, 0xc00014a5f8, 0x16, 0x0)
reflect/value.go:337 +0xb9
github.com/gotk3/gotk3/glib.goMarshal(0x7f3314e49350, 0x7f331effc600, 0x2, 0x7f331effc660, 0x7f331effc5e0, 0x0)
github.com/gotk3/[email protected]/glib/glib.go:271 +0xb71
github.com/gotk3/gotk3/gtk._Cfunc_gtk_main()
_cgo_gotypes.go:17413 +0x3e
github.com/gotk3/gotk3/gtk.Main(...)
github.com/gotk3/[email protected]/gtk/gtk.go:1241
main.main()
command-line-arguments/main.go:363 +0x1330
As per title, this commit seems to introduce some regression on the search-by-typing functionality.
Sometimes keypresses are not registered at all, some other times, after typing one letter, the focus is grabbed by the first available entry.
This causes the second letter to be lost. A third letter is again appended to the input. Rinse and repeat.
I specified the first entry 'cause if there is no entry, the input field doesn't lose focus.
I have a nwg-drawer
process in background, and when i run the command pkill -USR1 nwg-drawer
, nwg-drawer
panic randomly.
This problem is very similar in behavior to issue #45, but the logs are different.
nwg-drawer -fm nautilus -nocats -nofs -o 1 -ovl -r
in a first terminalpkill -USR1 nwg-drawer
time="2023-02-15T23:55:10+01:00" level=info msg="Data dir: /home/gouvinb/.local/share/nwg-drawer"
time="2023-02-15T23:55:10+01:00" level=info msg="term: foot"
time="2023-02-15T23:55:10+01:00" level=info msg="lang: fr_FR"
time="2023-02-15T23:55:10+01:00" level=info msg="Config dir: /home/gouvinb/.config/nwg-drawer"
time="2023-02-15T23:55:10+01:00" level=info msg="Found 0 pinned items"
time="2023-02-15T23:55:10+01:00" level=info msg="Found 155 desktop files"
time="2023-02-15T23:55:10+01:00" level=info msg="Skipped 59 duplicates; 26 .desktop entries hidden by \"NoDisplay=true\""
time="2023-02-15T23:55:10+01:00" level=info msg="/home/gouvinb/.config/nwg-drawer/preferred-apps.json file not found"
time="2023-02-15T23:55:10+01:00" level=info msg="/home/gouvinb/.config/nwg-drawer/excluded-dirs file not found"
time="2023-02-15T23:55:10+01:00" level=info msg="Preferring dark theme variants"
time="2023-02-15T23:55:10+01:00" level=info msg="Using style from /home/gouvinb/.config/nwg-drawer/drawer.css"
time="2023-02-15T23:55:10+01:00" level=warning msg="userDirsFile /home/gouvinb/.config/user-dirs.dirs not found, using defaults"
time="2023-02-15T23:55:10+01:00" level=info msg="UI created in 259 ms. Thank you for your patience."
time="2023-02-15T23:55:38+01:00" level=info msg="env vars: []; command: '/usr/bin/slack'; args: [-s]\n"
time="2023-02-15T23:55:39+01:00" level=info msg="env vars: []; command: '/usr/bin/discord'; args: []\n"
time="2023-02-15T23:55:45+01:00" level=info msg="env vars: []; command: '/usr/bin/google-chrome-stable'; args: []\n"
**
Gtk:ERROR:../gtk/gtk/gtkimagedefinition.c:287:gtk_image_definition_unref: code should not be reached
Bail out! Gtk:ERROR:../gtk/gtk/gtkimagedefinition.c:287:gtk_image_definition_unref: code should not be reached
SIGABRT: abort
PC=0x7f9e9dc808ec m=5 sigcode=18446744073709551610
signal arrived during cgo execution
goroutine 1 [syscall]:
runtime.cgocall(0x555f61fde0e0, 0xc00012da48)
runtime/cgocall.go:158 +0x5c fp=0xc00012da20 sp=0xc00012d9e8 pc=0x555f61e467bc
github.com/gotk3/gotk3/gtk._Cfunc_gtk_main()
_cgo_gotypes.go:17432 +0x45 fp=0xc00012da48 sp=0xc00012da20 pc=0x555f61f4afa5
github.com/gotk3/gotk3/gtk.Main(...)
github.com/gotk3/[email protected]/gtk/gtk.go:1241
main.main()
./main.go:591 +0x217e fp=0xc00012df80 sp=0xc00012da48 pc=0x555f61fbcd9e
runtime.main()
runtime/proc.go:250 +0x213 fp=0xc00012dfe0 sp=0xc00012df80 pc=0x555f61e7a513
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00012dfe8 sp=0xc00012dfe0 pc=0x555f61ea7d01
goroutine 2 [force gc (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc00005efb0 sp=0xc00005ef90 pc=0x555f61e7a8d6
runtime.goparkunlock(...)
runtime/proc.go:369
runtime.forcegchelper()
runtime/proc.go:302 +0xad fp=0xc00005efe0 sp=0xc00005efb0 pc=0x555f61e7a76d
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005efe8 sp=0xc00005efe0 pc=0x555f61ea7d01
created by runtime.init.6
runtime/proc.go:290 +0x25
goroutine 3 [GC sweep wait]:
runtime.gopark(0x1?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc00005f790 sp=0xc00005f770 pc=0x555f61e7a8d6
runtime.goparkunlock(...)
runtime/proc.go:369
runtime.bgsweep(0x0?)
runtime/mgcsweep.go:297 +0xd7 fp=0xc00005f7c8 sp=0xc00005f790 pc=0x555f61e672d7
runtime.gcenable.func1()
runtime/mgc.go:178 +0x26 fp=0xc00005f7e0 sp=0xc00005f7c8 pc=0x555f61e5bf26
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005f7e8 sp=0xc00005f7e0 pc=0x555f61ea7d01
created by runtime.gcenable
runtime/mgc.go:178 +0x6b
goroutine 4 [GC scavenge wait]:
runtime.gopark(0xc000088000?, 0x555f620351b8?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc00005ff70 sp=0xc00005ff50 pc=0x555f61e7a8d6
runtime.goparkunlock(...)
runtime/proc.go:369
runtime.(*scavengerState).park(0x555f6225ad40)
runtime/mgcscavenge.go:389 +0x53 fp=0xc00005ffa0 sp=0xc00005ff70 pc=0x555f61e65333
runtime.bgscavenge(0x0?)
runtime/mgcscavenge.go:622 +0x65 fp=0xc00005ffc8 sp=0xc00005ffa0 pc=0x555f61e65925
runtime.gcenable.func2()
runtime/mgc.go:179 +0x26 fp=0xc00005ffe0 sp=0xc00005ffc8 pc=0x555f61e5bec6
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005ffe8 sp=0xc00005ffe0 pc=0x555f61ea7d01
created by runtime.gcenable
runtime/mgc.go:179 +0xaa
goroutine 5 [finalizer wait]:
runtime.gopark(0x0?, 0x555f6212de40?, 0x0?, 0x40?, 0x1000000010?)
runtime/proc.go:363 +0xd6 fp=0xc00005e628 sp=0xc00005e608 pc=0x555f61e7a8d6
runtime.goparkunlock(...)
runtime/proc.go:369
runtime.runfinq()
runtime/mfinal.go:180 +0x10f fp=0xc00005e7e0 sp=0xc00005e628 pc=0x555f61e5b02f
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005e7e8 sp=0xc00005e7e0 pc=0x555f61ea7d01
created by runtime.createfing
runtime/mfinal.go:157 +0x45
goroutine 6 [select, locked to thread]:
runtime.gopark(0xc0000607a8?, 0x2?, 0x57?, 0xac?, 0xc0000607a4?)
runtime/proc.go:363 +0xd6 fp=0xc000060618 sp=0xc0000605f8 pc=0x555f61e7a8d6
runtime.selectgo(0xc0000607a8, 0xc0000607a0, 0x0?, 0x0, 0x0?, 0x1)
runtime/select.go:328 +0x7bc fp=0xc000060758 sp=0xc000060618 pc=0x555f61e89d5c
runtime.ensureSigM.func1()
runtime/signal_unix.go:991 +0x1b4 fp=0xc0000607e0 sp=0xc000060758 pc=0x555f61e8de54
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0000607e8 sp=0xc0000607e0 pc=0x555f61ea7d01
created by runtime.ensureSigM
runtime/signal_unix.go:974 +0xbd
goroutine 18 [syscall]:
runtime.notetsleepg(0xffffffffffffffff?, 0xc00005a728?)
runtime/lock_futex.go:236 +0x34 fp=0xc00005a7a0 sp=0xc00005a768 pc=0x555f61e4e854
os/signal.signal_recv()
runtime/sigqueue.go:152 +0x2f fp=0xc00005a7c0 sp=0xc00005a7a0 pc=0x555f61ea47ef
os/signal.loop()
os/signal/signal_unix.go:23 +0x19 fp=0xc00005a7e0 sp=0xc00005a7c0 pc=0x555f61f0ed79
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005a7e8 sp=0xc00005a7e0 pc=0x555f61ea7d01
created by os/signal.Notify.func1.1
os/signal/signal.go:151 +0x2a
goroutine 19 [chan receive]:
runtime.gopark(0x555f61e46813?, 0xc000358c00?, 0xd8?, 0xae?, 0x555f00000000?)
runtime/proc.go:363 +0xd6 fp=0xc00005ae70 sp=0xc00005ae50 pc=0x555f61e7a8d6
runtime.chanrecv(0xc00008c300, 0xc00005afc0, 0x1)
runtime/chan.go:583 +0x49b fp=0xc00005af00 sp=0xc00005ae70 pc=0x555f61e4979b
runtime.chanrecv1(0x0?, 0x0?)
runtime/chan.go:442 +0x18 fp=0xc00005af28 sp=0xc00005af00 pc=0x555f61e492d8
main.main.func1()
./main.go:162 +0x55 fp=0xc00005afe0 sp=0xc00005af28 pc=0x555f61fbd7b5
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005afe8 sp=0xc00005afe0 pc=0x555f61ea7d01
created by main.main
./main.go:160 +0x22a
goroutine 34 [GC worker (idle)]:
runtime.gopark(0x555f61f9ecb8?, 0xc000110a80?, 0x80?, 0xa?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc00005b750 sp=0xc00005b730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc00005b7e0 sp=0xc00005b750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005b7e8 sp=0xc00005b7e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 7 [select]:
runtime.gopark(0xc00006cfb0?, 0x2?, 0xa8?, 0xce?, 0xc00006cf84?)
runtime/proc.go:363 +0xd6 fp=0xc00006ce10 sp=0xc00006cdf0 pc=0x555f61e7a8d6
runtime.selectgo(0xc00006cfb0, 0xc00006cf80, 0xc00006cfa0?, 0x0, 0xc0001a24c8?, 0x1)
runtime/select.go:328 +0x7bc fp=0xc00006cf50 sp=0xc00006ce10 pc=0x555f61e89d5c
main.main.func6()
./main.go:541 +0x85 fp=0xc00006cfe0 sp=0xc00006cf50 pc=0x555f61fbd405
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00006cfe8 sp=0xc00006cfe0 pc=0x555f61ea7d01
created by main.main
./main.go:539 +0x216c
goroutine 8 [chan receive]:
runtime.gopark(0xc0003e82d0?, 0xc0003d6600?, 0x0?, 0xa0?, 0xc000061728?)
runtime/proc.go:363 +0xd6 fp=0xc00006de80 sp=0xc00006de60 pc=0x555f61e7a8d6
runtime.chanrecv(0xc0003e44e0, 0x0, 0x1)
runtime/chan.go:583 +0x49b fp=0xc00006df10 sp=0xc00006de80 pc=0x555f61e4979b
runtime.chanrecv1(0xc0001123c0?, 0x0?)
runtime/chan.go:442 +0x18 fp=0xc00006df38 sp=0xc00006df10 pc=0x555f61e492d8
main.watchFiles()
./watcher.go:55 +0x139 fp=0xc00006dfe0 sp=0xc00006df38 pc=0x555f61fc9399
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00006dfe8 sp=0xc00006dfe0 pc=0x555f61ea7d01
created by main.main
./main.go:589 +0x2178
goroutine 23 [syscall]:
syscall.Syscall6(0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
syscall/syscall_linux.go:90 +0x36 fp=0xc00048fb18 sp=0xc00048fa90 pc=0x555f61edc7d6
syscall.Syscall6(0xe8, 0x12, 0xc00048fc14, 0x7, 0xffffffffffffffff, 0x0, 0x0)
<autogenerated>:1 +0x45 fp=0xc00048fb60 sp=0xc00048fb18 pc=0x555f61edcb85
golang.org/x/sys/unix.EpollWait(0x0?, {0xc00048fc14?, 0x0?, 0x0?}, 0x0?)
golang.org/x/[email protected]/unix/zsyscall_linux_amd64.go:56 +0x58 fp=0xc00048fbd0 sp=0xc00048fb60 pc=0x555f61f2e398
github.com/fsnotify/fsnotify.(*fdPoller).wait(0xc00039faa0)
github.com/fsnotify/[email protected]/inotify_poller.go:87 +0x7d fp=0xc00048fc80 sp=0xc00048fbd0 pc=0x555f61fba35d
github.com/fsnotify/fsnotify.(*Watcher).readEvents(0xc000246370)
github.com/fsnotify/[email protected]/inotify.go:193 +0x275 fp=0xc00049ffc8 sp=0xc00048fc80 pc=0x555f61fb9635
github.com/fsnotify/fsnotify.NewWatcher.func1()
github.com/fsnotify/[email protected]/inotify.go:60 +0x26 fp=0xc00049ffe0 sp=0xc00049ffc8 pc=0x555f61fb8f66
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00049ffe8 sp=0xc00049ffe0 pc=0x555f61ea7d01
created by github.com/fsnotify/fsnotify.NewWatcher
github.com/fsnotify/[email protected]/inotify.go:60 +0x1c5
goroutine 24 [select]:
runtime.gopark(0xc0000617b0?, 0x2?, 0x8?, 0xfb?, 0xc00006175c?)
runtime/proc.go:363 +0xd6 fp=0xc0000615d0 sp=0xc0000615b0 pc=0x555f61e7a8d6
runtime.selectgo(0xc0000617b0, 0xc000061758, 0xc000061710?, 0x0, 0x555f61fc93ea?, 0x1)
runtime/select.go:328 +0x7bc fp=0xc000061710 sp=0xc0000615d0 pc=0x555f61e89d5c
main.watchFiles.func1()
./watcher.go:36 +0xb5 fp=0xc0000617e0 sp=0xc000061710 pc=0x555f61fc9095
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0000617e8 sp=0xc0000617e0 pc=0x555f61ea7d01
created by main.watchFiles
./watcher.go:34 +0x12d
goroutine 9 [syscall]:
syscall.Syscall6(0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x555f6207f760?)
syscall/syscall_linux.go:90 +0x36 fp=0xc000060e18 sp=0xc000060d90 pc=0x555f61edc7d6
os.(*Process).blockUntilWaitable(0xc000025080)
os/wait_waitid.go:32 +0x87 fp=0xc000060ef0 sp=0xc000060e18 pc=0x555f61ef8167
os.(*Process).wait(0xc000025080)
os/exec_unix.go:22 +0x28 fp=0xc000060f50 sp=0xc000060ef0 pc=0x555f61ef45c8
os.(*Process).Wait(...)
os/exec.go:132
os/exec.(*Cmd).Wait(0xc000422000)
os/exec/exec.go:599 +0x4b fp=0xc000060fc8 sp=0xc000060f50 pc=0x555f61f72cab
main.launch.func1()
./tools.go:614 +0x1d fp=0xc000060fe0 sp=0xc000060fc8 pc=0x555f61fc45fd
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc000060fe8 sp=0xc000060fe0 pc=0x555f61ea7d01
created by main.launch
./tools.go:613 +0x625
goroutine 10 [syscall]:
syscall.Syscall6(0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
syscall/syscall_linux.go:90 +0x36 fp=0xc000061e18 sp=0xc000061d90 pc=0x555f61edc7d6
os.(*Process).blockUntilWaitable(0xc000025bf0)
os/wait_waitid.go:32 +0x87 fp=0xc000061ef0 sp=0xc000061e18 pc=0x555f61ef8167
os.(*Process).wait(0xc000025bf0)
os/exec_unix.go:22 +0x28 fp=0xc000061f50 sp=0xc000061ef0 pc=0x555f61ef45c8
os.(*Process).Wait(...)
os/exec.go:132
os/exec.(*Cmd).Wait(0xc000422160)
os/exec/exec.go:599 +0x4b fp=0xc000061fc8 sp=0xc000061f50 pc=0x555f61f72cab
main.launch.func1()
./tools.go:614 +0x1d fp=0xc000061fe0 sp=0xc000061fc8 pc=0x555f61fc45fd
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc000061fe8 sp=0xc000061fe0 pc=0x555f61ea7d01
created by main.launch
./tools.go:613 +0x625
goroutine 25 [syscall]:
syscall.Syscall6(0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
syscall/syscall_linux.go:90 +0x36 fp=0xc00005c618 sp=0xc00005c590 pc=0x555f61edc7d6
os.(*Process).blockUntilWaitable(0xc0004c04e0)
os/wait_waitid.go:32 +0x87 fp=0xc00005c6f0 sp=0xc00005c618 pc=0x555f61ef8167
os.(*Process).wait(0xc0004c04e0)
os/exec_unix.go:22 +0x28 fp=0xc00005c750 sp=0xc00005c6f0 pc=0x555f61ef45c8
os.(*Process).Wait(...)
os/exec.go:132
os/exec.(*Cmd).Wait(0xc0004c6000)
os/exec/exec.go:599 +0x4b fp=0xc00005c7c8 sp=0xc00005c750 pc=0x555f61f72cab
main.launch.func1()
./tools.go:614 +0x1d fp=0xc00005c7e0 sp=0xc00005c7c8 pc=0x555f61fc45fd
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005c7e8 sp=0xc00005c7e0 pc=0x555f61ea7d01
created by main.launch
./tools.go:613 +0x625
goroutine 26 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc00005cf50 sp=0xc00005cf30 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc00005cfe0 sp=0xc00005cf50 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005cfe8 sp=0xc00005cfe0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 35 [GC worker (idle)]:
runtime.gopark(0x555f62130e00?, 0xc00005bfa8?, 0x5d?, 0x70?, 0x555f6212fe38?)
runtime/proc.go:363 +0xd6 fp=0xc00005bf50 sp=0xc00005bf30 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc00005bfe0 sp=0xc00005bf50 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005bfe8 sp=0xc00005bfe0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 36 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001da750 sp=0xc0001da730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001da7e0 sp=0xc0001da750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001da7e8 sp=0xc0001da7e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 50 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d6750 sp=0xc0001d6730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d67e0 sp=0xc0001d6750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d67e8 sp=0xc0001d67e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 51 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d6f50 sp=0xc0001d6f30 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d6fe0 sp=0xc0001d6f50 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d6fe8 sp=0xc0001d6fe0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 52 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d7750 sp=0xc0001d7730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d77e0 sp=0xc0001d7750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d77e8 sp=0xc0001d77e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 53 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d7f50 sp=0xc0001d7f30 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d7fe0 sp=0xc0001d7f50 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d7fe8 sp=0xc0001d7fe0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 54 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d8750 sp=0xc0001d8730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d87e0 sp=0xc0001d8750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d87e8 sp=0xc0001d87e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 55 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d8f50 sp=0xc0001d8f30 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d8fe0 sp=0xc0001d8f50 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d8fe8 sp=0xc0001d8fe0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 56 [GC worker (idle)]:
runtime.gopark(0x0?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d9750 sp=0xc0001d9730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d97e0 sp=0xc0001d9750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d97e8 sp=0xc0001d97e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 27 [GC worker (idle)]:
runtime.gopark(0x2b50aff075?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc00005d750 sp=0xc00005d730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc00005d7e0 sp=0xc00005d750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc00005d7e8 sp=0xc00005d7e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 57 [GC worker (idle)]:
runtime.gopark(0x2b50ae04fd?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001d9f50 sp=0xc0001d9f30 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001d9fe0 sp=0xc0001d9f50 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001d9fe8 sp=0xc0001d9fe0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 37 [GC worker (idle)]:
runtime.gopark(0x555f6228a6c0?, 0x1?, 0x17?, 0x6c?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001daf50 sp=0xc0001daf30 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001dafe0 sp=0xc0001daf50 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001dafe8 sp=0xc0001dafe0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 38 [GC worker (idle)]:
runtime.gopark(0x2b50afdf7e?, 0x0?, 0x0?, 0x0?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc0001db750 sp=0xc0001db730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0001db7e0 sp=0xc0001db750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0001db7e8 sp=0xc0001db7e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
goroutine 58 [GC worker (idle)]:
runtime.gopark(0x555f6228a6c0?, 0x1?, 0x99?, 0x46?, 0x0?)
runtime/proc.go:363 +0xd6 fp=0xc000508750 sp=0xc000508730 pc=0x555f61e7a8d6
runtime.gcBgMarkWorker()
runtime/mgc.go:1235 +0xf1 fp=0xc0005087e0 sp=0xc000508750 pc=0x555f61e5e091
runtime.goexit()
runtime/asm_amd64.s:1594 +0x1 fp=0xc0005087e8 sp=0xc0005087e0 pc=0x555f61ea7d01
created by runtime.gcBgMarkStartWorkers
runtime/mgc.go:1159 +0x25
rax 0x0
rbx 0x879
rcx 0x7f9e9dc808ec
rdx 0x6
rdi 0x873
rsi 0x879
rbp 0x7f9e715eb6c0
rsp 0x7f9e715e8a40
r8 0x7f9e600dd360
r9 0x0
r10 0x8
r11 0x246
r12 0x7f9e9dfa4de0
r13 0x6
r14 0x7f9e715e8b50
r15 0x7f9e600faec0
rip 0x7f9e9dc808ec
rflags 0x246
cs 0x33
fs 0x0
gs 0x0
I have a nwg-drawer
process in background, and when i run the command pkill -USR1 nwg-drawer
, nwg-drawer
panic.
nwg-drawer -fm nautilus -nocats -nofs -o 1 -ovl -r
in a first terminalpkill -USR1 nwg-drawer
INFO[0000] term: foot-direct
INFO[0000] lang: fr_FR
INFO[0000] Config dir: /home/gouvinb/.config/nwg-drawer
INFO[0000] Found 0 pinned items
INFO[0000] Found 279 desktop files
INFO[0000] Skipped 86 duplicates; 73 .desktop entries hidden by "NoDisplay=true"
INFO[0000] /home/gouvinb/.config/nwg-drawer/preferred-apps.json file not found
INFO[0000] /home/gouvinb/.config/nwg-drawer/excluded-dirs file not found
(nwg-drawer:30966): Gtk-WARNING **: 09:20:51.269: Unknown key gtk-monospace-font-name in /home/gouvinb/.config/gtk-3.0/settings.ini
INFO[0000] Using style from /home/gouvinb/.config/nwg-drawer/drawer.css
WARN[0000] Undefined icon for XDvi
INFO[0000] Using XDG user dirs from /home/gouvinb/.config/user-dirs.dirs
** (nwg-drawer:30966): WARNING **: 09:20:51.909: gtk-layer-shell v0.6.0 may not work on GTK v3.24.31. If you experience crashes, check https://github.com/wmww/gtk-layer-shell/blob/master/compatibility.md
INFO[0000] UI created in 807 ms. Thank you for your patience.
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x55cd4496c7e4]
goroutine 1 [running]:
main.main.func6()
./main.go:498 +0x64
reflect.Value.call({0x55cd44a25e60, 0xc0000d5490, 0xc0001cd7e0}, {0x55cd449a4250, 0x4}, {0x0, 0x0, 0xc000080400})
reflect/value.go:556 +0x845
reflect.Value.Call({0x55cd44a25e60, 0xc0000d5490, 0x81}, {0x0, 0x0, 0x0})
reflect/value.go:339 +0xc5
github.com/gotk3/gotk3/glib.sourceFunc(0xc0000001a0)
github.com/gotk3/[email protected]/glib/glib.go:324 +0xb2
github.com/gotk3/gotk3/gtk._Cfunc_gtk_main()
_cgo_gotypes.go:17413 +0x45
github.com/gotk3/gotk3/gtk.Main(...)
github.com/gotk3/[email protected]/gtk/gtk.go:1241
main.main()
./main.go:531 +0x1b05
Is it possible to add filters to nwg-drawer?
Example: I would like to create a key bind to open a menu that only displays Games application.
In nwggrid
I do this by a different feature. There I can select the source folder for the .desktop
files. To be honest this is not always exactly what I am looking for since I have to manually maintain all the desktop files. But it is also a good feature to have, for example using it I can not display some useless shortcut that is automatically create under /usr/share/applications
.
Wish everyone a Merry Christmas :-)
When swiping up/down on a touchscreen enabled device the drawer does scroll down while the scrolling action is in progress but immediately exits upon lifting the finger from the touchscreen.
Essentially, at the point where the pointer is at the end of the touch action a mouse click is done, which either opens the app the pointer is on or quits the drawer.
Steps to reproduce the behavior:
A swiping action should not result in a mouse click.
I realize this might be difficult to reproduce without a touch device so i'd happily help to debug this if you are interested in making this work on a touchscreen.
Incidentally, the nwggrid
works as expected
go version go1.17.5 linux/amd64
gtk-layer-shell 0.6.0-1
$ nwg-drawer -d
INFO[0000] term: xterm-kitty
INFO[0000] lang: en_US
INFO[0000] Config dir: /home/user/.config/nwg-drawer
INFO[0000] Found 0 pinned items
INFO[0000] Found 89 desktop files
INFO[0000] Skipped 0 duplicates; 23 .desktop entries hidden by "NoDisplay=true"
INFO[0000] /home/user/.config/nwg-drawer/preferred-apps.json file not found
INFO[0000] /home/user/.config/nwg-drawer/excluded-dirs file not found
INFO[0000] Using style from /home/user/.config/nwg-drawer/drawer.css
WARN[0000] Undefined icon for XDvi
WARN[0000] /home/user/.config/user-dirs.dirs file not found, using defaults
** (nwg-drawer:148169): WARNING **: 23:04:00.285: gtk-layer-shell v0.6.0 may not work on GTK v3.24.31. If you experience crashes, check https://github.com/wmww/gtk-layer-shell/blob/master/compatibility.md
INFO[0000] UI created in 423 ms. Thank you for your patience.
ERRO[0000] ERROR%!(EXTRA syscall.Errno=no such file or directory)
I most likely start the same application. e.g when I want to run nautilus
I search for files
. As I also have FileZilla
installed it's sorted before nautilus.
I wonder if it makes sense to count how often an application was launched and prefer sorting the applications this way. So you don't need to do additional navigation in case there are multiple matches.
I love this new launcher, a huge improvement to nwggrid! I love the fact that it works with my GTK theme, so I don't need to use hacks to make it work in light mode :)
I see in your screenshots that you have icons for the categories, how do I add those? I'm guessing they should be provided by the GTK theme?
As per the title, applications are not detached from the launcher process when the drawer instance is resident.
Normally this goes unnoticed, but if SIGKILL is sent to the launcher, all child processes are terminated as well.
Probably related, in the screenshot it's also possible to notice gimp as a zombie process; this happened after quitting gimp.
It would be better instead if processes were left to the init system to handle, similarly as it happens when a standalone instance of the drawer executes an app, then quits.
Hello. Running nwg-drawer on Ubuntu Arm 64 (on Raspberry Pi) gives an error:
cannot execute binary file: Exec format error
Is nwg-drawer x86-only?
Commands with spaces (in file names for example) won't run no matter what.
Suppose I want to run the following command
retroarch Chrono Trigger.smc
In which "Chrono Trigger.smc" is the name of the file. In standard bash we can express the middle space by two different ways (that I know of):
retroarch Chrono\ Trigger.smc
retroarch "Chrono Trigger.smc"
Ideally they would both work in nwg-drawer
but it seems that none of these does.
I tried to go through the source code but couldn't find a clear path to fix it.
First thank you for making so many great tools. I am using SwayWM on Arch and nwg-drawer is exactly what I am looking for.
I have installed nwg-drawer on two of my machines, both have same set up (Arch+Sway). However, on my laptop (thinkpad), nwg-drawer does not have any categories, other than "All". On the other machine (thinkcentre), all categories (including icons) showed up correctly.
I checked /usr/share/nwg-drawer
and I do have all the necessary files in the desktop-directories
directory. On both machines, I use default settings without any modification.
I also noticed that on thinkcentre, nwg-drawer automatically copies drawer.css
to my local config folder, even after I try to delete it. This was not the case on my thinkpad.
All packages are latest., installed from official repo.
The only difference I can think of is that Thinkcentre used to have Gnome installed, and then I uninstalled it to switch to Sway. On Thinkpad, I started fresh with Sway. I wonder if there is any on Gnome that made nwg-drawer categories working properly?
Thank you!
There is a blank app on my pinned bar. I do not see this app in my "All applications". This happend when I installed Terraria twice by accident the other day. I pinned both of the Tarraria's .desktop icons to the pinned bar, then I noticed that there was two. So I uninstalled 1 of the apps, and their .desktop file, but for some reason, the pinned icon was still there, I tried right clicking it to unpin, it doesn't work. I tried reinstalling nwg-drawer, doesn't work. I also tried completly removing the /usr/share/application folder, all my icons were gone except the pinned blank icon.
Also installed nwg-menu, the blank icon is there.
Here are my Specs
stampixel@overdose
.%;888:8898898: ------------------
x;XxXB%89b8:b8%b88: OS: Garuda Linux x86_64
.8Xxd 8X:. Host: ASUSTeK COMPUTER INC. UX434FAC
.8Xx; 8x:. Kernel: 5.16.16-zen1-1-zen
.tt8x .d x88; Uptime: 41 mins
.@8x8; .db: xx@; Packages: 1346 (pacman)
,tSXX° .bbbbbbbbbbbbbbbbbbbB8x@; Shell: bash 5.1.16
.SXxx bBBBBBBBBBBBBBBBBBBBbSBX8; Resolution: 1920x1080, 1080x2160
,888S pd! WM: sway
8X88/ q Theme: Nordic-darker [GTK2/3]
GBB. Icons: Tela-circle-dark [GTK2/3]
x%88 d888@8@X@X@X88X@@XX@@X@8@X. Terminal: alacritty
dxXd dB8b8b8B8B08bB88b998888b88x. Terminal Font: JetbrainsMonoNL
dxx8o .@@;. CPU: Intel i5-10210U (8) @ 4.200GHz
dx88 .t@x. GPU: Intel CometLake-U GT2 [UHD Graphi
d:SS@8ba89aa67a853Sxxad. Memory: 5088MiB / 7746MiB
.d988999889889899dd.
Message I get if i open it from nwg-menu (Since nwg-drawer doesn't do anything in the terminal if I open it)
lang: en_CA
Found 126 desktop files
Skipped 0 duplicates; 26 .desktop entries hidden by "NoDisplay=true"
Using style from /home/stampixel/.config/nwg-panel/menu-start.css
Using XDG user dirs from /home/stampixel/.config/user-dirs.dirs
** (nwg-menu:7287): WARNING **: 09:39:07.966: gtk-layer-shell v0.7.0 may not work on GTK v3.24.33. If you experience crashes, check https://github.com/wmww/gtk-layer-shell/blob/master/compatibility.md
UI created in 108 ms. Thanks for watching.
env vars: []; command: ''; args: []
Edit: I counted 100 icons in the "All application" (not including blank icon in pinned bar), so 126 icons minus 26 that are "NoDisplay" equals 100. So the logs are right.
it would be nice to have linting and testing enabled
The styling for category buttons does not work. The buttons continue to take the styling from the buttons.
nwg-drawer version 0.1.3
DRAWER.CSS
window {
background-color: rgba (36, 47, 79, 0.95);
color: #eeeeee
}
entry {
box-shadow: 0 0 6 5 #2e3440;
background-color: #3b4252;
border: none;
border-radius:10px;
}
button {
box-shadow: 0 0 6 5 #2e3440;
background-color: #3b4252;
border: none;
border-radius:5px;
margin: 4px;
}
category-button {
background-color: transparent;
padding: 1px;
}
button:hover {
background-color: rgba(129,161,193,0.7);
}
button:focus {
background-color: #5e81ac;
}
#pinned-box {
padding-bottom: 10px;
border-bottom: 1px dotted gray
}
#files-box {
padding: 10px;
border: 1px dotted gray;
}
When using the nwg-drawer in resident mode (starting the application with the -r
flag), the drawer should collect the exit status codes of all children, which is not the case and leads to a lot of zombies in the process tree. An easy fix would be to just insert a cmd.Wait()
after https://github.com/nwg-piotr/nwg-drawer/blob/main/tools.go#L586, like shown in the snipped below. But that is certainly not the optimal way to solve this problem.
cmd.Start()
go func() {
cmd.Wait()
}()
I did not understand how I can specify the icon theme, for example to use Papirus
Today I decided to update my NixOS machines so I can play Portal with RTX. However, once I rebooted into the updated system, I get this error with nwg-drawer
.
INFO[0000] Preferring dark theme variants
INFO[0000] Using style from /home/ross/.config/nwg-drawer/drawer.css
panic: runtime error: slice bounds out of range [:117] with capacity 56
goroutine 1 [running]:
main.flowBoxButton({{0xc0001b480c, 0x28}, {0xc00018f265, 0x10}, {0xc00018f265, 0x10}, {0xc000220788, 0x51}, {0xc0001ca37c, 0x97}, ...})
github.com/nwg-piotr/nwg-drawer/uicomponents.go:263 +0x4f5
main.setUpAppsFlowBox({0x0, 0x0, 0xc000300148?}, {0x0, 0x0})
github.com/nwg-piotr/nwg-drawer/uicomponents.go:203 +0x298
main.main()
github.com/nwg-piotr/nwg-drawer/main.go:469 +0x1966
The numbers mentioned in the panic aren't in my drawer.css
file. I can also try using nwg-drawer
with an empty css file and no arguments but I get the same error. I believe whatever change from 0.2.8 to 0.3.0 broke nwg-drawer. A fix would be appreciated as I don't have an easy way to open applications now.
This is less a glitch or bug I believe but my hard drive recently failed and I was without nwg for around a month. Instead of copying a snapshot over I decided to just throw together a whole fresh install. I'm still back with nwg of course lol. But now when I open the drawer, it selects the first icon in the alphabetical list is selected, where previously it selected the first application in my favorited list at the top. Is there a setting I am missing somewhere? I have been looking for any positional options but I haven't seen any yet.
Unless they are needed for some reason, build files should not be checked in the git repo so the .gitignore file should include a directive to ignore the bin folder.
After that, the already tracked bin directory shoud be removed from the repo, by using git rm.
I already added the changes in nightly-brew@7f18eee, if you would like to take a look.
I noticed that the desktop file description shown at the bottom only seems to update when the mouse hovers on an entry.
It doesn't follow the selection when navigating with keys nor when filtering with the search bar.
It would be cool if nwg-drawer would support the OnlyShowIn
and NotShowIn
from the XDG Desktop Entry specification. This would remove some unnecessary applications from the users view, making the application overall a bit more cleaner.
Hi Piotr, sorry if this is kind of a silly issue but I'm trying to figure out how to change these dotted lines to solid lines:
The default drawer.css
(https://github.com/nwg-piotr/nwg-drawer/blob/main/drawer.css) has dotted line values for pinned-box
and files-box
, but it seems these two lines in the screenshot are something else not in the file.
I poked around a bit to try and find any other version of the drawer.css
which describe more of the options that are being set, but I'll be honest I'm not really sure what I'm looking for. If they can't be changed it's no big deal, I just thought I'd ask before giving up. 😄
Thanks for taking a look,
-Jeremy
On Arch Linux, nwg-drawer version 0.1.7 installed through the AUR. Using Sway WM.
When bound to the $menu variable in Sway's config with set $menu nwg-drawer -ovl -nofs
, launching via a Sway keybind and left-clicking any category button causes nwg-drawer to crash immediately. Removing the -nofs argument allowed categories to work without issue, leading me to think the issue is related to this argument.
While running some tests I started a second wayfire session under my regular id from a linux console/tty.
In that second session I try to launch the drawer via the usual key combo and nothing happens.
So I fire up a terminal and I see this message:
INFO[0000] Showing resident instance (PID 2200)
Now I have made nwg-drawer resident so that there is no delay when I invoke it in the course of my wayfire session and It looks like a side-effect of this approach is that I can no longer invoke in it in a second wayfire session.
Is this to be expected... or is it a case of my not doing it right?
Among my wayfire session 'autostart commands' I have:
nwg-drawer -r
As to my wayfire bindings I have:
<Ctrl> <Alt> KEY_Y nwg-drawer
Not really relevant but the reason I'm doing this is that I'm trying to hunt down the applications that are not 'native-wayland-enabled' and have disabled XWayland before launching the second session (and I'm too lazy to clone my setup to another id :)
For some reason the applications I have hidden by copying the .desktop files to ~/.local/share/applications and appending NoDisplay=true are not hidden anymore in the newest update.
I was troubled by an stupid issue where I can launch other desktop entries but not the Looking Glass Client. Today I decided to investigate it.
Initially I though the desktop entry was bad but it worked with gkk-launch
. I then launch nwg-drawer
in terminal and found that it is trying to run xterm-kitty
to launch a console program (which looking-glass-client is). I then realized that nwg-drawer
uses $TERM as the default terminal, which is almost never going to give you a executable file name, since this variable denotes the terminal capabilities, not the binary itself.
Unfortunately there is no standard way to indicate the preferred default terminal, but whatever that would be, it is not gonna be $TERM, and such silent failure is confusing, as there is no error in main menu, and no graphical error message when the terminal failed to launch.
I think we could use $TERMINAL as overriding variable instead (used by i3 and suggested in another post, and actually check if this is a valid terminal and tell the user. Or show a graphical error message when the terminal failed to launch.
In my terminal i ran nwg-drawer -nofs
I then proceeded to type in firefox, which has alot of files in cache.
When i type the r in firefox nwg-drawer slows to a hault trying to get all the files to list, even though I gave the -nofs argument
I would like to configure nwg-drawer to look like it's coming out of the top of my screen. However, I see no way to change the margin of the window. Just as an example of implementation, swaync
solved this by adding "control-center-margin-bottom"
and others to an additional config.json.
Also, If this is not a feature of interest, how would I allow nwg-drawer to cover my bar (waybar)?
Currently nwg-drawer uses a lot of cpu cycles for polling the USR1 signal and file change trigger variables at a high interval: https://github.com/nwg-piotr/nwg-drawer/blob/main/main.go#L494-L529. This can be avoided by using channels and a goroutine to only execute tasks in the event loop if necessary. For example, by changing showWindowTrigger
into a channel and replacing the linked function with the following goroutine, the cpu utilization drops to 0 while not affecting the responsiveness.
go func() {
for {
< -showWindowChannel;
glib.TimeoutAdd(uint(0), func() bool {
// Insert code to show window
return false;
});
}
}()
Issue is fairly straight forward but im not finding anything I could be doing to cause this. I checked my desktop entry for thunar and nothing is out of the ordinary. If I launch from my hotkey it opens in homedir by default, which is expected behavior. Not sure how I can change this problem.
Keep up the great work, loving everything still!
as a result of the conversation in #19 I did an investigation into where time was spent during initialization.
turns out around ~80% of the time is spent on these lines.
I implemented a POC to speed up the total initialization time by around 4x. reducing the time from 520ms -> 100ish ms.
unfortunately it introduced a seg fault issue that seems related to the gtk bindings being used. (I'm assuming its due to the finalizer bugs that the binding library has in its issue tracker)
but wanted to bring this work to your attention just in case its useful.
Hi, would it be possible to specify launch settings in a config file as well?
I think it would be of help in standardizing systemd user units and xdg autostart desktop files.
Ideally, nwg-drawer could try to read something like "$XDG_CONFIG_DIR/nwg-drawer/settings" at startup.
For those use-cases where "-r" is specified, the launched instance could first try to trigger the background one, if it exists (kind of like it already does).
If no background instance is running instead, it just starts as that.
Of course, cli arguments should still have precedence over the config file, to allow overriding the default behaviour when needed.
Hello,
I'm finally coming back around to try and finish configuring and styling my launcher after a bit. I've been reading through the documentation on the entire set of nwg-launchers, as well as just nwg-drawer and -grid and am failing to see anything about how to at least identify the broken apps. Unlike most apps (even if the icon isn't right) where I can hover over the icon and at the bottom of the screen it will tell me what it is, these simply do nothing and say nothing, and I'd really like to get rid of them. I guess they were things pinned to favorites in the past. I'll include a screenshot below so you can see what I am talking about. Aside from going through the entire list of packages and seeing what matches up and what doesn't for .desktop entries vs. pacman -Q output, is there another more efficient way to figure this out specific to this package? Honestly even just resetting the entire thing and starting over would be fine too, but I am also having issues getting pacman to uninstall the packages as well, as it does not list those particular ones. It's been like a year since I started using it and I use your panel and bar too, so I think what I ended up doing was installing the entire launchers or shell package, because I also have nwg-grid and nwg-dmenu installed, along with Azote, nwg-look, and some other packages. Honestly I cannot claim to remember for sure. Any ideas to help me figure this out would be much appreciated, especially regarding where the best place to modify both the style specifically the drawer and if there is a config file that I cannot find that will let me toggle favorites, etc. I know I enabled favorites at some point, but I think I only had the packages individually installed at that point, so I'm afraid I do not remember where I did that. And no, simply right-clicking those does not make them unpin, I manually unpinned all of the favorites just to see if that would clear the field as well. This has been going on for a long time so it doesn't appear to be caused by any other app updates, etc., but I am finally trying to get around to fine tuning the launcher.
It's Monday morning and my coffee hasn't hit the back of my brain yet, so if I left something out sorry, please let me know. I probably did or am confused about how it's packaged. All help is appreciated.
Machine:
Surface 6 Pro
Arch Linux / Swayfx (all packages updated to latest a few minutes ago via pacman and yay)
Swayfx should be a fully up-to-date fork of normal Sway, swaymsg -v shows:
swaymsg version 0.3.2-19414f6 (Jul 11 2023, branch 'master')
Here is a screenshot of what the broken icons look like when the launcher is pulled up:
Here are the apps that pacman shows under nwg:
Neofetch in case it has more helpful information:
Please let me know if you need any sort of dump or whatever, and how to pull it for you if you don't mind.
Thank you for your help!
When lauching certain apps the the app doesnt launch for excample if I launch gnome-chess it will not launch if loading from sway config use either alt+f1 or the icon on the panel. If I kill all nwg-drawer applications and launch nwg-drawer from terminal it works as expected.
anyway to send a string to search from command line? would be good having a way to nwg-drawer -string-search SomeApp, then the app starts with string filled in the search already
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.