Best way to add an image to an oval graphic?

J. Landman Gay jacque at hyperactivesw.com
Wed Nov 11 11:48:37 EST 2020


Patterns are drawn from the top left so you'd need to create an image with 
the same dimensions as the oval with its content already centered. This 
will only work if the oval never changes its size.

Another way is to place the image behind the oval graphic and group them.

--
Jacqueline Landman Gay | jacque at hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
On November 11, 2020 10:22:38 AM William de Smet via use-livecode 
<use-livecode at lists.runrev.com> wrote:

> Hi Graig,
>
> I think I understand it a bit better now.
> The image I used has different dimensions than the graphic oval.
> See screenshot: https://ibb.co/0tXkLHy
>
> I could scale the image down to the same size (width) as the oval graphic
> but then I don;t get the center of the image.
> Because it is a pattern?
> Is it possible to get the center of the image in the oval graphic?
>
> LC 9.6.1
>
>
>
> greetings,
>
>
> William
>
>
>
>
> Op wo 11 nov. 2020 om 15:51 schreef Craig newman via use-livecode <
> use-livecode at lists.runrev.com>:
>
>> Hi.
>>
>> I made an oval graphic and set the backGroundPattern to the ID of a random
>> image I imported to the card. It filled the grc perfectly. Do you have a
>> screenshot of what you are seeing?
>>
>> Craig
>>
>> -----Original Message-----
>> From: use-livecode [mailto:use-livecode-bounces at lists.runrev.com] On
>> Behalf
>> Of William de Smet via use-livecode
>> Sent: Wednesday, November 11, 2020 6:38 AM
>> To: How to use LiveCode <use-livecode at lists.runrev.com>
>> Cc: William de Smet <williamdesmet at gmail.com>
>> Subject: Best way to add an image to an oval graphic?
>>
>> Hi there,
>>
>> When I set the BackgroundPattern of an graphic oval to the image ID, the
>> image is not centered inside the oval graphic.
>> What is a better way to add an image to a graphic oval (and center it?
>>
>>
>> greetings,
>>
>> William
>> _______________________________________________
>> use-livecode mailing list
>> use-livecode at lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription
>> preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
>>
>> _______________________________________________
>> use-livecode mailing list
>> use-livecode at lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your 
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode







More information about the use-livecode mailing list