PDA

View Full Version : Problem with Image frame sizing



Miserere
August 15th, 2008, 00:03
I'm about to run a Cthulhu campaign, and a big part of the visual appeal will be having portraits of the npcs they meet. I've been scanning portraits in from a bunch of sourcebooks, but I'm running into a problem.

The portraits are rectangular in shape, with a height to width ratio of about 1.5 to 1. When I view these portraits in Fantasy Grounds I'm getting very strange result with its choice of frame. For some the frame is perfect for the image and the entire picture is viewable with no scrolling. For others I'm getting a roughly square frame, which requires scrolling to see the entire image. Obviously, you don't want scrolling when you're just viewing a portrait of someone. Mind you, this happens with images of EXACTLTY the same dimensions (in this case 251 x 170 pixels) - one will show beautifully while the other gets the scrolling treatment.

Does anyone understand the logic behind the image sizing, or written more intelligent code for viewing images? There is no way that a 251 x 170 image should EVER require scrolling, so something is mucked up somewhere.

Thanks for looking.

Sorontar
August 15th, 2008, 00:27
If you ctrl+drag the window into a rectangle they should be viewed correctly.

Foen
August 15th, 2008, 06:53
I think the reason for the strange behaviour may be something to do with the campaign registry. It stores window sizes between sessions and 'remebers' the wrong size if you delete one image and replace with one of different dimensions.

If you have no combat tracker data stored (or don't mind losing it), then you could try deleting the campaign registry file and seeing if that helps.

Foen

Griogre
August 15th, 2008, 10:34
Wierd frame sizes can also be an off shoot of replacing images with the exact same name but were a different size. A frame size is remembered so if you add an image to FG then don't like the looks and edit the size of the image and don't change the name - the new image will have the old ones frame.

Foen
August 15th, 2008, 11:26
I think that's what I meant - I just got it wrong!

Griogre
August 15th, 2008, 23:29
Nah, you got it right. If you dump the campaign registery it resets all these values - plus puts all those "offscreen" popups back on the screen. :)

Bidmaron
August 17th, 2008, 03:04
What do you mean 'dumping the registry?'

Griogre
August 17th, 2008, 04:09
Each FG campaign has a CampaignRegistry.lua file. This file "remembers" the settings of FG's windows, their position ect. If you delete this file it will reset all these values back to their defaults. However, it also does hold the combat tracker information so if you are in the middle of a fight you don't want to delete this because it will clear the combat tracker also.

Miserere
August 31st, 2008, 02:52
Thanks for the advice - it worked like a charm!