windowShape

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

windowShape

Terence Heaford-2
I have been messing about with applying windowShape and although I can get the shape to work it does not take the colour of the image.

Should it? and how do I do it please?

I have taken a screen shot of the window being used as a palette with the original image beneath.

It can be seen here:

https://dl.dropboxusercontent.com/u/98788898/LiveCode/Screen%20Shot.png

The original image is a png with alpha and shows as blue.

The palette window is grey.

How do I apply the blue colour of the image?

Thanks

Terry


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

xtalkprogrammer
Terence,

Set the visible of the image to true and position it correctly :-)

--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553

Installer Maker for LiveCode:
http://qery.us/468

Buy my new book "Programming LiveCode for the Real Beginner"
http://qery.us/3fi

LiveCode on Facebook:
https://www.facebook.com/groups/runrev/

On 7/19/2015 21:36, Terence Heaford wrote:

> I have been messing about with applying windowShape and although I can get the shape to work it does not take the colour of the image.
>
> Should it? and how do I do it please?
>
> I have taken a screen shot of the window being used as a palette with the original image beneath.
>
> It can be seen here:
>
> https://dl.dropboxusercontent.com/u/98788898/LiveCode/Screen%20Shot.png
>
> The original image is a png with alpha and shows as blue.
>
> The palette window is grey.
>
> How do I apply the blue colour of the image?
>
> Thanks
>
> Terry
>
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Kind regards,

Drs. Mark Schonewille

Economy-x-Talk Consultancy and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
Facebook: http://facebook.com/LiveCode.Beginner
KvK: 50277553
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

Terence Heaford-2

> On 19 Jul 2015, at 20:41, Mark Schonewille <[hidden email]> wrote:
>
> Set the visible of the image to true and position it correctly :-)

Obvious really :-)

but I was storing the image in another stack until your comment.

Thanks

Terry


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

xtalkprogrammer
Obvious, but I can understand that you think this way, because sometimes
you may want to use a window shape with a simple background colour or
pattern. Btw you might want to set the cantSelect of the image to true
after positioning it. That will save you some frustrations while
building the interface of your stack.

--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553

Installer Maker for LiveCode:
http://qery.us/468

Buy my new book "Programming LiveCode for the Real Beginner"
http://qery.us/3fi

LiveCode on Facebook:
https://www.facebook.com/groups/runrev/

On 7/19/2015 21:52, Terence Heaford wrote:

>
>> On 19 Jul 2015, at 20:41, Mark Schonewille <[hidden email]> wrote:
>>
>> Set the visible of the image to true and position it correctly :-)
>
> Obvious really :-)
>
> but I was storing the image in another stack until your comment.
>
> Thanks
>
> Terry
>
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Kind regards,

Drs. Mark Schonewille

Economy-x-Talk Consultancy and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
Facebook: http://facebook.com/LiveCode.Beginner
KvK: 50277553
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

ScottR
In reply to this post by Terence Heaford-2
You can reference an image in a substack for example, and in addition to setting the windowShape of the stack to the ID of the image, set the backPattern of the card of your mainstack to the same image ID.  You don’t need to worry about aligning/positioning images, and you will likely get better blending at the edges of the window.

If you have any variable translucency in your source image, you’ll need to play with the backColor of the stack as this can “show through” the translucency of the card.

Regards,

Scott Rossi
Creative Director
Tactile Media, UX/UI Design

> On Jul 19, 2015, at 9:52 AM, Terence Heaford <[hidden email]> wrote:
>
>
>> On 19 Jul 2015, at 20:41, Mark Schonewille <[hidden email]> wrote:
>>
>> Set the visible of the image to true and position it correctly :-)
>
> Obvious really :-)
>
> but I was storing the image in another stack until your comment.
>
> Thanks
>
> Terry
>
>
> _______________________________________________
> use-livecode mailing list
> [hidden email]
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

Todd Fabacher
In reply to this post by Terence Heaford-2
I find the bast way to set and show an image in a windowShape is use
backgroundPattern.
This way you do not need to worry about the image moving or not filling the
screen. You can set it in the IDE or in code

set the backgroundPattern of *object* to {your* imageID*}

Hope that helps,

Todd Fabacher


Date: Sun, 19 Jul 2015 20:36:48 +0100
From: Terence Heaford <[hidden email]>
To: How to use LiveCode <[hidden email]>
Subject: windowShape
Message-ID: <[hidden email]>
Content-Type: text/plain; charset=us-ascii

I have been messing about with applying windowShape and although I can get
the shape to work it does not take the colour of the image.

Should it? and how do I do it please?

I have taken a screen shot of the window being used as a palette with the
original image beneath.

It can be seen here:

https://dl.dropboxusercontent.com/u/98788898/LiveCode/Screen%20Shot.png

The original image is a png with alpha and shows as blue.

The palette window is grey.

How do I apply the blue colour of the image?

Thanks

Terry
_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

Terence Heaford-2
In reply to this post by ScottR
Thanks for your comments.

This seems the ideal way to do it allowing you to store your images in a central repository.

All the best

Terry


> On 19 Jul 2015, at 22:53, Scott Rossi <[hidden email]> wrote:
>
> You can reference an image in a substack for example, and in addition to setting the windowShape of the stack to the ID of the image, set the backPattern of the card of your mainstack to the same image ID.  You don’t need to worry about aligning/positioning images, and you will likely get better blending at the edges of the window.
>
> If you have any variable translucency in your source image, you’ll need to play with the backColor of the stack as this can “show through” the translucency of the card.
>
>



> On 20 Jul 2015, at 03:26, Todd Fabacher <[hidden email]> wrote:
>
> I find the bast way to set and show an image in a windowShape is use
> backgroundPattern.
> This way you do not need to worry about the image moving or not filling the
> screen. You can set it in the IDE or in code
>
> set the backgroundPattern of *object* to {your* imageID*}

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

Richard Gaskin
In reply to this post by Todd Fabacher
Todd Fabacher wrote:

 > I find the bast way to set and show an image in a windowShape is use
 > backgroundPattern.
 > This way you do not need to worry about the image moving or not
 > filling the screen. You can set it in the IDE or in code
 >
 > set the backgroundPattern of *object* to {your* imageID*}

If the object having its backgroundPattern set is the card or stack,
proper alignment can depend on the specifics of the image.  For example,
if the image has a mask inset from the image bounds, setting the
backgroundPattern will cause the tiling to begin with the image's
topLeft, which can result in a misaligned placement when it gets tiled
within the object.

Using a separate object like a graphic would help, though for reasons I
don't fully understand I've found no other method of displaying images
that render as quickly button icons.

--
  Richard Gaskin
  Fourth World Systems
  Software Design and Development for the Desktop, Mobile, and the Web
  ____________________________________________________________________
  [hidden email]                http://www.FourthWorld.com

_______________________________________________
use-livecode mailing list
[hidden email]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode
Reply | Threaded
Open this post in threaded view
|

Re: windowShape

Dave Kilroy
Another thing that can screw up windowShape is scaleFactor (or it used to, haven't checked since the early 6.7's...) - make sure you have it at 1 or else you get (or used to get) weird on-screen artefacts
"The first 90% of the task takes 90% of the time, and the last 10% takes the other 90% of the time."
Peter M. Brigham