! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Genmon + script with icon makes my panel a little bigger then it should be
Status:
RESOLVED: FIXED
Product:
Xfce4-genmon-plugin
Component:
General

Comments

Description Dieter Plaetinck 2007-08-05 18:23:47 CEST
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.5) Gecko/20070728 Firefox/2.0.0.5
Build Identifier: 

Hi, my panel is set to size 27 pixels, I think this is pretty much the default. (Although this shouldn't even matter)
The problem is, when I use a script that sets an icon (with the <img> tags) then Genmon seems to display the icon with a fixed size and this makes my panel bigger then it's configured to be.  I can decrease the font size, but I have to set it to unreadable sizes ( <5px) to somewhat "fix" the problem.  It seems like Genmon is "made" for just 1 panel size? Also it doesn't matter what the size of my icon is: even if I create an icon of 2x2 pixels, Genmon will reserve the same space for it and the problem remains.

Screenie: http://dieter.plaetinck.be/files/xfce_genmon_nagios_script.png (3rd icon from the left)

Reproducible: Always
Comment 1 Julien Devemy 2007-08-12 14:44:40 CEST
Hi,

The genmon plugin is not made for a specific panel size. You can display image with this plugin and a small panel size but you have to select a small image.

Personally, I use 38 pixels panel with 16x16 images and 8 size font.

If you want to use a smaller panel, you should use small images (8x8). I tried with a 16 pixels high panel and a 8 pixels picture (without text) and it worked.

The only "special" thing with images and genmon plugin, is that you can't minimize the panel plugin beyond a certain point. For example, with a 16x16 pixels image with no text, you can't have a panel smaller than 20 pixels.

I hope I clarified the situation.

See you,
Jujucece
Comment 2 Dieter Plaetinck 2007-08-18 18:19:31 CEST
Apparently, for me it doesn't behave the way you described.
It looks like the GTK widget that holds the icon doesn't change size, no matter the size of the icon I pick.
Here is a screenshot when using an 1x1 pixels icon:
http://users.edpnet.be/dieter/xfce_genmon_1x1_icon.png
(mouse hoovering over the icon)

I'm using Arch Linux, installed the package from the official repository (package xfce4-goodies), using Xfce 4.4.1
Comment 3 Dieter Plaetinck 2007-08-18 19:24:51 CEST
Note in the above screenshot my panel is at the top of the screen, if i put the panel at the bottom and restart xfce, the problem remains
Comment 4 Julien Devemy 2007-08-18 20:19:53 CEST
Hi,

I finally managed to reproduce the bug, I didn't notice this happened only with the <click> option.

The bug is  :
You can't decrease the panel size below the value the panel had when you add the genmon plugin (I hope my sentence is clear)

The bug can be "circumvent" if, after adding the plugin, you change the panel position (one of the 12 positions) and re-put the panel at this original position.

I think I know where the bug comes from.

I'm taking a look at that, and I'll keep you inform.

Bye,
Jujucece
Comment 5 Julien Devemy 2007-08-21 13:37:24 CEST
Created attachment 1322 
Patch for the panel-plugin/main.c file
Comment 6 Julien Devemy 2007-08-21 13:42:51 CEST
Hi,
I just make a patch to resolve the bug.
In fact, it's a stupid bug, I introduce 2 lines doing nothing useful except this bug ;)

I'll commit the change to SVN, but as this bug is not too annoying, I'll only produce a new version with the "bug 3437" feature included (in a few weeks I think).

Bye,
Jujucece
Comment 7 Florian Rivoal editbugs 2011-02-24 15:27:35 CET
was fixed a while ago.

Bug #3436

Reported by:
Dieter Plaetinck
Reported on: 2007-08-05
Last modified on: 2011-02-24

People

Assignee:
Florian Rivoal
CC List:
1 user

Version

Version:
3.2 or older
Target Milestone:
3.2 or older

Attachments

Patch for the panel-plugin/main.c file (849 bytes, patch)
2007-08-21 13:37 CEST , Julien Devemy
no flags

Additional information