Understanding the rules for centering a sign
Steve Slevinski
slevin at SIGNPUDDLE.NET
Sat Oct 9 11:46:38 UTC 2010
Hi Val,
I'd like to discuss the way SignPuddle centers a sign? The center is
used to align signs for text layout.
To determine the center of a sign with an algorithm, select the
important symbols and create a smallest possible rectangle (a bounding
box) around only those symbols. This bounding box represents the center
of the sign. The absolute center of the bounding box is the center of
the sign.
I'm currently using 2 levels of symbol detection. Either there are head
& trunk symbols or not. If there are head or trunk symbols in a sign,
only the head and trunk symbols are selected and enclosed by the
centering bounding box. If there are no head or trunk symbols, then all
symbols are selected and the absolute center is used.
The current method is good enough, but I was considering a refinement
based on SignSpelling rule #2: "Every sign has a center":
http://www.signwriting.org/lessons/elessons/less064.html
There could be 4 levels of centering:
Head or trunk symbols in sign - select head and trunk symbols.
Contact symbols in sign - select hand and contact symbols.
Hand symbols in sign - select hand symbols.
Otherwise - select everything.
Try these levels while reading SignSpelling Rule #1, "Write the position
of contact":
http://www.signwriting.org/lessons/elessons/less063.html
You can see that a well written sign has a smaller centering bounding
box than a poorly written sign.
I believe this new centering algorithm can improve text layout for both
vertical and horizontal writing.
Regards,
-Steve
More information about the Sw-l
mailing list