Patrick R. wrote
Hi everyone :)
I am currently fixing some tests in the Multilingual package. While doing this I edited the StrikeFontSet class and was wondering about its purpose. Although it is called a FontSet it is actually a subclass of AbstractFont and all instances available in a recent image do only contain one single font. Even further some methods of the class are implemented along the line of:
self fontArray first ...
Unfortunately the class does not include a class comment yet and I would like to fix this. That is why I wanted to ask whether anyone still knows the rationale behind this seeming contradiction.
Thanks! and Bests
Patrick
Hi Patrick,
looking at FontSet, I don't think it does something useful. Maybe it was a helper class in the past. See FontSet class >> #installAsTextStyle.
The idea of StrikeFontSet to behave like a single font but being a set of (similar?) fonts is interesting. However, I think that there should be no need for that because we have the TextStyle abstraction to group multiple fonts to be used during layouting and rendering.
If the idea of StrikeFontSet (or any font set) actually is to describe a set of similar fonts that belong to the same
font family, such a grouping will be interesting in an object-oriented sense. Better than text styles, which group arbitrary fonts.
Best,
Marcel