当前位置: 首页>>代码示例>>C#>>正文


C# List.Add方法代码示例

本文整理汇总了C#中PaintDotNet.List.Add方法的典型用法代码示例。如果您正苦于以下问题:C# List.Add方法的具体用法?C# List.Add怎么用?C# List.Add使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PaintDotNet.List的用法示例。


在下文中一共展示了List.Add方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: UnhookStylus

        public static void UnhookStylus(Control control)
        {
            lock (hookedControls.SyncRoot)
            {
                List<WeakReference> deleteUs = new List<WeakReference>();

                foreach (WeakReference weakRef in hookedControls.Keys)
                {
                    object target = weakRef.Target;

                    if (target == null)
                    {
                        deleteUs.Add(weakRef);
                    }
                    else
                    {
                        Control control2 = (Control)target;

                        if (object.ReferenceEquals(control, control2))
                        {
                            deleteUs.Add(weakRef);
                        }
                    }
                }

                foreach (WeakReference weakRef in deleteUs)
                {
                    RealTimeStylus stylus = (RealTimeStylus)hookedControls[weakRef];
                    stylus.Enabled = false;
                    stylus.AsyncPluginCollection.Clear();
                    hookedControls.Remove(weakRef);
                }
            }
        }
开发者ID:herbqiao,项目名称:paint.net,代码行数:34,代码来源:StylusReader.cs

示例2: OnCreateSavePropertyCollection

        public override PropertyCollection OnCreateSavePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.DitherLevel, 7, 0, 8));
            props.Add(new Int32Property(PropertyNames.Threshold, 128, 0, 255));

            return new PropertyCollection(props);
        }
开发者ID:metadeta96,项目名称:openpdn,代码行数:9,代码来源:GifFileType.cs

示例3: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.BrushSize, 3, 1, 8));
            props.Add(new Int32Property(PropertyNames.Coarseness, 50, 3, 255));

            return new PropertyCollection(props);
        }
开发者ID:metadeta96,项目名称:openpdn,代码行数:9,代码来源:OilPaintingEffect.cs

示例4: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Radius, 10, 0, 200));
            props.Add(new DoubleProperty(PropertyNames.Strength, 0.4, 0, 1));

            return new PropertyCollection(props);
        }
开发者ID:herbqiao,项目名称:paint.net,代码行数:9,代码来源:ReduceNoiseEffect.cs

示例5: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> propsBuilder = new List<Property>();
            propsBuilder.Add(new DoubleProperty("X", 0.3, 0, 1));
            propsBuilder.Add(new DoubleProperty("Y", 0.5, 0, 1));
            propsBuilder.Add(new DoubleProperty("Z", 0.11, 0, 1));

            return new PropertyCollection(propsBuilder.ToArray());
        }
开发者ID:simonbrown,项目名称:NormalMapPlus,代码行数:9,代码来源:NormalMapPlus.cs

示例6: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Tolerance, 70, 0, 100));
            props.Add(new Int32Property(PropertyNames.Saturation, 90, 0, 100));

            return new PropertyCollection(props);
        }
开发者ID:herbqiao,项目名称:paint.net,代码行数:9,代码来源:RedEyeRemoveEffect.cs

示例7: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Radius, 10, 1, 200));
            props.Add(new Int32Property(PropertyNames.Percentile, 50, 0, 100));

            return new PropertyCollection(props);
        }
开发者ID:herbqiao,项目名称:paint.net,代码行数:9,代码来源:MedianEffect.cs

示例8: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
 	        List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Softness, 5, 0, 10));
            props.Add(new Int32Property(PropertyNames.Lighting, 0, -20, +20));
            props.Add(new Int32Property(PropertyNames.Warmth, 10, 0, 20));

            return new PropertyCollection(props);
        }
开发者ID:herbqiao,项目名称:paint.net,代码行数:10,代码来源:SoftenPortraitEffect.cs

示例9: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Intensity, 64, 0, 100));
            props.Add(new Int32Property(PropertyNames.Saturation, 100, 0, 400));
            props.Add(new DoubleProperty(PropertyNames.Coverage, 100, 0, 100));

            return new PropertyCollection(props);
        }
开发者ID:herbqiao,项目名称:paint.net,代码行数:10,代码来源:AddNoiseEffect.cs

示例10: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Radius, 6, 1, 20));
            props.Add(new Int32Property(PropertyNames.Brightness, 10, -100, +100));
            props.Add(new Int32Property(PropertyNames.Contrast, 10, -100, +100));

            return new PropertyCollection(props);
        }
开发者ID:metadeta96,项目名称:openpdn,代码行数:10,代码来源:GlowEffect.cs

示例11: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Hue, 0, -180, +180));
            props.Add(new Int32Property(PropertyNames.Saturation, 100, 0, 200));
            props.Add(new Int32Property(PropertyNames.Lightness, 0, -100, +100));

            return new PropertyCollection(props);
        }
开发者ID:metadeta96,项目名称:openpdn,代码行数:10,代码来源:HueAndSaturationAdjustment.cs

示例12: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new DoubleProperty(PropertyNames.Rotation, 30, -180, +180));
            props.Add(new DoubleProperty(PropertyNames.SquareSize, 40, 1, 800));
            props.Add(new DoubleProperty(PropertyNames.Curvature, 8, -100, 100));
            props.Add(new Int32Property(PropertyNames.Quality, 2, 1, 5));

            return new PropertyCollection(props);
        }
开发者ID:herbqiao,项目名称:paint.net,代码行数:11,代码来源:TileEffect.cs

示例13: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new DoubleProperty(PropertyNames.MaxScatterRadius, 3.0, 0.0, 200.0));
            props.Add(new DoubleProperty(PropertyNames.MinScatterRadius, 0.0, 0.0, 200.0));
            props.Add(new Int32Property(PropertyNames.NumSamples, 2, 1, 8));

            List<PropertyCollectionRule> propertyRules = new List<PropertyCollectionRule>();
            propertyRules.Add(new SoftMutuallyBoundMinMaxRule<double, DoubleProperty>(PropertyNames.MinScatterRadius, PropertyNames.MaxScatterRadius));

            PropertyCollection propertyCollection = new PropertyCollection(props, propertyRules);
            return propertyCollection;
        }
开发者ID:metadeta96,项目名称:openpdn,代码行数:14,代码来源:FrostedGlassEffect.cs

示例14: OnCreatePropertyCollection

        protected override PropertyCollection OnCreatePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(new Int32Property(PropertyNames.Amount, 45, -200, 100));

            props.Add(new DoubleVectorProperty(
                PropertyNames.Offset,
                Pair.Create(0.0, 0.0),
                Pair.Create(-1.0, -1.0),
                Pair.Create(1.0, 1.0)));

            return new PropertyCollection(props);
        }
开发者ID:metadeta96,项目名称:openpdn,代码行数:14,代码来源:BulgeEffect.cs

示例15: OnCreateSavePropertyCollection

        public override PropertyCollection OnCreateSavePropertyCollection()
        {
            List<Property> props = new List<Property>();

            props.Add(StaticListChoiceProperty.CreateForEnum<BmpBitDepthUIChoices>(PropertyNames.BitDepth, BmpBitDepthUIChoices.AutoDetect, false));
            props.Add(new Int32Property(PropertyNames.DitherLevel, 7, 0, 8));

            List<PropertyCollectionRule> rules = new List<PropertyCollectionRule>();

            rules.Add(new ReadOnlyBoundToValueRule<object, StaticListChoiceProperty>(PropertyNames.DitherLevel, PropertyNames.BitDepth, BmpBitDepthUIChoices.Bpp8, true));

            PropertyCollection pc = new PropertyCollection(props, rules);

            return pc;
        }
开发者ID:metadeta96,项目名称:openpdn,代码行数:15,代码来源:BmpFileType.cs


注:本文中的PaintDotNet.List.Add方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。