{"id":46,"date":"2008-04-10T09:36:27","date_gmt":"2008-04-10T09:36:27","guid":{"rendered":"http:\/\/todepoint.com\/blog\/?p=46"},"modified":"2008-04-10T09:36:27","modified_gmt":"2008-04-10T09:36:27","slug":"glossy-buttons-in-pure-as3-code","status":"publish","type":"post","link":"https:\/\/todepoint.com\/blog\/2008\/04\/10\/glossy-buttons-in-pure-as3-code\/","title":{"rendered":"Glossy buttons in pure as3 code"},"content":{"rendered":"<div id=\"glsscontent\"><img loading=\"lazy\" src=\"http:\/\/www.todepoint.com\/adi\/as_examples\/glossy\/glossy_but.jpg\" width=\"450\" height=\"200\" border=\"0\" \/><\/div>\n<p><script src=\"http:\/\/www.todepoint.com\/blog\/js\/swfobject.js\" type=\"text\/javascript\"><\/script><br \/>\n<script type=\"text\/javascript\">\n\/\/ <![CDATA[\nvar glsso = new SWFObject(\"http:\/\/www.todepoint.com\/adi\/as_examples\/glossy\/glossy_button2.swf\", \"sotester\", \"450\", \"200\", \"9\", \"#6d9a20\");\nglsso.write(\"glsscontent\");\n\/\/ ]]>\n<\/script>I&#8217;ve been playing with the drawing classes, experimenting gradients and blending modes, and so I put together a small (basic) as3 class that generates a glossy button with pure code &#8211; no library assets.<\/p>\n<p>You can <a href=\"http:\/\/www.todepoint.com\/adi\/as_examples\/glossy\/glossy_class.zip\" title=\"download the glossy class\">download the class here<\/a>.<\/p>\n<p>The class constructor expects only 3 parameters:<br \/>\n<code>@param <strong>rad<\/strong>          = Width of button<br \/>\n@param <strong>darkColor<\/strong>    = The color in top area, more dominant<br \/>\n@param <strong>lightColor<\/strong>  = The color in the bottom area<\/code><\/p>\n<p>* you can then place it anywhere, and use method <code><strong>setCaption<\/strong>(cap:String)<\/code> to place a label on the button, though this is a very basic implementation of text handling, I focused on drawing..<\/p>\n<p>Let me know if you liked it : )<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve been playing with the drawing classes, experimenting gradients and blending modes, and so I put together a small (basic) as3 class that generates a glossy button with pure code &#8211; no library assets. You can download the class here. The class constructor expects only&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[4,10,11,14,29],"tags":[],"_links":{"self":[{"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/posts\/46"}],"collection":[{"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/comments?post=46"}],"version-history":[{"count":0,"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/posts\/46\/revisions"}],"wp:attachment":[{"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/media?parent=46"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/categories?post=46"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/todepoint.com\/blog\/wp-json\/wp\/v2\/tags?post=46"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}