[ 
https://issues.apache.org/jira/browse/PDFBOX-4189?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16438914#comment-16438914
 ] 

John Hewson edited comment on PDFBOX-4189 at 4/16/18 1:41 AM:
--------------------------------------------------------------

{quote}
For correct text positioning using mixed language information from the 
following tables might be useful:
- GPOS: to adjust the glyph position
- BASE: baseline offsets on a script-by-script basis.
- JSTF: justification information, including whitespace and Kashida adjustments.
- BIDI Mirroring: 
https://www.unicode.org/Public/10.0.0/ucd/BidiMirroring.txt{quote}

It's probably worth noting that BASE, JSTF and BiDi are concerned with 
_paragraph-level_ layout, which happens at a higher level than the proposed 
layout() - which would be concerned with only a single script in a single 
direction (i.e. only OpenType _shaping_). BASE and BiDi are related to changes 
between different scripts, while JSTF is to aid in making good line break 
choices. So all of that functionality will happen somewhere else (this fits 
very closely with the layout code form forms, for example). So in layout we're 
really only going to be concerned with GPOS and GSUB features. That way the 
only options that one might want to pass to layout would be this list of which 
[feature 
flags|https://docs.microsoft.com/en-us/typography/opentype/spec/featurelist] to 
apply.

Maybe layout() should be called shapeText() to emphasize this distinction?


was (Author: jahewson):
{quote}
For correct text positioning using mixed language information from the 
following tables might be useful:
- GPOS: to adjust the glyph position
- BASE: baseline offsets on a script-by-script basis.
- JSTF: justification information, including whitespace and Kashida adjustments.
- BIDI Mirroring: 
https://www.unicode.org/Public/10.0.0/ucd/BidiMirroring.txt{quote}

It's probably worth noting that BASE, JSTF and BiDi are concerned with 
_paragraph-level_ layout, which happens at a higher level than the proposed 
layout() - which would be concerned with only a single script in a single 
direction (i.e. only OpenType _shaping_). BASE and BiDi are related to changes 
between different scripts, while JSTF is to aid in making good line break 
choices. So all of that functionality will happen somewhere else (this fits 
very closely with the layout code form forms, for example). So in layout we're 
really only going to be concerned with GPOS and GSUB features. That way the 
only options that one might want to pass to layout would be this list of which 
[feature 
flags|https://docs.microsoft.com/en-us/typography/opentype/spec/featurelist] to 
apply.

> Enable rendering of Indian languages, by reading and utilizing the GSUB table
> -----------------------------------------------------------------------------
>
>                 Key: PDFBOX-4189
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-4189
>             Project: PDFBox
>          Issue Type: New Feature
>          Components: FontBox, PDModel
>            Reporter: Palash Ray
>            Priority: Major
>         Attachments: Bengali-text-after.pdf, Bengali-text-before.pdf
>
>   Original Estimate: 336h
>  Remaining Estimate: 336h
>
> Implemented proper rendering of Indian languages, which need extensive Glyph 
> substitution. The GSUB table has been read and used effectively to replace 
> some compound words with their respective Glyphs. All tests are passing. I 
> have tested this for the Bengali font. Please review these changes and let me 
> know if it makes sense to incorporate these.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org

Reply via email to