BamlViewer is one of my favorite’s add-in,
Thanks Andrew!
Corrado
Andrew,
Where can I download the latest version?, CodePlex date is 2007…
Thanks
Corrado
From: wpf-di...@googlegroups.com
[mailto:wpf-di...@googlegroups.com] On Behalf Of Andrew
Sent: giovedì 25 settembre 2008 05:08
To: wpf-di...@googlegroups.com
Subject: [WPF Disciples] Baml Viewer...
For those that don't read my blog but use the BamlViewer addin for reflector, I checked in another set of fixes/improvements for it. If anyone finds anything they need addressed let me know and I'll try to look into it.
You will need to build the project, Corrado (or I can send you the compiled dll, if you'd like).
I agree... BamlViewer is my favorite add-in (followed thereafter by the Delphi add-in... I told you I had a thing for object pascal! :)
Building the AddIns project is pretty straight forward. Download the latest changeset. Unzip it to a local directory. Copy reflector.exe into the Build directory. Open the solution and build the BamlViewer project.
If you get build errors complaining that the .NET Framework 1.0 compiler cannot be found at a given path, then you need to install the .NET Framework 1.0 redistributable. (The reflector AddIns project specifically targets 1.0.)
Andrew's changes are awesome! Definitely worth grabbing if you're a bamlviewer user. Its always been a major pain fixing up "borrowed" xaml and Andrew has pretty much fixed all the big pita issues. Major kudos! :-D
Andrew, if you want another issue to add to your futures list... bamlviewer does not dissasemble "generic" styles correctly. (When I say generic, I don't mean generic.xaml... that's my term for non type-specific styles... I'm not sure what the actual SDK term is for such styles.)
When using a generic style, each property setter must specify the type as well as the property. BamlViewer leaves off the type, resulting in a parser error if you try to use the style without fixing it up.
For example, consider the following generic style from the aero.normalcolor theme:
<Style x:Key="ButtonFocusVisual">Property="Control.Template">Margin="2" StrokeThickness="1" Stroke="Black" StrokeDashArray="1 2" SnapsToDevicePixels="true"/>
<Setter
<Setter.Value>
<ControlTemplate>
<Rectangle
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
The baml gets dissassembled to something like this:
<Style x:Key="[0] Ñ">Property="Template">Margin="2" StrokeThickness="1" Stroke="Black" StrokeDashArray="1 2" SnapsToDevicePixels="true" />
<Setter
<Setter.Value>
<ControlTemplate>
<Rectangle
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
To use this style, you have to change the Property back to "Control.Template".
Anyway, that's not a super common scenario, so no big hurry, but it would be nice to have it fixed in some future release. :-)
Thanks again for getting these changes to the community!
Quoting "wpf-di...@googlegroups.com"
<wpf-di...@googlegroups.com>:
> Andrew,
>
> Where can I download the latest version?, CodePlex date is 2007…
>
>
>
> Thanks
>
> Corrado
>
>
>
> From: wpf-di...@googlegroups.com
[mailto:wpf-di...@googlegroups.com]
> On Behalf Of Andrew
>
Sent: giovedì 25 settembre 2008 05:08
> To:
wpf-di...@googlegroups.com
> Subject: [WPF Disciples] Baml
Viewer...
>
>
>
> For those that don't read my
blog but use the BamlViewer
> <http://www.codeplex.com/reflectoraddins/Wiki/View.aspx?title=BamlViewer&ref
> erringTitle=Home> addin for reflector, I checked in another set of
> fixes/improvements for it. If anyone finds anything they need addressed
let
> me know and I'll try to look into it.
>
>
>
>
>
Dr. WPF - Online Office at http://www.drwpf.com/blog/
Crap! Not sure what happened to the formatting of the sample in the earlier post, but hopefully its better here.
For example, consider the following generic style from the aero.normalcolor theme:
<Style
x:Key="ButtonFocusVisual">
<Setter
Property="Control.Template">
<Setter.Value>
<ControlTemplate>
<Rectangle Margin="2"
StrokeThickness="1" Stroke="Black"
StrokeDashArray="1 2"
SnapsToDevicePixels="true"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
The baml gets dissassembled to something like this:
<Style x:Key="[0] Ñ">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate>
<Rectangle Margin="2"
StrokeThickness="1" Stroke="Black"
StrokeDashArray="1 2"
SnapsToDevicePixels="true" />
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
To use this style, you have
to change the Property back to "Control.Template".
Dr. WPF - Online Office at http://www.drwpf.com/blog/
Hi Dr!
Thanks for the explanation, if you could send me the dll, I’d really appreciate it (I’m very short with time and any minute is precious in these busy days…)
Corrado
You should have it now. Feel free to ping me offline if you have any trouble receiving the file.
Quoting "wpf-di...@googlegroups.com"
<wpf-di...@googlegroups.com>:
> Hi Dr!
>
> Thanks for the explanation, if you could send me the dll, I’d really
> appreciate it (I’m very short with time and any minute is precious in
these
> busy days…)
>
>
>
> Corrado
>
>
>
> From: wpf-di...@googlegroups.com
[mailto:wpf-di...@googlegroups.com]
> On Behalf Of Dr. WPF
> Sent: giovedì 25 settembre 2008 08:29
> To:
wpf-di...@googlegroups.com
> Subject: [WPF Disciples] Re: Baml
Viewer...
>
>
>
> You will need to build the
project, Corrado (or I can send you the compiled
> dll, if you'd
like).
>
> I agree... BamlViewer is my favorite add-in
(followed thereafter by the
> Delphi add-in... I told you I had a
thing for object pascal! :)
>
> Building the AddIns project is
pretty straight forward. Download the
> <http://www.codeplex.com/reflectoraddins/SourceControl/ListDownloadableCommi
> ts.aspx> latest changeset. Unzip it to a local directory. Copy
> reflector.exe into the Build directory. Open the solution and build
the
> BamlViewer project.
>
> If you get build errors
complaining that the .NET Framework 1.0 compiler
> cannot be found at a
given path, then you need to install the .NET
> <http://www.microsoft.com/downloads/details.aspx?FamilyID=D7158DEE-A83F-4E21
> -B05A-009D06457787&displaylang=en> Framework 1.0
redistributable. (The
> <http://www.codeplex.com/reflectoraddins/Wiki/View.aspx?title=BamlViewer&ref
>> &ref
>> erringTitle=Home> addin for reflector, I
checked in another set of
>> fixes/improvements for it. If anyone
finds anything they need addressed
> let
>> me know and I'll
try to look into it.
>>
>>
>>
>>
>>
>
> Dr. WPF - Online Office at http://www.drwpf.com/blog/
>
>
>
>
>
Hmm. I'll try to take a look at this. The problem with this is that the baml viewer doesn't use or reference the WPF assemblies so I don't have the base class hierarchy. When I get a chance I'll step through it though and see what information is available and how I can handle this.
Thanks,
Andrew
Crap! Not sure what happened to the formatting of the sample in the earlier post, but hopefully its better here.
For example, consider the following generic style from the aero.normalcolor theme:
<Style x:Key="ButtonFocusVisual">
<Setter Property="Control.Template">
<Setter.Value>
<ControlTemplate>
<Rectangle Margin="2" StrokeThickness="1" Stroke="Black"
StrokeDashArray="1 2" SnapsToDevicePixels="true"/>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
The baml gets dissassembled to something like this:
<Style x:Key="[0] Ñ">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate>
<Rectangle Margin="2" StrokeThickness="1" Stroke="Black"
StrokeDashArray="1 2" SnapsToDevicePixels="true" />
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
To use this style, you have to change the Property back to "Control.Template".
Dr. WPF - Online Office at http://www.drwpf.com/blog/
You will need to build the project, Corrado (or I can send you the compiled dll, if you'd like).
I agree... BamlViewer is my favorite add-in (followed thereafter by the Delphi add-in... I told you I had a thing for object pascal! :)
Building the AddIns project is pretty straight forward. Download the latest changeset. Unzip it to a local directory. Copy reflector.exe into the Build directory. Open the solution and build the BamlViewer project.
If you get build errors complaining that the .NET Framework 1.0 compiler cannot be found at a given path, then you need to install the .NET Framework 1.0 redistributable. (The reflector AddIns project specifically targets 1.0.)
Andrew's changes are awesome! Definitely worth grabbing if you're a bamlviewer user. Its always been a major pain fixing up "borrowed" xaml and Andrew has pretty much fixed all the big pita issues. Major kudos! :-D
Andrew, if you want another issue to add to your futures list... bamlviewer does not dissasemble "generic" styles correctly. (When I say generic, I don't mean generic.xaml... that's my term for non type-specific styles... I'm not sure what the actual SDK term is for such styles.)
When using a generic style, each property setter must specify the type as well as the property. BamlViewer leaves off the type, resulting in a parser error if you try to use the style without fixing it up.
For example, consider the following generic style from the aero.normalcolor theme:
<Style x:Key="ButtonFocusVisual">Property="Control.Template">Margin="2"
StrokeThickness="1" Stroke="Black" StrokeDashArray="1 2" SnapsToDevicePixels="true"/>
<Setter
<Setter.Value>
<ControlTemplate>
<Rectangle
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
The baml gets dissassembled to something like this:
<Style x:Key="[0] Ñ">Property="Template">Margin="2" StrokeThickness="1"
Stroke="Black" StrokeDashArray="1 2" SnapsToDevicePixels="true" />
<Setter
<Setter.Value>
<ControlTemplate>
<Rectangle
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
To use this style, you have to change the Property back to "Control.Template".
Anyway, that's not a super common scenario, so no big hurry, but it would be nice to have it fixed in some future release. :-)
Thanks again for getting these changes to the community!
Quoting "wpf-di...@googlegroups.com" <wpf-di...@googlegroups.com>:
> Andrew,
>
> Where can I download the latest version?, CodePlex date is 2007…
>
>
>
> Thanks
>
> Corrado
>
>
>
> From: wpf-di...@googlegroups.com [mailto:wpf-di...@googlegroups.com]
> On Behalf Of Andrew
> Sent: giovedì 25 settembre 2008 05:08
> To: wpf-di...@googlegroups.com
> Subject: [WPF Disciples] Baml Viewer...
>
>
>
> For those that don't read my blog but use the BamlViewer
> <http://www.codeplex.com/reflectoraddins/Wiki/View.aspx?title=BamlViewer&ref
> erringTitle=Home> addin for reflector, I checked in another set of
> fixes/improvements for it. If anyone finds
anything they need addressed let
> me know and I'll try to look into it.
>
>
>
>
>