[squeak-dev] The Trunk: MorphicTests-mt.87.mcz
Marcel Taeumel
marcel.taeumel at hpi.de
Thu Jun 9 06:56:42 UTC 2022
Hi Karl --
Thanks for the pointer! In this case, we struggle with some legacy overhead in StrikeFont not implementing line gap correctly and mixing it in with line spacing in TextStyle.
However (!), this could be finally the font the help write some TrueType tests. Thanks!!!
Best,
Marcel
Am 09.06.2022 05:56:39 schrieb karl ramberg <karlramberg at gmail.com>:
I'm not sure this is helpful, but I just read about a font called ahem that is designed to help with layout testing. The glyphs are assigned a predefined square so it should result in predictable tests.
https://www.w3.org/Style/CSS/Test/Fonts/Ahem/ [https://www.w3.org/Style/CSS/Test/Fonts/Ahem/]
https://github.com/Hydrock/AhemFont [https://github.com/Hydrock/AhemFont]
Best,
Karl
On Wed, Jun 8, 2022 at 3:02 PM <commits at source.squeak.org [mailto:commits at source.squeak.org]> wrote:
Marcel Taeumel uploaded a new version of MorphicTests to project The Trunk:
http://source.squeak.org/trunk/MorphicTests-mt.87.mcz [http://source.squeak.org/trunk/MorphicTests-mt.87.mcz]
==================== Summary ====================
Name: MorphicTests-mt.87
Author: mt
Time: 8 June 2022, 3:02:18.474335 pm
UUID: 4c18dae8-f267-4c41-a3d4-7027c7a964cd
Ancestors: MorphicTests-mt.86
Fixes several tests that only fail if the system uses (pre-rendered) StrikeFonts, which is 100%, 125%, or 150% scale factor in a clean image.
=============== Diff against MorphicTests-mt.86 ===============
Item was changed:
----- Method: TextAnchorTest>>testHavingAnAnchorInTheCenter (in category 'tests') -----
testHavingAnAnchorInTheCenter
self
assert: (anchoredMorph ownerChain includes: textMorph);
+ assert: anchoredMorph topLeft >= textMorph topLeft!
- assert: anchoredMorph topLeft > textMorph topLeft!
Item was changed:
----- Method: TextAnchorTest>>testHavingAnAnchorInTheCenterWithHorizontalPadding (in category 'tests') -----
testHavingAnAnchorInTheCenterWithHorizontalPadding
anchoredMorph textAnchorProperties padding. 30 at 0.
self
assert: (anchoredMorph ownerChain includes: textMorph);
+ assert: (anchoredMorph topLeft >= textMorph topLeft)!
- assert: (anchoredMorph topLeft > textMorph topLeft)!
Item was changed:
----- Method: TextAnchorTest>>testLayoutingSetsTheMorphPosition (in category 'tests') -----
testLayoutingSetsTheMorphPosition
anchoredMorph := Morph new.
anchoredMorph textAnchorProperties
anchorLayout: #inline.
anchorAttribute anchoredMorph: anchoredMorph.
self prepareTextMorph.
textMorph position: 100 at 100.
+ self assert: anchoredMorph position >= (100 at 100).!
- self assert: anchoredMorph position > (100 at 100).!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20220609/4bbdb4bc/attachment.html>
More information about the Squeak-dev
mailing list
|