Click here to Skip to main content
15,897,273 members
Articles / Programming Languages / C#

Improvement of the .NET Menu Style Class

Rate me:
Please Sign up or sign in to vote.
4.27/5 (17 votes)
14 Jan 20032 min read 211.8K   468   51  
This is an improvement by Francesco Natali over an improvement by Sajith M of the "Visual Studio .NET Menu Style" by Carlos H. Perez
<?xml version="1.0" encoding="utf-8"?>
<root>
  <!-- 
            Microsoft ResX Schema 
        
            Version 1.3
                
            The primary goals of this format is to allow a simple XML format 
            that is mostly human readable. The generation and parsing of the 
            various data types are done through the TypeConverter classes 
            associated with the data types.
        
            Example:
        
                ... ado.net/XML headers & schema ...
                <resheader name="resmimetype">text/microsoft-resx</resheader>
                <resheader name="version">1.3</resheader>
                <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
                <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
                <data name="Name1">this is my long string</data>
                <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
                <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
                    [base64 mime encoded serialized .NET Framework object]
                </data>
                <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
                    [base64 mime encoded string representing a byte array form of the .NET Framework object]
                </data>
        
            There are any number of "resheader" rows that contain simple 
            name/value pairs.
            
            Each data row contains a name, and value. The row also contains a 
            type or mimetype. Type corresponds to a .NET class that support 
            text/value conversion through the TypeConverter architecture. 
            Classes that don't support this are serialized and stored with the 
            mimetype set.
                     
            The mimetype is used for serialized objects, and tells the 
            ResXResourceReader how to depersist the object. This is currently not 
            extensible. For a given mimetype the value must be set accordingly:
        
            Note - application/x-microsoft.net.object.binary.base64 is the format 
                   that the ResXResourceWriter will generate, however the reader can 
                   read any of the formats listed below.
        
            mimetype: application/x-microsoft.net.object.binary.base64
            value   : The object must be serialized with 
                    : System.Serialization.Formatters.Binary.BinaryFormatter
                    : and then encoded with base64 encoding.
        
            mimetype: application/x-microsoft.net.object.soap.base64
            value   : The object must be serialized with 
                    : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
                    : and then encoded with base64 encoding.
            mimetype: application/x-microsoft.net.object.bytearray.base64
            value   : The object must be serialized into a byte array 
                    : using a System.ComponentModel.TypeConverter
                    : and then encoded with base64 encoding.
        -->
  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
    <xsd:element name="root" msdata:IsDataSet="true">
      <xsd:complexType>
        <xsd:choice maxOccurs="unbounded">
          <xsd:element name="data">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
              </xsd:sequence>
              <xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
            </xsd:complexType>
          </xsd:element>
          <xsd:element name="resheader">
            <xsd:complexType>
              <xsd:sequence>
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
              </xsd:sequence>
              <xsd:attribute name="name" type="xsd:string" use="required" />
            </xsd:complexType>
          </xsd:element>
        </xsd:choice>
      </xsd:complexType>
    </xsd:element>
  </xsd:schema>
  <resheader name="resmimetype">
    <value>text/microsoft-resx</value>
  </resheader>
  <resheader name="version">
    <value>1.3</value>
  </resheader>
  <resheader name="reader">
    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <resheader name="writer">
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
  </resheader>
  <data name="mainMenu.Location" type="System.Drawing.Point, System.Drawing, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>17, 17</value>
  </data>
  <data name="imageList1.Location" type="System.Drawing.Point, System.Drawing, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>120, 17</value>
  </data>
  <data name="imageList1.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64">
    <value>
        AAEAAAD/////AQAAAAAAAAAMAgAAAFpTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0xLjAuMzMw
        MC4wLCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZT
        eXN0ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMA
        AADYBwAAAk1TRnQBSQFMAgEBAgEAAQUBAAEEAQABEAEAARABAAT/ASEBEAj/AUIBTQE2BwABNgMAASgD
        AAFAAwABIAMAAQEBAAEgBgABIP8A/wD/AP8A/wD/AP8A/wD/AP8A/wD/AP8A/wD/AP8ALgABYwFlAWMB
        /wFjAWUBYwH/AWMBZQFjAf8BYwFlAWMB/wFjAWUBYwH/5AABtQGKAYwB/wFzAXEBcwH/AZwBcQFzAf8B
        vQGWAZQB/wGtAYoBjAH/AYQBXQFaAf8BSgFFAUIB/wFjAWUBYwH/IAADgAH/A4AB/wOAAf8DgAH/A4AB
        /wOAAf8DgAH/A4AB/wOAAf8DgAH/A4AB/wOAAf8DgAH/A4AB/wOAAf+AAAG1AYoBjAH/Ab0BpgGlAf8B
        3gHXAdYB/wHeAd8B3gH/Ad4B1wHWAf8B1gHHAcYB/wHOAb4BvQH/Ab0BlgGUAf8BewFdAVoB/wFjAWUB
        YwH/GAABgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8B
        gAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8DgAH/gAABtQGKAYwB/wH3AfMB9wH/AfcB
        8wH3Af8D5wH/Ad4B1wHWAf8B3gHLAc4B/wHWAb4BvQH/AcYBpgGlAf8BxgGeAZwB/wFjAWUBYwH/GAAB
        gAIAMf8DwAH/AYACAAH/A4AB/4QAAbUBigGMAf8B9wHzAfcB/wH3AfMB9wH/Ad4B2wHeAf8B1gGyAbUB
        /wHOAZIBlAH/Ab0BigGMAf8BxgGeAZwB/xAAAWMBZQFjAf8BMQFRATkB/wQAAYACADH/A8AB/wGAAgAB
        /wOAAf+IAAHWAaYBpQH/AdYBsgG1Af8B1gGyAbUB/wHOAYYBhAH/Ac4BaQFrAf8BvQF1AXMB/wGcAXEB
        cwH/CAABYwFlAWMB/wExAVEBOQH/ARABhgEhAf8BEAFtARgB/wQAAYACADH/A8AB/wGAAgAB/wOAAf+I
        AAHvAaIBUgL/Aa4BMQH/Ae8BtgFzAf8BzgGGAYQB/wHGAV0BWgH/AYQBXQFaAf8BWgFRAUoB/wFjAWUB
        YwH/ATEBUQE5Af8BGAGWATEB/wExAaIBQgH/ARABhgEhAf8IAAGAAgAx/wPAAf8BgAIAAf8DgAH/hAAB
        tQGKAYwB/wH3AaYBQgL/AaoBIQL/AbYBMQL/AcMBSgH/AfcBpgEpAf8BrQFxASkB/wFaAVEBSgH/ASEB
        pgFCAf8BKQG6AVIB/wExAcsBYwH/ARABhgEhAf8MAAGAAgAx/wPAAf8BgAIAAf8DgAH/hAABtQGKAYwB
        /wH3AbIBSgL/AcMBSgL/AboBQgL/AaYBEAH/AecBlgE5Af8BvQGeAXMB/wE5AboBWgH/AUoB1wFzAf8B
        QgGiAVIB/wFzAXEBcwH/EAABgAIAMf8DwAH/AYACAAH/A4AB/4AAAbUBigGMAf8BvQGmAZQC/wHHAVoC
        /wHLAVoB/wGtAXEBKQH/AXMBUQExAf8B7wG+AYwB/wHvAcsBjAH/AaUBjgGMAf8BQgF9AUIB/wFzAXEB
        cwH/FAABgAIAMf8DwAH/AYACAAH/A4AB/4AAAbUBigGMAf8BzgG2AZQC/wHTAWsB/wHvAcsBewH/AUIB
        pgHeAf8BKQGWAc4B/wFKAZIBrQH/Ab0BngFzAf8B1gGSAUoB/wFjAUkBSgH/GAABgAIAMf8DwAH/AYAC
        AAH/A4AB/4AAAbUBigGMAf8B7wHLAYwC/wHbAXsB/wHWAc8BpQH/AUIBpgHeAf8BSgG2Ae8B/wFKAbYB
        7wH/AYwBugG1Af8B7wG2AXMB/wFzAXEBcwH/GAABgAIAAf8DwAH/A8AB/wPAAf8DwAH/A8AB/wPAAf8D
        wAH/A8AB/wPAAf8DwAH/A8AB/wPAAf8DwAH/AYACAAH/A4AB/4AAAbUBigGMAf8BzgG2AZQB/wH3AdcB
        jAL/AesBpQL/AfcBvQH/AYwBugG1Af8BjAG6AbUC/wHrAZwB/wHWAaYBcwH/AWMBZQFjAf8YAAGAAgAC
        /wIAAv8CAAL/AgAC/wIAAv8CAAL/AgAC/wIAAv8CAAL/AgAC/wIAAv8CAAL/AgAC/wIAAf8BgAIAAf8D
        gAH/gAABtQGKAYwB/wG9AaYBpQH/Ab0BpgGlAf8BzgG2AZQB/wHWAc8BpQH/Ae8B3wG9Av8B5wGtAv8B
        6wGlAf8BvQGeAXMB/wFzAXEBcwH/GAAB/wIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8B
        gAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAf8BgAIAAv8CAAH/iAABtQGKAYwB
        /wG1AYoBjAH/AbUBigGMAf8BtQGKAYwB/wG9AaYBpQH/Ab0BpgGlAf8BvQGmAZQB/wG1AYoBjAH/8AAB
        tQGKAYwB/wG1AYoBjAH/AbUBigGMAf/gAAFCAU0BPgcAAT4DAAEoAwABQAMAASADAAEBAQABAQYAAQEW
        AAP/gQAB4AP/BAABgAF/AYAGAAE/BwABPwYAAYABeQYAAcABYQYAAcABAwYAAYABBwYAAYABDwcAAR8H
        AAE/BwABPwcAAT8HAAE/AQABAQQAAYABfwL/BAAB+AP/GgAL
</value>
  </data>
  <data name="contextMenu1.Location" type="System.Drawing.Point, System.Drawing, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
    <value>225, 17</value>
  </data>
  <data name="$this.Name">
    <value>Form1</value>
  </data>
  <data name="$this.TrayHeight" type="System.Int32, mscorlib, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
    <value>63</value>
  </data>
</root>

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.


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

Comments and Discussions