Extend the WritingModes API. Bug 735577, r=jfkthame

This commit is contained in:
Simon Montagu 2014-02-12 23:55:08 -08:00
Родитель 8eb855ca1c
Коммит 1ca7304c0e
1 изменённых файлов: 15 добавлений и 0 удалений

Просмотреть файл

@ -192,6 +192,21 @@ public:
}
}
// For unicode-bidi: plaintext, reset the direction of the writing mode from
// the bidi paragraph level of the content
//XXX change uint8_t to UBiDiLevel after bug 924851
void SetDirectionFromBidiLevel(uint8_t level)
{
if (level & 1) {
// odd level, set RTL
mWritingMode |= eBidiMask;
} else {
// even level, set LTR
mWritingMode &= ~eBidiMask;
}
}
/**
* Compare two WritingModes for equality.
*/