[forms-devel] Intent of Image.IsOpaque

Jason Smith jas at microsoft.com
Tue Aug 16 08:00:07 UTC 2016


The documentation is wrong.

From: forms-devel [mailto:forms-devel-bounces at lists.dot.net] On Behalf Of Christoffer Årstrand
Sent: Tuesday, August 16, 2016 12:45 AM
To: forms-devel at lists.dot.net
Subject: Re: [forms-devel] Intent of Image.IsOpaque

Yes, that is normally how it is handled.

However either the flag is named incorrectly (supposed to be hasAlpha or something) or the documentation is wrong (negated). An image that is marked “opaque” is not supposed to be treated as it was transparent…

So the question is valid, are you suposed to set it to false (naming) or true (docs) for transparent images?

Cheers,

CHRISTOFFER ÅRSTRAND
DEVELOPMENT LEAD
YOOBA
VÄSTGÖTEGATAN 7
602 21  NORRKÖPING, SWEDEN
Office tel: +46 (0)11 12 20 90
www.yooba.com<https://na01.safelinks.protection.outlook.com/?url=http%3a%2f%2fwww.yooba.com&data=01%7c01%7cjas%40microsoft.com%7ca62742a9064b4eaccd1a08d3c5a93780%7c72f988bf86f141af91ab2d7cd011db47%7c1&sdata=CaEDhYylg9VwzMdr9QTD2cd3BZJIDBHbDgMbl5sebcM%3d> | | christoffer.arstrand at yooba.com<mailto:christoffer.arstrand at yooba.com>
se.linkedin.com/in/arstrand<https://na01.safelinks.protection.outlook.com/?url=http%3a%2f%2fse.linkedin.com%2fin%2farstrand&data=01%7c01%7cjas%40microsoft.com%7ca62742a9064b4eaccd1a08d3c5a93780%7c72f988bf86f141af91ab2d7cd011db47%7c1&sdata=5xvc2NPx9uFJZ4zGCzKCUFrzAOw8Ie%2fKUDlIfD692Jk%3d>

From: forms-devel <forms-devel-bounces at lists.dot.net<mailto:forms-devel-bounces at lists.dot.net>> on behalf of Jason Smith via forms-devel <forms-devel at lists.dot.net<mailto:forms-devel at lists.dot.net>>
Reply-To: Jason Smith <jas at microsoft.com<mailto:jas at microsoft.com>>
Date: Tuesday 16 August 2016 at 09:24
To: 이승근 <hi.root at gmail.com<mailto:hi.root at gmail.com>>, "forms-devel at lists.dot.net<mailto:forms-devel at lists.dot.net>" <forms-devel at lists.dot.net<mailto:forms-devel at lists.dot.net>>
Subject: Re: [forms-devel] Intent of Image.IsOpaque

IsOpaque is really a performance optimization. It is safe for a backend to ignore. A rendering engine can take certain shortcuts if it knows an image is opaque. That is all.

From: forms-devel [mailto:forms-devel-bounces at lists.dot.net] On Behalf Of ???
Sent: Thursday, August 11, 2016 7:57 PM
To: forms-devel at lists.dot.net<mailto:forms-devel at lists.dot.net>
Subject: [forms-devel] Intent of Image.IsOpaque


Hi, all

Who is known intent of Image.IsOpaque?

It only implemented in iOS, others platform renderers ignore this property.

Anyway, Currently Xamarin document describe this property like below
https://developer.xamarin.com/api/property/Xamarin.Forms.Image.IsOpaque/<https://na01.safelinks.protection.outlook.com/?url=https%3a%2f%2fdeveloper.xamarin.com%2fapi%2fproperty%2fXamarin.Forms.Image.IsOpaque%2f&data=01%7c01%7cjas%40microsoft.com%7c371abcf60fc24a65ae4008d3c25c457d%7c72f988bf86f141af91ab2d7cd011db47%7c1&sdata=Xx3kTYzcxzWU6N51CxryQKdyT17iKIcXnvtD5vPp%2f4M%3d>
"If true, you'll be able to see through transparent parts of the image."
According to this guide, If want show partially transparent image, IsOpaque should be set true.
Is that right?

As I know, IsOpaque property was mapped iOS UIView.opaque
https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIView_Class/#//apple_ref/occ/instp/UIView/opaque<https://na01.safelinks.protection.outlook.com/?url=https%3a%2f%2fdeveloper.apple.com%2flibrary%2fios%2fdocumentation%2fUIKit%2fReference%2fUIView_Class%2f%23%2f%2fapple_ref%2focc%2finstp%2fUIView%2fopaque&data=01%7c01%7cjas%40microsoft.com%7c371abcf60fc24a65ae4008d3c25c457d%7c72f988bf86f141af91ab2d7cd011db47%7c1&sdata=Ca%2fv7J0WSrIZ7tC9gBFLyzLfN0fcI4RSpttHEcLo30s%3d>
"You should always set the value of this property to NO if the view is fully or partially transparent."
According to this guide, If want show partially transparent image, opaque should be set false(NO)

Which is right?
Please, anyone answer this question.

Thanks!
Seungkeun Lee
_______________________________________________ forms-devel mailing list forms-devel at lists.dot.net<mailto:forms-devel at lists.dot.net> http://lists.dot.net/mailman/listinfo/forms-devel<https://na01.safelinks.protection.outlook.com/?url=http%3a%2f%2flists.dot.net%2fmailman%2flistinfo%2fforms-devel&data=01%7c01%7cjas%40microsoft.com%7ca62742a9064b4eaccd1a08d3c5a93780%7c72f988bf86f141af91ab2d7cd011db47%7c1&sdata=PjbaaHIB3N7i44aGvYJVKcK06JOHRT3%2bi3%2feZ7mvE8M%3d>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.dot.net/pipermail/forms-devel/attachments/20160816/356a8c56/attachment-0001.html>


More information about the forms-devel mailing list