How to disable xml Document in Author

Post here questions and problems related to oXygen frameworks/document types.
sebastienlavandier
Posts: 124
Joined: Tue May 29, 2012 5:42 pm

How to disable xml Document in Author

Post by sebastienlavandier »

Hello,

I want to know if it's possible to disable an Xml Document when it opening, maybe by using a framework ? which method can I use ?

In a second step, if user do a right click on the Xml document, I want to proposed him to enable this document.

Do you think that is possible ?

Thanks in advance you for your answer.
Best regards.
Seb.L
Radu
Posts: 9041
Joined: Fri Jul 09, 2004 5:18 pm

Re: How to disable xml Document in Author

Post by Radu »

Hi Sebastien,

What do you mean by "disable"? Do you mean not-editable?

We have some API like:

Code: Select all

ro.sync.exml.workspace.api.editor.page.WSTextBasedEditorPage.setEditable(boolean)
which might be useful to you.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
sebastienlavandier
Posts: 124
Joined: Tue May 29, 2012 5:42 pm

Re: How to disable xml Document in Author

Post by sebastienlavandier »

Hello Radu,
Thank you very much for your help.
Bye
sebastienlavandier
Posts: 124
Joined: Tue May 29, 2012 5:42 pm

Re: How to disable xml Document in Author

Post by sebastienlavandier »

Hi Radu,

Now, with the new 14.2 version I want to know how it's possible to disable xml document in text mode ?

Thanks in advance for your help.
Sébastien
adrian
Posts: 2853
Joined: Tue May 17, 2005 4:01 pm

Re: How to disable xml Document in Author

Post by adrian »

Hi,

Can you please clarify what you understand by "disable xml document"?
Do you want to hide the Text mode and make it inaccessible to the user?

Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
sebastienlavandier
Posts: 124
Joined: Tue May 29, 2012 5:42 pm

Re: How to disable xml Document in Author

Post by sebastienlavandier »

No, I just want that a user can't modify the document in text mode, like it's possible in author mode.
adrian
Posts: 2853
Joined: Tue May 17, 2005 4:01 pm

Re: How to disable xml Document in Author

Post by adrian »

There is no user option that does this. But, you can use the API that Radu mentioned:
ro.sync.exml.workspace.api.editor.page.WSTextBasedEditorPage.setEditable(boolean)

Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
sebastienlavandier
Posts: 124
Joined: Tue May 29, 2012 5:42 pm

Re: How to disable xml Document in Author

Post by sebastienlavandier »

Thanks you for your help.
Sébastien
Post Reply