On 05/02/2013 04:21 PM, Fabián Mandelbaum wrote:
we've implemented a copy-as-reference from our web application by
generating the same text generated by XXE on the clipboard for the same
operation (Open a file, select the root node, Copy as reference, open an
ASCII text editor, paste).
If we open XXE 5.4.0, and create a new document or open an existing one,
the paste button is enabled and we can indeed paste the clipboard
contents as a reference.
If we instead open XXE 5.6.0, and create a new document or open an
existing one, the paste button is disabled, we cannot paste the
clipboard contents as a reference. We can though, paste the clipboard
content as text (for example, inside a para, we get the same content we
got on the ASCII editor).
Yes, indeed. This new behavior is described here:
http://www.xmlmind.com/xmleditor/changes.html#v5.6.0
---
Incompatibilities:
* It is no longer possible to paste XML into XXE when some plain text
has been copied to the clipboard and this, even when the copied text
starts with "<?xml ".
---
Please find below an excerpt of the clipboard contents for one of our
tests. Why is it not working anymore on XXE 5.6.0?
Is the clipboard format documented somewhere?
Thanks in advance for your answer.
This is not a problem of the format. The clipboard format has not
changed in XXE 5.6.0.
An external application copying some XML to the clipboard for use by XXE
must now declare the copied data as being "application/xml" (or "text/xml").
In a nutshell, XXE 5.6.0 makes a difference between "text/plain" and
"application/xml", while XXE 5.4.0 ignored "application/xml" and
``sniffed'' the "text/plain" in order the detect the case where this
text was actually XML (starts with "<?xml ").
References:
*
http://www.xmlmind.com/xmleditor/_distrib/doc/api/com/xmlmind/xmledit/edit/XMLClipboard.html
*
http://www.xmlmind.com/xmleditor/_distrib/doc/api/com/xmlmind/xmledit/edit/XMLTransferable.html
---- clipboard contents -----
<?xml version="1.0"?><ns:clipboard
ns2:inclusion="com.xmlmind.xml.xinclude.XInclude:href="http://localhost:9000/workspaces/W1/content/en_US/Calenco-v23-api.xml"
xpointer="workspaces-get"" ns2:readOnly="true"
ns2:sourceURL="http://localhost:9000/workspaces/W1/content/en_US/Calenco-v23-api.xml"
xmlns:ns2="http://www.xmlmind.com/xmleditor/namespace/property"
xmlns:ns="http://www.xmlmind.com/xmleditor/namespace/clipboard"><section
xmlns="http://docbook.org/ns/docbook"
xml:id="workspaces-get"><info><title>List
Workspaces</title></info><section><info><title>Request</title></info><programlisting>GET
/workspaces</programlisting></section><section><info><title>Response</title></info><programlisting>[
{ name: 'W1', isActive: true, autoRegistrable: false, href:
'/workspaces/W1' }, { name: 'An Inactive Workspace', isActive: false,
autoRegistrable: false, href: '/workspaces/An Inactive Workspace' }
]</programlisting><note><para>If the user has role S, all workspaces are
listed; otherwise, only the workspaces the user has access to are
listed.</para></note></section></section></ns:clipboard>
-------------------------------------
--
XMLmind XML Editor Support List
[email protected]
http://www.xmlmind.com/mailman/listinfo/xmleditor-support