Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using this font in XeLaTeX #1

Open
rdholkar opened this issue Feb 14, 2018 · 4 comments
Open

Using this font in XeLaTeX #1

rdholkar opened this issue Feb 14, 2018 · 4 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@rdholkar
Copy link

rdholkar commented Feb 14, 2018

Hi,

thank you for this font! I could use this font in XeLaTeX; following is the MWE:

\documentclass{article}
\usepackage{polyglossia}
\setdefaultlanguage{marathi}
\newfontfamily{\devanagarifont}{MarathiCursiveT}
\setmainfont[Script=Devanagari]{MarathiCursiveT}
\begin{document}
मोडी मधील लाटेक्-वापरून बनवलेला पहिला दस्तऐवज.
\end{document}

However, in the output the line on the top of the words breaks when there is space in the source; this should not happen, and neither does this happen in Pages (OSX document editor). How can one overcome this issue?

@MihailJP MihailJP added bug Something isn't working help wanted Extra attention is needed labels Jun 27, 2018
@abhi-deshpande
Copy link

abhi-deshpande commented Apr 14, 2021

I noticed that when we explicitly define that whitespace character in our content, XeLaTeX correctly identifies it..! Although this should not be required, it may give us a clue of what may be defected.

I used the following XeLaTeX code (MarathiCursive 2.1 is used) :

\documentclass{article}
\usepackage{fontspec}
\setmainfont{MarathiCursive}
\begin{document}
𑘮𑘱\char"0020𑘦𑘻𑘚𑘲\char"0020𑘩𑘱𑘢𑘲\char"0020𑘁𑘮𑘹.
\end{document}

And the output was :
image

In the above image, some characters are misplaced, but the topline is working correctly. Also, it may be possible that its a XeLaTeX bug.

@khaledhosny
Copy link

Newer version of XeTeX has \XeTeXinterwordspaceshaping (default is 0, try with 1 and 2).

@abhi-deshpande
Copy link

abhi-deshpande commented Apr 17, 2021

@khaledhosny you were right on that count. I added \XeTeXinterwordspaceshaping=2 in my above code & removed the definition of whitespace from content. The topline worked correctly...! Although, the characters are still misplaced. This misplacing can also be seen in Scribus. This still needs to be worked out.

@abhi-deshpande
Copy link

abhi-deshpande commented Apr 21, 2021

@khaledhosny I diagnosed this issue a bit deeper and found that the misplacing of characters in XeLaTeX was due to the fact that I was not using Renderer=Graphite I found one of your thread here. By using the code in that post, I was able to enable Graphite renderer. MarathiCursiveG is working flawlessly there.

I am sharing my code for someone finding references or help :

\documentclass{article}
\usepackage{fontspec}
\newfontfamily\graphite[Renderer=Graphite]{MarathiCursiveG}
\XeTeXinterwordspaceshaping=2
\begin{document}
\graphite 𑘮𑘱 𑘦𑘻𑘚𑘲 𑘩𑘱𑘢𑘲 𑘁𑘮𑘹.
\end{document}

I got the accurate output :
image

Now speaking about Scribus, It currently does not have Graphite support, as mentioned in this open bug :

We have already made test with Harfbuzz graphite support. There are currently some difference on how Harfbuzz graphite engine provides results compared to the Opentype engine and amongst other things this triggers issues with OpenType fonts which contains both OpenType and Graphite features. As of now Graphite support is completely disabled in Scribus and Harfbuzz explicitly instructed not to use its graphite engine.

So it seems that this issue is completely solved. Thanks @khaledhosny & @MihailJP for their outstanding work in typography...!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

4 participants