예제 #1
0
        internal override void WriteColorSpaceForNotStroking(MemoryStream stream, Resources resources)
        {
            _name = resources.AddResources(ResourceType.Pattern, _streamDict);
            IPDFPageOperation operation = new ColorSpaceForNonStroking(Name);

            operation.WriteBytes(stream);
            operation = new ColorForNonStrokingEx(new float[0], _name);
            operation.WriteBytes(stream);
        }
예제 #2
0
        internal override void WriteColorSpaceForNotStroking(MemoryStream stream, Resources resources)
        {
            PDFArray array = new PDFArray();

            array.AddItem(new PDFName(Name));
            array.AddItem(_dict);
            _name = resources.AddResources(ResourceType.ColorSpace, array);
            IPDFPageOperation operation = new ColorSpaceForNonStroking(_name);

            operation.WriteBytes(stream);
        }
예제 #3
0
        internal override void WriteColorSpaceForNotStroking(MemoryStream stream, Resources resources)
        {
            _name = resources.AddResources(ResourceType.Pattern, _streamDict);
            PDFArray colorspace = new PDFArray();

            colorspace.AddItem(new PDFName(Name));
            colorspace.AddItem(new PDFName(_color.Colorspace.Name));
            string            name      = resources.AddResources(ResourceType.ColorSpace, colorspace);
            IPDFPageOperation operation = new ColorSpaceForNonStroking(name);

            operation.WriteBytes(stream);
            operation = new ColorForNonStrokingEx(_color.ToArray(), _name);
            operation.WriteBytes(stream);
        }
예제 #4
0
        internal override bool WriteChangesForNotStroking(Colorspace newCS, MemoryStream stream, Resources resources)
        {
            PDFArray array = new PDFArray();

            array.AddItem(new PDFName(Name));
            array.AddItem(_dict);
            _name = resources.AddResources(ResourceType.ColorSpace, array);
            if (newCS is ICCBasedColorspace)
            {
                if (!_name.Equals((newCS as ICCBasedColorspace)._name))
                {
                    IPDFPageOperation operation = new ColorSpaceForNonStroking((newCS as ICCBasedColorspace)._name);
                    operation.WriteBytes(stream);
                }
            }
            else
            {
                newCS.WriteColorSpaceForNotStroking(stream, resources);
                return(true);
            }
            return(false);
        }
예제 #5
0
        internal override void WriteColorSpaceForNotStroking(MemoryStream stream, Resources resources)
        {
            IPDFPageOperation operation = new ColorSpaceForNonStroking(_name);

            operation.WriteBytes(stream);
        }