XWidgetSoft Forum

XWidget & XLaunchpad , Desktop customization
It is currently 2017年 Nov 24日 21:36

All times are UTC - 8 hours




Post new topic Reply to topic  [ 11 posts ] 
Author Message
PostPosted: 2013年 Jul 29日 12:33 
Offline
User avatar

Joined: 2013年 Jul 29日 09:13
Posts: 572
Currently, when you click on the transparent part of an image then Xwidget recognises it as a valid event. This is a problem where you may have an odd-shaped image acting as a control. When the user clicks upon the transparent area around the control thinking they are pressing on the item layered behind it, then the click event is actually for the layer above.

I suggest that Xwidget excludes transparent areas and treats them as if they are not part of the layer.
In this way you can click on an item where it appears to exist in the image, the user would simply know that he was clicking on the things he could see.

Other widget engines do act in this way, sampling the layers in turn to see if they are transparent and allowing the click event to occur on the opaque layer beneath the mouse.

It could be controlled by a switch, allowing current behaviour to continue.


Last edited by yereverluvinuncleber on 2017年 Jun 16日 04:23, edited 2 times in total.

Top
 Profile  
 
PostPosted: 2013年 Jul 29日 13:40 
Offline
User avatar

Joined: 2012年 Jul 9日 13:14
Posts: 112
Perhaps you could try "Mouse Through".
Attachment:
mouse_through.png
mouse_through.png [ 19.49 KiB | Viewed 4304 times ]


Top
 Profile  
 
PostPosted: 2013年 Jul 29日 13:51 
Offline
User avatar

Joined: 2013年 Jul 29日 09:13
Posts: 572
[Edited by me in the light of further testing]
Thanks for your help. Getting to know the IDE slowly.

I should think I'll be making a lot more daft recommendations and asking silly questions before I know what I am doing. Coming from YWE background where there is no IDE means I have a lot to learn.


Last edited by yereverluvinuncleber on 2013年 Jul 29日 14:03, edited 1 time in total.

Top
 Profile  
 
PostPosted: 2013年 Jul 29日 14:01 
Offline
User avatar

Joined: 2013年 Jul 29日 09:13
Posts: 572
Nope that's no good, the layer is a control. It needs to function and the "mouse through" causes all events such as mouse functions to go through to the layer below regardless of whether the layer above is transparent or opaque.

I may not have made it clear enough.

Only the transparent areas need a "mouse through", the opaque areas of the image act as per normal.

Look at the slider control on this widget and you may see the issue:

Image

The slider is a non-standard shape and it must only move when it is clicked and dragged. Clicking on any other part of the widget must not cause the slider to slide.

The YWE version of this is here if it helps to get a demo:
http://rocketdock.com/addon/misc/45672


Top
 Profile  
 
PostPosted: 2013年 Jul 30日 10:24 
Offline
User avatar

Joined: 2012年 Jul 9日 13:14
Posts: 112
Hi,
I think there is no need for any layer at all. I 've made the widget just now and it works fine (used some script from "Volume bar 3" by Blaezer http://www.deviantart.com/art/Volume-ba ... -322692337). The only thing I couldn't get is a simple hand cursor for the thumb. Maybe someone else knows how to get it.
Attachment:
steam_volume.gif
steam_volume.gif [ 40.42 KiB | Viewed 4290 times ]

Attachment:
steam_volume.rar [76.54 KiB]
Downloaded 214 times


Last edited by Dagedee on 2013年 Jul 31日 00:08, edited 1 time in total.

Top
 Profile  
 
PostPosted: 2013年 Jul 30日 13:57 
Offline
User avatar

Joined: 2013年 Jul 29日 09:13
Posts: 572
You lovely chap - you beat me to it. A bit clever using a progress bar instead of the cable image.

Mine will be out soon. Differently done.

Still though, my feature request is not about this particular widget, it is about the concept of image layers with transparent parts and whether a click should "click through" these areas.


Top
 Profile  
 
PostPosted: 2013年 Jul 31日 00:07 
Offline
User avatar

Joined: 2012年 Jul 9日 13:14
Posts: 112
:) ... When I created it, I also learned something new - and now I'm curious about your solution!


Top
 Profile  
 
PostPosted: 2013年 Jul 31日 01:56 
Offline
User avatar

Joined: 2012年 Jun 10日 05:57
Posts: 315
the transparent part doesn't active event in my widget.


Attachments:
transparent_area.XWidgetPkg [179.75 KiB]
Downloaded 175 times
Top
 Profile  
 
PostPosted: 2013年 Aug 7日 16:54 
Offline
User avatar

Joined: 2013年 Jul 29日 09:13
Posts: 572
Yes, your example shows that a transparent area should have a click-through BUT...

Try the slightly modified version of your package that I have modified so that it has an extra layer below, you can click on the top layer and slide the top layer from right to left within the borders of the widget, the underneath layer stays still. That's how it should work.

Now, when you click on the transparent area above my additional image then I would expect the click to click-through down to the layer below, it doesn't. You can click on a transparent area above the pipes and it ignores the click-through and responds with a click event on the layer above. You can click on the transparent areas and slide them from right to left.

Try it and see. This is unexpected behaviour to me as I expect a transparent are not to register a click regardless of how you manipulate it. It should only register a click event when an opaque section is clicked upon.


Attachments:
transparent_area.XWidgetPkg [212.43 KiB]
Downloaded 154 times
xwidgetbug01.jpg
xwidgetbug01.jpg [ 31.16 KiB | Viewed 4193 times ]
Top
 Profile  
 
PostPosted: 2013年 Aug 7日 20:36 
Offline
User avatar

Joined: 2012年 Jun 10日 05:57
Posts: 315
Yes, you are right.
i will tell Tony about this bug.
Thank you very much.


Top
 Profile  
 
PostPosted: 2014年 May 29日 13:30 
Offline
User avatar

Joined: 2013年 Jul 29日 09:13
Posts: 572
Any news on this bug?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 13 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron

Powered by phpBB® Forum Software © phpBB Group