Giter VIP home page Giter VIP logo

lxpanel's People

Contributors

anubisg1 avatar brother avatar city-busz avatar crayxt avatar danwin avatar gilir avatar giuspen avatar helixbot avatar hsgg avatar ib avatar ikisham avatar jalakas avatar jnumm avatar jserv avatar juergenhoetzel avatar kbirabwa avatar knedlyk avatar lstranger avatar mbouzada avatar medicalwei avatar pcman avatar pjotr123 avatar psipika avatar reckku avatar smarquespt avatar vgezer avatar vililikku avatar wwycheuk avatar wylmer avatar zvacet avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lxpanel's Issues

Feature request: option to show "only title/no icon" on the taskbar

LXpanel has the option to show only icons (without title) on the taskbar, but it does not allow the opposite. I agree that having icons is a beautiful feature, but it is somehow distracting.

Maybe allowing the user to remove icons and leave only the title of the window on the taskbar could be an interesting feature. This looks pretty neat in tint2 and awesomewm's taskbar.

Nothing more to ask. Have a nice day guys!

LXPanel and/or the task bar plugin grows in width above the configured size.

When opening too many programs, the width of LXPanel starts to grow above the screen size.

The given behavior is observed on a two monitor configuration. The panel is attached only on the one of the monitors. Not sure whether this shows up on single monitor computers.

Also, it is not sure what is the immediate reason -- LXPanel expands itself in attempt to accommodate the wider task bar, or the task bar grows by itself and LXPanel width is simply the sum of the elements on it.

I am expecting, when the count of the open task grows, the task buttons to shrink in order to stay on the screen. In this relation it seems strange that there is an option "Maximum width of task button" while on my opinion, there should be an option "Minimum width of task button". Anyway, the task buttons never shrink and this IMHO is a misbehavior.

Also, I can try to fix this problem, but will need some directions on the source. Where to look and what is the general idea/algorithms of the panel/task bar size management.

Volume plugin: strange scroll behaviour

I experience unexpected behaviour in the volume plugin wrt mouse scrolling (lxpanel-0.10.1). No matter which direction I scroll, it decreases the volume.

I have localised the issue to lines 797--800 in plugins/volumealsa/volumealsa.c, and it stems from the incorrect assumption that a GdkEventScroll that is neither GDK_SCROLL_UP nor GDK_SCROLL_LEFT must be either GDK_SCROLL_DOWN or GDK_SCROLL_RIGHT. However, my scroll wheel generates GDK_SCROLL_SMOOTH, and in order to determine the direction one needs to consider delta_y (see https://developer.gnome.org/gdk3/stable/gdk3-Events.html#gdk-event-get-scroll-deltas). I attach a crude approximation of a patch for the issue, that at least solves the problem for me.

lxpanel-0.10.1-volume-plugin-fix-mouse-scrolling.patch.txt

NetSpeed - NetLoad plugin for lxpanel

This is a Feature Request and not an issue.
The lxpanel is great, but it is missing a "NetSpeed" plugin that is available in gnome-panel as shell extension, mate-panel as an applet and xfce4-panel as "xfce4-netload-plugin".
I'd like to ask any programmer, who is interested to create new or modify/reprogram an existing applet/plugin. Here are some existing projects for xfce4, mate and gnome panels:

https://github.com/search?q=xfce4-netload-plugin

https://github.com/search?q=mate-netspeed

https://github.com/search?q=gnome-netspeed

Thank you very much.

HiDPI: volume plugin too small

Hi, there is an issue with the volume plugin on a HiDPI monitor.
Its height is hard-coded to 140px which makes it too small to be usable:

I'm working on a fix that uses the DPI of the screen divided by 96 (the DPI assumed by GTK2) as scaling factor for the height of the slider.

LXPanel random missing apps/icons

Also posted to the LXDE Forum....

I have 2 panels - the top one just has an "Application Launch Bar" with 12 apps in it.....

Most times the panel starts up with some apps/icons missing - seemingly randomly but the bigger apps (e.g. Chromium & Thunderbird) are the most likely to be missing.

I have to do repeated calls to:
lxpanelctl restart
and eventually all apps/icons appear.

Questions:

  1. Anybody know what causes this behaviour?
  2. What checks is LXPanel running to decide that an icon cannot be displayed?
  3. Is there a record of which icons opened successfully and which could not be opened?
  4. Is there a test I can do to ensure that all apps are ready to be displayed?

Many thanks

Volume plugin does not work properly when built with gtk+3

Hi,

When lxpanel is built with gtk+3, the volumealsa plugin has two issues:

  1. Scrolling mouse wheel on the icon from lxpanel does nothing because of a missing gtk_widget_add_events(p, GDK_SCROLL_MASK).
  2. In the window of the plugin, scrolling mouse wheel only decreases the volume because the direction GDK_SCROLL_SMOOTH is not taken into account.

Best regards,

Multimonitor settings status bar missing

Hi, i would l to notice a possible bug when using lxde de with multi monitor (in my case i use 2 o 3 monitor) and configuring with arandr fine.

If i switch from 3 (or 2 ) monitor to only laptop and i have settings as screenshot below, status bar is missing, for have in normal settings i have to set monitor to 1 and later detach the additional monitor.

If i don't made this operation status bar is missing.

See screeshot below.

immagine

immagine

Maybe there is additional configuration to do ?

Thank you

lxpanel crashing

[106823:106823:0419/064914.560416:ERROR:gbm_wrapper.cc(255)] Failed to export buffer to dma_buf: No such file or directory (2)
[106823:106823:0419/064914.560480:ERROR:gbm_wrapper.cc(255)] Failed to export buffer to dma_buf: No such file or directory (2)
[106785:106785:0419/064917.635482:ERROR:CONSOLE(1)] "Error in migrateSettingsPromise: Unexpected end of JSON input", source: chrome-extension://mpognobbkildjkofajifpdfhcoklimli/background-common-bundle.js (1)
[106823:106823:0419/071530.793712:ERROR:shared_image_manager.cc(197)] SharedImageManager::ProduceSkia: Trying to Produce a Skia representation from a non-existent mailbox.
[106823:106823:0419/071530.825763:ERROR:shared_image_manager.cc(197)] SharedImageManager::ProduceSkia: Trying to Produce a Skia representation from a non-existent mailbox.
[106823:106823:0419/071530.826251:ERROR:shared_image_manager.cc(197)] SharedImageManager::ProduceSkia: Trying to Produce a Skia representation from a non-existent mailbox.
[106823:106823:0419/075625.134946:ERROR:shared_image_manager.cc(197)] SharedImageManager::ProduceSkia: Trying to Produce a Skia representation from a non-existent mailbox.
[106823:106823:0419/075625.135631:ERROR:shared_image_manager.cc(197)] SharedImageManager::ProduceSkia: Trying to Produce a Skia representation from a non-existent mailbox.
[106785:106785:0419/091824.860145:ERROR:CONSOLE(0)] "Unchecked runtime.lastError: No window with id: 300847120.", source: chrome-extension://mpognobbkildjkofajifpdfhcoklimli/browser.html (0)
[106785:106785:0419/095105.476936:ERROR:CONSOLE(1)] "Uncaught (in promise) Error: No tab with id: 300847164.", source: chrome-extension://mpognobbkildjkofajifpdfhcoklimli/bundle.js (1)
[111516:1:0419/101422.971869:ERROR:vivaldi_snapshot_page.cc(77)] empty visible content rect
[106785:111545:0419/101422.972289:ERROR:capture_page.cc(61)] no data from the renderer process
[106785:106785:0419/101423.007219:ERROR:thumbnails_api.cc(290)] Failed to capture https://www.youtube.com/feed/subscriptions
[1]    97796 segmentation fault (core dumped)  lxpanel
lxpanel  1111.16s user 235.36s system 1% cpu 27:31:16.19 total

I dont actaully want my web broswer icon to show up as youtube, or whatever its trying to do

Tooltip placement

Tooltips are mostly placed at the top of the screen instead of aside the panel. This is only present on the GTK3 build of lxpanel.

Broken system tray

Hello, everyone...

I use Debian sid with LXDE on board. After the last update I watch the broken system tray in LXDE panel. Look at this couple of screen shots.

no flag

with flag

If the screen resolution on my monitor is 1366X765 and the flag installed, there is no tray at all in the panel.

big resolution

There is the next strings in run.log file:

** (lxpanel:1025): WARNING **: 08:10:08.357: task button : X error
** (lxpanel:1025): WARNING **: 08:10:59.260: lxpanel : X error: BadWindow (invalid Window parameter)
** (lxpanel:1025): WARNING **: 08:10:59.260: lxpanel : X error: BadWindow (invalid Window parameter)
** (lxpanel:1025): WARNING **: 08:10:59.260: lxpanel : X error: BadWindow (invalid Window parameter)
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.860: GFileInfo created without standard::edit-name
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.860: file ../../../gio/gfileinfo.c: line 1743 (g_file_info_get_edit_name): should not be reached
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.860: GFileInfo created without standard::size
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.860: file ../../../gio/gfileinfo.c: line 1846 (g_file_info_get_size): should not be reached
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.860: GFileInfo created without standard::is-symlink
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.860: file ../../../gio/gfileinfo.c: line 1677 (g_file_info_get_is_symlink): should not be reached
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.861: GFileInfo created without standard::is-backup
(lxpanel:1025): GLib-GIO-CRITICAL **: 08:11:07.861: file ../../../gio/gfileinfo.c: line 1655 (g_file_info_get_is_backup): should not be reached

Before the last update everything worked fine. Any help would be wonderful!

netstatus could use updated icon names

Issue reported to debian bug tracker here.

The netstatus plugin still uses the old gnome-netstatus-* icon names. These icon names have been depricated for a very long time, and the names from the [FreeDesktop.org Icon Naming Specification] (https://specifications.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html) would be better to use. Most icon themes will have the FD.o names and not the gnome- prefixed names.

FD.o names include:

network-wired
network-wireless
network-error
network-idle
network-offline
network-receive
network-transmit
network-transmit-receive

Not part of FD.o but widely used (are in KDE's Breeze and Gnome's Adwaita icon themes):

network-wireless-signal-none
network-wireless-signal-weak
network-wireless-signal-ok
network-wireless-signal-good
network-wireless-signal-excellent

A quick grep shows where the names are used. It may be as simple as switching the icon names.

$ grep -r --exclude=\*.{po, Po, plo, Plo, gmo, svg, pot, intltool-merge-cache} gnome-netstatus-
data/Makefile.am:	images/gnome-netstatus-0-24.png \
data/Makefile.am:	images/gnome-netstatus-25-49.png \
data/Makefile.am:	images/gnome-netstatus-50-74.png \
data/Makefile.am:	images/gnome-netstatus-75-100.png \
data/Makefile.am:	images/gnome-netstatus-disconn.png \
data/Makefile.am:	images/gnome-netstatus-error.png \
data/Makefile.am:	images/gnome-netstatus-idle.png \
data/Makefile.am:	images/gnome-netstatus-rx.png \
data/Makefile.am:	images/gnome-netstatus-txrx.png \
data/Makefile.am:	images/gnome-netstatus-tx.png \
plugins/netstatus/netstatus-dialog.c:	// gnome_help_display_on_screen ("gnome-netstatus", "gnome-netstatus-props", screen, &error);
plugins/netstatus/netstatus-dialog.c:  if ((icon_info = gtk_icon_theme_lookup_icon (icon_theme, "gnome-netstatus-tx", 48, 0)))
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-disconn");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-idle");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-tx");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-rx");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-txrx");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-error");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-0-24");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-25-49");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-50-74");
plugins/netstatus/netstatus-icon.c:			      "gnome-netstatus-75-100");

Keyboard layout handler close does nothing

I have experienced issue raspberrypi-ui/rc_gui#39 on a Pi 4 with a fresh Raspbian Buster installation with LXPanel 0.10.0.

After editing the Keyboard Layout Handler settings, the new settings are not written to ~/.config/lxpanel/LXDE-pi/panels/panel after clicking the Close button on the dialog. It looks like the close button does nothing.

I have found a workaround:

  1. Edit the keyboard layout settings
  2. Close the keyboard layout settings / You don't even need to do this...
  3. Open the Panel Settings dialog
  4. Close the Panel Settings dialog
    And the keyboard layout configuration is written to the disk.
    Now the settings survive shutdown / restart, reboot etc.

Battery Monitor false alarms, yellow bargraph

I am using the most recent (to date) LXPanel version 0.10.1 with Gentoo GNU/Linux on a Lenovo laptop with a battery, model 45N1011, manufactured by LGC.

Defect (bug): the Battery Monitor panel applet continuously sends false "Battery Low" alarm notifications and the applet's bar graph is shown in yellow, in some common situations, where the following conditions apply:

  • The computer is on AC power, seated in a docking station and the battery is present.
  • The battery is nearly full of energy and computed energy level may vary from 96% to 99%.
  • No power is being drawn from the battery, so reasonably the applet shows "Power now = 0 mW".
  • The battery status (e.g. /sys/class/power_supply/BAT0/status) is fairly reported as "Not charging", and that is quite expected behavior from the embedded electronic in the battery module, since the battery is nearly full.
  • The time left if the battery was supplying power (if there was no AC power) can not be computed since the power consumption is unknown, so time left is fairly reported as "0:00".

Expected behavior:
The applet's bar graph shall be green and "Battery Low" alarms shall not appear, since there is AC power and the battery is nearly full.

Additional information:

  • The defect does not appear, if energy level is 100% and all the other conditions above hold true.
  • The defect with continuous false alarms, as described above, was not present in LXPanel version 0.10.0.

Can't find my city in weather plugin location search

Searching my city name "Shahrud" (or shahrood, or شاهرود) returns no result.

"Shahrud" on openweathermap: https://openweathermap.org/city/135423

It may be a good idea to let users set lat/long beside being able to search locations.
Also yahoo query api has been shutdown, so it would be a good idea to replace or remove it.
I'm eager to help in the debug/development. Please instruct me how to .

SEGFAULT on switching between Audio Card in volume plugin

On my Laptop I use a port replicator for external monitors and sound.
When I want to switch the Audio Card in settings of the volume plugin, lxpanels quits with segfault. Lxpanel restarts automatically and in the volume plugin is still the old Audio Card selected.

I used a fresh build of lxpanel with debug flags for backtrace

lxpanel -v
lxpanel 0.10.0
uname -srvmo
Linux 5.10.9-arch1-1 #1 SMP PREEMPT Tue, 19 Jan 2021 22:06:06 +0000 x86_64 GNU/Linux

Terminal output is

(lxpanel:20463): Gtk-CRITICAL **: 10:31:42.271: IA__gtk_tree_model_iter_nth_child: assertion 'n >= 0' failed
(lxpanel:20463): Gtk-CRITICAL **: 10:31:42.271: gtk_list_store_get_value: assertion 'VALID_ITER (iter, list_store)' failed
(lxpanel:20463): GLib-GObject-WARNING **: 10:31:42.271: ../glib/gobject/gtype.c:4268: type id '0' is invalid
(lxpanel:20463): GLib-GObject-WARNING **: 10:31:42.271: can't peek value table for type '<invalid>' which is not currently referenced

Backtrace

#0  0x00007ffff7c115e3 in gtk_tree_model_get_valist () at /usr/lib/libgtk-x11-2.0.so.0
#1  0x00007ffff7c11910 in gtk_tree_model_get () at /usr/lib/libgtk-x11-2.0.so.0
#2  0x00007ffff5421889 in channel_selector_changed (channel_selector=0x7fffffffcaf8, vol=0x5555556fbe90) at volumealsa/volumealsa.c:1106
#3  0x00007ffff75f6052 in g_closure_invoke () at /usr/lib/libgobject-2.0.so.0
#4  0x00007ffff761e9c5 in  () at /usr/lib/libgobject-2.0.so.0
#5  0x00007ffff761259d in g_signal_emit_valist () at /usr/lib/libgobject-2.0.so.0
#6  0x00007ffff7612b00 in g_signal_emit () at /usr/lib/libgobject-2.0.so.0
#7  0x00007ffff7a9d732 in  () at /usr/lib/libgtk-x11-2.0.so.0
#8  0x00007ffff7aa2f90 in gtk_combo_box_set_active () at /usr/lib/libgtk-x11-2.0.so.0
#9  0x00007ffff5421a69 in card_selector_changed (card_selector=0x7fffffffcfe0, vol=0x5555556fbe90) at volumealsa/volumealsa.c:1089
#10 0x00007ffff75f6052 in g_closure_invoke () at /usr/lib/libgobject-2.0.so.0
#11 0x00007ffff761e9c5 in  () at /usr/lib/libgobject-2.0.so.0
#12 0x00007ffff761259d in g_signal_emit_valist () at /usr/lib/libgobject-2.0.so.0
#13 0x00007ffff7612b00 in g_signal_emit () at /usr/lib/libgobject-2.0.so.0
#14 0x00007ffff7a9d732 in  () at /usr/lib/libgtk-x11-2.0.so.0
#15 0x00007ffff7aa372b in gtk_combo_box_set_active_iter () at /usr/lib/libgtk-x11-2.0.so.0
#16 0x00007ffff7aa3918 in  () at /usr/lib/libgtk-x11-2.0.so.0
#17 0x00007ffff75f6052 in g_closure_invoke () at /usr/lib/libgobject-2.0.so.0
#18 0x00007ffff761e9c5 in  () at /usr/lib/libgobject-2.0.so.0
#19 0x00007ffff761259d in g_signal_emit_valist () at /usr/lib/libgobject-2.0.so.0
#20 0x00007ffff7612b00 in g_signal_emit () at /usr/lib/libgobject-2.0.so.0
#21 0x00007ffff7c4ffa5 in gtk_widget_activate () at /usr/lib/libgtk-x11-2.0.so.0
#22 0x00007ffff7b3ede1 in gtk_menu_shell_activate_item () at /usr/lib/libgtk-x11-2.0.so.0
#23 0x00007ffff7b3f0ff in  () at /usr/lib/libgtk-x11-2.0.so.0
#24 0x00007ffff7b2c01c in  () at /usr/lib/libgtk-x11-2.0.so.0
#25 0x00007ffff75f6052 in g_closure_invoke () at /usr/lib/libgobject-2.0.so.0
#26 0x00007ffff761e3f0 in  () at /usr/lib/libgobject-2.0.so.0
#27 0x00007ffff7611bcb in g_signal_emit_valist () at /usr/lib/libgobject-2.0.so.0
#28 0x00007ffff7612b00 in g_signal_emit () at /usr/lib/libgobject-2.0.so.0
#29 0x00007ffff7c51265 in  () at /usr/lib/libgtk-x11-2.0.so.0
#30 0x00007ffff7b2a636 in gtk_propagate_event () at /usr/lib/libgtk-x11-2.0.so.0
#31 0x00007ffff7b2aaab in gtk_main_do_event () at /usr/lib/libgtk-x11-2.0.so.0
#32 0x00007ffff799932e in  () at /usr/lib/libgdk-x11-2.0.so.0
#33 0x00007ffff74ffa84 in g_main_context_dispatch () at /usr/lib/libglib-2.0.so.0
#34 0x00007ffff75539b1 in  () at /usr/lib/libglib-2.0.so.0
#35 0x00007ffff74fefd3 in g_main_loop_run () at /usr/lib/libglib-2.0.so.0
#36 0x00007ffff7b2995e in gtk_main () at /usr/lib/libgtk-x11-2.0.so.0
#37 0x0000555555561484 in main (argc=<optimized out>, argv=<optimized out>, env=0x7fffffffe268) at main.c:572

Strange offset of icons undex lxpanel-gtk3

Hi, idk if you support lxpanel-gtk3. id so.

I'm using the binary compiled here
https://launchpad.net/~mati75/+archive/ubuntu/lubuntu-testing/
And I have this strange offset in the taskbar plugin

image

It appends independently of the theme used.

That sound like a padding-left problem of the box. I thought that I could fix it inside a gtkrc file. But with gtk3, lxpanel seems to ignore the file I put in ~/.config/lxpanel/$PROFILE/gtkrc.

What would be the correct way to do this with gtk3 ?

Feature request: show panel on windows key down

I have lxpanel hidden by default. I mostly use a keyboard driven work flow. Currently to see the panel (to view the time, network load etc), I have to use the mouse.
I wish there is a key or at least a command to show the bar, for example:

lxpanelctl show

All process are lxpanels subprocess

my pstree output

sulin@DonkeyHUB:sulin :) > pstree
init─┬─ModemManager───2*[{ModemManager}]
     ├─NetworkManager───2*[{NetworkManager}]
     ├─accounts-daemon───2*[{accounts-daemon}]
     ├─agent───2*[{agent}]
     ├─at-spi-bus-laun─┬─dbus-daemon
     │                 └─3*[{at-spi-bus-laun}]
     ├─at-spi2-registr───2*[{at-spi2-registr}]
     ├─14*[busybox]
     ├─console-kit-dae───64*[{console-kit-dae}]
     ├─2*[dbus-daemon]
     ├─2*[dbus-launch]
     ├─dconf-service───2*[{dconf-service}]
     ├─elogind-daemon
     ├─gnome-terminal-─┬─bash───pstree
     │                 └─3*[{gnome-terminal-}]
     ├─gvfs-udisks2-vo───3*[{gvfs-udisks2-vo}]
     ├─gvfsd─┬─gvfsd-network───2*[{gvfsd-network}]
     │       ├─gvfsd-trash───2*[{gvfsd-trash}]
     │       └─2*[{gvfsd}]
     ├─gvfsd-metadata───2*[{gvfsd-metadata}]
     ├─light-locker───3*[{light-locker}]
     ├─lightdm─┬─Xorg───4*[{Xorg}]
     │         ├─lightdm─┬─lxsession─┬─lxclipboard
     │         │         │           ├─lxpanel─┬─Telegram───17*[{Telegram}]
     │         │         │           │         ├─firefox-bin─┬─Privileged Cont───24*[{Privileged Cont}]
     │         │         │           │         │             ├─Web Content───28*[{Web Content}]
     │         │         │           │         │             ├─Web Content───16*[{Web Content}]
     │         │         │           │         │             ├─WebExtensions───22*[{WebExtensions}]
     │         │         │           │         │             └─57*[{firefox-bin}]
     │         │         │           │         ├─gedit───4*[{gedit}]
     │         │         │           │         ├─gnome-screensho───3*[{gnome-screensho}]
     │         │         │           │         └─3*[{lxpanel}]
     │         │         │           ├─lxpolkit───2*[{lxpolkit}]
     │         │         │           ├─openbox
     │         │         │           ├─pcmanfm───2*[{pcmanfm}]
     │         │         │           ├─xscreensaver
     │         │         │           └─2*[{lxsession}]
     │         │         └─2*[{lightdm}]
     │         └─2*[{lightdm}]
     ├─login───bash
     ├─menu-cached───2*[{menu-cached}]
     ├─nm-applet───3*[{nm-applet}]
     ├─polkitd───7*[{polkitd}]
     ├─ssh-agent
     ├─supervise-daemo───dbus-daemon
     ├─2*[udevd]
     ├─udisksd───4*[{udisksd}]
     ├─wpa_supplicant
     ├─xfce4-notifyd───2*[{xfce4-notifyd}]
     └─xfconfd───2*[{xfconfd}]

kbd plugin fails to load flags when some options are set

When I set grp:alts_toggle (switching layouts by pressing both alt keys), instead of flags, the kbd plugin shows the text "GROUP" for one layout and the text "GROUP(ALTS" for the other. Hovering over the text shows the correct names in the tooltip. Adding another grp: option to my setting (such as grp:ctrl_shift_toggle) fixes this behaviour.

I had a look at the code, and I think the problem is caused in initialize_keyboard_description(). There two arrays get populated: group_names and symbol_names. I understand the group_names is the names of the 4 xkb groups (what could also be called layouts), but I'm not sure what symbol_names is for. I noticed that symbol_names is 4 elements long, but the string that is parsed to find those 4 elements has more thatn that on my machine, which uses only 2 of the 4 layouts:

$ setxkbmap -print | grep xkb_symbols
xkb_symbols   { include "pc+eu+ru(phonetic_YAZHERTY):2+inet(evdev)+group(alts_toggle):1+group(alts_toggle):2"   };

The elements are separated using '+' signs, so the count comes to 6.
With this setup, the `symbol_names' array gets filled correctly:

(gdb) p xkb->group_names
$5 = {"EurKEY (US based layout with European letters)", "Russian (phonetic, YAZHERTY)", "Unknown", "Unknown"}

But symbol_names has garbage:

(gdb) p xkb->symbol_names
$4 = {"GROUP", "GROUP(ALTS", "INET(EVDEV)", "None"}

Doing the thing, where I add another grp: option, gives the following xkb_symbols string:

pc+eu+ru(phonetic_YAZHERTY):2+inet(evdev)+group(ctrl_shift_toggle)+group(alts_toggle):1+group(alts_toggle):2

But for some reason, it gets truncated when it is read XGetAtomName() (xkb.c:179). I assume this is because the X Atom has a set length of 100 characters:

(gdb) p symbol_string
$5 = "pc+eu+ru(phonetic_YAZHERTY):2+inet(evdev)+group(ctrl_shift_toggle)+group(alts_toggle):1+group(alts_"

When that truncated string gets parsed the results are as follows:

(gdb) p xkb->group_names
$6 = {"EurKEY (US based layout with European letters)", "Russian (phonetic, YAZHERTY)", "Unknown", "Unknown"}
(gdb) p xkb->symbol_names
$7 = {"EU", "RU", "INET(EVDEV)", "GROUP(CTRL"}

group_names still has the correct contents and symbol_names, while having garbage in the last two fields, happens to have the correct contents in the first two.

Aside from trying to fit a 6-or-more-element array into a 4-element one, another problem I noticed was one added in 7dbea37. Before that commit, "group(alts_toggle)" would be turned into "group\0alts\0toggle\0" = "group" which would be recognized by the logic in xkb.c:192, that filters "pc", "inet", and "group" from the symbols string. Now however, it gets turned into "group(alts\0toggle)" = "group(alts" which is no longer caught by the code, and is probably where the garbage in symbol_names came from.

I think, that parsing xkb_symbols at all is a bad idea. A better solution for getting the short names of the layouts (EU, RU, US, etc.) is to do what setxkbmap does and use XkbRF_GetNamesProp() from X11/extensions/XKBrules.h. That function returns a struct which contains, among other things, both the layout and the variant.
A short example program:

#include <stdio.h>
#include <X11/Xlib.h>
#include <X11/XKBlib.h>
#include <X11/extensions/XKBrules.h>

int
main(void)
{
        Display *dpy;
        dpy = XOpenDisplay(NULL);
        XkbRF_VarDefsRec vd;
        XkbRF_GetNamesProp(dpy, NULL, &vd);
        puts(vd.layout);
        puts(vd.variant);
}
$ gcc -lX11 -lxkbfile test.c
$ ./a.out
eu,ru
,phonetic_YAZHERTY

Using this would be far easier and much less error prone than whatever lxpanel is currently doing.

battery monitor refresh and warning

I'm using a Lenovo T14s, running archlinux with LXDE.
lxpanel does an awesome job, thank you very much for this excellent piece of software!
My only complaint right now is that the battery monitor behaves weirdly, namely:
Whenever the power is plugged or unplugged, I get a "Battery low" warning for a few moments, regardless of how full the battery is currently. This is a bit annoying, especially when you're on an irregular power supply (like, e.g., power outlets in public transport), because you'll get warnings every few seconds. This is dangerous because you'll start ignoring these warnings and miss them when they're actually important - this has happened to me before.
Looking through the code, I was trying to figure out whether there's a way to avoid this happening. I don't really know how this works exactly, but as far as I can see, the battery monitor just reads out whatever is in the ACPI provided files, which is fair.
I suppose the real issue is with acpi and/or the hardware not providing correct numbers in the moment of plugging in or out, and I'm not sure how much can be done about that.
One "workaround" however would be to reduce the frequency at which the battery monitor checks the input, so that short fluctuations are not picked up - and let's be real: we don't need battery updates more than every minute or so.
So please take this as a feature request to add an option to manually set / override the frequency at which the monitor updates itself - or, alternatively, to add a "grace period" to the battery notification such that the warning is only displayed if the battery is below threshold for a certain number of time (5 seconds or so), to suppress "fake" notifications due to momentary fluctuations.

How to edit hide time feature

I have my lxbar with the option to hide automatically, but I want to modify the value that determines the time it hides.
2021-03-21-221737_1366x768_scrot

Memory leakage Error Message: Failed to fork (Cannot allocate memory)

Systems used:
Raspberry Pi Zero W (512 MB) running current version of Raspbian Buster (headless via VNC cloud).

That error showed up on many of my systems and is at least after some time reproducible.

After a couple of weeks running, the system becomes unreactive to any launch command from the panel. That includes Terminal and Shutdown/Reboot.
On any attempt to launch a new window I get

"Error Message Failed to fork (Cannot allocate memory) "

Since the system is not physically accessible, no way to reboot.
No way to SSL either since the system is behind a NAT with no open SSL ports.

Finally I found some interesting information and a way to unlock the situation:

VNC can send the keyb. combination ALT-SHIFT-DEL, which on Raspbian starts the Task Manager.
That worked.

With it I found that LXpanel did eat 210MB of memory!
Far much than any other process! The cache was full filled up...
It really looks like LXpanel has got a memory leakage.

It would have been a bad idea to kill that process: I would not have been able to launch anything, and could not reboot either.

Serendipitously, I found a workaround: I changed a LXpanel setting from "left" to "top" and...
bingo!

LXpanel shrinked to 20MB and became responsive again.
So I have a got workaround and my problem is solved for the time being, but you might want to address the very cause.
Maybe my observations could bring you to find the memory leakage?

If you need additional information I could built another system at home, from which I could give you a SSL access to investigate?

Regards

lxpanelctl

lxpanelctl has "refresh" command, which is available.

In following use case it does not help:

  1. Adding Application in the "/usr/share/applications/" directory;
  2. Doing no changes in the Configuration "Icon=/path/to/the/image" data. Instead making image swap in controlled environment of the Application (itself).
  3. After checking the Panel the Image is not changed.

These actions helps solve this problem:
a) making command and request to "lxpanelctl restart". It looks too resource consuming, not good.
b) doing some changes in Panel Settings. It takes extra task to do, waste of resources, no good.
c) restarting the Computer. It's not dynamic. Apps for real-time events can't be done.

This directory "/usr/share/lxpanel/images/" is no good, because of it's privileges and permissions.
Any ideas to solve simple "refresh" are appreciated.

battery monitor displays warning when disconnecting

The battery monitor mistakenly displays a "low battery" warning whenever the AC state changes (connected / disconnected).
This is not a huge issue in and of itself, but some modern laptops have a battery protection feature that will periodically disable the AC connection when fully charged in order to protect the battery.
This leads to a spam of "low battery" warnings when having a laptop connected to a docking station for an extended amount of time.
I've tried to look at the implementation for a bit, but couldn't make much sense of it.
I'm using a Lenovo ThinkPad T14s and running LXDE under archlinux.

Feaure request: Toggle Menu

lxpanel version 0.10.1-2

Can you make lxpanelctl menu toggle the menu?
So you can bind a key that pressed again hide it.

Windowlist overlaps elements

On the GTK3 port, if you open too many windows, the windowlist overlaps the other panel elements.
panel2
This leads to e.g. the systray and clock to be moved out of the window.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.