Creating a BottomPattern from an image

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
William Jamieson
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 212
Joined: Fri Feb 01, 2013 1:31 am
Contact:

Creating a BottomPattern from an image

Post by William Jamieson » Sat Jul 12, 2014 7:24 am

I want to see what Livecode is capable of doing when it comes to modifying text in a field. I hope to be able to place a graphic or an image of a graphic behind a word in a text field.

So far i have found setting:

Code: Select all

set the textstyle of word x of field "Post Text Field" of me to "threeDBox"
And I can adjust the 3D box using this line

Code: Select all

set the bottompattern of field "Post Text Field" of me to 100
in the Library Runrev says the syntax is this
set the bottomPattern of object to {empty | patternID | imageID}
So far I have tried this

Code: Select all

set the bottompattern of field "Post Text Field" of me to img "add.png" of card "icons" of stack "resources"
This error appears:
Script compile error:
Error description: seek: expected 'file'
Any suggestions on how to use this feature properly?

Klaus
Posts: 14199
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: Creating a BottomPattern from an image

Post by Klaus » Sat Jul 12, 2014 12:55 pm

Hi William,

well, you did not supply any ID! 8)

...
put the ID of img "add.png" of card "icons" of stack "resources" into tPatternID
set the bottompattern of field "Post Text Field" of me to tPatternID
...

Best

Klaus

William Jamieson
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 212
Joined: Fri Feb 01, 2013 1:31 am
Contact:

Re: Creating a BottomPattern from an image

Post by William Jamieson » Thu Jul 17, 2014 6:19 am

Ok that must have been what I was missing. Thank you Klaus!

Post Reply