[pdftex-Feature Requests][743] Fake beginning/end of line for protrusion
Feature Requests item #743, was opened at 2007-03-06 02:20 Status: Open Priority: 3 Submitted By: Robert (schlcht) Assigned to: The Thanh Han (hanthethanh) Summary: Fake beginning/end of line for protrusion Category: HZ Group: v1.50 Resolution: Accepted Initial Comment: Although the situation with missing protrusion has certainly improved, there are still a lot of cases where characters will not be protruded (e.g. with indented paragraphs, at the beginning of list items, or of table cells). So I think it would be useful to have some commands that make pdftex believe that it is at the beginning or end of a line (e.g. \protchar{left,right}). So that you could for instance say: \item\protcharleft ``... Difficult? ---------------------------------------------------------------------- Comment By: Robert (schlcht) Date: 2009-06-27 21:14 Message: Any news with this feature request? ---------------------------------------------------------------------- Comment By: The Thanh Han (hanthethanh) Date: 2007-03-07 09:52 Message: Logged In: YES user_id=710 yes inserting a whatsit node that would be changed to a kern seems the easiest way. I will give a try soon. ---------------------------------------------------------------------- Comment By: Robert (schlcht) Date: 2007-03-06 17:21 Message: Logged In: YES user_id=2217 Maybe new (whatsit) nodes that can be caught in find_protchar_left/right? microtype is quite good in translating characters into slots (\MT@get@slot), but not really good enough to always allow natural input, e.g., ligatures and things like "` (German babel) won't be recognised. So my current workaround is: \def\protcharleft#1{% {\everypar{}% \setbox0\vbox{\noindent#1}% \vbadness=10000 \splittopskip=0pt \global\setbox0=\vsplit0 to \baselineskip \unvbox0 \global\setbox0=\lastbox}% \ifhbox0 \leavevmode \kern\leftmarginkern0 \fi #1} But this doesn't always work, e.g. in tabulars. Ligatures and other stuff still have to be enclosed in braces. ---------------------------------------------------------------------- Comment By: Taco Hoekwater (taco) Date: 2007-03-06 08:00 Message: Logged In: YES user_id=1608 I will be experimenting with Aleph's \localleftbox somewhere next month, that may be a starting point. But it is unlikely that any command based on that will be able to influence line breaking. ---------------------------------------------------------------------- Comment By: The Thanh Han (hanthethanh) Date: 2007-03-06 07:52 Message: Logged In: YES user_id=710 yes it makes sense. I am not sure whether \protcharleft could be implemented as macro: one can fetch the next char, get the lpcode and do a corresponding kern. However I don't know how to convert a character to its charcode to fetch the relevant lpcode. Another problem is that if the next char is part of a ligature (as in your example), it doesn't work. Looks like a primitive is needed. Does anyone have a suggestion how it could be implemented? ---------------------------------------------------------------------- You can respond by visiting: http://sarovar.org/tracker/?func=detail&atid=496&aid=743&group_id=106
participants (1)
-
pdftex-featurerequests@sarovar.org