コード例 #1
0
        public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext context, object value, Attribute[] attributes)
        {
            PropertyDescriptorCollection props = TypeDescriptor.GetProperties(typeof(SelectionRange), attributes);

            return(props.Sort(new string[] { "Start", "End" }));
        }
コード例 #2
0
            /// <summary>
            ///  Retrieves the set of properties for this type. By default, a type has does
            ///  not return any properties. An easy implementation of this method can just
            ///  call TypeDescriptor.GetProperties for the correct data type.
            /// </summary>
            public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext?context, object value, Attribute[]?attributes)
            {
                PropertyDescriptorCollection props = TypeDescriptor.GetProperties(typeof(DockPaddingEdges), attributes);

                return(props.Sort(new string[] { "All", "Left", "Top", "Right", "Bottom" }));
            }
コード例 #3
0
        public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext context, object value, Attribute[] attributes)
        {
            PropertyDescriptorCollection props = TypeDescriptor.GetProperties(typeof(Padding), attributes);

            return(props.Sort(new string[] { nameof(Padding.All), nameof(Padding.Left), nameof(Padding.Top), nameof(Padding.Right), nameof(Padding.Bottom) }));
        }
コード例 #4
0
        public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext context, object value, Attribute[] attributes)
        {
            PropertyDescriptorCollection props = TypeDescriptor.GetProperties(typeof(TableLayoutPanelCellPosition), attributes);

            return(props.Sort(new string[] { "Column", "Row" }));
        }
コード例 #5
0
            public override PropertyDescriptorCollection GetProperties(ITypeDescriptorContext?context, object value, Attribute[]?attributes)
            {
                PropertyDescriptorCollection props = TypeDescriptor.GetProperties(typeof(LinkArea), attributes);

                return(props.Sort(new string[] { nameof(LinkArea.Start), nameof(LinkArea.Length) }));
            }