How to get Optical Margins Both Sides working?

Previous topic - Next topic

soukie

I am using Scribus 1.4.0 and when I apply Optical Margins as Both Sides or Left Side, characters such as quotes do not display as hanging on the left side (in preview or printed PDF) but they do appear as hanging on the right side (when Right or Both Sides is selected).

Any ideas if there is some other setting interfering with this, or could it be a bug?

Thanks!

Meho R.

It sounds like a bug. I asked about this on mailing list, another user confirmed that left optical margin isn't working, so I'll wait a little bit to see if any of devs comment.

Meho R.


NathanUp

It's been twelve years now; does anyone have insight on this bug? Is this something that's technically quite difficult to do, has it been designated a low priority item, or is it just simply the case that no one has decided to look into it? It seems like a rather serious issue.
EndeavourOS | Down with Adobe!

a.l.e

a wild guess: left optical margins are less common than the right ones (and most people won't really notice that there is a problem)... and it might also be less well defined which characters should behave in which way...
in the ticket you're linking to, there are a few examples, but it's not clear what is the list of characters to be "fixed".

probably, providing a list of clear rules can help the feature to be implemented.

utnik

imho 'optical margins' on the left side (in ltr languages) are much less crucial than on the right side. but it would still be nice to see dashes, quotation marks and ellipsis protruding on either side if 'optical margins' are applied.
...and what is suggested in the other request would make a lot of sense: two independent checkboxes for 'left' and 'right' instead of four radio buttons. (and probably including them in the 'advanced settings' tab...)

utnik

a.l.e

utnik, don't say it too loud, otherwise nitramr will do it : - )

(psssst... i have assigned the ticket to him...)

NathanUp

Quote from: utnik on January 05, 2024, 12:13:06 PMit would still be nice to see dashes, quotation marks and ellipsis protruding on either side if 'optical margins' are applied.

Wikipedia has the following suggested values for common seriffed fonts:

" " " ' ' ', .100%
hyphen75%
en-dash50%
em-dash25%

(The Wikipedia page also links to a good article explaining why it's important to hang punctuation).

The CSS Text 3 spec 8.2.1 (Hanging Punctuation: the hanging-punctuation property) may a good way to determine which characters should hang from the beginning and end of a line:
  • Beginning: "all characters in the Unicode categories Ps, Pf, Pi plus the ASCII quote marks U+0027 ' APOSTROPHE and U+0022 " QUOTATION MARK and the IDEOGRAPHIC SPACE U+3000"
  • End: "all characters in the Unicode categories Pe, Pf, Pi plus the ASCII quote marks U+0027 ' APOSTROPHE and U+0022 " QUOTATION MARK"

In addition, the following stops and commas will hang at the end of a line:

U+002C,COMMA
U+002.FULL STOP
U+060C،ARABIC COMMA
U+06D4۔ARABIC FULL STOP
U+3001IDEOGRAPHIC COMMA
U+3002IDEOGRAPHIC FULL STOP
U+FF0CFULLWIDTH COMMA
U+FF0EFULLWIDTH FULL STOP
U+FE50SMALL COMMA
U+FE51SMALL IDEOGRAPHIC COMMA
U+FE52SMALL FULL STOP
U+FF61HALFWIDTH IDEOGRAPHIC FULL STOP
U+FF64HALFWIDTH IDEOGRAPHIC COMMA
EndeavourOS | Down with Adobe!

MrB

Left Optical Margins specific calculation code is commented out in pageitem_textframe. Not sure why but it was never fully implemented. The rest of the layout code does not even consider it from what I see.