Your iMac should take 10.5, but it's an upgrade you'll have to purchase. Strangely, it's pretty pricey. You'll need the full retail installation, which can be found in the eBay listings [http://shop.ebay.com/i.html?_nkw=os+x+10.5+retail&_sacat=0&_trksid=p3286.m270.l1313&_odkw=os+x+10.5+upgrade&_osacat=0&bkBtn=1|here].
+
+
EDIT:
+
+
## Yep, you should be able to upgrade to Leopard just fine. It won't take the latest version, which is 10.6, but 10.5 should run normally.
+
# Provided you choose to "Upgrade" rather than erase and install, all your files should be fine.
+
# I think that all the apps you've mentioned above should work. The only kind of applications that 10.5 breaks are those that are written for OS9. Chances are, you were not using the Classic environment, so this shouldn't be a big deal.
+
+
As per where to get the discs, I'd try the solution that Ralph has given- that seems to be the cheapest way.
Your iMac should take 10.5, but it's an upgrade you'll have to purchase. Strangely, it's pretty pricey. You'll need the full retail installation, which can be found in the eBay listings [http://shop.ebay.com/i.html?_nkw=os+x+10.5+retail&_sacat=0&_trksid=p3286.m270.l1313&_odkw=os+x+10.5+upgrade&_osacat=0&bkBtn=1|here].