Entity auto complete not working in V10.3 ?
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 4
- Joined: Fri Jul 03, 2009 5:58 am
Entity auto complete not working in V10.3 ?
I recently upgraded from V10.2 to V10.3 and it appears that the auto completion of custom entities is no longer working.
Only the standard &, ', >, < and " show in the list after typing &.
I have many custom entities defined for keyboard commands, common names etc and these used to show up in the auto completion list.
Is this a bug, a configuration issue or something that I've stuffed up ?
Thanks.
Only the standard &, ', >, < and " show in the list after typing &.
I have many custom entities defined for keyboard commands, common names etc and these used to show up in the auto completion list.
Is this a bug, a configuration issue or something that I've stuffed up ?
Thanks.
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: Entity auto complete not working in V10.3 ?
Post by sorin_ristache »
Hello,
Entities should be displayed in the auto completion popup as in previous versions. If the schema of the document is large the initialization of the auto completion (of elements, attributes, entities) based on the schema could take some seconds. In such a case if you press '&' or '<' in the first seconds immediately after opening the XML document the initialization may not be finished yet and only the default 5 entities are available. Are all entities displayed if you wait for some more seconds before pressing '&'? If not please post or send a sample schema and XML document for reproducing the problem.
For example you know when the initialization is finished if you have Validate as you type enabled, your XML document is not valid and a validation error is displayed on the right side vertical stripe at a short time after opening the document and without modifying the document after opening it.
Regards,
Sorin
Entities should be displayed in the auto completion popup as in previous versions. If the schema of the document is large the initialization of the auto completion (of elements, attributes, entities) based on the schema could take some seconds. In such a case if you press '&' or '<' in the first seconds immediately after opening the XML document the initialization may not be finished yet and only the default 5 entities are available. Are all entities displayed if you wait for some more seconds before pressing '&'? If not please post or send a sample schema and XML document for reproducing the problem.
For example you know when the initialization is finished if you have Validate as you type enabled, your XML document is not valid and a validation error is displayed on the right side vertical stripe at a short time after opening the document and without modifying the document after opening it.
Regards,
Sorin
-
- Posts: 4
- Joined: Fri Jul 03, 2009 5:58 am
Re: Entity auto complete not working in V10.3 ?
Sorin,
Thank you for answering. It looks like a problem (probably mine) with how the entities are being included in my documents.
The entities for keys are defined in keys.txt similar to the following:
This is just a small example for illustration. The real file has hundreds of entries. The same thing is done to create entities for inline icon images etc.
The files to be included sit in the same directory as the DocBook chapter files. In all of the documents where the keys are used, the entity definitions are included:
Under V10.2 the auto completion would consider all of the entities defined in keys.txt. Now it does not show any of them.
The document still transforms into PDF with the entities included however.
I am quite new to DocBook, XML and <oXygen> so I appreciate any advice. If the whole method is wrong then let know how it should be done!
Thanks.
Thank you for answering. It looks like a problem (probably mine) with how the entities are being included in my documents.
The entities for keys are defined in keys.txt similar to the following:
Code: Select all
<!ENTITY keyTest "<keycap>Test</keycap>">
<!ENTITY keyHome "<keycap>Home</keycap>">
<!ENTITY keyEnter "<keycap>Enter</keycap>">
The files to be included sit in the same directory as the DocBook chapter files. In all of the documents where the keys are used, the entity definitions are included:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book
[
<!ENTITY % entity_Keys SYSTEM "keys.txt"> %entity_Keys;
]>
<chapter>
<Title>Chapter 1</Title>
<para>Press &keyHome; and everything will be revealed.</para>
</chapter>
The document still transforms into PDF with the entities included however.
I am quite new to DocBook, XML and <oXygen> so I appreciate any advice. If the whole method is wrong then let know how it should be done!
Thanks.
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: Entity auto complete not working in V10.3 ?
Post by sorin_ristache »
In version 10.3 your document is not associated with the DocBook 4 document type as in 10.2 but is should be because it does not specify a schema location, it specifies only the root element. We will fix the problem. Please insert the generic declaration for the DocBook DTD so that your document is associated with the DocBook 4 document type:
Regards,
Sorin
Code: Select all
<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.docbook.org/xml/4.4/docbookx.dtd"
[
<!ENTITY % entity_Keys SYSTEM "keys.txt"> %entity_Keys;
]>
Regards,
Sorin
-
- Posts: 4
- Joined: Fri Jul 03, 2009 5:58 am
Re: Entity auto complete not working in V10.3 ?
I would like to target DocBook 5.0.
The following is what I actually have in each chapter:
Sorry to mislead you with the previous snippet.
Is there a way to adapt this to V10.3?
The following is what I actually have in each chapter:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book
[
<!ENTITY % entity_Common SYSTEM "Entity_Common.txt"> %entity_Common;
<!ENTITY % entity_Icons SYSTEM "Entity_Icons.txt"> %entity_Icons;
<!ENTITY % entity_Menus SYSTEM "Entity_Menus.txt"> %entity_Menus;
<!ENTITY % entity_Samples SYSTEM "Entity_Samples.txt"> %entity_Samples;
]>
<chapter xml:id="Metadata" xmlns="http://docbook.org/ns/docbook" version="5.0">
<title>Managing Metadata</title>
<para>[etc]</para>
</chapter>
Is there a way to adapt this to V10.3?
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: Entity auto complete not working in V10.3 ?
Post by sorin_ristache »
Use a schema declaration like the following:
and enable the option Enable DTD/XML Schema processing in Preferences -> Document Type Association.
Regards,
Sorin
Code: Select all
<?oxygen RNGSchema="http://www.oasis-open.org/docbook/xml/5.0/rng/docbook.rng" type="xml"?>
<!DOCTYPE chapter
[
<!ENTITY % entity_Keys SYSTEM "keys.txt"> %entity_Keys;
]>
<chapter xml:id="Metadata" xmlns="http://docbook.org/ns/docbook" version="5.0">
...
Regards,
Sorin
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service