(fig)
| 1202 | |
| 1203 | |
| 1204 | def _test_complex_shaping(fig): |
| 1205 | # Raqm is Arabic for writing; note that because Arabic is RTL, the characters here |
| 1206 | # may seem to be in a different order than expected, but libraqm will order them |
| 1207 | # correctly for us. |
| 1208 | text = ( |
| 1209 | 'Arabic: \N{Arabic Letter REH}\N{Arabic FATHA}\N{Arabic Letter QAF}' |
| 1210 | '\N{Arabic SUKUN}\N{Arabic Letter MEEM}') |
| 1211 | math_signs = '\N{N-ary Product}\N{N-ary Coproduct}\N{N-ary summation}\N{Integral}' |
| 1212 | text = math_signs + text + math_signs |
| 1213 | fig.text(0.5, 0.75, text, size=32, ha='center', va='center') |
| 1214 | # Also check fallback behaviour: |
| 1215 | # - English should use cmr10 |
| 1216 | # - Math signs should use DejaVu Sans Display (and thus be larger than the rest) |
| 1217 | # - Arabic should use DejaVu Sans |
| 1218 | fig.text(0.5, 0.25, text, size=32, ha='center', va='center', |
| 1219 | family=['cmr10', 'DejaVu Sans Display', 'DejaVu Sans']) |
| 1220 | |
| 1221 | |
| 1222 | @image_comparison(['complex'], extensions=['png', 'pdf', 'svg', 'eps'], style='mpl20') |
no test coverage detected
searching dependent graphs…