
Looks like I'm going to be looking at the CSS limitations rather than the legalization of flow text based on the recommendations of Richard and the fact that there was no overwhelming desire for one over the other (just slightly more desire for flowtext). Here is what bulia wrote earlier (msg continues below):
bulia byak wrote:
- Overcoming the CSS limitations. The vocabulary of CSS font-family,
font-weight, and font-style is very limited and fails to account for fancy variants such as "swoosh", "outline", etc. Even for simpler cases, a 1-to-1 correspondence between a font and a CSS description may be very hard to establish. For example, which of the "light", "ultralight", "heavy", "black", "ultra" etc. weights correspond to which font-weight values? Even if we establish such a correspondence for one font, a different font family may use the same weight terms quite differently. So, what we need is a very simple thing: an extension attribute that stores the _exact_ system name, including variant, of the font that the user selected. Of course all CSS values will still be written for compatibility as best we could, but Inkscape will give that extension attribute priority when selecting which font to use for a text object. Without this, it's unthinkable to use Inkscape for professional design where one often finds elaborate font families with dozens of variants.
There is one thing I've been getting myself confused about.
I have a couple of fonts with, for example, small caps (BernhardMod) and swoosh (Arrus) variants. In the font_factory::Families() function, the function pango_font_map_list_families() is used to retrieve the family names of fonts. These strings are then used in the "font-family" portion of the CSS style. I printed out the list of these names for my system, and found that instead of giving simply Arrus or BernhardMod, I get names that include the small caps or swoosh: BernhardMod ItSwash BT and Arrus SmCap BT.
If the fact that a font is small caps is part of its family name, it is clear that there is no need to include small caps in the CSS style (which would be supported if we wanted to add it there). The same goes for those variants that are not supported by CSS (outline, swoosh, etc). As it happens, the same argument can be used for various weights of fonts - whether a font is medium, light, narrow, wide - it seems to be included in the family name (ex Lithograph and LithographLight)!
If this is true, and I'm not missing something (which is certainly possible), why the need for the Inkscape: attribute?
Of course, all this changes if we update our UI to show actual font families (like just Arrus and BernhardMod), and all available styles of that family in another column.
Gail