Пример #1
0
        public RtfImage addImageFromUrl(string url, string name, ImageFileType type)
        {
            if (!_allowImage)
            {
                throw new Exception("Image is not allowed.");
            }
            RtfImage block = new RtfImage(url, name, type);

            addBlock(block);
            return(block);
        }
Пример #2
0
        /// <summary>
        /// Add an image to this container.
        /// </summary>
        /// <param name="imgFname">Filename of the image.</param>
        /// <param name="imgType">File type of the image.</param>
        /// <returns>Image being added.</returns>
        public RtfImage addImage(string imgFname, ImageFileType imgType)
        {
            if (!_allowImage)
            {
                throw new Exception("Image is not allowed.");
            }
            RtfImage block = new RtfImage(imgFname, imgType);

            addBlock(block);
            return(block);
        }
Пример #3
0
        public RtfImage addImage(System.Drawing.Image ImageIn, ImageFileType imgType)
        {
            if (!_allowImage)
            {
                throw new Exception("Image is not allowed.");
            }
            RtfImage block = new RtfImage(ImageIn, imgType);

            addBlock(block);
            return(block);
        }
Пример #4
0
		/// <summary>
		/// Add an image to this container.
		/// </summary>
		/// <param name="imgFname">Filename of the image.</param>
		/// <param name="imgType">File type of the image.</param>
		/// <returns>Image being added.</returns>
		public RtfImage addImage(string imgFname, ImageFileType imgType)
		{
			if (!_allowImage) {
				throw new Exception("Image is not allowed.");
			}
			RtfImage block = new RtfImage(imgFname, imgType);
			addBlock(block);
			return block;
		}