[Kde-imaging] [Bug 205406] Javascript scaling of images in HTML export

Pieter Edelman p.edelman at gmx.net
Tue Sep 8 20:53:18 CEST 2009


--- Comment #2 from Pieter Edelman <p edelman gmx net>  2009-09-08 20:53:15 ---
Created an attachment (id=36799)
 --> (http://bugs.kde.org/attachment.cgi?id=36799)
Javascript functions to scale the photo

Ok, thanks for the suggestion. Here's the JavaScript file. To use it, the theme
author has to do the following:
- The main image needs to get an id of "mainImg".
- The main image needs to set scalePhoto() as its onLoad handler.
- The height property should be removed from the main image.
- Ideally, the main image needs to set its width to 100% (so that it also
produces a reasonable result when the script doesn't work).

So a typical declaration for the main image in the HTML file would be: <img
src="photo.jpeg" id="mainImg" width="100%" onLoad="scalePhoto()">

That's all.

Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the Kde-imaging mailing list