multiple Unicode fonts for content?
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 2
- Joined: Tue Apr 02, 2013 5:39 pm
multiple Unicode fonts for content?
I didn't see this issue addressed earlier, but forgive me if I missed something.
I have XML with content in three languages (English, Arabic, and Syriac), and I cannot make all three appear as text at the same time. The Arial Unicode MS font covers the codeblocks for English and Arabic, but renders the Syriac as boxes. I have Unicode fonts that cover the Syriac codeblock (Estrangelo Edessa, e.g.), but not the Arabic, so using that font renders the Arabic as boxes. Is there a way to use Estrangelo Edessa for Syriac text and Arial Unicode MS for everything else in the Oxygen text editor?
Interestingly, Windows and Mac OS handle this differently (I don't know about Linux, sorry): I'm running a Windows 7 machine, but my boss who uses a Mac has everything display properly if he sets his font to Estrangelo Edessa, because the system supplies another font (I think Arial Unicode MS) for those Unicode characters not covered by Estrangelo Edessa, so it works fine for him.
I appreciate any help!
Thomas.
I have XML with content in three languages (English, Arabic, and Syriac), and I cannot make all three appear as text at the same time. The Arial Unicode MS font covers the codeblocks for English and Arabic, but renders the Syriac as boxes. I have Unicode fonts that cover the Syriac codeblock (Estrangelo Edessa, e.g.), but not the Arabic, so using that font renders the Arabic as boxes. Is there a way to use Estrangelo Edessa for Syriac text and Arial Unicode MS for everything else in the Oxygen text editor?
Interestingly, Windows and Mac OS handle this differently (I don't know about Linux, sorry): I'm running a Windows 7 machine, but my boss who uses a Mac has everything display properly if he sets his font to Estrangelo Edessa, because the system supplies another font (I think Arial Unicode MS) for those Unicode characters not covered by Estrangelo Edessa, so it works fine for him.
I appreciate any help!
Thomas.
-
- Posts: 407
- Joined: Mon Dec 05, 2011 6:08 pm
Re: multiple Unicode fonts for content?
Hello,
To investigate this issue could you please send us a sample XML file with this mixed content (English, Arabic and Syriac charsets) to our support email address: support AT oxygenxml DOT com
Regards,
Ionela
To investigate this issue could you please send us a sample XML file with this mixed content (English, Arabic and Syriac charsets) to our support email address: support AT oxygenxml DOT com
Regards,
Ionela
Ionela Istodor
oXygen XML Editor and Author Support
oXygen XML Editor and Author Support
-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: multiple Unicode fonts for content?
Hello Thomas,
First, please note that Oxygen is a Java application and as far as we know Java still has some issues with Syriac writing. There's a report here: Report on Dealing with Syriac in Unitex and Java
The most significant problem for the Syriac writing in Java that also affects Oxygen is that "The characters in a word don’t link together". We've had at least one report of this problem.
Unfortunately, for the Text mode in Oxygen the only solution for combining English, Arabic and Syriac writing is rather complicated, because you can only use one font at a time. Usually, setting a logical font like Monospaced, Serif or SansSerif in the Oxygen font options resolves this problem. However, this assumes that all used character sets are mapped to corresponding physical fonts in the Java font configuration. Unfortunately, this is not the case for Syriac.
The solution for the Text mode would be to customize the Java font configuration file from the JRE and map the Estrangelo Edessa font (or similar) to one or several logical fonts. I'm still looking into this, it doesn't seem trivial.
A simpler solution for Oxygen would be to use the Author mode. The only issue with the Author mode for your use case is that it does not yet fully support RTL writing.
You are editing TEI documents (as seen in the sample you've sent) that Oxygen already supports in Author mode, so this would be a good alternative. The Author mode allows CSS customization, so it's pretty easy to write a simple CSS that specifies a certain font family for a specific element from the document. In your case, you can specify the 'Estrangelo Edessa' font for elements that contain the attribute xml:lang="syr".
The CSS looks like this:
Save this CSS to a file. Test this CSS with your XML document in Author by associating the CSS: Document > XML Document > Associate XSLT/CSS Stylesheet. Browse for this CSS file and associate it. Then you can switch to Author mode: Document > Edit Mode > Author
Note that this overrides the default CSS for TEI, but we can go into details about resolving this, if you are interested in pursuing this alternative.
Regards,
Adrian
First, please note that Oxygen is a Java application and as far as we know Java still has some issues with Syriac writing. There's a report here: Report on Dealing with Syriac in Unitex and Java
The most significant problem for the Syriac writing in Java that also affects Oxygen is that "The characters in a word don’t link together". We've had at least one report of this problem.
Unfortunately, for the Text mode in Oxygen the only solution for combining English, Arabic and Syriac writing is rather complicated, because you can only use one font at a time. Usually, setting a logical font like Monospaced, Serif or SansSerif in the Oxygen font options resolves this problem. However, this assumes that all used character sets are mapped to corresponding physical fonts in the Java font configuration. Unfortunately, this is not the case for Syriac.
The solution for the Text mode would be to customize the Java font configuration file from the JRE and map the Estrangelo Edessa font (or similar) to one or several logical fonts. I'm still looking into this, it doesn't seem trivial.
A simpler solution for Oxygen would be to use the Author mode. The only issue with the Author mode for your use case is that it does not yet fully support RTL writing.
You are editing TEI documents (as seen in the sample you've sent) that Oxygen already supports in Author mode, so this would be a good alternative. The Author mode allows CSS customization, so it's pretty easy to write a simple CSS that specifies a certain font family for a specific element from the document. In your case, you can specify the 'Estrangelo Edessa' font for elements that contain the attribute xml:lang="syr".
The CSS looks like this:
Code: Select all
@namespace xml "http://www.w3.org/XML/1998/namespace";
*[xml|lang = 'syr'] {
font-family: 'Estrangelo Edessa';
}
Note that this overrides the default CSS for TEI, but we can go into details about resolving this, if you are interested in pursuing this alternative.
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
-
- Posts: 2
- Joined: Tue Apr 02, 2013 5:39 pm
Re: multiple Unicode fonts for content?
Dear Adrian,
Thanks for looking into this. I associated the CSS file containing the code you posted, and in Author mode the Syriac text appears as Syriac characters, but backwards (LTR instead of RTL). In Text mode, the Syriac appears as boxes, but based on the spaces and the cursor behavior I can tell that it is attempting to display it RTL (the correct direction). Is this the expected behavior for Author mode?
If someone were to create a font which had characters for the Syriac, Latin, and Arabic blocks of Unicode, would that solve the problem for Text mode? I think I know someone who might be willing to put together such a font.
Thank you again!
Thomas.
Thanks for looking into this. I associated the CSS file containing the code you posted, and in Author mode the Syriac text appears as Syriac characters, but backwards (LTR instead of RTL). In Text mode, the Syriac appears as boxes, but based on the spaces and the cursor behavior I can tell that it is attempting to display it RTL (the correct direction). Is this the expected behavior for Author mode?
If someone were to create a font which had characters for the Syriac, Latin, and Arabic blocks of Unicode, would that solve the problem for Text mode? I think I know someone who might be willing to put together such a font.
Thank you again!
Thomas.
-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: multiple Unicode fonts for content?
Hi,
You are right, I didn't notice it when I first tried this, but in the Author mode the Syriac text is oriented LTR instead of RTL.
I've re-tested in the Text mode with the Estrangelo Edessa font and if I don't enable BiDi mode, the orientation for the Syriac text is again LTR instead of RTL. The same thing happens for the Author mode since it doesn't support the BiDi mode. This rules out the Author mode for Syriac text.
The Arabic text is not affected by this, it works correctly in both text and Author modes (but obviously with a different font).
Regarding the font, if you find/create a font with all three character sets, install it in the OS and configure it in Oxygen, it will work correctly in Text mode.
Please let us know if you are successful in using this solution.
Regards,
Adrian
You are right, I didn't notice it when I first tried this, but in the Author mode the Syriac text is oriented LTR instead of RTL.
I've re-tested in the Text mode with the Estrangelo Edessa font and if I don't enable BiDi mode, the orientation for the Syriac text is again LTR instead of RTL. The same thing happens for the Author mode since it doesn't support the BiDi mode. This rules out the Author mode for Syriac text.
The Arabic text is not affected by this, it works correctly in both text and Author modes (but obviously with a different font).
Regarding the font, if you find/create a font with all three character sets, install it in the OS and configure it in Oxygen, it will work correctly in Text mode.
Please let us know if you are successful in using this solution.
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
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