GNOME Bugzilla – Bug 354082
Slightly change font style sorting order
Last modified: 2012-01-26 04:59:35 UTC
Currently one may see in the font dialog style list: >> Condensed Light >> Light >> Condensed Light Oblique >> Light Oblique >> Condensed Medium >> Regular >> Narrow >> Condensed Oblique >> Oblique >> Narrow Oblique >> Condensed Bold >> Bold >> Condensed Bold Oblique >> Narrow Bold Oblique >> Bold Oblique This is sorting based on weight, slant, width, in that order. A more natural way to sort is to do width, weight, slant, to group the "Condensed"s together.
After checking Pango, I don't understand how Condensed is showing up before Light. The code seems correct to me. May be that something nasty is happening here, like the font having "Condensed Light" as the weight or something. Donno.
Condensed and Light are linearly independent. So, the statement makes no sense. The face: "light" actually means "<standard width> light" so "Condensed" should show up before <standard width> in any weight. The correct order (width, weight, slant): >> Condensed Light >> Condensed Light Oblique >> Condensed Medium <--- perhaps this should be: "Condensed" >> Condensed Oblique >> Condensed Bold >> Condensed Bold Oblique >> Narrow >> Narrow Oblique >> Narrow Bold >> Narrow Bold Oblique >> Light >> Light Oblique >> Regular <--- perhaps this should be: "Medium" >> Oblique >> Bold >> Bold Oblique
What I'm saying is that, the code is doing: append_field (result, weight_map, G_N_ELEMENTS (weight_map), desc->weight); append_field (result, style_map, G_N_ELEMENTS (style_map), desc->style); append_field (result, stretch_map, G_N_ELEMENTS (stretch_map), desc->stretch); append_field (result, variant_map, G_N_ELEMENTS (variant_map), desc->variant) in pango_font_description_to_string(). So I don't understand how can Condensed (an stretch attribute) come before weigth or style.
*** Bug 521049 has been marked as a duplicate of this bug. ***
the old font selection dialog is deprecated, the replacement has no style list, so closing this one