Click here to Skip to main content
15,891,375 members
Articles / Desktop Programming / WPF

A Document Outline Window for C# Files, in WPF

Rate me:
Please Sign up or sign in to vote.
4.94/5 (62 votes)
12 Oct 2010CPOL14 min read 109.3K   1.4K   93  
A Document Outline Visual Studio tool window for C# files, coded in WPF
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>8.0.30424</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{D3F48C95-3A82-4897-9F5F-845E3135158C}</ProjectGuid>
    <OutputType>Library</OutputType>
    <StartupObject>
    </StartupObject>
    <NoStandardLibraries>false</NoStandardLibraries>
    <AssemblyName>DocOutlineCSharp</AssemblyName>
    <DeploymentDirectory>.\bin\</DeploymentDirectory>
    <Utf8Output>true</Utf8Output>
    <ExpressionBlendVersion>4.0.20525.0</ExpressionBlendVersion>
    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
    <TargetFrameworkProfile>
    </TargetFrameworkProfile>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <DebugSymbols>true</DebugSymbols>
    <Optimize>false</Optimize>
    <OutputPath>.\bin\Debug\</OutputPath>
    <EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
    <DefineConstants>DEBUG;TRACE</DefineConstants>
    <WarningLevel>4</WarningLevel>
    <IncrementalBuild>false</IncrementalBuild>
    <DocumentationFile>DocOutlineCSharp.xml</DocumentationFile>
    <TreatWarningsAsErrors>false</TreatWarningsAsErrors>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <DebugSymbols>false</DebugSymbols>
    <Optimize>true</Optimize>
    <OutputPath>.\bin\Release\</OutputPath>
    <EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
    <DefineConstants>TRACE</DefineConstants>
    <WarningLevel>4</WarningLevel>
    <IncrementalBuild>false</IncrementalBuild>
    <DocumentationFile>DocOutlineCSharp.xml</DocumentationFile>
  </PropertyGroup>
  <PropertyGroup>
    <RootNamespace>DocOutlineCSharp</RootNamespace>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="Extensibility, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
      <EmbedInteropTypes>False</EmbedInteropTypes>
    </Reference>
    <Reference Include="PresentationCore" />
    <Reference Include="PresentationFramework" />
    <Reference Include="PresentationFramework.Aero" />
    <Reference Include="PresentationFramework.Luna" />
    <Reference Include="System" />
    <Reference Include="System.Core" />
    <Reference Include="System.Data" />
    <Reference Include="System.Drawing" />
    <Reference Include="System.Windows.Forms" />
    <Reference Include="System.Xml" />
    <Reference Include="UIAutomationProvider" />
    <Reference Include="WindowsBase" />
    <Reference Include="WindowsFormsIntegration" />
  </ItemGroup>
  <ItemGroup>
    <Compile Include="AssemblyInfo.cs">
      <SubType>Code</SubType>
    </Compile>
    <Compile Include="Connect.cs">
      <SubType>Component</SubType>
    </Compile>
    <Compile Include="DocOutline.xaml.cs">
      <DependentUpon>DocOutline.xaml</DependentUpon>
    </Compile>
    <Compile Include="DocOutlineHost.cs">
      <SubType>UserControl</SubType>
    </Compile>
    <Compile Include="DocOutlineHost.Designer.cs">
      <DependentUpon>DocOutlineHost.cs</DependentUpon>
    </Compile>
  </ItemGroup>
  <ItemGroup>
    <COMReference Include="EnvDTE">
      <Guid>{80CC9F66-E7D8-4DDD-85B6-D9E6CD0E93E2}</Guid>
      <VersionMajor>8</VersionMajor>
      <VersionMinor>0</VersionMinor>
      <Lcid>0</Lcid>
      <WrapperTool>primary</WrapperTool>
      <Isolated>False</Isolated>
      <EmbedInteropTypes>False</EmbedInteropTypes>
    </COMReference>
    <COMReference Include="EnvDTE100">
      <Guid>{26AD1324-4B7C-44BC-84F8-B86AED45729F}</Guid>
      <VersionMajor>10</VersionMajor>
      <VersionMinor>0</VersionMinor>
      <Lcid>0</Lcid>
      <WrapperTool>primary</WrapperTool>
      <Isolated>False</Isolated>
      <EmbedInteropTypes>False</EmbedInteropTypes>
    </COMReference>
    <COMReference Include="EnvDTE80">
      <Guid>{1A31287A-4D7D-413E-8E32-3B374931BD89}</Guid>
      <VersionMajor>8</VersionMajor>
      <VersionMinor>0</VersionMinor>
      <Lcid>0</Lcid>
      <WrapperTool>primary</WrapperTool>
      <Isolated>False</Isolated>
      <EmbedInteropTypes>False</EmbedInteropTypes>
    </COMReference>
    <COMReference Include="EnvDTE90">
      <Guid>{2CE2370E-D744-4936-A090-3FFFE667B0E1}</Guid>
      <VersionMajor>9</VersionMajor>
      <VersionMinor>0</VersionMinor>
      <Lcid>0</Lcid>
      <WrapperTool>primary</WrapperTool>
      <Isolated>False</Isolated>
      <EmbedInteropTypes>False</EmbedInteropTypes>
    </COMReference>
    <COMReference Include="Microsoft.VisualStudio.CommandBars">
      <Guid>{1CBA492E-7263-47BB-87FE-639000619B15}</Guid>
      <VersionMajor>8</VersionMajor>
      <VersionMinor>0</VersionMinor>
      <Lcid>0</Lcid>
      <WrapperTool>primary</WrapperTool>
      <Isolated>False</Isolated>
      <EmbedInteropTypes>False</EmbedInteropTypes>
    </COMReference>
    <COMReference Include="stdole">
      <Guid>{00020430-0000-0000-C000-000000000046}</Guid>
      <VersionMajor>2</VersionMajor>
      <VersionMinor>0</VersionMinor>
      <Lcid>0</Lcid>
      <WrapperTool>primary</WrapperTool>
      <Isolated>False</Isolated>
      <EmbedInteropTypes>False</EmbedInteropTypes>
    </COMReference>
  </ItemGroup>
  <ItemGroup>
    <Content Include="DocOutlineCSharp.AddIn" />
    <Resource Include="Resources\collapse.png" />
    <Resource Include="Resources\expand.png" />
    <EmbeddedResource Include="DocOutlineHost.resx">
      <DependentUpon>DocOutlineHost.cs</DependentUpon>
    </EmbeddedResource>
    <Resource Include="Resources\Protected.png" />
    <Resource Include="Resources\Classes.png" />
    <Resource Include="Resources\Constants.png" />
    <Resource Include="Resources\Constructors.png" />
    <Resource Include="Resources\Events.png" />
    <Resource Include="Resources\Fields.png" />
    <Resource Include="Resources\Internal.png" />
    <Resource Include="Resources\Methods.png" />
    <Resource Include="Resources\Private.png" />
    <Resource Include="Resources\Properties.png" />
    <Resource Include="Resources\refresh.png" />
    <EmbeddedResource Include="Resources\icon.ico" />
  </ItemGroup>
  <ItemGroup>
    <Page Include="DocOutline.xaml">
      <SubType>Designer</SubType>
      <Generator>MSBuild:Compile</Generator>
    </Page>
  </ItemGroup>
  <Import Project="$(MSBuildBinPath)\Microsoft.CSHARP.Targets" />
  <PropertyGroup>
    <PreBuildEvent>
    </PreBuildEvent>
    <PostBuildEvent>
    </PostBuildEvent>
  </PropertyGroup>
  <ProjectExtensions />
  <Target Name="AfterBuild">
    <PropertyGroup>
      <DllName>$(AssemblyName).dll</DllName>
      <PdbName>$(AssemblyName).pdb</PdbName>
      <DocFileName>$(AssemblyName).xml</DocFileName>
    </PropertyGroup>
    <Delete Condition="Exists('$(DeploymentDirectory)$(DllName)')" Files="$(DeploymentDirectory)$(DllName)">
    </Delete>
    <Delete Condition="Exists('$(DeploymentDirectory)$(PdbName)')" Files="$(DeploymentDirectory)$(PdbName)">
    </Delete>
    <Delete Condition="Exists('$(DeploymentDirectory)$(DocFileName)')" Files="$(DeploymentDirectory)$(DocFileName)">
    </Delete>
    <Copy Condition="Exists('$(OutputPath)$(DllName)')" SourceFiles="$(OutputPath)$(DllName)" DestinationFolder="$(DeploymentDirectory)">
      <Output TaskParameter="DestinationFiles" ItemName="FileWrites" />
    </Copy>
    <Copy Condition="Exists('$(OutputPath)$(PdbName)')" SourceFiles="$(OutputPath)$(PdbName)" DestinationFolder="$(DeploymentDirectory)">
      <Output TaskParameter="DestinationFiles" ItemName="FileWrites" />
    </Copy>
    <Copy Condition="Exists('$(OutputPath)$(DocFileName)')" SourceFiles="$(OutputPath)$(DocFileName)" DestinationFolder="$(DeploymentDirectory)">
      <Output TaskParameter="DestinationFiles" ItemName="FileWrites" />
    </Copy>
  </Target>
</Project>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
United States United States
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions