Jump to content
TNG Community
XerxX

New Mod: Verticalchart Photos

Recommended Posts

Merv

Hi Erik,

This is fantastic. The vertical chart has been my default chart for some time with the only slight disappointment was that there were no photos on the charts. Disappointed no more.

Thank you.

My initial observations on my site are that the photos seem to be fixed size (don't scale to vertical height) and a little off vertical center, Are there settings that I am overlooking?

cap.jpg

Share this post


Link to post
Share on other sites
Chris Lloyd

Very nice Erik - Thanks.

Share this post


Link to post
Share on other sites
XerxX

Hi Merv and Chris, I'm glad that you like it!

 

Merv, the size of the photo is set with CSS max-width and max-height like this:

max-width = box width / 3 and then subtract 6px for margins

max-height = box height - 4px for margins

The photo will be proportionally wide and high depending on which (max-width or max-height) is "reached first".

The margins are 2px except for the right margin that is 4px.

Your different top and bottom margins I guess can be fixed by increasing the box height by one or two pixels.

You set it in Admin >> Setup >> Chart Settings >> Pedigree Chart >> Vertical Chart: Box Height

 

HTH

Erik

Share this post


Link to post
Share on other sites
Merv
5 hours ago, XerxX said:

Merv, the size of the photo is set with CSS max-width and max-height like this:

max-width = box width / 3 and then subtract 6px for margins

max-height = box height - 4px for margins

Hi Erik,

When I look at the config file I can see the following

style=\"float:left; max-width:".(($width/3.5)-6)."px; max-height:".($height-8)

Should I change the code in the file to what you indicate above?

Share this post


Link to post
Share on other sites
XerxX

Ooops! Sorry Merv.

I wrote those figures from memory. What you see in the file is what I use at my site - no special mod.

If you look at the text in the two top left boxes (William and Kate) of your image above, you see the same different margins.

Did you try to modify the box height in Administration as I indicated above? I think that + or - just one or two pixels will solve your problem.

 

Best regards,

Erik

Share this post


Link to post
Share on other sites
Merv

Hi Erik,

Thanks for getting back. Yes I did increase the height value but the picture still wouldn't centre vertically. I think it may have something to do the template 8 because Graham's charts do something similar. But that's okay.

I can see myself printing these charts in future so larger images would be better for this. Making subtle changes to the code you gave me above, I have managed to achieve this. It's probably not everyone's choice of displaying the chart, but I'm happy with it.

Yes, I have your scrollbox mod installed also and it works great.

Thanks again,

cap.jpg

cap2.jpg

Share this post


Link to post
Share on other sites
jayat1familytree

Erik,  

FYI

This is working on my live site using TNG Ver 10.0.3 

THANKS!

 

Share this post


Link to post
Share on other sites
XerxX

Hi Jay. That's great! Thanks for letting us know. I'll update the Wiki page.

/Erik

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×