How to create nicely sized thumbnails of old photos of various dimensions?

I’ve been uploading scanned old photos, and want to put thumbnails into tiddlers, linked to the full size pictures. But the thumbnails only include part of the full size photo, which looks weird. I’d like the thumbnail to show the full picture.

Here are thumbnails of 3 photos of my grandmother. The first 2 are in portrait mode. The first one should show her full length in her wedding dress. The 2nd is also in portrait, she’s sitting in a chair but you can only see her hair and hat. The 3rd is in landscape, it’s better but the bottom third of the picture is missing.
I

I’ve read https://tiddlywiki.com/#thumbnail%20Macro
and followed the information there. Here’s my code for one thumbnail

I could create separate thumbnail versions of the originals (I’ve done that previously for other purposes using an app called EasyThumbnails). I tried it with one of the 3 pictures, used the thumbnail pics as the thumbnail link but there wasn’t much improvement, a chunk of the image was still missing.

If you’re interested, the pictures were taken in 1910, before she travelled from England to India to marry my grandfather, who was serving with the British Army there. There were no photographs of the wedding, in Mumbai (but called Bombay back then).

If it were me, I would not be using the thumbnail widget.

I’d code something similar to:

\define img() <$image source={{!!title}} height=128/>

<!-- 🟠 replace the  filter in the list widget with whatever is needed for your TW instance -->
<!-- 🟠 the button widget does nothing; it is just quicker than coding HTML for side-by-side div elements -->

<$list filter= "[[https://media.istockphoto.com/id/186810881/photo/vintage-snazzy.jpg?s=612x612&w=0&k=20&c=j6G5oTDE1Aa8bgXIDGpb7wcLKjHRk3WrjFG1kCscfXA=]] [[https://www.whizzpast.com/wp-content/uploads/2015/02/4b7013dfa0ad832ae341bfc0660cf76f.jpg]]">
  <$button disabled=yes>
      <a href={{!!title}} target="_blank"><<img>></a>
      <br><span style="color:white;background-color:black;">whatever title for the picture</span>
  </$button>
</$list>

I use separate fields for images vs thumbnails. And, my thumbnail images are thumbnail versions of the original. The purpose is for quick loading when I list the photos in a table or grid.

As I mentioned above, I tried using thumbnail versions of the original, but a chunk of the image was still missing.

Thanks for that. How do I replace “https://media.istockphoto.com …” with the photo that I’ve loaded to tiddlywiki?

I’ve tried replacing "[[https://media.istockphoto.com/id/186810881/photo/vintage-snazzy.jpg?s=612x612&w=0&k=20&c=j6G5oTDE1Aa8bgXIDGpb7wcLKjHRk3WrjFG1kCscfXA=]] " with [[STA007b Hilda Stainthorp in wedding dress before travel to India 1910.jpg]] but the picture doesn’t appear.

I don’t know Html, I’ve avoided learning any type of coding since I gave up doing it professionally nearly 30 years ago.

If I can’t see your TiddlyWiki instance, I can’t test for myself the answer I would give you.

If I can’t test a suggestion, I don’t make the suggestion.

My note “<!-- 🟠 replace the filter in the list widget with whatever is needed for your TW instance -->” indicates that I don’t know what filter to give you. i.e. replace my “hard-coded” filter with those URL’s with whatever gets your tiddlers containing the pictures.

I can’t give you an answer to “what should I make for lunch” if I don’t know what is in your pantry.

The answer to the last question is usually cheese on toast (which leads to the next question, Cheddar, Wensleydale or Double Gloucester.)

I’m still new to this, my instance is only about 3 weeks old. I’ve found where to change the instance to “Public” so you can test your answer. See https://thomson-rowan-stories.tiddlyhost.com/ and look at the tiddler at the top of the table of contents called “A thumbnail test”

When I wrote the question I thought there might be a simple solution, accurately downsized thumbnails appear on many websites.

As often happens, one must pick one’s poison (the trade-off that is the lesser of many evils.)

That philosophical brain-fart brought to nobody-who-asked-for-it after a sip of an oh-so-wonderful cup o’ coffee.

If you are pretty new to TiddlyWiki, then it is probably a good idea for us to slowly iterate from something very basic towards your target solution.

Let’s make sure you understand what is going on in this code, which you can paste into a new tiddler in your TW instance:

<$image source="STA007 Hilda Stainthorp in wedding dress before travel to India 1910.jpg" height=256/>

<$image source="STA005 Hilda Stainthorp 1 about 1910 before marriage.jpg" height=256/>

<$image source="STA006 Hilda Stainthorp 2 about 1910 before marriage.jpg" height=256/>

Thanks Charlie, that code produces properly proportioned thumbnails of a good size (and if necessary I can adjust the height or width). So I suppose the next step is to incorporate the code for the thumbnail into a link to the full size photo.

Looking at your code prompted me to look again at the thumbnail link macro I used first. I created a new tiddler, called “A thumbnail test 2”, and added height parameters to the photos in portrait format, and width parameters for the landscape format. That produces results which would be adequate, but not perfect, as I can adjust the height or width to produce a thumbnail that represents a reasonable proportion of the photo.

But the thumbnail link macro has the shortcoming that I’d have to adjust the height parameter by trial and error for each photo, to produce a thumbnail that is an adequate representation of the photo.

So I’m interested to see your next step…

Silly question: do you plan on storing all of the photos in the TiddlyWiki, or do you plan on storing the photos externally ?

Having the photos stored directly in the TW has an associated cost.

Stored in the TW makes for much less management. Also, you do not need to store thumbnails AND the normal-sized pictures.

However, the size of a TW will get big quick if you plan on keeping multiple MB’s of pictures in there. When somebody opens that TW, the browser page does load everything (i.e. the entire TW), which could be slow for a super-big TW, or for folk who don’t have high-speed internet. (Once all loaded, though: everything ought to be pretty fast.)

Storing the pictures externally can involve a fair bit of work, especially if you are managing both thumbnails and the normal-sized pictures. (Just store the normal-sized pictures.)

It’s not a silly question, and I haven’t made up my mind yet. I’d realised that the TiddlyWiki was already growing - I’ve backed it up to my hard drive a couple of times and I can see it has doubled in size in 3 weeks. It may be that my local copy on the hard drive becomes the master copy and I distribute copies from there to family members on flash drives or something.

But the disadvantage of distributing copies is that they are tedious to update. If another family member has stories and photos to add, I’d need to distribute a fresh copy from time to time.

There are not only photos, but other jpegs that are scanned old documents (wills, newspaper extracts etc), but also pdfs (transcriptions of the wills, newspaper extracts, a transcription of a cassette my aunt made talking about our family in the 1980’s that was 45 minutes long, etc).

Some of these jpegs and pdfs are already attached to my family tree in Ancestry.com. That’s a subscription site, so you only get to see them if you’re logged in, or if you are another member that I’ve invited to view my tree. Why don’t I only use Ancestry? Because it’s all based on the family tree, it’s difficult to know where the interesting stories are. TiddlyWiki allows me to take an approach based on the stories of my family, and also to highlight the significant people. Another aspect is I’m in my 70’s now, at some point I will no longer be around to pay £120 per year to Ancestry, and nobody else may know it needs to be paid. So the tree will be deleted.

Although I’m no fan of “big requirements up front” (BRUF), there are some “critical” things/goals/needs/etc. that need to be ironed out.

Things like:

  • how to make the content available to your audience?
  • should that content be easy to find/view, or should it be hard to find/view ?
  • if that content should be available beyond my own expiration date (or beyond my interest in it, or beyond my ability to do the gardening of it, or something I’ll drop when I win the lottery) … who will take over?

If you are already using ancestry.com, then would it make sense to create an account all other family members can share, and could that account have strictly “view-only” privileges? And, are there one or more family members who could be your “backup gardener” ? (Even if it is just somebody who can “export” the content at ancestry.com for posterity in some other fashion?)

If, for any reason at all, TW is the way you want to go, then we still have these big “architectural/administrative” kind of questions to resolve.

All important points. I don’t want the content to be easy to find, I prefer invitation only. Thinking about who takes over leads to another question, why would a member of my wife’s family be interested in maintaining my side of the content? I may need two people to do it, one from each family. As for who that will be, relatives of my generation are of a similar age to me, so I need to involve the next generation. As for exporting the content from Ancestry, that is already dealt with, using Family Tree Maker which is installed on my laptop. I started using that years before I joined Ancestry, and it synchronises with Ancestry. I’ve kept it because I like its ways of presenting the data.

Each extra Ancestry account costs £120 pa, they don’t have a “view-only” subscription. Each family tree can be public (and read-only) or private (ie invitation only) and living people are always hidden in public trees. Mine are all public, and I have at times given full access to distant cousins who are also subscribers and researching their families. I have several trees in Ancestry, one for my family, one for my wife’s and some for recording possible family members.

If I won the lottery, I’d visit eastern Europe to investigate my great-grandfather’s origins. That would mean employing a researcher who can read old documents in Russian (in the old alphabet, which had more letters back then) and in German Gothic script.

I started looking at various ways to record family stories at the beginning of January, investigated various options, including Memory Keeper, and felt that TiddlyWiki was a good way to do it. My instance is starting to look a lot like Memory Keeper.
I expect to spend about a year preparing the information, before presenting it to the family. So I have time to work out how to make it accessible.

For my family tree TW, I’ve decided to put it on a public static web service/site.

That way, I can share the link to it with family.

Anybody with the link can access it, but nobody can find it by doing any search of the web.

I do have living relatives in the tree, but I only put birth dates for relatives who have passed away. (Just in case a malicious person does access my TW, they won’t find it useful for the purpose of identity theft.)

IF I was gathering photos and other documents, I would have them all as documents external to TW, all in some organized tree of subfolders, with links to those documents in the TW.

Any family member who wants to be able to view the TW offline, would have to download the TW and the subfolder tree with all the photos and documents.

All editing of my TW, I do with my local copy sitting on my computer. When I want to make edits/additions available, I publish the TW to my public static web service/site.

Right now, my trees (my parents and onward) have about 2,000 ancestors in all. Fun because any other family tree I’ve seen on all sides of the family, they have only focused on the male family names.

I spent some time today thinking about the way forward, and I came to the conclusion that I need to do something very similar to what you have described above.
It seems inevitable that I’ll have to pay an annual fee for storing the TW and the photos, pdfs etc.
I might divide the TW into 2 separate TWs, one for my family, one for my wife’s, with some duplication or cross referencing for parts that apply to both of us (not just in our generation - the 4th great uncle of the husband of my 1st cousin once removed is also the step-father-in-law of my wife’s 3xgreat grandfather)

Have you managed to follow your family back to France? I guess they were Bretons.

And, getting back to my original question, the solution will be different if I’m keeping the TW and photos in separate places. I’ll have to create thumbnails of the photos to include in TW, and make sure each thumbnails is limited to just a few Mb.

I haven’t paid too much attention to location details other than country of origin.

Although largely from France (anywhere on the west coast), I’ve got a handful of ancestors from England, Ireland, Scotland, Portugal, Spain, and Switzerland, and one ancestor with parents from Holland.

Combining the family trees for both my mum and dad, all of their parents have common (very far away) ancestors, with a few of those common ancestors separated by only a few generations.

Pretty interesting stuff.

I would be tempted to keep the thumbnails and original photos in close proximity, external to the TW, and on the static web server. Just to make it easier to manage thumbnails to original photos. If you have a ton of thumbnails, even those will make the the whole TW slower to load at some point for folk with slow web service.

That said, for offline viewing of TW, it could be really nice for those thumbnails to exist in the TW.