[xwiki-users] Is there an easy way to copy paste multiple images onto a page?
One question I have about the very useful feature of xwiki is how to drag and drop multiple images onto a page. Offhand xmarks seems to create an image attachment called image.png; pasting another image onto the same page overwrites the first image, using with the same name. Any way to have xwiki increment the image names? I know I can attach the image and then reference it in the page but it's more work. -- View this message in context: http://xwiki.475771.n2.nabble.com/Is-there-an-easy-way-to-copy-paste-multipl... Sent from the XWiki- Users mailing list archive at Nabble.com.
On Sat, Dec 31, 2016 at 12:01 AM, novnovice <novnovice@gmail.com> wrote:
One question I have about the very useful feature of xwiki is how to drag and drop multiple images onto a page. Offhand xmarks seems to create an image attachment called image.png; pasting another image onto the same page overwrites the first image, using with the same name. Any way to have xwiki increment the image names? I know I can attach the image and then reference it in the page but it's more work.
I can drag & drop multiple images at the same time on the CKEditor (in edit mode) and they are attached with their file name, not "image.png". It's not clear where you drop your images.
-- View this message in context: http://xwiki.475771.n2.nabble. com/Is-there-an-easy-way-to-copy-paste-multiple-images- onto-a-page-tp7602229.html Sent from the XWiki- Users mailing list archive at Nabble.com.
That's interesting...I just tried it again and at first it seemed that the issue was solved. Several pasted images were added to the page, each with it's own distinct name. I was copy/pasting from saved files. I made some additional experiments and discovered how it was that I saw that image replacement behavior. In my original tests I was taking a screenshot, and pasting the image in directly from the buffer. In each case the image was named "image.png" and effectively the second copy/paste overwrote the first image. The screen capture software offers the image in each case with the name image.png. So it's not really an issue with xwiki. My legacy patterns which I hope to replace in part with xwiki involve pasting images into word documents as I'm documenting a process. Word does not retain the image as a file per se; it absorbs the file, and so there is no assigned file name, or chance of file name conflict. xwiki does save the image as a file and has no mechanism (that I know of) for detecting that the two images are different and then saving the two images as separate files. If there is an add in that might mitigate this issue that would be ideal, but I might guess there is not. I may be able to defeat the brain dead clipboard paste name of image.pgn, and that would solve things very well. Thank you for your input...since you reported, and I confirmed, that pasting multiple images can work, I had to look again at why it wasn't working in my test. -- View this message in context: http://xwiki.475771.n2.nabble.com/Is-there-an-easy-way-to-copy-paste-multipl... Sent from the XWiki- Users mailing list archive at Nabble.com.
On Wed, Jan 4, 2017 at 4:22 AM, novnovice <novnovice@gmail.com> wrote:
That's interesting...I just tried it again and at first it seemed that the issue was solved. Several pasted images were added to the page, each with it's own distinct name. I was copy/pasting from saved files.
I made some additional experiments and discovered how it was that I saw that image replacement behavior. In my original tests I was taking a screenshot, and pasting the image in directly from the buffer. In each case the image was named "image.png" and effectively the second copy/paste overwrote the first image. The screen capture software offers the image in each case with the name image.png.
So it's not really an issue with xwiki. My legacy patterns which I hope to replace in part with xwiki involve pasting images into word documents as I'm documenting a process. Word does not retain the image as a file per se; it absorbs the file, and so there is no assigned file name, or chance of file name conflict. xwiki does save the image as a file and has no mechanism (that I know of) for detecting that the two images are different and then saving the two images as separate files.
The CKEditor uses the file name specified by the OS/Browser. If the file name is not specified then it uses a default name https://github.com/xwiki-contrib/application-ckeditor/blob/master/ui/src/mai... which leads to a random (unique) attachment name https://github.com/xwiki-contrib/application-ckeditor/blob/master/ui/src/mai... . So the fact that the attachment is saved as "image.png" in your case it indicates that the OS / Browser / the image source (where you copied it from, e.g. the clipboard) specifies the "image.png" name. So CKEditor has to use it. Note that in some cases you want to overwrite an existing attachment. You edit a page that has an image and you want to upload a different image with the same name to replace it.
If there is an add in that might mitigate this issue that would be ideal, but I might guess there is not. I may be able to defeat the brain dead clipboard paste name of image.pgn, and that would solve things very well.
Thank you for your input...since you reported, and I confirmed, that pasting multiple images can work, I had to look again at why it wasn't working in my test.
-- View this message in context: http://xwiki.475771.n2.nabble. com/Is-there-an-easy-way-to-copy-paste-multiple-images- onto-a-page-tp7602229p7602259.html Sent from the XWiki- Users mailing list archive at Nabble.com.
participants (2)
-
Marius Dumitru Florea -
novnovice