Bent Rasmussen
Bent Rasmussen

Reputation: 5702

XAML syntax (machine-readable)

Is there a formal definition of the XAML syntax? There is a PDF document describing XAML in terms of XML Infoset but I haven't been able to find a mechanic description (XSD, RelaxNG or similar). Basically I want to take the schema and create a visualization of the syntax (new to XAML).

XAML goes beyond WPF of course but I'm mostly interested in XAML for WPF development and want a visual schema to get an overview over how constructs can be combined.

Upvotes: 0

Views: 172

Answers (1)

Colin Smith
Colin Smith

Reputation: 12550

Note that it is not possible to use XSD to fully describe a schema for XAML due to it's extensible nature.

However, saying that, there are some .xsd files which are an attempt to provide a close approximation.

Have a look in a directory of Visual Studio:

- C:\Program Files (x86)\Microsoft Visual Studio 9\Xml\Schemas
- C:\Program Files (x86)\Microsoft Visual Studio 9.0\Xml\Schemas
- C:\Program Files (x86)\Microsoft Visual Studio 10.0\Xml\Schemas
- C:\Program Files (x86)\Microsoft Visual Studio 11.0\Xml\Schemas

for wpfe.xsd and xaml2006.xsd.

(you might also see references to xaml.xsd and xaml2005.xsd on the web....provided through older sources).

The early versions of Visual Studio/XAML (e.g. Visual Studio 2005 with the WinFX addon) used to use those xsd's to provide basic intellisense support. Nowadays I they use a different technique (a Language Service) to provide the intellisense support for XAML.

Upvotes: 1

Related Questions