TextFace
TextFace Select a style for subsequent text drawing Style newStyle ; 0=plain text, 1=bold, 4= underline, etc TextFace selects the test-style variation(s) (bold, italic, underline, etc.) newStyle is an integer value (declared as an enum with a typedef of Style). A value 0 indicates a "plain" unmodified version of the current font.
You can use bit-manipulation operations to combine any of the
following styles using the constants defined in Quickdraw.h:
bold 1 increased width on vertical strokes
italic 2 slanted toward the right
underline 4 underscored, with breaks on descending letters outline 8 È outlined
shadow 16 ÍShadowed ( outlined, heavier on right bottom)
condense 32 ‹less space between characters
extend 64 Îmore space between characters
Notes: TextFace modifies the txFace field of the current GrafPort. It is initially set to 0 (plain text). The variation you select affects all subsequent text
drawing and text measuring.
You can read the current style setting by accessing the txFace field of the
curStyle = thePort -> txFace;
Here are some examples of usage:
TextFace( bold | italic ); /* set to bold and italic */ TextFace( thePort->txFace | bold ); /* add bolding */ TextFace( thePort->txFace & ~bold ); /* remove bolding */ The "condense" and "extend" variations change the spacing between
characters to an arbitrary value set by the Font Manager. Another way to
larger font. You may use SpaceExtra for spacing control; e.g., as an aid in displaying right-justified text.