Easiest Thumnails Ever!

The vp_x and vp_y are the dimensions of the viewport - which I’d expect to correspond to your display resolution in most circumstances.

It gets set using the perl FVWM::Tracker::PageInfo class which reports changes in page status and returns vp_height and vp_width as per the fvwm predefined variables. (I should have called the perl vars $vp_width and $vp_height as well thinking about it). Anyway, if you want to set them manually, they should be set to your screen resolution.

However, the “failed to write descriptor” message sugests that fvmw is having dificulties sending messages to the module.

On the other hand, I appear to be getting those values from the winlist and not the page tracker - and the winlist class is largely undocumented.

I’ve got a meeting on right now, but I’ll take a look at that when I get back in tonight

OK, I changed the module to use a page info tracker. I’ve added a debug statement to print the vp values and I’ve changed the vars to vp_width and vp_height so as to be less confusing.

Try this one and see if it works better. You can enable debug with

*FvwmThumbnail: Debug 1

I tried the new version, I still do not see the functions working.
and after I set debug flag, no error is generated

I look into the .fvwm/ ( set in .fvwm2rc ) , no snapshots are generated …

interesting.

The thumbnails, assuming any are being generated, go in subdirectories of the directory given to the module. So they’d be in

${HOME}/.fvwm/Pager ${HOME}/.fvwm/Icons ${HOME}/.fvwm/BigPager

Getting no errors at all is a little strange. I’d expect at least

### DEBUG: Debug Level set to 1
I did noticet that the debug flag is case dependant (a typo - fixed in next release ;)) so if you wrote

*FvwmThumbnail: debug 1

then it wouldn’t work.

Failing that, check and see of you have this line in your module, at 317:

debug "vp: height=$vp_height, width=$vp_width\n";

I created the 3 dirs , but to no avail

yes I typed
*FvwmThumbnail : Debug 1

yes I have that 317 line
but still no debug message,

I can ssee from ps that FvwmThumbnail is running

you shouldn’t need to create them - the module does that.

This is very strange. Is it possible that an old version is being picked up from somewhere?

I checked, it is the latest version that you added the Debug 1 flag

and I did locate on my machine, this seems to be the only FvwmThumbnail on the system

nevermind, thanks a lot, I 'll see if I can add more printf’s into it and debug it when I get time :slight_smile:

I get the following error in .xsession-errors:

Use of uninitialized value in sprintf at /usr/lib/fvwm/2.5.12/FvwmThumbnail line 608.
Use of uninitialized value in sprintf at /usr/lib/fvwm/2.5.12/FvwmThumbnail line 608.
[FVWM][style_parse_and_set_window_style]: <<ERROR>> Bad style option:  Padding 170 20
Unrecognised: Debug 1			# no debug messages
/home/sabmann/.themes/Milke 2.3/gtk-2.0/gtkrc:17: Kan invoegbestand "icons/iconrc" niet vinden
art_render_invoke: no image source given
Use of uninitialized value in regexp compilation at /usr/lib/fvwm/2.5.12/FvwmThumbnail line 578.
Use of uninitialized value in sprintf at /usr/lib/fvwm/2.5.12/FvwmThumbnail line 608.
Use of uninitialized value in sprintf at /usr/lib/fvwm/2.5.12/FvwmThumbnail line 608.
art_render_invoke: no image source given
/home/sabmann/.themes/Milke 2.3/gtk-2.0/gtkrc:17: Kan invoegbestand "icons/iconrc" niet vinden

Most of the times my thumbnails just show what is behind the window, like it’s complete transparant (but it’s not:)). Sometimes the thumbnail is totally white and sometimes it shows the window but it doesn’t refresh

This is my code in fvwm2rc:

DestroyModuleConfig FvwmThumbnail: *
*FvwmThumbnail: Directory /home/sabmann/fthumb
*FvwmThumbnail: Debug 1			# no debug messages
*FvwmThumbnail: Mode Auto		# automatically take thumbs
*FvwmThumbnail: Refresh 10 
*FvwmThumbnail: Class Icons, Factor 0.2x0.2
*FvwmThumbnail: Class Icons, Command "WindowId %w WindowStyle IconOverride, Icon %i"

I also used your laptop config but that didn’t work for me (I guess it’s someting with the GenerateOn thing.

I don’t know how to fix this… help :confused:

here one firefox thumbnail is ok, but the other is transparant :question: :question:

[/img]

Looking at those error messages, there’s a bug in the skip list functionality I added last time. If you don’t specify a skip list, it seems to try and skip everything.

On that basis you shouldn’t be seeing any at all, although it might be picking up some old images from your thumbnail directory. (I must get around to implementing that clearout option to remove old images at startup).

Anyway, here’s a patched version. Try that and see if matters improve. If not, post the results and we’ll take it from there.

[edit]
Last paragraph didn’t make sense and the url didn’t work :confused:

Ok I updated your latest module file, but that didn’t fix the problem,
but I added

*FvwmThumbnail: SkipList torsmo

And now it works:) torsmo is a system resource viewer on my root, it can’t be iconified but you told me it might be something with the skiplist. So now you know you were right about the skiplist bug… I dont’ see any errors anymore so I can’t give you any debug info…

So long as it’s working for you - I’ll pin the bug down next time :slight_smile:

I found another error in the code. Seems I’m not setting the default error handler for the FVWM::Module class. That might explain why you weren’t getting errors…

There’s a new version ready for download

Latest version does indeed support mini-icon composites.

There’s documentation in the file in POD format. man perlpod for more on that.

To make it work, set a mini-cion style in your config befoer you start the module. Then specify Overlay for whatever icon classes you wish to use it.

The overlay syntax works like this:

*FvwmThumbnail: Class Icons, Factor 0.2x0.2
*FvwmThumbnail: Class Icons, Overlay +8+4
*FvwmThumbnail: Class Icons, Command "WindowId %w WindowStyle IconOverride, Icon  %i"

Gravity is hardwired to the NW and the geometry let’s you adjust the position of the mini-icon from that origin.

I reinstalled my Ubuntu system due partitioning problems, I transferred my .fvwm map to a windows partition. After reinstalling I copied my .fvwm back to my home dir, and guess what, my thumbnails aint working anymore :imp:

I installed, your module in /usr/lib/fvwm/2.5.12/ this is where all the modules are stored. I also made another Modulepath and I inserted your module too… (Both with chmod +x) I have imagemagick and perlmagick installed… what the # is wrong? are there any other dependancies??
AARGH

[FVWM][style_parse_and_set_window_style]: <<ERROR>> Bad style option:  Padding 170 20
Missing charsets in String to FontSet conversion (JISX0208.1983-0)
Missing charsets in String to FontSet conversion (JISX0208.1983-0)
art_render_invoke: no image source given
art_render_invoke: no image source given
art_render_invoke: no image source given
[FVWM][convert_charsets]: WARNING -
	Invalid byte sequence during conversion from UTF-8 to ISO-8859-1
[FVWM][convert_charsets]: WARNING -
	Invalid byte sequence during conversion from UTF-8 to ISO-8859-1
art_render_invoke: no image source given
art_render_invoke: no image source given
art_render_invoke: no image source given

Well, it uses the ImageMagick perl interface, sometimes known as Image::Magick or PerlMagick. That’s proven a little fickle on occasion, but the one that ships with ImageMagick 6.2.2 seems stable enough.

I also use the Data::Dumper module for debugging, which I didn’t think was part of the standard perl package, but it doesn’t seem to have broken anything yet. So my first thought would be to check your ImageMagick install.

I have this error, and module dont load…

[FVWM][HandleModuleInput]: <<ERROR>> Module(4) command is too big (5427753776479225171), limit is 1000
Use of uninitialized value in split at /var/users/tchak/.fvwm/modules/FvwmThumbnail line 98.
no image path at /var/users/tchak/.fvwm/modules/FvwmThumbnail line 102.
DESTROY created new reference to dead object 'FVWM::Module' during global destruction.

with some kode modifications i can get rid of line 98 and 102 errors but module still dont load…

Ok then. A couple of questions.

First, have you set an ImagePath in your config. I’ve not tested it without, so it could have unforseen side-effects.

Second, do you have any very long configuration lines for the module, possibly with lots of \ continuation lines. The buffer used by the module protocol is surprisingly small, and if you overload it, odd things happen.

I’ll try the ImagePath test myself in a bit. I just started a new job today though, so it might be later in the week before I get to it

Sory i must specify my configs :slight_smile:
Nothing exotic!

DestroyModuleConfig FvwmThumbnail: *
*FvwmThumbnail: Directory $[fvwm_tmp]
*FvwmThumbnail: Mode Auto
*FvwmThumbnail: Debug 1
*FvwmThumbnail: Refresh 0
*FvwmThumbnail: Class Icons, Factor 0.2x0.2
*FvwmThumbnail: Class Icons, Overlay +8+4
*FvwmThumbnail: Class Icons, Command "WindowId %w WindowStyle IconOverride, Icon  %i"
*FvwmThumbnail: GenerateOn raise_window
*FvwmThumbnail: DeleteOn destroy_window windowshade iconify

ImagePath $[FVWM_USERDIR]/images:+

SetEnv 	fvwm_tmp  /dev/shm  (but i trayed with some lesse "exotic" stuff)

I realy dont understand what happen :frowning:
I do my self somme perl coding but i’m not verry advanced :slight_smile:
Thank you

OK - I can duplicate that. I’ll see if I can get a fix out soonish :slight_smile: