[FriBidi] Implementation of X6 in the FriBidi library

Eli Zaretskii eliz at gnu.org
Mon Sep 28 10:17:20 PDT 2009


Sorry if this is a FAQ, and please point me at it if it is.

The file fribidi-bidi.c in the FriBidi library has this code:

    for_run_list (pp, main_run_list)
      FriBidiCharType this_type = RL_TYPE (pp);
      if (FRIBIDI_IS_EXPLICIT_OR_BN (this_type))
	  /* X6. For all types besides RLE, LRE, RLO, LRO, and PDF:
	     a. Set the level of the current character to the current
	     embedding level.
	     b. Whenever the directional override status is not neutral,
	     reset the current character type to the directional override
	     status. */
	  RL_LEVEL (pp) = level;
	  if (!FRIBIDI_IS_NEUTRAL (override))
	    RL_TYPE (pp) = override;

Unless I'm misreading the code, this means that X6 is not applied to
characters whose original type is "WEAK BN".  However, UAX#9 does not
exempt WEAK BN characters from the override, so this looks like being
against the UAX#9 rules.

Am I missing something? are there good reasons for behaving like that?


More information about the fribidi mailing list