| Dylan's profileDylan PhillipsPhotosBlogLists | Help |
|
February 27 BorderificLike all SilverLight newbies, one of my first projects was an image carousel. Step 1: Make the images rotate. Step 2: Add some rounded corners to my images, via RectangleGeometry.RadiusX{Y} and Image.Clip Step 3: Let's add a shiny border...my brain totally page faults at this point. In XAML it's pretty straight forward: <Border BorderThickness="5" CornerRadius="10" BorderBrush="Black"> But, I'm a programmer damn it and I like to build all my stuff dynamically in code. At first, I thought adding a border would be as simple as: Notice there is no Image.Border property. A careful look at the XAML will reveal the error of my ways. The Border is not a Property of the Framework Object, the Border is the container of the Framework Object. I was hoping Border would work something like an inverse .Clip. My work around, and yes it sucks, was to treat Border as the Container object in all my calls, including the .Tick event which repositioned the Carousel in the ellipse. Being an Ex-Microsoft, I know this is a hack, and I have a sticky feeling that I need to be thinking of my object as a Control Template. But, I'm still a SilverLight newbie and this is about learning, and understanding through exploration. I guess my next Blog Entry will be about Control Templates
Follow Ups: @ryantherobot - Totally get the decorator bit, but I don't see it as appropriate for containment. It would be like Margin also being a parent of the Framework Object. To me at least, but thanks for the Tweet Back. February 25 Catching up on 45 Days of BusyBLUF (Bottom Line Up Front)I've been crazy busy for the last 45 days. While I'm still committed to "living la vida start up", the market has me a bit freaked out; so I'm upping my steady contract work to accumulate some "just in case" capital. With luck, six months from now, I'll be back to at least 50% of my time experimenting with technology. Does that mean, I've turned into Al Bundy. Hell no, I'm still me, and I still LOVE TECHNOLOGY. Since I don't have a ton of time, here are the cool things that have captured my attention and imagination. The Heterogenic Future and SilverLightIn my January 7th Post, I honestly felt that Flash was the future. I picked up some ActionScript books at the library, and cracked open CSS3. For all you programmers out there, take my advice and stop there. Holy crap, Flash is a nightmare. It just doesn't feel like a development environment. I love the pervasiveness of their plug-in, but ActionScript is exactly that; a Script Language. I know I'm old school, but I just don't get the Script Languages. So with my Adobe foray cut strikingly short, I felt pretty bummed for a few weeks. Then I had some free time about two weeks ago, and I needed to do some animation work for the Jax EBikes catalogue. I decided to crack open SilverLight. I had my animation going in like 4 hours, and after about 3 days, I felt really at home in the environment. SilverLight runs on Mac(s) and Windows Boxes, and it is the backend of NetFlicks' Streaming Video. Thus, I think it's a safe bet that it can at least be a player over the medium and long term. In the near term, I don't have a ton of use for SilverLight RIA(s), because the plug in is not ubiquitous, but I can definitely see it reaching critical mass. That will be an awesome time for the Internet, because RIA(s) are fun as hell to write. Jax EBikesSo I must be mental, but I just don't want to close Jax EBikes. They are too much fun, and I want people to be able to see how they can be used to change our conceptions of transportation. Sales suck. Gas is cheap. People are worried. And its been a cold Winter. It's not my bread and butter, the only thing is that it's having a negative impact on my relationship with Andrea. NoTimeOff == StressAtHome. Gotta figure out what to do. I thought good Karma was supposed to make things easier, not harder. |
|
|