Coder Social home page Coder Social logo

Tibetan line breaks about babel HOT 3 OPEN

BenjaminGalliot avatar BenjaminGalliot commented on July 30, 2024
Tibetan line breaks

from babel.

Comments (3)

jbezos avatar jbezos commented on July 30, 2024 1

(Related to #250 but I can’t reopen this issue, so I moved messages here.)

Please, don’t ask new questions in closed issues, even if related. I can overlook them easily.

As to the line breaking, you can make spaces in shads and tshegs more flexible with, for example:

\directlua{
  Babel.tibetan.shad = {.5, .5, 0, false}
  Babel.tibetan.tsheg = {0, .001, 0, false}
}

See https://latex3.github.io/babel/news/whats-new-in-babel-3.81.html

I’ll modify the rules so that closing characters are dealt with. In the meanwhile, you can modify babel-tibetan.tex in the following way. Replace:

 \babelprehyphenation{tibetan}{^^^^0f0b[^ ^^^^0f0d^^^^0f0e]}%
    { {insert, penalty=10000}, {insert, space=\bbl@tempe, data=1}, {},
      {insert, space=\bbl@tempe, data=1}, {} }}

with

  \babelprehyphenation{tibetan}{^^^^0f0b[^ {)}^^^^0f0d^^^^0f0e]}%
    { {insert, penalty=10000}, {insert, space=\bbl@tempe, data=1}, {},
      {insert, space=\bbl@tempe, data=1}, {} }}

Another question: is there a simple way to prevent a single syllable from being alone on its line (beginning – in the case where the line incorporates other languages just before – or end)?

Very likely it's possible with luatex, but I have to investigate.

A last one: བོུ། seems to be rendered as བོ◌ུ།, how to correct that?

The rendering of characters depends, in principle, on the renderer or the font. Try with HarfBuzz.

from babel.

BenjaminGalliot avatar BenjaminGalliot commented on July 30, 2024

Please, don’t ask new questions in closed issues, even if related. I can overlook them easily.

I hesitated, but you said "If you need further help, just continue this thread.", but after some days without any news, I started this new issue!

Thanks for the help, in LuaLaTeX, the line break, the management of the closing parenthesis and the rendering by Harfbuzz worked!

Do you have any idea of the unexpected behavior in XeLaTeX with foreignlanguage and selectlanguage?

Very likely it's possible with luatex, but I have to investigate.

Thank you!

from babel.

jbezos avatar jbezos commented on July 30, 2024

I hesitated, but you said "If you need further help, just continue this thread.", but after some days without any news, I started this new issue!

Quite true. But 8 months have passed! 🙂

Line breaking in xetex is hardcoded, but perhaps can be fine-tuned with the interchar mechanism (not sure).

from babel.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.