export snapshot transparent?
tsj at unimelb.edu.au
Mon May 10 20:56:03 CDT 2010
You could copy the word you want to create an image of into a transparent
(non-opaque) field, resize it to fit the text (using formattedWidth and
formattedHeight), then use the import snapshot command to create an image
object. This will retain the transparency and you can do whatever you want
with it from there (e.g. Export it in whatever format or use it within Rev).
On 11/05/10 11:43 AM, "Nicolas Cueto" <niconiko at gmail.com> wrote:
> To convert into transparent images (PNG or GIF) each of the words in a
> word-list, I am thinking of using Rev's "export snapshot" thus:
> put "elephant" into tNewWordEnglish
> put adjustFieldSizeToWordLength(tNewWordEnglish) into tNewRect
> set the rect of field "exportEnglish" to tNewRect
> put tNewWordEnglish into field "exportEnglish"
> export snapshot from rect tNewRect of window tWIS to file tPath as PNG
> put "zousan" into tNewWordJapanese
> Obviously this isn't going to result in a transparent image but, is
> there a way of configuring "things" so that it might?
> Thank you.
> (And if you're wondering why export the words as images instead of
> simply relying on text-fields... to ensure young Japanese learners see
> font-wise what their teacher rather than the OS's limitations
> intended. I realize there's "revFontLoad", but long painful experience
> teaches me to not rely on how Rev and Windows-on-Japanese-PCs interact
> font-wise. Even today, despite running the latest version of Rev on
> the latest Windows OS, when coding in Rev my fingers automatically
> adjust to Rev's imaginary keyboard layout rather than the actual
> physical keyboard layout of my Japanese machine.)
> Nicolas Cueto
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription
More information about the use-livecode