Breaking up (lines) is (not) hard to do [Tip: Put XAML attributes and elements on multiple lines so the markup is easy to read and work with]
**
This blog has moved to a new location and comments have been disabled.
All old posts, new posts, and comments can be found on The blog of dlaa.me.
See you there!
Comments
Anonymous
June 24, 2010
The comment has been removedAnonymous
June 24, 2010
The comment has been removedAnonymous
June 24, 2010
My opinion only. I hope I will never have to write any xaml by hand.Anonymous
June 24, 2010
My opinion only. I hope I will always be able to write xaml by hand. Many activities are quicker than can be done by mousing which I assume is what you would prefer.Anonymous
June 24, 2010
Marc/Mark, I hope you both get your wish - but for most people, I think the reality is probably somewhere in between... :)Anonymous
June 24, 2010
The comment has been removedAnonymous
June 24, 2010
I have found that in certain places in Xaml this is worthwhile. What works better is to change the color settings in VS so that the attributes and values 'pop' more. This keeps you from having to go back and edit a lot of UI stuff more than necessary.Anonymous
June 25, 2010
The comment has been removedAnonymous
June 25, 2010
Rob, What you say is true, though it's been my experience that the default (ZIP) compression that's applied to the content of XAP files really tends to minimize the impact of extra XAML whitespace on the final download size. There's some value in "minifying" the XAML for public assemblies, but I'm not aware of any great infrastructure to do so at this time - possibly because the benefit is relatively low in the overall scheme of things. However, if you find out about a good option here, I'd love to know about it! :)Anonymous
June 26, 2010
Hi David, Looks neat to me, but what about bindings? They can get pretty verbose with Path, Converter (plus StaticResource referencer), ConverterParameter et. al. However, they look a bit funny when spread across multiple lines. How do you handle these? Colin E.Anonymous
June 26, 2010
The comment has been removedAnonymous
July 01, 2010
VS itself provides very good support for formatting(auto) XAML. You just need to set few settings and that's it, you can easily format your XAML by using one shortcut and moreover if you copy paste the code VS automatically formats it. Auto formatting the XAML : weblogs.asp.net/.../auto-formatting-the-xaml.aspx