Exported images are no longer transparent

Topics related to using ToolBook for building web apps.

Exported images are no longer transparent

Postby Robert Stevenson » Sun May 31, 2020 8:59 am

All looks good pre-export as far as transparency goes but once it exports I am back to white. I find myself having to back frequently in books and change the backgrounds to white. I suspect that this is an issue with using version 9. Any quick and easy solutions?
Robert Stevenson
 
Posts: 138
Joined: Wed May 14, 2014 11:46 am

Re: Exported images are no longer transparent

Postby Clifton » Sun May 31, 2020 9:27 am

You might try UNchecking the draw direct property and see if that helps with image transparency for your bitmap images.

As a future note:
    PNG image files support smooth alpha transparency and are the preferred choice when making image backgrounds transparent. Most paint programs let you set the transparency of PNG images very easily using a "magic wand tool". (e.g.: Consider using the freely available Paint.net program.)
    Unfortunately ToolBook v9 does not support PNG images. However, PNG images are supported by all browsers and the PowerPac allows you to specify a PNG image using the function setHTMLContent(). One way to do this is to put all the PNG images in a folder of their own and mark the folder to be exported along with your book using the DHTML export tree manager. Then, for each image you want replaced with a PNG alternative:
    1. Draw a field the same size as your image.
    2. Name field the same name as your PNG image. (It is preferred to NOT use spaces in names in this case).
    3. For the on load page action on each field where a PNG image should be used add this action:
      setHTMLContent( name of self, "<img src='../pngfolder/'" & name of self & ".png' />");
    In the future, any edit to your PNG files will be automatically seen in the exported content without changing anything in ToolBook. To add an image, just copy one of your image fields, resize it and name it like the PNG file it will contain. Of course, in author mode you won't actually see the PNG image because they are not supported by native ToolBook v9.
Clifton
Site Admin
 
Posts: 732
Joined: Tue Jan 14, 2014 1:04 am


Return to Web (DHTML) Development

Who is online

Users browsing this forum: No registered users and 1 guest

cron